added support for separate animations for 'old' (entered from main menu) and 'new...
authorHolger Schemel <info@artsoft.org>
Sat, 20 May 2017 18:46:02 +0000 (20:46 +0200)
committerHolger Schemel <info@artsoft.org>
Sat, 20 May 2017 18:46:02 +0000 (20:46 +0200)
src/anim.c
src/main.c
src/main.h
src/screens.c
src/tools.c

index 7464637dd3dc9443eae91b2bcdeeb833d8c2dd41..37c7193c21c8745069ed60ce585928f6de14da56 100644 (file)
 #define ANIM_CLASS_BIT_TITLE_INITIAL   0
 #define ANIM_CLASS_BIT_TITLE           1
 #define ANIM_CLASS_BIT_MAIN            2
-#define ANIM_CLASS_BIT_SUBMENU         3
-#define ANIM_CLASS_BIT_MENU            4
-#define ANIM_CLASS_BIT_TOONS           5
+#define ANIM_CLASS_BIT_SCORES          3
+#define ANIM_CLASS_BIT_SUBMENU         4
+#define ANIM_CLASS_BIT_MENU            5
+#define ANIM_CLASS_BIT_TOONS           6
 
-#define NUM_ANIM_CLASSES               6
+#define NUM_ANIM_CLASSES               7
 
 #define ANIM_CLASS_NONE                        0
 #define ANIM_CLASS_TITLE_INITIAL       (1 << ANIM_CLASS_BIT_TITLE_INITIAL)
 #define ANIM_CLASS_TITLE               (1 << ANIM_CLASS_BIT_TITLE)
 #define ANIM_CLASS_MAIN                        (1 << ANIM_CLASS_BIT_MAIN)
+#define ANIM_CLASS_SCORES              (1 << ANIM_CLASS_BIT_SCORES)
 #define ANIM_CLASS_SUBMENU             (1 << ANIM_CLASS_BIT_SUBMENU)
 #define ANIM_CLASS_MENU                        (1 << ANIM_CLASS_BIT_MENU)
 #define ANIM_CLASS_TOONS               (1 << ANIM_CLASS_BIT_TOONS)
 
+#define ANIM_CLASS_TOONS_SCORES                (ANIM_CLASS_TOONS |     \
+                                        ANIM_CLASS_SCORES)
+
 #define ANIM_CLASS_TOONS_MENU_MAIN     (ANIM_CLASS_TOONS |     \
                                         ANIM_CLASS_MENU  |     \
                                         ANIM_CLASS_MAIN)
@@ -165,7 +170,8 @@ struct GameModeAnimClass
   { GAME_MODE_SETUP,                   ANIM_CLASS_TOONS_MENU_SUBMENU   },
   { GAME_MODE_PSEUDO_MAINONLY,         ANIM_CLASS_TOONS_MENU_MAIN      },
   { GAME_MODE_PSEUDO_TYPENAME,         ANIM_CLASS_TOONS_MENU_MAIN      },
-  { GAME_MODE_SCORES,                  ANIM_CLASS_TOONS                },
+  { GAME_MODE_PSEUDO_SCORESOLD,                ANIM_CLASS_TOONS_SCORES         },
+  { GAME_MODE_PSEUDO_SCORESNEW,                ANIM_CLASS_TOONS_SCORES         },
 
   { -1,                                        -1                              }
 };
@@ -179,6 +185,7 @@ struct AnimClassGameMode
   { ANIM_CLASS_BIT_TITLE_INITIAL,      GAME_MODE_TITLE_INITIAL         },
   { ANIM_CLASS_BIT_TITLE,              GAME_MODE_TITLE                 },
   { ANIM_CLASS_BIT_MAIN,               GAME_MODE_MAIN                  },
+  { ANIM_CLASS_BIT_SCORES,             GAME_MODE_SCORES                },
   { ANIM_CLASS_BIT_SUBMENU,            GAME_MODE_PSEUDO_SUBMENU        },
   { ANIM_CLASS_BIT_MENU,               GAME_MODE_PSEUDO_MENU           },
   { ANIM_CLASS_BIT_TOONS,              GAME_MODE_PSEUDO_TOONS          },
index e24e0b73f9bb63fb277c50d183b06645495568ba..690296dded7266b0be70af083fe264a0f1588339 100644 (file)
@@ -5534,6 +5534,8 @@ struct SpecialSuffixInfo special_suffix_info[NUM_SPECIAL_GFX_ARGS + 1 + 1] =
   { ".SUBMENU",                        GFX_SPECIAL_ARG_SUBMENU,                },
   { ".MENU",                   GFX_SPECIAL_ARG_MENU,                   },
   { ".TOONS",                  GFX_SPECIAL_ARG_TOONS,                  },
+  { ".SCORESOLD",              GFX_SPECIAL_ARG_SCORESOLD,              },
+  { ".SCORESNEW",              GFX_SPECIAL_ARG_SCORESNEW,              },
   { ".FADING",                 GFX_SPECIAL_ARG_FADING,                 },
   { ".QUIT",                   GFX_SPECIAL_ARG_QUIT,                   },
 
index e55f4c191330beaf0fee4ab2068d41910972f8ff..e93b51267ffca14ce5ca706d50d71ec7578b49d0 100644 (file)
 #define GFX_SPECIAL_ARG_SUBMENU                29
 #define GFX_SPECIAL_ARG_MENU           30
 #define GFX_SPECIAL_ARG_TOONS          31
-#define GFX_SPECIAL_ARG_FADING         32
-#define GFX_SPECIAL_ARG_QUIT           33
+#define GFX_SPECIAL_ARG_SCORESOLD      32
+#define GFX_SPECIAL_ARG_SCORESNEW      33
+#define GFX_SPECIAL_ARG_FADING         34
+#define GFX_SPECIAL_ARG_QUIT           35
 
-#define NUM_SPECIAL_GFX_ARGS           34
+#define NUM_SPECIAL_GFX_ARGS           36
 
 /* these additional definitions are currently only used for draw offsets */
 #define GFX_SPECIAL_ARG_INFO_MAIN      0
 #define GAME_MODE_PSEUDO_SUBMENU       29
 #define GAME_MODE_PSEUDO_MENU          30
 #define GAME_MODE_PSEUDO_TOONS         31
-#define GAME_MODE_PSEUDO_FADING                32
-#define GAME_MODE_QUIT                 33
+#define GAME_MODE_PSEUDO_SCORESOLD     32
+#define GAME_MODE_PSEUDO_SCORESNEW     33
+#define GAME_MODE_PSEUDO_FADING                34
+#define GAME_MODE_QUIT                 35
 
-#define NUM_GAME_MODES                 34
+#define NUM_GAME_MODES                 36
 
 /* special definitions currently only used for custom artwork configuration */
 #define MUSIC_PREFIX_BACKGROUND                0
index 0f47d876b7471443eaee95800dc63ba9dbe1ed12..3703935f523ae5c40c126f2b6c60235574d4c6f6 100644 (file)
@@ -4198,6 +4198,8 @@ void DrawHallOfFame(int highlight_position)
 
   if (highlight_position < 0) 
     LoadScore(level_nr);
+  else
+    SetAnimStatus(GAME_MODE_PSEUDO_SCORESNEW);
 
   FadeSetEnterScreen();
 
index e0e7985cf34909697919055a7fa76fe93ad1643b..f907d5dd2bf39816a2bc8ef2a8bbb78eef83147f 100644 (file)
@@ -8547,6 +8547,8 @@ void SetAnimStatus(int anim_status_new)
 {
   if (anim_status_new == GAME_MODE_MAIN)
     anim_status_new = GAME_MODE_PSEUDO_MAINONLY;
+  else if (anim_status_new == GAME_MODE_SCORES)
+    anim_status_new = GAME_MODE_PSEUDO_SCORESOLD;
 
   global.anim_status_next = anim_status_new;