fix #H260 - escaping lava let you stay there indefinitely

<email deleted>, escaping from being stuck
by lava via jumping--or simply walking--got you out of the lava while being
at the same location.  You could then stay there for as long as you liked
without falling back in.  This makes a lava and water check on turns where
time passes but hero hasn't moved, performing a subset of spoteffects().
I think the water case only matters when using wizard mode to wish for a
pool or moat, which gets created at hero's feet without making him fall in
(unlike wishing for lava, where hero does immediately fall in).
This commit is contained in:
nethack.rankin
2007-03-13 03:13:09 +00:00
parent f67a4547ac
commit d302e6252b
4 changed files with 27 additions and 2 deletions

View File

@@ -1,4 +1,4 @@
/* SCCS Id: @(#)allmain.c 3.5 2007/02/16 */
/* SCCS Id: @(#)allmain.c 3.5 2007/03/12 */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/* NetHack may be freely redistributed. See license for details. */
@@ -321,6 +321,8 @@ boolean resuming;
!In_endgame(&u.uz) && !BClairvoyant &&
!(moves % 15) && !rn2(2)) do_vicinity_map();
if (u.utrap && u.utraptype == TT_LAVA) sink_into_lava();
/* when/if hero escapes from lava, he can't just stay there */
else if (!u.umoved) stayeffects();
} /* actual time passed */