mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-04 03:40:14 +00:00
Fix removing heightfield from navigator
It's added not as object so it shouldn't be removed as it.
This commit is contained in:
parent
1e7b9fb6a5
commit
6adf7b10ae
@ -397,8 +397,8 @@ namespace MWWorld
|
||||
|
||||
if (cell->getCell()->isExterior())
|
||||
{
|
||||
if (const auto heightField = mPhysics->getHeightField(cellX, cellY))
|
||||
mNavigator.removeObject(DetourNavigator::ObjectId(heightField));
|
||||
if (mPhysics->getHeightField(cellX, cellY) != nullptr)
|
||||
mNavigator.removeHeightfield(osg::Vec2i(cellX, cellY));
|
||||
}
|
||||
|
||||
if (cell->getCell()->hasWater())
|
||||
|
Loading…
x
Reference in New Issue
Block a user