stumble_onto_mimic while blind, #untrap vs mimic
Noticed while testing a forthcoming mimic patch: when blind, some actions (open, close, #untrap, applying a key [as of a month ago], possibly others) taken against a mimic posing as a door would yield "Wait! That's a monster!" but leave the map showing the door instead of replacing it with the unseen monster glyph. Similarly, using #untrap towards a known trap location covered by a concealed mimic could yield "It is in the way." or "It isn't trapped.", depending upon the type of trap present, and not reveal the mimic. Same thing happened when not blind, except the message would refer to "the <size> mimic" rather than "it". Now it will expose the mimic, regardless of the type of trap.
This commit is contained in:
@@ -394,6 +394,10 @@ blanking items in pools while blind shouldn't reveal new obj description
|
||||
avoid infinite loop in topten output when killed by long-named monster
|
||||
grid bug could move diagonally 1 step using travel command
|
||||
unpaid shop items stolen from hero by a monster remained on hero's shop bill
|
||||
some actions taken when blind would yield "Wait! That's a monster!" (for a
|
||||
mimic posing as a door) but not display the unseen monster glyph
|
||||
#untrap toward known trap location containing concealed mimic would yield
|
||||
"{The mimic|It} {is in the way|isn't trapped}." but not reveal mimic
|
||||
|
||||
|
||||
Platform- and/or Interface-Specific Fixes
|
||||
|
||||
@@ -3935,6 +3935,12 @@ boolean force;
|
||||
(x == u.ux && y == u.uy) ? " in it" : "");
|
||||
return 1;
|
||||
}
|
||||
if ((mtmp = m_at(x, y)) != 0 &&
|
||||
(mtmp->m_ap_type == M_AP_FURNITURE ||
|
||||
mtmp->m_ap_type == M_AP_OBJECT)) {
|
||||
stumble_onto_mimic(mtmp);
|
||||
return 1;
|
||||
}
|
||||
switch(ttmp->ttyp) {
|
||||
case BEAR_TRAP:
|
||||
case WEB:
|
||||
@@ -3953,7 +3959,7 @@ boolean force;
|
||||
You("are already on the edge of the pit.");
|
||||
return 0;
|
||||
}
|
||||
if (!(mtmp = m_at(x,y))) {
|
||||
if (!mtmp) {
|
||||
pline("Try filling the pit instead.");
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -2560,6 +2560,11 @@ struct monst *mtmp;
|
||||
if (what) pline(fmt, what);
|
||||
|
||||
wakeup(mtmp); /* clears mimicking */
|
||||
/* if hero is blind, wakeup() won't display the monster even though
|
||||
it's no longer concealed */
|
||||
if (!canspotmon(mtmp) &&
|
||||
!glyph_is_invisible(levl[mtmp->mx][mtmp->my].glyph))
|
||||
map_invisible(mtmp->mx, mtmp->my);
|
||||
}
|
||||
|
||||
STATIC_OVL void
|
||||
|
||||
Reference in New Issue
Block a user