fix github issue 218 = hallu vs passive gaze

Fixes #218

Hallucinating hero has 75% to be unaffected by a gaze counterattack
that paralyzes.  Check for that before checking free action (100%
chance to be unaffected).  The only change is that player might get
different feedback when both forms of protection against the gaze.
This commit is contained in:
PatR
2019-09-06 14:39:25 -07:00
parent c53a72162c
commit 1a97dce727
2 changed files with 10 additions and 5 deletions

View File

@@ -1,4 +1,4 @@
$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.108 $ $NHDT-Date: 1567418344 2019/09/02 09:59:04 $
$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.110 $ $NHDT-Date: 1567805962 2019/09/06 21:39:22 $
This fixes36.3 file is here to capture information about updates in the 3.6.x
lineage following the release of 3.6.2 in May 2019. Please note, however,
@@ -137,6 +137,8 @@ when spellcasting monster aimed at wrong spot due to not being able to see
invisible hero, feedback could be erroneous if hero could see self
[messages used 'if (Invisible)' test where 'if (Invis)' was meant]
prevent impossible when guard tries to relocate a monster on a full level
hallucination provides partial protection from passive gaze counterattack
against hero's attack; check for that before checking for free action
Fixes to Post-3.6.2 Problems that Were Exposed Via git Repository

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 uhitm.c $NHDT-Date: 1562876956 2019/07/11 20:29:16 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.211 $ */
/* NetHack 3.6 uhitm.c $NHDT-Date: 1567805813 2019/09/06 21:36:53 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.212 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Robert Patrick Rankin, 2012. */
/* NetHack may be freely redistributed. See license for details. */
@@ -2854,13 +2854,16 @@ boolean wep_was_destroyed;
if (ureflects("%s gaze is reflected by your %s.",
s_suffix(Monnam(mon)))) {
;
} else if (Free_action) {
You("momentarily stiffen under %s gaze!",
s_suffix(mon_nam(mon)));
} else if (Hallucination && rn2(4)) {
/* [it's the hero who should be getting paralyzed
and isn't; this message describes the monster's
reaction rather than the hero's escape] */
pline("%s looks %s%s.", Monnam(mon),
!rn2(2) ? "" : "rather ",
!rn2(2) ? "numb" : "stupified");
} else if (Free_action) {
You("momentarily stiffen under %s gaze!",
s_suffix(mon_nam(mon)));
} else {
You("are frozen by %s gaze!", s_suffix(mon_nam(mon)));
nomul((ACURR(A_WIS) > 12 || rn2(4)) ? -tmp : -127);