fix (core): Shallow Water Calulation Correction (#11419)

Shallow water calculation (in water and water walking value) is in correct and were matching. not right at all. this corrects the issue.
This commit is contained in:
acidmanifesto
2022-04-16 16:38:57 -04:00
committed by GitHub
parent 536abaf08d
commit c283883aea

View File

@@ -1965,9 +1965,9 @@ inline LiquidData const GridMap::GetLiquidData(float x, float y, float z, float
if (delta > collisionHeight)
liquidData.Status = LIQUID_MAP_UNDER_WATER;
else if (delta > 0.2f)
else if (delta > 0.0f)
liquidData.Status = LIQUID_MAP_IN_WATER;
else if (delta > -0.2f)
else if (delta > -0.1f)
liquidData.Status = LIQUID_MAP_WATER_WALK;
else
liquidData.Status = LIQUID_MAP_ABOVE_WATER;