Advertisement
yuu16092

Untitled

Feb 8th, 2019
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.53 KB | None | 0 0
  1. command /getgrap:
  2. permission: skript:admin
  3. trigger:
  4. give player fishing rod with nbt "{display:{Name:""&6グラップラー""},ench:[{id:0s,lvl:0s}],HideFlags:5,Unbreakable:1b}"
  5. send "&7You got &6Grappling Hook&7!"
  6. on fishing:
  7. if name of player's tool is "&6グラップラー":
  8. if fishing state is IN_GROUND:
  9. push player direction from player to fishing hook at speed distance between player and fishing hook/3.5
  10. if difference between y-coordinate of player and y-coordinate of fishing hook <= 2:
  11. set {_speed} to distance between player and fishing hook/30
  12. if {_speed} < 0.5:
  13. if distance between player and fishing hook >= 2:
  14. set {_speed} to 0.5
  15. push player upwards at speed {_speed}
  16. if fishing state is CAUGHT_ENTITY:
  17. caught entity is a living entity
  18. push caught entity direction from caught entity to player at speed distance between player and fishing hook/4
  19. push caught entity upwards at speed 0.5
  20. if fishing state is FISHING:
  21. loop blocks in radius 10 around location 1 meter above location of player:
  22. if loop-block is target block:
  23. set {_targetblock} to loop-block
  24. if {_targetblock} is not set:
  25. push fishing hook in direction of player at speed 8
  26. else if name of player's offhand is "&6Grappling Hook":
  27. if fishing state is IN_GROUND:
  28. push player direction from player to fishing hook at speed distance between player and fishing hook/3.5
  29. if difference between y-coordinate of player and y-coordinate of fishing hook <= 2:
  30. set {_speed} to distance between player and fishing hook/30
  31. if {_speed} < 0.5:
  32. if distance between player and fishing hook >= 2:
  33. set {_speed} to 0.5
  34. push player upwards at speed {_speed}
  35. if fishing state is CAUGHT_ENTITY:
  36. caught entity is a living entity
  37. push caught entity direction from caught entity to player at speed distance between player and fishing hook/4
  38. push caught entity upwards at speed 0.5
  39. if fishing state is FISHING:
  40. loop blocks in radius 10 around location 1 meter above location of player:
  41. if loop-block is target block:
  42. set {_targetblock} to loop-block
  43. if {_targetblock} is not set:
  44. push fishing hook in direction of player at speed 8
  45. every tick:
  46. loop all players:
  47. if loop-player's tool is fishing rod:
  48. if name of loop-player's tool is "&6Grappling Hook":
  49. add "{FallDistance:0}" to nbt of loop-player
  50. if loop-player's offhand is fishing rod:
  51. if name of loop-player's offhand is "&6Grappling Hook":
  52. add "{FallDistance:0}" to nbt of loop-player
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement