game.restart_level = FALSE;
game.request_active = FALSE;
game.envelope_active = FALSE;
+ game.any_door_active = FALSE;
if (level.game_engine_type == GAME_ENGINE_TYPE_MM)
InitGameActions_MM();
}
// do not ask to play again if request dialog is already active
- if (game.request_active)
+ if (checkRequestActive())
return FALSE;
// do not ask to play again if request dialog already handled
return (checkGameSolved() || checkGameFailed());
}
+boolean checkRequestActive(void)
+{
+ return (game.request_active || game.envelope_active || game.any_door_active);
+}
+
// ----------------------------------------------------------------------------
// random generator functions
// values for special request dialog control
boolean request_active;
boolean envelope_active;
+ boolean any_door_active;
// values for special game control
int centered_player_nr;
boolean checkGameSolved(void);
boolean checkGameFailed(void);
boolean checkGameEnded(void);
+boolean checkRequestActive(void);
unsigned int InitEngineRandom_RND(int);
unsigned int RND(int);
SetDoorBackgroundImage(IMG_BACKGROUND_DOOR);
+ game.any_door_active = TRUE;
+
for (k = start; k < num_move_steps; k++)
{
int last_frame = num_move_steps - 1; // last frame of this "for" loop
BackToFront();
}
}
+
+ game.any_door_active = FALSE;
}
if (door_state & DOOR_ACTION_1)