From 46ccfa1741abbf445b49e79045e649798d1c0b63 Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Sun, 18 Nov 2007 13:37:02 +0000 Subject: * Found several cases where prim set physical were not subscribing to physics events. --- OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs') diff --git a/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs b/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs index c2bb019..3b5fc57 100644 --- a/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs +++ b/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs @@ -46,6 +46,7 @@ namespace OpenSim.Region.Environment.Scenes SceneObjectPart rootPart = obj.GetChildPart(obj.UUID); bool UsePhysics = (((rootPart.ObjectFlags & (uint)LLObject.ObjectFlags.Physics) > 0) && m_parentScene.m_physicalPrim); if ((rootPart.ObjectFlags & (uint)LLObject.ObjectFlags.Phantom) == 0) + { rootPart.PhysActor = m_innerScene.PhyScene.AddPrimShape( rootPart.Name, rootPart.Shape, @@ -54,6 +55,9 @@ namespace OpenSim.Region.Environment.Scenes new PhysicsVector(rootPart.Scale.X, rootPart.Scale.Y, rootPart.Scale.Z), new Quaternion(rootPart.RotationOffset.W, rootPart.RotationOffset.X, rootPart.RotationOffset.Y, rootPart.RotationOffset.Z), UsePhysics); + rootPart.doPhysicsPropertyUpdate(UsePhysics); + + } primCount++; } } @@ -112,6 +116,7 @@ namespace OpenSim.Region.Environment.Scenes SceneObjectPart rootPart = obj.GetChildPart(obj.UUID); bool UsePhysics = (((rootPart.ObjectFlags & (uint)LLObject.ObjectFlags.Physics) > 0) && m_parentScene.m_physicalPrim); if ((rootPart.ObjectFlags & (uint)LLObject.ObjectFlags.Phantom) == 0) + { rootPart.PhysActor = m_innerScene.PhyScene.AddPrimShape( rootPart.Name, rootPart.Shape, @@ -120,6 +125,8 @@ namespace OpenSim.Region.Environment.Scenes new PhysicsVector(rootPart.Scale.X, rootPart.Scale.Y, rootPart.Scale.Z), new Quaternion(rootPart.RotationOffset.W, rootPart.RotationOffset.X, rootPart.RotationOffset.Y, rootPart.RotationOffset.Z), UsePhysics); + rootPart.doPhysicsPropertyUpdate(UsePhysics); + } } public void SavePrimsToXml2(string fileName) -- cgit v1.1