From 24c2d465a345e682c1f93a95616f6729ab876fdd Mon Sep 17 00:00:00 2001 From: "nethack.rankin" Date: Fri, 9 Aug 2002 02:35:30 +0000 Subject: [PATCH] blindness vs vault guards I implemented this before seeing 's forwarded report. It makes guards come to vaults when you can't see them, but does have one odd side-effect: if the vault has boulders in the way then you might not be able to follow the guard out. (Usually you can alternately search and step in order to successfully follow him out when unable to see.) --- doc/fixes34.1 | 1 + src/vault.c | 16 +++++++--------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/doc/fixes34.1 b/doc/fixes34.1 index d316a1b78..0aec85a9d 100644 --- a/doc/fixes34.1 +++ b/doc/fixes34.1 @@ -192,6 +192,7 @@ grammar tid: "The looking glass miss the ." fix wishing for "looking glass" and " glass" Archeologists suffer same alignment penalty for statue destruction by stone_to_flesh as they do by other means of statue destruction +being unable to see a vault guard doesn't prevent him from arriving Platform- and/or Interface-Specific Fixes diff --git a/src/vault.c b/src/vault.c index 63fe7027c..89da12273 100644 --- a/src/vault.c +++ b/src/vault.c @@ -1,4 +1,4 @@ -/* SCCS Id: @(#)vault.c 3.4 2002/04/18 */ +/* SCCS Id: @(#)vault.c 3.4 2002/08/06 */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* NetHack may be freely redistributed. See license for details. */ @@ -234,14 +234,12 @@ fnd: EGD(guard)->vroom = vaultroom; EGD(guard)->warncnt = 0; - if(!cansee(guard->mx, guard->my)) { - mongone(guard); - return; - } - reset_faint(); /* if fainted - wake up */ - pline("Suddenly one of the Vault's %s enters!", - makeplural(g_monnam(guard))); + if (canspotmon(guard)) + pline("Suddenly one of the Vault's %s enters!", + makeplural(g_monnam(guard))); + else + pline("Someone else has entered the Vault."); newsym(guard->mx,guard->my); if ((youmonst.m_ap_type == M_AP_OBJECT && youmonst.mappearance == GOLD_PIECE) || u.uundetected) { @@ -736,7 +734,7 @@ cleanup: restfakecorr(grd); if(!semi_dead && (in_fcorridor(grd, u.ux, u.uy) || cansee(x, y))) { - if (!disappear_msg_seen) + if (!disappear_msg_seen && canspotmon(grd)) pline("Suddenly, the %s disappears.", g_monnam(grd)); return(1); } -- 2.49.0