Microsoft MakeCode

Maximum score

A quick question if I may ask. :grin:
Is there a maximum score that can be set? (

Don’t worry, I should really answer my own question by investigating the possibility.

I didn’t try reaching the maximum value, but I noticed that the ‘info.score’ only has room for 10 decimal places to the left.

If score = x
change score by -1

where x-1 = max score


I have another question relating to the score in ‘info’. Is there anyway to reset the highest score of a game ? Or does this happen automatically when you publish a new version?

1 Like

Just some observations and thoughts; I haven’t dug through the source code to verify. :slight_smile:

The game’s score appears to be stored as an integer and not a floating-point data type. It looks like it rolls over at around two billion, so I’m guessing it’s a signed 32-bit integer.

As far as high score, it should be stored in the browser’s data store along with the game. So, convincing MakeCode Arcade that you have a new game would cause the high score to reset. Clearing your browser’s data store, duplicating the game, or opening the game in your browser’s anonymous mode are a few ways that I can think of to open the game with an initialized state. Publishing a new copy of the game generates a new URL, so using that new URL should also convince MakeCode Arcade that you are playing a new game and give you a clean state.

1 Like

Thank you Alex for explaining that. It makes sense indeed, that a new web page would contain a new cache.