• images
  • 2:36 pm
  • images
  • No Comments.

Large Integer Issues

I had an issue with large integers recently.  I’ve since patched it to allow for a new maximum score well beyond the previous arbitrary limit of 1,000,000 (limited for reasons I couldn’t fathom).  The existing patches didn’t work me, so I devised something a little more creative, and the new maximum score will soon be: ((10^3,999,992) – 1). I could probably increase this a bit (to ((10^39,999,992)-1)). Notably, the current maximum score is 1,000,000 (though it recalculates), which only left the population bugging out on extended beta tester saves.

This new patch will roll into play for all large numbers (even numbers that really should never get that high), and will require some significant rewriting of display and storage functions to ensure that the data is not lost on save/load.

The code used in this patch has been tested, and only works for simple adding and subtracting (notably the overhead for multiplying anything past a googol would be fairly substantial and I’m not looking to set systems on fire!).

Edit: Okay, it turns out that I could push it to ((10^59999988)-1) if I’m prepared to make changes.  That should be enough of a hint to those who want to know what I’ve done 😉