From c2fb384a5d03fac741a2cc479c883e83dffcdff6 Mon Sep 17 00:00:00 2001 From: PatR Date: Thu, 14 Dec 2017 16:39:21 -0800 Subject: [PATCH] rehumanizing while Unchanging When hero poly'd into paper golem "burns completely" he is rehumanized even if he has the Unchanging attribute. A comment states that that is intentional, but there was no explanation given to the player. Report that "your amulet of unchanging failed" when rehumanization despite Unchanging happens. (Don't ask me how or why it fails; I don't know.) --- doc/fixes36.1 | 2 ++ src/polyself.c | 16 +++++++++++----- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/doc/fixes36.1 b/doc/fixes36.1 index a99a24fd0..f2c33c3c3 100644 --- a/doc/fixes36.1 +++ b/doc/fixes36.1 @@ -488,6 +488,8 @@ being "dead inside" (self-genocide while polymorphed) conferred partial invulnerability--normal monster behavior stopped attacking hero if a fiery monster, wand of fire, or fiery explosion burned up a paper golem, it could still leave blank scrolls +hero poly'd into paper or straw golem reverts to human if burned up even when + Unchanging without any explanation given Fixes to Post-3.6.0 Problems that Were Exposed Via git Repository diff --git a/src/polyself.c b/src/polyself.c index e66c522b6..d79f01f44 100644 --- a/src/polyself.c +++ b/src/polyself.c @@ -1,4 +1,4 @@ -/* NetHack 3.6 polyself.c $NHDT-Date: 1513130017 2017/12/13 01:53:37 $ $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.115 $ */ +/* NetHack 3.6 polyself.c $NHDT-Date: 1513298347 2017/12/15 00:39:07 $ $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.116 $ */ /* Copyright (C) 1987, 1988, 1989 by Ken Arromdee */ /* NetHack may be freely redistributed. See license for details. */ @@ -1010,10 +1010,16 @@ void rehumanize() { /* You can't revert back while unchanging */ - if (Unchanging && (u.mh < 1)) { - killer.format = NO_KILLER_PREFIX; - Strcpy(killer.name, "killed while stuck in creature form"); - done(DIED); + if (Unchanging) { + if (u.mh < 1) { + killer.format = NO_KILLER_PREFIX; + Strcpy(killer.name, "killed while stuck in creature form"); + done(DIED); + } else if (uamul && uamul->otyp == AMULET_OF_UNCHANGING) { + Your("%s %s!", simpleonames(uamul), otense(uamul, "fail")); + uamul->dknown = 1; + makeknown(AMULET_OF_UNCHANGING); + } } if (emits_light(youmonst.data))