Advertisement
Guest User

Untitled

a guest
May 8th, 2024
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.14 KB | None | 0 0
  1. Arena.Resize(75, 75)
  2. Player.MoveTo(0,-27, false)
  3. Player.sprite.color = {15/255, 214/255, 28/255}
  4. Arena.Move(0, 50)
  5.  
  6. spawntimer = 0
  7. Player.SetControlOverride(true)
  8. shield = CreateProjectile("shield", 0, 0)
  9. ring = CreateProjectile("green_ring", 0, 0)
  10. shield.SetVar("safe", true)
  11. ring.SetVar("safe", true)
  12.  
  13. Up = CreateProjectile("spear", 0, -400)
  14.  
  15. function Update()
  16. spawntimer = spawntimer + 1
  17. shield.MoveTo(Player.x, Player.y)
  18. ring.MoveTo(Player.x, Player.y)
  19. if Input.Right > 0 then
  20. shield.sprite.rotation = 270
  21. end
  22. if Input.Left > 0 then
  23. shield.sprite.rotation = 90
  24. end
  25. if Input.Up> 0 then
  26. shield.sprite.rotation = 0
  27. end
  28. if Input.Down> 0 then
  29. shield.sprite.rotation = 180
  30. end
  31. Up.Move(0, 10)
  32. if Up.y == shield.y - 50 then
  33. Up.MoveTo(99999, 99999)
  34. end
  35. end
  36. function OnHit(bullet)
  37. if bullet.GetVar("safe") then
  38. Player.Hurt(0, 0)
  39. end
  40. if not bullet.GetVar("safe") and not bullet.GetVar('color') then
  41. Player.Hurt(1, 0)
  42. end
  43. if bullet.GetVar('blue') and Player.isMoving then
  44. Player.Hurt(1, 0)
  45. end
  46. if bullet.GetVar('blue') and not Player.isMoving then
  47. Player.Hurt(0, 0)
  48. end
  49. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement