Problem Nine

Problem: A character fires a bullet and has to wait one second before being able to fire the next bullet. 

Solution: 

Bullet: 
Create Event: start moving in directions 000000010 with speed set to 5

Object Shooting:
Create Event: set variable canshoot to 1
Alarm Event for alarm 0: set variable canshoot to 1
Key Press Event for <Space> Key: if canshoot is equal to 1, create instance of object object0 at relative position (0,0), set variable canshoot to 0, set Alarm 0 to 30

Advertisement

Leave a Comment

Filed under GameMaker

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s