Challenge 9
Problem:
A character fires a bullet and has to wait one second before being able to fire the next bullet.
Solution:
This one is easy because you you start off with problem 8 and then add a few things.
In the create event for the player set canshoot to true. Then In the Alarm 0 event set the variable canshoot to true or 1. Then In the Space bar event I set the variable canshoot to false and set the alarm0 to 30, and thats all you have to do to make the player have to wait one second to shoot.
Create Event
Set value of variable canshoot, value 1 or true.
Alarm 0
Set value of variable canshoot, value 1 or true.
Press Space
Set value of variable canshoot, value 0 or false
alarm0 to 30,
Help:
For this one I just needed to read the hint throughly.
1 Comment »
Leave a Reply
-
Recent
-
Links
-
Archives
- April 2006 (2)
- March 2006 (5)
- February 2006 (9)
-
Categories
-
RSS
Entries RSS
Comments RSS
it’s good, would be even better to show some code