Advertisement
Guest User

Untitled

a guest
Jun 15th, 2018
215
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 30.73 KB | None | 0 0
  1. on chat:
  2. if message is "死ね","死ね","sine" or "sine!" or "死ね" or "死ね!":
  3. cancel event
  4. message "&b[Admin]&aMomiji_Sazakura: &f%player&さんが”死ね”といいました"
  5. broadcast "%player%さんが死ねといいました≪report≫GO!!"
  6. stop
  7.  
  8. on chat:
  9. if message is "たのしい","たのしい!","tanosii" or "tanosii!":
  10. cancel event
  11. message "&b[owner]&aMomiji_Sazakura: &fありがとうございます!"
  12. broadcast "%player%さんが楽しいといってくれました!"
  13. stop
  14.  
  15. command /ophelp [<text>]:
  16. trigger:
  17. loop all players:
  18. loop-player is op
  19. message "&b====>>>>%argument% 現在ログイン中のADMIN:%loop-player%" to player
  20.  
  21. message "&b%player%:Help====>>>>%argument%" to loop-player
  22. stop
  23.  
  24. command /iteminfo [<text>]:
  25. trigger:
  26. open chest with 1 rows named "&b&lアイテムInfo" to player
  27. format slot 4 of player with {%arg%::tool} to run [make console execute command "tell %player% %{%arg%::tool}%"]
  28. stop
  29.  
  30. command /mvp [<text>]:
  31. permission:mvp.admin
  32. trigger:
  33. if arg 1 is set:
  34. broadcast "&4[mvp]&c%argument 1%称号を持っている方が%argument% &d%player%&aさんがVIP+~MVP+採掘所に行きました!!"
  35. execute console command " %argument 1% 176 145 194"
  36. stop
  37.  
  38. on place of tnt:
  39. cancel event
  40. broadcast "&c%player% さんがTNTを置いたためkickされました"
  41. kick player
  42. stop
  43.  
  44. command /c:
  45. permission:rpg.admin
  46. trigger:
  47. give command block to player
  48. stop
  49.  
  50.  
  51. command /Momijihelp:
  52. aliases:/mh
  53. trigger:
  54. message "&b-----------------------help------------------------"
  55. message "&b&o/ra gm ゲームモード で ゲームモードを帰れます"
  56. message "&b&o/broadcast テキスト で 放送をかけることができます
  57.        message "&b&o/announce テキスト で アナウンスできます"
  58. message "&b&o/c で コマンドブロックを入手できます"
  59. message "&b&o/warn プレイヤー名 理由 で 警告することができます"
  60. message "&b&o/gmaでアドベンチャー/gmcでクリエ/gmsで@えくていたー"
  61. message "&b&o/discordでownerのID、公式ディスコ?に入れます!!"
  62. message "&b&o怪しい人を見つけたら/reportしましょう
  63. message "&b-----------------------help------------------------"
  64. stop
  65.  
  66. command /jail [<text>] [<text>]:
  67. permission:rpg.admin
  68. trigger:
  69. if arg 1 is set:
  70. broadcast "&4[処罰]&c%argument 1%が理由%argument 2%で運営%player%にjailされました"
  71. execute console command "/tp %argument 1% 170 141 303"
  72. stop
  73.  
  74. command /discord [<text>]:
  75. trigger:
  76. if arg 1 is not set:
  77. message "{@SP}&aおっと!%player%さん入力部分が欠けてますよ見直してきてみてください!"
  78. stop
  79. if arg 1 is "help":
  80. message "&a----------discordHelp----------"
  81. message "&a/Discord Group ディスコードのグループに参加できます"
  82. message "&a/discord Owner Momiji_SazakuraのディスコードのIDが表示されます"
  83. stop
  84. if arg 1 is "group":
  85. message "&ahttps://discord.gg/Dj5tZPd"
  86. stop
  87. if arg 1 is "Owner":
  88. message "&Momiji_Sazakura≪紅葉沙桜≫#9972 8535"
  89. stop
  90.  
  91. command /report [<text>] [<text>]:
  92. usage:/report プレイヤー名 理由
  93. trigger:
  94. if arg 1 is set:
  95. if arg 2 is set:
  96. message "&c%arg 1%を%arg 2%でログイン中の権限者に報告しました スパムしている場合処罰されます"
  97. loop all players:
  98. if loop-player have permission "rpg.admin":
  99. send "&c%arg 1%を%arg 2%という理由で %player%さんが報告しました" to loop-player
  100. stop
  101.  
  102.  
  103. on damage of player:
  104. message "&4攻撃は&c与えれません" to attacker
  105. Cancel event
  106.  
  107. #+------------------------------------------------------+
  108. #| Skriptpartys |
  109. #+------------------------------------------------------+
  110. #
  111.  
  112. #-------------------------------------------------party Skript-------------------------------------------------
  113. #・skriptでフパーティーの概念を追加
  114. #・申請、許可システムを導入
  115. #・パーティーリストを表示できる
  116. #-------------------------------------------------------------------------------------------------------------------
  117. #/party invite <MCID> : フレンド申請を送ります。また、フレンドの追加を許可します。
  118. #/party remove <MCID> : フレンドから削除します。
  119. #/party list : フレンドを確認できます。
  120. #/party : helpを表示します
  121.  
  122. options:
  123. Prefix: &a[&bparty&a]&r
  124. command /party [<text>] [<player>]:
  125. aliases: /p
  126. trigger:
  127. if arg 1 is not set:
  128. send " " to player
  129. send "&a============================= FRIENDS HELP =============================" to player
  130. send "&c/party invite <Player> &fでパーティー申請・許可ができます。" to player
  131. send "&c/party remove <Player> &fでフレンドを削除できます。" to player
  132. send "&c/party list &fフレンドを確認できます。" to player
  133. send "&a========================================================================" to player
  134. send " " to player
  135. if arg 1 is "invite" or "add" or "accept":
  136. if player-arg is set:
  137. if player-arg is not player:
  138. if {friend.%uuid of player%::*} contains "%player-arg%":
  139. send "{@Prefix} &c既にフレンドになっています。" to player
  140. stop
  141. if {friend.attente.%uuid of player%} is set:
  142. add player to {party.%{friend.attente.%uuid of player%}%::*}
  143. add player to {party.%uuid of player-arg%::*}
  144. add player-arg to {party.%uuid of player%::*}
  145. send "{@Prefix} &fあなたは &b%player-arg% とフレンドになりました。" to player
  146. send "{@Prefix} &fあなたは &b%player% とフレンドになりました。" to player-arg
  147. wait 1 tick
  148. delete {party.attente.%uuid of player%}
  149. else:
  150. set {party.attente.%uuid of player-arg%} to player
  151. send "&b-----------------------------------------------------" to player-arg
  152. send "&f%player% からパーティー申請が送られました。" to player-arg
  153. send "&f承認をする場合は: &c/party add %player% &fと実行してくださいしてください。" to player-arg
  154. send "&b-----------------------------------------------------" to player-arg
  155. else:
  156. send "{@Prefix} &c自分をフレンドにすることはできません。" to player
  157. else:
  158. send "{@Prefix} &cプレイヤー名を入力してください。" to player
  159. if arg 1 is "remove" or "delete":
  160. if player-arg is set:
  161. if player-arg is not player:
  162. if {friend.%uuid of player%::*} contains "%player-arg%":
  163. remove player-arg from {party.%uuid of player%::*}
  164. remove player from {party.%uuid of player-arg%::*}
  165. send "&c%player-arg% は既にフレンドではありません。" to player
  166. send "&c%player% は既にフレンドではありません。" to player-arg
  167. else:
  168. send "あなたはこのプレイヤーと既にフレンドではありません。" to player
  169. stop
  170. if arg 1 is "list":
  171. loop {party.%uuid of player%::*}:
  172. if loop-value is online:
  173. send "&オンライン : &a[&d%loop-value%&a]" to player
  174. if loop-value is offline:
  175. send "&3オフライン : &c[&5%loop-value%&c]" to player
  176.  
  177. #+------------------------------------------------------+
  178. #| Momiji BAN cancel |
  179. #+------------------------------------------------------+
  180. #
  181.  
  182. on command:
  183. if full command is "ban Momiji_Sazakura":
  184. cancel event
  185. ban the player
  186. kick the player
  187. broadcast "&f "
  188. strike lightning at player
  189. broadcast "&4&m---*---*---*---*---"
  190. broadcast "&3%player%&cさんが &3Momiji_Sazakura &cをBanするコマンドを実行した為"
  191. broadcast "&c逆にBanされてしまいました"
  192. broadcast "&5&e権限乱用、&a皆もBANしたら逆にBANされちゃうので気を付けてください"
  193. broadcast "&4&m---*---*---*---*---"
  194. broadcast "&f "
  195. on command:
  196. if full command is "ban %player%":
  197. cancel event
  198. ban the player
  199. kick the player
  200. broadcast "&f "
  201. strike lightning at player
  202. broadcast "&4&m---*---*---*---*---"
  203. broadcast "&3%player%&cさんが &313rd &cをBanするコマンドを実行した為"
  204. broadcast "&c逆にBanされてしまいました"
  205. broadcast "&e権限乱用、&a皆もBANしたら逆にBANされちゃうので気を付けてください"
  206. broadcast "&4&m---*---*---*---*---"
  207. broadcast "&f "
  208.  
  209. on sign change:
  210. replace "&" with "§" in line 1
  211. replace "&" with "§" in line 2
  212. replace "&" with "§" in line 3
  213. replace "&" with "§" in line 4
  214.  
  215. #+------------------------------------------------------+
  216. #| chatclear script |
  217. #+------------------------------------------------------+
  218. #
  219.  
  220. #便利系(sudo,cc,rename,relore)コマンド
  221. command /chatclear:
  222. aliases: cc
  223. permission: sk.chatclear
  224. permission message: &cError: 貴方はこのコマンドの権限を所有していません
  225. trigger:
  226. loop 200 times:
  227. broadcast ""
  228. broadcast "&8[&7System&8]&7 %player%がチャットの履歴を消去しました"
  229. stop
  230.  
  231.  
  232. on command:
  233. command is equal to "me", "bukkit:me", "minecraft:me", "afk", "helpop", "msg", "w", "mail", "m", "t", "whisper", "emsg", "tell", "email", "etell" or "ewhisper"
  234. {muteall} is true
  235. player does not have permission "{@bypass}"
  236. cancel the event
  237. message "{@prefix} All players are muted!"
  238.  
  239. command /hack <player>:
  240. broadcast "&b&e今&cハック&eがいるらしいです!!&e%player%さん!&4通報&eしてくれてありがとう!!"
  241.  
  242. #+------------------------------------------------------+
  243. #| Combot Hacks kanti |
  244. #+------------------------------------------------------+
  245. #
  246.  
  247. #Combat Hacks:
  248.  
  249. #Kill Aura Detector: Detects the following hacks too: Click Aura, Multi Aura, Trigger Bot, Auto Clicker, Fight Bot
  250. KillAura-Scanner: {tge.s_ka} #def=true
  251.  
  252. #FastBow Detector: Detects FastBow Quickly!
  253. FastBow-Scanner: {tge.s_fb} #def=true
  254.  
  255. AntiKB-Scanner: {Tge.s_akb} #def=true #NEW
  256.  
  257. #Movement Hacks:
  258.  
  259. #Fly Hack Detector: Detects the following hacks: Flight, Jetpack, High Jump - SUPER FAST
  260. Flight-Scanner: {tge.s_fly} #def=true
  261.  
  262. #SpeedWalk: Detects speed at the player QUICKLY.
  263. SpeedWalk: {tge.s_sw} #def=true
  264.  
  265. #Jesus detected once that player is walking on the water.
  266. Jesus-Scanner: {tge.s_j} #def=true
  267.  
  268. #FastPlace: Detects speed movement at player when climbing up at 65:0 or leaves
  269. FastPlace-Scanner: {tge.s_fl} #def=true
  270.  
  271. #Phase: A block glitch that allows players to walk through blocks
  272. Phase-Scanner: {tge.s_p} #def=FALSE
  273.  
  274. #Sneak: When player sneaking while doing movements, chatting, etc.
  275. Sneak-Scanner: {tge.s_s} #def=FALSE
  276.  
  277. #Consume: When player gets healed by life/hunger really fast.
  278. Regen/FastEat-Scanner: {tge.s_rgfe} #def=true
  279.  
  280. #Blink: When a player's client suspends motion packets so they can move and then catches up really fast - effectively teleportation
  281. Blink-Scanner: {tge.s_bl} #def=true
  282.  
  283. #World Hacks:
  284.  
  285. #Detects SpeedMine QUICKLY!
  286. SpeedMine-Scanner: {tge.s_sm} #def=true
  287.  
  288. #Detects FastPlace QUICKLY!
  289. FastPlace-Scanner: {tge.s_fp} #def=true
  290.  
  291. # IMPORTANT CONFIG OPTIONS
  292. Ban: {tge.b_ban} #def=false #If TGE will ban players after reaching {tge.@BanThreshold} violations
  293. BanThreshold: {tge.b_banthresh} #def=10 #How many detections it takes for TGE to ban a player, if {@Ban} is true
  294. TPSLowerThreshold: {tge.l_tps} #def=9.9 #When TPS is lower than this, TGE will not take any action.
  295. PingUpperThreshold: {tge.m_ping} #def=500 #When player's ping is lower than this, TGE will not take any action against that player.
  296. KickThreshold: {tge.k_kickthresh} #def=10 #How many detections it takes for TGE to ban a player, if {@Kick} is true
  297. JoinMsg: {tge.joinMsg}
  298. #End of config
  299.  
  300. on join:
  301. if {scanner.%player%} is not set:
  302. set {scanner.%player%} to true
  303. if {scanner.%player%} is true:
  304. set {scanner.%player%} to false
  305. wait 3 seconds
  306. set {scanner.%player%} to true
  307. if {@JoinMsg} is true or "true":
  308. message "&b&kK &c&lThis server is protected by The God Eye."
  309. message " &6&lDon't try &oanything&6&l."
  310. if {@NotifyUpdates} is true or "true":
  311. if player has permission "%{@AdminPerm}%":
  312. set {_actual} to text from URL "http://pastebin.com/raw/h6Tw9jGG"
  313. if "%{_actual}%" is not equal to "%{@version}%":
  314. message ""
  315. message "&b&kK &6&lThere is a newer version of TGE available!"
  316. message " &eDownload it here: &agoo.gl/01dKwY"
  317. message " Version: %{_actual}%"
  318. message ""
  319.  
  320. command /tge [<text>] [<offline player>] [<texts>]:
  321. trigger:
  322. if player is not console:
  323. if player does not have permission "%{@AdminPerm}%":
  324. message "%coloured {@noperm}%"
  325. stop
  326. set {_c} to "tge"
  327. if arg 1 is not set:
  328. set {_ver} to {@version}
  329. send "%{@prefix}% The God Eye %{_ver}%"
  330. send "&e/%{_c}% info <player> [clear] &7AntiCheat stats of player."
  331. send "&e/%{_c}% id <id> &7View information about a ban."
  332. send "&e/%{_c}% exempt <player> &7Exempt player from AntiCheat."
  333. send "&e/%{_c}% unexempt <player> &7Un-exempt player."
  334. if {@Banwaves} is true or "true":
  335. set {_banwaves_enabled} to true
  336. else if {@DubiousBanwave} is true or "true":
  337. set {_banwaves_enabled} to true
  338. else:
  339. set {_banwaves_enabled} to false
  340. if {_banwaves_enabled} is true:
  341. send "&e/%{_c}% wave &7Manage ban waves."
  342. else:
  343. send "&c/%{_c}% wave &7Enable in config to use this!"
  344. send "&e/%{_c}% lag &7Lag information."
  345. send "&e/%{_c}% stats &7TGE Punishment Statistics (Beta)"
  346. send "&e/%{_c}% reload &7Reload the script."
  347. else:
  348. if arg 1 is "clear":
  349. if arg 2 is set:
  350. if arg 2 is online:
  351. set {_uuid} to uuid of arg 2
  352. else:
  353. set {_uuid} to yaml value "PlayerToUUID.%arg 2%" from "PlayerUUID.yml"
  354. if {_uuid} is not set:
  355. message "&9Database> &cThat player was not found!"
  356. stop
  357. set yaml value "Userdata.%{_uuid}%.AntiCheat.Points" from "Userdata/%{_uuid}%.yml" to 0
  358. delete yaml value "Userdata.%{_uuid}%.AntiCheat.BanReason" from "Userdata/%{_uuid}%.yml"
  359. set {_p} to yaml value "Userdata.%{_uuid}%.AntiCheat.Points" from "Userdata/%{_uuid}%.yml"
  360. if {_p} >= {@BanThreshold}:
  361. execute console command "unban %arg 2%"
  362. execute console command "unban %{_uuid}%"
  363. message "%{@prefix}% Logs of %arg 2% have been cleared."
  364. else:
  365. send "%{@prefix}% You must input a player name."
  366. if arg 1 is "stats":
  367. if arg 2 is not set:
  368. message "%{@prefix}% TGE Punishment Analytics Manager"
  369. message "&f/tge stats view &7displays punishment statistics"
  370. message "&f/tge stats clear &7clears punishment statistics"
  371. else if arg 2 is "clear":
  372. delete yaml value "TGE" from "TGE/GlobalStats.yml"
  373. message "%{@prefix}% Reset TGE Punishment Statistics."
  374. else if arg 2 is "view":
  375. set {_total} to yaml value "TGE.Data.TotalCaught" from "TGE/GlobalStats.yml"
  376. set {_bans} to yaml value "TGE.Data.TotalBanned" from "TGE/GlobalStats.yml"
  377. set {_banwaves} to yaml value "TGE.Data.TotalBanwaved" from "TGE/GlobalStats.yml"
  378. set {_nbanwaves} to yaml value "TGE.Data.TotalBanwaves" from "TGE/GlobalStats.yml"
  379. if {_total} is not set:
  380. set {_total} to 0
  381. if {_bans} is not set:
  382. set {_bans} to 0
  383. if {_banwaves} is not set:
  384. set {_banwaves} to 0
  385. if {_nbanwaves} is not set:
  386. set {_nbanwaves} to 0
  387. message "%{@prefix}% Recorded Punishment Statistics:"
  388. message " &7Total Hackers Caught: &f%{_total}%"
  389. message " &7Total Hackers Banned: &f%{_bans}%"
  390. message " &7Total Hackers Banned by Banwaves: &f%{_banwaves}%"
  391. message " &7Total Banwaves: &f%{_nbanwaves}%"
  392. if arg 1 is "id":
  393. set {_valid} to yaml value "TGELog.%arg 2%.PreTouch" from "TGE/Punish-Logs/%arg 2%.yml"
  394. if {_valid} is not set:
  395. message "%{@prefix}% That's not a valid ID!"
  396. stop
  397. set {_id} to "%arg 2%"
  398. set {_reason} to yaml value "TGELog.%{_id}%.Reason" from "TGE/Punish-Logs/%{_id}%.yml"
  399. set {_time} to yaml value "TGELog.%{_id}%.Timestamp" from "TGE/Punish-Logs/%{_id}%.yml"
  400. set {_by} to yaml value "TGELog.%{_id}%.Punisher" from "TGE/Punish-Logs/%{_id}%.yml"
  401. set {_loc} to yaml value "TGELog.%{_id}%.Location" from "TGE/Punish-Logs/%{_id}%.yml"
  402. set {_data} to yaml value "TGELog.%{_id}%.Data" from "TGE/Punish-Logs/%{_id}%.yml"
  403. send "%{@prefix}% Data for Ban ID %arg 2%:"
  404. send "&7 Reason: &f%{_reason}%"
  405. send "&7 Timestamp: &f%{_time}%"
  406. send "&7 By: &f%{_by}%"
  407. send "&7 Location: &f%{_loc}%"
  408. if {_data} is set:
  409. send "&7 Data: &f%{_data}%"
  410. if arg 1 is "info":
  411. if arg 2 is set:
  412. if arg 3 is not set:
  413. set {_uuid} to yaml value "PlayerToUUID.%arg 2%" from "PlayerUUID.yml" #Global database of UUIDs
  414. if {_uuid} is not set:
  415. message "%{@prefix}% &cThat player was not found in our database!"
  416. stop
  417. set {_p} to yaml value "Userdata.%{_uuid}%.AntiCheat.Points" from "Userdata/%{_uuid}%.yml"
  418. set {_r} to yaml value "Userdata.%{_uuid}%.AntiCheat.BanReason" from "Userdata/%{_uuid}%.yml"
  419. set {_ib} to yaml value "Userdata.%{_uuid}%.Punish.Ban.IsBanned" from "Userdata/%{_uuid}%.yml"
  420. if arg 2 is online:
  421. send "%{@prefix}% &aONLINE - %arg 2%'s TGE Info"
  422. message "&7 Violation Count: &e%{_p}%"
  423. message "&7 Location: &e%location of arg 2% [%world of arg 2%]"
  424. message "&7 Gamemode: &e%gamemode of arg 2%"
  425. message "&7 Current UUID: &e%uuid of arg 2%"
  426. message "&7 Speed: &ewalk=%walkspeed of arg 2% fly=%flyspeed of arg 2%"
  427. message "&7 Health / Hunger: &e%health of arg 2%/10 &e%hunger of arg 2%/10"
  428. message "&7 Ping: &e%arg 2's ping%"
  429. if arg 2 is not online:
  430. send "%{@prefix}% &cOFFLINE - %arg 2%'s TGE Info"
  431. if {_p} is set:
  432. message "&7 Violation Count: &e%{_p}%"
  433. else:
  434. send "&7 Violation Count: &e0"
  435. if {_uuid} is set:
  436. message "&7 Saved UUID: &e%{_uuid}%"
  437. else:
  438. send "&7 Saved UUID: &cERROR: Couldn't find %arg 2%'s saved UUID."
  439. if {_r} is set:
  440. set {_id} to yaml value "BanWaveID.%{_uuid}%" from "TGE/BQData.yml"
  441. set {_reason} to yaml value "TGELog.%{_id}%.Reason" from "TGE/Punish-Logs/%{_id}%.yml"
  442. set {_time} to yaml value "TGELog.%{_id}%.Timestamp" from "TGE/Punish-Logs/%{_id}%.yml"
  443. set {_by} to yaml value "TGELog.%{_id}%.Punisher" from "TGE/Punish-Logs/%{_id}%.yml"
  444. set {_loc} to yaml value "TGELog.%{_id}%.Location" from "TGE/Punish-Logs/%{_id}%.yml"
  445. if {_ib} is true or "true":
  446. send "&7&l Banned by TGE: &f&l%{_reason}% [%{_id}%]"
  447. else:
  448. set {_bw::*} to yaml list "Banwaves" from "TGE/BanQueue.yml"
  449. if {_bw::*} contains "%{_uuid}%":
  450. set {_wr} to yaml value "Userdata.%{_uuid}%.AntiCheat.BanwaveReason" from "Userdata/%{_uuid}%.yml"
  451. send "&7&l To be banned by TGE: &f&l%{_reason}% [%{_id}%]"
  452. set {_nh::*} to yaml list "Userdata.%{_uuid}%.NameHistory" from "Userdata/%{_uuid}%.yml"
  453. set {_iph::*} to yaml list "Userdata.%{_uuid}%.IPHistory" from "Userdata/%{_uuid}%.yml"
  454. message "&7 Name History:"
  455. loop {_nh::*}:
  456. message "&7 - &e%loop-value%"
  457. message "&7 IP History:"
  458. loop {_iph::*}:
  459. message "&7 - &e%loop-value%"
  460. else if arg 3 is "clear":
  461. set {_t} to "%arg 2%" parsed as player
  462. if {_t} is online:
  463. set {_uuid} to uuid of {_t}
  464. else:
  465. set {_uuid} to yaml value "PlayerToUUID.%arg 2%" from "PlayerUUID.yml"
  466. if {_uuid} is not set:
  467. message "%{@prefix}% &cThat player was not found in our database!"
  468. stop
  469. set yaml value "Userdata.%{_uuid}%.AntiCheat.Points" from "Userdata/%{_uuid}%.yml" to 0
  470. delete yaml value "Userdata.%{_uuid}%.AntiCheat.BanReason" from "Userdata/%{_uuid}%.yml"
  471. set {_p} to yaml value "Userdata.%{_uuid}%.AntiCheat.Points" from "Userdata/%{_uuid}%.yml"
  472. if {_p} >= {@BanThreshold}:
  473. execute console command "unban %arg 2%"
  474. execute console command "unban %{_uuid}%"
  475. message "%{@prefix}% Logs of %arg 2% have been cleared."
  476. else:
  477. send "%{@prefix}% You must input a player name."
  478.  
  479.  
  480. if arg 1 is "wave":
  481. if {@Banwaves} is false or "false":
  482. if {@DubiousBanwave} is false or "false":
  483. message "%{@prefix}% Please enable Ban Waves in your config.yml before using this!"
  484. stop
  485. if arg 2 is not set:
  486. message "%{@prefix}% Manage Ban waves."
  487. message "&f/tge wave ban &7run ban wave"
  488. message "&f/tge wave list &7list ban wave queue"
  489. message "&f/tge wave count &7number of players waiting to be banned"
  490. message "&f/tge wave add [player] &7add a player to the queue"
  491. message "&f/tge wave remove [player] &7remove a player from the queue"
  492. message "&f/tge wave clear &7clear ban wave queue"
  493. stop
  494. if arg 2 is "ban":
  495. set {_err} to 0
  496. set {_c} to 0
  497. set {_ban_uuid::*} to yaml list "Banwaves" from "TGE/BanQueue.yml"
  498. loop {_ban_uuid::*}:
  499. set {__name} to yaml value "Userdata.%loop-value%.Name" from "Userdata/%loop-value%.yml"
  500. if {__name} is not set:
  501. add 1 to {_err}
  502. else:
  503. set {_wave::reasons::%{__name}%} to yaml value "Userdata.%loop-value%.AntiCheat.BanwaveReason" from "Userdata/%loop-value%.yml"
  504. add "%{__name}%" to {_ban::*}
  505. set {_banwaves} to yaml value "TGE.Data.TotalBanwaved" from "TGE/GlobalStats.yml"
  506. if {_banwaves} is not set:
  507. set {_banwaves} to 0
  508. broadcast "%{@prefix}% Running Ban Wave! All hackers will now be banned!"
  509. loop {_ban::*}:
  510. set {_u} to yaml value "PlayerToUUID.%loop-value%" from "PlayerUUID.yml"
  511. set {_id} to yaml value "BanWaveID.%{_u}%" from "TGE/BQData.yml"
  512. if {_id} is not set:
  513. set {_text_id} to "&oNo ID was associated with this ban."
  514. else:
  515. set {_text_id} to "Ban ID: %{_id}%"
  516. set {__reason} to {_wave::reasons::%loop-value%}
  517. if {__reason} is not set:
  518. set {__reason} to "&eHacking"
  519. execute console command "ban %loop-value% &a[Ban Wave] &e%{__reason}%%nl%&f%{_text_id}%"
  520. add 1 to {_c}
  521. add 1 to {_banwaves}
  522. delete {_id}
  523. delete {__reason}
  524. delete yaml list "Banwaves" from "TGE/BanQueue.yml"
  525. message "%{@prefix}% Ban Wave successful. %{_c}% players were banned. %{_err}% ban failures."
  526. set {_nbanwaves} to yaml value "TGE.Data.TotalBanwaves" from "TGE/GlobalStats.yml"
  527. if {_nbanwaves} is not set:
  528. set {_nbanwaves} to 0
  529. add 1 to {_nbanwaves}
  530. set yaml value "TGE.Data.TotalBanwaves" from "TGE/GlobalStats.yml" to {_nbanwaves}
  531. set yaml value "TGE.Data.TotalBanwaved" from "TGE/GlobalStats.yml" to {_banwaves}
  532. if arg 2 is "list":
  533. set {_err} to 0
  534. set {_c} to 0
  535. set {_ban_uuid::*} to yaml list "Banwaves" from "TGE/BanQueue.yml"
  536. loop {_ban_uuid::*}:
  537. set {__name} to yaml value "Userdata.%loop-value%.Name" from "Userdata/%loop-value%.yml"
  538. if {__name} is not set:
  539. add 1 to {_err}
  540. else:
  541. add "%{__name}%" to {_ban::*}
  542. if {_ban::*} is empty:
  543. message "%{@prefix}% Ban Wave queue is empty!"
  544. stop
  545. loop {_ban::*}:
  546. add 1 to {_c}
  547. message "%{@prefix}% %{_c}% Players waiting to be banned:"
  548. loop {_ban::*}:
  549. message "&f - %loop-value%"
  550. if arg 2 is "count":
  551. set {_c} to 0
  552. set {_ban_uuid::*} to yaml list "Banwaves" from "TGE/BanQueue.yml"
  553. loop {_ban_uuid::*}:
  554. add 1 to {_c}
  555. message "%{@prefix}% %{_c}% Players are waiting to be banned in the next Ban Wave."
  556. if arg 2 is "add":
  557. set {_uuid} to yaml value "PlayerToUUID.%arg 3%" from "PlayerUUID.yml"
  558. if {_uuid} is not set:
  559. message "%{@prefix}% &cThat player could not be found in our database! Try again."
  560. stop
  561. set {_ban_uuid::*} to yaml list "Banwaves" from "TGE/BanQueue.yml"
  562. if {_ban_uuid::*} contains "%{_uuid}%":
  563. message "%{@prefix}% That player is already waiting to be banned!"
  564. stop
  565. add "%{_uuid}%" to yaml list "Banwaves" from "TGE/BanQueue.yml"
  566. set yaml value "Userdata.%{_uuid}%.AntiCheat.BanwaveReason" from "Userdata/%{_uuid}%.yml" to "&eHacking"
  567. message "%{@prefix}% Added %arg 3% to Ban Wave queue."
  568. if arg 2 is "remove":
  569. set {_ban_uuid::*} to yaml list "Banwaves" from "TGE/BanQueue.yml"
  570. set {_uuid} to yaml value "PlayerToUUID.%arg 3%" from "PlayerUUID.yml"
  571. if {_uuid} is not set:
  572. message "%{@prefix}% &cThat player could not be found in our database! Try again."
  573. stop
  574. if {_ban_uuid::*} does not contain "%{_uuid}%":
  575. message "%{@prefix}% That player is not in the Ban Wave queue! &f/tge wave list"
  576. stop
  577. remove "%{_uuid}%" from yaml list "Banwaves" from "TGE/BanQueue.yml"
  578. message "%{@prefix}% Removed %arg 3% from Ban Wave queue."
  579. if arg 2 is "clear":
  580. delete yaml list "Banwaves" from "TGE/BanQueue.yml"
  581. message "%{@prefix}% Cleared Ban Wave queue."
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement