aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Physics/OdePlugin/ODEPrim.cs')
-rw-r--r--OpenSim/Region/Physics/OdePlugin/ODEPrim.cs22
1 files changed, 14 insertions, 8 deletions
diff --git a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
index 13c69d6..b4b7e7f 100644
--- a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
+++ b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
@@ -351,10 +351,11 @@ namespace OpenSim.Region.Physics.OdePlugin
351 if (m_assetFailed) 351 if (m_assetFailed)
352 { 352 {
353 d.GeomSetCategoryBits(prim_geom, 0); 353 d.GeomSetCategoryBits(prim_geom, 0);
354 d.GeomSetCollideBits(prim_geom, BadMeshAssetCollideBits); 354 d.GeomSetCollideBits(prim_geom, BadAssetColideBits());
355 } 355 }
356 else 356 else
357 { 357 {
358
358 d.GeomSetCategoryBits(prim_geom, (int)m_collisionCategories); 359 d.GeomSetCategoryBits(prim_geom, (int)m_collisionCategories);
359 d.GeomSetCollideBits(prim_geom, (int)m_collisionFlags); 360 d.GeomSetCollideBits(prim_geom, (int)m_collisionFlags);
360 } 361 }
@@ -424,7 +425,7 @@ namespace OpenSim.Region.Physics.OdePlugin
424 if (m_assetFailed) 425 if (m_assetFailed)
425 { 426 {
426 d.GeomSetCategoryBits(prim_geom, 0); 427 d.GeomSetCategoryBits(prim_geom, 0);
427 d.GeomSetCollideBits(prim_geom, BadMeshAssetCollideBits); 428 d.GeomSetCollideBits(prim_geom, BadAssetColideBits());
428 } 429 }
429 else 430 else
430 { 431 {
@@ -857,6 +858,11 @@ namespace OpenSim.Region.Physics.OdePlugin
857 858
858 private static Dictionary<IMesh, IntPtr> m_MeshToTriMeshMap = new Dictionary<IMesh, IntPtr>(); 859 private static Dictionary<IMesh, IntPtr> m_MeshToTriMeshMap = new Dictionary<IMesh, IntPtr>();
859 860
861 public int BadAssetColideBits()
862 {
863 return (m_isphysical ? (int)CollisionCategories.Land : 0);
864 }
865
860 private void setMesh(OdeScene parent_scene, IMesh mesh) 866 private void setMesh(OdeScene parent_scene, IMesh mesh)
861 { 867 {
862// m_log.DebugFormat("[ODE PRIM]: Setting mesh on {0} to {1}", Name, mesh); 868// m_log.DebugFormat("[ODE PRIM]: Setting mesh on {0} to {1}", Name, mesh);
@@ -1138,7 +1144,7 @@ Console.WriteLine("ZProcessTaints for " + Name);
1138 if (prm.m_assetFailed) 1144 if (prm.m_assetFailed)
1139 { 1145 {
1140 d.GeomSetCategoryBits(prm.prim_geom, 0); 1146 d.GeomSetCategoryBits(prm.prim_geom, 0);
1141 d.GeomSetCollideBits(prm.prim_geom, prm.BadMeshAssetCollideBits); 1147 d.GeomSetCollideBits(prm.prim_geom, prm.BadAssetColideBits());
1142 } 1148 }
1143 else 1149 else
1144 { 1150 {
@@ -1192,7 +1198,7 @@ Console.WriteLine("ZProcessTaints for " + Name);
1192 if (m_assetFailed) 1198 if (m_assetFailed)
1193 { 1199 {
1194 d.GeomSetCategoryBits(prim_geom, 0); 1200 d.GeomSetCategoryBits(prim_geom, 0);
1195 d.GeomSetCollideBits(prim_geom, BadMeshAssetCollideBits); 1201 d.GeomSetCollideBits(prim_geom, BadAssetColideBits());
1196 } 1202 }
1197 else 1203 else
1198 { 1204 {
@@ -1394,7 +1400,7 @@ Console.WriteLine("ZProcessTaints for " + Name);
1394 if (m_assetFailed) 1400 if (m_assetFailed)
1395 { 1401 {
1396 d.GeomSetCategoryBits(prim_geom, 0); 1402 d.GeomSetCategoryBits(prim_geom, 0);
1397 d.GeomSetCollideBits(prim_geom, BadMeshAssetCollideBits); 1403 d.GeomSetCollideBits(prim_geom, BadAssetColideBits());
1398 } 1404 }
1399 else 1405 else
1400 { 1406 {
@@ -2138,7 +2144,7 @@ Console.WriteLine(" JointCreateFixed");
2138 } 2144 }
2139 2145
2140 if (m_assetFailed) 2146 if (m_assetFailed)
2141 d.GeomSetCollideBits(prim_geom, BadMeshAssetCollideBits); 2147 d.GeomSetCollideBits(prim_geom, BadAssetColideBits());
2142 else 2148 else
2143 2149
2144 d.GeomSetCollideBits(prim_geom, (int)m_collisionFlags); 2150 d.GeomSetCollideBits(prim_geom, (int)m_collisionFlags);
@@ -2949,7 +2955,7 @@ Console.WriteLine(" JointCreateFixed");
2949 } 2955 }
2950 public override bool PIDActive { set { m_usePID = value; } } 2956 public override bool PIDActive { set { m_usePID = value; } }
2951 public override float PIDTau { set { m_PIDTau = value; } } 2957 public override float PIDTau { set { m_PIDTau = value; } }
2952 2958
2953 public override float PIDHoverHeight { set { m_PIDHoverHeight = value; ; } } 2959 public override float PIDHoverHeight { set { m_PIDHoverHeight = value; ; } }
2954 public override bool PIDHoverActive { set { m_useHoverPID = value; } } 2960 public override bool PIDHoverActive { set { m_useHoverPID = value; } }
2955 public override PIDHoverType PIDHoverType { set { m_PIDHoverType = value; } } 2961 public override PIDHoverType PIDHoverType { set { m_PIDHoverType = value; } }
@@ -3376,4 +3382,4 @@ Console.WriteLine(" JointCreateFixed");
3376 } 3382 }
3377 } 3383 }
3378 } 3384 }
3379} \ No newline at end of file 3385}