Merge branch 'justincc-master'

master-beforevarregion
Justin Clark-Casey (justincc) 2014-01-10 20:37:14 +00:00
commit 68cbccb288
1 changed files with 5 additions and 5 deletions

View File

@ -3235,13 +3235,10 @@ namespace OpenSim.Region.Framework.Scenes
Vector3 oldPos;
// FIXME: This improves the situation where editing just the root prim of an attached object would send
// all the other parts to oblivion after detach/reattach. However, a problem remains since the root prim
// still ends up in the wrong position on reattach.
if (IsAttachment)
oldPos = RootPart.OffsetPosition;
oldPos = m_rootPart.AttachedPos + m_rootPart.OffsetPosition; // OffsetPosition should always be 0 in an attachments's root prim
else
oldPos = AbsolutePosition + RootPart.OffsetPosition;
oldPos = AbsolutePosition + m_rootPart.OffsetPosition;
Vector3 diff = oldPos - newPos;
Quaternion partRotation = m_rootPart.RotationOffset;
@ -3257,6 +3254,9 @@ namespace OpenSim.Region.Framework.Scenes
AbsolutePosition = newPos;
if (IsAttachment)
m_rootPart.AttachedPos = newPos;
HasGroupChanged = true;
ScheduleGroupForTerseUpdate();
}