Poly into fire elemental, eat flammable items

This commit is contained in:
Pasi Kallinen
2023-01-20 18:56:01 +02:00
parent b998a368c7
commit b1fd7344e3
2 changed files with 9 additions and 1 deletions

View File

@@ -1088,6 +1088,7 @@ fix freeing a worn object when forced to drop it by falling down stairs
allow setting per-level "temperature": hot, cold, or temperate, currently
only affects some messages
digging is noisy
polymorphing into fire elemental allows you eat flammable items
Fixes to 3.7.0-x Problems that Were Exposed Via git Repository

View File

@@ -96,6 +96,10 @@ is_edible(register struct obj *obj)
/* above also prevents the Amulet from being eaten, so we must never
allow fake amulets to be eaten either [which is already the case] */
if (gy.youmonst.data == &mons[PM_FIRE_ELEMENTAL]
&& is_flammable(obj))
return TRUE;
if (metallivorous(gy.youmonst.data) && is_metallic(obj)
&& (gy.youmonst.data != &mons[PM_RUST_MONSTER] || is_rustprone(obj)))
return TRUE;
@@ -520,7 +524,10 @@ done_eating(boolean message)
pline1(gn.nomovemsg);
gn.nomovemsg = 0;
} else if (message)
You("finish eating %s.", food_xname(piece, TRUE));
You("finish %s %s.",
(gy.youmonst.data == &mons[PM_FIRE_ELEMENTAL])
? "consuming" : "eating",
food_xname(piece, TRUE));
if (piece->otyp == CORPSE || piece->globby)
cpostfx(piece->corpsenm);