static void ResetGfxFrame(int x, int y)
{
+ // profiling showed that "autotest" spends 10~20% of its time in this function
+ if (DrawingDeactivatedField())
+ return;
+
int element = Feld[x][y];
int graphic = el_act_dir2img(element, GfxAction[x][y], GfxDir[x][y]);
void RedrawPlayfield_EM(boolean force_redraw)
{
+ // skip redrawing playfield in warp mode or when testing tapes with "autotest"
+ if (DrawingDeactivatedField())
+ return;
+
boolean draw_new_player_location = FALSE;
boolean quick_relocation = setup.quick_switch;
int max_center_distance_player_nr =
void RedrawPlayfield_SP(boolean force_redraw)
{
+ // skip redrawing playfield in warp mode or when testing tapes with "autotest"
+ if (DrawingDeactivatedField())
+ return;
+
if (force_redraw)
RestorePlayfield();
return FALSE;
}
+boolean DrawingDeactivatedField()
+{
+ if (program.headless)
+ return TRUE;
+
+ if (gfx.draw_deactivation_mask & REDRAW_FIELD)
+ return TRUE;
+
+ return FALSE;
+}
+
boolean DrawingDeactivated(int x, int y, int width, int height)
{
return CheckDrawingArea(x, y, width, height, gfx.draw_deactivation_mask);
void ClearRectangle(Bitmap *, int, int, int, int);
void ClearRectangleOnBackground(Bitmap *, int, int, int, int);
void BlitBitmapMasked(Bitmap *, Bitmap *, int, int, int, int, int, int);
+boolean DrawingDeactivatedField(void);
boolean DrawingDeactivated(int, int, int, int);
boolean DrawingOnBackground(int, int);
boolean DrawingAreaChanged();