diff options
| author | Xavier ASUS <xavi92psx@gmail.com> | 2018-11-29 01:07:06 +0100 |
|---|---|---|
| committer | Xavier ASUS <xavi92psx@gmail.com> | 2018-11-29 01:07:06 +0100 |
| commit | 9cbaf49e93758b50e82a4d7d42762de242e7f086 (patch) | |
| tree | ccef6f3880f390783ded88fe844a18cba0fba30c /Source/Menu.c | |
| parent | 0b60fe23cdbca9df95c8cc2bf978874c29334e69 (diff) | |
| download | airport-9cbaf49e93758b50e82a4d7d42762de242e7f086.tar.gz | |
Some important bugfixes.
Added BUILDING_ATC_LOC.
Added more levels.
Diffstat (limited to 'Source/Menu.c')
| -rw-r--r-- | Source/Menu.c | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/Source/Menu.c b/Source/Menu.c index 74802c4..f3651e2 100644 --- a/Source/Menu.c +++ b/Source/Menu.c @@ -32,13 +32,16 @@ typedef enum t_levelId LEVEL1 = 0, LEVEL2, LEVEL3, + LEVEL4, + LEVEL5, + MAX_LEVELS }LEVEL_ID; typedef struct t_lvlpltdata { LEVEL_ID levelID; - const char** fileNames[]; + const char* const* fileNames[]; }TYPE_LVL_PLT_DATA; typedef enum @@ -156,7 +159,9 @@ static const char* MainMenuLevelList[] = { [LEVEL1] = "DATA\\LEVELS\\LEVEL1.LVL", [LEVEL2] = "DATA\\LEVELS\\LEVEL2.LVL", - [LEVEL3] = "DATA\\LEVELS\\LEVEL3.LVL" + [LEVEL3] = "DATA\\LEVELS\\LEVEL3.LVL", + [LEVEL4] = "DATA\\LEVELS\\XAMI.LVL", + [LEVEL5] = "DATA\\LEVELS\\LEVEL18.LVL" }; static const char** MainMenuPltList[] = @@ -179,6 +184,18 @@ static const char** MainMenuPltList[] = { "DATA\\LEVELS\\LEVEL3.PLT", NULL + }, + + [LEVEL4] = (const char*[]) + { + "DATA\\LEVELS\\XAMI.PLT", + NULL + }, + + [LEVEL5] = (const char*[]) + { + "DATA\\LEVELS\\LEVEL18.PLT", + NULL } }; @@ -542,7 +559,7 @@ static void MainMenuRenderLevelList(void) for (i = LEVEL1; i < MAX_LEVELS; i++) { char baseName[32]; - const size_t maxLength = sizeof (baseName) / sizeof (baseName[0]); + const size_t maxLength = ARRAY_SIZE(baseName); // Update "baseName" with file name + extension. SystemGetFileBasename(MainMenuLevelList[i], baseName, maxLength); |
