Merge branch 'master' into NetHack-3.7
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.87 $ $NHDT-Date: 1562532730 2019/07/07 20:52:10 $
|
||||
$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.89 $ $NHDT-Date: 1562632673 2019/07/09 00:37:53 $
|
||||
|
||||
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,
|
||||
@@ -99,6 +99,9 @@ if an engulfer has any worn items, hero could pick them up from inside and
|
||||
worse (Juiblex will wear an amulet if created with one; a shapechanger
|
||||
might wear one and then turn into an engulfer)
|
||||
kicking an altar ignored god's wrath if hero injured himself during the kick
|
||||
detect unseen/secret door detection/^E failed to find monsters hiding under
|
||||
objects and failed to find monsters hiding at trap locations
|
||||
when farlook describes a monster at a visible spot as trapped, reveal the trap
|
||||
|
||||
|
||||
Fixes to Post-3.6.2 Problems that Were Exposed Via git Repository
|
||||
|
||||
56
src/detect.c
56
src/detect.c
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.6 detect.c $NHDT-Date: 1544437284 2018/12/10 10:21:24 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.91 $ */
|
||||
/* NetHack 3.6 detect.c $NHDT-Date: 1562630266 2019/07/08 23:57:46 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.96 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/*-Copyright (c) Robert Patrick Rankin, 2018. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -379,7 +379,7 @@ register struct obj *sobj;
|
||||
You("notice some gold between your %s.", makeplural(body_part(FOOT)));
|
||||
return 0;
|
||||
|
||||
outgoldmap:
|
||||
outgoldmap:
|
||||
cls();
|
||||
|
||||
(void) unconstrain_map();
|
||||
@@ -993,7 +993,7 @@ struct obj *sobj; /* null if crystal ball, *scroll if gold detection scroll */
|
||||
Your("%s itch.", makeplural(body_part(TOE)));
|
||||
return 0;
|
||||
|
||||
outtrapmap:
|
||||
outtrapmap:
|
||||
cls();
|
||||
|
||||
(void) unconstrain_map();
|
||||
@@ -1441,6 +1441,8 @@ struct rm *lev;
|
||||
lev->doormask = newmask;
|
||||
}
|
||||
|
||||
/* find something at one location; it should find all somethings there
|
||||
since it is used for magical detection rather than physical searching */
|
||||
STATIC_PTR void
|
||||
findone(zx, zy, num)
|
||||
int zx, zy;
|
||||
@@ -1449,6 +1451,13 @@ genericptr_t num;
|
||||
register struct trap *ttmp;
|
||||
register struct monst *mtmp;
|
||||
|
||||
/*
|
||||
* This used to use if/else-if/else-if/else/end-if but that only
|
||||
* found the first hidden thing at the location. Two hidden things
|
||||
* at the same spot is uncommon, but it's possible for an undetected
|
||||
* monster to be hiding at the location of an unseen trap.
|
||||
*/
|
||||
|
||||
if (levl[zx][zy].typ == SDOOR) {
|
||||
cvt_sdoor_to_door(&levl[zx][zy]); /* .typ = DOOR */
|
||||
magic_map_background(zx, zy, 0);
|
||||
@@ -1460,19 +1469,25 @@ genericptr_t num;
|
||||
magic_map_background(zx, zy, 0);
|
||||
newsym(zx, zy);
|
||||
(*(int *) num)++;
|
||||
} else if ((ttmp = t_at(zx, zy)) != 0) {
|
||||
if (!ttmp->tseen && ttmp->ttyp != STATUE_TRAP) {
|
||||
ttmp->tseen = 1;
|
||||
newsym(zx, zy);
|
||||
(*(int *) num)++;
|
||||
}
|
||||
} else if ((mtmp = m_at(zx, zy)) != 0) {
|
||||
}
|
||||
|
||||
if ((ttmp = t_at(zx, zy)) != 0 && !ttmp->tseen
|
||||
/* [shouldn't successful 'find' reveal and activate statue traps?] */
|
||||
&& ttmp->ttyp != STATUE_TRAP) {
|
||||
ttmp->tseen = 1;
|
||||
newsym(zx, zy);
|
||||
(*(int *) num)++;
|
||||
}
|
||||
|
||||
if ((mtmp = m_at(zx, zy)) != 0
|
||||
/* brings hidden monster out of hiding even if already sensed */
|
||||
&& (!canspotmon(mtmp) || mtmp->mundetected || M_AP_TYPE(mtmp))) {
|
||||
if (M_AP_TYPE(mtmp)) {
|
||||
seemimic(mtmp);
|
||||
(*(int *) num)++;
|
||||
}
|
||||
if (mtmp->mundetected
|
||||
&& (is_hider(mtmp->data) || mtmp->data->mlet == S_EEL)) {
|
||||
} else if (mtmp->mundetected && (is_hider(mtmp->data)
|
||||
|| hides_under(mtmp->data)
|
||||
|| mtmp->data->mlet == S_EEL)) {
|
||||
mtmp->mundetected = 0;
|
||||
newsym(zx, zy);
|
||||
(*(int *) num)++;
|
||||
@@ -1600,8 +1615,7 @@ struct trap *trap;
|
||||
|
||||
/* The "Hallucination ||" is to preserve 3.6.1 behaviour, but this
|
||||
behaviour might need a rework in the hallucination case
|
||||
(e.g. to not prompt if any trap glyph appears on the
|
||||
square). */
|
||||
(e.g. to not prompt if any trap glyph appears on the square). */
|
||||
if (Hallucination ||
|
||||
levl[trap->tx][trap->ty].glyph !=
|
||||
trap_to_glyph(trap, rn2_on_display_rng)) {
|
||||
@@ -1634,18 +1648,22 @@ boolean via_warning;
|
||||
if (M_AP_TYPE(mtmp)) {
|
||||
seemimic(mtmp);
|
||||
found_something = TRUE;
|
||||
} else if (!canspotmon(mtmp)) {
|
||||
if (mtmp->mundetected
|
||||
&& (is_hider(mtmp->data) || mtmp->data->mlet == S_EEL)) {
|
||||
} else {
|
||||
/* this used to only be executed if a !canspotmon() test passed
|
||||
but that failed to bring sensed monsters out of hiding */
|
||||
found_something = !canspotmon(mtmp);
|
||||
if (mtmp->mundetected && (is_hider(mtmp->data)
|
||||
|| hides_under(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;
|
||||
found_something = TRUE;
|
||||
}
|
||||
newsym(x, y);
|
||||
found_something = TRUE;
|
||||
}
|
||||
|
||||
if (found_something) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.6 pager.c $NHDT-Date: 1558045586 2019/05/16 22:26:26 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.153 $ */
|
||||
/* NetHack 3.6 pager.c $NHDT-Date: 1562632673 2019/07/09 00:37:53 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.154 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/*-Copyright (c) Robert Patrick Rankin, 2018. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -297,9 +297,11 @@ int x, y;
|
||||
int tt = t ? t->ttyp : NO_TRAP;
|
||||
|
||||
/* newsym lets you know of the trap, so mention it here */
|
||||
if (tt == BEAR_TRAP || is_pit(tt) || tt == WEB)
|
||||
if (tt == BEAR_TRAP || is_pit(tt) || tt == WEB) {
|
||||
Sprintf(eos(buf), ", trapped in %s",
|
||||
an(defsyms[trap_to_defsym(tt)].explanation));
|
||||
t->tseen = 1;
|
||||
}
|
||||
}
|
||||
|
||||
/* we know the hero sees a monster at this location, but if it's shown
|
||||
|
||||
Reference in New Issue
Block a user