Advertisement
Yando

Untitled

Mar 1st, 2019
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.73 KB | None | 0 0
  1. # ______ _______ _______ _______ ___ ______ _______ _______ ______ ______
  2. #| _ | | || || _ || | | _ | | || _ || _ | | |
  3. #| | || | ___|| _ || |_| || | | | || | || |_| || | || | _ |
  4. #| |_||_ | |___ | |_| || || | | |_||_ | || || |_||_ | | | |
  5. #| __ || ___|| ___|| || | | __ | | _|| || __ || |_| |
  6. #| | | || |___ | | | _ || | | | | | | |_ | _ || | | || |
  7. #|___| |_||_______||___| |__| |__||___| |___| |_| |_______||__| |__||___| |_||______|
  8.  
  9. # Created by ShaneBolenback
  10.  
  11. options:
  12. server: YourServerHere #<-- color codes can be used as well
  13. prefix: [RepairCard] #<--- Use any prefix you would like, currently set to "RepairCard" in pink/purple
  14. version: 1.0 # Do not edit version
  15.  
  16. # --- DO NOT EDIT BELOW THIS LINE OR YOU RISK LOOSING SUPPORT --
  17.  
  18. on load:
  19. send "[&bRepairCard&r] - &2Loaded Successfully" to console
  20. if text from "https://pastebin.com/raw/eH2QR9wF" is not "{@version}":
  21. set {_version} to text from "https://pastebin.com/raw/eH2QR9wF"
  22. send "[&bRepairCard&r] - &2Running current version: {@version}" to console
  23. send "[&bRepairCard&r] - &cUpdate available, version: %{_version}%" to console
  24. if text from "https://pastebin.com/raw/eH2QR9wF" is "{@version}":
  25. send "[&bRepairCard&r] - &2Running current version: {@version}" to console
  26.  
  27. on join:
  28. wait 1 second
  29. if player has permission "repaircard.admin":
  30. if text from "https://pastebin.com/raw/eH2QR9wF" is not "{@version}": # -- EDIT THIS AS WELL
  31. set {_version} to text from "https://pastebin.com/raw/eH2QR9wF"
  32. send "[&bRepairCard&r] - &2Running current version: {@version}" to player
  33. send "[&bRepairCard&r] - &cUpdate available, version: %{_version}%" to player
  34.  
  35.  
  36. command /repaircard [<text>]:
  37. description: This is used to give repair cards to players
  38. permission: repaircard.admin
  39. permission message: {@prefix} - &cYou do not have permission for this command
  40. trigger:
  41. if arg 1 is not set:
  42. set {_repaircard} to 1 paper named "&2Repair&aCard"
  43. set 1st line of lore of {_repaircard} to "This is your RepairCard"
  44. set 2nd line of lore of {_repaircard} to "It is a ONE TIME USE card!"
  45. set 3rd line of lore of {_repaircard} to "RepairCards fix ONE item"
  46. set 4th line of lore of {_repaircard} to "of your choice! Use WISELY!"
  47. give 1 of {_repaircard} to player
  48. stop
  49. if arg 1 is set:
  50. if arg 1 is not "version":
  51. set {_repaircard} to 1 paper named "&2Repair&aCard"
  52. set 1st line of lore of {_repaircard} to "This is your RepairCard"
  53. set 2nd line of lore of {_repaircard} to "It is a ONE TIME USE card!"
  54. set 3rd line of lore of {_repaircard} to "RepairCards fix ONE item"
  55. set 4th line of lore of {_repaircard} to "of your choice! Use WISELY!"
  56. if arg-1 parsed as a player is online:
  57. give 1 of {_repaircard} to arg-1 parsed as a player
  58. send "[&bRepairCard&r] - You have given one card to &6%arg-1%" to player
  59. stop
  60. if arg-1 parsed as a offline player is not online:
  61. send "[&bRepairCard&r] - &6%arg-1%&c is not online, player must be online to recieve a card" to player
  62. if arg 1 is "version":
  63. if text from "https://pastebin.com/raw/eH2QR9wF" is not "{@version}":
  64. set {_version} to text from "https://pastebin.com/raw/eH2QR9wF"
  65. send "[&bRepairCard&r] - &2Running current version: {@version}" to player
  66. send "[&bRepairCard&r] - &cUpdate available, version: %{_version}%" to player
  67. if text from "https://pastebin.com/raw/eH2QR9wF" is "{@version}":
  68. send "[&bRepairCard&r] - &2Running current version: {@version}" to player
  69.  
  70. on right-click holding a paper:
  71. if "%lore of players's tool%" contains "This is your RepairCard":
  72. remove 1 of item from player's inventory
  73. send "&c~~~~~~~~{@server}~~~~~~~~~"
  74. send " {@prefix}"
  75. send "&aNow right click with the tool"
  76. send "&a that needs repairing!"
  77. send "&c~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
  78. wait 1 tick
  79. set {repaircard.%player%} to true
  80. stop
  81.  
  82. on right-click:
  83. if {repaircard.%player%} is true:
  84. cancel event
  85. repair player's tool
  86. set {repaircard.%player%} to false
  87. send "[&bRepairCard&r] - Your &6%player's tool%&r has been repaired" to player
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement