From 6f49aa871760d12114a4fb64e31c536eca3063ca Mon Sep 17 00:00:00 2001 From: Steve Date: Wed, 4 Apr 2018 08:16:36 +0100 Subject: [PATCH] Display "Controls" text on controls options screen. --- src/defs.h | 1 + src/game/options.c | 9 ++++++++- src/system/strings.c | 1 + 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/defs.h b/src/defs.h index bd84abe..14c3121 100644 --- a/src/defs.h +++ b/src/defs.h @@ -377,6 +377,7 @@ enum ST_COMPLETE, ST_PRESS_FIRE, ST_OPTIONS, + ST_CONTROLS, ST_TROPHIES, ST_PAGE, ST_HIDDEN, diff --git a/src/game/options.c b/src/game/options.c index c1cc97c..2eb6f73 100644 --- a/src/game/options.c +++ b/src/game/options.c @@ -166,7 +166,14 @@ static void draw(void) h = (SCREEN_WIDTH / 800.0) * background->rect.h; - drawText(SCREEN_WIDTH / 2, 50, 40, TA_CENTER, colors.white, app.strings[ST_OPTIONS]); + if (section == SECTION_MAIN) + { + drawText(SCREEN_WIDTH / 2, 50, 40, TA_CENTER, colors.white, app.strings[ST_OPTIONS]); + } + else + { + drawText(SCREEN_WIDTH / 2, 50, 40, TA_CENTER, colors.white, app.strings[ST_CONTROLS]); + } blitRectScaled(atlasTexture->texture, 0, SCREEN_HEIGHT - h, SCREEN_WIDTH, h, &background->rect, 0); diff --git a/src/system/strings.c b/src/system/strings.c index 288f158..2043f62 100644 --- a/src/system/strings.c +++ b/src/system/strings.c @@ -29,6 +29,7 @@ void initStrings(void) app.strings[ST_PRESS_FIRE] = _("Press Fire to Continue"); app.strings[ST_OPTIONS] = _("Options"); + app.strings[ST_CONTROLS] = _("Controls"); app.strings[ST_TROPHIES] = _("Trophies"); app.strings[ST_PAGE] = _("Page %d / %d"); app.strings[ST_HIDDEN] = _("Hidden");