From: nethack.rankin Date: Thu, 5 Jan 2006 03:50:08 +0000 (+0000) Subject: fix #H12 - unseen wand of striking becoming known X-Git-Tag: MOVE2GIT~1167 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=cfbc5194aedf27c78536b74d0cf9e1ea617831ef;p=nethack fix #H12 - unseen wand of striking becoming known From a bug report: while hero was blinded, monster zapped him with a not-yet-discovered wand of striking and the wand type became discovered. The report was slightly off; the described case is already handled correctly. However, if the zap happened to hit a door, the wand would incorrectly be made known even when not seen. --- diff --git a/doc/fixes34.4 b/doc/fixes34.4 index 16f13a600..91a52e92f 100644 --- a/doc/fixes34.4 +++ b/doc/fixes34.4 @@ -178,6 +178,7 @@ recognize "mindflayer" as an alternative spelling for "mind flayer" treat mattock as blunt object when forcing locks restore capability to force locks with wielded statue only count successful statue creations against the monster limit in sp_lev.c +unseen wand of striking zapped by unseen monster became known if it hit a door Platform- and/or Interface-Specific Fixes diff --git a/src/muse.c b/src/muse.c index 29677214a..774b68ec8 100644 --- a/src/muse.c +++ b/src/muse.c @@ -1,4 +1,4 @@ -/* SCCS Id: @(#)muse.c 3.5 2005/12/05 */ +/* SCCS Id: @(#)muse.c 3.5 2006/01/04 */ /* Copyright (C) 1990 by Ken Arromdee */ /* NetHack may be freely redistributed. See license for details. */ @@ -1237,7 +1237,7 @@ struct obj *obj; /* 2nd arg to fhitm/fhito */ case WAN_LOCKING: case WAN_STRIKING: if (doorlock(obj, bhitpos.x, bhitpos.y)) { - makeknown(obj->otyp); + if (zap_oseen) makeknown(obj->otyp); /* if a shop door gets broken, add it to the shk's fix list (no cost to player) */ if (levl[bhitpos.x][bhitpos.y].doormask ==