X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fgame.c;h=703cfa54c6a07d17cc1830cd5e4d867c385411fd;hb=2884cb273130660d64871bef2845525ef0bfc034;hp=4e4c901c990286248b043614b2716d243a3d822e;hpb=c0c5862d9ee59c70412b1c35e558101b109a8ec9;p=rocksndiamonds.git diff --git a/src/game.c b/src/game.c index 4e4c901c..703cfa54 100644 --- a/src/game.c +++ b/src/game.c @@ -9924,8 +9924,26 @@ void GameActions() network_player_action_received = FALSE; #endif + /* when playing tape, read previously recorded player input from tape data */ recorded_player_action = (tape.playing ? TapePlayAction() : NULL); +#if 1 + /* TapePlayAction() may return NULL when toggling to "pause before death" */ + if (tape.pausing) + return; +#endif + +#if 0 + if (tape.playing) + { + if (recorded_player_action == NULL) + printf("!!! THIS SHOULD NOT HAPPEN !!!\n"); + else + printf("::: %05d: TAPE PLAYING: %08x\n", + FrameCounter, recorded_player_action[0]); + } +#endif + if (tape.set_centered_player) { game.centered_player_nr_next = tape.centered_player_nr_next; @@ -9972,6 +9990,12 @@ void GameActions() if (tape.recording) TapeRecordAction(tape_action); +#if 0 + if (tape.recording) + printf("::: %05d: TAPE RECORDING: %08x\n", + FrameCounter, tape_action[0]); +#endif + if (level.game_engine_type == GAME_ENGINE_TYPE_EM) { GameActions_EM_Main();