diff options
author | Colin Noga <Tempus@chronometry.ca> | 2012-09-21 20:43:21 -0500 |
---|---|---|
committer | Colin Noga <Tempus@chronometry.ca> | 2012-09-21 20:43:21 -0500 |
commit | d47a9ed57a826d60c37bfa8a4ae00ccaba0ed806 (patch) | |
tree | c3f6657118d71abcd1ce3b4584b3e0472841e53f /src/newer.cpp | |
parent | 8d0a306f0a526a76182c8d2b513d7a0441d6f466 (diff) | |
parent | 5654d5c0a056f9cfc99ac608d16aa0a601b997f5 (diff) | |
download | kamek-d47a9ed57a826d60c37bfa8a4ae00ccaba0ed806.tar.gz kamek-d47a9ed57a826d60c37bfa8a4ae00ccaba0ed806.zip |
Merge branch 'level-select' of ssh://treeki.rustedlogic.net:30000/Kamek into level-select
Diffstat (limited to 'src/newer.cpp')
-rw-r--r-- | src/newer.cpp | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/src/newer.cpp b/src/newer.cpp new file mode 100644 index 0000000..6d672e2 --- /dev/null +++ b/src/newer.cpp @@ -0,0 +1,77 @@ +#include <newer.h> + +NWRWorld NewerWorldForLevelID(int w, int l) { + switch (w) { + case 1: return YOSHI_ISLAND; + case 2: + if (((l>1) && (l<5)) || (l==15) || (l==33) || (l==34)) + return SOGGY_SEWERS; + else + return RUBBLE_RUINS; + case 3: return MUSHROOM_PEAKS; + case 4: return SAKURA_VILLAGE; + case 5: + if (l<7 || l==15 || l==33 || l==34) + return FREEZEFLAME_GLACIER; + else + return FREEZEFLAME_VOLCANO; + case 6: return PUMPKIN_BONEYARD; + case 7: + if (l<4) + return SKY_MOUNTAIN; + else + return STARRY_SKIES; + case 8: + if (l<6 || l==15 || l==25 || l==33 || l==34) + return KOOPA_PLANET; + else + return KOOPA_CORE; + case 9: return BONUS_LAND; + case 10: + if (l<6 || l==30 || l==41) + return GOLDWOOD_FOREST; + else if (l<11 || l==32) + return MINIMEGA_ISLAND; + else if (l<16 || l==33 || l==34 || l==31) + return CRYSTAL_CAVES; + else if (l<19) + return BOMBARD_CLIFFS; + else + return SKY_CITY; + } + + return UNKNOWN_WORLD; +} + + +const wchar_t *NewerWorldNames[] = { + L"Yoshi's Island", + L"Rubble Ruins", + L"Soggy Sewers", + L"Mushroom Peaks", + L"Sakura Village", + L"Freezeflame Glacier", + L"Freezeflame Volcano", + L"Pumpkin Boneyard", + L"Sky Mountain", + L"Starry Skies", + L"Koopa Planet", + L"Koopa Core", + L"Bonus Land", + L"Goldwood Forest", + L"Mini-Mega Island", + L"Crystal Caves", + L"Bombard Cliffs", + L"Sky City" +}; + +// This is an array so it can be accessed from fileselect.S +int NewerWorldCount[] = { + 18 +}; + +const wchar_t *NewerWorldName(NWRWorld world) { + if (world < 0 || world >= WORLD_COUNT) + return L"Unknown World"; + return NewerWorldNames[world]; +} |