From: Holger Schemel Date: Wed, 29 Jan 2025 18:19:26 +0000 (+0100) Subject: added not saving extra colors to BDCFF when using classic BD color set X-Git-Tag: 4.4.0.4~16 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=a1835c897de8defe4d7cedffa17f384c13289d15;p=rocksndiamonds.git added not saving extra colors to BDCFF when using classic BD color set --- 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)