X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fgame.c;h=6463df1b976f65ad72cec76db6253daf99917944;hb=a72578211d241dd0282ed9f803e85e027395f27a;hp=d517cdc06587c182cfb5f522b6beddb064dc4af1;hpb=64f0d273ab910b98d1c929bad3146aeccfd6468a;p=rocksndiamonds.git diff --git a/src/game.c b/src/game.c index d517cdc0..6463df1b 100644 --- a/src/game.c +++ b/src/game.c @@ -4503,7 +4503,7 @@ void GameWon(void) int i; // do not start end game actions before the player stops moving (to exit) - if (local_player->MovPos) + if (local_player->active && local_player->MovPos) return; game.LevelSolved_GameWon = TRUE; @@ -12164,7 +12164,8 @@ void GameActions_RND(void) DrawAllPlayers(); PlayAllPlayersSound(); - if (local_player->show_envelope != 0 && local_player->MovPos == 0) + if (local_player->show_envelope != 0 && (!local_player->active || + local_player->MovPos == 0)) { ShowEnvelope(local_player->show_envelope - EL_ENVELOPE_1); @@ -13451,6 +13452,9 @@ void RemovePlayer(struct PlayerInfo *player) player->present = FALSE; player->active = FALSE; + // required for some CE actions (even if the player is not active anymore) + player->MovPos = 0; + if (!ExplodeField[jx][jy]) StorePlayer[jx][jy] = 0;