mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-19 20:53:50 +00:00
Added check before removing water collision object from world
This commit is contained in:
parent
e30dfb13d3
commit
7c2a088b34
1 changed files with 4 additions and 1 deletions
|
@ -1463,7 +1463,10 @@ namespace MWPhysics
|
||||||
{
|
{
|
||||||
if (mWaterCollisionObject.get())
|
if (mWaterCollisionObject.get())
|
||||||
{
|
{
|
||||||
mCollisionWorld->removeCollisionObject(mWaterCollisionObject.get());
|
if (mWaterCollisionObject.get()->getWorldArrayIndex() >= 0)
|
||||||
|
{
|
||||||
|
mCollisionWorld->removeCollisionObject(mWaterCollisionObject.get());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!mWaterEnabled)
|
if (!mWaterEnabled)
|
||||||
|
|
Loading…
Reference in a new issue