Add more time to timer once at 0
Champachan
Member Posts: 21
in Tech Support
Hello ppl,
I have a little countdown timer that counts down to 0 from a set amount put in by user.
Problem is I need to also be able to add more time once timer gets to 0.
Only way I can think to do it is make a rule if time less than 0 then reset game.
This works but you see the time go into negatives for a spit second before the reset.
Can anyone think of a solution that doesn't involve a rule set to less that 0?
Comments
A rule set to equal to 0 ?
if the rule is set to equals 0 you can't add more time to it.
Why not ?
You should just be able to say when the value = 0 then add X to the value ?
attached is an example. If I constrain the 0 to 0 I can not add to it either.
example.zip
I'm not really sure what 'constrain the 0 to 0' means, but you can use a rule to check whether your time value = 0, and if it does then add X to that value.
The constrain attribute is preventing you from adding any to it. You don't need the constrain. Take a look at this example, it's just one way to do what you are trying.
Thanks Slick, that works a treat.
So you added a rule on the startcount actor to stop it going under zero by saying if time is less than 0 make time 0
and added a rule on the addtime actor to turn the timer off and add 1
One thing I don't get is why GS stopped flicking into negatives for the split second while it goes from <0 to 0.