From: Holger Schemel Date: Wed, 22 Feb 2006 22:34:30 +0000 (+0100) Subject: rnd-20060222-1-src X-Git-Tag: 3.2.0^2~65 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=89ce36da9108b04faf263cd2624db2a2d9fc8f27;p=rocksndiamonds.git rnd-20060222-1-src * fixed little bug when trying to switch to player that does not exist * added player switching (visual and quick) to R'n'D and EM game engine * added setup option to select visual or quick in-game player switching --- diff --git a/ChangeLog b/ChangeLog index 2bf75b8e..80dee958 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2006-02-22 + * fixed little bug when trying to switch to player that does not exist + +2006-02-19 + * added player switching (visual and quick) to R'n'D and EM game engine + * added setup option to select visual or quick in-game player switching + 2006-02-16 * added use of "Home" and "End" keys to handle element list in editor diff --git a/src/conftime.h b/src/conftime.h index eaad6287..f9dde6fb 100644 --- a/src/conftime.h +++ b/src/conftime.h @@ -1 +1 @@ -#define COMPILE_DATE_STRING "[2006-02-19 21:10]" +#define COMPILE_DATE_STRING "[2006-02-22 23:30]" diff --git a/src/game.c b/src/game.c index 4bda5189..19fcafdd 100644 --- a/src/game.c +++ b/src/game.c @@ -8811,10 +8811,13 @@ void GameActions() if (ScreenMovPos == 0) /* screen currently aligned at tile position */ { + struct PlayerInfo *player = &stored_player[game.centered_to_player_next]; + + if (!player->active) + game.centered_to_player_next = game.centered_to_player; + if (game.centered_to_player != game.centered_to_player_next) { - struct PlayerInfo *player = &stored_player[game.centered_to_player_next]; - DrawRelocatePlayer(player, setup.quick_switch); game.centered_to_player = game.centered_to_player_next; diff --git a/src/tools.c b/src/tools.c index de8e9df3..712be239 100644 --- a/src/tools.c +++ b/src/tools.c @@ -5131,6 +5131,9 @@ int getGameFrameDelay_EM(int native_em_game_frame_delay) int getCenteredPlayer_EM() { + if (!native_em_level.ply[game.centered_to_player_next]->alive) + game.centered_to_player_next = game.centered_to_player; + if (game.centered_to_player != game.centered_to_player_next) game.centered_to_player = game.centered_to_player_next;