summaryrefslogtreecommitdiff
path: root/indra/newview/llcontrolavatar.cpp
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2018-09-27 19:34:41 +0100
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2018-09-27 19:34:41 +0100
commit4d4255c27b45ed5e32fe7c4870e2ce3ed10cb140 (patch)
tree50a69d38060aca293aed567e5149597e360128bb /indra/newview/llcontrolavatar.cpp
parent963945b3ab258ea445e1d9757fc5a89ce397ff7b (diff)
SL-1350 - keep control avatar rotation synced to corresponding root drawable
Diffstat (limited to 'indra/newview/llcontrolavatar.cpp')
-rw-r--r--indra/newview/llcontrolavatar.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llcontrolavatar.cpp b/indra/newview/llcontrolavatar.cpp
index 0efed8ab7c..a620f2abe9 100644
--- a/indra/newview/llcontrolavatar.cpp
+++ b/indra/newview/llcontrolavatar.cpp
@@ -175,7 +175,16 @@ void LLControlAvatar::matchVolumeTransform()
// complexity info and such line up better. Should defer
// this until avatars also get fixed.
- LLQuaternion obj_rot = mRootVolp->getRotation();
+ LLQuaternion obj_rot;
+ if (mRootVolp->mDrawable)
+ {
+ obj_rot = mRootVolp->mDrawable->getRotation();
+ }
+ else
+ {
+ obj_rot = mRootVolp->getRotation();
+ }
+
LLMatrix3 bind_mat;
LLQuaternion bind_rot;