How to add more time to a countdown timer?
Dell7730
Member, PRO Posts: 388
This is my basketball game and the rule is, if there's only 20 seconds left in the game and you made a successful shot, it's supposed to add 15 seconds more to the timer as a reward.
This is my countdown timer:
Text display abs(prec(game.My Timer,2))
Constrain Attribute game.My Timer to 180-(game.Time-game.Start Time)
Change Attribute game.Start Time to game.Time
so say for example
if game.My Timer is less than 20 seconds and game.Ball Score is True
then???? (how do I add 15 seconds more?)
I tried Change Attribute game.My Timer to game.My Timer+15 and it does not work, I thought it would since that's the same formula I used on all others like counting throws, hits and misses
Answers
Nevermind, found an alternative, not using the Timer anymore, instead, using an integer as timer and works flawlessly
@Dell7730
Hey can u please explain how u got it to work, I'm in the same scenario where timer counts down and if a bonus pickup is collected i want it to add 10 seconds.
Thank you
See this: http://forums.gamesalad.com/discussion/comment/580750/#Comment_580750
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User