From fe9f77850ab05767d1e4fc0eddef5f2a238ba713 Mon Sep 17 00:00:00 2001 From: Loobinex Date: Mon, 29 Jul 2024 01:00:58 +0200 Subject: [PATCH] Rebounded shots can kill destructible traps too --- src/thing_shots.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/thing_shots.c b/src/thing_shots.c index 11d1af7c78..a1d4f3d675 100644 --- a/src/thing_shots.c +++ b/src/thing_shots.c @@ -1205,9 +1205,12 @@ long shot_hit_creature_at(struct Thing *shotng, struct Thing *trgtng, struct Coo pos2.y.val = killertng->mappos.y.val; if(thing_is_deployed_trap(killertng)) { - pos2.z.val = killertng->mappos.z.val; pos2.z.val += (killertng->clipbox_size_z >> 1); + if (thing_is_destructible_trap(killertng)) + { + shotng->shot.hit_type = THit_CrtrsNObjctsNotOwn; + } } else {