diff options
author | Filip Gawin <filip.gawin@zoho.com> | 2021-01-31 20:44:39 +0100 |
---|---|---|
committer | Filip Gawin <filip.gawin@zoho.com> | 2021-01-31 20:44:39 +0100 |
commit | 7a3b80a9b7f414967fe59f89ab0fe5416735babe (patch) | |
tree | a84fb5e1dbdb00959d6916594d43b9c82c9bef23 /src/control/Pickups.cpp | |
parent | fix realloc (diff) | |
download | re3-7a3b80a9b7f414967fe59f89ab0fe5416735babe.tar re3-7a3b80a9b7f414967fe59f89ab0fe5416735babe.tar.gz re3-7a3b80a9b7f414967fe59f89ab0fe5416735babe.tar.bz2 re3-7a3b80a9b7f414967fe59f89ab0fe5416735babe.tar.lz re3-7a3b80a9b7f414967fe59f89ab0fe5416735babe.tar.xz re3-7a3b80a9b7f414967fe59f89ab0fe5416735babe.tar.zst re3-7a3b80a9b7f414967fe59f89ab0fe5416735babe.zip |
Diffstat (limited to '')
-rw-r--r-- | src/control/Pickups.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/control/Pickups.cpp b/src/control/Pickups.cpp index 96a8a670..8318bc1a 100644 --- a/src/control/Pickups.cpp +++ b/src/control/Pickups.cpp @@ -814,6 +814,9 @@ void CPickups::RenderPickUpText() { wchar *strToPrint; +#ifdef FIX_BUGS + strToPrint = nil; +#endif for (int32 i = 0; i < NumMessages; i++) { if (aMessages[i].m_quantity <= 39) { switch (aMessages[i].m_quantity) // could use some enum maybe @@ -1285,7 +1288,11 @@ CPacManPickups::GeneratePMPickUpsForRace(int32 race) int i = 0; if (race == 0) pPos = aRacePoints1; // there's only one available - assert(pPos != nil); + + if(!pPos) { + debug("This shouldn't happen"); + return; + } while (!pPos->IsZero()) { while (aPMPickUps[i].m_eType != PACMAN_NONE) |