Advertisement
Guest User

Untitled

a guest
Jan 28th, 2020
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.75 KB | None | 0 0
  1. options:
  2. prefix: &dMiningServer&c>>
  3.  
  4. command /setminescore [<text>]:
  5. permission: mine.sk
  6. trigger:
  7. tool of player is not block:
  8. message "{@prefix}&c設定するブロックを手に持ってください。"
  9. stop
  10. tool of player is air:
  11. message "{@prefix}&c設定するブロックを手に持ってください。"
  12. stop
  13. arg-1 is not set:
  14. message "{@prefix}&c数値を指定する必要があります。"
  15. stop
  16. set {_num} to arg-1 parsed as number
  17. {_num} is not number:
  18. message "{@prefix}&c有効な数値ではありません。"
  19. stop
  20. set {mp.point::%type of tool of player%} to {_num}
  21. message "{@prefix}&e%type of tool of player%&eの取得スコアを%{mp.point::%type of tool of player%}%に設定しました。"
  22.  
  23. command /setminemp [<text>]:
  24. permission: mine.sk
  25. trigger:
  26. tool of player is not block:
  27. message "{@prefix}&c設定するブロックを手に持ってください。"
  28. stop
  29. tool of player is air:
  30. message "{@prefix}&c設定するブロックを手に持ってください。"
  31. stop
  32. arg-1 is not set:
  33. message "{@prefix}&c数値を指定する必要があります。"
  34. stop
  35. set {_num} to arg-1 parsed as number
  36. {_num} is not number:
  37. message "{@prefix}&c有効な数値ではありません。"
  38. stop
  39. set {mp.score::%type of tool of player%} to {_num}
  40. message "{@prefix}&e%type of tool of player%&eの取得MPを%{mp.score::%type of tool of player%}%に設定しました。"
  41.  
  42. command /setminelv [<text>]:
  43. permission: mine.sk
  44. trigger:
  45. tool of player is not block:
  46. message "{@prefix}&c設定するブロックを手に持ってください。"
  47. stop
  48. tool of player is air:
  49. message "{@prefix}&c設定するブロックを手に持ってください。"
  50. stop
  51. arg-1 is not set:
  52. message "{@prefix}&c数値を指定する必要があります。"
  53. stop
  54. set {_num} to arg-1 parsed as number
  55. {_num} is not number:
  56. message "{@prefix}&c有効な数値ではありません。"
  57. stop
  58. set {mp.lv::%type of tool of player%} to {_num}
  59.  
  60. command /pickaxe:
  61. trigger:
  62. set {_item} to unbreakable iron pickaxe named "&f&l&o%player%の鶴橋" with lore "&c現在のレベル: &e1" , "&b効率: &e1" , "&b幸運: &e1"
  63. add "{HideFlags:61}" to nbt of {_item}
  64. give player {_item}
  65.  
  66. function pickaxemenu(p:player):
  67. set {_lores::*} to lore of tool of {_p}
  68. set {_1::*} to {_lores::1} split at " "
  69. set {_lv} to (uncolored {_1::2}) parsed as number
  70. set {_1::*} to {_lores::2} split at " "
  71. set {_eff} to (uncolored {_1::2}) parsed as number
  72. set {_1::*} to {_lores::3} split at " "
  73. set {_lucky} to (uncolored {_1::2}) parsed as number
  74. set {_effmp} to 3 * (20 + {_eff} ^ 2) + 28 * {_eff}
  75. set {_luckymp} to 3 * (20 + {_lucky} ^ 2) + 28 * {_lucky}
  76. set {_lvmp} to 3 * (20 + {_lv} ^ 2) + 28 * {_lv}
  77. add 1 to {_lucky}
  78. add 1 to {_eff}
  79. add 1 to {_lv}
  80. open chest with 3 rows named "&8強化メニュー" to {_p}
  81. set slot 4 of {_p}'s current inventory to {_p}'s tool
  82. set slot 10 of {_p}'s current inventory to enchanted book named "&a効率強化" with lore "&c必要MP: &b%{_effmp}%" , "" , "&f&l次のレベル: &e&l%{_eff}%"
  83. set slot 12 of {_p}'s current inventory to glistering melon slice named "&a幸運" with lore "&c必要MP: &b%{_luckymp}%" , "" , "&f&l次のレベル: &e&l%{_lucky}%"
  84. set slot 14 of {_p}'s current inventory to anvil named "&aピッケルのLv強化" with lore "&c必要MP: &b%{_lvmp}%" , "" , "&f&l次のレベル: &e&l%{_lv}%"
  85. set slot 16 of {_p}'s current inventory to barrier named "&c未実装"
  86.  
  87. on right click:
  88. tool of player is iron pickaxe
  89. player is sneaking
  90. pickaxemenu(player)
  91.  
  92. on inventory click:
  93. name of player's current inventory is "&8強化メニュー"
  94. cancel event
  95. set {_item} to slot 4 of player's current inventory
  96. set {_c::*} to lore of {_item}
  97. set {_lores::*} to {_c::1} split at " "
  98. set {_picklv} to (uncolored {_lores::2}) parsed as number
  99. set {_lores::*} to lore of item
  100. name of item is "&aピッケルのLv強化":
  101. set {_c::*} to {_lores::1} split at " "
  102. set {_mp} to (uncolored {_c::2}) parsed as number
  103. set {_c::*} to {_lores::3} split at " "
  104. set {_nextlv} to (uncolored {_c::2}) parsed as number
  105. {status::%uuid of player%::mp} <= {_mp}:
  106. close player's inventory
  107. message "{@prefix}&c&lMPが足りません!"
  108. stop
  109. remove {_mp} from {status::%uuid of player%::mp}
  110. message "&a&lピッケルのLvを強化しました。"
  111. set {_item} to slot 4 of player's current inventory
  112. remove {_item} from player
  113. set line 1 of lore of {_item} to "&c現在のレベル: &e%{_nextlv}%"
  114. give player {_item}
  115. close player's inventory
  116. wait 1 tick
  117. pickaxemenu(player)
  118. name of item is "&a効率強化":
  119. set {_c::*} to {_lores::1} split at " "
  120. set {_mp} to (uncolored {_c::2}) parsed as number
  121. set {_c::*} to {_lores::3} split at " "
  122. set {_nextlv} to (uncolored {_c::2}) parsed as number
  123. {_picklv} < {_nextlv}:
  124. close player's inventory
  125. message "{@prefix}&e&l%{_nextlv}%&c&lLv以上のピッケルが必要です!"
  126. stop
  127. {status::%uuid of player%::mp} <= {_mp}:
  128. close player's inventory
  129. message "{@prefix}&c&lMPが足りません!"
  130. stop
  131. remove {_mp} from {status::%uuid of player%::mp}
  132. message "&a&lピッケルの効率を強化しました。"
  133. set {_item} to slot 4 of player's current inventory
  134. remove {_item} from player
  135. enchant {_item} with "efficiency %{_nextlv}%" parsed as enchantment type
  136. set line 2 of lore of {_item} to "&b効率: &e%{_nextlv}%"
  137. give player {_item}
  138. close player's inventory
  139. wait 1 tick
  140. pickaxemenu(player)
  141. name of item is "&a幸運":
  142. set {_c::*} to {_lores::1} split at " "
  143. set {_mp} to (uncolored {_c::2}) parsed as number
  144. set {_c::*} to {_lores::3} split at " "
  145. set {_nextlv} to (uncolored {_c::2}) parsed as number
  146. {_picklv} < {_nextlv}:
  147. close player's inventory
  148. message "{@prefix}&e&l%{_nextlv}%&c&lLv以上のピッケルが必要です!"
  149. stop
  150. {status::%uuid of player%::mp} <= {_mp}:
  151. close player's inventory
  152. message "{@prefix}&c&lMPが足りません!"
  153. stop
  154. remove {_mp} from {status::%uuid of player%::mp}
  155. message "&a&l幸運を強化しました。"
  156. set {_item} to slot 4 of player's current inventory
  157. remove {_item} from player
  158. set line 3 of lore of {_item} to "&b幸運: &e%{_nextlv}%"
  159. give player {_item}
  160. close player's inventory
  161. wait 1 tick
  162. pickaxemenu(player)
  163.  
  164.  
  165.  
  166.  
  167. every 5 ticks:
  168. loop all players:
  169. send action bar "&6&lLevel: &e%{status::%uuid of loop-player%::lv}% &6&lNextLvExp: &e%{status::%uuid of loop-player%::nextexp}% &6&lEXP: &e%{status::%uuid of loop-player%::exp}% &6&lMP: &e%{status::%uuid of loop-player%::mp}% &6&lScore: &e%{status::%uuid of loop-player%::score}%" to loop-player
  170.  
  171. on join:
  172. {status::%uuid of player%::exp} is not set:
  173. set {status::%uuid of player%::exp} to 0
  174. {status::%uuid of player%::mp} is not set:
  175. set {status::%uuid of player%::mp} to 0
  176. {status::%uuid of player%::score} is not set:
  177. set {status::%uuid of player%::score} to 0
  178. {status::%uuid of player%::lv} is not set:
  179. set {status::%uuid of player%::lv} to 1
  180. {status::%uuid of player%::nextexp} is not set:
  181. set {status::%uuid of player%::nextexp} to 2 * (30 + {status::%uuid of player%::lv} ^ 2) + 28 * {status::%uuid of player%::lv}
  182.  
  183. on mine:
  184. {mp.score::%type of event-block%} is set
  185. {mp.lv::%type of event-block%} is set
  186. {mp.point::%type of event-block%} is set
  187. {mp.lv::%type of event-block%} > {status::%uuid of player%::lv}:
  188. message "{@prefix}&c%{mp.lv::%type of event-block%}%Lv以上のみ採掘可能です!"
  189. stop
  190. add {mp.score::%type of event-block%} to {status::%uuid of player%::mp}
  191. add {ranks::%{status::%player%::rank}%::mp} to {status::%uuid of player%::mp}
  192. add 1 to {status::%uuid of player%::exp}
  193. add {mp.point::%type of event-block%} to {status::%uuid of player%::score}
  194. {status::%uuid of player%::exp} >= {status::%uuid of player%::nextexp}
  195. set {_lv} to {status::%uuid of player%::lv} + 1
  196. message "&e&l&m "
  197. message ""
  198. message ""
  199. message "&f &lおめでとうございます!あなたのレベルが上がりました!"
  200. message "&f &a&l%{status::%uuid of player%::lv}%&f >> &a&l%{_lv}%"
  201. message ""
  202. message ""
  203. message "&e&l&m "
  204. add 1 to {status::%uuid of player%::lv}
  205. set {_nextlv} to 2 * (30 + {status::%uuid of player%::lv} ^ 2) + 28 * {status::%uuid of player%::lv}
  206. set {status::%uuid of player%::nextexp} to {_nextlv}
  207. set {status::%uuid of player%::exp} to 0
  208.  
  209.  
  210. command /createrank [<text>]:
  211. permission: mine.sk
  212. trigger:
  213. arg-1 is not set:
  214. message "{@prefix}&c作るランク入力する必要があります。"
  215. stop
  216. {ranks::%arg-1%} is set:
  217. message "{@prefix}&c既に存在するランクです。"
  218. stop
  219. message "{@prefix}&e%arg-1%&bランクを作成しました。"
  220. message "{@prefix}&e/editrank %arg-1% でランクの編集ができます。"
  221. set {ranks::%arg-1%} to true
  222.  
  223. command /editrank [<text>] [<text>] [<text>]:
  224. permission: mine.sk
  225. trigger:
  226. arg-1 is not set:
  227. message "{@prefix}&e/editrank <ランク> prefix <Prefix> &7- Prefixを設定します。"
  228. message "{@prefix}&e/editrank <ランク> fly <true or false> &7- flyが可能かどうかを設定します。"
  229. message "{@prefix}&e/editrank <ランク> mp <number> &7- 掘った時に加算されるポイントを設定します。"
  230. stop
  231. {ranks::%arg-1%} is not true:
  232. message "{@prefix}&c存在しないランクです。作成してください。"
  233. stop
  234. arg-2 is not "prefix" or "fly" or "mp":
  235. message "{@prefix}&e/editrank %arg-1% prefix <Prefix> &7- Prefixを設定します。"
  236. message "{@prefix}&e/editrank %arg-1% fly <true or false> &7- flyが可能かどうかを設定します。"
  237. message "{@prefix}&e/editrank %arg-1% mp <number> &7- 掘った時に加算されるポイントを設定します。"
  238. stop
  239. arg-2 is "prefix":
  240. arg-3 is not set:
  241. message "{@prefix}&cPrefixを入力する必要があります。"
  242. stop
  243. set {ranks::%arg-1%::prefix} to arg-3
  244. message "{@prefix}&e%arg-1%&bのPrefixを%arg-3%&bに設定しました。"
  245. arg-2 is "fly":
  246. set {_boolean} to arg-3 parsed as boolean
  247. {_boolean} is not true or false:
  248. message "{@prefix}&ctrueあるいはfalseを入力する必要があります。"
  249. stop
  250. set {ranks::%arg-1%::fly} to {_boolean}
  251. message "{@prefix}&e%arg-1%&bのflyを&e%arg-3%&bに設定しました。"
  252. arg-2 is "mp":
  253. set {_number} to arg-3 parsed as number
  254. {_number} is not number:
  255. message "{@prefix}&c数値を入力する必要があります。"
  256. stop
  257. set {ranks::%arg-1%::mp} to {_number}
  258. message "{@prefix}&e%arg-1%&bのMPを&e%arg-3%&bに設定しました。"
  259.  
  260. command /ranklist:
  261. trigger:
  262. loop {ranks::*}:
  263. set {_c} to ""
  264. loop {ranks::%loop-index%::*}:
  265. set {_c} to "%{_c}%&e%loop-index-2%: &b%loop-value-2% "
  266. message "&6&l%loop-index% &8[%{_c}%&8]"
  267.  
  268.  
  269.  
  270. command /setrank [<text>] [<text>]:
  271. permission: mine.sk
  272. trigger:
  273. arg-1 is not set:
  274. message "{@prefix}&cプレイヤーを指定してください。"
  275. stop
  276. set {_player} to arg-1 parsed as number
  277. {_player} is not online:
  278. message "{@prefix}&cプレイヤーが参加している必要があります。"
  279. stop
  280. arg-2 is not set:
  281. message "{@prefix}&cランクを指定する必要があります。"
  282. {ranks::%arg-2%} is not set:
  283. message "{@prefix}&c存在しないランクです。以下はランク一覧です。%nl%&6%{ranks::*}%"
  284. stop
  285. set {status::%player%::rank} to arg-2
  286. message "{@prefix}&bプレイヤーのランクを&e%arg-1%&bに変更しました。"
  287. message "{@prefix}&bあなたのランクを&e%arg-1%&bに変更しました。" to {_player}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement