wizard mode wishing for terrain

Fix some issues noticed when experimenting with ceiling hiders.
They're all blind (at least without the monks' Eyes) and some of
the behavior while blind seemed to be incorrect (though some that
I thought was wrong turned out to be ok; feel_newsym() won't update
the map if the hero can't reach the floor).  Fixing that made me
notice that some terrain side-effects (being underwater or stuck in
lava) weren't getting disabled when the underlying terrain wasn't
the corresponding type anymore.
This commit is contained in:
PatR
2019-12-17 18:14:08 -08:00
parent 0ee445ce0b
commit 512f886ca6
3 changed files with 54 additions and 49 deletions

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 trap.c $NHDT-Date: 1576274483 2019/12/13 22:01:23 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.325 $ */
/* NetHack 3.6 trap.c $NHDT-Date: 1576635243 2019/12/18 02:14:03 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.328 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Robert Patrick Rankin, 2013. */
/* NetHack may be freely redistributed. See license for details. */
@@ -3746,6 +3746,7 @@ drown()
boolean inpool_ok = FALSE, crawl_ok;
int i, x, y;
feel_newsym(u.ux, u.uy); /* in case Blind, map the water here */
/* happily wading in the same contiguous pool */
if (u.uinwater && is_pool(u.ux - u.dx, u.uy - u.dy)
&& (Swimming || Amphibious)) {
@@ -5262,6 +5263,7 @@ lava_effects()
int dmg = d(6, 6); /* only applicable for water walking */
boolean usurvive, boil_away;
feel_newsym(u.ux, u.uy); /* in case Blind, map the lava here */
burn_away_slime();
if (likes_lava(youmonst.data))
return FALSE;