From c3d665fda600d887075c1ac686170e6a3d41b635 Mon Sep 17 00:00:00 2001 From: Brad Harding Date: Fri, 6 Dec 2024 08:33:13 +1100 Subject: [PATCH] Improve traversing adjacent liquid sectors at different heights --- src/p_map.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/p_map.c b/src/p_map.c index 7654bc0fc..21c9bce28 100644 --- a/src/p_map.c +++ b/src/p_map.c @@ -1001,7 +1001,7 @@ bool P_IsInLiquid(mobj_t *thing) { const sector_t *sector = seclist->m_sector; - if (sector->terraintype < LIQUID || sector->isselfreferencing) + if ((sector->terraintype < LIQUID && thing->z == sector->floorheight) || sector->isselfreferencing) return false; } } @@ -1018,7 +1018,7 @@ bool P_IsInLiquid(mobj_t *thing) { const sector_t *sector = seclist->m_sector; - if (sector->terraintype < LIQUID || sector->isselfreferencing) + if ((sector->terraintype < LIQUID && thing->z == sector->floorheight) || sector->isselfreferencing) return false; } }