]> granicus.if.org Git - nethack/commitdiff
steeds don't remember traps
authorcohrs <cohrs>
Thu, 13 Feb 2003 05:23:46 +0000 (05:23 +0000)
committercohrs <cohrs>
Thu, 13 Feb 2003 05:23:46 +0000 (05:23 +0000)
<Someone> reported to the list that steeds didn't remember traps
encountered while mounted.  When not mounted, a monster will remember
traps, even when they don't damage the monster.  To that end, added code to
set the steed's mtrapseen mask.

doc/fixes34.1
src/trap.c

index a56ecf6328a5e970e99da1b9544ecfa0b7a3ea03..16274706f491b7c6b1653a793554b121b73f67ee 100644 (file)
@@ -382,6 +382,7 @@ fix sequencing of Magicbane's hit messages
 avoid buffer overflow from long or too many -s params
 wake up first if trying to crawl out of water while asleep
 while waiting, don't try to change into were form when already in were form
+steed should remember traps encountered while mounted
 
 
 Platform- and/or Interface-Specific Fixes
index 55ea74d95743d44c290cdb630380dda839cc2ec9..330e603cdc3bcad85c39a1b0b539a8eafd8d4955 100644 (file)
@@ -552,6 +552,10 @@ unsigned trflags;
            }
        }
 
+#ifdef STEED
+       if (u.usteed) u.usteed->mtrapseen |= (1 << (ttype-1));
+#endif
+
        switch(ttype) {
            case ARROW_TRAP:
                seetrap(trap);