added playing next level when leaving hall of fame via back link
authorHolger Schemel <info@artsoft.org>
Wed, 11 May 2022 12:00:25 +0000 (14:00 +0200)
committerHolger Schemel <info@artsoft.org>
Wed, 11 May 2022 12:00:25 +0000 (14:00 +0200)
src/libgame/system.h
src/screens.c

index 065d8836a86ecdc0d6d5af95cd95849d9b09fcef..30ef7d7986b735c5b8289d82ecbe4771c898307d 100644 (file)
 #define BACKLINK_TEXT_SETUP    ".. (setup menu)"
 #define BACKLINK_TEXT_PARENT   ".. (parent directory)"
 #define BACKLINK_TEXT_BACK     "back"
+#define BACKLINK_TEXT_NEXT     "next"
 
 #define TREE_INFOTEXT(t)       ((t) == TREE_TYPE_SCORE_ENTRY ?         \
                                 INFOTEXT_SCORE_ENTRY :                 \
index 53ac39a7e8911e8d3af97091f7819af2073ff1b4..58a9afae8ab2a8e3b0235f253b5690a2cf169263 100644 (file)
@@ -4362,7 +4362,11 @@ static void DrawChooseTree(TreeInfo **ti_ptr)
     {
       execSetupArtwork();
     }
-    else       // GAME_MODE_LEVELS
+    else if (game_status == GAME_MODE_SCORES && scores.continue_playing)
+    {
+      StartPlayingFromHallOfFame();
+    }
+    else
     {
       SetGameStatus(GAME_MODE_MAIN);
 
@@ -5307,6 +5311,9 @@ static void DrawHallOfFame_setScoreEntries(void)
   if (score_entry_current == NULL)
     score_entry_current = getFirstValidTreeInfoEntry(score_entries);
 
+  if (score_entries != NULL && scores.last_added >= 0)
+    setString(&score_entries->node_group->name, BACKLINK_TEXT_NEXT);
+
   // ("score_entries" and "score_entry_current" may be NULL here)
 }