summaryrefslogtreecommitdiff
path: root/indra/newview/llvoavatar.cpp
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2014-12-11 16:33:34 -0500
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2014-12-11 16:33:34 -0500
commita357a4096cb645956a2432adfd5dcadc55c153f5 (patch)
tree22b8a59fa5ea2abed572a4f5fc388aeecf859bb9 /indra/newview/llvoavatar.cpp
parentc9981ec59c4613531b2d5bb03f6ab8f6d914343c (diff)
SL-92 WIP
Diffstat (limited to 'indra/newview/llvoavatar.cpp')
-rwxr-xr-xindra/newview/llvoavatar.cpp19
1 files changed, 17 insertions, 2 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index d150ace455..118ed10eb2 100755
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -3219,6 +3219,10 @@ BOOL LLVOAvatar::updateCharacter(LLAgent &agent)
{
debug_line += llformat(" - cof rcv:%d", last_received_cof_version);
}
+ if (mHoverOffset[2] != 0.0)
+ {
+ debug_line += llformat(" hov_z: %f", mHoverOffset[2]);
+ }
addDebugText(debug_line);
}
if (gSavedSettings.getBOOL("DebugAvatarCompositeBaked"))
@@ -3589,7 +3593,7 @@ BOOL LLVOAvatar::updateCharacter(LLAgent &agent)
else if (mDrawable.notNull())
{
LLVector3 pos = mDrawable->getPosition();
- pos += mHoverOffset;
+ pos += mHoverOffset * mDrawable->getRotation();
mRoot->setPosition(pos);
mRoot->setRotation(mDrawable->getRotation());
}
@@ -7327,11 +7331,22 @@ void LLVOAvatar::processAvatarAppearance( LLMessageSystem* mesgsys )
}
}
- if (contents.mHoverOffsetWasSet)
+ if (contents.mHoverOffsetWasSet && !isSelf())
{
+ // Got an update for some other avatar.
+ // (Ignore updates for self because they may be out of date.)
mHoverOffset = contents.mHoverOffset;
}
+ if (!contents.mHoverOffsetWasSet)
+ {
+ // If we don't get a value at all, we are presumably in a
+ // region that does not support hover height.
+// FIXME RESTORE AFTER TESTING
+ LL_WARNS() << "zeroing hover because not defined in appearance message" << LL_ENDL;
+ mHoverOffset = LLVector3(0.0, 0.0, 0.0);
+ }
+
setCompositeUpdatesEnabled( TRUE );
// If all of the avatars are completely baked, release the global image caches to conserve memory.