Hello, I’m celexux!
I just need a bit of help. When I try to do the wait thing, it still constantly does it.
I’m making this space shooter game. I’m trying to make a fire rate for the player and a system where the enemy shoots every couple seconds. When I try to do it, it always comes out as a constant stream of lasers. Here is my event code/layout:
for the player: (ship1)
conditionals
When Space key pressed
If the timer “fireRate” is greater than 0.2 seconds
actions
Create object: bullet at position x: ship1.X() - 35; ship1.Y()
Create object: bullet at position x: ship1.X() + 35; ship1.Y()
Reset the timer “fireRate” of ship1
for the enemy: (enemy1)
conditionals
If the timer “enemyShooting” is greater than 2 seconds
actions
Create object: enemyBullet at position x: enemy1.X() - 30; enemy1.Y()
Create object: enemyBullet at position x: enemy1.X() + 30; enemy1.Y()
Reset the timer “enemyShooting” of enemy1
Thanks!