From 98c783a5e4c5bc5bf520d48ac20898970291b3d5 Mon Sep 17 00:00:00 2001 From: Holger Schemel Date: Fri, 8 Mar 2024 21:20:20 +0100 Subject: [PATCH] fixed crash bug when running in headless mode --- src/game_bd/bd_graphics.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/game_bd/bd_graphics.c b/src/game_bd/bd_graphics.c index b122219a..bb3fb894 100644 --- a/src/game_bd/bd_graphics.c +++ b/src/game_bd/bd_graphics.c @@ -457,6 +457,9 @@ void gd_prepare_tile_bitmap(GdCave *cave, Bitmap *bitmap, int scale_down_factor) static Bitmap *gd_tile_bitmap_original = NULL; static int scale_down_factor_last = -1; + if (program.headless) + return; + // check if tile bitmap has changed (different artwork or tile size selected) if (bitmap != gd_tile_bitmap_original || scale_down_factor != scale_down_factor_last) { -- 2.34.1