7mm

Skript: Grandia

7mm
Mar 25th, 2019
264
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 17.02 KB | None | 0 0
  1. command /prsec <boolean>:
  2. trigger:
  3. if arg 1 is true:
  4. player is an op
  5. command "pex user %player% add playerrealms.security"
  6. if arg 1 is false:
  7. command "pex user %player% add -playerrealms.security"
  8.  
  9. on chat:
  10. cancel event
  11. if {prefix::%uuid of player%} is not set:
  12. set {prefix::%uuid of player%} to "&6旅立ち"
  13. if {suffix::%uuid of player%} is not set:
  14. set {suffix::%uuid of player%} to "&7@Player"
  15. broadcast "&8&l[%{prefix::%uuid of player%}%&8&l]&f%player%%{suffix::%uuid of player%}%&e: &r%message%"
  16.  
  17. command /freeze <player> <boolean>:
  18. permission: skript.freeze
  19. trigger:
  20. player is "Malb7mm" parsed as player
  21. set {freeze::%arg 1%} to arg 2
  22.  
  23. on any movement:
  24. {freeze::%player%} is true
  25. cancel event
  26.  
  27. command /suffix <offline player> <text>:
  28. permission: skript.suffix
  29. trigger:
  30. set {suffix::%uuid of arg 1%} to colored arg 2
  31.  
  32. command /setclass <text> <text>:
  33. permission: grandia.setclass
  34. aliases: /.sc
  35. trigger:
  36. set {_p} to arg 1
  37. if arg 1 is "@":
  38. set {_p} to player
  39. set {grandia::player::%{_p}%::class::classname} to arg 2
  40. set {grandia::player::%{_p}%::skillboard::boardname} to {grandia::sys.cl::%arg 2%::opt::board}
  41. set {_coord::*} to {grandia::sys.cl::%arg 2%::start} split by ","
  42. set {grandia::player::%{_p}%::skillboard::coord.x} to {_coord::1} parsed as integer
  43. set {grandia::player::%{_p}%::skillboard::coord.y} to {_coord::2} parsed as integer
  44. remove 1 from {grandia::player::%{_p}%::skillboard::coord.x}
  45. remove 1 from {grandia::player::%{_p}%::skillboard::coord.y}
  46.  
  47. command /skillboardsetting <text> <text> <text> <text>:
  48. permission: grandia.skillboardsetting
  49. aliases: /.sbs
  50. trigger:
  51. set {grandia::sys.sb::%arg 1%::layout::%arg 2%,%arg 3%} to arg 4
  52. if arg 4 is "1":
  53. set {grandia::sys.sb::%arg 1%::start} to "%arg 2%,%arg 3%"
  54.  
  55. command /skillboardreset <text>:
  56. permission: grandia.skillboardreset
  57. aliases: /.sbr
  58. trigger:
  59. set {_p} to arg 1
  60. if arg 1 is "@":
  61. set {_p} to player
  62. set {_coord::*} to {grandia::sys.cl::%{grandia::player::%{_p}%::skillboard::boardname}%::start} split by ","
  63. set {grandia::player::%{_p}%::skillboard::coord.x} to {_coord::1} parsed as integer
  64. set {grandia::player::%{_p}%::skillboard::coord.y} to {_coord::2} parsed as integer
  65. remove 1 from {grandia::player::%{_p}%::skillboard::coord.x}
  66. remove 1 from {grandia::player::%{_p}%::skillboard::coord.y}
  67. clear {grandia::player::%{_p}%::skillboard::status::*}
  68. clear {grandia::player::%{_p}%::attributes::*}
  69.  
  70. command /classsetting <text> <text> <text>:
  71. permission: grandia.classsetting
  72. aliases: /.cs
  73. trigger:
  74. set {grandia::sys.cl::%arg 1%::opt::%arg 2%} to arg 3
  75.  
  76. command /setstatus <text> <text> <integer>:
  77. permission: grandia.setstatus
  78. aliases: /.ss
  79. trigger:
  80. set {_p} to arg 1
  81. if arg 1 is "@":
  82. set {_p} to player
  83. set {grandia::player::%arg 1%::status::%arg 2%} to arg 3
  84.  
  85. command /skillboard:
  86. aliases: /sb
  87. trigger:
  88. if {grandia::player::%player%::skillboard::boardname} is not set:
  89. message "&cボードが未設定です"
  90. stop
  91. open chest with 6 rows named "&4&lSkill &1&lBoard &0&l- %{grandia::player::%player%::skillboard::boardname}%&0(%{grandia::player::%player%::skillboard::coord.x}%,%{grandia::player::%player%::skillboard::coord.y}%)" to player
  92. wait a tick
  93. set {_name} to {grandia::player::%player%::skillboard::boardname}
  94. set {_y} to 0
  95. loop 6 times:
  96. set {_x} to 0
  97. loop 9 times:
  98. set {_slot} to (5-{_y})*9+{_x}
  99. set {_fieldx} to {_x}+{grandia::player::%player%::skillboard::coord.x}
  100. set {_fieldy} to {_y}+{grandia::player::%player%::skillboard::coord.y}
  101. if {grandia::sys.sb::%{_name}%::layout::%{_fieldx}%,%{_fieldy}%} is "1":
  102. set {_icon} to sugar
  103. set {_lore::*} to "&e&lボード開始地点" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  104. set {_iconname} to "&7---"
  105. else if {grandia::sys.sb::%{_name}%::layout::%{_fieldx}%,%{_fieldy}%} is "2":
  106. if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} > 0:
  107. if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} is 1:
  108. set {_icon} to red dye
  109. set {_lore::*} to "&7カケラ設定済: &c&l赤" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  110. set {_iconname} to "&7---"
  111. else if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} is 2:
  112. set {_icon} to orange dye
  113. set {_lore::*} to "&7カケラ設定済: &6&l橙" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  114. set {_iconname} to "&7---"
  115. else if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} is 3:
  116. set {_icon} to yellow dye
  117. set {_lore::*} to "&7カケラ設定済: &e&l黄" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  118. set {_iconname} to "&7---"
  119. else if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} is 4:
  120. set {_icon} to lime dye
  121. set {_lore::*} to "&7カケラ設定済: &a&l緑" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  122. set {_iconname} to "&7---"
  123. else if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} is 5:
  124. set {_icon} to light blue dye
  125. set {_lore::*} to "&7カケラ設定済: &b&l青" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  126. set {_iconname} to "&7---"
  127. else if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} is 6:
  128. set {_icon} to cyan dye
  129. set {_lore::*} to "&7カケラ設定済: &9&l藍" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  130. set {_iconname} to "&7---"
  131. else if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy}%} is 7:
  132. set {_icon} to purple dye
  133. set {_lore::*} to "&7カケラ設定済: &d&l紫" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  134. set {_iconname} to "&7---"
  135. else:
  136. set {_fieldx_} to {_fieldx}-1
  137. set {_fieldy_} to {_fieldy}-1
  138. if {_fieldy} is 0:
  139. if {grandia::player::%player%::skillboard::status::%{_fieldx_}%,%{_fieldy}%} > 0:
  140. set {_icon} to magma cream
  141. set {_lore::*} to "&7&lカケラ設定可" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  142. set {_iconname} to "&e&lカケラ &aを設定する"
  143. else if {grandia::sys.sb::%{_name}%::layout::%{_fieldx_}%,%{_fieldy}%} is "1":
  144. set {_icon} to magma cream
  145. set {_lore::*} to "&7&lカケラ設定可" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  146. set {_iconname} to "&e&lカケラ &aを設定する"
  147. else:
  148. set {_icon} to snowball
  149. set {_lore::*} to "&7カケラ未設定" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  150. set {_iconname} to "&7---"
  151. else:
  152. if {grandia::player::%player%::skillboard::status::%{_fieldx}%,%{_fieldy_}%} > 0:
  153. set {_icon} to magma cream
  154. set {_lore::*} to "&7&lカケラ設定可" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  155. set {_iconname} to "&e&lカケラ &aを設定する"
  156. else if {grandia::sys.sb::%{_name}%::layout::%{_fieldx}%,%{_fieldy_}%} is "1":
  157. set {_icon} to magma cream
  158. set {_lore::*} to "&7&lカケラ設定可" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  159. set {_iconname} to "&e&lカケラ &aを設定する"
  160. else:
  161. set {_icon} to snowball
  162. set {_lore::*} to "&7カケラ未設定" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  163. set {_iconname} to "&7---"
  164. else if {grandia::sys.sb::%{_name}%::layout::%{_fieldx}%,%{_fieldy}%} is "3":
  165. set {_icon} to glowstone dust
  166. set {_lore::*} to "&e&lボード終了地点" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  167. set {_iconname} to "&7---"
  168. else:
  169. set {_icon} to light gray stained glass pane
  170. set {_lore::*} to "&8カケラ設定不可" and "&f座標: (%{_fieldx}%,%{_fieldy}%)"
  171. set {_iconname} to "&7---"
  172. if {_x} is 0:
  173. set slot {_slot} of player's current inventory to {_icon} named "&e&l左 &aにスクロールする" with lore {_lore::*}
  174. if {_y} is 5:
  175. set slot {_slot} of player's current inventory to {_icon} named "&e横 &aの移動量を &e上げる" with lore {_lore::*}
  176. if {_y} is 0:
  177. set slot {_slot} of player's current inventory to {_icon} named "&e横 &aの移動量を &e下げる" with lore {_lore::*}
  178. else if {_x} is 8:
  179. set slot {_slot} of player's current inventory to {_icon} named "&e&l右 &aにスクロールする" with lore {_lore::*}
  180. if {_y} is 5:
  181. set slot {_slot} of player's current inventory to {_icon} named "&e縦 &aの移動量を &e上げる" with lore {_lore::*}
  182. if {_y} is 0:
  183. set slot {_slot} of player's current inventory to {_icon} named "&e縦 &aの移動量を &e下げる" with lore {_lore::*}
  184. else if {_y} is 0:
  185. set slot {_slot} of player's current inventory to {_icon} named "&e&l下 &aにスクロールする" with lore {_lore::*}
  186. else if {_y} is 5:
  187. set slot {_slot} of player's current inventory to {_icon} named "&e&l上 &aにスクロールする" with lore {_lore::*}
  188. else:
  189. set slot {_slot} of player's current inventory to {_icon} named "%{_iconname}%" with lore {_lore::*}
  190. add 1 to {_x}
  191. add 1 to {_y}
  192.  
  193. on inventory click:
  194. if name of player's current inventory contains "&4&lSkill &1&lBoard":
  195. cancel event
  196. if {grandia::player::%player%::skillboard::move.x} is not set:
  197. set {grandia::player::%player%::skillboard::move.x} to 1
  198. if {grandia::player::%player%::skillboard::move.y} is not set:
  199. set {grandia::player::%player%::skillboard::move.y} to 1
  200. if name of clicked item contains "左 ":
  201. remove {grandia::player::%player%::skillboard::move.x} from {grandia::player::%player%::skillboard::coord.x}
  202. execute player command "/sb"
  203. if name of clicked item contains "右 ":
  204. add {grandia::player::%player%::skillboard::move.x} to {grandia::player::%player%::skillboard::coord.x}
  205. execute player command "/sb"
  206. if name of clicked item contains "下 ":
  207. remove {grandia::player::%player%::skillboard::move.y} from {grandia::player::%player%::skillboard::coord.y}
  208. execute player command "/sb"
  209. if name of clicked item contains "上 ":
  210. add {grandia::player::%player%::skillboard::move.y} to {grandia::player::%player%::skillboard::coord.y}
  211. execute player command "/sb"
  212. if name of clicked item contains "縦" and "上げる":
  213. if {grandia::player::%player%::skillboard::move.y} >= 10:
  214. message "&cこれ以上上がりません"
  215. else:
  216. add 1 to {grandia::player::%player%::skillboard::move.y}
  217. message "&a%{grandia::player::%player%::skillboard::move.y}%に設定しました"
  218. execute player command "/sb"
  219. if name of clicked item contains "縦" and "下げる":
  220. if {grandia::player::%player%::skillboard::move.y} <= 1:
  221. message "&cこれ以上下がりません"
  222. else:
  223. add -1 to {grandia::player::%player%::skillboard::move.y}
  224. message "&a%{grandia::player::%player%::skillboard::move.y}%に設定しました"
  225. execute player command "/sb"
  226. if name of clicked item contains "横" and "上げる":
  227. if {grandia::player::%player%::skillboard::move.x} >= 10:
  228. message "&cこれ以上上がりません"
  229. else:
  230. add 1 to {grandia::player::%player%::skillboard::move.x}
  231. message "&a%{grandia::player::%player%::skillboard::move.x}%に設定しました"
  232. execute player command "/sb"
  233. if name of clicked item contains "横" and "下げる":
  234. if {grandia::player::%player%::skillboard::move.x} <= 1:
  235. message "&cこれ以上下がりません"
  236. else:
  237. add -1 to {grandia::player::%player%::skillboard::move.x}
  238. message "&a%{grandia::player::%player%::skillboard::move.x}%に設定しました"
  239. execute player command "/sb"
  240. if name of clicked item contains "設定":
  241. if {grandia::player::%player%::status::ap} is not set:
  242. set {grandia::player::%player%::status::ap} to 0
  243. if {grandia::player::%player%::status::ap} <= 0:
  244. message "&cアトリビュートポイントが足りません"
  245. execute player command "/sb"
  246. stop
  247. set {grandia::temp::skillboard.clickedslot::%player%} to clicked slot
  248. open chest with 1 rows named "&4Select Attributes-Piece" to player
  249. wait a tick
  250. set slot 0 of player's current inventory to barrier named "&7キャンセル" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%"
  251. set slot 2 of player's current inventory to red dye named "&c&l赤 &cのカケラ&fを設定する" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%" and "&c割り振り済み: &l%{grandia::player::%player%::attributes::1}%"
  252. set slot 3 of player's current inventory to orange dye named "&6&l橙 &6のカケラ&fを設定する" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%" and "&6割り振り済み: &l%{grandia::player::%player%::attributes::2}%"
  253. set slot 4 of player's current inventory to yellow dye named "&e&l黄 &eのカケラ&fを設定する" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%" and "&e割り振り済み: &l%{grandia::player::%player%::attributes::3}%"
  254. set slot 5 of player's current inventory to lime dye named "&a&l緑 &aのカケラ&fを設定する" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%" and "&a割り振り済み: &l%{grandia::player::%player%::attributes::4}%"
  255. set slot 6 of player's current inventory to light blue dye named "&b&l青 &bのカケラ&fを設定する" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%" and "&b割り振り済み: &l%{grandia::player::%player%::attributes::5}%"
  256. set slot 7 of player's current inventory to cyan dye named "&9&l藍 &9のカケラ&fを設定する" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%" and "&9割り振り済み: &l%{grandia::player::%player%::attributes::6}%"
  257. set slot 8 of player's current inventory to purple dye named "&d&l紫 &dのカケラ&fを設定する" with lore "&3所持AP: &l%{grandia::player::%player%::status::ap}%" and "&d割り振り済み: &l%{grandia::player::%player%::attributes::7}%"
  258. else if name of player's current inventory contains "&4Select Attributes-Piece":
  259. cancel event
  260. set {_x} to mod({grandia::temp::skillboard.clickedslot::%player%},9)
  261. set {_y} to 5-floor({grandia::temp::skillboard.clickedslot::%player%}/9)
  262. add {grandia::player::%player%::skillboard::coord.x} to {_x}
  263. add {grandia::player::%player%::skillboard::coord.y} to {_y}
  264. if name of clicked item contains "キャンセル":
  265. execute player command "/sb"
  266. stop
  267. add -1 to {grandia::player::%player%::status::ap}
  268. if name of clicked item contains "赤":
  269. set {grandia::player::%player%::skillboard::status::%{_x}%,%{_y}%} to 1
  270. add 1 to {grandia::player::%player%::attributes::1}
  271. execute player command "/sb"
  272. if name of clicked item contains "橙":
  273. set {grandia::player::%player%::skillboard::status::%{_x}%,%{_y}%} to 2
  274. add 1 to {grandia::player::%player%::attributes::2}
  275. execute player command "/sb"
  276. if name of clicked item contains "黄":
  277. set {grandia::player::%player%::skillboard::status::%{_x}%,%{_y}%} to 3
  278. add 1 to {grandia::player::%player%::attributes::3}
  279. execute player command "/sb"
  280. if name of clicked item contains "緑":
  281. set {grandia::player::%player%::skillboard::status::%{_x}%,%{_y}%} to 4
  282. add 1 to {grandia::player::%player%::attributes::4}
  283. execute player command "/sb"
  284. if name of clicked item contains "青":
  285. set {grandia::player::%player%::skillboard::status::%{_x}%,%{_y}%} to 5
  286. add 1 to {grandia::player::%player%::attributes::5}
  287. execute player command "/sb"
  288. if name of clicked item contains "藍":
  289. set {grandia::player::%player%::skillboard::status::%{_x}%,%{_y}%} to 6
  290. add 1 to {grandia::player::%player%::attributes::6}
  291. execute player command "/sb"
  292. if name of clicked item contains "紫":
  293. set {grandia::player::%player%::skillboard::status::%{_x}%,%{_y}%} to 7
  294. add 1 to {grandia::player::%player%::attributes::7}
  295. execute player command "/sb"
  296.  
  297. command /skillexe <text> [<player>]:
  298. aliases: /.se
  299. permission: grandia.skillexe
  300. trigger:
  301. set {_p} to arg 2
  302. if arg 2 is not set:
  303. set {_p} to player
  304. if arg 1 is "aquaball":
  305. set {_loc} to {_p}'s location
  306. set {_cnt} to 100
  307. while {_cnt}>0:
  308. set {_loctext} to "%{_loc}'s x-coord% %{_loc}'s y-coord% %{_loc}'s z-coord%"
  309. command "execute @p %{_loctext}% particle splash ~ ~ ~ 0.25 0.25 0.25 10 100"
  310. add -1 to {_cnt}
  311. wait a tick
  312.  
  313. on join:
  314. command "gamemode 2 %player%"
  315. if {serverjoin::%uuid of player%} is not set:
  316. command "execute @a ~ ~ ~ playsound entity.player.levelup master @s ~ ~ ~ 1 0.5"
  317. set join message to "&2&lEntrance&f: &dFirstJoin: %player%"
  318. add 1 to {serverjoin::%uuid of player%}
  319. stop
  320. add 1 to {serverjoin::%uuid of player%}
  321. command "execute @a ~ ~ ~ playsound entity.player.levelup master @s"
  322. set join message to "&2&lEntrance&f: &eJoin: %player%"
  323. if mod({lbwar.player.join::%uuid of player%},50) is 0:
  324. broadcast "&6&l%{lbwar.player.join::%uuid of player%}%th Join!"
  325.  
  326. on quit:
  327. set quit message to "&2&lEntrance&f: &cQuit: %player%"
  328. command "execute @a ~ ~ ~ playsound entity.creeper.primed master @s"
Advertisement
Add Comment
Please, Sign In to add comment