-$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.38 $ $NHDT-Date: 1559685281 2019/06/04 21:54:41 $
+$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.41 $ $NHDT-Date: 1559733390 2019/06/05 11:16:30 $
This fixes36.3 file is here to capture information about updates in the 3.6.x
lineage following the release of 3.6.2 in May 2019. Please note, however,
fix memory leak if corpse auto-revival attempt failed ("you feel less hassled")
allow a parent function to issue an an unplacebc() call that restricts
subsequent placebc() calls to that parent only
+flying monsters could enter water on the Plane of Water but then they'd drown
+ unless they could also swim or else didn't need to breathe
+when finding a place to put a monster on the Plane of Water, don't pick a
+ water location for flyers or floaters (levitate) or clingers (ceiling)
Fixes to Post-3.6.2 Problems that Were Exposed Via git Repository
-/* NetHack 3.6 makemon.c $NHDT-Date: 1556150377 2019/04/24 23:59:37 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.134 $ */
+/* NetHack 3.6 makemon.c $NHDT-Date: 1559733390 2019/06/05 11:16:30 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.137 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Robert Patrick Rankin, 2012. */
/* NetHack may be freely redistributed. See license for details. */
struct monst fakemon;
cc.x = cc.y = 0; /* lint suppression */
+ fakemon = zeromonst;
fakemon.data = ptr; /* set up for goodpos */
if (!makemon_rnd_goodpos(ptr ? &fakemon : (struct monst *)0,
gpflags, &cc))
-/* NetHack 3.6 mon.c $NHDT-Date: 1559596286 2019/06/03 21:11:26 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.291 $ */
+/* NetHack 3.6 mon.c $NHDT-Date: 1559733390 2019/06/05 11:16:30 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.292 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Derek S. Ray, 2015. */
/* NetHack may be freely redistributed. See license for details. */
{
boolean inpool, inlava, infountain;
- /* [what about ceiling clingers?] */
+ /* [ceiling clingers are handled below] */
inpool = (is_pool(mtmp->mx, mtmp->my)
&& (!(is_flyer(mtmp->data) || is_floater(mtmp->data))
/* there's no "above the surface" on the plane of water */
nowtyp = levl[x][y].typ;
nodiag = NODIAG(mdat - mons);
- wantpool = mdat->mlet == S_EEL;
- poolok = (is_flyer(mdat) || is_clinger(mdat)
+ wantpool = (mdat->mlet == S_EEL);
+ poolok = ((!Is_waterlevel(&u.uz)
+ && (is_flyer(mdat) || is_floater(mdat) || is_clinger(mdat)))
|| (is_swimmer(mdat) && !wantpool));
- lavaok = (is_flyer(mdat) || is_clinger(mdat) || likes_lava(mdat));
+ /* note: floating eye is the only is_floater() so this could be
+ simplified, but then adding another floater would be error prone */
+ lavaok = (is_flyer(mdat) || is_floater(mdat) || is_clinger(mdat)
+ || likes_lava(mdat));
+ if (mdat == &mons[PM_FLOATING_EYE]) /* prefers to avoid heat */
+ lavaok = FALSE;
thrudoor = ((flag & (ALLOW_WALL | BUSTDOOR)) != 0L);
poisongas_ok = ((nonliving(mdat) || is_vampshifter(mon)
|| breathless(mdat)) || resists_poison(mon));
rloc_to(mon, mx, my); /* note: mon, not mtmp */
} else {
/* last resort - migrate mon to the next plane */
- if (Is_waterlevel(&u.uz) || Is_firelevel(&u.uz) || Is_earthlevel(&u.uz)) {
+ if (Is_waterlevel(&u.uz) || Is_firelevel(&u.uz)
+ || Is_earthlevel(&u.uz)) {
/* try sending mon on to the next plane */
xchar target_lev = 0, xyloc = 0;
struct trap *trap = ftrap;
-/* NetHack 3.6 teleport.c $NHDT-Date: 1559227830 2019/05/30 14:50:30 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.87 $ */
+/* NetHack 3.6 teleport.c $NHDT-Date: 1559733391 2019/06/05 11:16:31 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.88 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Robert Patrick Rankin, 2011. */
/* NetHack may be freely redistributed. See license for details. */
mdat = mtmp->data;
if (is_pool(x, y) && !ignorewater) {
+ /* [what about Breathless?] */
if (mtmp == &youmonst)
- return (Levitation || Flying || Wwalking || Swimming
- || Amphibious);
+ return (Swimming || Amphibious
+ || (!Is_waterlevel(&u.uz)
+ /* water on the Plane of Water has no surface
+ so there's no way to be on or above that */
+ && (Levitation || Flying || Wwalking)));
else
- return (is_floater(mdat) || is_flyer(mdat) || is_swimmer(mdat)
- || is_clinger(mdat));
+ return (is_swimmer(mdat)
+ || (!Is_waterlevel(&u.uz)
+ && (is_floater(mdat) || is_flyer(mdat)
+ || is_clinger(mdat))));
} else if (mdat->mlet == S_EEL && rn2(13) && !ignorewater) {
return FALSE;
} else if (is_lava(x, y)) {
- if (mtmp == &youmonst)
+ /* 3.6.3: floating eye can levitate over lava but it avoids
+ that due the effect of the heat causing it to dry out */
+ if (mdat == &mons[PM_FLOATING_EYE])
+ return FALSE;
+ else if (mtmp == &youmonst)
return (Levitation || Flying
|| (Fire_resistance && Wwalking && uarmf
&& uarmf->oerodeproof)