projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
added setup option to show dynamite and keys in game panel for EM artwork
[rocksndiamonds.git]
/
src
/
tools.c
diff --git
a/src/tools.c
b/src/tools.c
index de19e464567463177202220a0734e57367be1607..2157ef740c812d23b87ba6cb453781c2eec7b877 100644
(file)
--- a/
src/tools.c
+++ b/
src/tools.c
@@
-462,6
+462,11
@@
void SetDrawtoField(int mode)
}
}
}
}
+int GetDrawtoField(void)
+{
+ return (drawto_field == fieldbuffer ? DRAW_TO_FIELDBUFFER : DRAW_TO_BACKBUFFER);
+}
+
static void RedrawPlayfield_RND(void)
{
if (game.envelope_active)
static void RedrawPlayfield_RND(void)
{
if (game.envelope_active)
@@
-4212,6
+4217,7
@@
static int RequestHandleEvents(unsigned int req_state)
{
boolean game_just_ended = (game_status == GAME_MODE_PLAYING &&
checkGameEnded());
{
boolean game_just_ended = (game_status == GAME_MODE_PLAYING &&
checkGameEnded());
+ int draw_buffer_last = GetDrawtoField();
int width = request.width;
int height = request.height;
int sx, sy;
int width = request.width;
int height = request.height;
int sx, sy;
@@
-4234,9
+4240,7
@@
static int RequestHandleEvents(unsigned int req_state)
{
if (game_just_ended)
{
{
if (game_just_ended)
{
- // the MM game engine does not use a special (scrollable) field buffer
- if (level.game_engine_type != GAME_ENGINE_TYPE_MM)
- SetDrawtoField(DRAW_TO_FIELDBUFFER);
+ SetDrawtoField(draw_buffer_last);
HandleGameActions();
HandleGameActions();
@@
-4521,6
+4525,8
@@
static int RequestHandleEvents(unsigned int req_state)
BackToFront();
}
BackToFront();
}
+ SetDrawtoField(draw_buffer_last);
+
game.request_active = FALSE;
return result;
game.request_active = FALSE;
return result;
@@
-9091,7
+9097,7
@@
boolean CheckSingleStepMode_EM(byte action[MAX_PLAYERS], int frame,
boolean any_player_dropping)
{
if (tape.single_step && tape.recording && !tape.pausing)
boolean any_player_dropping)
{
if (tape.single_step && tape.recording && !tape.pausing)
- if (frame == 7 && !any_player_dropping)
+ if (frame == 7 && !any_player_dropping
&& FrameCounter > 6
)
TapeTogglePause(TAPE_TOGGLE_AUTOMATIC);
CheckSaveEngineSnapshot_EM(action, frame, any_player_moving,
TapeTogglePause(TAPE_TOGGLE_AUTOMATIC);
CheckSaveEngineSnapshot_EM(action, frame, any_player_moving,