Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- A blue and orange bone wave. this is the fist time i actually my own made a unitale/cyf wave. you can use it without credit! just i'd rather like credit. does not matter. i could never have made this if UTPlays did not have a tutorial for it!
- spawntimer = 0
- bullets = {}
- sprite2 = "cyan2"
- sprite3 = "orange2"
- sprite4 = "orange3"
- sprite5 = "orange4"
- sprite6 = "orange5"
- sprite7 = "orange6"
- function Update()
- -- this is how we make the wave work in action!
- spawntimer = spawntimer + 1
- if spawntimer%40 == 0 then
- local number = math.random(1,2)
- local posx = 80
- local.posy = 0
- if number == 1 then
- local bullet = Createprojectile(sprite2, posx, posy)
- bullet.SetVar('type', "cyan2")
- bullet.SetVar('xspeed', 1.3)
- bullet.SetVar('yspeed', 0)
- table.insert(bullets, bullet)
- elesif number == 2 then
- local bullet = Createprojectile(sprite3, posx, posy)
- bullet.SetVar('type', "orange2")
- bullet.SetVar('xspeed', 1)
- bullet.SetVar('yspeed', 0)
- table.insert(bullets, bullet)
- end
- end
- for i=1 #bullets do
- local bullet = bullets[1]
- local xdifference = Player.x - bullet.x
- local ydifference = Player.y - bullet.y
- local xpos = bullet.GetVar('xpos')
- local ypos = bullet.GetVar('ypos')
- local xspeed = bullet.GetVar('xspeed')
- local yspeed = bullet.GetVar('yspeed')
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement