Changing timer

eligameseligames Member, PRO Posts: 40

How would I change a timer from 1 to 2 when I press a button and when I press it again it goes up to 3 and so on...

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    Make an integer attribute called game.myTimer. Then add these rules to your timer actor:

    Timer every 1 second
         Change attribute game.myTimer to game.myTimer-1

    When touch is pressed
         Change attribute game.myTimer to game.myTimer+1

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

Sign In or Register to comment.