fix #7501 - searching while blind
My "fix github issue #38 - indentation vs 'if {}'" patch, commit
d2ae45984e, broke finding unseen
monsters via searching. Most notable if blind, but applied to
invisible monsters too.
This commit is contained in:
@@ -194,6 +194,7 @@ simplify #wizidentify; don't rely on having bold menu entries
|
||||
ensure tmp_at() structures are initialized for all code paths when swallowed
|
||||
trapped-vs-levitation/flying change broke Sting releasing hero from web
|
||||
life-saving while poly'd and Unchanging wasn't restoring u.mh (HP as monster)
|
||||
change in searching stopped finding unseen monsters except hiders and eels
|
||||
tty: turn off an optimization that is the suspected cause of Windows reported
|
||||
partial status lines following level changes
|
||||
tty: ensure that current status fields are always copied to prior status
|
||||
|
||||
18
src/detect.c
18
src/detect.c
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.6 detect.c $NHDT-Date: 1539908137 2018/10/19 00:15:37 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.83 $ */
|
||||
/* NetHack 3.6 detect.c $NHDT-Date: 1541119051 2018/11/02 00:37:31 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.84 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/*-Copyright (c) Robert Patrick Rankin, 2018. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -1548,14 +1548,16 @@ boolean via_warning;
|
||||
if (mtmp->m_ap_type) {
|
||||
seemimic(mtmp);
|
||||
found_something = TRUE;
|
||||
} else if (mtmp->mundetected
|
||||
&& (is_hider(mtmp->data) || mtmp->data->mlet == S_EEL)) {
|
||||
if (via_warning) {
|
||||
Your("warning senses cause you to take a second %s.",
|
||||
Blind ? "to check nearby" : "look close by");
|
||||
display_nhwindow(WIN_MESSAGE, FALSE); /* flush messages */
|
||||
} else {
|
||||
if (mtmp->mundetected
|
||||
&& (is_hider(mtmp->data) || mtmp->data->mlet == S_EEL)) {
|
||||
if (via_warning) {
|
||||
Your("warning senses cause you to take a second %s.",
|
||||
Blind ? "to check nearby" : "look close by");
|
||||
display_nhwindow(WIN_MESSAGE, FALSE); /* flush messages */
|
||||
}
|
||||
mtmp->mundetected = 0;
|
||||
}
|
||||
mtmp->mundetected = 0;
|
||||
newsym(x, y);
|
||||
found_something = TRUE;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user