diff options
author | Treeki <treeki@gmail.com> | 2013-05-12 22:52:46 +0200 |
---|---|---|
committer | Treeki <treeki@gmail.com> | 2013-05-12 22:52:46 +0200 |
commit | cb7cc05946dc0b43066f479e42afdcf03895655c (patch) | |
tree | 71f8c699e65fcc95276299c6332cdf471c5cd790 /src | |
parent | 77769c3df06f2dec746c6d163d18986fa9a15e3b (diff) | |
download | kamek-cb7cc05946dc0b43066f479e42afdcf03895655c.tar.gz kamek-cb7cc05946dc0b43066f479e42afdcf03895655c.zip |
fixed a couple of completion message bugs
Diffstat (limited to '')
-rw-r--r-- | src/koopatlas/pathmanager.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/koopatlas/pathmanager.cpp b/src/koopatlas/pathmanager.cpp index 4651b3e..b1108b8 100644 --- a/src/koopatlas/pathmanager.cpp +++ b/src/koopatlas/pathmanager.cpp @@ -316,6 +316,9 @@ dWMPathManager_c::~dWMPathManager_c() { } } + LastLevelPlayed[0] = enteredLevel->worldSlot; + LastLevelPlayed[1] = enteredLevel->levelSlot; + // Now, a fuckton of checks for the various possible things we can finish! dLevelInfo_c *li = &dLevelInfo_c::s_info; u32 theseConds = save->GetLevelCondition(enteredLevel->worldSlot, enteredLevel->levelSlot); @@ -385,14 +388,16 @@ dWMPathManager_c::~dWMPathManager_c() { } } - // So.. are we candidates for any of these? - LastLevelPlayed[0] = enteredLevel->worldSlot; - LastLevelPlayed[1] = enteredLevel->levelSlot; + // I'm using gotos. SUE ME. + // Anyhow, don't consider non-levels for this. + if (!(enteredLevel->flags & 2)) + goto cannotFinishAnything; + // So.. are we candidates for any of these? int everythingFlag = 0, gEverythingFlag = 0; if (coinCount == totalCoinCount) everythingFlag |= 1; - if (exitCount == globalExitCount) + if (exitCount == totalExitCount) everythingFlag |= 2; if (globalCoinCount == totalGlobalCoinCount) gEverythingFlag |= 1; @@ -444,6 +449,7 @@ dWMPathManager_c::~dWMPathManager_c() { CanFinishEverything = true; } +cannotFinishAnything: if (penguinSlideSound.Exists()) penguinSlideSound.Stop(5); } |