* This fixes mantis 553 (It appears that the exception is thrown when there is a collision with a cylinder that is both hollowed and either tapered or cut. The sequence of actions that reproduce the problem for me are: create a cylinder, hollow to 95%, taper X/Y, then collide it with another object or avatar. Note that the cylinder itself is not marked physical. )
parent
df21da6dec
commit
2e89c01851
|
@ -92,7 +92,7 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
public OdePrim(String primName, OdeScene parent_scene, IntPtr targetSpace, PhysicsVector pos, PhysicsVector size,
|
public OdePrim(String primName, OdeScene parent_scene, IntPtr targetSpace, PhysicsVector pos, PhysicsVector size,
|
||||||
Quaternion rotation, IMesh mesh, PrimitiveBaseShape pbs, bool pisPhysical)
|
Quaternion rotation, IMesh mesh, PrimitiveBaseShape pbs, bool pisPhysical)
|
||||||
{
|
{
|
||||||
System.Threading.Thread.Sleep(20);
|
|
||||||
_velocity = new PhysicsVector();
|
_velocity = new PhysicsVector();
|
||||||
_position = pos;
|
_position = pos;
|
||||||
m_taintposition = pos;
|
m_taintposition = pos;
|
||||||
|
|
|
@ -730,7 +730,16 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
try
|
||||||
|
{
|
||||||
|
|
||||||
|
d.GeomDestroy(prim.prim_geom);
|
||||||
|
}
|
||||||
|
catch (System.AccessViolationException)
|
||||||
|
{
|
||||||
|
m_log.Info("[PHYSICS]: Couldn't remove prim from physics scene, it was already be removed.");
|
||||||
|
}
|
||||||
|
_prims.Remove(prim);
|
||||||
|
|
||||||
//If there are no more geometries in the sub-space, we don't need it in the main space anymore
|
//If there are no more geometries in the sub-space, we don't need it in the main space anymore
|
||||||
if (d.SpaceGetNumGeoms(prim.m_targetSpace) == 0)
|
if (d.SpaceGetNumGeoms(prim.m_targetSpace) == 0)
|
||||||
|
@ -755,9 +764,7 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
d.GeomDestroy(prim.prim_geom);
|
|
||||||
|
|
||||||
_prims.Remove(prim);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
Loading…
Reference in New Issue