Guest User

wave

a guest
Aug 30th, 2020
214
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.53 KB | None | 0 0
  1. timer = 0
  2. Arena.Resize(250,130)
  3. bluebones = {}
  4. regularbones = {}
  5.  
  6. Encounter["wavetimer"] = 7.0
  7.  
  8. blue = require "Libraries/bluesoul"
  9. blue.Initialize()
  10.  
  11. function Update()
  12.  
  13. blue.Update()
  14.  
  15. timer = timer + 1
  16. if timer == 30 then
  17. local bluebone1 = CreateProjectile('attacks/bones/large', 125, -60)
  18. bluebone1.sprite.color = {0,255,255}
  19. table.insert(bluebones,bluebone1)
  20. end
  21. if timer == 60 then
  22. local regularbone1 = CreateProjectile('attacks/bones/normal', 125, -30)
  23. table.insert(regularbones,regularbone1)
  24. end
  25. if timer == 90 then
  26. local bluebone2 = CreateProjectile('attacks/bones/large', 125, -60)
  27. bluebone2.sprite.color = {0,255,255}
  28. table.insert(bluebones,bluebone2)
  29. end
  30. if timer == 120 then
  31. local regularbone2 = CreateProjectile('attacks/bones/normal', 125, -30)
  32. table.insert(regularbones,regularbone2)
  33. end
  34. if timer == 150 then
  35. local bluebone3 = CreateProjectile('attacks/bones/large', 125, -60)
  36. bluebone3.sprite.color = {0,255,255}
  37. table.insert(bluebones,bluebone3)
  38. end
  39. if timer == 180 then
  40. local regularbone3 = CreateProjectile('attacks/bones/normal', 125, -30)
  41. table.insert(regularbones,regularbone3)
  42. end
  43.  
  44. for i=1, #bluebones do
  45. local bluebone1 = bluebones[i]
  46. local bluebone2 = bluebones[i]
  47. local bluebone3 = bluebones[i]
  48. if bluebones[i].isactive then
  49. bluebones[i].Move(-3,0)
  50. if bluebones[i].x <= -125 then
  51. bluebones[i].Remove()
  52. end
  53. end
  54.  
  55. end
  56.  
  57.  
  58. end
  59.  
  60. function OnHit(bluebone1)
  61. if Player.isMoving then
  62. Player.Hurt(1,0.01)
  63. end
  64. end
Advertisement
Add Comment
Please, Sign In to add comment