aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs8
-rw-r--r--OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs5
2 files changed, 9 insertions, 4 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index ea3d716..1c72b10 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -916,7 +916,7 @@ namespace OpenSim.Region.Framework.Scenes
916 get 916 get
917 { 917 {
918 PhysicsActor actor = PhysActor; 918 PhysicsActor actor = PhysActor;
919 if ((actor != null) && actor.IsPhysical) 919 if ((actor != null) && actor.IsPhysical && ParentGroup.RootPart == this)
920 { 920 {
921 m_angularVelocity = actor.RotationalVelocity; 921 m_angularVelocity = actor.RotationalVelocity;
922 } 922 }
@@ -1893,7 +1893,8 @@ namespace OpenSim.Region.Framework.Scenes
1893 1893
1894 Velocity = new Vector3(0, 0, 0); 1894 Velocity = new Vector3(0, 0, 0);
1895 Acceleration = new Vector3(0, 0, 0); 1895 Acceleration = new Vector3(0, 0, 0);
1896 AngularVelocity = new Vector3(0, 0, 0); 1896 if (ParentGroup.RootPart == this)
1897 AngularVelocity = new Vector3(0, 0, 0);
1897 1898
1898 PhysActor.OnRequestTerseUpdate -= PhysicsRequestingTerseUpdate; 1899 PhysActor.OnRequestTerseUpdate -= PhysicsRequestingTerseUpdate;
1899 PhysActor.OnOutOfBounds -= PhysicsOutOfBounds; 1900 PhysActor.OnOutOfBounds -= PhysicsOutOfBounds;
@@ -1917,7 +1918,8 @@ namespace OpenSim.Region.Framework.Scenes
1917 // velocity-vector. 1918 // velocity-vector.
1918 Velocity = new Vector3(0, 0, 0); 1919 Velocity = new Vector3(0, 0, 0);
1919 Acceleration = new Vector3(0, 0, 0); 1920 Acceleration = new Vector3(0, 0, 0);
1920 AngularVelocity = new Vector3(0, 0, 0); 1921 if (ParentGroup.RootPart == this)
1922 AngularVelocity = new Vector3(0, 0, 0);
1921 //RotationalVelocity = new Vector3(0, 0, 0); 1923 //RotationalVelocity = new Vector3(0, 0, 0);
1922 } 1924 }
1923 1925
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs
index ae46c97..78e9b29 100644
--- a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs
+++ b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs
@@ -99,8 +99,11 @@ namespace OpenSim.Region.OptionalModules.World.NPC
99 // Delete existing sp attachments 99 // Delete existing sp attachments
100 scene.AttachmentsModule.DeleteAttachmentsFromScene(sp, false); 100 scene.AttachmentsModule.DeleteAttachmentsFromScene(sp, false);
101 101
102 AvatarAppearance app = new AvatarAppearance(appearance, true);
103 sp.Appearance = app;
104
102 // Set new sp appearance. Also sends to clients. 105 // Set new sp appearance. Also sends to clients.
103 scene.RequestModuleInterface<IAvatarFactoryModule>().SetAppearance(sp, new AvatarAppearance(appearance, true)); 106 scene.RequestModuleInterface<IAvatarFactoryModule>().SetAppearance(sp, app);
104 107
105 // Rez needed sp attachments 108 // Rez needed sp attachments
106 scene.AttachmentsModule.RezAttachments(sp); 109 scene.AttachmentsModule.RezAttachments(sp);