Expression to determine if value is a multiple of a certain number
RossmanBrothersGames
Member Posts: 659
Hi wondering if I can get some math/function help from someone. In my game you die a lot and I want to make a rule that will make the game pause on a tip screen every certain number of deaths.
For example. If I wanted every ten deaths for the screen to pop up is there an expression to determine if the current number of deaths is a multiple of ten? (20,30,40.... 110,120,130). Thanks in advance!
-Eric
Comments
Rule
When numerical expression mod(game.deaths,10) = 0
-- The screen pops up
thanks @socks I knew it would most likely be simple, you're always pretty knowledgable about functions.
www.rossmanbrosgames.com