From df6c9cee730fe98f42807df302f4c385d48fe109 Mon Sep 17 00:00:00 2001 From: AJ Martinez Date: Fri, 19 May 2023 15:34:54 -0700 Subject: [PATCH] Instashield: actually do height checks --- src/p_map.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/p_map.c b/src/p_map.c index d96afc08d..b72ce2145 100644 --- a/src/p_map.c +++ b/src/p_map.c @@ -745,6 +745,10 @@ static BlockItReturn_t PIT_CheckThing(mobj_t *thing) if (tm.thing->type == MT_INSTAWHIP) { + if (tm.thing->z > thing->z + thing->height) + return BMIT_CONTINUE; // overhead + if (tm.thing->z + tm.thing->height < thing->z) + return BMIT_CONTINUE; // underneath K_InstaWhipCollide(tm.thing, thing); return BMIT_CONTINUE; }