From: nethack.allison Date: Tue, 11 Apr 2006 02:00:38 +0000 (+0000) Subject: don't reveal surface when Blind and levitating X-Git-Tag: MOVE2GIT~1070 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=cc31b256342e38cb581df234779ceb23fa54fd98;p=nethack don't reveal surface when Blind and levitating wrote the following on April 10, 2006: > When blind and levitating, you can produce a message - "You try to feel what > is lying here on the ice. But you can't reach it!" - which reveals too much > about the terrain below you. --- diff --git a/doc/fixes34.4 b/doc/fixes34.4 index 47e0d6980..c6958f754 100644 --- a/doc/fixes34.4 +++ b/doc/fixes34.4 @@ -204,6 +204,7 @@ cancelled nurses shouldn't say "Relax, this won't hurt a bit" check for hero location in digactualhole() before clearing u.utrap clear any pits that the hero digs in the vault guard's temporary corridor shattering a monster's weapon didn't work as intended for stack of N>1 +don't reveal surface information that you can neither feel or see Platform- and/or Interface-Specific Fixes diff --git a/src/hack.c b/src/hack.c index 93f83ef5e..37097eb86 100644 --- a/src/hack.c +++ b/src/hack.c @@ -1,4 +1,4 @@ -/* SCCS Id: @(#)hack.c 3.5 2006/02/22 */ +/* SCCS Id: @(#)hack.c 3.5 2006/04/10 */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* NetHack may be freely redistributed. See license for details. */ @@ -1967,6 +1967,8 @@ dopickup() else if (u.usteed && P_SKILL(P_RIDING) < P_BASIC) rider_cant_reach(); #endif + else if (Blind && !can_reach_floor(TRUE)) + You("cannot reach anything here."); else You("cannot reach the %s.", surface(u.ux,u.uy)); return 0; diff --git a/src/invent.c b/src/invent.c index f613f93c5..bae65c6fd 100644 --- a/src/invent.c +++ b/src/invent.c @@ -1,4 +1,4 @@ -/* SCCS Id: @(#)invent.c 3.5 2006/02/15 */ +/* SCCS Id: @(#)invent.c 3.5 2006/04/10 */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /* NetHack may be freely redistributed. See license for details. */ @@ -2269,9 +2269,13 @@ boolean picked_some; /* don't say "altar" twice, dfeature has more info */ You("try to feel what is here."); } else { + const char *where = (Blind && !can_reach_floor(TRUE)) ? + "lying beneath you" : "lying here on the ", + *onwhat = (Blind && !can_reach_floor(TRUE)) ? + "" : surface(u.ux,u.uy); You("try to feel what is %s%s.", - drift ? "floating here" : "lying here on the ", - drift ? "" : surface(u.ux, u.uy)); + drift ? "floating here" : where, + drift ? "" : onwhat); } if (dfeature && !drift && !strcmp(dfeature, surface(u.ux,u.uy))) dfeature = 0; /* ice already identifed */