aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-10-15 02:42:43 +0100
committerJustin Clark-Casey (justincc)2011-10-15 02:42:43 +0100
commit3843efe478ed682fd08bf12ea8bd7377c68a36fb (patch)
tree9e1b9bc21e2ec4a267728fb6ce05bdcefc0babe2
parentremove redundant PhysActor.IsPhysical call from SOP.UpdatePrimFlags() as its ... (diff)
downloadopensim-SC_OLD-3843efe478ed682fd08bf12ea8bd7377c68a36fb.zip
opensim-SC_OLD-3843efe478ed682fd08bf12ea8bd7377c68a36fb.tar.gz
opensim-SC_OLD-3843efe478ed682fd08bf12ea8bd7377c68a36fb.tar.bz2
opensim-SC_OLD-3843efe478ed682fd08bf12ea8bd7377c68a36fb.tar.xz
Restore [Startup] physical_prim flag which can stop any prims being subject to physics
This had stopped working. However, at the moment it still allows the physics flag to be set even though this has no effect. This needs to be fixed. Default for this flag is true as previously.
-rw-r--r--OpenSim/Framework/ConfigSettings.cs6
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs7
-rw-r--r--bin/OpenSimDefaults.ini3
3 files changed, 14 insertions, 2 deletions
diff --git a/OpenSim/Framework/ConfigSettings.cs b/OpenSim/Framework/ConfigSettings.cs
index b0bdebe..6ee7fee 100644
--- a/OpenSim/Framework/ConfigSettings.cs
+++ b/OpenSim/Framework/ConfigSettings.cs
@@ -34,7 +34,13 @@ namespace OpenSim.Framework
34 public bool See_into_region_from_neighbor { get; set; } 34 public bool See_into_region_from_neighbor { get; set; }
35 public string StorageDll { get; set; } 35 public string StorageDll { get; set; }
36 public string ClientstackDll { get; set; } 36 public string ClientstackDll { get; set; }
37
38 /// <summary>
39 /// Controls whether physics can be applied to prims. Even if false, prims still have entries in a
40 /// PhysicsScene in order to perform collision detection
41 /// </summary>
37 public bool PhysicalPrim { get; set; } 42 public bool PhysicalPrim { get; set; }
43
38 public string LibrariesXMLFile { get; set; } 44 public string LibrariesXMLFile { get; set; }
39 45
40 public const uint DefaultRegionHttpPort = 9000; 46 public const uint DefaultRegionHttpPort = 9000;
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index 05c9924..8ad35d3 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -1551,7 +1551,9 @@ namespace OpenSim.Region.Framework.Scenes
1551 /// <param name="m_physicalPrim"></param> 1551 /// <param name="m_physicalPrim"></param>
1552 public void ApplyPhysics(uint rootObjectFlags, bool VolumeDetectActive, bool m_physicalPrim) 1552 public void ApplyPhysics(uint rootObjectFlags, bool VolumeDetectActive, bool m_physicalPrim)
1553 { 1553 {
1554// m_log.DebugFormat("[SCENE OBJECT PART]: Applying physics to {0} {1} {2}", Name, LocalId, UUID); 1554// m_log.DebugFormat(
1555// "[SCENE OBJECT PART]: Applying physics to {0} {1}, m_physicalPrim {2}",
1556// Name, LocalId, UUID, m_physicalPrim);
1555 1557
1556 bool isPhysical = (((rootObjectFlags & (uint) PrimFlags.Physics) != 0) && m_physicalPrim); 1558 bool isPhysical = (((rootObjectFlags & (uint) PrimFlags.Physics) != 0) && m_physicalPrim);
1557 bool isPhantom = ((rootObjectFlags & (uint) PrimFlags.Phantom) != 0); 1559 bool isPhantom = ((rootObjectFlags & (uint) PrimFlags.Phantom) != 0);
@@ -1816,6 +1818,9 @@ namespace OpenSim.Region.Framework.Scenes
1816 /// <param name="isNew"></param> 1818 /// <param name="isNew"></param>
1817 public void DoPhysicsPropertyUpdate(bool UsePhysics, bool isNew) 1819 public void DoPhysicsPropertyUpdate(bool UsePhysics, bool isNew)
1818 { 1820 {
1821 if (!ParentGroup.Scene.m_physicalPrim && UsePhysics)
1822 return;
1823
1819 if (IsJoint()) 1824 if (IsJoint())
1820 { 1825 {
1821 DoPhysicsPropertyUpdateForNinjaJoint(UsePhysics, isNew); 1826 DoPhysicsPropertyUpdateForNinjaJoint(UsePhysics, isNew);
diff --git a/bin/OpenSimDefaults.ini b/bin/OpenSimDefaults.ini
index e158096..4f4e112 100644
--- a/bin/OpenSimDefaults.ini
+++ b/bin/OpenSimDefaults.ini
@@ -177,7 +177,8 @@
177 ; ## PHYSICS 177 ; ## PHYSICS
178 ; ## 178 ; ##
179 179
180 ; if you would like to allow prims to be physical and move by physics with the physical checkbox in the client set this to true. 180 ; If true then prims can be made subject to physics (gravity, pushing, etc.).
181 ; If false then physics flag can be set but it is not honoured. However, prims are still solid for the purposes of collision direction
181 physical_prim = true 182 physical_prim = true
182 183
183 ; Select a mesher here. 184 ; Select a mesher here.