From 79aea3e588c7458cee9ec1ee7a66dac389475e62 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Sun, 20 Jul 2014 09:21:00 +0100 Subject: physicsSit SendSitResponse also relative to parent prim --- OpenSim/Region/Framework/Scenes/ScenePresence.cs | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index f57d4fe..f54ba9c 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs @@ -2824,14 +2824,20 @@ namespace OpenSim.Region.Framework.Scenes Vector3 cameraEyeOffset = part.GetCameraEyeOffset(); bool forceMouselook = part.GetForceMouselook(); - ControllingClient.SendSitResponse( - part.UUID, offset, Orientation, false, cameraAtOffset, cameraEyeOffset, forceMouselook); - - // not using autopilot - Rotation = Orientation; m_pos = offset; + if (!part.IsRoot) + { + Orientation = part.RotationOffset * Orientation; + offset = offset * part.RotationOffset; + offset += part.OffsetPosition; + } + + ControllingClient.SendSitResponse( + part.ParentGroup.UUID, offset, Orientation, false, cameraAtOffset, cameraEyeOffset, forceMouselook); + + m_requestedSitTargetID = 0; part.ParentGroup.AddAvatar(UUID); -- cgit v1.1