diff --git a/doc/fixes37.0 b/doc/fixes37.0 index ed72685f59..6b1d49be6a 100644 --- a/doc/fixes37.0 +++ b/doc/fixes37.0 @@ -1,4 +1,4 @@ -NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.595 $ $NHDT-Date: 1626315675 2021/07/15 02:21:15 $ +NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.596 $ $NHDT-Date: 1626390626 2021/07/15 23:10:26 $ General Fixes and Modified Features ----------------------------------- @@ -1080,6 +1080,7 @@ menu for what-is command supports /^ and /" to view a list of nearby or whole spiders will occasionally spin webs when moving around drinking a burning potion of oil will cure being turned into slime new bigroom variant, a boulder maze +vomiting on an altar provokes the deities wrath Platform- and/or Interface-Specific New Features diff --git a/src/eat.c b/src/eat.c index 63bd7e3598..c132863c68 100644 --- a/src/eat.c +++ b/src/eat.c @@ -1,4 +1,4 @@ -/* NetHack 3.7 eat.c $NHDT-Date: 1620548002 2021/05/09 08:13:22 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.243 $ */ +/* NetHack 3.7 eat.c $NHDT-Date: 1626390626 2021/07/15 23:10:26 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.247 $ */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /*-Copyright (c) Robert Patrick Rankin, 2012. */ /* NetHack may be freely redistributed. See license for details. */ @@ -3361,6 +3361,8 @@ floorfood(const char *verb, void vomit(void) /* A good idea from David Neves */ { + boolean spewed = FALSE; + if (cantvomit(g.youmonst.data)) { /* doesn't cure food poisoning; message assumes that we aren't dealing with some esoteric body_part() */ @@ -3373,6 +3375,8 @@ vomit(void) /* A good idea from David Neves */ reaches 0, but only if u.uhs < FAINTING (and !cantvomit()) */ if (u.uhs >= FAINTING) Your("%s heaves convulsively!", body_part(STOMACH)); + else + spewed = TRUE; } /* nomul()/You_can_move_again used to be unconditional, which was @@ -3383,6 +3387,27 @@ vomit(void) /* A good idea from David Neves */ g.multi_reason = "vomiting"; g.nomovemsg = You_can_move_again; } + + if (spewed) { + struct attack + *mattk = attacktype_fordmg(g.youmonst.data, AT_BREA, AD_ACID); + + /* currently, only yellow dragons can breathe acid */ + if (mattk) { + You("breathe acid on yourself..."); /* [why?] */ + ubreatheu(mattk); + } + /* vomiting on an altar is, all things considered, rather impolite */ + if (IS_ALTAR(levl[u.ux][u.uy].typ)) + altar_wrath(u.ux, u.uy); + /* if poly'd into acidic form, stomach acid is stronger than normal */ + if (acidic(g.youmonst.data)) { + /* TODO: if there's a web here, destroy that too (before ice) */ + if (is_ice(u.ux, u.uy)) + melt_ice(u.ux, u.uy, + "Your stomach acid melts straight through the ice!"); + } + } } int diff --git a/src/zap.c b/src/zap.c index 406bedfd07..9771627ad2 100644 --- a/src/zap.c +++ b/src/zap.c @@ -1,4 +1,4 @@ -/* NetHack 3.7 zap.c $NHDT-Date: 1620413928 2021/05/07 18:58:48 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.360 $ */ +/* NetHack 3.7 zap.c $NHDT-Date: 1626390628 2021/07/15 23:10:28 $ $NHDT-Branch: NetHack-3.7 $:$NHDT-Revision: 1.369 $ */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /*-Copyright (c) Robert Patrick Rankin, 2013. */ /* NetHack may be freely redistributed. See license for details. */ @@ -4457,7 +4457,7 @@ melt_ice(xchar x, xchar y, const char *msg) if (Underwater) vision_recalc(1); newsym(x, y); - if (cansee(x, y)) + if (cansee(x, y) || (x == u.ux && y == u.uy)) Norep("%s", msg); if ((otmp = sobj_at(BOULDER, x, y)) != 0) { if (cansee(x, y))