Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --An empty wave to serve as a skeleton
- lborder = CreateProjectile('vborder', -Arena.width/2, 0)
- lborder.SetVar('real', true)
- rborder = CreateProjectile('vborder', Arena.width/2, 0)
- rborder.SetVar('real', true)
- tborder = CreateProjectile('hborder', 0, Arena.height/2)
- tborder.SetVar('real', true)
- bborder = CreateProjectile('hborder', 0, -Arena.height/2)
- bborder.SetVar('real', true)
- mask = CreateProjectile('orangeheart', 0, 0)
- unmoved = true
- num = math.random()
- xstart = math.sin(2*math.pi*num)
- ystart = math.cos(2*math.pi*num)
- lastx = 0
- lasty = 0
- function Update()
- if Player.isMoving then
- unmoved = false
- currentx = Player.x
- currenty = Player.y
- end
- if unmoved then
- Player.MoveTo(Player.x + xstart, Player.y + ystart, false)
- elseif not Player.isMoving then
- Player.MoveTo(Player.x + currentx - lastx, Player.y + currenty - lasty, false)
- currentx = Player.x
- currenty = Player.y
- end
- lastx = mask.x
- lasty = mask.y
- mask.MoveTo(Player.x, Player.y)
- end
- function OnHit(bullet)
- if bullet.GetVar('real') and currentx - lastx == 0 and currenty - lasty == 0 then
- Player.Hurt(1, 0.5)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment