Page 1 of 1

A button problem

PostPosted: Wed May 02, 2012 5:32 am
by raminkhan
You know when you have a button then after so many clicks on it, it count's down for i.e. from 10 to 1 then during this countdown its disabled for clicking but after the countdown it re-enables it's self? so how can I make one?

Re: A button problem

PostPosted: Wed May 02, 2012 9:40 am
by savvy
Put an actor variable inside the button, then when the button is click the variable goes up, when it gets to the number of clicks you want,
use,
Disable event mouse downs to stop clicking
then use either,
a timer where after the time it sets the actor variable back to 0 and enables the events.
or use another actor variable which does a constant ++ on the draw actor event, then when it gets to a certain amount it enables events and resets the first actor variable to 0 and itself too.

savvy

PS: if you need code for this, i will supply it at your request, i'm tired XD

Re: A button problem

PostPosted: Wed May 02, 2012 9:29 pm
by Hblade
Savvy answered your question :)

Re: A button problem

PostPosted: Wed May 02, 2012 10:07 pm
by lcl
Hblade wrote:Savvy answered your question :)

Isn't that quite obvious? XD

Let me guess, you had answered to him but savvy made it first so you decided to remove your post :D

Re: A button problem

PostPosted: Thu May 03, 2012 2:57 am
by Hblade
no lol he pmed me.