fix #K2617 - metallivores eating iron bars
Monsters with rust attacks (rust monster) and corrosion attacks (black pudding, gray ooze) can eat or otherwise destroy iron bars but xorns could only move through the iron bars spot without being able to eat the metal there. Change xorn to eat bars instead of phazing through them. Lets rock moles eat bars too. Hero polymorphed into a rust monster would eat bars if trying to move to their location but couldn't do so if already there (maybe was in xorn form and now in rust monster form). Xorns could pass through them but not eat them. Allow hero metallivores to eat bars at the current location via 'e', similar to eating food off the floor. Hero as rock mole behaves like rust monster.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.7 mondata.c $NHDT-Date: 1596498186 2020/08/03 23:43:06 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.83 $ */
|
||||
/* NetHack 3.7 mondata.c $NHDT-Date: 1603507386 2020/10/24 02:43:06 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.86 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/*-Copyright (c) Robert Patrick Rankin, 2011. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -334,7 +334,10 @@ struct permonst *mptr;
|
||||
{
|
||||
return (boolean) (passes_walls(mptr) || amorphous(mptr) || unsolid(mptr)
|
||||
|| is_whirly(mptr) || verysmall(mptr)
|
||||
|| dmgtype(mptr, AD_CORR) || dmgtype(mptr, AD_RUST)
|
||||
/* rust monsters and some puddings can destroy bars */
|
||||
|| dmgtype(mptr, AD_RUST) || dmgtype(mptr, AD_CORR)
|
||||
/* rock moles can eat bars */
|
||||
|| metallivorous(mptr)
|
||||
|| (slithy(mptr) && !bigmonst(mptr)));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user