mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-20 18:39:39 +00:00
Merge branch 'navcrash' into 'master'
Fix #5798 Closes #5798 See merge request OpenMW/openmw!554
This commit is contained in:
commit
b28adafee4
1 changed files with 3 additions and 11 deletions
|
@ -340,17 +340,9 @@ namespace MWWorld
|
|||
|
||||
if ((*iter)->getCell()->isExterior())
|
||||
{
|
||||
const ESM::Land* land =
|
||||
MWBase::Environment::get().getWorld()->getStore().get<ESM::Land>().search(
|
||||
(*iter)->getCell()->getGridX(),
|
||||
(*iter)->getCell()->getGridY()
|
||||
);
|
||||
if (land && land->mDataTypes&ESM::Land::DATA_VHGT)
|
||||
{
|
||||
if (const auto heightField = mPhysics->getHeightField(cellX, cellY))
|
||||
navigator->removeObject(DetourNavigator::ObjectId(heightField));
|
||||
mPhysics->removeHeightField(cellX, cellY);
|
||||
}
|
||||
if (const auto heightField = mPhysics->getHeightField(cellX, cellY))
|
||||
navigator->removeObject(DetourNavigator::ObjectId(heightField));
|
||||
mPhysics->removeHeightField(cellX, cellY);
|
||||
}
|
||||
|
||||
if ((*iter)->getCell()->hasWater())
|
||||
|
|
Loading…
Reference in a new issue