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.cs36
1 files changed, 23 insertions, 13 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index 48e65a5..d174d04 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -104,7 +104,7 @@ namespace OpenSim.Region.Framework.Scenes
104 104
105 #endregion Enumerations 105 #endregion Enumerations
106 106
107 public class SceneObjectPart : IScriptHost 107 public class SceneObjectPart : IScriptHost, ISceneEntity
108 { 108 {
109 /// <value> 109 /// <value>
110 /// Denote all sides of the prim 110 /// Denote all sides of the prim
@@ -714,6 +714,24 @@ namespace OpenSim.Region.Framework.Scenes
714 } 714 }
715 } 715 }
716 716
717 public Vector3 RelativePosition
718 {
719 get
720 {
721 if (IsRoot)
722 {
723 if (IsAttachment)
724 return AttachedPos;
725 else
726 return AbsolutePosition;
727 }
728 else
729 {
730 return OffsetPosition;
731 }
732 }
733 }
734
717 public Quaternion RotationOffset 735 public Quaternion RotationOffset
718 { 736 {
719 get 737 get
@@ -985,7 +1003,6 @@ namespace OpenSim.Region.Framework.Scenes
985 get { return AggregateScriptEvents; } 1003 get { return AggregateScriptEvents; }
986 } 1004 }
987 1005
988
989 public Quaternion SitTargetOrientation 1006 public Quaternion SitTargetOrientation
990 { 1007 {
991 get { return m_sitTargetOrientation; } 1008 get { return m_sitTargetOrientation; }
@@ -2911,11 +2928,7 @@ namespace OpenSim.Region.Framework.Scenes
2911 //if (LocalId != ParentGroup.RootPart.LocalId) 2928 //if (LocalId != ParentGroup.RootPart.LocalId)
2912 //isattachment = ParentGroup.RootPart.IsAttachment; 2929 //isattachment = ParentGroup.RootPart.IsAttachment;
2913 2930
2914 byte[] color = new byte[] {m_color.R, m_color.G, m_color.B, m_color.A}; 2931 remoteClient.SendPrimUpdate(this, PrimUpdateFlags.FullUpdate);
2915 remoteClient.SendPrimitiveToClient(new SendPrimitiveData(m_regionHandle, m_parentGroup.GetTimeDilation(), LocalId, m_shape,
2916 lPos, Velocity, Acceleration, RotationOffset, AngularVelocity, clientFlags, m_uuid, _ownerID,
2917 m_text, color, _parentID, m_particleSystem, m_clickAction, (byte)m_material, m_TextureAnimation, IsAttachment,
2918 AttachmentPoint,FromItemID, Sound, SoundGain, SoundFlags, SoundRadius, ParentGroup.GetUpdatePriority(remoteClient)));
2919 } 2932 }
2920 2933
2921 /// <summary> 2934 /// <summary>
@@ -4627,11 +4640,7 @@ namespace OpenSim.Region.Framework.Scenes
4627 4640
4628 // Causes this thread to dig into the Client Thread Data. 4641 // Causes this thread to dig into the Client Thread Data.
4629 // Remember your locking here! 4642 // Remember your locking here!
4630 remoteClient.SendPrimTerseUpdate(new SendPrimitiveTerseData(m_regionHandle, 4643 remoteClient.SendPrimUpdate(this, PrimUpdateFlags.Position | PrimUpdateFlags.Rotation | PrimUpdateFlags.Velocity | PrimUpdateFlags.Acceleration | PrimUpdateFlags.AngularVelocity);
4631 m_parentGroup.GetTimeDilation(), LocalId, lPos,
4632 RotationOffset, Velocity, Acceleration,
4633 AngularVelocity, FromItemID,
4634 OwnerID, (int)AttachmentPoint, null, ParentGroup.GetUpdatePriority(remoteClient)));
4635 } 4644 }
4636 4645
4637 public void AddScriptLPS(int count) 4646 public void AddScriptLPS(int count)
@@ -4681,7 +4690,8 @@ namespace OpenSim.Region.Framework.Scenes
4681 4690
4682 public Color4 GetTextColor() 4691 public Color4 GetTextColor()
4683 { 4692 {
4684 return new Color4((byte)Color.R, (byte)Color.G, (byte)Color.B, (byte)(0xFF - Color.A)); 4693 Color color = Color;
4694 return new Color4(color.R, color.G, color.B, (byte)(0xFF - color.A));
4685 } 4695 }
4686 4696
4687 public void ResetOwnerChangeFlag() 4697 public void ResetOwnerChangeFlag()