]> granicus.if.org Git - nethack/commitdiff
fix pull request #544 - fire vortex engulf
authorPatR <rankin@nethack.org>
Fri, 9 Jul 2021 13:51:10 +0000 (06:51 -0700)
committerPatR <rankin@nethack.org>
Fri, 9 Jul 2021 13:51:10 +0000 (06:51 -0700)
of hero carrying burning objects shouldn't cause those to be
extinguished.  Ditto when fire vortex or poly'd hero engulfs
monsters.

Fixes #544

doc/fixes37.0
src/mhitm.c
src/mhitu.c
src/uhitm.c

index 0ad957529b39a799c860c25aba70f7df218e3c25..0d4b3ece84435bc783b75a8011ae397e9aef6289 100644 (file)
@@ -1,4 +1,4 @@
-NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.585 $ $NHDT-Date: 1625796800 2021/07/09 02:13:20 $
+NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.586 $ $NHDT-Date: 1625838646 2021/07/09 13:50:46 $
 
 General Fixes and Modified Features
 -----------------------------------
@@ -559,6 +559,7 @@ change getloc fastmove keys in number_pad mode from hardcoded HJKL to the
 allow using rush/run prefix key in getloc to fastmove the cursor
 avoid "it" in messages "Wait!  There's an it hiding under <an object>!" (hero
        moving) and "It was hidden under <an object>!" (unseen monster moving)
+don't extinguish burning objects when engulfed by a fire vortex
 
 
 Fixes to 3.7.0-x Problems that Were Exposed Via git Repository
index 72ebb10c39f7dd6139de45be968777bdaf229e0d..cda45a8f6d89c1a7299165ea749ceb108cd04168 100644 (file)
@@ -1,4 +1,4 @@
-/* NetHack 3.7 mhitm.c $NHDT-Date: 1614910020 2021/03/05 02:07:00 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.192 $ */
+/* NetHack 3.7 mhitm.c $NHDT-Date: 1625838646 2021/07/09 13:50:46 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.198 $ */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /*-Copyright (c) Robert Patrick Rankin, 2011. */
 /* NetHack may be freely redistributed.  See license for details. */
@@ -744,8 +744,10 @@ gulpmm(register struct monst *magr, register struct monst *mdef,
         Sprintf(buf, "%s swallows", Monnam(magr));
         pline("%s %s.", buf, mon_nam(mdef));
     }
-    for (obj = mdef->minvent; obj; obj = obj->nobj)
-        (void) snuff_lit(obj);
+    if (!flaming(magr->data)) {
+        for (obj = mdef->minvent; obj; obj = obj->nobj)
+            (void) snuff_lit(obj);
+    }
 
     if (is_vampshifter(mdef)
         && newcham(mdef, &mons[mdef->cham], FALSE, FALSE)) {
index e12add0421ca00561ef8ba7d0e1e1a75dab38afb..1404db76cb782dd8abf63d36d6d70921a1df149d 100644 (file)
@@ -1,4 +1,4 @@
-/* NetHack 3.7 mhitu.c $NHDT-Date: 1625446012 2021/07/05 00:46:52 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.245 $ */
+/* NetHack 3.7 mhitu.c $NHDT-Date: 1625838648 2021/07/09 13:50:48 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.246 $ */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /*-Copyright (c) Robert Patrick Rankin, 2012. */
 /* NetHack may be freely redistributed.  See license for details. */
@@ -1181,8 +1181,10 @@ gulpmu(struct monst *mtmp, struct attack *mattk)
         /* u.uswldtim always set > 1 */
         u.uswldtim = (unsigned) ((tim_tmp < 2) ? 2 : tim_tmp);
         swallowed(1); /* update the map display, shows hero swallowed */
-        for (otmp2 = g.invent; otmp2; otmp2 = otmp2->nobj)
-            (void) snuff_lit(otmp2);
+        if (!flaming(mtmp->data)) {
+            for (otmp2 = g.invent; otmp2; otmp2 = otmp2->nobj)
+                (void) snuff_lit(otmp2);
+        }
     }
 
     if (mtmp != u.ustuck)
index b0f0f5fdf4aa2dbfd81ae58b07cbbcafada11d26..a0269477e77ef068bed65f182a674f3e91573489 100644 (file)
@@ -1,4 +1,4 @@
-/* NetHack 3.7 uhitm.c $NHDT-Date: 1625446013 2021/07/05 00:46:53 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.311 $ */
+/* NetHack 3.7 uhitm.c $NHDT-Date: 1625838649 2021/07/09 13:50:49 $  $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.312 $ */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /*-Copyright (c) Robert Patrick Rankin, 2012. */
 /* NetHack may be freely redistributed.  See license for details. */
@@ -4223,8 +4223,10 @@ gulpum(struct monst *mdef, struct attack *mattk)
         return MM_MISS;
 
     if (u.uhunger < 1500 && !u.uswallow) {
-        for (otmp = mdef->minvent; otmp; otmp = otmp->nobj)
-            (void) snuff_lit(otmp);
+        if (!flaming(g.youmonst.data)) {
+            for (otmp = mdef->minvent; otmp; otmp = otmp->nobj)
+                (void) snuff_lit(otmp);
+        }
 
         /* force vampire in bat, cloud, or wolf form to revert back to
            vampire form now instead of dealing with that when it dies */