From: Holger Schemel Date: Wed, 6 Jan 2021 23:05:23 +0000 (+0100) Subject: added level editor gadget to use time score for 1 or 10 seconds left X-Git-Tag: 4.2.2.1~13 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=cafb1c16c5595fb7caf15435d2e8eb34b4db037c;p=rocksndiamonds.git added level editor gadget to use time score for 1 or 10 seconds left --- diff --git a/src/editor.c b/src/editor.c index b6736132..fd32ac7a 100644 --- a/src/editor.c +++ b/src/editor.c @@ -559,6 +559,7 @@ enum // selectbox identifiers GADGET_ID_TIME_OR_STEPS, + GADGET_ID_TIME_SCORE_BASE, GADGET_ID_GAME_ENGINE_TYPE, GADGET_ID_LEVELSET_SAVE_MODE, GADGET_ID_WIND_DIRECTION, @@ -840,6 +841,7 @@ enum enum { ED_SELECTBOX_ID_TIME_OR_STEPS, + ED_SELECTBOX_ID_TIME_SCORE_BASE, ED_SELECTBOX_ID_GAME_ENGINE_TYPE, ED_SELECTBOX_ID_LEVELSET_SAVE_MODE, ED_SELECTBOX_ID_WIND_DIRECTION, @@ -1410,7 +1412,7 @@ static struct GADGET_ID_LEVEL_TIMESCORE_DOWN, GADGET_ID_LEVEL_TIMESCORE_UP, GADGET_ID_LEVEL_TIMESCORE_TEXT, GADGET_ID_NONE, &level.score[SC_TIME_BONUS], - "score for each second/step left:", NULL, NULL + "score for time or steps left:", NULL, NULL }, { ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(12), @@ -1733,6 +1735,14 @@ static struct ValueTextInfo options_time_or_steps[] = { -1, NULL } }; +static struct ValueTextInfo options_time_score_base[] = +{ + { 1, "per second/step" }, + { 10, "per 10 seconds/steps" }, + + { -1, NULL } +}; + static struct ValueTextInfo options_game_engine_type[] = { { GAME_ENGINE_TYPE_RND, "Rocks'n'Diamonds" }, @@ -2467,6 +2477,14 @@ static struct &level.use_step_counter, NULL, NULL, "(0 => no limit)", "time or step limit" }, + { + -1, ED_LEVEL_SETTINGS_YPOS(10), + GADGET_ID_TIME_SCORE_BASE, GADGET_ID_LEVEL_TIMESCORE_UP, + -1, + options_time_score_base, + &level.time_score_base, + NULL, NULL, NULL, "time score for 1 or 10 seconds/steps" + }, { ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(11), GADGET_ID_GAME_ENGINE_TYPE, GADGET_ID_NONE,