diff options
Diffstat (limited to 'indra/newview/llagent.cpp')
-rwxr-xr-x | indra/newview/llagent.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index bff691769a..ecc3acd91a 100755 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -1092,11 +1092,19 @@ const LLVector3d &LLAgent::getPositionGlobal() const //----------------------------------------------------------------------------- const LLVector3 &LLAgent::getPositionAgent() { - if (isAgentAvatarValid() && !gAgentAvatarp->mDrawable.isNull()) + if (isAgentAvatarValid()) { - mFrameAgent.setOrigin(gAgentAvatarp->getRenderPosition()); + if(gAgentAvatarp->mDrawable.isNull()) + { + mFrameAgent.setOrigin(gAgentAvatarp->getPositionAgent()); + } + else + { + mFrameAgent.setOrigin(gAgentAvatarp->getRenderPosition()); + } } + return mFrameAgent.getOrigin(); } |