Advertisement
Guest User

My Broken Code

a guest
May 15th, 2016
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. spawntimer = 0
  2. bullets = {}
  3.  
  4. function spawnbullet()
  5. spawntimer = spawntimer + 1
  6. if(spawntimer % 30 == 0) then
  7. local posx = 0
  8. local posy = 30 - math.random(60)
  9. local bullet = CreateProjectile('bullet', 0, 0)
  10. table.insert(bullets, bullet)
  11. end
  12.  
  13. for i=1, #bullets do
  14. local bullet = bullets[i]
  15. bullet.Move[0,-60]
  16. end
  17. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement