MAINT-931 Fixed Sitting avatar's rotation is not updated correctly viewer side

master
andreykproductengine 2018-02-14 20:17:55 +02:00
parent bbb516c5ae
commit 86935443eb
1 changed files with 8 additions and 3 deletions

View File

@ -1587,9 +1587,14 @@ void LLPanelObject::sendRotation(BOOL btn_down)
{
rotation = rotation * ~mRootObject->getRotationRegion();
}
// To include avatars into movements and rotation
// If false, all children are selected anyway - move avatar
// If true, not all children are selected - save positions
bool individual_selection = gSavedSettings.getBOOL("EditLinkedParts");
std::vector<LLVector3>& child_positions = mObject->mUnselectedChildrenPositions ;
std::vector<LLQuaternion> child_rotations;
if (mObject->isRootEdit())
if (mObject->isRootEdit() && individual_selection)
{
mObject->saveUnselectedChildrenRotation(child_rotations) ;
mObject->saveUnselectedChildrenPosition(child_positions) ;
@ -1599,8 +1604,8 @@ void LLPanelObject::sendRotation(BOOL btn_down)
LLManip::rebuild(mObject) ;
// for individually selected roots, we need to counterrotate all the children
if (mObject->isRootEdit())
{
if (mObject->isRootEdit() && individual_selection)
{
mObject->resetChildrenRotationAndPosition(child_rotations, child_positions) ;
}