Page 1 of 1
Game Help
Posted:
Mon Jun 09, 2008 11:38 pm
by paperboy321
I am making a game where you have a score and a timer countdown. You have to push the right arrow key as many times as you can before the timer goes to zero. I set the timer for 15 sec, I want the key down(the right key ) to be disabled when the timer reaches zero, but you can still push the right arrow key to get more points. Can you tell me how to disable the ability to push the right arrow key (get more points).
Re: Game Help
Posted:
Tue Jun 10, 2008 12:30 am
by stevenp
ok, put this in your key down event
replace the word gooey with your actor's name
if(gooey.textNumber >= 15)
{
EventDisable("Event Actor", EVENTKEYDOWN);
}
this means, if your score is more then or equal to 15, it disables the key
Re: Game Help
Posted:
Tue Jun 10, 2008 8:13 pm
by paperboy321
There is something wrong with that. Look at it and fix it then send it back
Thanks
Re: Game Help
Posted:
Tue Jun 10, 2008 8:21 pm
by stevenp
replace left and right actor with your actor names
if(left_actor.textNumber <= 0)
{
EventDisable("right_actor", EVENTKEYDOWN);
}
Re: Game Help
Posted:
Tue Jun 10, 2008 8:26 pm
by paperboy321
great is there a way to stop the timer at zero
Re: Game Help
Posted:
Tue Jun 10, 2008 8:32 pm
by paperboy321
Re: Game Help
Posted:
Tue Jun 10, 2008 8:57 pm
by stevenp
put this in the timer
if(left_actor.textNumber <= 0)
{
//destroy timer
}
this is assuming your timer decreases your counter by 1 every second
Re: Game Help
Posted:
Tue Jun 10, 2008 9:00 pm
by paperboy321
can you check out my other topics