sequencing issue: dismounting from dying steed
Reported by entrez: if a trap killed hero's steed and dismounting
was fatal for the hero (probably by falling onto the same trap),
impossible "dmonsfree: 1 removed doesn't match 0 pending" warning
occurred during game-over cleanup.
Move the dismount calls in mondead() and mongone() from before their
m_detach() call to the end of m_detach() itself. This led to a
cascade of problems and attempted fixes until finally zeroing in on
place_monster()'s sanity checks and dismount_steed()'s attempts to
work-around one of them.
This reverts the convoluted hack from four years ago in commit
be327d9822 and deals with the issue in
a simpler way. After that, the new dismount_steed() placement at
end of m_detach() works cleanly.
This commit is contained in:
@@ -2897,7 +2897,8 @@ spoteffects(boolean pick)
|
||||
: (time_left < 10L) ? 1
|
||||
: 0]);
|
||||
}
|
||||
if ((mtmp = m_at(u.ux, u.uy)) && !u.uswallow) {
|
||||
|
||||
if ((mtmp = m_at(u.ux, u.uy)) != 0 && !u.uswallow) {
|
||||
mtmp->mundetected = mtmp->msleeping = 0;
|
||||
switch (mtmp->data->mlet) {
|
||||
case S_PIERCER:
|
||||
|
||||
Reference in New Issue
Block a user