taktie0304

Untitled

Jul 28th, 2019
244
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 31.88 KB | None | 0 0
  1. command /teamgunpvp:
  2. aliases: /tgp
  3. permission: skript.admin
  4. trigger:
  5. command "/scoreboard teams remove red"
  6. wait 1 tick
  7. command "/scoreboard teams remove blue"
  8. wait 1 tick
  9. command "/scoreboard teams add red"
  10. wait 1 tick
  11. command "/scoreboard teams add blue"
  12. wait 1 tick
  13. command "/scoreboard teams option red color red"
  14. wait 1 tick
  15. command "/scoreboard teams option blue color blue"
  16. wait 1 tick
  17. command "/scoreboard teams option red nametagVisibility hideForOtherTeams"
  18. wait 1 tick
  19. command "/scoreboard teams option blue nametagVisibility hideForOtherTeams"
  20. wait 1 tick
  21. set {game} to false
  22. set {start} to false
  23. set {button} to true
  24. send "completed" to player
  25.  
  26. #==================================================[ 関数 ]==================================================#
  27.  
  28. function endgame():
  29. set {button} to false
  30. set {game} to false
  31. disable PvP in "world"
  32. if {tresult} is "&6&l勝利":
  33. loop all players:
  34. if {team.%loop-player%} is "t":
  35. send title "%{tresult}%" with subtitle "%{tresultsub}%" to loop-player for 5 seconds
  36. send "%{tresult}%" to loop-player
  37. send "&a+10xp &6+100coins" to loop-player
  38. add 100 to {coin.%uuid of loop-player%}
  39. add 10 to {xp.%uuid of loop-player%}
  40. add 1 to {win.%uuid of loop-player%}
  41. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.5 1"
  42. if {team.%loop-player%} is "ct":
  43. send title "%{ctresult}%" with subtitle "%{ctresultsub}%" to loop-player for 5 seconds
  44. send "%{ctresult}%" to loop-player
  45. send "&a+2xp &6+10coins" to loop-player
  46. add 10 to {coin.%uuid of loop-player%}
  47. add 2 to {xp.%uuid of loop-player%}
  48. add 1 to {lose.%uuid of loop-player%}
  49. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.5 1"
  50. if {ctresult} is "&6&l勝利":
  51. loop all players:
  52. if {team.%loop-player%} is "t":
  53. send title "%{tresult}%" with subtitle "%{tresultsub}%" to loop-player for 5 seconds
  54. send "%{tresult}%" to loop-player
  55. send "&a+2xp &6+10coins" to loop-player
  56. add 10 to {coin.%uuid of loop-player%}
  57. add 2 to {xp.%uuid of loop-player%}
  58. add 1 to {win.%uuid of loop-player%}
  59. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.5 1"
  60. if {team.%loop-player%} is "ct":
  61. send title "%{ctresult}%" with subtitle "%{ctresultsub}%" to loop-player for 5 seconds
  62. send "%{ctresult}%" to loop-player
  63. send "&a+10xp &6+100coins" to loop-player
  64. add 10 to {coin.%uuid of loop-player%}
  65. add 2 to {xp.%uuid of loop-player%}
  66. add 1 to {lose.%uuid of loop-player%}
  67. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.5 1"
  68. wait 6 seconds
  69. loop all players:
  70. if {team.%loop-player%} is set:
  71. close loop-player's inventory
  72. command "clear %loop-player%"
  73. command "kill @e[type=Item]"
  74. command "/scoreboard teams empty red"
  75. command "/scoreboard teams empty blue"
  76. give grey dye named "&eゲームに参加する" to loop-player
  77. teleport the loop-player to {lobby}
  78. set health of loop-player to max health of loop-player
  79. set the loop-player's gamemode to adventure
  80. set the loop-player's tablist name to "&7[Lv%{level.%uuid of loop-player%}%]&r%{prefix.%uuid of loop-player%}%&r%loop-player%&r%{suffix.%uuid of loop-player%}%"
  81. delete {team.%loop-player%}
  82. if {mapselector} == 1:
  83. command "/fill -43 21 -9 -47 21 -5 air"
  84. command "/fill -11 21 37 -7 21 41 air"
  85. if {mapselector} == 2:
  86. command "/fill 183 19 13 179 19 9 air"
  87. command "/fill 171 22 76 175 22 72 air"
  88. set {button} to true
  89. else:
  90. send "&a試合が終了しました" to loop-player
  91.  
  92. function showvs():
  93. loop all players:
  94. if {team.%loop-player%} is "t":
  95. send title " " with subtitle "%{t}% VS %{ct}%" to loop-player for 3 seconds
  96. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.2 2"
  97. if {team.%loop-player%} is "ct":
  98. send title " " with subtitle "%{ct}% VS %{t}%" to loop-player for 3 seconds
  99. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.2 2"
  100.  
  101. #==================================================[ ゲームスタート ]==================================================#
  102.  
  103. on rightclick on wood button:
  104. if {button} is true:
  105. {start} is false
  106. if {game} is false:
  107. set {start} to true
  108. loop all players:
  109. send title "&a5" with subtitle "スタートまで" to loop-player for 2 seconds
  110. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:ui.button.click master %loop-player% ~ ~ ~ 1 2"
  111. wait 1 second
  112. loop all players:
  113. send title "&a4" with subtitle "スタートまで" to loop-player for 2 seconds
  114. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:ui.button.click master %loop-player% ~ ~ ~ 1 2"
  115. wait 1 second
  116. loop all players:
  117. send title "&a3" with subtitle "スタートまで" to loop-player for 2 seconds
  118. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:ui.button.click master %loop-player% ~ ~ ~ 1 2"
  119. wait 1 second
  120. loop all players:
  121. send title "&a2" with subtitle "スタートまで" to loop-player for 2 seconds
  122. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:ui.button.click master %loop-player% ~ ~ ~ 1 2"
  123. wait 1 second
  124. loop all players:
  125. send title "&a1" with subtitle "スタートまで" to loop-player for 1 seconds
  126. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:ui.button.click master %loop-player% ~ ~ ~ 1 2"
  127. wait 1 second
  128. set {gameplayer} to 0
  129. loop all players:
  130. if {join.%loop-player%} is true:
  131. add 1 to {gameplayer}
  132. if {gameplayer} <= 1:
  133. broadcast "&c参加人数が足りませんでした"
  134. wait 1 second
  135. set {start} to false
  136. else:
  137. set {t} to 0
  138. set {ct} to 0
  139. set {count} to 120
  140. set {lobby} to location (49, 5, 10)
  141. set {cmdlobby} to "49 5 10"
  142. if {gameplayer} >= 4:
  143. set {mapselector} to random integer between 2 and 2
  144. else:
  145. set {mapselector} to random integer between 1 and 1
  146. if {mapselector} == 1:
  147. set {tspawn} to location (-80, 22, 33)
  148. set {ctspawn} to location (-18, 19, 0)
  149. if {mapselector} == 2:
  150. set {tspawn} to location (96, 24, 26)
  151. set {ctspawn} to location (166, 14, 51)
  152. set {givebomb} to true
  153. set {putbomb} to false
  154. loop all players:
  155. if {join.%loop-player%} is true:
  156. if {teamselector} == 0:
  157. command "/clear %loop-player%"
  158. if {givebomb} is true:
  159. command "give %loop-player% minecraft:obsidian 1 0 {display:{Name:""金ブロックの上に置いてください!""},CanPlaceOn:[""minecraft:gold_block""]}"
  160. set {givebomb} to false
  161. set {team.%loop-player%} to "t"
  162. set {teamchat.%loop-player%} to "&c"
  163. delete {died.%loop-player%}
  164. delete {mainweapon.%loop-player%}
  165. add 1 to {t}
  166. command "/scoreboard teams join red %loop-player%"
  167. teleport the loop-player to {tspawn}
  168. if {ak47use.%uuid of loop-player%} is true:
  169. if {ak47.%uuid of loop-player%} > 0:
  170. set {mainweapon.%loop-player%} to "ak47"
  171. command "shot give %loop-player% ak47"
  172. if {mainweapon.%loop-player%} is not set:
  173. if {awpuse.%uuid of loop-player%} is true:
  174. if {awp.%uuid of loop-player%} > 0:
  175. set {mainweapon.%loop-player%} to "awp"
  176. command "shot give %loop-player% awp"
  177. command "shot give %loop-player% glock18"
  178. give red wool named "&cあなたはテロリストチームです" to loop-player
  179. set the loop-player's gamemode to adventure
  180. set the loop-player's tablist name to "&7[Lv%{level.%uuid of loop-player%}%]&c%loop-player%"
  181. send title " " with subtitle "敵を全滅、もしくは爆弾を防衛せよ" to loop-player for 5 seconds
  182. delete {join.%loop-player%}
  183. set {teamselector} to 1
  184. else:
  185. command "/clear %loop-player%"
  186. command "give %loop-player% minecraft:diamond_pickaxe 1 0 {display:{Name:""爆弾を破壊してください!""},ench:[{id:32s,lvl:1s}],CanDestroy:[""minecraft:obsidian""]}"
  187. set {team.%loop-player%} to "ct"
  188. set {teamchat.%loop-player%} to "&9"
  189. delete {died.%loop-player%}
  190. delete {mainweapon.%loop-player%}
  191. add 1 to {ct}
  192. command "/scoreboard teams join blue %loop-player%"
  193. teleport the loop-player to {ctspawn}
  194. if {m4a4use.%uuid of loop-player%} is true:
  195. if {m4a4.%uuid of loop-player%} > 0:
  196. set {mainweapon.%loop-player%} to "m4a4"
  197. command "shot give %loop-player% m4a4"
  198. if {mainweapon.%loop-player%} is not set:
  199. if {awpuse.%uuid of loop-player%} is true:
  200. if {awp.%uuid of loop-player%} > 0:
  201. set {mainweapon.%loop-player%} to "awp"
  202. command "shot give %loop-player% awp"
  203. command "shot give %loop-player% usp"
  204. give blue wool named "&9あなたはカウンターテロリストチームです" to loop-player
  205. set the loop-player's gamemode to adventure
  206. set the loop-player's tablist name to "&7[Lv%{level.%uuid of loop-player%}%]&9%loop-player%"
  207. send title " " with subtitle "敵を全滅、もしくは爆弾を破壊せよ" to loop-player for 5 seconds
  208. delete {join.%loop-player%}
  209. set {teamselector} to 0
  210. set {game} to true
  211. broadcast "&cテロリスト%{t}%人 &9カウンターテロリスト%{ct}%人 &a参加中"
  212. enable PvP
  213. set {start} to false
  214. set {button} to true
  215. else:
  216. send "&c現在試合中です" to player
  217.  
  218. #==================================================[ 死んだ時 ]==================================================#
  219.  
  220. on death of player:
  221. if name of attacker's held item contains "USP":
  222. set the death message to "%{teamchat.%attacker%}%%attacker% &7--[&aUSP&7]--> %{teamchat.%victim%}%%victim%"
  223. else if name of attacker's held item contains "Glock-18":
  224. set the death message to "%{teamchat.%attacker%}%%attacker% &7--[&aGlock-18&7]--> %{teamchat.%victim%}%%victim%"
  225. else if name of attacker's held item contains "AK-47":
  226. set the death message to "%{teamchat.%attacker%}%%attacker% &7--[&aAK-47&7]--> %{teamchat.%victim%}%%victim%"
  227. else if name of attacker's held item contains "M4A4":
  228. set the death message to "%{teamchat.%attacker%}%%attacker% &7--[&aM4A4&7]--> %{teamchat.%victim%}%%victim%"
  229. else if name of attacker's held item contains "AWP":
  230. set the death message to "%{teamchat.%attacker%}%%attacker% &7--[&5AWP&7]--> %{teamchat.%victim%}%%victim%"
  231. if {game} is true:
  232. if name of victim's held item contains "AK-47":
  233. if {mainweapon.%victim%} is "ak47":
  234. remove 1 from {ak47.%uuid of victim%}
  235. if name of victim's held item contains "M4A4":
  236. if {mainweapon.%victim%} is "m4a4":
  237. remove 1 from {m4a4.%uuid of victim%}
  238. if name of victim's held item contains "AWP":
  239. if {mainweapon.%victim%} is "awp":
  240. remove 1 from {awp.%uuid of victim%}
  241. set {died.%victim%} to true
  242. set {deathpoint.%victim%} to location of victim
  243. force the victim to respawn
  244. teleport player to {deathpoint.%player%}
  245. set the player's gamemode to spectator
  246. remove 1 from {%{team.%victim%}%}
  247. add 1 to {kill.%uuid of attacker%}
  248. add 1 to {death.%uuid of victim%}
  249. add 3 to {xp.%uuid of attacker%}
  250. add 30 to {coin.%uuid of attacker%}
  251. send "&a+3xp &6+30coins" to attacker
  252. if {putbomb} is true:
  253. if {t} is 0:
  254. set {button} to false
  255. loop all players:
  256. if {team.%loop-player%} is "t":
  257. send title " " with subtitle "味方が全員倒された" to loop-player for 3 seconds
  258. send "&l味方が全員倒された" to loop-player
  259. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.2 2"
  260. if {team.%loop-player%} is "ct":
  261. send title " " with subtitle "敵は全滅した。爆弾を破壊せよ" to loop-player for 3 seconds
  262. send "&l敵は全滅した。爆弾を破壊せよ" to loop-player
  263. execute console command "execute %loop-player% ~ ~ ~ playsound minecraft:entity.wither.spawn master %loop-player% ~ ~ ~ 0.2 2"
  264. else if {ct} is 0:
  265. set {tresult} to "&6&l勝利"
  266. set {ctresult} to "&9&l敗北"
  267. set {tresultsub} to "敵を全員倒した"
  268. set {ctresultsub} to "味方が全員倒された"
  269. endgame()
  270. else:
  271. showvs()
  272. else if {t} is 0:
  273. set {tresult} to "&9&l敗北"
  274. set {ctresult} to "&6&l勝利"
  275. set {tresultsub} to "味方が全員倒された"
  276. set {ctresultsub} to "敵を全員倒した"
  277. endgame()
  278. else if {ct} is 0:
  279. set {tresult} to "&6&l勝利"
  280. set {ctresult} to "&9&l敗北"
  281. set {tresultsub} to "敵を全員倒した"
  282. set {ctresultsub} to "味方が全員倒された"
  283. endgame()
  284. else:
  285. showvs()
  286.  
  287. #==================================================[ 爆弾が置かれた時 ]==================================================#
  288.  
  289. on place of obsidian:
  290. if {game} is true:
  291. set {count} to 40
  292. set {putbomb} to true
  293. loop all players:
  294. if {team.%loop-player%} is "t":
  295. send "&a&l爆弾が設置された! 40秒間守り切れ!" to loop-player
  296. send title " " with subtitle "&a爆弾が設置された! 40秒間守り切れ!" to loop-player for 3 seconds
  297. if {team.%loop-player%} is "ct":
  298. send "&c&l爆弾が設置された! 40秒以内に破壊せよ!" to loop-player
  299. send title " " with subtitle "&c爆弾が設置された! 40秒以内に破壊せよ!" to loop-player for 3 seconds
  300.  
  301. #==================================================[ 爆弾が壊された時 ]==================================================#
  302.  
  303. on break of obsidian:
  304. if {game} is true:
  305. set {tresult} to "&9&l敗北"
  306. set {ctresult} to "&6&l勝利"
  307. set {tresultsub} to "爆弾が破壊された"
  308. set {ctresultsub} to "爆弾を破壊した"
  309. endgame()
  310.  
  311. #==================================================[ 残り時間計測 ]==================================================#
  312.  
  313. every a second in "world":
  314. if {game} is true:
  315. remove 1 from {count}
  316. if {count} < 0:
  317. if {putbomb} is true:
  318. set {tresult} to "&6&l勝利"
  319. set {ctresult} to "&9&l敗北"
  320. set {tresultsub} to "時間切れ"
  321. set {ctresultsub} to "時間切れ"
  322. endgame()
  323. else:
  324. set {tresult} to "&9&l敗北"
  325. set {ctresult} to "&6&l勝利"
  326. set {tresultsub} to "時間切れ"
  327. set {ctresultsub} to "時間切れ"
  328. endgame()
  329. loop all players:
  330. if {team.%loop-player%} is set:
  331. send action bar "&f(残り時間: %{count}%秒)" to loop-player
  332.  
  333. #==================================================[ 抜けたとき ]==================================================#
  334.  
  335. on quit:
  336. if {team.%player%} is set:
  337. delete {team.%player%}
  338. delete {teamchat.%player%}
  339. if {died.%player%} is false:
  340. remove 1 from {%{team.%player%}%}
  341. command "/scoreboard teams leave %{team.%player%}% %player%"
  342. if {t} is 0:
  343. set {tresult} to "&9&l敗北"
  344. set {ctresult} to "&6&l勝利"
  345. set {tresultsub} to "味方が全員倒された"
  346. set {ctresultsub} to "敵を全員倒した"
  347. endgame()
  348. else if {blue} is 0:
  349. set {tresult} to "&6&l勝利"
  350. set {ctresult} to "&9&l敗北"
  351. set {tresultsub} to "敵を全員倒した"
  352. set {ctresultsub} to "味方が全員倒された"
  353. endgame()
  354. else:
  355. showvs()
  356.  
  357. #==================================================[ 仕様 ]==================================================#
  358.  
  359. on damage of player:
  360. if {game} is true:
  361. if {team.%attacker%} == {team.%victim%}:
  362. cancel event
  363.  
  364. on pick up of red wool:
  365. if {team.%player%} is set:
  366. cancel event
  367.  
  368. on pick up of blue wool:
  369. if {team.%player%} is set:
  370. cancel event
  371.  
  372. on pick up of iron horse armor:
  373. if {team.%player%} is set:
  374. if player have iron horse armor:
  375. cancel event
  376.  
  377. on pick up of gold horse armor:
  378. if {team.%player%} is set:
  379. if player have gold horse armor:
  380. cancel event
  381.  
  382. on pick up of obsidian:
  383. if {team.%player%} is "ct":
  384. cancel event
  385.  
  386. on pick up of diamond pickaxe:
  387. if {team.%player%} is "red":
  388. cancel event
  389. else if player have diamond pickaxe:
  390. cancel event
  391.  
  392. on hunger bar change:
  393. set the player's food level to 10
  394.  
  395. #==================================================[ コマンド ]==================================================#
  396.  
  397. command /stats [<offline player>]:
  398. trigger:
  399. if arg 1 is not set:
  400. send "&6-----< &b%player% &6>-----"
  401. set {killdeath.%uuid of player%} to {kill.%uuid of player%} / {death.%uuid of player%}
  402. set {winlose.%uuid of player%} to {win.%uuid of player%} / {lose.%uuid of player%}
  403. send " &alevel: &e%{level.%uuid of player%}%" to player
  404. send " &axp: &e%{xp.%uuid of player%}%&7/%{needxp.%uuid of player%}%" to player
  405. send " "
  406. send " &akill: &e%{kill.%uuid of player%}%" to player
  407. send " &adeath: &e%{death.%uuid of player%}%" to player
  408. send " &aK/D: &e%{killdeath.%uuid of player%}%" to player
  409. send " &awin: &e%{win.%uuid of player%}%" to player
  410. send " &alose: &e%{lose.%uuid of player%}%" to player
  411. send " &aW/L: &e%{winlose.%uuid of player%}%" to player
  412. else:
  413. send "&6-----< &b%arg 1% &6>-----"
  414. set {killdeath.%uuid of arg 1%} to {kill.%uuid of arg 1%} / {death.%uuid of arg 1%}
  415. set {winlose.%uuid of arg 1%} to {win.%uuid of arg 1%} / {lose.%uuid of arg 1%}
  416. send " &alevel: &e%{level.%uuid of arg 1%}%" to player
  417. send " &axp: &e%{xp.%uuid of arg 1%}%&7/%{needxp.%uuid of arg 1%}%" to player
  418. send " "
  419. send " &akill: &e%{kill.%uuid of arg 1%}%" to player
  420. send " &adeath: &e%{death.%uuid of arg 1%}%" to player
  421. send " &aK/D: &e%{killdeath.%uuid of arg 1%}%" to player
  422. send " &awin: &e%{win.%uuid of arg 1%}%" to player
  423. send " &alose: &e%{lose.%uuid of arg 1%}%" to player
  424. send " &aW/L: &e%{winlose.%uuid of arg 1%}%" to player
  425.  
  426. #==================================================[ 武器選択 ]==================================================#
  427.  
  428. command /buycoin [<number>] [<offline player>]:
  429. permission: skript.admin
  430. trigger:
  431. if arg 1 is 1000:
  432. add 1000 to {coin.%uuid of arg 2%}
  433. if arg 1 is 5000:
  434. add 5000 to {coin.%uuid of arg 2%}
  435.  
  436. command /shop [<text>]:
  437. trigger:
  438. if arg 1 is "hnfewfbbfwygbb":
  439. open chest with 4 row named "武器選択、購入" to player
  440. set slot 31 of player's current inventory to nether star named "&e所持金&6%{coin.%uuid of player%}%&eコイン"
  441. set slot 10 of player's current inventory to gold horse armor named "&a&lAK-47" with lore "&62700コイン必要" and "&c赤チーム専用" and "&7現在&f%{ak47.%uuid of player%}%&7個所持" and " " and "&eクリックで10個購入"
  442. if {ak47use.%uuid of player%} is not set:
  443. set slot 19 of player's current inventory to grey dye named "&cOFF" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでAK-47の使用をON"
  444. else:
  445. set slot 19 of player's current inventory to lime dye named "&aON" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでAK-47の使用をOFF"
  446. set slot 11 of player's current inventory to gold horse armor named "&a&lM4A4" with lore "&63100コイン必要" and "&9青チーム専用" and "&7現在&f%{m4a4.%uuid of player%}%&7個所持" and " " and "&eクリックで10個購入"
  447. if {m4a4use.%uuid of player%} is not set:
  448. set slot 20 of player's current inventory to grey dye named "&cOFF" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでM4A4の使用をON"
  449. else:
  450. set slot 20 of player's current inventory to lime dye named "&aON" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでM4A4の使用をOFF"
  451. set slot 12 of player's current inventory to gold horse armor named "&5&lAWP" with lore "&64750コイン必要" and "&7全チーム兼用" and "&7現在&f%{awp.%uuid of player%}%&7個所持" and " " and "&eクリックで10個購入"
  452. if {awpuse.%uuid of player%} is not set:
  453. set slot 21 of player's current inventory to grey dye named "&cOFF" with lore "&7武器の数が0個だと、OFFにしても意味がありません" and " " and "&eクリックでAWPの使用をON"
  454. else:
  455. set slot 21 of player's current inventory to lime dye named "&aON" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでAWPの使用をOFF"
  456.  
  457. command /coin:
  458. trigger:
  459. send "&6%{coin.%uuid of player%}%&eコイン"
  460.  
  461. every 5 seconds:
  462. loop all players:
  463. if {ak47.%uuid of loop-player%} is not set:
  464. set {ak47.%uuid of loop-player%} to 0
  465. if {m4a4.%uuid of loop-player%} is not set:
  466. set {m4a4.%uuid of loop-player%} to 0
  467. if {awp.%uuid of loop-player%} is not set:
  468. set {awp.%uuid of loop-player%} to 0
  469. if {coin.%uuid of loop-player%} is not set:
  470. set {coin.%uuid of loop-player%} to 0
  471.  
  472. on rightclick on villager:
  473. cancel event
  474. open chest with 4 row named "武器選択、購入" to player
  475. set slot 31 of player's current inventory to nether star named "&e所持金&6%{coin.%uuid of player%}%&eコイン"
  476. set slot 10 of player's current inventory to gold horse armor named "&a&lAK-47" with lore "&62700コイン必要" and "&c赤チーム専用" and "&7現在&f%{ak47.%uuid of player%}%&7個所持" and " " and "&eクリックで10個購入"
  477. if {ak47use.%uuid of player%} is not set:
  478. set slot 19 of player's current inventory to grey dye named "&cOFF" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでAK-47の使用をON"
  479. else:
  480. set slot 19 of player's current inventory to lime dye named "&aON" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでAK-47の使用をOFF"
  481. set slot 11 of player's current inventory to gold horse armor named "&a&lM4A4" with lore "&63100コイン必要" and "&9青チーム専用" and "&7現在&f%{m4a4.%uuid of player%}%&7個所持" and " " and "&eクリックで10個購入"
  482. if {m4a4use.%uuid of player%} is not set:
  483. set slot 20 of player's current inventory to grey dye named "&cOFF" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでM4A4の使用をON"
  484. else:
  485. set slot 20 of player's current inventory to lime dye named "&aON" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでM4A4の使用をOFF"
  486. set slot 12 of player's current inventory to gold horse armor named "&5&lAWP" with lore "&64750コイン必要" and "&7全チーム兼用" and "&7現在&f%{awp.%uuid of player%}%&7個所持" and " " and "&eクリックで10個購入"
  487. if {awpuse.%uuid of player%} is not set:
  488. set slot 21 of player's current inventory to grey dye named "&cOFF" with lore "&7武器の数が0個だと、OFFにしても意味がありません" and " " and "&eクリックでAWPの使用をON"
  489. else:
  490. set slot 21 of player's current inventory to lime dye named "&aON" with lore "&7武器の数が0個だと、ONにしても意味がありません" and " " and "&eクリックでAWPの使用をOFF"
  491.  
  492. on inventory click:
  493. if name of player's current inventory contains "武器選択、購入":
  494. cancel event
  495. if clicked slot is 10:
  496. if {coin.%uuid of player%} >= 2700:
  497. remove 2700 from {coin.%uuid of player%}
  498. add 10 to {ak47.%uuid of player%}
  499. send "&aAK-47を10個分購入しました" to player
  500. make player execute command "/shop hnfewfbbfwygbb"
  501. else:
  502. send "&cコインが足りません" to player
  503. if clicked slot is 11:
  504. if {coin.%uuid of player%} >= 3100:
  505. remove 3100 from {coin.%uuid of player%}
  506. add 10 to {m4a4.%uuid of player%}
  507. send "&aM4A4を10個分購入しました" to player
  508. make player execute command "/shop hnfewfbbfwygbb"
  509. else:
  510. send "&cコインが足りません" to player
  511. if clicked slot is 12:
  512. if {coin.%uuid of player%} >= 4750:
  513. remove 4750 from {coin.%uuid of player%}
  514. add 10 to {awp.%uuid of player%}
  515. send "&aAWPを10個分購入しました" to player
  516. make player execute command "/shop hnfewfbbfwygbb"
  517. else:
  518. send "&cコインが足りません" to player
  519. if clicked slot is 19:
  520. if {ak47use.%uuid of player%} is not set:
  521. set {ak47use.%uuid of player%} to true
  522. else:
  523. delete {ak47use.%uuid of player%}
  524. make player execute command "/shop hnfewfbbfwygbb"
  525. if clicked slot is 20:
  526. if {m4a4use.%uuid of player%} is not set:
  527. set {m4a4use.%uuid of player%} to true
  528. else:
  529. delete {m4a4use.%uuid of player%}
  530. make player execute command "/shop hnfewfbbfwygbb"
  531. if clicked slot is 21:
  532. if {awpuse.%uuid of player%} is not set:
  533. set {awpuse.%uuid of player%} to true
  534. else:
  535. delete {awpuse.%uuid of player%}
  536. make player execute command "/shop hnfewfbbfwygbb"
  537.  
  538. #==================================================[ その他 ]==================================================#
  539.  
  540. on first join:
  541. set {kill.%uuid of player%} to 0
  542. set {death.%uuid of player%} to 0
  543. set {killdeath.%uuid of player%} to 0
  544. set {win.%uuid of player%} to 0
  545. set {lose.%uuid of player%} to 0
  546. set {winlose.%uuid of player%} to 0
  547. set {level.%uuid of player%} to 1
  548. set {xp.%uuid of player%} to 0
  549. set {needxp.%uuid of player%} to 10
  550. set {prefix.%uuid of player%} to ""
  551. set {suffix.%uuid of player%} to ""
  552.  
  553. every 3 seconds:
  554. loop all players:
  555. if {xp.%uuid of loop-player%} >= {needxp.%uuid of loop-player%}:
  556. set {xp.%uuid of loop-player%} to {xp.%uuid of loop-player%} - {needxp.%uuid of loop-player%}
  557. add 1 to {level.%uuid of loop-player%}
  558. set {needxp.%uuid of loop-player%} to {needxp.%uuid of loop-player%} * 1.5
  559. send "&b&lレベルアップ!! &a現在のレベル&7: &e%{level.%uuid of loop-player%}%" to loop-player
  560. set the loop-player's tablist name to "&7[Lv%{level.%uuid of loop-player%}%]&r%{prefix.%uuid of loop-player%}%&r%loop-player%&r%{suffix.%uuid of loop-player%}%"
  561.  
  562. on join:
  563. wait 3 ticks
  564. set the player's tablist name to "&7[Lv%{level.%uuid of player%}%]&r%{prefix.%uuid of player%}%&r%player%&r%{suffix.%uuid of player%}%"
  565. command "/gamemode 2 %player%"
  566. command "/clear %player%"
  567. give grey dye named "&eゲームに参加する" to player
  568. teleport the player to {lobby}
  569. set health of player to max health of player
  570. send "&a▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬" to player
  571. send " &f&lTeamGunPvP" to player
  572. send " " to player
  573. send " &e&l攻撃側と防衛側に分かれ、チームで戦います。" to player
  574. send " &e&l攻撃側は特定の場所に黒曜石を置き、" to player
  575. send " &e&lそれを壊されないよう守る必要があります。" to player
  576. send " &e&l防衛側は黒曜石を置かれないように防衛しましょう。" to player
  577. send " &e&lもし置かれても、破壊が可能です。" to player
  578. send " " to player
  579. send "&a▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬" to player
  580.  
  581. on chat:
  582. cancel event
  583. if {mutelist::*} contains player:
  584. send "&cあなたはミュートされているため、発言することができません。" to player
  585. stop
  586. else if {spam.%player's UUID%} is coloured message:
  587. send "&6---------------------------" to player
  588. send "&c&l同じメッセージを送信できません" to player
  589. send "&6---------------------------" to player
  590. stop
  591. else if {team.%player%} is set:
  592. set {spam.%player's UUID%} to coloured message
  593. broadcast "&7[Lv%{level.%uuid of player%}%]&r%{prefix.%uuid of player%}%&r%{teamchat.%player%}%%player%&r%{suffix.%uuid of player%}%&e》&r%coloured message%"
  594. else:
  595. set {spam.%player's UUID%} to coloured message
  596. broadcast "&7[Lv%{level.%uuid of player%}%]&r%{prefix.%uuid of player%}%&r%player%&r%{suffix.%uuid of player%}%&e》&r%coloured message%"
  597.  
  598. command /chat [<text>] [<offline player>] [<text>]:
  599. permission: skript.admin
  600. usage: /chat <prefix|suffix|mute|unmute> <player> <text>
  601. trigger:
  602. if arg 1 is "prefix":
  603. set {prefix.%uuid of arg 2%} to colored arg 3
  604. send "&b%arg 2%さんのprefixを「&r%{prefix.%arg 2%}%&b」に変更しました。" to player
  605. stop
  606. if arg 1 is "suffix":
  607. set {suffix.%uuid of arg 2%} to colored arg 3
  608. send "&b%arg 2%さんのsuffixを&r「%{suffix.%arg 2%}%&b」に変更しました。" to player
  609. stop
  610. if arg 1 is "deleteprefix":
  611. if arg 3 is not set:
  612. set {prefix.%uuid of arg 2%} to ""
  613. send "&b%arg 2%さんのprefixを削除しました" to player
  614. stop
  615. if arg 1 is "deletesuffix":
  616. if arg 3 is not set:
  617. set {suffix.%uuid of arg 2%} to ""
  618. send "&b%arg 2%さんのsuffixを削除しました" to player
  619. stop
  620. if arg 1 is "mute":
  621. if {mutelist::*} contains arg 2:
  622. send "&c%arg 2%さんはすでにミュートされています。"
  623. stop
  624. send "&e%arg 2%さんが%sender%さんにミュートされました。" to ops
  625. send "&e理由:%coloured arg 3%" to ops
  626. add arg 2 to {mutelist::*}
  627. stop
  628. if arg 1 is "unmute":
  629. if {mutelist::*} contains arg 2:
  630. send "&a%arg 2%さんが%sender%さんにミュート解除されました。" to ops
  631. send "&a理由:%coloured arg 3%" to ops
  632. remove arg 2 from {mutelist::*}
  633. stop
  634. send "&c%arg 2%さんはミュートされていません。" to player
  635. stop
  636.  
  637. command /mutelist [<offline player>]:
  638. permission: skript.admin
  639. trigger:
  640. if arg 1 is not set:
  641. send "&d次のプレイヤーがミュートされています:"
  642. send "%{mutelist::*}%"
  643. stop
  644. if {mutelist::*} contains arg 1:
  645. send "&d対象のプレイヤーはミュートされています。"
  646. stop
  647. send "&b対象のプレイヤーはミュートされていません。"
  648.  
  649. on click:
  650. if player is holding lime dye named "&cゲームを抜ける":
  651. remove lime dye named "&cゲームを抜ける" from player
  652. set {join.%player%} to false
  653. send "&cゲームを抜けました"
  654. wait 5 ticks
  655. give grey dye named "&eゲームに参加する" to player
  656.  
  657. on click:
  658. if player is holding grey dye named "&eゲームに参加する":
  659. remove grey dye named "&eゲームに参加する" from player
  660. set {join.%player%} to true
  661. send "&eゲームに参加しました" to player
  662. wait 5 ticks
  663. give lime dye named "&cゲームを抜ける" to player
  664.  
  665. command /dye:
  666. permission: skript.admin
  667. trigger:
  668. give grey dye named "&eゲームに参加する" to player
Advertisement
Add Comment
Please, Sign In to add comment