From 3299e318ca2d97c43f88c9f75408c9d0c2a02608 Mon Sep 17 00:00:00 2001 From: "nethack.allison" Date: Sun, 19 Mar 2006 23:13:11 +0000 Subject: [PATCH] digactualhole() bit I'm pretty sure this check at_u should be included since x,y can be passed to digactualhole(). The lack of any related bug reports suggest that at_u is currently always true for any code that calls digactualhole(). --- doc/fixes34.4 | 1 + src/dig.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/fixes34.4 b/doc/fixes34.4 index 80c9e06fb..ac45b237e 100644 --- a/doc/fixes34.4 +++ b/doc/fixes34.4 @@ -201,6 +201,7 @@ use "your kraken" instead of "a kraken" when searching reveals a tame Magicbane should not produce " are confused" message handle antholes more sensibly when ants aren't available cancelled nurses shouldn't say "Relax, this won't hurt a bit" +check for hero location in digactualhole() before clearing u.utrap Platform- and/or Interface-Specific Fixes diff --git a/src/dig.c b/src/dig.c index 4a2cd240a..0533523f0 100644 --- a/src/dig.c +++ b/src/dig.c @@ -488,7 +488,7 @@ int ttyp; boolean at_u = (x == u.ux) && (y == u.uy); boolean wont_fall = Levitation || Flying; - if (u.utrap) { + if (at_u && u.utrap) { if (u.utraptype == TT_BURIEDBALL) buried_ball_to_punishment(); else if (u.utraptype == TT_INFLOOR) u.utrap = 0; } -- 2.40.0