ubode: fix physical prims space destroy

This commit is contained in:
UbitUmarov
2022-10-29 03:49:53 +01:00
parent ec793ae7d3
commit 327fad2a6e

View File

@@ -1582,7 +1582,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
//waitForSpaceUnlock(currentspace);
SafeNativeMethods.SpaceRemove(currentspace, geom);
if (SafeNativeMethods.SpaceGetSublevel(currentspace) > 2 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0)
if (SafeNativeMethods.SpaceGetSublevel(currentspace) == 0 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0)
{
SafeNativeMethods.SpaceDestroy(currentspace);
}
@@ -1603,7 +1603,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
//waitForSpaceUnlock(currentspace);
SafeNativeMethods.SpaceRemove(currentspace, geom);
if (SafeNativeMethods.SpaceGetSublevel(currentspace) > 2 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0)
if (SafeNativeMethods.SpaceGetSublevel(currentspace) == 0 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0)
{
SafeNativeMethods.SpaceDestroy(currentspace);
}