aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectPart.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs22
1 files changed, 8 insertions, 14 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index ba84b88..badd357 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -682,25 +682,13 @@ namespace OpenSim.Region.Framework.Scenes
682 682
683 // Tell the physics engines that this prim changed. 683 // Tell the physics engines that this prim changed.
684 m_parentGroup.Scene.PhysicsScene.AddPhysicsActorTaint(actor); 684 m_parentGroup.Scene.PhysicsScene.AddPhysicsActorTaint(actor);
685
685 } 686 }
686 catch (Exception e) 687 catch (Exception e)
687 { 688 {
688 m_log.Error("[SCENEOBJECTPART]: GROUP POSITION. " + e.Message); 689 m_log.Error("[SCENEOBJECTPART]: GROUP POSITION. " + e.Message);
689 } 690 }
690 } 691 }
691
692 // TODO if we decide to do sitting in a more SL compatible way (multiple avatars per prim), this has to be fixed, too
693 if (m_sitTargetAvatar != UUID.Zero)
694 {
695 if (m_parentGroup != null) // TODO can there be a SOP without a SOG?
696 {
697 ScenePresence avatar;
698 if (m_parentGroup.Scene.TryGetScenePresence(m_sitTargetAvatar, out avatar))
699 {
700 avatar.ParentPosition = GetWorldPosition();
701 }
702 }
703 }
704 } 692 }
705 } 693 }
706 694
@@ -709,6 +697,7 @@ namespace OpenSim.Region.Framework.Scenes
709 get { return m_offsetPosition; } 697 get { return m_offsetPosition; }
710 set 698 set
711 { 699 {
700 Vector3 oldpos = m_offsetPosition;
712 StoreUndoState(UndoType.STATE_PRIM_POSITION); 701 StoreUndoState(UndoType.STATE_PRIM_POSITION);
713 m_offsetPosition = value; 702 m_offsetPosition = value;
714 703
@@ -727,7 +716,12 @@ namespace OpenSim.Region.Framework.Scenes
727 List<ScenePresence> avs = ParentGroup.GetLinkedAvatars(); 716 List<ScenePresence> avs = ParentGroup.GetLinkedAvatars();
728 foreach (ScenePresence av in avs) 717 foreach (ScenePresence av in avs)
729 { 718 {
730 av.SendFullUpdateToAllClients(); 719 if (av.LinkedPrim == m_uuid)
720 {
721 Vector3 offset = (m_offsetPosition - oldpos);
722 av.OffsetPosition += offset;
723 av.SendFullUpdateToAllClients();
724 }
731 } 725 }
732 } 726 }
733 } 727 }