From a1835c897de8defe4d7cedffa17f384c13289d15 Mon Sep 17 00:00:00 2001 From: Holger Schemel Date: Wed, 29 Jan 2025 19:19:26 +0100 Subject: [PATCH] added not saving extra colors to BDCFF when using classic BD color set --- src/game_bd/bd_bdcff.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/game_bd/bd_bdcff.c b/src/game_bd/bd_bdcff.c index 3fff7962..093afb4b 100644 --- a/src/game_bd/bd_bdcff.c +++ b/src/game_bd/bd_bdcff.c @@ -1397,6 +1397,13 @@ static void save_properties(GdPtrArray *out, void *str, void *str_def, if (prop_desc[i].flags & GD_DONT_SAVE) continue; + // when using classic set of colors, skip saving extra colors + if (gfx.has_reduced_color_template && + prop_desc[i].type == GD_TYPE_COLOR && + (prop_desc[i].offset == STRUCT_OFFSET(GdCave, color[6]) || + prop_desc[i].offset == STRUCT_OFFSET(GdCave, color[7]))) + continue; + // string data // write together with identifier, as one string per line. if (prop_desc[i].type == GD_TYPE_STRING) -- 2.34.1