Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(+1)

Ooh, another bug report, I hope these are helpful!

Thanks to golden spoon, it's rather easy to double your gold past the maximum value assigned for it, and because you're using a signed type, that buffer overflows to a negative value.

It may be worth running a quick check on if gold*2 would be << 0, and if it would, either don't use the spoon, or set gold it to a tested maximum. (Probably worth using a similar check on any function that increases gold, in fact.)

All feedback is obviously very useful. This bug had already been reported to me. I'm thinking of adding a limit of double the gold spoon. For example: Double your gold (Max +2000 gold). I would still need to plan for overflow.

Thank you very much :)