Found an highscore overflow bug in Santa game.
Fri Jun 22, 2018 3:53am

Just for kicks I decided to see how Santa's Rescue held up after not looking at it for a while. All in all, I was still pretty happy with the results. Some graphical glitches but nothing too annoying.

One thing I noticed is that if you get a score of over 32k, you hit the integer overflow and your high score goes negative. I had a good run and it didn't happen until the end of level 24 so it's very possible to finish the game without hitting it.

The only bummer is that if you get a negative score, you don't make it to the high score table as the minimum score is like 500 pts or something.

I'll have to release an update changing the datatype to a larger type to fix it. Not a big bug but sort of bummed me out when I made it to level 25 (last level) and my score went negative.

integer overflow on high score

    • Old games used to max outPuckdropper, Sun Jun 24 8:31am
      You'd hit 9999 and couldn't score any more points. That was probably for display reasons, seeing as there's like ~7000 more points they could score before the next power of 2. It's also why they also ... more
      • Yeah I remember on Atari 2600...Erik, Fri Jul 6 11:08am
        Space Invaders and Asteroids (among other games) the score would roll over from whatever the max "99999" score was back to zero like an odometer. That was my "okay, I guess I beat this" mark as there ... more
        • 299999 in a early PriusPuckdropper, Sun Jul 8 6:04pm
          It's like they didn't expect their drivers to go past 300,000 mi in their car! I had some issues with the display that showed this info in mine and came across this little nugget. At least mine won't ... more
          • Wow that's surprising!Erik, Fri Aug 17 11:21am
            I would have thought they would have picked a higher number than 299k to be the max if they were going that route. I feel like it's not unheard of for Toyota's to go over 300k. Although, I guess... more
  • Click here to receive daily updates
    "Don't quote me." - Erik