diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/koopatlas/mapdata.cpp | 52 |
1 files changed, 21 insertions, 31 deletions
diff --git a/src/koopatlas/mapdata.cpp b/src/koopatlas/mapdata.cpp index d766bed..0c413cf 100644 --- a/src/koopatlas/mapdata.cpp +++ b/src/koopatlas/mapdata.cpp @@ -53,44 +53,34 @@ void dKPNode_s::setupNodeExtra() { const char *colour; - OSReport("Level %d-%d, isUnlocked: %d, exitComplete: %d", world, level, isUnlocked, exitComplete); + //OSReport("Level %d-%d, isUnlocked: %d, exitComplete: %d", world, level, isUnlocked, exitComplete); - // Is it unlocked? - if (!isUnlocked) - colour = "g3d/black.brres"; + // default: non-unlocked levels AND completed one-time levels + colour = "g3d/black.brres"; - // Is it a one time level? - else if ((level >= 30) && (level <= 37)) { - // Is it complete? - if (exitComplete) - colour = "g3d/yellow.brres"; - - // It's still available - else - colour = "g3d/green.brres"; - } + // one-time levels + if ((level >= 30) && (level <= 37) && !exitComplete) + colour = "g3d/red.brres"; - // Is it a shop? + // the shop else if (level == 99) colour = "g3d/shop.brres"; - // Is it complete? - else if ((exitComplete) || (secretComplete)) { - // Does it have two exits? - if ((this->hasSecret) && (exitComplete) && (secretComplete)) - colour = "g3d/blue.brres"; - - // Does it have one exit? - else if ((!this->hasSecret) && (exitComplete)) - colour = "g3d/blue.brres"; - - // Not all exits are complete - else - colour = "g3d/purple.brres"; + else if (isUnlocked) { + if (hasSecret) { + if (exitComplete && secretComplete) + colour = "g3d/blue.brres"; + else if (exitComplete || secretComplete) + colour = "g3d/red.brres"; + else + colour = "g3d/purple.brres"; + } else { + if (exitComplete) + colour = "g3d/blue.brres"; + else + colour = "g3d/red.brres"; + } } - // Not complete after all - else - colour = "g3d/red.brres"; // model time this->extra->mallocator.link(-1, GameHeaps[0], 0, 0x20); |