mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-29 21:45:32 +00:00
Fix isUnderwater checks being off by one for exterior cells
This commit is contained in:
parent
86881bcf39
commit
d0c6b407b4
2 changed files with 3 additions and 1 deletions
|
@ -296,6 +296,8 @@ namespace MWWorld
|
|||
|
||||
float CellStore::getWaterLevel() const
|
||||
{
|
||||
if (isExterior())
|
||||
return -1;
|
||||
return mWaterLevel;
|
||||
}
|
||||
|
||||
|
|
|
@ -265,7 +265,7 @@ namespace MWWorld
|
|||
|
||||
mRendering.addCell(cell);
|
||||
bool waterEnabled = cell->getCell()->hasWater() || cell->isExterior();
|
||||
float waterLevel = cell->isExterior() ? -1.f : cell->getWaterLevel();
|
||||
float waterLevel = cell->getWaterLevel();
|
||||
mRendering.setWaterEnabled(waterEnabled);
|
||||
if (waterEnabled)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue