tamem313a

Untitled

Oct 15th, 2017
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 416.56 KB | None | 0 0
  1. on load:
  2. set {mineplex.starttime} to now
  3.  
  4. #(Old ugly acci text here)
  5. #
  6. #Mineplex Core Remake
  7. #The best and only Mineplex Copy
  8. #by Josh Roy (WheezyGold7931)
  9. #Enjoy!
  10. script options:
  11. $ use permissions
  12.  
  13. #! MCR Settings
  14.  
  15.  
  16. #! If you want to use MySQL features edit the details below
  17. script options:
  18. $ db url jdbc:mysql://<HOST>:3306/<DATABASE>
  19. $ db username <USERNAME>
  20. $ db password <PASSWORD>
  21.  
  22.  
  23. #! This value can be set to the following:
  24. #! "file": Stores the playerdata into files (Default)
  25. #! "sql": Stores the playerdata into a sql database (Details must be setup above)
  26. options:
  27. mode: file
  28.  
  29. #! These are internal settings, it is not recomended that you mess with them as they WILL mess up the plugin!
  30. options:
  31. MCRVER: 2.9
  32. MCRHOTFIX: 0
  33. configver: shamu
  34. playerdata: 3
  35.  
  36. #! json.sk code DO NOT MESS WITH THIS! !(Rezz ily)!
  37. options:
  38. debug: false
  39. codes: 0|1|2|3|4|5|6|7|8|9|a|b|c|d|e|f|k|l|m|n|o|r
  40.  
  41. function mcrremoveColor(msg: text) :: text:
  42. set {_m::*} to {_msg} split at ""
  43.  
  44. set {_color-codes} to "{@codes}"
  45. set {_colors::*} to {_color-codes} split at "|"
  46.  
  47. set {_new} to ""
  48.  
  49. loop {_m::*}:
  50. set {_char} to loop-value
  51. set {_prev} to the last character of {_new}
  52.  
  53. if {_prev} is "&":
  54.  
  55. loop {_colors::*}:
  56.  
  57. if loop-value-2 is {_char}:
  58. set {_skip} to true
  59.  
  60. if {_skip} is set:
  61. delete {_skip}
  62.  
  63. else:
  64. set {_new} to "%{_new}%%{_char}%"
  65.  
  66. return {_new}
  67.  
  68. function mcrjsonColorize(msg: text, default-color: text = "&r") :: text:
  69. set {_m::*} to {_msg} split at ""
  70.  
  71. set {_color-codes} to "{@codes}"
  72. set {_colors::*} to {_color-codes} split at "|"
  73.  
  74. set {_color} to colored {_default-color}
  75. set {_code} to the first character of {_color}
  76.  
  77. set {_new} to ""
  78. set {_skip} to 0
  79.  
  80. loop amount of {_m::*} times:
  81.  
  82. if {_skip} is more than or equal to 1:
  83. subtract 1 from {_skip}
  84.  
  85. else:
  86. set {_char} to {_m::%loop-number%}
  87. set {_next} to {_m::%loop-number + 1%}
  88.  
  89. if {@debug} is true:
  90. broadcast "&a[Character Check] &r%loop-number%: &7%{_char}% &r&onext: &8%{_next}% &r[%{_color}%color&r]"
  91.  
  92. if {_char} is "&" or {_code}:
  93.  
  94. if {@debug} is true:
  95. broadcast "&a[Color Check] &rFOUND: &o%{_char}%%{_next}% &7&m<--&7&o is it valid?"
  96.  
  97. loop {_colors::*}:
  98.  
  99. if loop-value-2 is {_next}:
  100. set {_color} to "%{_color}%%{_code}%%{_next}%"
  101.  
  102. if {_next} is "r":
  103. set {_color} to {_default-color}
  104.  
  105. set {_new} to "%{_new}%%{_color}%"
  106. set {_skip} to 1
  107.  
  108. if {_skip} is less than or equal to 0:
  109. set {_new} to "%{_new}%%{_char}%"
  110.  
  111. else if {_char} is " ":
  112. set {_new} to "%{_new}% %{_color}%"
  113.  
  114. else:
  115. set {_new} to "%{_new}%%{_char}%"
  116.  
  117. return {_new}
  118.  
  119. function mcrjsonSanitize(msg: text) :: text:
  120. if {@debug} is true:
  121. broadcast "&a[Sanitize] &7&oSanitizing input..."
  122.  
  123. set {_m::*} to {_msg} split at ""
  124.  
  125. loop {_m::*}:
  126.  
  127. if loop-value is """":
  128. set {_m::%loop-index%} to "\""" # """
  129.  
  130. else if loop-value is "\":
  131. set {_m::%loop-index%} to "\\"
  132.  
  133. set {_new} to join {_m::*} with ""
  134. return {_new}
  135.  
  136. function mcrjsonFormat(msg: text, color: boolean = true) :: text:
  137. set {_m::*} to {_msg} split at "||"
  138.  
  139. set {_current} to 1
  140.  
  141. loop {_m::*}:
  142. if {_clusters::%{_current}%} is not set:
  143. set {_clusters::%{_current}%} to ""
  144.  
  145. if {_clusters::%{_current}%::text} is not set:
  146. set {_clusters::%{_current}%::text} to mcrjsonSanitize(loop-value)
  147.  
  148. else:
  149. set {_tag} to the first 4 characters of loop-value
  150. set {_value} to subtext of loop-value from characters 5 to the length of loop-value
  151.  
  152. if {_tag} is "ttp:":
  153. set {_clusters::%{_current}%::tooltip} to mcrjsonSanitize({_value})
  154.  
  155. else if {_tag} is "cmd:":
  156. set {_clusters::%{_current}%::command} to mcrjsonSanitize({_value})
  157.  
  158. else if {_tag} is "sgt:":
  159. set {_clusters::%{_current}%::suggest} to mcrjsonSanitize({_value})
  160.  
  161. else if {_tag} is "url:":
  162.  
  163. if {_value} doesn't contain "http://" or "https://":
  164. set {_value} to "http://%{_value}%"
  165.  
  166. set {_clusters::%{_current}%::url} to mcrjsonSanitize({_value})
  167.  
  168. else if {_tag} is "ins:":
  169. set {_clusters::%{_current}%::insertion} to mcrjsonSanitize({_value})
  170.  
  171. else:
  172. add 1 to {_current}
  173. set {_clusters::%{_current}%::text} to mcrjsonSanitize(loop-value)
  174. set {_clusters::%{_current}%} to ""
  175.  
  176. if {@debug} is true:
  177. broadcast "&a[Tag Check] &3cluster:&b%{_current}% &8(&f&o%{_tag}%&8)"
  178.  
  179. loop {_clusters::*}:
  180.  
  181. if {@debug} is true:
  182. broadcast "&a[Cluster Check] &7&oCluster ##%loop-index% exists."
  183.  
  184. set {_i} to loop-index
  185.  
  186. set {_text} to {_clusters::%{_i}%::text}
  187.  
  188. if {_color} is true:
  189. set {_text} to mcrjsonColorize({_text})
  190.  
  191. if {_json} is not set:
  192. set {_json} to "{""text"":""%{_text}%"""
  193. else:
  194. set {_json} to "%{_json}%,{""text"":""%{_text}%"""
  195.  
  196. if {_clusters::%{_i}%::tooltip} is set:
  197.  
  198. if {_color} is true:
  199. set {_tooltip} to mcrjsonColorize({_clusters::%{_i}%::tooltip})
  200.  
  201. else:
  202. set {_tooltip} to {_clusters::%{_i}%::tooltip}
  203.  
  204. set {_json} to "%{_json}%,""hoverEvent"":{""action"": ""show_text"",""value"": ""%{_tooltip}%""}"
  205.  
  206. if {_clusters::%{_i}%::insertion} is set:
  207. set {_json} to "%{_json}%,""insertion"":""%{_clusters::%{_i}%::insertion}%"",""obfuscated"":false"
  208.  
  209. if {_clusters::%{_i}%::command} is set:
  210. set {_clickable} to "%{_json}%,""clickEvent"":{""action"":""run_command"",""value"":""%{_clusters::%{_i}%::command}%""}"
  211.  
  212. if {_clusters::%{_i}%::suggest} is set:
  213. set {_clickable} to "%{_json}%,""clickEvent"":{""action"": ""suggest_command"",""value"": ""%{_clusters::%{_i}%::suggest}%""}"
  214.  
  215. if {_clusters::%{_i}%::url} is set:
  216. set {_clickable} to "%{_json}%,""clickEvent"":{""action"": ""open_url"",""value"": ""%{_clusters::%{_i}%::url}%""}"
  217.  
  218. if {_clickable} is set:
  219. set {_json} to "%{_clickable}%}"
  220. delete {_clickable}
  221.  
  222. else:
  223. set {_json} to "%{_json}%}"
  224.  
  225. return "{""text"":"""", ""extra"":[%{_json}%]}"
  226.  
  227. function mcrjson(to: text, msg: text, color: boolean = true):
  228. set {_msg} to mcrjsonFormat({_msg}, {_color})
  229. execute console command "/tellraw %{_to}% %{_msg}%"
  230.  
  231. if {@debug} is true:
  232. set {_player} to {_to} parsed as offline player
  233. if {_player} is online:
  234. send uncolored {_msg} to {_player}
  235.  
  236. function mcrjsonBroadcast(msg: text, color: boolean = true):
  237. mcrjson("@a", {_msg}, {_color})
  238.  
  239. #MCR Code
  240. #MCR Code
  241. #MCR Code
  242. #MCR Code
  243. #MCR Code
  244. #MCR Code
  245. #MCR Code
  246.  
  247. on load: #You cannot trust people to enter the correct thing so lets double check for them :)
  248. if "{@mode}" is "file":
  249. set {mineplex.mode} to "file"
  250. send "§9MCR> §eMCR has been set to store playerdata into files!" to the console
  251. else if "{@mode}" is "sql":
  252. set {mineplex.mode} to "sql"
  253. send "§9MCR> §eMCR has been set to store playerdata into SQL!" to the console
  254. send "§9MCR> §eThey better have setup the database correctly" to the console
  255. else:
  256. set {mineplex.mode} to "file"
  257. send "§9MCR> §eMCR has been set to store playerdata into files!" to the console
  258.  
  259. on load:
  260. if {mineplex.mode} is "sql":
  261. update "CREATE TABLE IF NOT EXISTS `accounts` ( `id` INT NULL DEFAULT NULL AUTO_INCREMENT , `name` VARCHAR(40) NOT NULL , `uuid` VARCHAR(100) NOT NULL , `rank` VARCHAR(20) NOT NULL DEFAULT 'All' , `level` INT(20) NOT NULL DEFAULT '0' , `gems` INT(20) NOT NULL DEFAULT '0' , `shards` INT(20) NOT NULL DEFAULT '0' , `banned` VARCHAR(20) NOT NULL DEFAULT 'no' , `muted` VARCHAR(20) NOT NULL DEFAULT 'no' , UNIQUE (`id`)) ENGINE = InnoDB;"
  262. update "CREATE TABLE IF NOT EXISTS `newslist` ( `id` INT(11) NOT NULL AUTO_INCREMENT , `newsString` VARCHAR(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL , `newsPosition` VARCHAR(11) NULL DEFAULT NULL , UNIQUE (`id`)) ENGINE = InnoDB;"
  263.  
  264. command /getu [<string>]:
  265. trigger:
  266. set {_p} to player
  267. set {_get} to first element out of objects in column "%arg-1%" from result of query "SELECT %arg-1% FROM `accounts` WHERE uuid = '%uuid of {_p}%'"
  268. send "&a||&b%{_get}%&a||"
  269.  
  270. function parseRank(p: player , r: text) :: string:
  271. set {_uuid} to uuid of {_p}
  272. if {mineplex.mode} is "file":
  273. set {_get} to value "rank" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  274. if {mineplex.mode} is "sql":
  275. set {_get} to first element out of objects in column "rank" from result of query "SELECT rank FROM `accounts` WHERE uuid = '%uuid of {_p}%'"
  276. if {_get} is "All":
  277. set {mineplex.rank.%{_p}%} to ""
  278. return "&fPlayer"
  279. if {_get} is "Ultra":
  280. set {mineplex.rank.%{_p}%} to "&b&lULTRA "
  281. return "&bUltra"
  282. if {_get} is "Hero":
  283. set {mineplex.rank.%{_p}%} to "&d&lHERO "
  284. return "&dHero"
  285. if {_get} is "Legend":
  286. set {mineplex.rank.%{_p}%} to "&a&lLEGEND "
  287. return "&aLegend"
  288. if {_get} is "Titan":
  289. set {mineplex.rank.%{_p}%} to "&c&lTITAN "
  290. return "&cTitan"
  291. if {_get} is "Trainee":
  292. set {mineplex.rank.%{_p}%} to "&6&lTRAINEE "
  293. return "&6Trainee"
  294. if {_get} is "Mod":
  295. set {mineplex.rank.%{_p}%} to "&6&lMOD "
  296. return "&6Mod"
  297. if {_get} is "SrMod":
  298. set {mineplex.rank.%{_p}%} to "&6&lSR.MOD "
  299. return "&6Sr.Mod"
  300. if {_get} is "CMod":
  301. set {mineplex.rank.%{_p}%} to "&6&lC.MOD "
  302. return "&6C.Mod"
  303. if {_get} is "Admin":
  304. set {mineplex.rank.%{_p}%} to "&4&lADMIN "
  305. return "&4Admin"
  306. if {_get} is "Apex":
  307. set {mineplex.rank.%{_p}%} to "&9&lAPEX "
  308. return "&9Apex"
  309. if {_get} is "Leader":
  310. set {mineplex.rank.%{_p}%} to "&4&lLEADER "
  311. return "&4Leader"
  312. if {_get} is "Owner":
  313. set {mineplex.rank.%{_p}%} to "&4&lOWNER "
  314. return "&4Owner"
  315. if {_get} is "Builder":
  316. set {mineplex.rank.%{_p}%} to "&9&lBUILDER "
  317. return "&9Builder"
  318. if {_get} is "Maplead":
  319. set {mineplex.rank.%{_p}%} to "&9&lMAPLEAD "
  320. return "&9Maplead"
  321. if {_get} is "Mapper":
  322. set {mineplex.rank.%{_p}%} to "&9&lMAPPER "
  323. return "&9Mapper"
  324. if {_get} is "JrDev":
  325. set {mineplex.rank.%{_p}%} to "&6&lJR.DEV "
  326. return "&6Jr.Dev"
  327. if {_get} is "Dev":
  328. set {mineplex.rank.%{_p}%} to "&4&lDEV "
  329. return "&4Dev"
  330. if {_get} is "Twitch":
  331. set {mineplex.rank.%{_p}%} to "&5&lTWITCH "
  332. return "&5Twitch"
  333. if {_get} is "Youtube":
  334. set {mineplex.rank.%{_p}%} to "&c&lYOUTUBE "
  335. return "&cYouTube"
  336. if {_get} is "Event":
  337. set {mineplex.rank.%{_p}%} to "&f&lEVENT "
  338. return "&fEvent"
  339. if {_get} is "Yt":
  340. set {mineplex.rank.%{_p}%} to "&5&lYT "
  341. return "&5YT"
  342. if {_get} is "Eternal":
  343. set {mineplex.rank.%{_p}%} to "&3&lETERNAL "
  344. return "&3Eternal"
  345. if {_get} is "Support":
  346. set {mineplex.rank.%{_p}%} to "&9&lSUPPORT "
  347. return "&9Support"
  348. if {_get} is "Artist":
  349. set {mineplex.rank.%{_p}%} to "&9&lARTIST "
  350. return "&9Artist"
  351.  
  352. function parseRankRaw(r: text) :: string:
  353. set {_get} to {_r}
  354. if {_get} is "All":
  355. set {_rank} to ""
  356. if {_get} is "Ultra":
  357. set {_rank} to "&b&lULTRA "
  358. if {_get} is "Hero":
  359. set {_rank} to "&d&lHERO "
  360. if {_get} is "Legend":
  361. set {_rank} to "&a&lLEGEND "
  362. if {_get} is "Titan":
  363. set {_rank} to "&c&lTITAN "
  364. if {_get} is "Trainee":
  365. set {_rank} to "&6&lTRAINEE "
  366. if {_get} is "Mod":
  367. set {_rank} to "&6&lMOD "
  368. if {_get} is "SrMod":
  369. set {_rank} to "&6&lSR.MOD "
  370. if {_get} is "CMod":
  371. set {_rank} to "&6&lC.MOD "
  372. if {_get} is "Admin":
  373. set {_rank} to "&4&lADMIN "
  374. if {_get} is "Apex":
  375. set {_rank} to "&9&lAPEX "
  376. if {_get} is "Leader":
  377. set {_rank} to "&4&lLEADER "
  378. if {_get} is "Owner":
  379. set {_rank} to "&4&lOWNER "
  380. if {_get} is "Builder":
  381. set {_rank} to "&9&lBUILDER "
  382. if {_get} is "Maplead":
  383. set {_rank} to "&9&lMAPLEAD "
  384. if {_get} is "Mapper":
  385. set {_rank} to "&9&lMAPPER "
  386. if {_get} is "JrDev":
  387. set {_rank} to "&6&lJR.DEV "
  388. if {_get} is "Dev":
  389. set {_rank} to "&4&lDEV "
  390. if {_get} is "Twitch":
  391. set {_rank} to "&5&lTWITCH "
  392. if {_get} is "Youtube":
  393. set {_rank} to "&c&lYOUTUBE "
  394. if {_get} is "Event":
  395. set {_rank} to "&f&lEVENT "
  396. if {_get} is "Yt":
  397. set {_rank} to "&5&lYT "
  398. if {_get} is "Eternal":
  399. set {_rank} to "&3&lETERNAL "
  400. if {_get} is "Support":
  401. set {_rank} to "&9&lSUPPORT "
  402. if {_get} is "Artist":
  403. set {_rank} to "&9&lARTIST "
  404. if {_rank} is set:
  405. return {_rank}
  406. else:
  407. return "null"
  408.  
  409. function playerdata(p: offline player) :: boolean:
  410. set {_uuid} to uuid of {_p}
  411. if {mineplex.mode} is "file":
  412. if file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml" doesn't exists:
  413. create file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  414. set "version" to "{@playerdata}" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  415. set "player" to "%{_p}%" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  416. set "rank" to "All" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  417. set "level" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  418. set "gems" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  419. set "shards" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  420. set "banned" to "no" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  421. set "muted" to "no" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  422. set "stats.global.gems" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  423. set "stats.global.games" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  424. set "stats.global.dailyr" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  425. set "stats.global.voted" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  426. set "stats.global.chests" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  427. else:
  428. set {_ver} to value "version" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  429. if {_ver} is not "{@playerdata}":
  430. if {_ver} is "1":
  431. set "stats.global.gems" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  432. set "stats.global.games" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  433. set "stats.global.dailyr" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  434. set "stats.global.voted" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  435. set "stats.global.chests" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  436. set "version" to "{@playerdata}" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  437. send "&9MCR> &7Your playdata has been updated to the latest version!" to {_p}
  438. if {_ver} is "2":
  439. set "stats.global.gems" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  440. set "stats.global.games" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  441. set "stats.global.dailyr" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  442. set "stats.global.voted" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  443. set "stats.global.chests" to "0" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  444. set "version" to "{@playerdata}" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  445. send "&9MCR> &7Your playdata has been updated to the latest version!" to {_p}
  446. set "player" to "%{_p}%" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  447. set {_get} to value "rank" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  448. parseRank({_p}, "LOL")
  449. set {_lvl} to value "level" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  450. execute console command "/givestat %{_p}% Global.ExpEarned %{_lvl}%"
  451. set {_sh} to value "shards" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  452. set {mineplex.shards.%{_p}%} to {_sh} parsed as an number
  453. set {_ge} to value "gems" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  454. set {mineplex.gems.%{_p}%} to {_ge} parsed as an number
  455. set {_ban} to value "banned" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  456. if {_ban} is "yes":
  457. set {banned::%{_p}%} to true
  458. else:
  459. set {banned::%{_p}%} to false
  460. set {_mute} to value "muted" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  461. if {_mute} is "yes":
  462. set {muted::%{_p}%} to true
  463. else:
  464. set {muted::%{_p}%} to false
  465. else if {mineplex.mode} is "sql":
  466. set {_getuuid} to first element out of objects in column "uuid" from result of query "SELECT uuid FROM `accounts` WHERE uuid = '%{_uuid}%'"
  467. if {_getuuid} is not set:
  468. update "INSERT INTO `accounts` (`uuid`, `name`) VALUES ('%{_uuid}%', '%{_p}%')"
  469. parseRank({_p}, "LOL")
  470. set {_lvl} to first element out of objects in column "level" from result of query "SELECT level FROM `accounts` WHERE uuid = '%{_uuid}%'"
  471. execute console command "/givestat %{_p}% Global.ExpEarned %{_lvl}%"
  472. set {_sh} to first element out of objects in column "shards" from result of query "SELECT shards FROM `accounts` WHERE uuid = '%{_uuid}%'"
  473. set {mineplex.shards.%{_p}%} to {_sh}
  474. set {_ge} to first element out of objects in column "gems" from result of query "SELECT gems FROM `accounts` WHERE uuid = '%{_uuid}%'"
  475. set {mineplex.gems.%{_p}%} to {_ge}
  476. set {_ban} to first element out of objects in column "banned" from result of query "SELECT banned FROM `accounts` WHERE uuid = '%{_uuid}%'"
  477. if {_ban} is "yes":
  478. set {banned::%{_p}%} to true
  479. else:
  480. set {banned::%{_p}%} to false
  481. set {_mute} to first element out of objects in column "muted" from result of query "SELECT muted FROM `accounts` WHERE uuid = '%{_uuid}%'"
  482. if {_mute} is "yes":
  483. set {muted::%{_p}%} to true
  484. else:
  485. set {muted::%{_p}%} to false
  486.  
  487. function getPlayerdata(p: offline player , f: text) :: string:
  488. set {_uuid} to uuid of {_p}
  489. if {mineplex.mode} is "file":
  490. set {_get} to value "%{_f}%" get of "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  491. return {_get}
  492. else if {mineplex.mode} is "sql":
  493. set {_get} to first element out of objects in column "%{_f}%" from result of query "SELECT %{_f}% FROM `accounts` WHERE uuid = '%{_uuid}%'"
  494. return {_get}
  495.  
  496. function setPlayerdata(p: offline player , f: text , v: text) :: boolean:
  497. set {_uuid} to uuid of {_p}
  498. if {mineplex.mode} is "file":
  499. set "%{_f}%" to "%{_v}%" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  500. return true
  501. playerdata({_p})
  502. else if {mineplex.mode} is "sql":
  503. update "UPDATE `accounts` SET `%{_f}%` = '%{_v}%' WHERE uuid = '%{_uuid}%'"
  504. return true
  505. set {_s} to getPlayerdata({_p}, "shards")
  506. set {_g} to getPlayerdata({_p}, "gems")
  507. broadcast "shard: %{_s}% -gem: %{_g}%"
  508. playerdata({_p})
  509.  
  510. function addShards(p: offline player , a: number) :: boolean:
  511. set {_uuid} to uuid of {_p}
  512. if {mineplex.mode} is "file":
  513. set {_get} to getPlayerdata({_p}, "shards")
  514. set {_cur} to {_get} parsed as a number
  515. add {_a} to {_cur}
  516. setPlayerdata({_p}, "shards", "%{_cur}%")
  517. else if {mineplex.mode} is "sql":
  518. set {_get} to first element out of objects in column "shards" from result of query "SELECT shards FROM `accounts` WHERE uuid = '%{_uuid}%'"
  519. add {_a} to {_get}
  520. setPlayerdata({_p}, "shards", "%{_get}%")
  521.  
  522. function delShards(p: offline player , a: number) :: boolean:
  523. set {_uuid} to uuid of {_p}
  524. if {mineplex.mode} is "file":
  525. set {_get} to getPlayerdata({_p}, "shards")
  526. set {_cur} to {_get} parsed as a number
  527. remove {_a} from {_cur}
  528. setPlayerdata({_p}, "shards", "%{_cur}%")
  529. else if {mineplex.mode} is "sql":
  530. set {_get} to first element out of objects in column "shards" from result of query "SELECT shards FROM `accounts` WHERE uuid = '%{_uuid}%'"
  531. remove {_a} from {_get}
  532. setPlayerdata({_p}, "shards", "%{_get}%")
  533.  
  534. function addGems(p: offline player , a: number) :: boolean:
  535. set {_uuid} to uuid of {_p}
  536. if {mineplex.mode} is "file":
  537. set {_get} to getPlayerdata({_p}, "gems")
  538. set {_cur} to {_get} parsed as a number
  539. add {_a} to {_cur}
  540. setPlayerdata({_p}, "gems", "%{_cur}%")
  541. else if {mineplex.mode} is "sql":
  542. set {_get} to first element out of objects in column "gems" from result of query "SELECT gems FROM `accounts` WHERE uuid = '%{_uuid}%'"
  543. add {_a} to {_get}
  544. setPlayerdata({_p}, "gems", "%{_get}%")
  545.  
  546. function delGems(p: offline player , a: number) :: boolean:
  547. set {_uuid} to uuid of {_p}
  548. if {mineplex.mode} is "file":
  549. set {_get} to getPlayerdata({_p}, "gems")
  550. set {_cur} to {_get} parsed as a number
  551. remove {_a} from {_cur}
  552. setPlayerdata({_p}, "gems", "%{_cur}%")
  553. else if {mineplex.mode} is "sql":
  554. set {_get} to first element out of objects in column "gems" from result of query "SELECT gems FROM `accounts` WHERE uuid = '%{_uuid}%'"
  555. remove {_a} from {_get}
  556. setPlayerdata({_p}, "gems", "%{_get}%")
  557.  
  558. on quit:
  559. delete {mineplex.rank.%player%}
  560. delete {mineplex.level.%player%}
  561. delete {mineplex.gems.%player%}
  562. delete {mineplex.shards.%player%}
  563. delete {banned::%player%}
  564. delete {muted::%player%}
  565.  
  566. on connect:
  567. set {_uuid} to uuid of {_p}
  568. playerdata(player)
  569. send "§9MCR> §e%player% (%uuid of player%) has been loaded from playerdata!" to the console
  570.  
  571. function Beam(e1: entity , e2: entity):
  572. spawn a squid at location 0 meter behind {_e1}'s head
  573. set {_el} to last spawned entity
  574. set target of {_el} to {_e2}
  575. apply invisibility to the last spawned entity
  576. add "{CustomName:""BeamGuar"", NoGravity:1, Silent:1, NoAI:1}" to nbt of last spawned entity
  577. set {_targLoc} to location of {_e2}
  578.  
  579. loop 100 times:
  580. teleport {_el} to location 0 meter behind {_e1}'s head
  581. set target of {_el} to {_e2}
  582. add "{Motion:[0.0,0.0,0.0]}" to nbt of {_el}
  583. if "%{_e2}'s name%" is "BeamCow":
  584. teleport {_e2} to {_targLoc}
  585. add "{Motion:[0.0,0.0,0.0]}" to nbt of {_e2}
  586. wait 1 tick
  587.  
  588. create a safe explosion with force 2 at {_e1}
  589. loop entities in radius 3 of {_e2}:
  590. make {_e1} damage loop-entity by (3 - (distance between loop-entity and {_e2}))
  591. teleport {_el} 300 blocks below {_el}
  592. teleport {_e2} 300 blocks below {_e2}
  593. kill {_el}
  594. kill {_e2}
  595.  
  596. function ClientBeam(e1: entity , e3: entity , e2: entity):
  597. spawn a cow at location of {_e2}
  598. set {_c} to last spawned entity
  599. add "{CustomName:""BeamCow"", NoGravity:1, Silent:1}" to nbt of last spawned entity
  600. spawn a guardian at location 1 meter behind {_e1}'s head
  601. set {_el} to last spawned entity
  602. set target of {_el} to {_e2}
  603. loop all players:
  604. protocol hide {_e1} from loop-player
  605. protocol hide {_e2} from loop-player
  606. protocol show {_e1} to {_e3}
  607. protocol show {_e2} to {_e3}
  608. apply invisibility to {_c}
  609. apply invisibility to the last spawned entity
  610. add "{CustomName:""BeamGuar"", NoGravity:1, Silent:1}" to nbt of last spawned entity
  611. set {_targLoc} to location of {_e2}
  612.  
  613. loop 100 times:
  614. teleport {_el} to location 1 meter behind {_e1}'s head
  615. add "{Motion:[0.0,0.0,0.0]}" to nbt of {_el}
  616. if "%{_e2}'s name%" is "BeamCow":
  617. teleport {_e2} to {_targLoc}
  618. add "{Motion:[0.0,0.0,0.0]}" to nbt of {_e2}
  619. wait 1 tick
  620.  
  621. create a safe explosion with force 2 at {_e2}
  622. loop entities in radius 3 of {_c}:
  623. make {_e1} damage loop-entity by (3 - (distance between loop-entity and {_c}))
  624. teleport {_el} 300 blocks below {_el}
  625. teleport {_e2} 300 blocks below {_e2}
  626. kill {_el}
  627. kill {_c}
  628.  
  629. function configRefresh(n: number) :: number:
  630. set {mineplex.config.config} to value "config" get of "plugins/Mineplex-Core-Remake/config.yml"
  631. set {mineplex.config.servername} to value "servername" get of "plugins/Mineplex-Core-Remake/config.yml"
  632. set {mineplex.config.website} to value "website" get of "plugins/Mineplex-Core-Remake/config.yml"
  633. set {mineplex.config.appealwebsite} to value "appealwebsite" get of "plugins/Mineplex-Core-Remake/config.yml"
  634. set {mineplex.config.ruleswebsite} to value "ruleswebsite" get of "plugins/Mineplex-Core-Remake/config.yml"
  635. set {mineplex.config.youtube} to value "youtube" get of "plugins/Mineplex-Core-Remake/config.yml"
  636. set {mineplex.config.twitter} to value "twitter" get of "plugins/Mineplex-Core-Remake/config.yml"
  637. set {mineplex.config.shoplink} to value "shoplink" get of "plugins/Mineplex-Core-Remake/config.yml"
  638. set {mineplex.config.world} to value "worldname" get of "plugins/Mineplex-Core-Remake/config.yml"
  639. set {mineplex.config.doublejump} to value "doublejump" get of "plugins/Mineplex-Core-Remake/config.yml"
  640. set {mineplex.config.autoop} to value "autoop" get of "plugins/Mineplex-Core-Remake/config.yml"
  641. set {mineplex.config.unbanadmin} to value "unbanadmin" get of "plugins/Mineplex-Core-Remake/config.yml"
  642.  
  643. function configPopulate(n: number) :: number:
  644. create file "plugins/Mineplex-Core-Remake/config.yml"
  645. set "config" to "{@configver}" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  646. set "servername" to "Mineplex" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  647. set "website" to "www.mineplex.com" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  648. set "appealwebsite" to "www.mineplex.com/appeals" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  649. set "ruleswebsite" to "www.mineplex.com/rules" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  650. set "youtube" to "http://youtube.com/mineplexgamesofficial" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  651. set "twitter" to "http://twitter.com/mineplex" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  652. set "shoplink" to "www.mineplex.com/shop" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  653. set "worldname" to "world" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  654. set "doublejump" to "true" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  655. set "autoop" to "false" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  656. set "unbanadmin" to "false" in yaml file "plugins/Mineplex-Core-Remake/config.yml"
  657.  
  658. function updateRankAPI(p: player) :: player:
  659. wait 5 ticks
  660. if {mineplex.rank.%{_p}%} is not set:
  661. set {mineplex.rank.%{_p}%} to ""
  662. if {mineplex.disguise.%{_p}%} is set:
  663. set {_br} to uncolored {mineplex.rank.%{_p}%}
  664. set {_dr} to uncolored {mineplex.rank.%{mineplex.disguise.%{_p}%}%}
  665. if {mineplex.rank.%{mineplex.disguise.%{_p}%}%} is set:
  666. make all players see {_p}'s prefix as "%{mineplex.rank.%{mineplex.disguise.%{_p}%}%}%&r&e"
  667. else:
  668. make all players see {_p}'s prefix as "&e"
  669. set {_br} to convert string "%{_br}%" to lowercase
  670. set {_br} to 1st char in each word of "%{_br}%" to caps
  671. set {_dr} to convert string "%{_dr}%" to lowercase
  672. set {_dr} to 1st char in each word of "%{_dr}%" to caps
  673. replace all " " in {_br} with ""
  674. replace all " " in {_dr} with ""
  675. if {_dr} is "":
  676. set {_dr} to "No Rank"
  677. if {_br} contains "mod":
  678. replace all "mod" with "Mod" in {_br}
  679. if {_dr} contains "mod":
  680. replace all "mod" with "Mod" in {_dr}
  681. if {_br} contains "dev":
  682. replace all "dev" with "Dev" in {_br}
  683. if {_dr} contains "dev":
  684. replace all "dev" with "Dev" in {_dr}
  685. if {_dr} contains "lead":
  686. replace all "lead" with "Lead" in {_dr}
  687. if {_br} contains "lead":
  688. replace all "lead" with "Lead" in {_br}
  689. if {_br} is "":
  690. set {_br} to "No Rank"
  691. if {_br} contains "mod":
  692. replace all "mod" with "Mod" in {_br}
  693. if {_br} contains "dev":
  694. replace all "dev" with "Dev" in {_br}
  695. if {_br} contains "mod":
  696. replace all "mod" with "Mod" in {_br}
  697. if {_br} contains "tube":
  698. replace all "tube" with "Tube" in {_br}
  699. loop {mineplex.patreon::*}:
  700. if loop-value is "%{_p}%":
  701. set {_br} to "P.%{_br}%"
  702. set {mineplex.api.displayrank.%{_p}%} to "%{_dr}% (%{_br}%)"
  703. set {mineplex.api.displayname.%{_p}%} to "%{mineplex.disguise.%{_p}%}%"
  704. else:
  705. set {_br} to uncolored {mineplex.rank.%{_p}%}
  706. if {mineplex.rank.%{_p}%} is set:
  707. make all players see {_p}'s prefix as "%{mineplex.rank.%{_p}%}%&r&e"
  708. else:
  709. make all players see {_p}'s prefix as "&e"
  710. set {_br} to convert string "%{_br}%" to lowercase
  711. set {_br} to 1st char in each word of "%{_br}%" to caps
  712. if {_br} is "":
  713. set {_br} to "No Rank"
  714. if {_br} contains "mod":
  715. replace all "mod" with "Mod" in {_br}
  716. if {_br} contains "dev":
  717. replace all "dev" with "Dev" in {_br}
  718. if {_br} contains "mod":
  719. replace all "mod" with "Mod" in {_br}
  720. if {_br} contains "tube":
  721. replace all "tube" with "Tube" in {_br}
  722. if {_br} contains "lead":
  723. replace all "lead" with "Lead" in {_br}
  724. if {_br} contains "dev":
  725. replace all "dev" with "Dev" in {_br}
  726. loop {mineplex.patreon::*}:
  727. if loop-value is "%{_p}%":
  728. set {_br} to "P.%{_br}%"
  729. set {mineplex.api.displayrank.%{_p}%} to "%{_br}%"
  730. set {mineplex.api.displayname.%{_p}%} to "%{_p}%"
  731.  
  732. function mcs(p: player , m: text) :: number:
  733. if {mineplex.overridechat} is true:
  734. if {mineplex.disguise.%{_p}%} is set:
  735. set {_player} to {mineplex.disguise.%{_p}%}
  736. else:
  737. set {_player} to {_p}
  738. set {_prerank} to getPlayerdata({_player}, "rank")
  739. set {_rank} to parseRankRaw({_prerank})
  740. if {_rank} is not set:
  741. set {_rank} to ""
  742. if {_rank} is "null":
  743. set {_rank} to ""
  744. if {mineplex.level.%{_player}%} is not set:
  745. set {mineplex.level.%{_player}%} to "&70"
  746. replace all " fuck " with " **** " in {_m}
  747. replace all " bitch " with " ***** " in {_m}
  748. replace all " ass " with " *** " in {_m}
  749. replace all " nigger " with " *** " in {_m}
  750. replace all " cunt " with " *** " in {_m}
  751. replace all " f|_|ck " with " ****** " in {_m}
  752. replace all " shit " with " **** " in {_m}
  753. if {_m} is {mineplex.lastsent.%{_p}%}:
  754. if {_p} does not have permission "mineplex.mod":
  755. send "&9Chat> &7This message is too similar to your previous message." to {_p}
  756. return -1
  757. stop
  758. if {mineplex.authlock.%{_p}%} is true:
  759. return -1
  760. stop
  761. set {mineplex.lastsent.%{_p}%} to {_m}
  762. loop all players:
  763. if {mineplex.pref.pc.%loop-player%} is true:
  764. if {mineplex.rank.%{_player}%} is set:
  765. set {_lvl} to {mineplex.level.%{_player}%}
  766. if {_player} is "WheezyGold7931":
  767. set {_lvl} to "&c101"
  768. loop {mineplex.ignorelist.%loop-player%::*}:
  769. if loop-value-2 is "%{_player}%":
  770. set {_ignore.%loop-player-1%} to true
  771. if {_ignore.%loop-player-1%} is not set:
  772. if {mineplex.rank.%{_player}%} is not "":
  773. set {_sanitizedm} to uncolored {_m}
  774. loop {mineplex.patreon::*}: #Do not worry about this. It only has to do with my test server, not you guys <3
  775. if loop-value-2 is {_player}:
  776. set {_brank} to uncolored {mineplex.rank.%{_player}%}
  777. set {_rank} to "&6&lP.%{_brank}%"
  778. else:
  779. set {_rank} to {mineplex.rank.%{_player}%}
  780. mcrjson("%loop-player%", "%{_lvl}%|| %{_rank}%||ttp:%{mineplex.hover.%{_player}%}%||&e%{_player}% &f%{_sanitizedm}%", false)
  781. else:
  782. send "%{_lvl}% %{mineplex.rank.%{_player}%}%&e%{_player}% &f%{_m}%" to loop-player
  783. return -1
  784. else:
  785. stop
  786.  
  787. function caseSensitive(source: String, compareTo: String) :: boolean:
  788. if size of split {_source} at {_compareTo} is 2:
  789. return true
  790. else: #Hi Snow
  791. return false
  792.  
  793. function gwenAlert(p: player , r: text) :: number:
  794. if {mineplex.disguise.%{_p}%} is set:
  795. set {_player} to {mineplex.disguise.%{_p}%}
  796. else:
  797. set {_player} to {_p}
  798. loop all players:
  799. if loop-player has permission "mineplex.trainee":
  800. if {mineplex.pref.gwen.%loop-player%} is true:
  801. send "&b&kK&r &c&lGWEN > &6%{_player}% &esuspected of &a%{_r}%&e." to loop-player
  802.  
  803. #Config Loading
  804.  
  805. on script unload:
  806. broadcast "&9MCR> &7Mineplex Core is recompiling!"
  807.  
  808. on load:
  809. if file "plugins/Mineplex-Core-Remake/config.yml" doesn't exists:
  810. configPopulate(1)
  811. # set {mineplex.config.servername} to colored value "servername" get of "plugins/Mineplex-Core-Remake/config.yml"
  812. configRefresh(1)
  813. wait 1 second
  814. if {mineplex.config.config} is "{@configver}":
  815. broadcast "&9MCR> &7Config &e{@configver} &7is up to date!"
  816. else:
  817. broadcast "&9Mineplex Core> &7Your Config is not up to Date! Updating this shit for you!"
  818. configPopulate(1)
  819. broadcast "&9Mineplex Core> &7Config Re-Populated!"
  820. broadcast "&9Mineplex Core> &7Going to reload plugin now!"
  821. broadcast "&9Mineplex Core> &7Going to reload plugin now!"
  822. wait 1 second
  823. configRefresh(1)
  824. broadcast "&9Mineplex Core> &7Config Done!"
  825. if {mineplex.usescoreboard} is not set:
  826. set {mineplex.usescoreboard} to true
  827.  
  828. #Main Command/Toggles
  829. command /mineplex-core [<string>] [<string>] [<string>]:
  830. aliases: /mpcore
  831. permission: op
  832. permission message: &9Permissions> &7This requires Permission Rank [&9OP&7].
  833. trigger:
  834. if arg-1 is not set:
  835. send "&a"
  836. send "&9Core Settings> &7Listing Commands:"
  837. send "&4/Mineplex-Core Chat (True/False) &7Toggles the MCR Chat system to override the default chat system. &4Operator"
  838. send "&4/Mineplex-Core Admin (Player) &7Give the target administrator permissions temporarily. &4Operator"
  839. send "&4/Mineplex-Core News (True/False) &7Toggles whether the MCR News system is being used. &4Operator"
  840. send "&4/Mineplex-Core Scoreboard (True/False) &7Toggles whether the MCR Scoreboard is being used. &4Operator"
  841. send "&4/Mineplex-Core TreasurePoint (1/2/3/4) &7Sets the Treasure point to your targeted block. &4Operator"
  842. send "&4/Mineplex-Core TreasurePointSub (1/2/3/4) (1/2/3/4/5/6/7/8) &7Sets the Opening Treasure point to your targeted block. &4Operator"
  843. send "&4/Mineplex-Core Carl &7Spawn Carl the Creeper in a fixed position at your current location. &4Operator"
  844. send "&4/Mineplex-Core TNT (True/False) &7Toggles the Throwing TNT Mechanics to be true or false. &4Operator"
  845. send "&4/Mineplex-Core purgehistory (player) &7Purges a player's punish history. &4Operator"
  846. send "&4/Mineplex-Core ForcefieldOff (Player) &7Forces a player to toggle off thier forcefield. &4Operator"
  847. send "&a"
  848. else if arg-1 is set:
  849. if arg-1 is "help":
  850. send "&a"
  851. send "&9Core Settings> &7Listing Commands:"
  852. send "&4/Mineplex-Core Chat (True/False) &7Toggles the MCR Chat system to override the default chat system. &4Operator"
  853. send "&4/Mineplex-Core Admin (Player) &7Give the target administrator permissions temporarily. &4Operator"
  854. send "&4/Mineplex-Core News (True/False) &7Toggles whether the MCR News system is being used. &4Operator"
  855. send "&4/Mineplex-Core Scoreboard (True/False) &7Toggles whether the MCR Scoreboard is being used. &4Operator"
  856. send "&4/Mineplex-Core TreasurePoint (1/2/3/4) &7Sets the Treasure point to your targeted block. &4Operator"
  857. send "&4/Mineplex-Core TreasurePointSub (1/2/3/4) (1/2/3/4/5/6/7/8) &7Sets the Opening Treasure point to your targeted block. &4Operator"
  858. send "&4/Mineplex-Core Carl &7Spawn Carl the Creeper in a fixed position at your current location. &4Operator"
  859. send "&4/Mineplex-Core TNT (True/False) &7Toggles the Throwing TNT Mechanics to be true or false. &4Operator"
  860. send "&4/Mineplex-Core purgehistory (player) &7Purges a player's punish history. &4Operator"
  861. send "&4/Mineplex-Core ForcefieldOff (Player) &7Forces a player to toggle off thier forcefield. &4Operator"
  862. send "&a"
  863. else if arg-1 is "Chat":
  864. if arg-2 is not set:
  865. send "&4/Mineplex-Core Chat (True/False) &7Toggles the MCR Chat system to override the default chat system. &4Operator"
  866. else if arg-2 is set:
  867. if arg-2 is "true":
  868. set {mineplex.overridechat} to true
  869. send "&9Core Settings> &7Now using the Mineplex Chat System (MCS)."
  870. else if arg-2 is "false":
  871. set {mineplex.overridechat} to false
  872. send "&9Core Settings> &7No longer using the Mineplex Chat System (MCS)."
  873. else:
  874. send "&4/Mineplex-Core Chat (True/False) &7Toggles the MCR Chat system to override the default chat system. &4Operator"
  875. else:
  876. send "&4/Mineplex-Core Chat (True/False) &7Toggles the MCR Chat system to override the default chat system. &4Operator"
  877. else if arg-1 is "Scoreboard":
  878. if arg-2 is not set:
  879. send "&4/Mineplex-Core Scoreboard (True/False) &7Toggles whether the MCR Scoreboard is being used. &4Operator"
  880. else if arg-2 is set:
  881. if arg-2 is "true":
  882. set {mineplex.usescoreboard} to true
  883. send "&9Core Settings> &7Now using the Mineplex Scoreboard System."
  884. else if arg-2 is "false":
  885. set {mineplex.usescoreboard} to false
  886. send "&9Core Settings> &7No longer using the Mineplex Scoreboard System."
  887. else:
  888. send "&4/Mineplex-Core Scoreboard (True/False) &7Toggles whether the MCR Scoreboard is being used. &4Operator"
  889. else:
  890. send "&4/Mineplex-Core Scoreboard (True/False) &7Toggles whether the MCR Scoreboard is being used. &4Operator"
  891. else if arg-1 is "ForcefieldOff":
  892. if arg-2 is not set:
  893. send "&4/Mineplex-Core ForcefieldOff (Player) &7Forces a player to toggle off thier forcefield. &4Operator"
  894. else:
  895. delete {mineplex.pref.ff.%arg-2%}
  896. delete {mineplex.ff.list::%arg-2%}
  897. send "&9MCR> &7Done!"
  898. else if arg-1 is "News":
  899. if arg-2 is not set:
  900. send "&4/Mineplex-Core News (True/False) &7Toggles whether the MCR News system is being used. &4Operator"
  901. else if arg-2 is set:
  902. if arg-2 is "true":
  903. set {mineplex.news.allow} to true
  904. send "&9Core Settings> &7Now using the Mineplex News System."
  905. else if arg-2 is "false":
  906. set {mineplex.news.allow} to false
  907. send "&9Core Settings> &7No longer using the Mineplex News System."
  908. else:
  909. send "&4/Mineplex-Core News (True/False) &7Toggles whether the MCR News system is being used. &4Operator"
  910. else:
  911. send "&4/Mineplex-Core News (True/False) &7Toggles whether the MCR News system is being used. &4Operator"
  912. else if arg-1 is "TNT":
  913. if arg-2 is not set:
  914. send "&4/Mineplex-Core TNT (True/False) &7Toggles the Throwing TNT Mechanics to be true or false. &4Operator"
  915. else if arg-2 is set:
  916. if arg-2 is "true":
  917. set {mineplex.tntlauncher} to true
  918. send "&9Core Settings> &7Now using the Throwing TNT Mechanics."
  919. else if arg-2 is "false":
  920. set {mineplex.tntlauncher} to false
  921. send "&9Core Settings> &7No longer using the Throwing TNT Mechanics."
  922. else:
  923. send "&4/Mineplex-Core TNT (True/False) &7Toggles the Throwing TNT Mechanics to be true or false. &4Operator"
  924. else:
  925. send "&4/Mineplex-Core TNT (True/False) &7Toggles the Throwing TNT Mechanics to be true or false. &4Operator"
  926. else if arg-1 is "purgehistory":
  927. if arg 2 is not set:
  928. send "&4/Mineplex-Core purgehistory (player) &7Purges a player's punish history. &4Operator"
  929. else:
  930. send "&9MCR> &7Purged %arg-2%'s history"
  931. delete {p.%arg-2%::*}
  932. delete {punishgui.%arg-2%::*}
  933. delete {reversed.p.%arg-2%::history::*}
  934. delete {reversed.p.%arg-2%::*}
  935. else if arg-1 is "reload":
  936. configRefresh(1)
  937. send "&9Core Settings> &7The main configuration file has been refreshed."
  938. else if arg-1 is "Carl":
  939. spawn 1 creeper at location of player
  940. set {_carl} to spawned creeper
  941. set name of last spawned entity to "&a&lCarl the Creeper"
  942. add "{NoAI:1b}" to nbt of {_carl}
  943. add "{powered:1}" to nbt of {_carl}
  944. apply slowness 255 to last spawned entity for 999 days
  945. set {kitnpc} to location of player
  946. send "&9Core Settings> &7Carl has been spawned in a fixed position at your current location."
  947. else if arg-1 is "admin":
  948. if arg-2 is set:
  949. set {mineplex.rank.%arg-2%} to "&4&lADMIN "
  950. set {_mineplex.setadmin.temp} to "%arg-2%" parsed as player
  951. execute console command "/__mp__dp__ %arg-2%"
  952. add "mineplex.trainee" to {_mineplex.setadmin.temp}'s permissions
  953. add "mineplex.mod" to {_mineplex.setadmin.temp}'s permissions
  954. add "mineplex.srmod" to {_mineplex.setadmin.temp}'s permissions
  955. add "mineplex.admin" to {_mineplex.setadmin.temp}'s permissions
  956. add "mineplex.legend" to {_mineplex.setadmin.temp}'s permissions
  957. add "mineplex.builder" to {_mineplex.setadmin.temp}'s permissions
  958. updateRankAPI({_mineplex.setadmin.temp})
  959. send "&9Core Settings> &7Temporarily added Admin permissions to %arg-2%."
  960. else:
  961. send "&4/Mineplex-Core Admin (Player) &7Give the target administrator permissions temporarily. &4Operator"
  962. else if arg-1 is "TreasurePoint":
  963. if arg-2 is "1" or "2" or "3" or "4":
  964. set {mineplex.chestpoint.%arg-2%} to target block
  965. send "&9Core Settings> &7Treasure Point %arg-2% has been set to your targeted block."
  966. else:
  967. send "&4/Mineplex-Core TreasurePoint (1/2/3/4) &7Sets the Treasure point to your targeted block. &4Operator"
  968. else if arg-1 is "TreasurePointSub":
  969. if arg-2 is "1" or "2" or "3" or "4":
  970. if arg-3 is "1" or "2" or "3" or "4" or "5" or "6" or "7" or "8":
  971. set {mineplex.chestpoint.%arg-2%.sub.%arg-3%} to target block
  972. send "&9Core Settings> &7Treasure Point Sub %arg-3% of Treasure Point %arg-2% has been set to your targeted block."
  973. else:
  974. send "&4/Mineplex-Core TreasurePointSub (1/2/3/4) (1/2/3/4/5/6/7/8) &7Sets the Opening Treasure point to your targeted block. &4Operator"
  975. else:
  976. send "&4/Mineplex-Core TreasurePointSub (1/2/3/4) (1/2/3/4/5/6/7/8) &7Sets the Opening Treasure point to your targeted block. &4Operator"
  977. else:
  978. send "&a"
  979. send "&9Core Settings> &7Listing Commands:"
  980. send "&4/Mineplex-Core Chat (True/False) &7Toggles the MCR Chat system to override the default chat system. &4Operator"
  981. send "&4/Mineplex-Core Admin (Player) &7Give the target administrator permissions temporarily. &4Operator"
  982. send "&4/Mineplex-Core News (True/False) &7Toggles whether the MCR News system is being used. &4Operator"
  983. send "&4/Mineplex-Core Scoreboard (True/False) &7Toggles whether the MCR Scoreboard is being used. &4Operator"
  984. send "&4/Mineplex-Core TreasurePoint (1/2/3/4) &7Sets the Treasure point to your targeted block. &4Operator"
  985. send "&4/Mineplex-Core TreasurePointSub (1/2/3/4) (1/2/3/4/5/6/7/8) &7Sets the Opening Treasure point to your targeted block. &4Operator"
  986. send "&4/Mineplex-Core Carl &7Spawn Carl the Creeper in a fixed position at your current location. &4Operator"
  987. send "&4/Mineplex-Core TNT (True/False) &7Toggles the Throwing TNT Mechanics to be true or false. &4Operator"
  988. send "&4/Mineplex-Core purgehistory (player) &7Purges a player's punish history. &4Operator"
  989. send "&4/Mineplex-Core ForcefieldOff (Player) &7Forces a player to toggle off thier forcefield. &4Operator"
  990. send "&a"
  991.  
  992. command /help [<string>]:
  993. trigger:
  994. send "&9MCR> &7Please see &bhttps://github.com/WheezyGold7931/Mineplex-Core/wiki/Commands-and-Permissions &7for updated commands!"
  995.  
  996. command /recompile [<string>]:
  997. aliases: /rec
  998. permission: op
  999. permission message: &9Permissions> &7This requires Permission Rank [&9OP&7].
  1000. trigger:
  1001. if arg 1 is not set:
  1002. broadcast "&9MCR> &7Mineplex Core &e{@MCRVER} &7will be recompiling in two seconds."
  1003. wait 2 second
  1004. player command "/sk reload Mineplex"
  1005. else:
  1006. if arg 1 is "-s":
  1007. broadcast "&9MCR> &7Mineplex Core will be recompiling in two seconds. (Silent)"
  1008. execute console command "/sk reload Mineplex"
  1009.  
  1010. #Thanks XeXRainnn
  1011. command /bugreport [<string>]:
  1012. trigger:
  1013. if arg 1 is not set:
  1014. send "&9MCR> &7Commands List:"
  1015. send "&f/bugreport <bug> &7Reports a bug to the MCR Developers &fPlayer"
  1016. else:
  1017. set {_pl} to "%list of plugins%"
  1018. replace all " " with "" in {_pl}
  1019. replace all "," with ",+" in {_pl}
  1020. set {_ra} to arg-1
  1021. replace all "`" with "" in {_ra}
  1022. replace all "*" with "" in {_ra}
  1023. replace all " " with "%%20" in {_ra}
  1024. set {_mc} to minecraft version
  1025. set {_sk} to skript version
  1026. set {_bk} to bukkit version
  1027. set {_mcr} to "{@MCRVER}"
  1028. set {_url} to uncolored "http://mpcore.us/mcr/bugreport.php?plugins=%{_pl}%&&rmcver=%{_mc}%&&rskver=%{_sk}%&&rbukkit=%{_bk}%&&rplayer=%player%&&rbug=%{_ra}%&&rmcrver=%{_mcr}%"
  1029. $ thread
  1030. set {_response::*} to contents from url {_url}
  1031. send "&9MCR> &7Please Wait!"
  1032. wait 5 seconds
  1033. if {_response::1} is "600":
  1034. send "&9MCR> &7Bug Report was &eSuccessful&7!"
  1035. else if {_response::1} contains "602":
  1036. send "&9MCR> &7Bug Report was marked as &eInvalid&7!"
  1037. else if {_response::1} is "603":
  1038. send "&9MCR> &c&lYou are blacklisted from the bug report system!"
  1039. else if {_response::1} contains "604":
  1040. set {_cr::*} to {_response} split at ":"
  1041. send "&9MCR> &7Bug Report returned a diffrent response: &e%{_cr::2}%"
  1042. else if {_response::1} is not set:
  1043. send "&9MCR> &7The bug report was malformed and we did not get a response!"
  1044.  
  1045. command /rules:
  1046. trigger:
  1047. send "&9Rules> &7The rules can be found here: &a%{mineplex.config.ruleswebsite}%"
  1048.  
  1049. #CarlBae
  1050.  
  1051. on load:
  1052. if {poll.id.last} is not set:
  1053. set {poll.id.last} to 0
  1054.  
  1055. on join:
  1056. set {_player} to "%player%"
  1057. replace all "s" in {_player} with "sssss"
  1058. send "&2&lCarl the Creeper> &aHey %{_player}%! I have sssome amazing rewardsss for you! Come sssee me!"
  1059. if {spintickets.%player%} is not set:
  1060. set {spintickets.%player%} to 0
  1061. if {mineplex.polltaken.0.%player%} is not set:
  1062. set {mineplex.polltaken.0.%player%} to true
  1063. if {mineplex.thankrewards.%player%} is not set:
  1064. set {mineplex.thankrewards.%player%} to 0
  1065.  
  1066. command /thank [<offline player>]:
  1067. trigger:
  1068. if arg 1 is set:
  1069. if arg 1 is player:
  1070. send "&9Thank> &7You cannot thank yourself!"
  1071. else:
  1072. if arg 1 is online:
  1073. if {mineplex.thank.last.%player%} is not set:
  1074. set {_good} to true
  1075. else:
  1076. set {_t} to difference between {mineplex.thank.last.%player%} and now
  1077. set {_tc} to "24 hours" parsed as a timespan
  1078. if {_t} is more than {_tc}:
  1079. set {_good} to true
  1080. if {_good} is true:
  1081. send "&9Thank> &7You thanked &e%arg-1% &7and earned &b5 Treasure Shards&7!"
  1082. send "&9Thank> &e%player% &7used &e/thank &7on you! +&b5 Treasure Shards&7!%nl%&9Thank> &7You can claim your reward at &eCarl the Creeper" to arg-1
  1083. addShards(player, 5)
  1084. add 5 to {mineplex.thankrewards.%arg-1%}
  1085. set {mineplex.thank.last.%player%} to now
  1086. else:
  1087. send "&9Thank> &7You can only /thank once per day!"
  1088. stop
  1089. else:
  1090. send "&9Online Player Search> &e0 &7matches for [&e%arg-1%&7]."
  1091. else:
  1092. send "&9Thank> &7Usage: &e/thank <player>"
  1093.  
  1094. function carlSpin(p: player) :: number:
  1095. if {spintickets.%{_p}%} >= 1:
  1096. remove 1 from {spintickets.%{_p}%}
  1097. wait 5 ticks
  1098. open chest with 3 rows named "Carl's Spinner" to {_p}
  1099. set {opener.%{_p}%} to true
  1100. loop 30 times:
  1101. inventory name of {_p}'s current inventory is "Carl's Spinner"
  1102. play "NOTE_PLING" to {_p} at volume 0.5
  1103. format slot 0 of {_p} with white stained glass pane to be unstealable
  1104. format slot 1 of {_p} with white glass to be unstealable
  1105. format slot 2 of {_p} with white glass to be unstealable
  1106. format slot 3 of {_p} with white glass to be unstealable
  1107. format slot 4 of {_p} with hopper to be unstealable
  1108. format slot 5 of {_p} with white glass to be unstealable
  1109. format slot 6 of {_p} with white glass to be unstealable
  1110. format slot 7 of {_p} with white glass to be unstealable
  1111. format slot 8 of {_p} with white stained glass pane to be unstealable
  1112. set {_randomint1.%{_p}%} to random integer between 95 and 375
  1113. format slot 9 of {_p} with prismarine shard named "&b%{_randomint1.%{_p}%}% Shards" to be unstealable
  1114. format slot 8 of {_p} with white stained glass pane to be unstealable
  1115. set {_randomint2.%{_p}%} to random integer between 95 and 375
  1116. format slot 10 of {_p} with prismarine shard named "&b%{_randomint2.%{_p}%}% Shards" to be unstealable
  1117. format slot 8 of {_p} with white stained glass pane to be unstealable
  1118. set {_randomint3.%{_p}%} to random integer between 95 and 375
  1119. format slot 11 of {_p} with prismarine shard named "&b%{_randomint3.%{_p}%}% Shards" to be unstealable
  1120. format slot 8 of {_p} with white stained glass pane to be unstealable
  1121. set {_randomint4.%{_p}%} to random integer between 95 and 375
  1122. format slot 12 of {_p} with prismarine shard named "&b%{_randomint4.%{_p}%}% Shards" to be unstealable
  1123. format slot 8 of {_p} with white stained glass pane to be unstealable
  1124. set {_randomint5.%{_p}%} to random integer between 95 and 375
  1125. format slot 13 of {_p} with prismarine shard named "&b%{_randomint5.%{_p}%}% Shards" to be unstealable
  1126. format slot 8 of {_p} with white stained glass pane to be unstealable
  1127. set {_randomint6.%{_p}%} to random integer between 95 and 375
  1128. format slot 14 of {_p} with prismarine shard named "&b%{_randomint6.%{_p}%}% Shards" to be unstealable
  1129. format slot 8 of {_p} with white stained glass pane to be unstealable
  1130. set {_randomint7.%{_p}%} to random integer between 95 and 375
  1131. format slot 15 of {_p} with prismarine shard named "&b%{_randomint7.%{_p}%}% Shards" to be unstealable
  1132. format slot 8 of {_p} with white stained glass pane to be unstealable
  1133. set {_randomint8.%{_p}%} to random integer between 95 and 375
  1134. format slot 16 of {_p} with prismarine shard named "&b%{_randomint8.%{_p}%}% Shards" to be unstealable
  1135. format slot 8 of {_p} with white stained glass pane to be unstealable
  1136. set {_randomint9.%{_p}%} to random integer between 95 and 375
  1137. format slot 17 of {_p} with prismarine shard named "&b%{_randomint9.%{_p}%}% Shards" to be unstealable
  1138. format slot 18 of {_p} with white stained glass pane to be unstealable
  1139. format slot 19 of {_p} with white glass to be unstealable
  1140. format slot 20 of {_p} with white glass to be unstealable
  1141. format slot 21 of {_p} with white glass to be unstealable
  1142. format slot 22 of {_p} with white glass to be unstealable
  1143. format slot 23 of {_p} with white glass to be unstealable
  1144. format slot 24 of {_p} with white glass to be unstealable
  1145. format slot 25 of {_p} with white glass to be unstealable
  1146. format slot 26 of {_p} with white stained glass pane to be unstealable
  1147. delete {_randomint1.%{_p}%}
  1148. delete {_randomint2.%{_p}%}
  1149. delete {_randomint3.%{_p}%}
  1150. delete {_randomint4.%{_p}%}
  1151. delete {_randomint6.%{_p}%}
  1152. delete {_randomint7.%{_p}%}
  1153. delete {_randomint8.%{_p}%}
  1154. delete {_randomint9.%{_p}%}
  1155. wait 0.2 seconds
  1156. send "&9Carl> &7You won &b%{_randomint5.%{_p}%}% Shards!" to {_p}
  1157. addShards({_p}, {_randomint5.%{_p}%})
  1158. wait 3 ticks
  1159. delete {_randomint5.%{_p}%}
  1160. delete {opener.%{_p}%}
  1161. wait 1 second
  1162. close {_p}'s inventory
  1163. else:
  1164. send "&9Carl's Spinner> &7You don't have a Carl Spinner Ticket!" to {_p}
  1165.  
  1166. function ytlink(p: player) :: number:
  1167. set {_t} to difference between {carl.ytr.%{_p}%} and now
  1168. set {_tc} to "1 day" parsed as a timespan
  1169. if {_t} is less than {_tc}:
  1170. message "&6&m=====================================" to {_p}
  1171. message "&b &f" to {_p}
  1172. message " &f&lClick to Open in Web Browser and visit our YouTube page" to {_p}
  1173. message " &a%{mineplex.config.youtube}%" to {_p}
  1174. message "&b &f" to {_p}
  1175. message "&6&m=====================================" to {_p}
  1176. stop
  1177. else:
  1178. set {carl.ytr.%{_p}%} to now
  1179. addShards({_p}, 250)
  1180. message "&6&m=====================================" to {_p}
  1181. message "&b &f" to {_p}
  1182. message " &f&lClick to Open in Web Browser and visit our YouTube page" to {_p}
  1183. message " &a%{mineplex.config.youtube}%" to {_p}
  1184. message "&b &f" to {_p}
  1185. message "&6&m=====================================" to {_p}
  1186. wait 60 seconds
  1187. message "&9Carl> &7Rewarded 250 Shards for watching the YouTube Video" to {_p}
  1188.  
  1189. function tlink(p: player) :: number:
  1190. message "&6&m=====================================" to {_p}
  1191. message "&b &f" to {_p}
  1192. message " &f&lClick to Open in Web Browser" to {_p}
  1193. message " &a%{mineplex.config.twitter}%" to {_p}
  1194. message "&b &f" to {_p}
  1195. message "&6&m=====================================" to {_p}
  1196.  
  1197. function dailyr(p: player) :: number:
  1198. set {_t} to difference between {carl.dr.%{_p}%} and now
  1199. set {_tc} to "20 hours" parsed as a timespan
  1200. if {_t} is less than {_tc}:
  1201. message "&9Carl> &7Come back in another 24 hours." to {_p}
  1202. stop
  1203. else:
  1204. message "&9Carl> &7Rewarded &e100 Treasure Shards" to {_p}
  1205. message "&9Carl> &7Rewarded &e100 Gems" to {_p}
  1206. message "&9Carl> &7Rewarded &e250 Experience" to {_p}
  1207. set {carl.dr.%{_p}%} to now
  1208. addShards({_p}, 100)
  1209. addGems({_p}, 100)
  1210. set {_cur} to getPlayerdata({_p}, "stats.global.dailyr") parsed as a number
  1211. add 1 to {_cur}
  1212. setPlayerdata({_p}, "stats.global.dailyr", "%{_cur}%")
  1213.  
  1214. function rawVote(p: player , v: number) :: number:
  1215. add 1 to {mineplex.poll.results.%{_v}%.%{poll.id.last}%}
  1216. set {mineplex.polltaken.%{poll.id.last}%.%{_p}%} to true
  1217. addGems({_p}, {mineplex.poll.gems.%{poll.id.last}%})
  1218. message "&9Carl> &7Rewarded &a%{mineplex.poll.gems.%{poll.id.last}%}% Gems&7." to {_p}
  1219.  
  1220. function pollVote(p: player) :: number:
  1221. open chest with 6 rows named "Poll:" to {_p}
  1222. wait 2 ticks
  1223. format slot 13 of {_p} with book and quill named "&a&lVote on Poll" with lore "||&f%{mineplex.poll.question.%{poll.id.last}%}%||||&b1.) &f%{mineplex.poll.a1.%{poll.id.last}%}%||&b2.) &f%{mineplex.poll.a2.%{poll.id.last}%}%||&b3.) &f%{mineplex.poll.a3.%{poll.id.last}%}%||&b4.) &f%{mineplex.poll.a4.%{poll.id.last}%}%||||&eRewards|| &f%{mineplex.poll.gems.%{poll.id.last}%}% Gems" to be unstealable
  1224. format slot 28 of {_p} with emerald named "&aOption 1" with lore "||&f%{mineplex.poll.a1.%{poll.id.last}%}%" to close then run [rawVote({_p}, 1)]
  1225. format slot 30 of {_p} with emerald named "&aOption 2" with lore "||&f%{mineplex.poll.a2.%{poll.id.last}%}%" to close then run [rawVote({_p}, 2)]
  1226. format slot 32 of {_p} with emerald named "&aOption 3" with lore "||&f%{mineplex.poll.a3.%{poll.id.last}%}%" to close then run [rawVote({_p}, 3)]
  1227. format slot 34 of {_p} with emerald named "&aOption 4" with lore "||&f%{mineplex.poll.a4.%{poll.id.last}%}%" to close then run [rawVote({_p}, 4)]
  1228.  
  1229. function claimThank(p: player) :: number:
  1230. set {_am} to {mineplex.thankrewards.%{_p}%}
  1231. set {_tp} to {_am} / 5
  1232. send "&9Carl> &7You collected &b%{_am}% Treasure Shards &7from &e%{_tp}% &7players!" to {_p}
  1233. set {mineplex.thankrewards.%{_p}%} to 0
  1234. set {_get} to getPlayerdata({_p}, "shards")
  1235. set {_cur} to {_get} parsed as a number
  1236. add {_am} to {_cur}
  1237. setPlayerdata({_p}, "shards", "%{_cur}%")
  1238.  
  1239. #Dank as all heck
  1240. function carlGUI(p: player) :: number:
  1241. open chest with 6 rows named "%{_p}%'s Bonuses" to {_p}
  1242. wait 2 ticks
  1243. format slot 10 of {_p} with redstone block named "&c&lRank Monthly Bonus" with lore "||&7Players with a Rank get a Monthly Bonus!||||&bUltra recieves 1 Mythical Chest Monthly||&dHero recieves 2 Mythical Chests Monthly||&aLegend recieves 3 Mythical Chests Monthly||&cTitan recieves 5 Mythical Chests Monthly||||&fPurchase a Rank at;||&f%{mineplex.config.shoplink}%" to close
  1244. set {_t} to difference between {carl.dr.%{_p}%} and now
  1245. set {_tc} to "20 hours" parsed as a timespan
  1246. set {_mc} to {_tc} - {_t}
  1247. set {_st} to "%{_t}%"
  1248. set {_args::*} to {_st} split at " "
  1249. set {_num1} to "%{_args::1}%" parsed as an int
  1250. set {_num2} to 1200
  1251. set {_num3} to {_num2} - {_num1}
  1252. set {_hourconvert} to {_num3} / 60
  1253. set {_finalwait} to "%{_hourconvert}% hours"
  1254. if {_t} is less than {_tc}:
  1255. format slot 12 of {_p} with redstone block named "&c&lDaily Reward" with lore "||&fNext reward in %{_finalwait}%!|| ||&7||&eRewards|| &f100 Treasure Shards|| &f100 Gems|| &f250 Experience||&7||&eCurrent Streak: &f0||&eStreak Bonus: &f0%%||&7||&eHighest Streak: &f0" to close
  1256. else:
  1257. format slot 12 of {_p} with chest named "&a&lDaily Reward" with lore "||&fClick to Claim!|| ||&7||&eRewards|| &f100 Treasure Shards|| &f100 Gems|| &f250 Experience||&7||&eCurrent Streak: 0||&eStreak Bonus: 5||&7||&eHighest Streak: &f1||&eStreak Reset: &f1.3 Days" to close then run [dailyr({_p})]
  1258. format slot 14 of {_p} with creeper head named "&c&lCarl's Spinner" with lore "||&fYou need a Carl Spin Ticket to Spin||&b||&eYour Tickets: &f%{spintickets.%{_p}%}%" to close then run [carlSpin({_p})]
  1259. format slot 16 of {_p} with redstone block named "&c&lPower Play Club" with lore "&eFebruary's Cosmetic|| &fTrue Love Pet||&b &f||&eOther Rewards|| &f2 Game Amplifier|| &f1 Omega Chest||&b||&cGet Power Play Club months at||&b%{mineplex.config.shoplink}%" to close
  1260. format slot 20 of {_p} with water bucket named "&e&lVisit us on Facebook" with lore "||&eRewards|| &f10 Ancient Chest" to close
  1261. set {_t} to difference between {carl.ytr.%{_p}%} and now
  1262. set {_tc} to "1 day" parsed as a timespan
  1263. if {_t} is less than {_tc}:
  1264. format slot 24 of {_p} with apple named "&a&lVisit us on YouTube" with lore "&fCome back Tomorrow for your||&fDaily Reward!||||&fCheck out the lastest Video||&fon the %{mineplex.config.servername}% Channel!||&b||&fBe sure and Subscribe so you ||&fdon't miss a video!||&b||&aClick to visit us on YouTube!" to close then run [ytlink({_p})]
  1265. else:
  1266. format slot 24 of {_p} with apple named "&a&lVisit us on YouTube" with lore "&eClaim your Daily 250 Shard Reward||&fby checking out the latest Video ||&fon the %{mineplex.config.servername}% Channel!||&b||&fBe sure and Subscribe so you ||&fdon't miss a video!||&b||&aClick to visit us on YouTube!" to close then run [ytlink({_p})]
  1267. if {mineplex.polltaken.%{poll.id.last}%.%{_p}%} is set:
  1268. format slot 28 of {_p} with redstone block named "&cVote on Poll" with lore "||&fYou voted on all of the polls!" to close
  1269. else:
  1270. format slot 28 of {_p} with book and quill named "&a&lVote on Poll" with lore "||&f%{mineplex.poll.question.%{poll.id.last}%}%||||&b1.) &f%{mineplex.poll.a1.%{poll.id.last}%}%||&b2.) &f%{mineplex.poll.a2.%{poll.id.last}%}%||&b3.) &f%{mineplex.poll.a3.%{poll.id.last}%}%||&b4.) &f%{mineplex.poll.a4.%{poll.id.last}%}%||||&eRewards|| &f%{mineplex.poll.gems.%{poll.id.last}%}% Gems||||&aClick to go to the vote page!" to run [pollVote({_p})]
  1271. if {mineplex.thankrewards.%{_p}%} is greater than 0:
  1272. format slot 30 of {_p} with emerald named "&a&lThank Rewards" with lore "||&eYour Rewards|| &f%{mineplex.thankrewards.%{_p}%}% Treasure Shards|| ||&fClick to Claim!" to close then run [claimThank({_p})]
  1273. else:
  1274. format slot 30 of {_p} with redstone block named "&c&lThank Rewards" with lore "||&7Earn Thank Rewards from players using /thank||&7on you, or by enabling Game Amplifiers.||&b||&fGet Amplifiers at &a%{mineplex.config.shoplink}%" to close
  1275. format slot 32 of {_p} with tripwire hook named "&a&lWatch an Ad!" with lore "&eEarn 1 Carl Spin Ticket||&fby checking out our partner's Advertisement||||&fYou can watch 5 Ads every 24 hours.||||&fPlease help us keep %{mineplex.config.servername}% awesome||&c&lBe sure to have your AdBlocker disabled!||||&aClick to watch the Ad now!" to be unstealable
  1276. format slot 34 of {_p} with egg named "&a&lVisit us on Twitter" with lore "&fCheck out and follow %{mineplex.config.servername}% on||&fTwitter for Giveaways, Announcements,||&fTeasers, and Tips!||||&aClick to visit us on Twitter" to close then run [tlink({_p})]
  1277. format slot 40 of {_p} with jukebox named "&a&lVote for %{mineplex.config.servername}%" with lore "||&fClick to Vote!||||&eRewards|| &f1 Carl Spin Ticket|| &f400 Gems||||&eCurrent Streak: &f0||&eStreak Bonus: &f+0%%||||&eHighest Streak: &f0" to be unstealable
  1278.  
  1279. command /poll [<text>] [<text>] [<text>] [<text>] [<text>] [<text>] [<integer>] [<string>]:
  1280. permission: mineplex.admin
  1281. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  1282. trigger:
  1283. if arg 1 is set:
  1284. if arg 1 is "create":
  1285. if arg 2 is set:
  1286. if arg 3 is set:
  1287. if arg 4 is set:
  1288. if arg 5 is set:
  1289. if arg 6 is set:
  1290. if arg 7 is set:
  1291. add 1 to {poll.id.last}
  1292. send "&9Poll> &7Rolling out poll with id &e%{poll.id.last}%&7!"
  1293. wait 1 second
  1294. set {_arg1} to arg 2
  1295. set {_arg2} to arg 3
  1296. set {_arg3} to arg 4
  1297. set {_arg4} to arg 5
  1298. set {_arg5} to arg 6
  1299. set {mineplex.poll.gems.%{poll.id.last}%} to "%arg 7%" parsed as an integer
  1300. replace every "_" with " " in {_arg1}
  1301. replace every "_" with " " in {_arg2}
  1302. replace every "_" with " " in {_arg3}
  1303. replace every "_" with " " in {_arg4}
  1304. replace every "_" with " " in {_arg5}
  1305. broadcast "&9Poll> &7A new poll is available! Vote in Carl!"
  1306. wait 0.5 seconds
  1307. send "&9Poll> &7The poll has been rolled out successfully!"
  1308. set {mineplex.poll.question.%{poll.id.last}%} to {_arg1}
  1309. set {mineplex.poll.a1.%{poll.id.last}%} to {_arg2}
  1310. set {mineplex.poll.a2.%{poll.id.last}%} to {_arg3}
  1311. set {mineplex.poll.a3.%{poll.id.last}%} to {_arg4}
  1312. set {mineplex.poll.a4.%{poll.id.last}%} to {_arg5}
  1313. set {mineplex.poll.results.1.%{poll.id.last}%} to 0
  1314. set {mineplex.poll.results.2.%{poll.id.last}%} to 0
  1315. set {mineplex.poll.results.3.%{poll.id.last}%} to 0
  1316. set {mineplex.poll.results.4.%{poll.id.last}%} to 0
  1317. else:
  1318. send "&9Poll> &7Correct Usage:"
  1319. send "&4/poll create (Question) (Opt.1) (Opt.2) (Opt.3) (Opt.4) (Gem Reward) Admin"
  1320. send "&4/poll results [(id)] Admin"
  1321. send ""
  1322. send "&9Poll> &7Example:"
  1323. send "/poll create Is_Wheezy_Da_Best? Yes No He_Could_Be Ur_Funny 111 Admin"
  1324. else:
  1325. send "&9Poll> &7Correct Usage:"
  1326. send "&4/poll create (Question) (Opt.1) (Opt.2) (Opt.3) (Opt.4) (Gem Reward) Admin"
  1327. send "&4/poll results [(id)] Admin"
  1328. send ""
  1329. send "&9Poll> &7Example:"
  1330. send "/poll create Is_Wheezy_Da_Best? Yes No He_Could_Be Ur_Funny 111"
  1331. else:
  1332. send "&9Poll> &7Correct Usage:"
  1333. send "&4/poll create (Question) (Opt.1) (Opt.2) (Opt.3) (Opt.4) (Gem Reward) Admin"
  1334. send "&4/poll results [(id)] Admin"
  1335. send ""
  1336. send "&9Poll> &7Example:"
  1337. send "/poll create Is_Wheezy_Da_Best? Yes No He_Could_Be Ur_Funny 111"
  1338. else:
  1339. send "&9Poll> &7Correct Usage:"
  1340. send "&4/poll create (Question) (Opt.1) (Opt.2) (Opt.3) (Opt.4) (Gem Reward) Admin"
  1341. send "&4/poll results [(id)] Admin"
  1342. send ""
  1343. send "&9Poll> &7Example:"
  1344. send "/poll create Is_Wheezy_Da_Best? Yes No He_Could_Be Ur_Funny 111"
  1345. else:
  1346. send "&9Poll> &7Correct Usage:"
  1347. send "&4/poll create (Question) (Opt.1) (Opt.2) (Opt.3) (Opt.4) (Gem Reward) Admin"
  1348. send "&4/poll results [(id)] Admin"
  1349. send ""
  1350. send "&9Poll> &7Example:"
  1351. send "/poll create Is_Wheezy_Da_Best? Yes No He_Could_Be Ur_Funny 111"
  1352. else:
  1353. send "&9Poll> &7Correct Usage:"
  1354. send "&4/poll create (Question) (Opt.1) (Opt.2) (Opt.3) (Opt.4) (Gem Reward) Admin"
  1355. send "&4/poll results [(id)] Admin"
  1356. send ""
  1357. send "&9Poll> &7Example:"
  1358. send "/poll create Is_Wheezy_Da_Best? Yes No He_Could_Be Ur_Funny 111"
  1359. else if arg 1 is "results":
  1360. if player has permission "mineplex.admin":
  1361. if arg 2 is not set:
  1362. open chest with 5 row named "Poll Results" to player
  1363. format slot 13 of player with book and quill named "&b&lCurrent Poll" with lore "&eOuestion:||&b%{mineplex.poll.question.%{poll.id.last}%}%|| ||&e&lReward: &f%{mineplex.poll.gems.%{poll.id.last}%}% Gems" to be unstealable
  1364. format slot 19 of player with book named "&b&lOption 1" with lore "&eAnswer 1:|| &f%{mineplex.poll.a1.%{poll.id.last}%}%" to be unstealable
  1365. format slot 21 of player with book named "&b&lOption 2" with lore "&eAnswer 2:|| &f%{mineplex.poll.a2.%{poll.id.last}%}%" to be unstealable
  1366. format slot 23 of player with book named "&b&lOption 3" with lore "&eAnswer 3:|| &f%{mineplex.poll.a3.%{poll.id.last}%}%" to be unstealable
  1367. format slot 25 of player with book named "&b&lOption 4" with lore "&eAnswer 4:|| &f%{mineplex.poll.a4.%{poll.id.last}%}%" to be unstealable
  1368. format slot 28 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.1.%{poll.id.last}%}% &evotes||&efor answer 1:|| &f%{mineplex.poll.a1.%{poll.id.last}%}%" to be unstealable
  1369. format slot 30 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.2.%{poll.id.last}%}% &evotes||&efor answer 2:|| &f%{mineplex.poll.a2.%{poll.id.last}%}%" to be unstealable
  1370. format slot 32 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.3.%{poll.id.last}%}% &evotes||&efor answer 3:|| &f%{mineplex.poll.a3.%{poll.id.last}%}%" to be unstealable
  1371. format slot 34 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.4.%{poll.id.last}%}% &evotes||&efor answer 4:|| &f%{mineplex.poll.a4.%{poll.id.last}%}%" to be unstealable
  1372. else:
  1373. set {_id} to arg-2 parsed as a number
  1374. if {_id} is 0:
  1375. send "&9Poll> &cInvalid Poll ID!"
  1376. stop
  1377. if {_id} is greater than {poll.id.last}:
  1378. send "&9Poll> &cInvalid Poll ID!"
  1379. stop
  1380. if {_id} is not set:
  1381. send "&9Poll> &cInvalid Poll ID!"
  1382. stop
  1383. open chest with 5 row named "Poll Results" to player
  1384. format slot 13 of player with book and quill named "&b&lCurrent Poll" with lore "&eOuestion:||&b%{mineplex.poll.question.%{_id}%}%|| ||&e&lReward: &f%{mineplex.poll.gems.%{_id}%}% Gems" to be unstealable
  1385. format slot 19 of player with book named "&b&lOption 1" with lore "&eAnswer 1:|| &f%{mineplex.poll.a1.%{_id}%}%" to be unstealable
  1386. format slot 21 of player with book named "&b&lOption 2" with lore "&eAnswer 2:|| &f%{mineplex.poll.a2.%{_id}%}%" to be unstealable
  1387. format slot 23 of player with book named "&b&lOption 3" with lore "&eAnswer 3:|| &f%{mineplex.poll.a3.%{_id}%}%" to be unstealable
  1388. format slot 25 of player with book named "&b&lOption 4" with lore "&eAnswer 4:|| &f%{mineplex.poll.a4.%{_id}%}%" to be unstealable
  1389. format slot 28 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.1.%{_id}%}% &evotes||&efor answer 1:|| &f%{mineplex.poll.a1.%{_id}%}%" to be unstealable
  1390. format slot 30 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.2.%{_id}%}% &evotes||&efor answer 2:|| &f%{mineplex.poll.a2.%{_id}%}%" to be unstealable
  1391. format slot 32 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.3.%{_id}%}% &evotes||&efor answer 3:|| &f%{mineplex.poll.a3.%{_id}%}%" to be unstealable
  1392. format slot 34 of player with blue stained glass pane named "&b&lVote Count:" with lore "&f%{mineplex.poll.results.4.%{_id}%}% &evotes||&efor answer 4:|| &f%{mineplex.poll.a4.%{_id}%}%" to be unstealable
  1393. else:
  1394. send "&9Permissions> &7This requires Permission Rank [&9ADMIN&7]."
  1395. else:
  1396. send "&9Poll> &7Correct Usage:"
  1397. send "&4/poll create (Question) (Opt.1) (Opt.2) (Opt.3) (Opt.4 (Gem Reward) Admin"
  1398. send "&4/poll results [(id)] Admin"
  1399. send ""
  1400. send "&9Poll> &7Example:"
  1401. send "/poll create Is_Wheezy_Da_Best? Yes No He_Could_Be Ur_Funny 111"
  1402.  
  1403. command /fixanimation:
  1404. permission: mineplex.dev
  1405. permission message: &9Permissions> &7This requires Permission Rank [&9DEV&7].
  1406. trigger:
  1407. loop all entities:
  1408. if name of loop-entity is "&a&lCarl the Creeper":
  1409. set {_e1} to loop-entity
  1410. exit loop
  1411. add "{NoAI:0b}" to nbt of {_e1}
  1412. teleport {_e1} 100 blocks below {_e1}
  1413. kill {_e1}
  1414.  
  1415. command /animation:
  1416. permission: mineplex.dev
  1417. permission message: &9Permissions> &7This requires Permission Rank [&9DEV&7].
  1418. trigger:
  1419. loop all entities:
  1420. if name of loop-entity is "&a&lCarl the Creeper":
  1421. set {_e1} to loop-entity
  1422. exit loop
  1423. set {_loc} to location of {_e1}
  1424. add "{Fuse:999}" to nbt of {_e1}
  1425. add "{ignited:1}" to nbt of {_e1}
  1426. wait 1 second
  1427. loop all players:
  1428. show 1 "Explosion Huge" particles at {_loc} for loop-player
  1429. play raw sound "random.explode1" at {_e1} with pitch 1 volume 10
  1430. play raw sound "random.explode" at {_e1} with pitch 1 volume 10
  1431. wait 0.6 seconds
  1432. spawn 1 creeper at location of {_e1}
  1433. add "{NoAI:0b}" to nbt of {_e1}
  1434. teleport {_e1} 100 blocks below {_e1}
  1435. kill {_e1}
  1436. set {_carl} to spawned creeper
  1437. set name of last spawned entity to "&a&lCarl the Creeper"
  1438. add "{NoAI:1b}" to nbt of {_carl}
  1439. add "{powered:1}" to nbt of {_carl}
  1440. apply slowness 255 to last spawned entity for 999 days
  1441.  
  1442. every 2 minutes:
  1443. execute console command "/animation" #Sue me
  1444.  
  1445. command /ticket [<offline player>] [<string>] [<string>]:
  1446. permission: mineplex.admin
  1447. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  1448. trigger:
  1449. if arg-1 is set:
  1450. if arg-2 is set:
  1451. set {_int} to arg-2 parsed as an int
  1452. if {_int} is an int:
  1453. send "&9Tickets> &7You gave &e%arg-2% &7Carl spin tickets to &e%arg-1%" to sender
  1454. send "&9Tickets> &7You recieved &e%arg 2% &7Carl spin tickets" to arg 1
  1455. add {_int} to {spintickets.%arg-1%}
  1456. else:
  1457. send "&9Tickets> &7Listing Commands"
  1458. send "&4/ticket <player> <amount> &7Give a player spin tickets &4Admin"
  1459. else:
  1460. send "&9Tickets> &7Listing Commands"
  1461. send "&4/ticket <player> <amount> &7Give a player spin tickets &4Admin"
  1462. else:
  1463. send "&9Tickets> &7Listing Commands"
  1464. send "&4/ticket <player> <amount> &7Give a player spin tickets &4Admin"
  1465.  
  1466. on inventory close:
  1467. if {opener.%player%} is true:
  1468. wait 2 ticks
  1469. open chest with 3 rows named "Carl's Spinner" to player
  1470.  
  1471. every second:
  1472. loop all entities:
  1473. name of loop-entity contains "&a&lCarl the Creeper"
  1474. teleport loop-entity to {kitnpc}
  1475.  
  1476. on damage:
  1477. name of victim contains "&a&lCarl the Creeper"
  1478. cancel event
  1479.  
  1480. on right click on entity:
  1481. if player is holding chest:
  1482. if name of player's tool is "&aCosmetic Menu":
  1483. stop
  1484. else:
  1485. send "&9MCR> &e##BlameWheezy"
  1486. else:
  1487. name of clicked entity contains "&a&lCarl the Creeper"
  1488. if {nospam.%player%} is true:
  1489. stop
  1490. else:
  1491. set {nospam.%player%} to true
  1492. carlGUI(player)
  1493. wait 1 second
  1494. set {nospam.%player%} to false
  1495.  
  1496. on death:
  1497. set {nospam.%victim%} to false
  1498.  
  1499. on join:
  1500. set {nospam.%player%} to false
  1501.  
  1502. #Broadcast System
  1503.  
  1504. every 10 seconds:
  1505. $ thread
  1506. set {_check} to line 1 from url "https://pastebin.com/raw/8YXXWuiA"
  1507. if {mineplex.globalannounce.%{_check}%} is not set:
  1508. set {mineplex.globalannounce.%{_check}%} to true
  1509. $ thread
  1510. set {_message} to line 1 from url "https://pastebin.com/raw/fGAUXi37"
  1511. send all players title "&eMCR Announcement" with subtitle "&f%{_message}%" for 10 seconds
  1512. broadcast "&9MCR Announcement> &b%{_message}%"
  1513.  
  1514. #Titles
  1515.  
  1516. function createTitle(arg1: player , arg2: text) :: number:
  1517. set {_tploc} to location of {_arg1}
  1518. add 1.6 to y-coordinate of {_tploc}
  1519. spawn a armor stand at {_tploc}
  1520. teleport {%{_arg1}%.title} to {_tploc}
  1521. set {%{_arg1}%.title} to the last spawned entity
  1522. set metadata value "titleOwner" of last spawned entity to "%{_arg1}%"
  1523. add "{CustomName:""%{_arg2}%""}" to nbt of last spawned entity
  1524. add "{NoGravity:1}" to nbt of last spawned entity
  1525. add "{CustomNameVisible:1}" to nbt of last spawned entity
  1526. add "{PersistenceRequired:1}" to nbt of last spawned entity
  1527. add "{Invisible:1}" to nbt of last spawned entity
  1528. add "{Marker:1}" to nbt of last spawned entity
  1529. set {title.%{_arg1}%.active} to true
  1530. set {_tploc} to location of {_arg1}
  1531. add 1.6 to y-coordinate of {_tploc}
  1532. teleport {%{_arg1}%.title} to {_tploc}
  1533.  
  1534. function removeTitle(arg1: player) :: number:
  1535. if {title.%{_arg1}%.active} is true:
  1536. kill {%{_arg1}%.title}
  1537. set {title.%{_arg1}%.active} to false
  1538. delete {%{_arg1}%.title}
  1539. set {_void} to location of {_arg1}
  1540. remove 256 from y-coordinate of {_void}
  1541. loop all entities:
  1542. if metadata value "titleOwner" of loop-entity is "%{_arg1}%":
  1543. add "{NoGravity:0}" to nbt of loop-entity
  1544. teleport loop-entity to {_void}
  1545.  
  1546. set {title.%{_arg1}%.active} to false
  1547. wait 4 ticks
  1548. delete {%{_arg1}%.title}
  1549. else:
  1550. message "[TitleAPI] Error:" to console
  1551. message "[TitleAPI] %{_arg1}% has no title active" to console
  1552. stop
  1553.  
  1554. on any move:
  1555. if {title.%player%.active} is true:
  1556. set {_tploc} to location of player
  1557. add 1.6 to y-coordinate of {_tploc}
  1558. teleport {%player%.title} to {_tploc}
  1559.  
  1560. on any move:
  1561. if {title.%player%.active} is true:
  1562. push {%player%.title} forwards
  1563. set {_tploc} to location of player
  1564. add 1.6 to y-coordinate of {_tploc}
  1565. teleport {%player%.title} to {_tploc}
  1566. make {%player%.title} home towards player
  1567. push {%player%.title} forwards
  1568.  
  1569. command /createtitle [<player>] [<text>]:
  1570. permission: mineplex.dev
  1571. trigger:
  1572. set {_txt} to colored arg 2
  1573. removeTitle(arg 1)
  1574. message "&9Titles> &7Generating title, please wait..."
  1575. wait 5 ticks
  1576. createTitle(arg 1, "%{_txt}%")
  1577. message "&9Titles> &7Title &e%{_txt}% &7Generated."
  1578.  
  1579. #protocol hide {_e1} from loop-player
  1580.  
  1581. on quit:
  1582. removeTitle(player)
  1583.  
  1584. command /removeTitle [<player>]:
  1585. trigger:
  1586. removeTitle(arg-1)
  1587.  
  1588. function trackDB(p: player , t: string) :: string:
  1589. if {_t} is "aprilfools-2017":
  1590. set {_r} to "&5&k?&d 2017 April Fools &5&k?"
  1591. if {_t} is "gotta-go":
  1592. set {_r} to "&c&k?&c Has Santa's Number &c&k?"
  1593. if {_t} is "leveler":
  1594. set {_r} to "&c&k?&c Friend of Douglas &c&k?"
  1595. if {_t} is "lucky":
  1596. set {_r} to "&c&k?&c Hashtag Blessed &c&k?"
  1597. if {_t} is "mineplex-mastery":
  1598. set {_r} to "&c&k?&c Mineplex Master &c&k?"
  1599. if {_t} is "party-animal":
  1600. set {_r} to "&c&k?&c Life is a Party &c&k?"
  1601. if {_t} is "peaceful":
  1602. set {_r} to "&c&k?&c Pacifist &c&k?"
  1603. if {_t} is "peaceful":
  1604. set {_r} to "&c&k?&c Doer of Things &c&k?"
  1605. if {_t} is "power-play":
  1606. if {mineplex.ppc.%{_p}%} is set:
  1607. set {_r} to "&b&k?&b Power Play Club &b&k?"
  1608. else:
  1609. return "perm"
  1610. if {_t} is "sweet-tooth":
  1611. set {_r} to "treasure-hunter"
  1612. if {_t} is "unlucky":
  1613. set {_r} to "&c&k?&c Things Don't Go My Way &c&k?"
  1614. if {_t} is "warrior":
  1615. set {_r} to "&c&k?&c Champion &c&k?"
  1616. if {_t} is "gotta-go":
  1617. set {_r} to "&6┬┴┬┴┤(・_├┬┴┬┴)"
  1618. if {_t} is "leader":
  1619. if {_p} has permission "mineplex.leader":
  1620. set {_r} to "&c&kK&4 What's a leader? &c&kK"
  1621. else:
  1622. return "perm"
  1623. if {_t} is "mcr-dev":
  1624. if {_p} is "WheezyGold7931" or "TheSkripterDK" or "Torksi" or "Y7S" or "Ottelino" or "ItzRenderman":
  1625. set {_r} to "&6&kK&c&l MCR Dev &6&kK"
  1626. else:
  1627. return "perm"
  1628. if {_r} is not set:
  1629. set {_r} to "false"
  1630. return {_r}
  1631.  
  1632. command /track [<string>] [<string>]:
  1633. trigger:
  1634. if {mineplex.track.%player%} is set:
  1635. send "&9Track> &7You have disabled your active track"
  1636. removeTitle(player)
  1637. delete {mineplex.track.%player%}
  1638. else:
  1639. if arg 1 is not set:
  1640. send "&9Track> &7You must specify the ID of a track to enable"
  1641. else:
  1642. set {_track} to trackDB(player, arg-1)
  1643. if {_track} is "false":
  1644. send "&9Track> &7That is not a valid track"
  1645. stop
  1646. if {_track} is "perm":
  1647. send "&9Track> &7You have not unlocked any tiers on that track"
  1648. stop
  1649. removeTitle(player)
  1650. wait 5 ticks
  1651. createTitle(player, {_track})
  1652. send "&9Track> &7Your active track has been updated to %{_track}%"
  1653. set {mineplex.track.%player%} to {_track}
  1654.  
  1655. #Cosmetics
  1656. on join:
  1657. message "&9Cosmetics> &7You enabled all Previously enabled Cosmetics" to player
  1658.  
  1659. command /chestmeup:
  1660. trigger:
  1661. give player chest named "&aCosmetic Menu"
  1662.  
  1663. function mountapi(p: player, action: text, type: text) :: number:
  1664. if {_action} is "remove":
  1665. set {_loc} to {_p}'s location
  1666. add -100000 to y-coordinate of {_loc}
  1667. teleport {currentmount.%{_p}%} to {_loc}
  1668. delete {currentmount.%{_p}%}
  1669. message "&9Mount> &7Despawned &e%{currentmount.%{_p}%.type}%" to {_p}
  1670. set {currentmount.%{_p}%.type} to "None"
  1671. if {_action} is "create":
  1672. if {_type} is "slime":
  1673. if {currentmount.%{_p}%} is set:
  1674. message "&9MountAPI> &6[WARN] &7%{_p}% already has a mount active. The Action has been canceled." to console
  1675. stop
  1676. spawn a slime at {_p}
  1677. set {currentmount.%{_p}%} to the last spawned entity
  1678. add "{CustomName:""%{_p}%'s Slime""}" to nbt of last spawned entity
  1679. add "{CustomNameVisible:1}" to nbt of last spawned entity
  1680. add "{PersistenceRequired:1}" to nbt of last spawned entity
  1681. add "{Size:1}" to nbt of last spawned entity
  1682. add "{Attributes:{Name:generic.attackDamage,Base:0},[{Name:generic.followRange,Base:0}]}" to nbt of last spawned entity
  1683. add "{ActiveEffects:[{Id:18,Amplifier:255,Duration:19999980,ShowParticles:0b}]}" to nbt of last spawned entity
  1684. set {currentmount.%{_p}%.type} to "Slime Mount"
  1685. while {currentmount.%{_p}%} is alive:
  1686. wait 15 ticks
  1687. {_p} is online
  1688. if distance between {currentmount.%{_p}%} and {_p} is less than 5:
  1689. make {currentmount.%{_p}%} pathfind to {_p} with speed 1
  1690. else if distance between {currentmount.%{_p}%} and {_p} is more than 15:
  1691. teleport {currentmount.%{_p}%} to {_p}
  1692. else:
  1693. make {currentmount.%{_p}%} pathfind to {_p} with speed 2
  1694.  
  1695.  
  1696.  
  1697. function cosmetic_system(arg1: text , arg2: text , p: player) :: number:
  1698. set {_wither} to "MHF_WSkeleton" parsed as a player
  1699. if {_arg1} is "menu":
  1700. if {_arg2} is "gadgets":
  1701. if {mineplex.%{_p}%.cosmetics.gadgets.pearl} is not set:
  1702. set {mineplex.%{_p}%.cosmetics.gadgets.pearl} to 0
  1703. if {mineplex.%{_p}%.cosmetics.gadgets.firework} is not set:
  1704. set {mineplex.%{_p}%.cosmetics.gadgets.firework} to 0
  1705. if {mineplex.%{_p}%.cosmetics.gadgets.coal} is not set:
  1706. set {mineplex.%{_p}%.cosmetics.gadgets.coal} to 0
  1707. if {mineplex.%{_p}%.cosmetics.gadgets.tnt} is not set:
  1708. set {mineplex.%{_p}%.cosmetics.gadgets.tnt} to 0
  1709. if {mineplex.%{_p}%.cosmetics.gadgets.snowball} is not set:
  1710. set {mineplex.%{_p}%.cosmetics.gadgets.snowball} to 0
  1711. wait 2 ticks
  1712. open chest with 6 rows named "Inventory" to {_p}
  1713. wait 4 ticks
  1714. format slot 4 of {_p} with bed item named "&7⇽ Go Back" to close then run [cosmetic_system("menu", "main", {_p})]
  1715. format slot 10 of {_p} with ender pearl named "&a&lEthereal Pearl" with lore "||&7These Pearls are stolen from||&7sleeping Endermen!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.pearl}%" to close then run [cosmetic_system("use", "pearl", {_p})]
  1716. if {mineplex.gadget.selected.%{_p}%} is "pearl":
  1717. format slot 10 of {_p} with shiny ender pearl named "&a&lEthereal Pearl" with lore "||&7These Pearls are stolen from||&7sleeping Endermen!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.pearl}%" to close then run [cosmetic_system("use", "pearl", {_p})]
  1718.  
  1719. format slot 11 of {_p} with firework rocket named "&a&lFireworks" with lore "||&7Need to celebrate? These||&7Fireworks should do the trick!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.firework}%" to close then run [cosmetic_system("use", "firework", {_p})]
  1720. if {mineplex.gadget.selected.%{_p}%} is "firework":
  1721. format slot 11 of {_p} with shiny firework rocket named "&a&lFireworks" with lore "||&7Need to celebrate? These||&7Fireworks should do the trick!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.firework}%" to close then run [cosmetic_system("use", "firework", {_p})]
  1722. format slot 14 of {_p} with snowball named "&a&lSnowballs" with lore "||&fJoin in on the festive fun by||&fthrowing show at people!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.snowball}%" to close then run [cosmetic_system("use", "snowball", {_p})]
  1723. if {mineplex.gadget.selected.%{_p}%} is "Snowball":
  1724. format slot 14 of {_p} with shiny snowball named "&a&lSnowballs" with lore "||&fJoin in on the festive fun by||&fthrowing show at people!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.snowball}%" to close then run [cosmetic_system("use", "snowball", {_p})]
  1725. format slot 12 of {_p} with tnt named "&a&lTNT" with lore "||&7Thowing tnt at %{mineplex.config.servername}%||&7Staff is highly encouraged!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.tnt}%" to close then run [cosmetic_system("use", "tnt", {_p})]
  1726. if {mineplex.gadget.selected.%{_p}%} is "tnt":
  1727. format slot 12 of {_p} with shiny tnt named "&a&lTNT" with lore "||&7Thowing tnt at %{mineplex.config.servername}%||&7Staff is highly encouraged!||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.tnt}%" to close then run [cosmetic_system("use", "tnt", {_p})]
  1728. format slot 13 of {_p} with coal named "&a&lCoal" with lore "||&7Just a large chunk of coal.||&7Maybe you were naughty or||&7something||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.coal}%" to close then run [cosmetic_system("use", "coal", {_p})]
  1729. if {mineplex.gadget.selected.%{_p}%} is "coal":
  1730. format slot 13 of {_p} with shiny coal named "&a&lCoal" with lore "||&7Just a large chunk of coal.||&7Maybe you were naughty or||&7something||||&fYou own &a%{mineplex.%{_p}%.cosmetics.gadgets.coal}%" to close then run [cosmetic_system("use", "coal", {_p})]
  1731. if {_arg2} is "main":
  1732. if {mineplex.%{_p}%.cosmetics.morphs} is not set:
  1733. set {mineplex.%{_p}%.cosmetics.morphs} to 0
  1734. if {mineplex.%{_p}%.cosmetics.hats} is not set:
  1735. set {mineplex.%{_p}%.cosmetics.hats} to 0
  1736. wait 2 ticks
  1737. open chest with 6 rows named "Inventory" to {_p}
  1738. set {mineplex.error.slot} to 0
  1739. wait 4 ticks
  1740. loop 54 times:
  1741. format slot {mineplex.error.slot} of {_p} with black glass pane named "&8" with lore "&6" to be unstealable
  1742. add 1 to {mineplex.error.slot}
  1743. format slot 1 of {_p} with nether star named "&a&lParticle Effects" with lore "||&7Show everyone how cool you ||&7are with swirly particles that ||&7follow you when you walk. ||&8Visible Everywhere ||||&fYou own 0/22 ||||&fActive: &eNone ||&aLeft-click to view category" to close then run [cosmetic_system("menu", "particles", {_p})]
  1744. format slot 10 of {_p} with arrow named "&a&lArrow Effects" with lore "||&7Your arrows will now leave ||&7Particle Trails as they soar ||&7through the air ||&8Visible In Games ||||&fYou own 0/13 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1745. format slot 28 of {_p} with golden boots named "&a&lDouble Jump Effects" with lore "||&7Demonstrate your parkour ||&7prowess with sweet particles ||&7when you double jump ||&8Visible Everywhere ||||&fYou own 0/13 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1746. format slot 19 of {_p} with skeleton head named "&a&lDeath Animations" with lore "||&7Your death will now be mourned ||&7with a wonderfull particle ||&7tribute ||&8Visible In Games ||||&fYou own 0/13 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1747. format slot 22 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore " ||&7This seems like it might come in||&7handy. Maybe I can collect more!" to be unstealable
  1748. format slot 49 of {_p} with melon block named "&a&lGadgets" with lore "||&fAll sorts of zany contraptions||&7to use on your friends and||&7foes.||&8Useable in Lobbies||||&fYou own 4/4||||&fActive: &e%{mineplex.gadget.selected.%{_p}%}%||&aClick to view Category" to close then run [cosmetic_system("menu", "gadgets", {_p})]
  1749. format slot 25 of {_p} with leather named "&a&lMorphs" with lore "||&7Have you ever wanted to be a||&7tiger? Well, you cant be a||&7tiger! Thats silly! But you can||&7be mny other things!||&8Useable in Lobbies||||&fYou own %{mineplex.%{_p}%.cosmetics.morphs}%/4||||&fActive: &e%{mineplex.currentmorph.%{_p}%}%||&aClick to view Category" to close then run [cosmetic_system("menu", "morphs", {_p})]
  1750. format slot 50 of {_p} with iron horse armor named "&a&lMounts" with lore "||&7Why walk when you can ride? ||&7Summon fancy mounts to help ||&7you move in style. ||&8Usable In Lobbies ||||&fYou own %{mineplex.%{_p}%.cosmetics.mounts}%/1 ||||&fActive: &e%{currentmount.%{_p}%.type}% ||&aLeft-click to view category" to close then run [cosmetic_system("menu", "mounts", {_p})]
  1751. format slot 51 of {_p} with bone named "&a&lPets" with lore "||&7Life on a server can get ||&7lonely sometimes. summon an ||&7adorable pet to follow you ||&7around and cheer you up! ||&8Usable In Lobbies ||||&fYou own 0/16 ||||&fActive: &eNone ||&aLeft-click to view category" to close then run [cosmetic_system("menu", "pets", {_p})]
  1752. format slot 7 of {_p} with golden helmet named "&a&lHats" with lore "||&7Hats are in this year. Wear||&7them on your head to impress||&7the ladies.||&8Useable in Lobbies||||&fYou own %{mineplex.%{_p}%.cosmetics.hats}%/2" to close then run [cosmetic_system("menu", "hats", {_p})]
  1753. format slot 16 of {_p} with diamond chestplate named "&A&LCostumes" with lore "||&7Sometimes going out calls for ||&7Special Clothes! Gain bonus ||&7effects for matching outfits. ||&8Usable In Lobbies ||||&fYou own 0/12 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1754. format slot 48 of {_p} with music disc named "&A&LMusic" with lore "||&7I JUST WANT TO DANCE WITH ||&7YOU! ||&8Usable In Lobbies ||||&fYou own 0/11 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1755. format slot 31 of {_p} with name tag named "&A&lTaunts" with lore "||&7Taunt your enemies or just ||&7show off. Use /taunt to have ||&7a good time! ||&8Visible In Games ||||&fYou own 0/1 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1756. format slot 13 of {_p} with cake item named "&A&LWin Effects" with lore "||&7Winning a game with your ||&7friends is all good and dandy, ||&7but being able to also ||&7show off awesome effects is ||&7even more fun! ||&8Visible In Games ||||&fYou own 0/10 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1757. format slot 21 of {_p} with torch named "&A&lGame Modifiers" with lore "||&7Cosmetic effects which changes ||&7appearances of objects in ||&7game. ||&8Visible In Games ||||&fYou own 0/25 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1758. format slot 47 of {_p} with lead named "&A&lBalloons" with lore "||&7Balloons are collectibles that ||&7you can float above your head ||&7as you wander the lobby. You ||&7can have up to 10 balloons in ||&7you hand at one time. ||&8Usable In Lobbies ||||&fYou own 0/14 ||||&fActive: &eNone ||&aLeft-click to view category" to be unstealable
  1759. format slot 23 of {_p} with lever named "&a&lKit Selector Particles" with lore "||&7Click here to select different||&7particles to indicate which kit you have selected!||&8Usable In Game Lobbies||||&fYou own 0/8 ||##||&aLeft-click to view category" to be unstealable
  1760. format slot 34 of {_p} with banner named "&a&lFlags" with lore "||&7Show off your country's flag!||&8Usable In Lobbies||||&fYou own 0/2 ||||&aLeft-click to view category" to be unstealable
  1761.  
  1762.  
  1763.  
  1764.  
  1765. if {_arg2} is "pets":
  1766. if {mineplex.%{_p}%.cosmetics.pets.ocelot} is not set:
  1767. set {mineplex.%{_p}%.cosmetics.pets.ocelot} to 0
  1768. if {mineplex.%{_p}%.cosmetics.pets.wolf} is not set:
  1769. set {mineplex.%{_p}%.cosmetics.pets.wolf} to 0
  1770. if {mineplex.%{_p}%.cosmetics.pets.chicken} is not set:
  1771. set {mineplex.%{_p}%.cosmetics.pets.chicken} to 0
  1772. wait 2 ticks
  1773. open chest with 6 rows named "Inventory" to {_p}
  1774. wait 4 ticks
  1775. format slot 4 of {_p} with bed item named "&7? Go Back" to close then run [cosmetic_system("menu", "main", {_p})]
  1776. format slot 10 of {_p} with gray dye named "&c&lGuardian" with lore "||&7Your very own Guardian!||&cUnlocked with Titan Rank" to close then run [cosmetic_system("use", "guardian", {_p})]
  1777. format slot 11 of {_p} with gray dye named "&c&lCat" with lore "||&7Your very own Cat!" to close then run [cosmetic_system("use", "ocelot", {_p})]
  1778. format slot 12 of {_p} with gray dye named "&c&lDog" with lore "||&7Your very own Dog!" to close then run [cosmetic_system("use", "wolf", {_p})]
  1779. format slot 13 of {_p} with gray dye named "&c&lChicken" with lore "||&7Your very own Chicken!" to close then run [cosmetic_system("use", "chicken", {_p})]
  1780. if {_arg2} is "morphs":
  1781. if {mineplex.%{_p}%.cosmetics.morphs.owned.villager} is not set:
  1782. set {mineplex.%{_p}%.cosmetics.morphs.owned.villager} to 0
  1783. if {mineplex.%{_p}%.cosmetics.morphs.owned.slime} is not set:
  1784. set {mineplex.%{_p}%.cosmetics.morphs.owned.slime} to 0
  1785. if {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} is not set:
  1786. set {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} to 0
  1787. if {mineplex.%{_p}%.cosmetics.morphs.owned.cow} is not set:
  1788. set {mineplex.%{_p}%.cosmetics.morphs.owned.cow} to 0
  1789. wait 2 ticks
  1790. open chest with 6 rows named "Inventory" to {_p}
  1791. wait 4 ticks
  1792. format slot 4 of {_p} with bed item named "&7⇽ Go Back" to close then run [cosmetic_system("menu", "main", {_p})]
  1793. if {mineplex.%{_p}%.cosmetics.morphs.owned.villager} is 0:
  1794. format slot 10 of {_p} with gray dye named "&c&lVillager Morph" with lore "||&7HURRRR! MURR HURRR!||||&f&lCOST: &b12000 Treasure Shards" to close then run [cosmetic_system("buy", "morph_villager", {_p})]
  1795. else:
  1796. format slot 10 of {_p} with emerald named "&a&lVillager Morph" with lore "||&7HURRRR! MURR HURRR!||||&aClick to use" to close then run [cosmetic_system("use", "morph_villager", {_p})]
  1797. if {mineplex.currentmorph.%{_p}%} is "Villager Morph":
  1798. format slot 10 of {_p} with shiny emerald named "&a&lVillager Morph" with lore "||&7HURRRR! MURR HURRR!||||&aClick disable" to close then run [cosmetic_system("use", "morph_villager", {_p})]
  1799. if {mineplex.%{_p}%.cosmetics.morphs.owned.slime} is 0:
  1800. format slot 11 of {_p} with gray dye named "&c&lSlime Morph" with lore "||&7Splat Splat!||||&f&lCOST: &b20000 Treasure Shards" to close then run [cosmetic_system("buy", "morph_slime", {_p})]
  1801. else:
  1802. format slot 11 of {_p} with slimeball named "&a&lSlime Morph" with lore "||&7Splat Splat!||||&aClick to enable." to close then run [cosmetic_system("use", "morph_slime", {_p})]
  1803. if {mineplex.currentmorph.%{_p}%} is "Slime Morph":
  1804. format slot 11 of {_p} with shiny slimeball named "&a&lSlime Morph" with lore "||&7Splat Splat!||||&aClick to disable." to close then run [cosmetic_system("use", "morph_slime", {_p})]
  1805. if {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} is 0:
  1806. format slot 12 of {_p} with gray dye named "&c&lCreeper Morph" with lore "||&7Hissss!||||&f&lCOST: &b10000 Treasure Shards" to close then run [cosmetic_system("buy", "morph_creeper", {_p})]
  1807. else:
  1808. format slot 12 of {_p} with gunpowder named "&a&lCreeper Morph" with lore "||&7Hissssss!||||&aClick to enable." to close then run [cosmetic_system("use", "morph_creeper", {_p})]
  1809. if {mineplex.currentmorph.%{_p}%} is "Creeper Morph":
  1810. format slot 12 of {_p} with shiny gunpowder named "&a&lCreeper Morph" with lore "||&7Hissssss!||||&aClick to disable." to close then run [cosmetic_system("use", "morph_creeper", {_p})]
  1811. if {mineplex.%{_p}%.cosmetics.morphs.owned.cow} is 0:
  1812. format slot 13 of {_p} with gray dye named "&c&lCow Morph" with lore "||&7How now brown cow?||||&f&lCOST: &b6000 Treasure Shards" to close then run [cosmetic_system("buy", "morph_cow", {_p})]
  1813. else:
  1814. format slot 13 of {_p} with steak named "&a&lCow Morph" with lore "||&7How now brown cow?||||&aClick to enable." to close then run [cosmetic_system("use", "morph_cow", {_p})]
  1815. if {mineplex.currentmorph.%{_p}%} is "Cow Morph":
  1816. format slot 13 of {_p} with shiny steak named "&a&lCow Morph" with lore "||&7Moooo!||||&aClick to disable." to close then run [cosmetic_system("use", "morph_cow", {_p})]
  1817. if {_p} has permission "mineplex.legend":
  1818. format slot 14 of {_p} with {_wither}'s skull named "&a&lWither Morph" with lore "||&7Legends have foretold the||&7coming of a powerful Wither...||||&fFly through the air!||||&aClick to Enable" to close then run [cosmetic_system("use", "morph_wither", {_p})]
  1819. if {mineplex.currentmorph.%{_p}%} is "Wither Morph":
  1820. format slot 14 of {_p} with shiny {_wither}'s skull named "&a&lWither Morph" with lore "||&7Legends have foretold the||&7coming of a powerful Wither...||||&fFly through the air!||||&aClick to Disable" to close then run [cosmetic_system("use", "morph_wither", {_p})]
  1821. else:
  1822. format slot 14 of {_p} with gray dye named "&c&lWither Morph" with lore "||&7Legends have foretold the||&7coming of a powerful Wither...||||&fFly through the air!||||&aUnlocked with Legend Rank" to be unstealable
  1823.  
  1824. if {_arg2} is "hats":
  1825. wait 2 ticks
  1826. open chest with 6 rows named "Inventory" to {_p}
  1827. wait 4 ticks
  1828. format slot 4 of {_p} with bed item named "&7⇽ Go Back" to close then run [cosmetic_system("menu", "main", {_p})]
  1829. if {mineplex.hat.%{_p}%.owned.compCube} is not set:
  1830. set {mineplex.hat.%{_p}%.owned.compCube} to 0
  1831. if {mineplex.hat.%{_p}%.owned.present} is not set:
  1832. set {mineplex.hat.%{_p}%.owned.present} to 0
  1833. if {mineplex.hat.%{_p}%.owned.compCube} is 0:
  1834. format slot 10 of {_p} with gray dye named "&c&lCompanion Cube" with lore "||&7The Enrichment Center is||&7required to remind you that||&7the Weighted Companion cube||&7cannot talk. In the event that it does talk The Enrichment||&7Center asks you to ignore its||&7advice.||||&9Found in Treasure Chests" to be unstealable
  1835. else:
  1836. format slot 10 of {_p} with stone:6 named "&a&lCompanion Cube" with lore "||&7The Enrichment Center is||&7required to remind you that||&7the Weighted Companion cube||&7cannot talk. In the event that it does talk The Enrichment||&7Center asks you to ignore its||&7advice.||||&aClick to enable" to close then run [cosmetic_system("use", "hat_compCube", {_p})]
  1837. if {mineplex.hat.selected.%{_p}%} is "compCube":
  1838. format slot 10 of {_p} with shiny stone:6 named "&a&lCompanion Cube" with lore "||&7The Enrichment Center is||&7required to remind you that||&7the Weighted Companion cube||&7cannot talk. In the event that||&7it does talk The Enrichment||&7Center asks you to ignore its||&7advice.||||&aClick to disable" to close then run [cosmetic_system("use", "hat_compCube", {_p})]
  1839. if {mineplex.hat.%{_p}%.owned.present} is 0:
  1840. format slot 11 of {_p} with gray dye named "&c&lPresent" with lore "||&7WHAT'S IN THE PRESENT? Oh, it's||&7just you...||||&9Found in Treasure Chests" to be unstealable
  1841. else:
  1842. format slot 11 of {_p} with chest named "&a&lPresent" with lore "||&7WHAT'S IN THE PRESENT? Oh, it's||&7just you...||||&aClick to enable." to close then run [cosmetic_system("use", "hat_present", {_p})]
  1843. if {mineplex.hat.selected.%{_p}%} is "present":
  1844. format slot 11 of {_p} with shiny chest named "&a&lPresent" with lore "||&7WHAT'S IN THE PRESENT? Oh, it's||&7just you...||||&aClick to disable." to close then run [cosmetic_system("use", "hat_present", {_p})]
  1845. if {_arg2} is "particles":
  1846. wait 2 ticks
  1847. open chest with 6 rows named "Inventory" to {_p}
  1848. wait 4 ticks
  1849. format slot 4 of {_p} with bed item named "&7⇽ Go Back" to close then run [cosmetic_system("menu", "main", {_p})]
  1850. if {mineplex.particle.%{_p}%.owned.shadow} is not set:
  1851. set {mineplex.particle.%{_p}%.owned.shadow} to 0
  1852. if {mineplex.particle.%{_p}%.owned.shadow} is 0:
  1853. format slot 10 of {_p} with gray dye named "&c&lShadow Walk" with lore "||&7In a world where footprints do||&7not exist, leaving you shadow||&7behind is the next best thing!||||&9Found in Treasure Chests" to be unstealable
  1854. else:
  1855. format slot 10 of {_p} with leather boots named "&a&lShadow Walk" with lore "||&7In a world where footprints do||&7not exist, leaving you shadow||&7behind is the next best thing!||||&aClick to enable" to close then run [cosmetic_system("use", "particle_shadow", {_p})]
  1856. if {mineplex.particle.selected.%{_p}%} is "shadow":
  1857. format slot 10 of {_p} with shiny leather boots named "&a&lShadow Walk" with lore "||&7In a world where footprints do||&7not exist, leaving you shadow||&7behind is the next best thing!||||&aClick to disabe" to close then run [cosmetic_system("use", "particle_shadow", {_p})]
  1858. if {mineplex.particle.%{_p}%.owned.flame} is 0:
  1859. format slot 11 of {_p} with gray dye named "&c&lFlame Rings" with lore "||&7Forged from the blazing rods||&7of 1000 Blazes by the||&7infamous Nether King.||||&9Found in Treasure Chests" to be unstealable
  1860. else:
  1861. format slot 11 of {_p} with blaze rod named "&a&lFlame Rings" with lore "||&7Forged from the blazing rods||&7of 1000 Blazes by the||&7infamous Nether King.||||&aClick to enable" to close then run [cosmetic_system("use", "particle_flame", {_p})]
  1862. if {mineplex.particle.selected.%{_p}%} is "flame":
  1863. format slot 11 of {_p} with shiny blaze rod named "&a&lFlame Rings" with lore "||&7Forged from the blazing rods||&7of 1000 Blazes by the||&7infamous Nether King.||||&aClick to disabe" to close then run [cosmetic_system("use", "particle_flame", {_p})]
  1864. if {_arg2} is "mounts":
  1865. if {mineplex.%{_p}%.cosmetics.mounts.owned.slime} is not set:
  1866. set {mineplex.%{_p}%.cosmetics.mounts.owned.slime} to 0
  1867. wait 2 ticks
  1868. open chest with 6 rows named "Inventory" to {_p}
  1869. wait 4 ticks
  1870. format slot 4 of {_p} with bed item named "&7⇽ Go Back" to close then run [cosmetic_system("menu", "main", {_p})]
  1871. if {mineplex.%{_p}%.cosmetics.mounts.owned.slime} is 0:
  1872. format slot 10 of {_p} with gray dye named "&c&lSlime Mount" with lore "||&7Splat Splat!||||&f&lCOST: &b12000 Treasure Shards" to close then run [cosmetic_system("buy", "mount_slime", {_p})]
  1873. else:
  1874. format slot 10 of {_p} with slimeball named "&a&lSlime Mount" with lore "||&7Splat Splat!||||&aClick to use" to close then run [cosmetic_system("use", "mount_slime", {_p})]
  1875. if {currentmount.%{_p}%.type} is "Slime Mount":
  1876. format slot 10 of {_p} with shiny slimeball named "&a&lSlime Mount" with lore "||&7Splat Splat!||||&aClick disable" to close then run [cosmetic_system("use", "mount_slime", {_p})]
  1877.  
  1878.  
  1879. if {_arg1} is "use":
  1880. if {_arg2} is "hat_compCube":
  1881. if {mineplex.hat.selected.%{_p}%} is "compCube":
  1882. wait 1 tick
  1883. message "&9Gadget> &7You unequipped &eCompanion Cube" to {_p}
  1884. set {mineplex.hat.selected.%{_p}%} to "none"
  1885. execute console command "/replaceitem entity %{_p}% slot.armor.head air 1 0"
  1886. cosmetic_system("menu", "hats", {_p})
  1887. stop
  1888. if {mineplex.hat.%{_p}%.owned.compCube} is 1:
  1889. wait 1 tick
  1890. execute console command "/replaceitem entity %{_p}% slot.armor.head skull 1 3 {display:{Name:&a&lCompanion Cube},SkullOwner:{Id:c1e0dbe1-7fef-4de0-96d2-59aa96dafef7,Properties:{textures:[{Value:eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMmU1ZDZjNTY5N2U2ZTA2MmEzNjc5YzdiZjU0MDg0YjU4ZWIzZTNjYWE1N2U0MGFkZjZlNTJmMjFiYzM1Mzk1In19fQ==}]}}}"
  1891. message "&9Gadget> &7You equipped &eCompanion Cube" to {_p}
  1892. set {mineplex.hat.selected.%{_p}%} to "compCube"
  1893. cosmetic_system("menu", "hats", {_p})
  1894. if {_arg1} is "use":
  1895. if {_arg2} is "hat_present":
  1896. if {mineplex.hat.selected.%{_p}%} is "present":
  1897. message "&9Gadget> &7You unequipped &ePresent" to {_p}
  1898. set {mineplex.hat.selected.%{_p}%} to "none"
  1899. execute console command "/replaceitem entity %{_p}% slot.armor.head air 1 0"
  1900. cosmetic_system("menu", "hats", {_p})
  1901. stop
  1902. if {mineplex.hat.%{_p}%.owned.compCube} is 1:
  1903. execute console command "/replaceitem entity %{_p}% slot.armor.head skull 1 3 {display:{Name:&a&lPresent},SkullOwner:{Id:d350d00d-4dbb-46a9-b769-60bd67546da3,Properties:{textures:[{Value:eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvZTE4ZjhmMTE1MTRjMWZmYmM2ZTk5OTc1ZDdjYTZiNWJhZjkyZGM5MjRjNTIyM2M0ZWM0OTY5M2NkZmNiOCJ9fX0=}]}}}"
  1904. message "&9Gadget> &7You equipped &ePresent" to {_p}
  1905. set {mineplex.hat.selected.%{_p}%} to "present"
  1906. cosmetic_system("menu", "hats", {_p})
  1907. if {_arg1} is "use":
  1908. if {_arg2} is "particle_shadow":
  1909. if {mineplex.particle.selected.%{_p}%} is "shadow":
  1910. message "&9Gadget> &7You unequipped &eShadow Walk" to {_p}
  1911. set {mineplex.particle.selected.%{_p}%} to "none"
  1912. cosmetic_system("menu", "particles", {_p})
  1913. stop
  1914. if {mineplex.particle.%{_p}%.owned.shadow} is 1:
  1915. message "&9Gadget> &7You equipped &eShadow Walk" to {_p}
  1916. set {mineplex.particle.selected.%{_p}%} to "shadow"
  1917. cosmetic_system("menu", "particles", {_p})
  1918. if {_arg2} is "particle_flame":
  1919. if {mineplex.particle.selected.%{_p}%} is "flame":
  1920. message "&9Gadget> &7You unequipped &eFlame Rings" to {_p}
  1921. set {mineplex.particle.selected.%{_p}%} to "none"
  1922. cosmetic_system("menu", "particles", {_p})
  1923. stop
  1924. if {mineplex.particle.%{_p}%.owned.flame} is 1:
  1925. message "&9Gadget> &7You equipped &eFlame Rings" to {_p}
  1926. set {mineplex.particle.selected.%{_p}%} to "flame"
  1927. cosmetic_system("menu", "particles", {_p})
  1928. if {_arg1} is "use":
  1929. if {_arg2} is "ocelot":
  1930. if {mineplex.pets.ocelot.active.%{_p}%} is not set:
  1931. set {mineplex.pets.ocelot.active.%{_p}%} to false
  1932. if {mineplex.pets.ocelot.active.%{_p}%} is false:
  1933. spawn a ocelot at {_p}
  1934. set {_ocelotpet} to the last spawned entity
  1935. add "{CustomName:&a%{_p}%'s&c Pet Cat}" to nbt of last spawned entity
  1936. add "{Silent:1}" to nbt of last spawned entity
  1937. add "{CustomNameVisible:1}" to nbt of last spawned entity
  1938. add "{PersistenceRequired:1}" to nbt of last spawned entity
  1939. tame {_ocelotpet} to {_p}
  1940. evaluate "set {pet::%{_p}%} to {_ocelotpet}"
  1941. set {mineplex.pets.ocelot.active.%{_p}%} to true
  1942. while {pet::%{_p}%} is alive:
  1943. wait 15 ticks
  1944. {_p} is online
  1945. if distance between {pet::%{_p}%} and {_p} is less than 5:
  1946. make {pet::%{_p}%} pathfind to {_p} with speed 1
  1947. else if distance between {pet::%{_p}%} and {_p} is more than 15:
  1948. teleport {pet::%{_p}%} to {_p}
  1949. else:
  1950. make {pet::%{_p}%} pathfind to {_p} with speed 2
  1951. else:
  1952. if {mineplex.pets.ocelot.active.%{_p}%} is true:
  1953. kill {pet::%{_p}%}
  1954. delete {pet::%{_p}%}
  1955. set {mineplex.pets.ocelot.active.%{_p}%} to false
  1956. if {_arg1} is "use":
  1957. if {_arg2} is "wolf":
  1958. if {mineplex.pets.wolf.active.%{_p}%} is not set:
  1959. set {mineplex.pets.wolf.active.%{_p}%} to false
  1960. if {mineplex.pets.wolf.active.%{_p}%} is false:
  1961. spawn a wolf at {_p}
  1962. set {_ocelotpet} to the last spawned entity
  1963. add "{CustomName:&a%{_p}%'s&c Pet Wolf}" to nbt of last spawned entity
  1964. add "{Silent:1}" to nbt of last spawned entity
  1965. add "{CustomNameVisible:1}" to nbt of last spawned entity
  1966. add "{PersistenceRequired:1}" to nbt of last spawned entity
  1967. tame {_ocelotpet} to {_p}
  1968. evaluate "set {pet::%{_p}%} to {_ocelotpet}"
  1969. set {mineplex.pets.wolf.active.%{_p}%} to true
  1970. while {pet::%{_p}%} is alive:
  1971. wait 15 ticks
  1972. {_p} is online
  1973. if distance between {pet::%{_p}%} and {_p} is less than 5:
  1974. make {pet::%{_p}%} pathfind to {_p} with speed 1
  1975. else if distance between {pet::%{_p}%} and {_p} is more than 15:
  1976. teleport {pet::%{_p}%} to {_p}
  1977. else:
  1978. make {pet::%{_p}%} pathfind to {_p} with speed 2
  1979. else:
  1980. if {mineplex.pets.wolf.active.%{_p}%} is true:
  1981. kill {pet::%{_p}%}
  1982. delete {pet::%{_p}%}
  1983. set {mineplex.pets.wolf.active.%{_p}%} to false
  1984. if {_arg1} is "use":
  1985. if {_arg2} is "chicken":
  1986. if {mineplex.pets.chicken.active.%{_p}%} is not set:
  1987. set {mineplex.pets.chicken.active.%{_p}%} to false
  1988. if {mineplex.pets.chicken.active.%{_p}%} is false:
  1989. spawn a chicken at {_p}
  1990. set {_ocelotpet} to the last spawned entity
  1991. add "{CustomName:&a%{_p}%'s&c Pet Chicken}" to nbt of last spawned entity
  1992. add "{Silent:1}" to nbt of last spawned entity
  1993. add "{CustomNameVisible:1}" to nbt of last spawned entity
  1994. add "{PersistenceRequired:1}" to nbt of last spawned entity
  1995. tame {_ocelotpet} to {_p}
  1996. evaluate "set {pet::%{_p}%} to {_ocelotpet}"
  1997. set {mineplex.pets.chicken.active.%{_p}%} to true
  1998. while {pet::%{_p}%} is alive:
  1999. wait 15 ticks
  2000. {_p} is online
  2001. if distance between {pet::%{_p}%} and {_p} is less than 5:
  2002. make {pet::%{_p}%} pathfind to {_p} with speed 1
  2003. else if distance between {pet::%{_p}%} and {_p} is more than 15:
  2004. teleport {pet::%{_p}%} to {_p}
  2005. else:
  2006. make {pet::%{_p}%} pathfind to {_p} with speed 2
  2007. else:
  2008. if {mineplex.pets.chicken.active.%{_p}%} is true:
  2009. kill {pet::%{_p}%}
  2010. delete {pet::%{_p}%}
  2011. set {mineplex.pets.chicken.active.%{_p}%} to false
  2012. if {_arg1} is "use":
  2013. if {_arg2} is "guardian":
  2014. if {mineplex.pets.guardian.active.%{_p}%} is not set:
  2015. set {mineplex.pets.guardian.active.%{_p}%} to false
  2016. if {mineplex.pets.guardian.active.%{_p}%} is false:
  2017. spawn a guardian at {_p}
  2018. set {_ocelotpet} to the last spawned entity
  2019. add "{CustomName:&a%{_p}%'s&c Pet Guardian}" to nbt of last spawned entity
  2020. add "{Silent:1}" to nbt of last spawned entity
  2021. add "{CustomNameVisible:1}" to nbt of last spawned entity
  2022. add "{PersistenceRequired:1}" to nbt of last spawned entity
  2023. tame {_ocelotpet} to {_p}
  2024. evaluate "set {pet::%{_p}%} to {_ocelotpet}"
  2025. set {mineplex.pets.guardian.active.%{_p}%} to true
  2026. while {pet::%{_p}%} is alive:
  2027. wait 15 ticks
  2028. {_p} is online
  2029. if distance between {pet::%{_p}%} and {_p} is less than 5:
  2030. make {pet::%{_p}%} pathfind to {_p} with speed 1
  2031. else if distance between {pet::%{_p}%} and {_p} is more than 15:
  2032. teleport {pet::%{_p}%} to {_p}
  2033. else:
  2034. make {pet::%{_p}%} pathfind to {_p} with speed 2
  2035. else:
  2036. if {mineplex.pets.guardian.active.%{_p}%} is true:
  2037. kill {pet::%{_p}%}
  2038. delete {pet::%{_p}%}
  2039. set {mineplex.pets.guardian.active.%{_p}%} to false
  2040. if {_arg1} is "use":
  2041. if {_arg2} is "coal":
  2042. if {mineplex.gadget.selected.%{_p}%} is "coal":
  2043. message "&9Gadget> &7You unequipped &eCoal" to {_p}
  2044. set {mineplex.gadget.selected.%{_p}%} to "none"
  2045. set slot 3 of {_p} to air with name "lolz"
  2046. cosmetic_system("menu", "gadgets", {_p})
  2047. stop
  2048. message "&9Gadget> &7You equipped &eCoal" to {_p}
  2049. set {mineplex.gadget.selected.%{_p}%} to "coal"
  2050. set slot 3 of {_p} to coal with name "&e%{mineplex.%{_p}%.cosmetics.gadgets.coal}% Coal"
  2051. cosmetic_system("menu", "gadgets", {_p})
  2052. stop
  2053. if {_arg1} is "buy":
  2054. wait 2 ticks
  2055. open chest with 6 rows named " Confirmation" to {_p}
  2056. wait 2 ticks
  2057. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f10000 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2058. format slot 22 of {_p} with gunpowder named "&fCreeper Morph" with lore "&fHissssss!" to be unstealable
  2059. format slot 27 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2060. format slot 28 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2061. format slot 29 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2062. format slot 36 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2063. format slot 37 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2064. format slot 38 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2065. format slot 45 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2066. format slot 46 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2067. format slot 47 of {_p} with emerald block named "&aOK" with lore "" to close then run [cosmetic_system("confirm", {_arg2}, {_p})]
  2068. format slot 33 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2069. format slot 34 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2070. format slot 35 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2071. format slot 42 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2072. format slot 43 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2073. format slot 44 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2074. format slot 51 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2075. format slot 52 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2076. format slot 53 of {_p} with redstone block named "&cCANCEL" with lore "" to close then run [cosmetic_system("menu", "main", {_p})]
  2077. #Mounts
  2078. if {_arg2} is "mount_slime":
  2079. if {mineplex.%{_p}%.cosmetics.morphs.owned.slime} is 1:
  2080. message "&9Gadget> &7You already own this mount!" to {_p}
  2081. else:
  2082. format slot 22 of {_p} with slimeball named "&fSlime Mount" with lore "&fSplat Splat!" to be unstealable
  2083. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f10000 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2084. #Morphs
  2085. if {_arg2} is "morph_creeper":
  2086. if {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} is 1:
  2087. message "&9Gadget> &7You already own this morph!" to {_p}
  2088. else:
  2089. format slot 22 of {_p} with gunpowder named "&fCreeper Morph" with lore "&fHissssss!" to be unstealable
  2090. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f10000 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2091. if {_arg2} is "morph_cow":
  2092. if {mineplex.%{_p}%.cosmetics.morphs.owned.cow} is 1:
  2093. message "&9Gadget> &7You already own this morph!" to {_p}
  2094. else:
  2095. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f60000 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2096. format slot 22 of {_p} with steak named "&fCow Morph" with lore "&fMooooo!" to be unstealable
  2097. if {_arg2} is "morph_slime":
  2098. if {mineplex.%{_p}%.cosmetics.morphs.owned.slime} is 1:
  2099. message "&9Gadget> &7You already own this morph!" to {_p}
  2100. else:
  2101. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f20000 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2102. format slot 22 of {_p} with slimeball named "&fSlime Morph" with lore "&fSplat Splat!" to be unstealable
  2103. if {_arg2} is "morph_villager":
  2104. if {mineplex.%{_p}%.cosmetics.morphs.owned.villager} is 1:
  2105. message "&9Gadget> &7You already own this morph!" to {_p}
  2106. else:
  2107. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f12000 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2108. format slot 22 of {_p} with emerald named "&fVillager Morph" with lore "&fMURRR! HURR MURRR!" to be unstealable
  2109. #Gadgets
  2110. if {_arg2} is "pearl":
  2111. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f500 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2112. format slot 22 of {_p} with ender pearl named "&fEthereal Pearl" with lore "&fThese Pearls are stolen from||&fsleeping Endermen!" to be unstealable
  2113. if {_arg2} is "firework":
  2114. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f500 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2115. format slot 22 of {_p} with firework rocket named "&fFirework" with lore "&fNeed to celebrate? These||&fFireworks should do the trick!" to be unstealable
  2116. if {_arg2} is "tnt":
  2117. format slot 4 of {_p} with prismarine shard named "&fTreasure Shards" with lore "&f500 Treasure Shards will be||&fdeducated from your account balance" to be unstealable
  2118. format slot 22 of {_p} with tnt named "&fTNT" with lore "&fThowing tnt at %{mineplex.config.servername}%||&fStaff is highly encouraged!" to be unstealable
  2119. if {_arg1} is "confirm":
  2120. if {_arg2} is "mount_slime":
  2121. if {mineplex.shards.%{_p}%} is bigger than 9999:
  2122. set {mineplex.proc.slot} to 45
  2123. wait 2 ticks
  2124. open chest with 6 rows named " Confirmation" to {_p}
  2125. loop 9 times:
  2126. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2127. wait 1 tick
  2128. add 1 to {mineplex.proc.slot}
  2129. if {mineplex.proc.slot} is 54:
  2130. message "&9Cosmetics> &7Purchased &eSlime Mount" to {mineplex.chest.buyplayer.%{_p}%}
  2131. set {mineplex.%{_p}%.cosmetics.morphs.owned.slime} to 1
  2132. delShards({_p}, 10000)
  2133. add 1 to {mineplex.%{_p}%.cosmetics.mounts}
  2134. set {mineplex.error.slot} to 0
  2135. loop 54 times:
  2136. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased &eCreeper Morph" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2137. add 1 to {mineplex.error.slot}
  2138. wait 2 ticks
  2139. stop
  2140. if {mineplex.shards.%{_p}%} is not bigger than 9999:
  2141. wait 2 ticks
  2142. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2143. set {mineplex.error.slot} to 0
  2144. loop 54 times:
  2145. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "mounts", {_p})]
  2146. add 1 to {mineplex.error.slot}
  2147. if {_arg1} is "use":
  2148. if {_arg2} is "mount_slime":
  2149. if {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} is not 1:
  2150. message "&9Gadget> &7You dont own this mount." to {_p}
  2151. stop
  2152. if {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} is 1:
  2153. if {mineplex.currentmorph.%{_p}%} is not set:
  2154. set {mineplex.currentmorph.%{_p}%} to "None"
  2155. if {currentmount.%{_p}%.type} is not "Slime Mount":
  2156. if {currentmount.%{_p}%.type} is not "None":
  2157. message "&9Gadget> &7You despawned &e%{currentmount.%{_p}%.type}%" to {_p}
  2158. message "&9Gadget> &7You spawned &eSlime Mount" to {_p}
  2159. mountapi({_p}, "create", "slime")
  2160. cosmetic_system("menu", "mounts", {_p})
  2161. stop
  2162. if {currentmount.%{_p}%.type} is "Slime Mount":
  2163. message "&9Gadget> &7You despawned &e%{currentmount.%{_p}%.type}%" to {_p}
  2164. set {mineplex.currentmorph.%{_p}%} to "None"
  2165. mountapi({_p}, "remove", "notused")
  2166. cosmetic_system("menu", "morphs", {_p})
  2167. stop
  2168. if {_arg1} is "confirm":
  2169. if {_arg2} is "morph_creeper":
  2170. if {mineplex.shards.%{_p}%} is bigger than 9999:
  2171. set {mineplex.proc.slot} to 45
  2172. wait 2 ticks
  2173. open chest with 6 rows named " Confirmation" to {_p}
  2174. loop 9 times:
  2175. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2176. wait 1 tick
  2177. add 1 to {mineplex.proc.slot}
  2178. if {mineplex.proc.slot} is 54:
  2179. message "&9Cosmetics> &7Purchased &eCreeper Morph" to {mineplex.chest.buyplayer.%{_p}%}
  2180. set {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} to 1
  2181. delShards({_p}, 10000)
  2182. add 1 to {mineplex.%{_p}%.cosmetics.morphs}
  2183. set {mineplex.error.slot} to 0
  2184. loop 54 times:
  2185. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased &eCreeper Morph" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2186. add 1 to {mineplex.error.slot}
  2187. wait 2 ticks
  2188. stop
  2189. if {mineplex.shards.%{_p}%} is not bigger than 9999:
  2190. wait 2 ticks
  2191. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2192. set {mineplex.error.slot} to 0
  2193. loop 54 times:
  2194. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2195. add 1 to {mineplex.error.slot}
  2196. if {_arg1} is "use":
  2197. if {_arg2} is "morph_creeper":
  2198. if {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} is not 1:
  2199. message "&9Gadget> &7You dont own this morph." to {_p}
  2200. stop
  2201. if {mineplex.%{_p}%.cosmetics.morphs.owned.creeper} is 1:
  2202. if {mineplex.currentmorph.%{_p}%} is not set:
  2203. set {mineplex.currentmorph.%{_p}%} to "None"
  2204. if {mineplex.currentmorph.%{_p}%} is not "Creeper Morph":
  2205. if {mineplex.currentmorph.%{_p}%} is not "None":
  2206. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2207. message "&9Gadget> &7You morphed into &eCreeper Morph" to {_p}
  2208. set {mineplex.currentmorph.%{_p}%} to "Creeper Morph"
  2209. execute console command "odisguise %{_p}% creeper"
  2210. cosmetic_system("menu", "morphs", {_p})
  2211. stop
  2212. if {mineplex.currentmorph.%{_p}%} is "Creeper Morph":
  2213. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2214. set {mineplex.currentmorph.%{_p}%} to "None"
  2215. execute console command "undisguise %{_p}%"
  2216. cosmetic_system("menu", "morphs", {_p})
  2217. stop
  2218. if {_arg1} is "use":
  2219. if {_arg2} is "morph_wither":
  2220. if {_p} has permission "mineplex.legend":
  2221. if {mineplex.currentmorph.%{_p}%} is not set:
  2222. set {mineplex.currentmorph.%{_p}%} to "None"
  2223. if {mineplex.currentmorph.%{_p}%} is not "Wither Morph":
  2224. if {mineplex.currentmorph.%{_p}%} is not "None":
  2225. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2226. message "&9Gadget> &7You morphed into &eWither Morph" to {_p}
  2227. set {mineplex.currentmorph.%{_p}%} to "Wither Morph"
  2228. execute console command "odisguise %{_p}% wither"
  2229. set {mineplex.dj.%{_p}%} to 0
  2230. set {_p}'s flight state to true
  2231. cosmetic_system("menu", "morphs", {_p})
  2232. stop
  2233. if {mineplex.currentmorph.%{_p}%} is "Wither Morph":
  2234. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2235. set {mineplex.currentmorph.%{_p}%} to "None"
  2236. execute console command "undisguise %{_p}%"
  2237. set {mineplex.dj.%{_p}%} to 1
  2238. set {_p}'s flight state to false
  2239. cosmetic_system("menu", "morphs", {_p})
  2240. stop
  2241. else:
  2242. message "&9Gadget> &7You dont own this Morph" to {_p}
  2243. if {_arg1} is "confirm":
  2244. if {_arg2} is "morph_cow":
  2245. if {mineplex.shards.%{_p}%} is bigger than 5999:
  2246. set {mineplex.proc.slot} to 45
  2247. wait 2 ticks
  2248. open chest with 6 rows named " Confirmation" to {_p}
  2249. loop 9 times:
  2250. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2251. wait 1 tick
  2252. add 1 to {mineplex.proc.slot}
  2253. if {mineplex.proc.slot} is 54:
  2254. message "&9Cosmetics> &7Purchased &eCow Morph" to {mineplex.chest.buyplayer.%{_p}%}
  2255. set {mineplex.%{_p}%.cosmetics.morphs.owned.cow} to 1
  2256. delShards({_p}, 6000)
  2257. add 1 to {mineplex.%{_p}%.cosmetics.morphs}
  2258. set {mineplex.error.slot} to 0
  2259. loop 54 times:
  2260. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased &eCow Morph" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2261. add 1 to {mineplex.error.slot}
  2262. wait 2 ticks
  2263. stop
  2264. if {mineplex.shards.%{_p}%} is not bigger than 9999:
  2265. wait 2 ticks
  2266. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2267. set {mineplex.error.slot} to 0
  2268. loop 54 times:
  2269. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2270. add 1 to {mineplex.error.slot}
  2271. if {_arg1} is "use":
  2272. if {_arg2} is "morph_cow":
  2273. if {mineplex.%{_p}%.cosmetics.morphs.owned.cow} is not 1:
  2274. message "&9Gadget> &7You dont own this morph." to {_p}
  2275. stop
  2276. if {mineplex.%{_p}%.cosmetics.morphs.owned.cow} is 1:
  2277. if {mineplex.currentmorph.%{_p}%} is not set:
  2278. set {mineplex.currentmorph.%{_p}%} to "None"
  2279. if {mineplex.currentmorph.%{_p}%} is not "Cow Morph":
  2280. if {mineplex.currentmorph.%{_p}%} is not "None":
  2281. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2282. message "&9Gadget> &7You morphed into &eCow Morph" to {_p}
  2283. set {mineplex.currentmorph.%{_p}%} to "Cow Morph"
  2284. execute console command "odisguise %{_p}% cow"
  2285. cosmetic_system("menu", "morphs", {_p})
  2286. stop
  2287. if {mineplex.currentmorph.%{_p}%} is "Cow Morph":
  2288. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2289. set {mineplex.currentmorph.%{_p}%} to "None"
  2290. execute console command "undisguise %{_p}%"
  2291. cosmetic_system("menu", "morphs", {_p})
  2292. stop
  2293. if {_arg1} is "confirm":
  2294. if {_arg2} is "morph_slime":
  2295. if {mineplex.shards.%{_p}%} is bigger than 19999:
  2296. set {mineplex.proc.slot} to 45
  2297. wait 2 ticks
  2298. open chest with 6 rows named " Confirmation" to {_p}
  2299. loop 9 times:
  2300. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2301. wait 1 tick
  2302. add 1 to {mineplex.proc.slot}
  2303. if {mineplex.proc.slot} is 54:
  2304. message "&9Cosmetics> &7Purchased &eSlime Morph" to {mineplex.chest.buyplayer.%{_p}%}
  2305. set {mineplex.%{_p}%.cosmetics.morphs.owned.slime} to 1
  2306. delShards({_p}, 20000)
  2307. add 1 to {mineplex.%{_p}%.cosmetics.morphs}
  2308. set {mineplex.error.slot} to 0
  2309. loop 54 times:
  2310. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased &eSlime Morph" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2311. add 1 to {mineplex.error.slot}
  2312. wait 2 ticks
  2313. stop
  2314. if {mineplex.shards.%{_p}%} is not bigger than 19999:
  2315. wait 2 ticks
  2316. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2317. set {mineplex.error.slot} to 0
  2318. loop 54 times:
  2319. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2320. add 1 to {mineplex.error.slot}
  2321. if {_arg1} is "use":
  2322. if {_arg2} is "morph_slime":
  2323. if {mineplex.%{_p}%.cosmetics.morphs.owned.slime} is not 1:
  2324. message "&9Gadget> &7You dont own this morph." to {_p}
  2325. stop
  2326. if {mineplex.%{_p}%.cosmetics.morphs.owned.slime} is 1:
  2327. if {mineplex.currentmorph.%{_p}%} is not set:
  2328. set {mineplex.currentmorph.%{_p}%} to "None"
  2329. if {mineplex.currentmorph.%{_p}%} is not "Slime Morph":
  2330. if {mineplex.currentmorph.%{_p}%} is not "None":
  2331. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2332. message "&9Gadget> &7You morphed into &eSlime Morph" to {_p}
  2333. set {mineplex.currentmorph.%{_p}%} to "Slime Morph"
  2334. execute console command "odisguise %{_p}% slime"
  2335. cosmetic_system("menu", "morphs", {_p})
  2336. stop
  2337. if {mineplex.currentmorph.%{_p}%} is "Slime Morph":
  2338. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2339. set {mineplex.currentmorph.%{_p}%} to "None"
  2340. execute console command "undisguise %{_p}%"
  2341. cosmetic_system("menu", "morphs", {_p})
  2342. stop
  2343. if {_arg1} is "confirm":
  2344. if {_arg2} is "morph_villager":
  2345. if {mineplex.shards.%{_p}%} is bigger than 11999:
  2346. set {mineplex.proc.slot} to 45
  2347. wait 2 ticks
  2348. open chest with 6 rows named " Confirmation" to {_p}
  2349. loop 9 times:
  2350. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2351. wait 1 tick
  2352. add 1 to {mineplex.proc.slot}
  2353. if {mineplex.proc.slot} is 54:
  2354. message "&9Cosmetics> &7Purchased &eVillager Morph" to {mineplex.chest.buyplayer.%{_p}%}
  2355. set {mineplex.%{_p}%.cosmetics.morphs.owned.villager} to 1
  2356. delShards({_p}, 12000)
  2357. add 1 to {mineplex.%{_p}%.cosmetics.morphs}
  2358. set {mineplex.error.slot} to 0
  2359. loop 54 times:
  2360. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased &eVillager morph" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2361. add 1 to {mineplex.error.slot}
  2362. wait 2 ticks
  2363. stop
  2364. if {mineplex.shards.%{_p}%} is not bigger than 499:
  2365. wait 3 ticks
  2366. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2367. wait 2 ticks
  2368. set {mineplex.error.slot} to 0
  2369. loop 54 times:
  2370. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "morphs", {_p})]
  2371. add 1 to {mineplex.error.slot}
  2372. if {_arg1} is "use":
  2373. if {_arg2} is "morph_villager":
  2374. if {mineplex.%{_p}%.cosmetics.morphs.owned.villager} is not 1:
  2375. message "&9Gadget> &7You dont own this morph." to {_p}
  2376. stop
  2377. if {mineplex.%{_p}%.cosmetics.morphs.owned.villager} is 1:
  2378. if {mineplex.currentmorph.%{_p}%} is not set:
  2379. set {mineplex.currentmorph.%{_p}%} to "None"
  2380. if {mineplex.currentmorph.%{_p}%} is not "villager Morph":
  2381. if {mineplex.currentmorph.%{_p}%} is not "None":
  2382. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2383. message "&9Gadget> &7You morphed into &eVillager Morph" to {_p}
  2384. set {mineplex.currentmorph.%{_p}%} to "Villager Morph"
  2385. execute console command "odisguise %{_p}% villager"
  2386. cosmetic_system("menu", "morphs", {_p})
  2387. stop
  2388. if {mineplex.currentmorph.%{_p}%} is "Villager Morph":
  2389. message "&9Gadget> &7You unmorphed from &e%{mineplex.currentmorph.%{_p}%}%" to {_p}
  2390. set {mineplex.currentmorph.%{_p}%} to "None"
  2391. execute console command "undisguise %{_p}%"
  2392. cosmetic_system("menu", "morphs", {_p})
  2393. stop
  2394. if {_arg1} is "use":
  2395. if {_arg2} is "pearl":
  2396. if {mineplex.gadget.selected.%{_p}%} is "Ethereal Pearl":
  2397. message "&9Gadget> &7You unequipped &eEthereal Pearl" to {_p}
  2398. set {mineplex.gadget.selected.%{_p}%} to "None"
  2399. set slot 3 of {_p} to air with name "lolz"
  2400. cosmetic_system("menu", "gadgets", {_p})
  2401. stop
  2402. message "&9Cosmetics> &7You equipped &eEthereal Pearl" to {_p}
  2403. set slot 3 of {_p} to ender pearl with name "&e%{mineplex.%{_p}%.cosmetics.gadgets.pearl}% &5Ethereal Pearls"
  2404. set {mineplex.gadget.selected.%{_p}%} to "Ethereal Pearl"
  2405. cosmetic_system("menu", "gadgets", {_p})
  2406. stop
  2407. if {_arg1} is "confirm":
  2408. if {_arg2} is "pearl":
  2409. if {mineplex.shards.%{_p}%} is bigger than 499:
  2410. set {mineplex.proc.slot} to 45
  2411. wait 2 ticks
  2412. open chest with 6 rows named " Confirmation" to {_p}
  2413. loop 9 times:
  2414. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2415. wait 1 tick
  2416. add 1 to {mineplex.proc.slot}
  2417. if {mineplex.proc.slot} is 54:
  2418. message "&9Cosmetics> &7Purchased 50x &eEthereal Pearl" to {mineplex.chest.buyplayer.%{_p}%}
  2419. add 50 to {mineplex.%{_p}%.cosmetics.gadgets.pearl}
  2420. delShards({_p}, 50)
  2421. set {mineplex.error.slot} to 0
  2422. loop 54 times:
  2423. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased 50x &eEthereal Pearl" to close then run [cosmetic_system("menu", "gadgets", {_p})]
  2424. add 1 to {mineplex.error.slot}
  2425. wait 2 ticks
  2426. stop
  2427. if {mineplex.shards.%{_p}%} is not bigger than 499:
  2428. wait 2 ticks
  2429. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2430. set {mineplex.error.slot} to 0
  2431. loop 54 times:
  2432. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "gadgets", {_p})]
  2433. add 1 to {mineplex.error.slot}
  2434. if {_arg1} is "use":
  2435. if {_arg2} is "firework":
  2436. if {mineplex.gadget.selected.%{_p}%} is "Fireworks":
  2437. message "&9Gadget> &7You unequipped &eFireworks" to {_p}
  2438. set {mineplex.gadget.selected.%{_p}%} to "None"
  2439. set slot 3 of {_p} to air with name "lolz"
  2440. cosmetic_system("menu", "gadgets", {_p})
  2441. stop
  2442. message "&9Gadget> &7You equipped &eFireworks" to {_p}
  2443. set slot 3 of {_p} to ender pearl with name "&e%{mineplex.%{_p}%.cosmetics.gadgets.firework}% &eFireworks"
  2444. set {mineplex.gadget.selected.%{_p}%} to "Fireworks"
  2445. cosmetic_system("menu", "gadgets", {_p})
  2446. stop
  2447. if {_arg1} is "use":
  2448. if {_arg2} is "tnt":
  2449. if {mineplex.gadget.selected.%{_p}%} is "TNT":
  2450. message "&9Gadget> &7You unequipped &eTNT" to {_p}
  2451. set {mineplex.gadget.selected.%{_p}%} to "None"
  2452. set slot 3 of {_p} to air with name "lolz"
  2453. cosmetic_system("menu", "gadgets", {_p})
  2454. stop
  2455. message "&9Gadget> &7You equipped &eTNT" to {_p}
  2456. set slot 3 of {_p} to tnt with name "&e%{mineplex.%{_p}%.cosmetics.gadgets.tnt}% &eTNT"
  2457. set {mineplex.gadget.selected.%{_p}%} to "TNT"
  2458. cosmetic_system("menu", "gadgets", {_p})
  2459. if {_arg1} is "use":
  2460. if {_arg2} is "snowball":
  2461. if {mineplex.gadget.selected.%{_p}%} is "Snowball":
  2462. message "&9Gadget> &7You unequipped &eSnowball" to {_p}
  2463. set {mineplex.gadget.selected.%{_p}%} to "None"
  2464. set slot 3 of {_p} to air with name "lolz"
  2465. cosmetic_system("menu", "gadgets", {_p})
  2466. stop
  2467. message "&9Gadget> &7You equipped &eSnowball" to {_p}
  2468. set slot 3 of {_p} to tnt with name "&e%{mineplex.%{_p}%.cosmetics.gadgets.snowball}% &eSnowballs"
  2469. set {mineplex.gadget.selected.%{_p}%} to "Snowball"
  2470. cosmetic_system("menu", "gadgets", {_p})
  2471. if {_arg1} is "confirm":
  2472. if {_arg2} is "firework":
  2473. if {mineplex.shards.%{_p}%} is bigger than 499:
  2474. set {mineplex.proc.slot} to 45
  2475. wait 2 ticks
  2476. open chest with 6 rows named " Confirmation" to {_p}
  2477. loop 9 times:
  2478. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2479. wait 1 tick
  2480. add 1 to {mineplex.proc.slot}
  2481. if {mineplex.proc.slot} is 54:
  2482. message "&9Cosmetics> &7Purchased 50x &eFireworks" to {_p}
  2483. add 50 to {mineplex.%{_p}%.cosmetics.gadgets.firework}
  2484. delShards({_p}, 500)
  2485. set {mineplex.error.slot} to 0
  2486. loop 54 times:
  2487. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased 50x &eFirworks" to close then run [cosmetic_system("menu", "gadgets", {_p})]
  2488. add 1 to {mineplex.error.slot}
  2489. wait 2 ticks
  2490. stop
  2491. if {mineplex.shards.%{_p}%} is not bigger than 499:
  2492. wait 2 ticks
  2493. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2494. set {mineplex.error.slot} to 0
  2495. loop 54 times:
  2496. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "gadgets", {_p})]
  2497. add 1 to {mineplex.error.slot}
  2498. if {_arg1} is "confirm":
  2499. if {_arg2} is "tnt":
  2500. if {mineplex.shards.%{_p}%} is bigger than 499:
  2501. set {mineplex.proc.slot} to 45
  2502. wait 2 ticks
  2503. open chest with 6 rows named " Confirmation" to {_p}
  2504. loop 9 times:
  2505. format slot {mineplex.proc.slot} of {_p} with lapis block named "&9Processing" with lore "" to close
  2506. wait 1 tick
  2507. add 1 to {mineplex.proc.slot}
  2508. if {mineplex.proc.slot} is 54:
  2509. message "&9Cosmetics> &7Purchased 50x &eTNT" to {_p}
  2510. add 50 to {mineplex.%{_p}%.cosmetics.gadgets.tnt}
  2511. delShards({_p}, 500)
  2512. set {mineplex.error.slot} to 0
  2513. loop 54 times:
  2514. format slot {mineplex.error.slot} of {_p} with emerald block named "&aPurchase Successful" with lore "&7Purchased 50x &eTNT" to close then run [cosmetic_system("menu", "gadgets", {_p})]
  2515. add 1 to {mineplex.error.slot}
  2516. wait 2 ticks
  2517. stop
  2518. if {mineplex.shards.%{_p}%} is not bigger than 499:
  2519. wait 2 ticks
  2520. open chest with 6 rows named " Confirmation" to {mineplex.chest.buyplayer.%{_p}%}
  2521. set {mineplex.error.slot} to 0
  2522. loop 54 times:
  2523. format slot {mineplex.error.slot} of {_p} with redstone block named "&cPurchase Failed" with lore "" to close then run [cosmetic_system("menu", "gadgets", {_p})]
  2524. add 1 to {mineplex.error.slot}
  2525.  
  2526. on right click:
  2527. if player is holding chest:
  2528. if name of player's tool is "&aCosmetic Menu":
  2529. cancel event
  2530. cosmetic_system("menu", "main", player)
  2531.  
  2532. on left click:
  2533. if player is holding chest:
  2534. if name of player's tool is "&aCosmetic Menu":
  2535. cancel event
  2536. cosmetic_system("menu", "main", player)
  2537.  
  2538. on damage:
  2539. victim's name contains "Pet"
  2540. cancel event
  2541.  
  2542. on any move:
  2543. if {mineplex.particle.selected.%player%} is "shadow":
  2544. loop all players:
  2545. show 1 "footstep" particles at location of player for loop-player offset by 0.4, 0.7, 0.4
  2546. if {mineplex.particle.selected.%player%} is "flame":
  2547. loop all players:
  2548. show 1 "flame" particles at location of player for loop-player offset by 0.4, 0.7, 0.4
  2549.  
  2550. command /giveitem [<player>] [<number>] [<text>]:
  2551. permission: mineplex.admin
  2552. permission message: &9Permissions> &7This requires permission rank [&9ADMIN&7].
  2553. trigger:
  2554. if arg 3 is "hat_compCube":
  2555. if {mineplex.hat.%arg 1%.owned.compCube} is 1:
  2556. message "&9Cosmetics> &e%arg 1% &7already owns &eCompanion Cube"
  2557. stop
  2558. set {mineplex.hat.%arg 1%.owned.compCube} to 1
  2559. add 1 to {mineplex.%arg 1%.cosmetics.hats}
  2560. message "&9Cosmetics> &7You gave &e%arg 1% Companion Cube" to player
  2561. message "&9Cosmetics> &7You recieved the &eCompanion Cube &7from &e%player%" to arg 1
  2562. stop
  2563. if arg 3 is "hat_present":
  2564. if {mineplex.hat.%arg 1%.owned.present} is 1:
  2565. message "&9Cosmetics> &e%arg 1% &7already owns &ePresent"
  2566. stop
  2567. set {mineplex.hat.%arg 1%.owned.present} to 1
  2568. add 1 to {mineplex.%arg 1%.cosmetics.hats}
  2569. message "&9Cosmetics> &7You gave &e%arg 1% Present" to player
  2570. message "&9Cosmetics> &7You recieved the &ePresent &7from &e%player%" to arg 1
  2571. stop
  2572. if arg 3 is "particle_shadow":
  2573. if {mineplex.particle.%arg 1%.owned.shadow} is 1:
  2574. message "&9Cosmetics> &e%arg 1% &7already owns &eShadow Walk"
  2575. stop
  2576. set {mineplex.particle.%arg 1%.owned.shadow} to 1
  2577. add 1 to {mineplex.%arg 1%.cosmetics.particles}
  2578. message "&9Cosmetics> &7You gave &e%arg 1% Shadow Walk" to player
  2579. message "&9Cosmetics> &7You recieved the &eShadow Walk &7from &e%player%" to arg 1
  2580. stop
  2581. if arg 3 is "particle_flame":
  2582. if {mineplex.particle.%arg 1%.owned.flame} is 1:
  2583. message "&9Cosmetics> &e%arg 1% &7already owns &eShadow Walk"
  2584. stop
  2585. set {mineplex.particle.%arg 1%.owned.flame} to 1
  2586. add 1 to {mineplex.%arg 1%.cosmetics.particles}
  2587. message "&9Cosmetics> &7You gave &e%arg 1% Flame Rings" to player
  2588. message "&9Cosmetics> &7You recieved the &eFlame Rings &7from &e%player%" to arg 1
  2589. stop
  2590. if arg 3 is "take:hat_compCube":
  2591. if {mineplex.hat.%arg 1%.owned.compCube} is 0:
  2592. message "&9Cosmetics> &e%arg 1% &7doesnt own &eCompanion Cube"
  2593. stop
  2594. set {mineplex.hat.%arg 1%.owned.compCube} to 0
  2595. remove 1 from {mineplex.%arg 1%.cosmetics.hats}
  2596. message "&9Cosmetics> &7You took &e%arg 1%'s Companion Cube" to player
  2597. message "&9Cosmetics> &e%player% &7took your &eCompanion Cube" to arg 1
  2598. stop
  2599. if arg 3 is "take:hat_present":
  2600. if {mineplex.hat.%arg 1%.owned.present} is 0:
  2601. message "&9Cosmetics> &e%arg 1% &7doesnt own &ePresent"
  2602. stop
  2603. set {mineplex.hat.%arg 1%.owned.present} to 0
  2604. remove 1 from {mineplex.%arg 1%.cosmetics.hats}
  2605. message "&9Cosmetics> &7You took &e%arg 1%'s Present" to player
  2606. message "&9Cosmetics> &e%player% &7took your &ePresent" to arg 1
  2607. stop
  2608. if arg 3 is "pearl":
  2609. add arg 2 to {mineplex.%arg 1%.cosmetics.gadgets.pearl}
  2610. message "&9Item> &7You gave %arg 2% Ethereal Pearls &7to player %arg 1%" to player
  2611. message "&9Item> &e%player% &7gave you &e%arg 2% Ethereal Pearls" to arg 1
  2612. stop
  2613. if arg 3 is "fireworks":
  2614. add arg 2 to {mineplex.%arg 1%.cosmetics.gadgets.firework}
  2615. message "&9Item> &7You gave %arg 2% Fireworks &7to player %arg 1%" to player
  2616. message "&9Item> &e%player% &7gave you &e%arg 2% Fireworks" to arg 1
  2617. stop
  2618. if arg 3 is "coal":
  2619. add arg 2 to {mineplex.%arg 1%.cosmetics.gadgets.coal}
  2620. message "&9Item> &7You gave %arg 2% Coal &7to player %arg 1%" to player
  2621. message "&9Item> &e%player% &7gave you &e%arg 2% Coal" to arg 1
  2622. stop
  2623. if arg 3 is "tnt":
  2624. add arg 2 to {mineplex.%arg 1%.cosmetics.gadgets.tnt}
  2625. message "&9Item> &7You gave %arg 2% TNT &7to player %arg 1%" to player
  2626. message "&9Item> &e%player% &7gave you &e%arg 2% TNT" to arg 1
  2627. stop
  2628. if arg 3 is "snowball":
  2629. add arg 2 to {mineplex.%arg 1%.cosmetics.gadgets.snowball}
  2630. message "&9Item> &7You gave %arg 2% Snowballs &7to player %arg 1%" to player
  2631. message "&9Item> &e%player% &7gave you &e%arg 2% Snowballs" to arg 1
  2632. stop
  2633. message "&9Cosmetics> &c&lInvalid Cosmetic."
  2634.  
  2635.  
  2636. command /gadget:
  2637. permission: mineplex.admin
  2638. permission message: &9Permissions> &7This requires permission rank [&9ADMIN&7].
  2639. trigger:
  2640. if {mineplex.cosmetics} is not set:
  2641. set {mineplex.cosmetics} to 1
  2642. if {mineplex.cosmetics} is 1:
  2643. set {mineplex.cosmetics} to 0
  2644. broadcast "&f&lGadgets/Mounts are now &c&lDisabled"
  2645. stop
  2646. if {mineplex.cosmetics} is 0:
  2647. set {mineplex.cosmetics} to 1
  2648. broadcast "&f&lGadgets/Mounts are now &a&lEnabled"
  2649. stop
  2650.  
  2651. every tick:
  2652. loop all players:
  2653. if {mineplex.cosmetics} is not set:
  2654. set {mineplex.cosmetics} to 1
  2655. if {mineplex.cosmetics} is 0:
  2656. set slot 3 of loop-player to air with name "remove"
  2657. stop
  2658. loop-player's gamemode is not creative:
  2659. if {mineplex.cosmetics.%loop-player%} is not set:
  2660. set {mineplex.cosmetics.%loop-player%} to 1
  2661. if {mineplex.gadget.selected.%loop-player%} is "Ethereal Pearl":
  2662. set slot 3 of loop-player to ender pearl with name "&e%{mineplex.%loop-player%.cosmetics.gadgets.pearl}% Ethereal Pearl"
  2663. if {mineplex.gadget.selected.%loop-player%} is "Fireworks":
  2664. set slot 3 of loop-player to firework rocket with name "&e%{mineplex.%loop-player%.cosmetics.gadgets.firework}% Fireworks"
  2665. if {mineplex.gadget.selected.%loop-player%} is "Coal":
  2666. set slot 3 of loop-player to coal with name "&e%{mineplex.%loop-player%.cosmetics.gadgets.coal}% Coal"
  2667. if {mineplex.gadget.selected.%loop-player%} is "TNT":
  2668. set slot 3 of loop-player to tnt with name "&e%{mineplex.%loop-player%.cosmetics.gadgets.tnt}% TNT"
  2669. if {mineplex.gadget.selected.%loop-player%} is "Snowball":
  2670. set slot 3 of loop-player to snowball with name "&e%{mineplex.%loop-player%.cosmetics.gadgets.snowball}% Snowballs"
  2671.  
  2672.  
  2673. on shoot:
  2674. if projectile is an enderpearl:
  2675. if name of shooter's tool is "&e%{mineplex.%shooter%.cosmetics.gadgets.pearl}% Ethereal Pearl":
  2676. if {mineplex.%shooter%.cosmetics.gadgets.pearl} is 0:
  2677. cancel event
  2678. cosmetic_system("buy", "pearl", shooter)
  2679. stop
  2680. if {mineplex.%shooter%.cosmetics.gadgets.pearlCooldown} is 1:
  2681. set action bar of shooter to "&f&lEthereal Pearl is recharging"
  2682. cancel event
  2683. stop
  2684. remove 1 from {mineplex.%shooter%.cosmetics.gadgets.pearl}
  2685. set {mineplex.%shooter%.cosmetics.gadgets.pearlCooldown} to 1
  2686. message "&9Skill> &7You threw &aEthereal Pearl&7." to shooter
  2687. make shooter ride projectile
  2688. wait 3 ticks
  2689. make shooter ride projectile
  2690. wait 3 seconds
  2691. set {mineplex.%shooter%.cosmetics.gadgets.pearlCooldown} to 0
  2692. set action bar of shooter to "&a&lEthereal Pearl Recharged."
  2693. if projectile is an snowball:
  2694. if name of shooter's tool is "&e%{mineplex.%shooter%.cosmetics.gadgets.snowball}% Snowballs":
  2695. if {mineplex.%shooter%.cosmetics.gadgets.snowball} is 0:
  2696. cancel event
  2697. message "&9Gadget> &7You have no Snowballs left!" to shooter
  2698. stop
  2699. if {mineplex.%shooter%.cosmetics.gadgets.snowballCooldown} is 1:
  2700. set action bar of shooter to "&f&lSnowball is recharging"
  2701. cancel event
  2702. stop
  2703. remove 1 from {mineplex.%shooter%.cosmetics.gadgets.snowball}
  2704. set {mineplex.%shooter%.cosmetics.gadgets.snowballCooldown} to 1
  2705. message "&9Skill> &7You threw &aSnowball&7." to shooter
  2706. wait 10 ticks
  2707. set {mineplex.%shooter%.cosmetics.gadgets.snowballCooldown} to 0
  2708. set action bar of shooter to "&a&lSnowball Recharged."
  2709.  
  2710. on right click:
  2711. if player is holding tnt:
  2712. if name of player's tool is "&e%{mineplex.%player%.cosmetics.gadgets.tnt}% TNT":
  2713. if {mineplex.%player%.cosmetics.gadgets.tnt} is less than 1:
  2714. cosmetic_system("buy", "tnt", player)
  2715. stop
  2716. if {mineplex.%player%.cosmetics.gadgets.tntCooldown} is 1:
  2717. set action bar of player to "&f&lTNT is recharging"
  2718. stop
  2719. remove 1 from {mineplex.%player%.cosmetics.gadgets.tnt}
  2720. spawn a primed tnt 1 meter above the player
  2721. add "{Fuse:60}" to nbt of the spawned entity
  2722. push the spawned entity in direction of player at speed 0.9
  2723. push the spawned entity upwards at speed 0.2
  2724. message "&9Skill> &7You threw &aTNT&7."
  2725. set {mineplex.%player%.cosmetics.gadgets.tntCooldown} to 1
  2726. wait 3 seconds
  2727. set {mineplex.%player%.cosmetics.gadgets.tntCooldown} to 0
  2728. set action bar of player to "&a&lTNT Recharged."
  2729.  
  2730. on right click:
  2731. if player is holding firework rocket:
  2732. if name of player's tool is "&e%{mineplex.%player%.cosmetics.gadgets.firework}% Fireworks":
  2733. if {mineplex.%player%.cosmetics.gadgets.firework} is 0:
  2734. cancel event
  2735. cosmetic_system("buy", "firework", player)
  2736. stop
  2737. if {mineplex.%player%.cosmetics.gadgets.fireworkCooldown} is 1:
  2738. set action bar of player to "&f&lFireworks &f&lis recharging..."
  2739. cancel event
  2740. stop
  2741. remove 1 from {mineplex.%player%.cosmetics.gadgets.firework}
  2742. cancel event
  2743. set {firework} to a random integer from 1 to 15
  2744. if {firework} is 1:
  2745. launch creeper firework colored red at player timed 1
  2746. if {firework} is 2:
  2747. launch burst firework colored green at player timed 1
  2748. if {firework} is 3:
  2749. launch ball firework colored yellow at player timed 1
  2750. if {firework} is 4:
  2751. launch ball firework colored blue at player timed 1
  2752. if {firework} is 5:
  2753. launch burst firework colored red at player timed 1
  2754. if {firework} is 6:
  2755. launch creeper firework colored light green at player timed 1
  2756. if {firework} is 7:
  2757. launch burst firework colored light green at player timed 1
  2758. if {firework} is 8:
  2759. launch ball firework colored orange at player timed 1
  2760. if {firework} is 9:
  2761. launch burst firework colored orange at player timed 1
  2762. if {firework} is 10:
  2763. launch creeper firework colored pink at player timed 1
  2764. if {firework} is 11:
  2765. launch burst firework colored orange at player timed 1
  2766. if {firework} is 12:
  2767. launch burst firework colored light green at player timed 1
  2768. if {firework} is 13:
  2769. launch burst firework colored blue at player timed 1
  2770. if {firework} is 14:
  2771. launch burst firework colored blue at player timed 1
  2772. if {firework} is 15:
  2773. launch burst firework colored yellow at player timed 1
  2774. set {mineplex.%player%.cosmetics.gadgets.fireworkCooldown} to 1
  2775. message "&9Skill> &7You used &aFireworks&7."
  2776. wait 10 ticks
  2777. set {mineplex.%player%.cosmetics.gadgets.fireworkCooldown} to 0
  2778. set action bar of player to "&a&lFireworks Recharged."
  2779. on right click:
  2780. if player is holding coal:
  2781. if name of player's tool is "&e%{mineplex.%player%.cosmetics.gadgets.coal}% Coal":
  2782. if {mineplex.%player%.cosmetics.gadgets.coal} is 0:
  2783. message "&9Coal> &7You should go and get some coal..."
  2784. stop
  2785. if {mineplex.%player%.cosmetics.gadgets.coalCooldown} is 1:
  2786. set action bar of player to "&f&lCoal &f&lis recharging..."
  2787. cancel event
  2788. stop
  2789. message "&9Skill> &7You used &aCoal&7."
  2790. set {coalMessage} to a random integer from 1 to 10
  2791. if {coalMessage} is 1:
  2792. message "&9Coal> &7Maybe you could... eat it?"
  2793. if {coalMessage} is 2:
  2794. message "&9Coal> &7Now... if you only had a furnace."
  2795. if {coalMessage} is 3:
  2796. message "&9Coal> &7Did you know a diamond is formed from coal?"
  2797. if {coalMessage} is 4:
  2798. message "&9Coal> &7Coal is a word that sounds wierd if you say it too much."
  2799. if {coalMessage} is 5:
  2800. message "&9Coal> &7Did you know coal is used for &knothing&7!"
  2801. if {coalMessage} is 6:
  2802. message "&9Coal> &7I hope you didn't miss any diamonds."
  2803. if {coalMessage} is 7:
  2804. message "&9Coal> &7Na na na na, Na na na na, &8BLACK COAL"
  2805. if {coalMessage} is 8:
  2806. message "&9Coal> &7With 9 of these you could make a Block."
  2807. if {coalMessage} is 9:
  2808. message "&9Coal> &7Lava is hotter, but coal is quicker."
  2809. if {coalMessage} is 10:
  2810. message "&9Coal> &7For what do you even need Coal on a Minigame server?"
  2811. set {mineplex.%player%.cosmetics.gadgets.coalCooldown} to 1
  2812. wait 10 ticks
  2813. set {mineplex.%player%.cosmetics.gadgets.coalCooldown} to 0
  2814. set action bar of player to "&a&lCoal Recharged."
  2815.  
  2816. #Slime mount test
  2817. on right click on slime:
  2818. if {currentmount.%player%} is not set:
  2819. delete {currentmount.%player%}
  2820. message "&9Mount> &7This is not your mount."
  2821. else:
  2822. if {currentmount.%player%} is the clicked entity:
  2823. make the player ride the clicked entity
  2824. else:
  2825. message "&9Mount> &7This is not your mount."
  2826.  
  2827.  
  2828.  
  2829. on explode:
  2830. create a safe explosion with force 3
  2831. cancel event
  2832.  
  2833. on damage:
  2834. attacker's name contains "Slime"
  2835. set damage to 0
  2836. cancel event
  2837.  
  2838. #Morph Disablers (Quit)
  2839. on quit:
  2840. if {mineplex.currentmorph.%player%} is "Creeper Morph":
  2841. cosmetic_system("use", "morph_creeper", player)
  2842. if {mineplex.currentmorph.%player%} is "Slime Morph":
  2843. cosmetic_system("use", "morph_slime", player)
  2844. if {mineplex.currentmorph.%player%} is "Cow Morph":
  2845. cosmetic_system("use", "morph_cow", player)
  2846. if {mineplex.currentmorph.%player%} is "Villager Morph":
  2847. cosmetic_system("use", "morph_villager", player)
  2848. if {mineplex.currentmorph.%player%} is "Wither Morph":
  2849. cosmetic_system("use", "morph_wither", player)
  2850.  
  2851. #Treasure System
  2852.  
  2853. function resetPoints(p: offline player, l: number) :: number:
  2854. delete {mineplex.chestbusy.%{_l}%}
  2855. delete {mineplex.inchest.%{_p}%}
  2856. delete {mineplex.chestsopened.%{_p}%}
  2857. set block at {mineplex.chestpoint.%{_l}%.sub.1} to air
  2858. set block at {mineplex.chestpoint.%{_l}%.sub.2} to air
  2859. set block at {mineplex.chestpoint.%{_l}%.sub.3} to air
  2860. set block at {mineplex.chestpoint.%{_l}%.sub.4} to air
  2861. set block at {mineplex.chestpoint.%{_l}%.sub.5} to air
  2862. set block at {mineplex.chestpoint.%{_l}%.sub.6} to air
  2863. set block at {mineplex.chestpoint.%{_l}%.sub.7} to air
  2864. set block at {mineplex.chestpoint.%{_l}%.sub.8} to air
  2865. set block at {mineplex.chestpoint.%{_l}%} to chest
  2866.  
  2867. function rewardTreasure(p: player , c: number , l: number , s: number) :: number:
  2868. set {_mineplex.chestpoint.%{_l}%.sub.%{_s}%} to {mineplex.chestpoint.%{_l}%.sub.%{_s}%}
  2869. add 0 to y-coordinate of {_mineplex.chestpoint.%{_l}%.sub.%{_s}%}
  2870. if {_c} is 3:
  2871. set {_r} to a random integer between 1 and 350
  2872. if {_r} is 50:
  2873. if {mineplex.rank.%{_p}%} is "":
  2874. set {_ra} to "ULTRA"
  2875. else if {mineplex.rank.%{_p}%} is "&b&lULTRA ":
  2876. set {_ra} to "HERO"
  2877. else if {mineplex.rank.%{_p}%} is "&d&lHERO ":
  2878. set {_ra} to "LEGEND"
  2879. else if {mineplex.rank.%{_p}%} is "&a&lLEGEND ":
  2880. set {_ra} to "TITAN"
  2881. else if {mineplex.rank.%{_p}%} is "&c&lTITAN ":
  2882. set {_ra} to "ETERNAL"
  2883. else:
  2884. set {_ra} to a random integer between 2750 and 3750
  2885. broadcast "&9Treasure> &e%{_p}% &7found &aLegendary %{_ra}% Shards&7."
  2886. addShards({_p}, {_ra})
  2887. wait 2.25 seconds
  2888. execute console command "/updaterank %{_p}% %{_ra}%"
  2889. broadcast "&9Treasure> &e%{_p}% &7found &cMythical %{_ra}% Rank&7."
  2890. send all players title "&eTreasure" with subtitle "&f%{_p}% has found &cMythical Rank Upgrade" for 10 seconds
  2891. else if {_r} is 45 or 46 or 47 or 48 or 49 or 51 or 52 or 53 or 54 or 55:
  2892. set {_ra} to a random integer between 1500 and 2250
  2893. broadcast "&9Treasure> &e%{_p}% &7found &aLegendary %{_ra}% Shards&7."
  2894. addShards({_p}, {_ra})
  2895. else if {_r} is 35 or 36 or 37 or 38 or 39 or 40 or 41 or 42 or 43 or 44 or 65 or 64 or 63 or 62 or 61 or 60 or 59 or 58 or 57 or 56 or 55:
  2896. set {_ra} to a random integer between 1025 and 1495
  2897. broadcast "&9Treasure> &e%{_p}% &7found &bSuper Rare %{_ra}% Shards&7."
  2898. addShards({_p}, {_ra})
  2899. else if {_r} is 21 or 22 or 23 or 24 or 25 or 26 or 27 or 28 or 29 or 30 or 31 or 32 or 33 or 34 or 65 or 66 or 67 or 68:
  2900. set {_ra} to a random integer between 525 and 985
  2901. send "&9Treasure> &7You found &dRare %{_ra}% Shards&7." to {_p}
  2902. addShards({_p}, {_ra})
  2903. else:
  2904. set {_ra} to a random integer between 150 and 499
  2905. send "&9Treasure> &7You found &7Common %{_ra}% Shards&7." to {_p}
  2906. addShards({_p}, {_ra})
  2907. else:
  2908. set {_r} to a random integer between 1 and 350
  2909. if {_r} is 50:
  2910. set {_ra} to a random integer between 2750 and 3750
  2911. broadcast "&9Treasure> &e%{_p}% &7found &aLegendary %{_ra}% Shards&7."
  2912. addShards({_p}, {_ra})
  2913. else if {_r} is 45 or 46 or 47 or 48 or 49 or 51 or 52 or 53 or 54 or 55:
  2914. set {_ra} to a random integer between 1500 and 2250
  2915. broadcast "&9Treasure> &e%{_p}% &7found &aLegendary %{_ra}% Shards&7."
  2916. addShards({_p}, {_ra})
  2917. wait 2.25 seconds
  2918. resetPoints({_p}, {_l})
  2919. delete {mineplex.inchest.%{_p}%}
  2920. else if {_r} is 35 or 36 or 37 or 38 or 39 or 40 or 41 or 42 or 43 or 44 or 65 or 64 or 63 or 62 or 61 or 60 or 59 or 58 or 57 or 56 or 55:
  2921. set {_ra} to a random integer between 1025 and 1495
  2922. broadcast "&9Treasure> &e%{_p}% &7found &bSuper Rare %{_ra}% Shards&7."
  2923. addShards({_p}, {_ra})
  2924. else if {_r} is 21 or 22 or 23 or 24 or 25 or 26 or 27 or 28 or 29 or 30 or 31 or 32 or 33 or 34 or 65 or 66 or 67 or 68:
  2925. set {_ra} to a random integer between 525 and 985
  2926. send "&9Treasure> &7You found &dRare %{_ra}% Shards&7." to {_p}
  2927. addShards({_p}, {_ra})
  2928. else:
  2929. set {_ra} to a random integer between 150 and 499
  2930. send "&9Treasure> &7You found &7Common %{_ra}% Shards&7." to {_p}
  2931. addShards({_p}, {_ra})
  2932.  
  2933. on join:
  2934. if {oldchests.%player%} is not set:
  2935. set {oldchests.%player%} to 0
  2936. if {ancientchests.%player%} is not set:
  2937. set {ancientchests.%player%} to 0
  2938. if {mythicalchests.%player%} is not set:
  2939. set {mythicalchests.%player%} to 0
  2940.  
  2941. function buyChest(p: player, n: number) :: player:
  2942. if {_n} is 1:
  2943. if {mineplex.shards.%{_p}%} >= 1000:
  2944. close {_p}'s inventory
  2945. wait 3 ticks
  2946. open chest with 6 rows named " Confirmation" to {_p}
  2947. wait 5 ticks
  2948. set {_slot} to 0
  2949. format slot 0 of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  2950. loop 44 times:
  2951. format slot {_slot} of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  2952. add 1 to {_slot}
  2953. loop 10 times:
  2954. wait 0.4 ticks
  2955. format slot {_slot} of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  2956. add 1 to {slot}
  2957. delShards({_p}, 1000)
  2958. add 1 to {oldchests.%{_p}%}
  2959. wait 10 ticks
  2960. close {_p}'s inventory
  2961. else:
  2962. close {_p}'s inventory
  2963. wait 3 ticks
  2964. open chest with 6 rows named " Confirmation" to {_p}
  2965. wait 5 ticks
  2966. format slot 0 of {_p} with redstone block named "&cYour account has insufficent funds." to be unstealable
  2967. set {_slot} to 0
  2968. loop 54 times:
  2969. format slot {_slot} of {_p} with redstone block named "&cYour account has insufficent funds." to be unstealable
  2970. add 1 to {_slot}
  2971. wait 10 ticks
  2972. close {_p}'s inventory
  2973. if {_n} is 2:
  2974. if {mineplex.shards.%{_p}%} >= 5000:
  2975. close {_p}'s inventory
  2976. wait 3 ticks
  2977. open chest with 6 rows named " Confirmation" to {_p}
  2978. wait 5 ticks
  2979. set {_slot} to 0
  2980. format slot 0 of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  2981. loop 44 times:
  2982. format slot {_slot} of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  2983. add 1 to {_slot}
  2984. loop 10 times:
  2985. wait 0.4 ticks
  2986. format slot {_slot} of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  2987. add 1 to {slot}
  2988. remove 5000 from {mineplex.shards.%{_p}%}
  2989. delShards({_p}, 5000)
  2990. add 1 to {ancientchests.%{_p}%}
  2991. wait 10 ticks
  2992. close {_p}'s inventory
  2993. else:
  2994. close {_p}'s inventory
  2995. wait 3 ticks
  2996. open chest with 6 rows named " Confirmation" to {_p}
  2997. wait 5 ticks
  2998. format slot 0 of {_p} with redstone block named "&cYour account has insufficent funds." to be unstealable
  2999. set {_slot} to 0
  3000. loop 54 times:
  3001. format slot {_slot} of {_p} with redstone block named "&cYour account has insufficent funds." to be unstealable
  3002. add 1 to {_slot}
  3003. wait 10 ticks
  3004. close {_p}'s inventory
  3005. if {_n} is 3:
  3006. if {mineplex.shards.%{_p}%} >= 10000:
  3007. close {_p}'s inventory
  3008. wait 3 ticks
  3009. open chest with 6 rows named " Confirmation" to {_p}
  3010. wait 5 ticks
  3011. set {_slot} to 0
  3012. format slot 0 of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  3013. loop 44 times:
  3014. format slot {_slot} of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  3015. add 1 to {_slot}
  3016. loop 10 times:
  3017. wait 0.4 ticks
  3018. format slot {_slot} of {_p} with emerald block named "&aYour purchase was successfull." to be unstealable
  3019. add 1 to {slot}
  3020. delShards({_p}, 10000)
  3021. add 1 to {mythicalchests.%{_p}%}
  3022. wait 10 ticks
  3023. close {_p}'s inventory
  3024. else:
  3025. close {_p}'s inventory
  3026. wait 3 ticks
  3027. open chest with 6 rows named " Confirmation" to {_p}
  3028. wait 5 ticks
  3029. format slot 0 of {_p} with redstone block named "&cYour account has insufficent funds." to be unstealable
  3030. set {_slot} to 0
  3031. loop 54 times:
  3032. format slot {_slot} of {_p} with redstone block named "&cYour account has insufficent funds." to be unstealable
  3033. add 1 to {_slot}
  3034. wait 10 ticks
  3035. close {_p}'s inventory
  3036.  
  3037. function openTreasure(p: player , c: number , l: number) :: number:
  3038. if {_c} is 1:
  3039. if {oldchests.%{_p}%} < 1:
  3040. close {_p}'s inventory
  3041. wait 2 ticks
  3042. open chest with 6 rows named " Confirmation" to {_p}
  3043. wait 1 tick
  3044. format slot 4 of {_p} with prismarine shard named "&b&l1000 Shards" to be unstealable
  3045. format slot 22 of {_p} with chest named "&a&lOld Chest" with lore " ||&fOld Chests Owned: &e0 ||&7We've scoured the lands of Minecraft||&7and found these abandoned chests.||&7The contents are unknown, but||&7according to the inscriptions on the||&7straps they appear to contain||&7many kinds of loot." to be unstealable
  3046. format slot 27 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3047. format slot 28 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3048. format slot 29 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3049. format slot 33 of {_p} with redstone block named "&cNO" to close
  3050. format slot 34 of {_p} with redstone block named "&cNO" to close
  3051. format slot 35 of {_p} with redstone block named "&cNO" to close
  3052. format slot 36 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3053. format slot 37 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3054. format slot 38 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3055. format slot 42 of {_p} with redstone block named "&cNO" to close
  3056. format slot 43 of {_p} with redstone block named "&cNO" to close
  3057. format slot 44 of {_p} with redstone block named "&cNO" to close
  3058. format slot 45 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3059. format slot 46 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3060. format slot 47 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 1)]
  3061. format slot 51 of {_p} with redstone block named "&cNO" to close
  3062. format slot 52 of {_p} with redstone block named "&cNO" to close
  3063. format slot 53 of {_p} with redstone block named "&cNO" to close
  3064. if {oldchests.%{_p}%} >= 1:
  3065. remove 1 from {oldchests.%{_p}%}
  3066. set {mineplex.chestbusy.%{_l}%.} to {_p}
  3067. send {_p} title "&eOld Treasure" with subtitle "&fChoose 4 Chests To Open" for 8 seconds
  3068. set {mineplex.inchest.%{_p}%} to {_l}
  3069. set block at {mineplex.chestpoint.%{_l}%} to air
  3070. teleport {_p} to {mineplex.chestpoint.%{_l}%}
  3071. send "&9Treasure> &7Choose 4 chests to open" to {_p}
  3072. wait 1.2 seconds
  3073. set block at {mineplex.chestpoint.%{_l}%.sub.1} to chest
  3074. set block at {mineplex.chestpoint.%{_l}%.sub.2} to chest
  3075. set block at {mineplex.chestpoint.%{_l}%.sub.3} to chest
  3076. set block at {mineplex.chestpoint.%{_l}%.sub.4} to chest
  3077. set block at {mineplex.chestpoint.%{_l}%.sub.5} to chest
  3078. set block at {mineplex.chestpoint.%{_l}%.sub.6} to chest
  3079. set block at {mineplex.chestpoint.%{_l}%.sub.7} to chest
  3080. set block at {mineplex.chestpoint.%{_l}%.sub.8} to chest
  3081. set {_get} to getPlayerdata({_p}, "stats.global.chests")
  3082. set {_cur} to {_get} parsed as a number
  3083. add 1 to {_cur}
  3084. setPlayerdata({_p}, "stats.global.chests", "%{_cur}%")
  3085. if {_c} is 2:
  3086. if {ancientchests.%{_p}%} < 1:
  3087. close {_p}'s inventory
  3088. wait 2 ticks
  3089. open chest with 6 rows named " Confirmation" to {_p}
  3090. wait 1 tick
  3091. format slot 4 of {_p} with prismarine shard named "&b&l5000 Shards" to be unstealable
  3092. format slot 22 of {_p} with chest named "&6&lAncient Chest" with lore " ||&fAncient Chests Owned: &e0 ||&7Some of our bravest adventurers||&7have discovered these chests within||&7temples hidden in Minecrafts worlds." to be unstealable
  3093. format slot 27 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3094. format slot 28 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3095. format slot 29 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3096. format slot 33 of {_p} with redstone block named "&cNO" to close
  3097. format slot 34 of {_p} with redstone block named "&cNO" to close
  3098. format slot 35 of {_p} with redstone block named "&cNO" to close
  3099. format slot 36 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3100. format slot 37 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3101. format slot 38 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3102. format slot 42 of {_p} with redstone block named "&cNO" to close
  3103. format slot 43 of {_p} with redstone block named "&cNO" to close
  3104. format slot 44 of {_p} with redstone block named "&cNO" to close
  3105. format slot 45 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3106. format slot 46 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3107. format slot 47 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 2)]
  3108. format slot 51 of {_p} with redstone block named "&cNO" to close
  3109. format slot 52 of {_p} with redstone block named "&cNO" to close
  3110. format slot 53 of {_p} with redstone block named "&cNO" to close
  3111. if {ancientchests.%{_p}%} >= 1:
  3112. remove 1 from {ancientchests.%{_p}%}
  3113. set {mineplex.chestbusy.%{_l}%.} to {_p}
  3114. send {_p} title "&6Ancient Treasure" with subtitle "&fChoose 4 Chests To Open" for 8 seconds
  3115. set {mineplex.inchest.%{_p}%} to {_l}
  3116. set block at {mineplex.chestpoint.%{_l}%} to air
  3117. teleport {_p} to {mineplex.chestpoint.%{_l}%}
  3118. send "&9Treasure> &7Choose 4 chests to open" to {_p}
  3119. wait 2.5 seconds
  3120. set block at {mineplex.chestpoint.%{_l}%.sub.1} to chest
  3121. set block at {mineplex.chestpoint.%{_l}%.sub.2} to chest
  3122. set block at {mineplex.chestpoint.%{_l}%.sub.3} to chest
  3123. set block at {mineplex.chestpoint.%{_l}%.sub.4} to chest
  3124. set block at {mineplex.chestpoint.%{_l}%.sub.5} to chest
  3125. set block at {mineplex.chestpoint.%{_l}%.sub.6} to chest
  3126. set block at {mineplex.chestpoint.%{_l}%.sub.7} to chest
  3127. set block at {mineplex.chestpoint.%{_l}%.sub.8} to chest
  3128. if {_c} is 3:
  3129. if {mythicalchests.%{_p}%} < 1:
  3130. close {_p}'s inventory
  3131. wait 2 ticks
  3132. open chest with 6 rows named " Confirmation" to {_p}
  3133. wait 1 tick
  3134. format slot 4 of {_p} with prismarine shard named "&b&l10000 Shards" to be unstealable
  3135. format slot 22 of {_p} with ender chest named "&c&lMythical Chest" with lore " ||&fMythical Chests Owned: &e0 ||&7All our previous adventurers have||&7perished in search of these chests.||&7However, legends of thier existence||&7convinced Sterling, Chiss, and Defek7||&7to venture out and discover the||&7location of these chests on thier own." to be unstealable
  3136. format slot 27 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3137. format slot 28 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3138. format slot 29 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3139. format slot 33 of {_p} with redstone block named "&cNO" to close
  3140. format slot 34 of {_p} with redstone block named "&cNO" to close
  3141. format slot 35 of {_p} with redstone block named "&cNO" to close
  3142. format slot 36 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3143. format slot 37 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3144. format slot 38 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3145. format slot 42 of {_p} with redstone block named "&cNO" to close
  3146. format slot 43 of {_p} with redstone block named "&cNO" to close
  3147. format slot 44 of {_p} with redstone block named "&cNO" to close
  3148. format slot 45 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3149. format slot 46 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3150. format slot 47 of {_p} with emerald block named "&aOK" to close then run [buyChest({_p}, 3)]
  3151. format slot 51 of {_p} with redstone block named "&cNO" to close
  3152. format slot 52 of {_p} with redstone block named "&cNO" to close
  3153. format slot 53 of {_p} with redstone block named "&cNO" to close
  3154. if {mythicalchests.%{_p}%} >= 1:
  3155. remove 1 from {mythicalchests.%{_p}%}
  3156. set {mineplex.chestbusy.%{_l}%.} to {_p}
  3157. send {_p} title "&cMythical Treasure" with subtitle "&fChoose 4 Chests To Open" for 8 seconds
  3158. set {mineplex.inchest.%{_p}%} to {_l}
  3159. set block at {mineplex.chestpoint.%{_l}%} to air
  3160. teleport {_p} to {mineplex.chestpoint.%{_l}%}
  3161. send "&9Treasure> &7Choose 4 chests to open" to {_p}
  3162. wait 2.5 seconds
  3163. set block at {mineplex.chestpoint.%{_l}%.sub.1} to chest
  3164. set block at {mineplex.chestpoint.%{_l}%.sub.2} to chest
  3165. set block at {mineplex.chestpoint.%{_l}%.sub.3} to chest
  3166. set block at {mineplex.chestpoint.%{_l}%.sub.4} to chest
  3167. set block at {mineplex.chestpoint.%{_l}%.sub.5} to chest
  3168. set block at {mineplex.chestpoint.%{_l}%.sub.6} to chest
  3169. set block at {mineplex.chestpoint.%{_l}%.sub.7} to chest
  3170. set block at {mineplex.chestpoint.%{_l}%.sub.8} to chest
  3171.  
  3172. on inventory click:
  3173. if inventory name of player's current inventory is " Confirmation":
  3174. cancel event
  3175. close player's inventory
  3176.  
  3177. function TreasurePage(p: player , n: number , c: number) :: player:
  3178. if {_N} is 2:
  3179. if {_C} is 1:
  3180. close {_p}'s inventory
  3181. wait 4 ticks
  3182. open chest with 6 rows named "Open Treasure - Page 2" to {_p}
  3183. wait 2 ticks
  3184. format slot 10 of {_p} with rose bush named "&a&lSpring Treasure" with lore " ||&fSpring Chests Owned: &e0 ||||&7Spring is here! Find 6 limited ||&7edition Spring Cosmetics in the ||&7Spring Chest! Only available for ||&7a limited time. Garunteed no ||&7Duplicate items! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3185. format slot 12 of {_p} with skull of ("luigi" parsed as an offline player) named "&a&lSt. Patrick's treasure" with lore "||&fSt Patrick's Chests Owned: &e0 ||||&7Happy St. Patrick's Day! Get||&7your Pot's of Gold and Luck||&7of the Irish in this chest! ||&7items, no duplicates||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3186. format slot 14 of {_p} with pink wool named "&c&lLove Chest" with lore " ||&fLove Chests Owned: &e0 ||||&7Cupid and his hunters have||&7searched far and wide to||&7collect a whole bunch of lovey||&7dovey items. 6 items, no||&7duplicates.||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3187. format slot 16 of {_p} with skull of ("CruXXx" parsed as an offline player) named "&2&lWinter Holiday Treasure" with lore "||&fWinter Holiday Chests Owned: &e0 ||||&7Legend tells of the Winter Lord's ||&7vast treasuer horde, locked away in ||&7a vault of ice, deep beneath the ||&7Frozen Sea. It is said it can only be ||&7accessed in the deepest parts of Winter... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3188. format slot 22 of {_p} with skull of ("WheezyGold7931" parsed as an offline player) named "&c&lFreedom &9&lTreasure" with lore "||&fFreedom Chests Owned: &e0 ||||&7It is said that George Washington ||&7carved this chest himself from the wood ||&7of the apple tree he cut down... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3189. format slot 28 of {_p} with skull of ("unyelped" parsed as an offline player) named "&6&lHaunted Treasure" with lore "||&fHaunted Chests Owned: &e0 ||||&7The haunted chest can only be found ||&7during the month of October when the ||&7veil between this world and the shadow is thin... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3190. format slot 30 of {_p} with skull of ("Torksi" parsed as an offline player) named "&6&lTrick or Treat Treasure" with lore "||&fTrick or Treat Chests Owned: &e0 ||||&7The Trick or Treat Chest contains all ||&7sorts of surprises. From Rank Upgrades to ||&7long lost Halloween items. and even other chests! ||||&cThis item is no longer available" to close
  3191. format slot 32 of {_p} with cooked chicken named "&6&lThankful Treasure" with lore "||&fThankful Chests Owned: &e0 ||||&7The Thankful Chest is our way of ||&7showing thanks to you. Containing items from Rank Upgrades to ||&7Power Play Club Subscriptions. Among other things! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3192. format slot 34 of {_p} with skull of ("Ottelino" parsed as an offline player) named "&c&lGingerbread &a&lTreasure" with lore "||&fGingerbread Chests Owned: &e0 ||||&7The legendary burglar, the ||&7Gingerbread Man, has finally ||&7been caught! Now, for the first ||&7time his loot is available for ||&7auction. There are 8 pieces ||&7available to collect and no ||&7duplicates can be obtained from ||&7this chest! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3193. format slot 45 of {_p} with arrow named "&7<- Last Page" to close then run [TreasurePage({_p}, 1, 1)]
  3194. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3195. else if {_C} is 2:
  3196. close {_p}'s inventory
  3197. wait 4 ticks
  3198. open chest with 6 rows named "Open Treasure - Page 2" to {_p}
  3199. wait 2 ticks
  3200. format slot 10 of {_p} with rose bush named "&a&lSpring Treasure" with lore " ||&fSpring Chests Owned: &e0 ||||&7Spring is here! Find 6 limited ||&7edition Spring Cosmetics in the ||&7Spring Chest! Only available for ||&7a limited time. Garunteed no ||&7Duplicate items! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3201. format slot 12 of {_p} with skull of ("luigi" parsed as an offline player) named "&a&lSt. Patrick's treasure" with lore "||&fSt Patrick's Chests Owned: &e0 ||||&7Happy St. Patrick's Day! Get||&7your Pot's of Gold and Luck||&7of the Irish in this chest! ||&7items, no duplicates||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3202. format slot 14 of {_p} with pink wool named "&c&lLove Chest" with lore " ||&fLove Chests Owned: &e0 ||||&7Cupid and his hunters have||&7searched far and wide to||&7collect a whole bunch of lovey||&7dovey items. 6 items, no||&7duplicates.||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3203. format slot 16 of {_p} with skull of ("CruXXx" parsed as an offline player) named "&2&lWinter Holiday Treasure" with lore "||&fWinter Holiday Chests Owned: &e0 ||||&7Legend tells of the Winter Lord's ||&7vast treasuer horde, locked away in ||&7a vault of ice, deep beneath the ||&7Frozen Sea. It is said it can only be ||&7accessed in the deepest parts of Winter... ||||&cThis item is no longer available" to close
  3204. format slot 22 of {_p} with skull of ("WheezyGold7931" parsed as an offline player) named "&c&lFreedom &9&lTreasure" with lore "||&fFreedom Chests Owned: &e0 ||||&7It is said that George Washington ||&7carved this chest himself from the wood ||&7of the apple tree he cut down... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3205. format slot 28 of {_p} with skull of ("unyelped" parsed as an offline player) named "&6&lHaunted Treasure" with lore "||&fHaunted Chests Owned: &e0 ||||&7The haunted chest can only be found ||&7during the month of October when the ||&7veil between this world and the shadow is thin... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3206. format slot 30 of {_p} with skull of ("Torksi" parsed as an offline player) named "&6&lTrick or Treat Treasure" with lore "||&fTrick or Treat Chests Owned: &e0 ||||&7The Trick or Treat Chest contains all ||&7sorts of surprises. From Rank Upgrades to ||&7long lost Halloween items. and even other chests! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3207. format slot 32 of {_p} with cooked chicken named "&6&lThankful Treasure" with lore "||&fThankful Chests Owned: &e0 ||||&7The Thankful Chest is our way of ||&7showing thanks to you. Containing items from Rank Upgrades to ||&7Power Play Club Subscriptions. Among other things! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3208. format slot 34 of {_p} with skull of ("Ottelino" parsed as an offline player) named "&c&lGingerbread &a&lTreasure" with lore "||&fGingerbread Chests Owned: &e0 ||||&7The legendary burglar, the ||&7Gingerbread Man, has finally ||&7been caught! Now, for the first ||&7time his loot is available for ||&7auction. There are 8 pieces ||&7available to collect and no ||&7duplicates can be obtained from ||&7this chest! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3209. format slot 45 of {_p} with arrow named "&7<- Last Page" to close then run [TreasurePage({_p}, 1, 2)]
  3210. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3211. else if {_C} is 3:
  3212. close {_p}'s inventory
  3213. wait 4 ticks
  3214. open chest with 6 rows named "Open Treasure - Page 2" to {_p}
  3215. wait 2 ticks
  3216. format slot 10 of {_p} with rose bush named "&a&lSpring Treasure" with lore " ||&fSpring Chests Owned: &e0 ||||&7Spring is here! Find 6 limited ||&7edition Spring Cosmetics in the ||&7Spring Chest! Only available for ||&7a limited time. Garunteed no ||&7Duplicate items! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3217. format slot 12 of {_p} with skull of ("luigi" parsed as an offline player) named "&a&lSt. Patrick's treasure" with lore "||&fSt Patrick's Chests Owned: &e0 ||||&7Happy St. Patrick's Day! Get||&7your Pot's of Gold and Luck||&7of the Irish in this chest! ||&7items, no duplicates||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3218. format slot 14 of {_p} with pink wool named "&c&lLove Chest" with lore " ||&fLove Chests Owned: &e0 ||||&7Cupid and his hunters have||&7searched far and wide to||&7collect a whole bunch of lovey||&7dovey items. 6 items, no||&7duplicates.||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3219. format slot 16 of {_p} with skull of ("CruXXx" parsed as an offline player) named "&2&lWinter Holiday Treasure" with lore "||&fWinter Holiday Chests Owned: &e0 ||||&7Legend tells of the Winter Lord's ||&7vast treasuer horde, locked away in ||&7a vault of ice, deep beneath the ||&7Frozen Sea. It is said it can only be ||&7accessed in the deepest parts of Winter... ||||&cThis item is no longer available" to close
  3220. format slot 22 of {_p} with skull of ("WheezyGold7931" parsed as an offline player) named "&c&lFreedom &9&lTreasure" with lore "||&fFreedom Chests Owned: &e0 ||||&7It is said that George Washington ||&7carved this chest himself from the wood ||&7of the apple tree he cut down... ||||&cThis item is no longer available" to close
  3221. format slot 28 of {_p} with skull of ("unyelped" parsed as an offline player) named "&6&lHaunted Treasure" with lore "||&fHaunted Chests Owned: &e0 ||||&7The haunted chest can only be found ||&7during the month of October when the ||&7veil between this world and the shadow is thin... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3222. format slot 30 of {_p} with skull of ("Torksi" parsed as an offline player) named "&6&lTrick or Treat Treasure" with lore "||&fTrick or Treat Chests Owned: &e0 ||||&7The Trick or Treat Chest contains all ||&7sorts of surprises. From Rank Upgrades to ||&7long lost Halloween items. and even other chests! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3223. format slot 32 of {_p} with cooked chicken named "&6&lThankful Treasure" with lore "||&fThankful Chests Owned: &e0 ||||&7The Thankful Chest is our way of ||&7showing thanks to you. Containing items from Rank Upgrades to ||&7Power Play Club Subscriptions. Among other things! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3224. format slot 34 of {_p} with skull of ("Ottelino" parsed as an offline player) named "&c&lGingerbread &a&lTreasure" with lore "||&fGingerbread Chests Owned: &e0 ||||&7The legendary burglar, the ||&7Gingerbread Man, has finally ||&7been caught! Now, for the first ||&7time his loot is available for ||&7auction. There are 8 pieces ||&7available to collect and no ||&7duplicates can be obtained from ||&7this chest! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3225. format slot 45 of {_p} with arrow named "&7<- Last Page" to close then run [TreasurePage({_p}, 1, 3)]
  3226. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3227. else if {_C} is 4:
  3228. close {_p}'s inventory
  3229. wait 4 ticks
  3230. open chest with 6 rows named "Open Treasure - Page 2" to {_p}
  3231. wait 2 ticks
  3232. format slot 10 of {_p} with rose bush named "&a&lSpring Treasure" with lore " ||&fSpring Chests Owned: &e0 ||||&7Spring is here! Find 6 limited ||&7edition Spring Cosmetics in the ||&7Spring Chest! Only available for ||&7a limited time. Garunteed no ||&7Duplicate items! ||||&cThis item is no longer available" to close
  3233. format slot 12 of {_p} with skull of ("luigi" parsed as an offline player) named "&a&lSt. Patrick's treasure" with lore "||&fSt Patrick's Chests Owned: &e0 ||||&7Happy St. Patrick's Day! Get||&7your Pot's of Gold and Luck||&7of the Irish in this chest! ||&7items, no duplicates||||&cThis item is no longer available" to close
  3234. format slot 14 of {_p} with pink wool named "&c&lLove Chest" with lore " ||&fLove Chests Owned: &e0 ||||&7Cupid and his hunters have||&7searched far and wide to||&7collect a whole bunch of lovey||&7dovey items. 6 items, no||&7duplicates.||||&cThis item is no longer available" to close
  3235. format slot 16 of {_p} with skull of ("CruXXx" parsed as an offline player) named "&2&lWinter Holiday Treasure" with lore "||&fWinter Holiday Chests Owned: &e0 ||||&7Legend tells of the Winter Lord's ||&7vast treasuer horde, locked away in ||&7a vault of ice, deep beneath the ||&7Frozen Sea. It is said it can only be ||&7accessed in the deepest parts of Winter... ||||&cThis item is no longer available" to close
  3236. format slot 22 of {_p} with skull of ("WheezyGold7931" parsed as an offline player) named "&c&lFreedom &9&lTreasure" with lore "||&fFreedom Chests Owned: &e0 ||||&7It is said that George Washington ||&7carved this chest himself from the wood ||&7of the apple tree he cut down... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3237. format slot 28 of {_p} with skull of ("unyelped" parsed as an offline player) named "&6&lHaunted Treasure" with lore "||&fHaunted Chests Owned: &e0 ||||&7The haunted chest can only be found ||&7during the month of October when the ||&7veil between this world and the shadow is thin... ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3238. format slot 30 of {_p} with skull of ("Torksi" parsed as an offline player) named "&6&lTrick or Treat Treasure" with lore "||&fTrick or Treat Chests Owned: &e0 ||||&7The Trick or Treat Chest contains all ||&7sorts of surprises. From Rank Upgrades to ||&7long lost Halloween items. and even other chests! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3239. format slot 32 of {_p} with cooked chicken named "&6&lThankful Treasure" with lore "||&fThankful Chests Owned: &e0 ||||&7The Thankful Chest is our way of ||&7showing thanks to you. Containing items from Rank Upgrades to ||&7Power Play Club Subscriptions. Among other things! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3240. format slot 34 of {_p} with skull of ("Ottelino" parsed as an offline player) named "&c&lGingerbread &a&lTreasure" with lore "||&fGingerbread Chests Owned: &e0 ||||&7The legendary burglar, the ||&7Gingerbread Man, has finally ||&7been caught! Now, for the first ||&7time his loot is available for ||&7auction. There are 8 pieces ||&7available to collect and no ||&7duplicates can be obtained from ||&7this chest! ||||&cThis item is no longer available" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3241. format slot 45 of {_p} with arrow named "&7<- Last Page" to close then run [TreasurePage({_p}, 1, 4)]
  3242. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3243. if {_N} is 1:
  3244. if {_C} is 1:
  3245. wait 2 ticks
  3246. open chest with 6 rows named "Open Treasure - Page 1" to {_p}
  3247. wait 2 ticks
  3248. format slot 19 of {_p} with chest named "&a&lOld Chest" with lore " ||&fOld Chests Owned: &e%{oldchests.%{_p}%}% ||||&7We've scoured the lands of Minecraft||&7and found these abandoned chests.||&7The contents are unknown, but||&7according to the inscriptions on the||&7straps they appear to contain||&7many kinds of loot.|| ||&fClick to Purchase for &b1000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 1, 1)]
  3249. format slot 21 of {_p} with trapped chest named "&6&lAncient Chest" with lore " ||&fAncient Chests Owned: &e%{ancientchests.%{_p}%}% ||||&7Some of our bravest adventurers||&7have discovered these chests within||&7temples hidden in Minecrafts worlds.|| ||&fClick to Purchase for &b5000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 2, 1)]
  3250. format slot 23 of {_p} with ender chest named "&c&lMythical Chest" with lore " ||&fMythical Chests Owned: &e%{mythicalchests.%{_p}%}% ||||&7All our previous adventurers have||&7perished in search of these chests.||&7However, legends of thier existence||&7convinced Sterling, Chiss, and Defek7||&7to venture out and discover the||&7location of these chests on thier own.|| ||&fClick to Purchase for &b10000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 3, 1)]
  3251. format slot 25 of {_p} with sea lantern named "&3&lIlluminated Treasure" with lore "||&fIlluminated Chests Owned: &e0 ||||&7The illuminated chest shines brightly ||&7in the depths, always bringing a new ||&7treasure from the darkness. ||&fClick to craft for &b20000 Treasure Shards || ||&for Purchase at: &e%{mineplex.config.website}%." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3252. format slot 38 of {_p} with skull of ("Chest" parsed as an offline player) named "&b&lOmega Treasure" with lore "||&fOmega Chests Owned: &e0 ||||&7The most powerful of all chests, ||&7it is able to go back in time to find ||&7loot that has been lost..." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3253. format slot 42 of {_p} with tnt named "&6&lMinestrike Treasure" with lore "||&fMinestrike Chests Owned: &e0 ||||&7The Minestrike Chest is the ||&7only place to get the unique ||&7skins for Minestrike weapons! ||||&fEach use opens two chests. Can ||&fGive duplicates. ||||&fClick to craft for &b10000 Treasure Shards ||||&for Purchase at: &e%{mineplex.config.website}%" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3254. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3255. format slot 53 of {_p} with arrow named "&7Next page ->" to close then run [TreasurePage({_p}, 2, 1)]
  3256. if {_C} is 2:
  3257. wait 2 ticks
  3258. open chest with 6 rows named "Open Treasure - Page 1" to {_p}
  3259. wait 2 ticks
  3260. format slot 19 of {_p} with chest named "&a&lOld Chest" with lore " ||&fOld Chests Owned: &e%{oldchests.%{_p}%}% ||||&7We've scoured the lands of Minecraft||&7and found these abandoned chests.||&7The contents are unknown, but||&7according to the inscriptions on the||&7straps they appear to contain||&7many kinds of loot.|| ||&fClick to Purchase for &b1000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 1, 2)]
  3261. format slot 21 of {_p} with trapped chest named "&6&lAncient Chest" with lore " ||&fAncient Chests Owned: &e%{ancientchests.%{_p}%}% ||||&7Some of our bravest adventurers||&7have discovered these chests within||&7temples hidden in Minecrafts worlds.|| ||&fClick to Purchase for &b5000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 2, 2)]
  3262. format slot 23 of {_p} with ender chest named "&c&lMythical Chest" with lore " ||&fMythical Chests Owned: &e%{mythicalchests.%{_p}%}% ||||&7All our previous adventurers have||&7perished in search of these chests.||&7However, legends of thier existence||&7convinced Sterling, Chiss, and Defek7||&7to venture out and discover the||&7location of these chests on thier own.|| ||&fClick to Purchase for &b10000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 3, 2)]
  3263. format slot 25 of {_p} with sea lantern named "&3&lIlluminated Treasure" with lore "||&fIlluminated Chests Owned: &e0 ||||&7The illuminated chest shines brightly ||&7in the depths, always bringing a new ||&7treasure from the darkness. ||&fClick to craft for &b20000 Treasure Shards || ||&for Purchase at: &e%{mineplex.config.website}%." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3264. format slot 38 of {_p} with skull of ("Chest" parsed as an offline player) named "&b&lOmega Treasure" with lore "||&fOmega Chests Owned: &e0 ||||&7The most powerful of all chests, ||&7it is able to go back in time to find ||&7loot that has been lost..." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3265. format slot 42 of {_p} with tnt named "&6&lMinestrike Treasure" with lore "||&fMinestrike Chests Owned: &e0 ||||&7The Minestrike Chest is the ||&7only place to get the unique ||&7skins for Minestrike weapons! ||||&fEach use opens two chests. Can ||&fGive duplicates. ||||&fClick to craft for &b10000 Treasure Shards ||||&for Purchase at: &e%{mineplex.config.website}%" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3266. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3267. format slot 53 of {_p} with arrow named "&7Next page ->" to close then run [TreasurePage({_p}, 2, 2)]
  3268. if {_C} is 3:
  3269. wait 2 ticks
  3270. open chest with 6 rows named "Open Treasure - Page 1" to {_p}
  3271. wait 2 ticks
  3272. format slot 19 of {_p} with chest named "&a&lOld Chest" with lore " ||&fOld Chests Owned: &e%{oldchests.%{_p}%}% ||||&7We've scoured the lands of Minecraft||&7and found these abandoned chests.||&7The contents are unknown, but||&7according to the inscriptions on the||&7straps they appear to contain||&7many kinds of loot.|| ||&fClick to Purchase for &b1000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 1, 3)]
  3273. format slot 21 of {_p} with trapped chest named "&6&lAncient Chest" with lore " ||&fAncient Chests Owned: &e%{ancientchests.%{_p}%}% ||||&7Some of our bravest adventurers||&7have discovered these chests within||&7temples hidden in Minecrafts worlds.|| ||&fClick to Purchase for &b5000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 2, 3)]
  3274. format slot 23 of {_p} with ender chest named "&c&lMythical Chest" with lore " ||&fMythical Chests Owned: &e%{mythicalchests.%{_p}%}% ||||&7All our previous adventurers have||&7perished in search of these chests.||&7However, legends of thier existence||&7convinced Sterling, Chiss, and Defek7||&7to venture out and discover the||&7location of these chests on thier own.|| ||&fClick to Purchase for &b10000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 3, 3)]
  3275. format slot 25 of {_p} with sea lantern named "&3&lIlluminated Treasure" with lore "||&fIlluminated Chests Owned: &e0 ||||&7The illuminated chest shines brightly ||&7in the depths, always bringing a new ||&7treasure from the darkness. ||&fClick to craft for &b20000 Treasure Shards || ||&for Purchase at: &e%{mineplex.config.website}%." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3276. format slot 38 of {_p} with skull of ("Chest" parsed as an offline player) named "&b&lOmega Treasure" with lore "||&fOmega Chests Owned: &e0 ||||&7The most powerful of all chests, ||&7it is able to go back in time to find ||&7loot that has been lost..." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3277. format slot 42 of {_p} with tnt named "&6&lMinestrike Treasure" with lore "||&fMinestrike Chests Owned: &e0 ||||&7The Minestrike Chest is the ||&7only place to get the unique ||&7skins for Minestrike weapons! ||||&fEach use opens two chests. Can ||&fGive duplicates. ||||&fClick to craft for &b10000 Treasure Shards ||||&for Purchase at: &e%{mineplex.config.website}%" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3278. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3279. format slot 53 of {_p} with arrow named "&7Next page ->" to close then run [TreasurePage({_p}, 2, 3)]
  3280. if {_C} is 4:
  3281. wait 2 ticks
  3282. open chest with 6 rows named "Open Treasure - Page 1" to {_p}
  3283. wait 2 ticks
  3284. format slot 19 of {_p} with chest named "&a&lOld Chest" with lore " ||&fOld Chests Owned: &e%{oldchests.%{_p}%}% ||||&7We've scoured the lands of Minecraft||&7and found these abandoned chests.||&7The contents are unknown, but||&7according to the inscriptions on the||&7straps they appear to contain||&7many kinds of loot.|| ||&fClick to Purchase for &b1000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 1, 4)]
  3285. format slot 21 of {_p} with trapped chest named "&6&lAncient Chest" with lore " ||&fAncient Chests Owned: &e%{ancientchests.%{_p}%}% ||||&7Some of our bravest adventurers||&7have discovered these chests within||&7temples hidden in Minecrafts worlds.|| ||&fClick to Purchase for &b5000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 2, 4)]
  3286. format slot 23 of {_p} with ender chest named "&c&lMythical Chest" with lore " ||&fMythical Chests Owned: &e%{mythicalchests.%{_p}%}% ||||&7All our previous adventurers have||&7perished in search of these chests.||&7However, legends of thier existence||&7convinced Sterling, Chiss, and Defek7||&7to venture out and discover the||&7location of these chests on thier own.|| ||&fClick to Purchase for &b10000 Treasure Shards|| ||&for Purchase at: &e%{mineplex.config.website}%" to close then run [openTreasure({_p}, 3, 4)]
  3287. format slot 25 of {_p} with sea lantern named "&3&lIlluminated Treasure" with lore "||&fIlluminated Chests Owned: &e0 ||||&7The illuminated chest shines brightly ||&7in the depths, always bringing a new ||&7treasure from the darkness. ||&fClick to craft for &b20000 Treasure Shards || ||&for Purchase at: &e%{mineplex.config.website}%." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3288. format slot 38 of {_p} with skull of ("Chest" parsed as an offline player) named "&b&lOmega Treasure" with lore "||&fOmega Chests Owned: &e0 ||||&7The most powerful of all chests, ||&7it is able to go back in time to find ||&7loot that has been lost..." to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3289. format slot 42 of {_p} with tnt named "&6&lMinestrike Treasure" with lore "||&fMinestrike Chests Owned: &e0 ||||&7The Minestrike Chest is the ||&7only place to get the unique ||&7skins for Minestrike weapons! ||||&fEach use opens two chests. Can ||&fGive duplicates. ||||&fClick to craft for &b10000 Treasure Shards ||||&for Purchase at: &e%{mineplex.config.website}%" to close then run [send "&9Treasure> &7This Treasure Bundle isn't added in this version of MCR." to {_p}]
  3290. format slot 49 of {_p} with prismarine shard named "&b&l%{mineplex.shards.%{_p}%}% Treasure Shards" with lore "||&7This seems like it might come in ||&7handy. Maybe I can collect more!" to close
  3291. format slot 53 of {_p} with arrow named "&7Next page ->" to close then run [TreasurePage({_p}, 2, 4)]
  3292.  
  3293. command /givetreasure [<string>] [<number>] [<offline player>]:
  3294. permission: mineplex.admin
  3295. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7]
  3296. trigger:
  3297. if arg-1 is set:
  3298. if arg-2 is set:
  3299. if arg-2 is an integer:
  3300. if arg-3 is set:
  3301. if arg-1 is "Mythical":
  3302. add arg-2 to {mythicalchests.%arg-3%}
  3303. message "&9Treasure> &7You gave &e%arg-3% %arg-2% &7Mythical Treasure Chests." to sender
  3304. message "&9Treasure> &7You recieved &e%arg-2% &7Mythical Treasure Chests." to arg-3
  3305. stop
  3306. else if arg-1 is "Ancient":
  3307. add arg-2 to {ancientchests.%arg-3%}
  3308. message "&9Treasure> &7You gave &e%arg-3% %arg-2% &7Ancient Treasure Chests." to sender
  3309. message "&9Treasure> &7You recieved &e%arg-2% &7Ancient Treasure Chests." to arg-3
  3310. stop
  3311. else if arg-1 is "old":
  3312. add arg-2 to {oldchests.%arg-3%}
  3313. message "&9Treasure> &7You gave &e%arg-3% %arg-2% &7Old Treasure Chests." to sender
  3314. message "&9Treasure> &7You recieved &e%arg-2% &7Old Treasure Chests." to arg-3
  3315. stop
  3316. else:
  3317. send "&9Treasure> &7Unknown Treasure [&e%arg-1%&7]." to sender
  3318. stop
  3319. else:
  3320. send "&9Treasure> &7Please specify a player" to sender
  3321. stop
  3322. else if arg-2 is not an integer:
  3323. send "&9Treasure> &7Unknown Integer [&e%arg-2%&7]." to sender
  3324. stop
  3325. else:
  3326. send "&9Treasure> &7Please specify an amount." to sender
  3327. stop
  3328. else:
  3329. send "&9Treasure> &7Listing Commands:" to sender
  3330. send "&4/GiveTreasure <treasure> <amount> <name> &7Gives a player some treasure chests &4Admin" to sender
  3331. stop
  3332.  
  3333. every 5 ticks:
  3334. loop all players:
  3335. if {mineplex.inchest.%loop-player%} is set:
  3336. set {_di} to distance between {mineplex.chestpoint.%{mineplex.inchest.%loop-player%}%} and loop-player
  3337. if {_di} is greater than 3.11:
  3338. teleport loop-player to {mineplex.chestpoint.%{mineplex.inchest.%loop-player%}%}
  3339.  
  3340. every 5 ticks:
  3341. loop all players:
  3342. if {mineplex.inchest.%loop-player%} is set:
  3343. loop players in radius 4 of loop-player:
  3344. if loop-player-2 is not loop-player-1:
  3345. if {mineplex.pref.ff.%loop-player-2%} is false:
  3346. push the loop-player-2 upwards at speed 0.925
  3347. push the loop-player-2 backwards at speed 0.825
  3348. play raw sound "mob.chicken.plop" at loop-player-2 with pitch 1 volume 10
  3349.  
  3350. on right click on chest:
  3351. if player is holding chest:
  3352. if name of player's tool is "&aCosmetic Menu":
  3353. stop
  3354. else:
  3355. send "&9MCR> &e##BlameWheezy"
  3356. else:
  3357. if event-block is {mineplex.chestpoint.1}:
  3358. cancel event
  3359. TreasurePage(player, 1, 1)
  3360. if event-block is {mineplex.chestpoint.2}:
  3361. cancel event
  3362. TreasurePage(player, 1, 2)
  3363. if event-block is {mineplex.chestpoint.3}:
  3364. cancel event
  3365. TreasurePage(player, 1, 3)
  3366. if event-block is {mineplex.chestpoint.4}:
  3367. cancel event
  3368. TreasurePage(player, 1, 4)
  3369.  
  3370. on right click on chest or ender chest:
  3371. if player is holding chest:
  3372. if name of player's tool is "&aCosmetic Menu":
  3373. stop
  3374. else:
  3375. send "&9MCR> &e##BlameWheezy"
  3376. else:
  3377. if event-block is {mineplex.chestpoint.1.sub.1} or {mineplex.chestpoint.1.sub.2} or {mineplex.chestpoint.1.sub.3} or {mineplex.chestpoint.1.sub.4} or {mineplex.chestpoint.1.sub.5} or {mineplex.chestpoint.1.sub.6} or {mineplex.chestpoint.1.sub.7} or {mineplex.chestpoint.1.sub.8}:
  3378. if {mineplex.inchest.%player%} is set:
  3379. if {mineplex.chestsopened.%player%} is not set:
  3380. set {mineplex.chestsopened.%player%} to 1
  3381. cancel event
  3382. make the event-block appear open
  3383. rewardTreasure(player, {mineplex.inchest.%player%}, 1, 1)
  3384. loop all players:
  3385. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3386. stop
  3387. else if {mineplex.chestsopened.%player%} is 3:
  3388. cancel event
  3389. add 1 to {mineplex.chestsopened.%player%}
  3390. make the event-block appear open
  3391. rewardTreasure(player, {mineplex.inchest.%player%}, 1, 1)
  3392. loop all players:
  3393. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3394. wait 3 seconds
  3395. resetPoints(player, 1)
  3396. execute player command "/hub"
  3397. stop
  3398. else if {mineplex.chestsopened.%player%} is 1 or 2:
  3399. cancel event
  3400. add 1 to {mineplex.chestsopened.%player%}
  3401. make the event-block appear open
  3402. rewardTreasure(player, {mineplex.inchest.%player%}, 1, 1)
  3403. loop all players:
  3404. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3405. stop
  3406. else if {mineplex.chestsopened.%player%} is not 1 or 2 or 3:
  3407. cancel event
  3408. else:
  3409. cancel event
  3410. else if event-block is {mineplex.chestpoint.2.sub.1} or {mineplex.chestpoint.2.sub.2} or {mineplex.chestpoint.2.sub.3} or {mineplex.chestpoint.2.sub.4} or {mineplex.chestpoint.2.sub.5} or {mineplex.chestpoint.2.sub.6} or {mineplex.chestpoint.2.sub.7} or {mineplex.chestpoint.2.sub.8}:
  3411. if {mineplex.inchest.%player%} is set:
  3412. if {mineplex.chestsopened.%player%} is not set:
  3413. set {mineplex.chestsopened.%player%} to 1
  3414. cancel event
  3415. make the event-block appear open
  3416. rewardTreasure(player, {mineplex.inchest.%player%}, 2, 1)
  3417. loop all players:
  3418. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3419. stop
  3420. else if {mineplex.chestsopened.%player%} is 3:
  3421. cancel event
  3422. add 1 to {mineplex.chestsopened.%player%}
  3423. make the event-block appear open
  3424. rewardTreasure(player, {mineplex.inchest.%player%}, 2, 1)
  3425. loop all players:
  3426. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3427. wait 3 seconds
  3428. resetPoints(player, 2)
  3429. execute player command "/hub"
  3430. stop
  3431. else if {mineplex.chestsopened.%player%} is 1 or 2:
  3432. cancel event
  3433. add 1 to {mineplex.chestsopened.%player%}
  3434. make the event-block appear open
  3435. rewardTreasure(player, {mineplex.inchest.%player%}, 2, 1)
  3436. loop all players:
  3437. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3438. stop
  3439. else if {mineplex.chestsopened.%player%} is not 1 or 2 or 3:
  3440. cancel event
  3441. else:
  3442. cancel event
  3443. else if event-block is {mineplex.chestpoint.3.sub.1} or {mineplex.chestpoint.3.sub.2} or {mineplex.chestpoint.3.sub.3} or {mineplex.chestpoint.3.sub.4} or {mineplex.chestpoint.3.sub.5} or {mineplex.chestpoint.3.sub.6} or {mineplex.chestpoint.3.sub.7} or {mineplex.chestpoint.3.sub.8}:
  3444. if {mineplex.inchest.%player%} is set:
  3445. if {mineplex.chestsopened.%player%} is not set:
  3446. set {mineplex.chestsopened.%player%} to 1
  3447. cancel event
  3448. make the event-block appear open
  3449. rewardTreasure(player, {mineplex.inchest.%player%}, 3, 1)
  3450. loop all players:
  3451. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3452. stop
  3453. else if {mineplex.chestsopened.%player%} is 3:
  3454. cancel event
  3455. add 1 to {mineplex.chestsopened.%player%}
  3456. make the event-block appear open
  3457. rewardTreasure(player, {mineplex.inchest.%player%}, 3, 1)
  3458. loop all players:
  3459. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3460. wait 3 seconds
  3461. resetPoints(player, 3)
  3462. execute player command "/hub"
  3463. stop
  3464. else if {mineplex.chestsopened.%player%} is 1 or 2:
  3465. cancel event
  3466. add 1 to {mineplex.chestsopened.%player%}
  3467. make the event-block appear open
  3468. rewardTreasure(player, {mineplex.inchest.%player%}, 3, 1)
  3469. loop all players:
  3470. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3471. stop
  3472. else if {mineplex.chestsopened.%player%} is not 1 or 2 or 3:
  3473. cancel event
  3474. else:
  3475. cancel event
  3476. else if event-block is {mineplex.chestpoint.4.sub.1} or {mineplex.chestpoint.4.sub.2} or {mineplex.chestpoint.4.sub.3} or {mineplex.chestpoint.4.sub.4} or {mineplex.chestpoint.4.sub.5} or {mineplex.chestpoint.4.sub.6} or {mineplex.chestpoint.4.sub.7} or {mineplex.chestpoint.4.sub.8}:
  3477. if {mineplex.inchest.%player%} is set:
  3478. if {mineplex.chestsopened.%player%} is not set:
  3479. set {mineplex.chestsopened.%player%} to 1
  3480. cancel event
  3481. make the event-block appear open
  3482. rewardTreasure(player, {mineplex.inchest.%player%}, 4, 1)
  3483. loop all players:
  3484. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3485. stop
  3486. else if {mineplex.chestsopened.%player%} is 3:
  3487. cancel event
  3488. add 1 to {mineplex.chestsopened.%player%}
  3489. make the event-block appear open
  3490. rewardTreasure(player, {mineplex.inchest.%player%}, 4, 1)
  3491. loop all players:
  3492. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3493. wait 3 seconds
  3494. resetPoints(player, 4)
  3495. execute player command "/hub"
  3496. stop
  3497. else if {mineplex.chestsopened.%player%} is 1 or 2:
  3498. cancel event
  3499. add 1 to {mineplex.chestsopened.%player%}
  3500. make the event-block appear open
  3501. rewardTreasure(player, {mineplex.inchest.%player%}, 4, 1)
  3502. loop all players:
  3503. show 200 "flame" particles at location 0.1 metres above event-block for loop-player
  3504. stop
  3505. else if {mineplex.chestsopened.%player%} is not 1 or 2 or 3:
  3506. cancel event
  3507. else:
  3508. cancel event
  3509.  
  3510. on quit:
  3511. set {_p} to player
  3512. if {mineplex.inchest.%{_p}%} is set:
  3513. resetPoints({_p}, {mineplex.inchest.%{_p}%})
  3514. delete {mineplex.inchest.%{_p}%}
  3515. #Scoreboard
  3516.  
  3517. every 2 seconds:
  3518. if {mineplex.usescoreboard} is false:
  3519. stop
  3520. else:
  3521. loop all players:
  3522. wipe loop-player's sidebar
  3523. set {_fc} to convert string {mineplex.config.servername} to uppercase
  3524. set name of sidebar of loop-player to "&6&l%{_fc}%"
  3525. set score "&b&lServer" in sidebar of loop-player to 15
  3526. set score "&f%{mineplex.config.world}%" in sidebar of loop-player to 14
  3527. set score "&1 " in sidebar of loop-player to 13
  3528. set score "&a&lGems" in sidebar of loop-player to 12
  3529. set score "&r%{mineplex.gems.%loop-player%}%" in sidebar of loop-player to 11
  3530. set score "&2 " in sidebar of loop-player to 10
  3531. set score "&e&lShards" in sidebar of loop-player to 9
  3532. set score "&f%{mineplex.shards.%loop-player%}%" in sidebar of loop-player to 8
  3533. set score "&3 " in sidebar of loop-player to 7
  3534. set score "&6&lRank" in sidebar of loop-player to 6
  3535. set score "&f%{mineplex.api.displayrank.%loop-player%}%" in sidebar of loop-player to 5
  3536. set score "&4 " in sidebar of loop-player to 4
  3537. set score "&c&lWebsite" in sidebar of loop-player to 3
  3538. set score "&f%{mineplex.config.website}%" in sidebar of loop-player to 2
  3539. set score "&f----------------" in sidebar of loop-player to 1
  3540.  
  3541. #Rank Loader
  3542.  
  3543. function rankLoad(p: player , n: number , t: number) :: string:
  3544. if {_n} is 1:
  3545. if {mineplex.testrank.%{_p}%} is set:
  3546. if {_t} is 0:
  3547. set {mineplex.rank.%{_p}%} to {mineplex.testrank.%{_p}%}
  3548. delete {mineplex.testrank.%{_p}%}
  3549. if {mineplex.rank.%{_p}%} is not set:
  3550. set {mineplex.rank.%{_p}%} to ""
  3551. if {mineplex.rank.%{_p}%} is "":
  3552. execute console command "/updaterank %{_p}% ALL"
  3553. set {_p} tab name to "&e%{_p}%"
  3554. set {mineplex.displaya.%{_p}%} to "&fPlayer"
  3555. set {mineplex.colora.%{_p}%} to "§f"
  3556. return "&fPlayer"
  3557. if {mineplex.rank.%{_p}%} is "&b&lULTRA ":
  3558. execute console command "/updaterank %{_p}% ULTRA"
  3559. set {_p} tab name to "&b&lULTRA &e%{_p}%"
  3560. set {mineplex.displaya.%{_p}%} to "&bUltra"
  3561. set {mineplex.colora.%{_p}%} to "§b"
  3562. set {mineplex.hover.%{_p}%} to "&b&lULTRA%nl%&fA first step into the stories of the mist.%nl%&fOnly those brave enough may enter.%nl% %nl%&fThe first purchasable rank at %{mineplex.config.shoplink}%"
  3563. return "&bUltra"
  3564. if {mineplex.rank.%{_p}%} is "&d&lHERO ":
  3565. execute console command "/updaterank %{_p}% HERO"
  3566. set {_p} tab name to "&d&lHERO &e%{_p}%"
  3567. set {mineplex.displaya.%{_p}%} to "&dHero"
  3568. set {mineplex.colora.%{_p}%} to "§d"
  3569. set {mineplex.hover.%{_p}%} to "&d&lHERO%nl%&fThere are many stories of a%nl%&fvaliant Hero who was brave enough to%nl%&ftame the most fearsome dragon in the land.%nl% %nl%&fThe second purchasable rank at %{mineplex.config.shoplink}%"
  3570. return "&dHero"
  3571. if {mineplex.rank.%{_p}%} is "&a&lLEGEND ":
  3572. execute console command "/updaterank %{_p}% LEGEND"
  3573. set {_p} tab name to "&a&lLEGEND &e%{_p}%"
  3574. set {mineplex.displaya.%{_p}%} to "&aLegend"
  3575. set {mineplex.colora.%{_p}%} to "§a"
  3576. set {mineplex.hover.%{_p}%} to "&a&lLEGEND%nl%&fYears they have told stories of this rank,%nl%&fonly for the legends to be true.%nl% %nl%&fThe third purchasable rank at %{mineplex.config.shoplink}%"
  3577. return "&aLegend"
  3578. if {mineplex.rank.%{_p}%} is "&c&lTITAN ":
  3579. execute console command "/updaterank %{_p}% TITAN"
  3580. set {_p} tab name to "&c&lTITAN &e%{_p}%"
  3581. set {mineplex.displaya.%{_p}%} to "&cTitan"
  3582. set {mineplex.colora.%{_p}%} to "§c"
  3583. set {mineplex.hover.%{_p}%} to "&c&lTITAN%nl%&fAncient myths spoke of a gigantic being%nl%&fwith immence power...%nl% %nl%&fThe fourth purchasable rank at %{mineplex.config.shoplink}%"
  3584. return "&cTitan"
  3585. if {mineplex.rank.%{_p}%} is "&6&lTRAINEE ":
  3586. execute console command "/updaterank %{_p}% TRAINEE"
  3587. loop {mineplex.patreon::*}: #Do not worry about this. It only has to do with my test server, not you guys <3
  3588. if loop-value is {_p}:
  3589. set {_p} tab name to "&6&lP.TRAINEE &e%{_p}%"
  3590. else:
  3591. set {_p} tab name to "&6&lTRAINEE &e%{_p}%"
  3592. set {_p} tab name to "&6&lTRAINEE &e%{_p}%"
  3593. set {mineplex.displaya.%{_p}%} to "&6Trainee"
  3594. set {mineplex.colora.%{_p}%} to "§6"
  3595. set {mineplex.hover.%{_p}%} to "&6&lTRAINEE%nl%&fTrainee are moderators-in-training.%nl%&ftheir duties include enforcing the rules and%nl%&fproviding help to anyone with questions or concerns.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3596. return "&6Trainee"
  3597. if {mineplex.rank.%{_p}%} is "&6&lMOD ":
  3598. execute console command "/updaterank %{_p}% MODERATOR"
  3599. loop {mineplex.patreon::*}: #Do not worry about this. It only has to do with my test server, not you guys <3
  3600. if loop-value is {_p}:
  3601. set {_p} tab name to "&6&lP.MOD &e%{_p}%"
  3602. else:
  3603. set {_p} tab name to "&6&lMOD &e%{_p}%"
  3604. set {mineplex.displaya.%{_p}%} to "&6Mod"
  3605. set {mineplex.colora.%{_p}%} to "§6"
  3606. set {mineplex.hover.%{_p}%} to "&6&lMOD%nl%&fModerators enforce rules and provide help to%nl%&fanyone with questions or concerns.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3607. return "&6Mod"
  3608. if {mineplex.rank.%{_p}%} is "&6&lSR.MOD ":
  3609. execute console command "/updaterank %{_p}% SNR_MODERATOR"
  3610. loop {mineplex.patreon::*}: #Do not worry about this. It only has to do with my test server, not you guys <3
  3611. if loop-value is {_p}:
  3612. set {_p} tab name to "&6&lP.SR.MOD &e%{_p}%"
  3613. else:
  3614. set {_p} tab name to "&6&lSR.MOD &e%{_p}%"
  3615. set {mineplex.displaya.%{_p}%} to "&6Sr.Mod"
  3616. set {mineplex.colora.%{_p}%} to "§6"
  3617. set {mineplex.hover.%{_p}%} to "&6&lSR.MOD%nl%&fSenior Moderators are members of a special%nl%&fSenior Moderators team where they have to fulfull specific tasks.%nl%&fJust like Moderators, you can always ask them for help.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3618. return "&6Sr.Mod"
  3619. if {mineplex.rank.%{_p}%} is "&6&lC.MOD ":
  3620. execute console command "/updaterank %{_p}% CLANS_MOD"
  3621. set {_p} tab name to "&6&lC.MOD &e%{_p}%"
  3622. set {mineplex.displaya.%{_p}%} to "&6C.Mod"
  3623. set {mineplex.colora.%{_p}%} to "§6"
  3624. set {mineplex.hover.%{_p}%} to "&6&lC.MOD%nl%&fClans Moderators are members of a special%nl%&fSenior Moderators team where they focus on helping the clans servers.%nl%&fJust like Moderators, you can always ask them for help.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3625. return "&6C.Mod"
  3626. if {mineplex.rank.%{_p}%} is "&4&lADMIN ":
  3627. execute console command "/updaterank %{_p}% ADMIN"
  3628. loop {mineplex.patreon::*}: #Do not worry about this. It only has to do with my test server, not you guys <3
  3629. if loop-value is {_p}:
  3630. set {_p} tab name to "&6&lP.ADMIN &e%{_p}%"
  3631. else:
  3632. set {_p} tab name to "&4&lADMIN &e%{_p}%"
  3633. set {mineplex.displaya.%{_p}%} to "&4Admin"
  3634. set {mineplex.colora.%{_p}%} to "§4"
  3635. set {mineplex.hover.%{_p}%} to "&4&lADMIN%nl%&fAn Administrator's role is to manage%nl%&ftheir respective Senoir Moderator team%nl%&fand all moderators within it."
  3636. return "&4Admin"
  3637. if {mineplex.rank.%{_p}%} is "&9&lAPEX ":
  3638. execute console command "/updaterank %{_p}% APEX"
  3639. set {_p} tab name to "&9&lAPEX &e%{_p}%"
  3640. set {mineplex.displaya.%{_p}%} to "&9Apex"
  3641. set {mineplex.colora.%{_p}%} to "§4"
  3642. set {mineplex.hover.%{_p}%} to "&9&lAPEX%nl%&fStaff at Apex Hosting. These guys help support the test server!"
  3643. return "&9Apex"
  3644. if {mineplex.rank.%{_p}%} is "&4&lLEADER ":
  3645. execute console command "/updaterank %{_p}% LEADER"
  3646. loop {mineplex.patreon::*}: #Do not worry about this. It only has to do with my test server, not you guys <3
  3647. if loop-value is {_p}:
  3648. set {_p} tab name to "&6&lP.LEADER &e%{_p}%"
  3649. else:
  3650. set {_p} tab name to "&4&lLEADER &e%{_p}%"
  3651. set {mineplex.displaya.%{_p}%} to "&4Leader"
  3652. set {mineplex.colora.%{_p}%} to "§4"
  3653. set {mineplex.hover.%{_p}%} to "&4&lLEADER%nl%&fLeaders manage the operation of their respective team%nl%&for projects. They usually operate on affairs within%nl%&fthe staff, development, or management team."
  3654. return "&4Leader"
  3655. if {mineplex.rank.%{_p}%} is "&4&lOWNER ":
  3656. execute console command "/updaterank %{_p}% OWNER"
  3657. loop {mineplex.patreon::*}: #Do not worry about this. It only has to do with my test server, not you guys <3
  3658. if loop-value is {_p}:
  3659. set {_p} tab name to "&6&lP.OWNER &e%{_p}%"
  3660. else:
  3661. set {_p} tab name to "&4&lOWNER &e%{_p}%"
  3662. set {mineplex.displaya.%{_p}%} to "&4Owner"
  3663. set {mineplex.colora.%{_p}%} to "§4"
  3664. set {mineplex.hover.%{_p}%} to "&4&lOWNER%nl%&fOwners are the founders of Mineplex.%nl%&fEach owner manages a different aspect of the%nl%server and ensures its efficient operation."
  3665. return "&4Owner"
  3666. if {mineplex.rank.%{_p}%} is "&9&lBUILDER ":
  3667. execute console command "/updaterank %{_p}% BUILDER"
  3668. set {_p} tab name to "&9&lBUIDLER &e%{_p}%"
  3669. set {mineplex.displaya.%{_p}%} to "&9Mapper"
  3670. set {mineplex.colora.%{_p}%} to "§9"
  3671. set {mineplex.hover.%{_p}%} to "&9&lBUILDER%nl%&fBuilders are members of the Mineplex Build Team.%nl%&fThey create many of the maps used across Mineplex."
  3672. return "&9Builder"
  3673. if {mineplex.rank.%{_p}%} is "&9&lMAPPER ":
  3674. execute console command "/updaterank %{_p}% MAPPER"
  3675. set {_p} tab name to "&9&lMAPPER &e%{_p}%"
  3676. set {mineplex.displaya.%{_p}%} to "&9Mapper"
  3677. set {mineplex.colora.%{_p}%} to "§9"
  3678. set {mineplex.hover.%{_p}%} to "&9&lMAPPER%nl%&fThese senior members work closely with the development and design teams to build new maps for new and old content!"
  3679. return "&9Mapper"
  3680. if {mineplex.rank.%{_p}%} is "&9&lMAPLEAD ":
  3681. execute console command "/updaterank %{_p}% MAPLEAD"
  3682. set {_p} tab name to "&9&lMAPLEAD &e%{_p}%"
  3683. set {mineplex.displaya.%{_p}%} to "&9MapLead"
  3684. set {mineplex.colora.%{_p}%} to "§9"
  3685. set {mineplex.hover.%{_p}%} to "&9&lMAPLEAD%nl%&fMap Leaders are leaders of the Mineplex Build Team.%nl%&fThey oversee the creation of new maps and manage Builders."
  3686. return "&9MapLead"
  3687. if {mineplex.rank.%{_p}%} is "&6&lJR.DEV ":
  3688. execute console command "/updaterank %{_p}% JNR_DEV"
  3689. set {mineplex.displaya.%{_p}%} to "&6Jr.Dev"
  3690. set {mineplex.colora.%{_p}%} to "§c"
  3691. set {mineplex.hover.%{_p}%} to "&6&lJR.DEV%nl%&fThese are part time Developers that work behind the%nl%&fscenes to create new games and features,%nl%&fand fix bugs to give the best experience."
  3692. return "&6Jr.Dev"
  3693. if {mineplex.rank.%{_p}%} is "&4&lDEV ":
  3694. execute console command "/updaterank %{_p}% DEVELOPER"
  3695. set {_p} tab name to "&4&lDEV &e%{_p}%"
  3696. set {mineplex.displaya.%{_p}%} to "&4Dev"
  3697. set {mineplex.colora.%{_p}%} to "§4"
  3698. set {mineplex.hover.%{_p}%} to "&4&lDEV%nl%&fDevelopers work behind the scenes to%nl%&fcreate new games and features, and fix bugs to%nl%&fgive the best experience."
  3699. return "&4Dev"
  3700. if {mineplex.rank.%{_p}%} is "&5&lTWITCH ":
  3701. execute console command "/updaterank %{_p}% TWITCH"
  3702. set {_p} tab name to "&5&lTWITCH &e%{_p}%"
  3703. set {mineplex.displaya.%{_p}%} to "&5Twitch"
  3704. set {mineplex.colora.%{_p}%} to "§5"
  3705. set {mineplex.hover.%{_p}%} to "&5&lTWITCH%nl%&fA Twitch streamer who often features%nl%&fMinepex in their streams."
  3706. return "&5Twitch"
  3707. if {mineplex.rank.%{_p}%} is "&c&lYOUTUBE ":
  3708. execute console command "/updaterank %{_p}% YOUTUBE"
  3709. set {_p} tab name to "&c&lYOUTUBE &e%{_p}%"
  3710. set {mineplex.displaya.%{_p}%} to "&cYouTube"
  3711. set {mineplex.colora.%{_p}%} to "§c"
  3712. set {mineplex.hover.%{_p}%} to "&c&lYOUTUBE%nl%&fA YouTuber who creates content for%nl%&for related to Mineplex.%nl%&fThey are the official YouTubers of Mineplex."
  3713. return "&cYouTube"
  3714. if {mineplex.rank.%{_p}%} is "&f&lEVENT ":
  3715. execute console command "/updaterank %{_p}% EVENT"
  3716. set {_p} tab name to "&f&lEVENT &e%{_p}%"
  3717. set {mineplex.displaya.%{_p}%} to "&fEvent"
  3718. set {mineplex.colora.%{_p}%} to "§f"
  3719. set {mineplex.hover.%{_p}%} to "&f&lEVENT%nl%&f???"
  3720. return "&fEvent"
  3721. if {mineplex.rank.%{_p}%} is "&5&lYT ":
  3722. execute console command "/updaterank %{_p}% YT"
  3723. set {_p} tab name to "&5&lYT &e%{_p}%"
  3724. set {mineplex.displaya.%{_p}%} to "&5YT"
  3725. set {mineplex.colora.%{_p}%} to "§5"
  3726. set {mineplex.hover.%{_p}%} to "&5&lYT%nl%&fA YouTuber who creates content for%nl%&for related to Mineplex."
  3727. return "&5YT"
  3728. if {mineplex.rank.%{_p}%} is "&3&lETERNAL ":
  3729. execute console command "/updaterank %{_p}% ETERNAL"
  3730. set {_p} tab name to "&3&lETERNAL &e%{_p}%"
  3731. set {mineplex.displaya.%{_p}%} to "&3Eternal"
  3732. set {mineplex.colora.%{_p}%} to "§3"
  3733. set {mineplex.hover.%{_p}%} to "&3&lETERNAL%nl%&fFantastic and magical, no one%nl%&fexcept the time lords truly understand%nl%&fthe power of this rank.%nl% %nl%&fThe fifth purchasable rank at %{mineplex.config.shoplink}%"
  3734. return "&3Eternal"
  3735. if {mineplex.rank.%{_p}%} is "&9&lSUPPORT ":
  3736. execute console command "/updaterank %{_p}% SUPPORT"
  3737. set {mineplex.displaya.%{_p}%} to "&9Support"
  3738. set {mineplex.colora.%{_p}%} to "§9"
  3739. set {mineplex.hover.%{_p}%} to "&9&lSUPPORT%nl%&fSupport agents handle tickets and%nl%&fprovide customer service."
  3740. return "&9Support"
  3741. if {mineplex.rank.%{_p}%} is "&9&lARTIST ":
  3742. execute console command "/updaterank %{_p}% ARTIST"
  3743. set {mineplex.displaya.%{_p}%} to "&9Artist"
  3744. set {mineplex.colora.%{_p}%} to "§9"
  3745. set {mineplex.hover.%{_p}%} to "&9&lARTIST%nl%&fThe Artist rank is given to talented artists%nl%who are endorsed to create content for Mineplex."
  3746. return "&9Artist"
  3747. else if {_n} is 2:
  3748. if {mineplex.testrank.%{_p}%} is set:
  3749. if {_t} is 0:
  3750. set {mineplex.rank.%{_p}%} to {mineplex.testrank.%{_p}%}
  3751. delete {mineplex.testrank.%{_p}%}
  3752. if {mineplex.rank.%{_p}%} is not set:
  3753. set {mineplex.rank.%{_p}%} to ""
  3754. if {mineplex.rank.%{_p}%} is "":
  3755. set {_p} tab name to "&e%{_p}%"
  3756. set {mineplex.displaya.%{_p}%} to "&fPlayer"
  3757. set {mineplex.colora.%{_p}%} to "§f"
  3758. return "&fPlayer"
  3759. if {mineplex.rank.%{_p}%} is "&b&lULTRA ":
  3760. set {_p} tab name to "&b&lULTRA &e%{_p}%"
  3761. set {mineplex.displaya.%{_p}%} to "&bUltra"
  3762. set {mineplex.colora.%{_p}%} to "§b"
  3763. set {mineplex.hover.%{_p}%} to "&b&lULTRA%nl%&fA first step into the stories of the mist.%nl%&fOnly those brave enough may enter.%nl% %nl%&fThe first purchasable rank at %{mineplex.config.shoplink}%"
  3764. return "&bUltra"
  3765. if {mineplex.rank.%{_p}%} is "&d&lHERO ":
  3766. set {_p} tab name to "&d&lHERO &e%{_p}%"
  3767. set {mineplex.displaya.%{_p}%} to "&dHero"
  3768. set {mineplex.colora.%{_p}%} to "§d"
  3769. set {mineplex.hover.%{_p}%} to "&d&lHERO%nl%&fThere are many stories of a%nl%&fvaliant Hero who was brave enough to%nl%&ftame the most fearsome dragon in the land.%nl% %nl%&fThe second purchasable rank at %{mineplex.config.shoplink}%"
  3770. return "&dHero"
  3771. if {mineplex.rank.%{_p}%} is "&a&lLEGEND ":
  3772. set {_p} tab name to "&a&lLEGEND &e%{_p}%"
  3773. set {mineplex.displaya.%{_p}%} to "&aLegend"
  3774. set {mineplex.colora.%{_p}%} to "§a"
  3775. set {mineplex.hover.%{_p}%} to "&a&lLEGEND%nl%&fYears they have told stories of this rank,%nl%&fonly for the legends to be true.%nl% %nl%&fThe third purchasable rank at %{mineplex.config.shoplink}%"
  3776. return "&aLegend"
  3777. if {mineplex.rank.%{_p}%} is "&c&lTITAN ":
  3778. set {_p} tab name to "&c&lTITAN &e%{_p}%"
  3779. set {mineplex.displaya.%{_p}%} to "&cTitan"
  3780. set {mineplex.colora.%{_p}%} to "§c"
  3781. set {mineplex.hover.%{_p}%} to "&c&lTITAN%nl%&fAncient myths spoke of a gigantic being%nl%&fwith immence power...%nl% %nl%&fThe fourth purchasable rank at %{mineplex.config.shoplink}%"
  3782. return "&cTitan"
  3783. if {mineplex.rank.%{_p}%} is "&6&lTRAINEE ":
  3784. set {_p} tab name to "&6&lTRAINEE &e%{_p}%"
  3785. set {mineplex.displaya.%{_p}%} to "&6Trainee"
  3786. set {mineplex.colora.%{_p}%} to "§6"
  3787. set {mineplex.hover.%{_p}%} to "&6&lTRAINEE%nl%&fTrainee are moderators-in-training.%nl%&ftheir duties include enforcing the rules and%nl%&fproviding help to anyone with questions or concerns.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3788. return "&6Trainee"
  3789. if {mineplex.rank.%{_p}%} is "&6&lMOD ":
  3790. set {_p} tab name to "&6&lMOD &e%{_p}%"
  3791. set {mineplex.displaya.%{_p}%} to "&6Mod"
  3792. set {mineplex.colora.%{_p}%} to "§6"
  3793. set {mineplex.hover.%{_p}%} to "&6&lMOD%nl%&fModerators enforce rules and provide help to%nl%&fanyone with questions or concerns.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3794. return "&6Mod"
  3795. if {mineplex.rank.%{_p}%} is "&6&lSR.MOD ":
  3796. set {_p} tab name to "&6&lSR.MOD &e%{_p}%"
  3797. set {mineplex.displaya.%{_p}%} to "&6Sr.Mod"
  3798. set {mineplex.colora.%{_p}%} to "§6"
  3799. set {mineplex.hover.%{_p}%} to "&6&lSR.MOD%nl%&fSenior Moderators are members of a special%nl%&fSenior Moderators team where they have to fulfull specific tasks.%nl%&fJust like Moderators, you can always ask them for help.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3800. return "&6Sr.Mod"
  3801. if {mineplex.rank.%{_p}%} is "&6&lC.MOD ":
  3802. set {_p} tab name to "&6&lC.MOD &e%{_p}%"
  3803. set {mineplex.displaya.%{_p}%} to "&6C.Mod"
  3804. set {mineplex.colora.%{_p}%} to "§6"
  3805. set {mineplex.hover.%{_p}%} to "&6&lC.MOD%nl%&fClans Moderators are members of a special%nl%&fSenior Moderators team where they focus on helping the clans servers.%nl%&fJust like Moderators, you can always ask them for help.%nl% %nl%&fFor assistance, contact them using &e/a <message>&f."
  3806. return "&6C.Mod"
  3807. if {mineplex.rank.%{_p}%} is "&4&lADMIN ":
  3808. set {_p} tab name to "&4&lADMIN &e%{_p}%"
  3809. set {mineplex.displaya.%{_p}%} to "&4Admin"
  3810. set {mineplex.colora.%{_p}%} to "§4"
  3811. set {mineplex.hover.%{_p}%} to "&4&lADMIN%nl%&fAn Administrator's role is to manage%nl%&ftheir respective Senoir Moderator team%nl%&fand all moderators within it."
  3812. return "&4Admin"
  3813. if {mineplex.rank.%{_p}%} is "&9&lAPEX ":
  3814. set {_p} tab name to "&9&lAPEX &e%{_p}%"
  3815. set {mineplex.displaya.%{_p}%} to "&9Apex"
  3816. set {mineplex.colora.%{_p}%} to "§4"
  3817. set {mineplex.hover.%{_p}%} to "&9&lAPEX%nl%&fStaff at Apex Hosting. These guys help support the test server!"
  3818. return "&9Apex"
  3819. if {mineplex.rank.%{_p}%} is "&4&lLEADER ":
  3820. set {_p} tab name to "&4&lLEADER &e%{_p}%"
  3821. set {mineplex.displaya.%{_p}%} to "&4Leader"
  3822. set {mineplex.colora.%{_p}%} to "§4"
  3823. set {mineplex.hover.%{_p}%} to "&4&lLEADER%nl%&fLeaders manage the operation of their respective team%nl%&for projects. They usually operate on affairs within%nl%&fthe staff, development, or management team."
  3824. return "&4Leader"
  3825. if {mineplex.rank.%{_p}%} is "&4&lOWNER ":
  3826. set {_p} tab name to "&4&lOWNER &e%{_p}%"
  3827. set {mineplex.displaya.%{_p}%} to "&4Owner"
  3828. set {mineplex.colora.%{_p}%} to "§4"
  3829. set {mineplex.hover.%{_p}%} to "&4&lOWNER%nl%&fOwners are the founders of Mineplex.%nl%&fEach owner manages a different aspect of the%nl%server and ensures its efficient operation."
  3830. return "&4Owner"
  3831. if {mineplex.rank.%{_p}%} is "&9&lBUILDER ":
  3832. set {_p} tab name to "&9&lBUIDLER &e%{_p}%"
  3833. set {mineplex.displaya.%{_p}%} to "&8Builder"
  3834. set {mineplex.colora.%{_p}%} to "§9"
  3835. set {mineplex.hover.%{_p}%} to "&9&lBUILDER%nl%&fThese creative staff members help build maps for your favorite games!"
  3836. return "&9Builder"
  3837. if {mineplex.rank.%{_p}%} is "&9&lMAPLEAD ":
  3838. set {_p} tab name to "&9&lMAPLEAD &e%{_p}%"
  3839. set {mineplex.displaya.%{_p}%} to "&9MapLead"
  3840. set {mineplex.colora.%{_p}%} to "§9"
  3841. set {mineplex.hover.%{_p}%} to "&9&lMAPLEAD%nl%&fMap Leaders are leaders of the Mineplex Build Team.%nl%&fThey oversee the creation of new maps and manage Builders."
  3842. return "&9MapLead"
  3843. if {mineplex.rank.%{_p}%} is "&9&lMAPPER ":
  3844. set {_p} tab name to "&9&lMAPPER &e%{_p}%"
  3845. set {mineplex.displaya.%{_p}%} to "&9Mapper"
  3846. set {mineplex.colora.%{_p}%} to "§9"
  3847. set {mineplex.hover.%{_p}%} to "&9&lMAPPER%nl%&fThese senior members work closely with the development and design teams to build new maps for new and old content!"
  3848. return "&9Mapper"
  3849. if {mineplex.rank.%{_p}%} is "&6&lJR.DEV ":
  3850. set {mineplex.displaya.%{_p}%} to "&6Jr.Dev"
  3851. set {mineplex.colora.%{_p}%} to "§c"
  3852. set {mineplex.hover.%{_p}%} to "&6&lJR.DEV%nl%&fThese are part time Developers that work behind the%nl%&fscenes to create new games and features,%nl%&fand fix bugs to give the best experience."
  3853. return "&6Jr.Dev"
  3854. if {mineplex.rank.%{_p}%} is "&4&lDEV ":
  3855. set {_p} tab name to "&4&lDEV &e%{_p}%"
  3856. set {mineplex.displaya.%{_p}%} to "&4Dev"
  3857. set {mineplex.colora.%{_p}%} to "§4"
  3858. set {mineplex.hover.%{_p}%} to "&4&lDEV%nl%&fDevelopers work behind the scenes to%nl%&fcreate new games and features, and fix bugs to%nl%&fgive the best experience."
  3859. return "&4Dev"
  3860. if {mineplex.rank.%{_p}%} is "&5&lTWITCH ":
  3861. set {_p} tab name to "&5&lTWITCH &e%{_p}%"
  3862. set {mineplex.displaya.%{_p}%} to "&5Twitch"
  3863. set {mineplex.colora.%{_p}%} to "§5"
  3864. set {mineplex.hover.%{_p}%} to "&5&lTWITCH%nl%&fA Twitch streamer who often features%nl%&fMinepex in their streams."
  3865. return "&5Twitch"
  3866. if {mineplex.rank.%{_p}%} is "&c&lYOUTUBE ":
  3867. set {_p} tab name to "&c&lYOUTUBE &e%{_p}%"
  3868. set {mineplex.displaya.%{_p}%} to "&cYouTube"
  3869. set {mineplex.colora.%{_p}%} to "§c"
  3870. set {mineplex.hover.%{_p}%} to "&c&lYOUTUBE%nl%&fA YouTuber who creates content for%nl%&for related to Mineplex.%nl%&fThey are the official YouTubers of Mineplex."
  3871. return "&cYouTube"
  3872. if {mineplex.rank.%{_p}%} is "&f&lEVENT ":
  3873. set {_p} tab name to "&f&lEVENT &e%{_p}%"
  3874. set {mineplex.displaya.%{_p}%} to "&fEvent"
  3875. set {mineplex.colora.%{_p}%} to "§f"
  3876. set {mineplex.hover.%{_p}%} to "&f&lEVENT%nl%&f???"
  3877. return "&fEvent"
  3878. if {mineplex.rank.%{_p}%} is "&5&lYT ":
  3879. set {_p} tab name to "&5&lYT &e%{_p}%"
  3880. set {mineplex.displaya.%{_p}%} to "&5YT"
  3881. set {mineplex.colora.%{_p}%} to "§5"
  3882. set {mineplex.hover.%{_p}%} to "&5&lYT%nl%&fA YouTuber who creates content for%nl%&for related to Mineplex."
  3883. return "&5YT"
  3884. if {mineplex.rank.%{_p}%} is "&3&lETERNAL ":
  3885. set {_p} tab name to "&3&lETERNAL &e%{_p}%"
  3886. set {mineplex.displaya.%{_p}%} to "&3Eternal"
  3887. set {mineplex.colora.%{_p}%} to "§3"
  3888. set {mineplex.hover.%{_p}%} to "&3&lETERNAL%nl%&fFantastic and magical, no one%nl%&fexcept the time lords truly understand%nl%&fthe power of this rank.%nl% %nl%&fThe fifth purchasable rank at %{mineplex.config.shoplink}%"
  3889. return "&3Eternal"
  3890. if {mineplex.rank.%{_p}%} is "&9&lSUPPORT ":
  3891. set {mineplex.displaya.%{_p}%} to "&9Support"
  3892. set {mineplex.colora.%{_p}%} to "§9"
  3893. set {mineplex.hover.%{_p}%} to "&9&lSUPPORT%nl%&fSupport agents handle tickets and%nl%&fprovide customer service."
  3894. return "&9Support"
  3895. if {mineplex.rank.%{_p}%} is "&9&lARTIST ":
  3896. set {mineplex.displaya.%{_p}%} to "&9Artist"
  3897. set {mineplex.colora.%{_p}%} to "§9"
  3898. set {mineplex.hover.%{_p}%} to "&9&lARTIST%nl%&fThe Artist rank is given to talented artists%nl%who are endorsed to create content for Mineplex."
  3899. return "&9Artist"
  3900.  
  3901. on death of player:
  3902. if attacker is a player:
  3903. if projectile is set:
  3904. set the death message to "&9Death> &e%victim% &7killed by &e%attacker% &7with &eArchery&7."
  3905. if attacker is not a player:
  3906. if attacker is set:
  3907. set {_dm} to 1st char in each word of "%attacker%" to caps
  3908. set the death message to "&9Death> &e%victim% &7killed by &e%{_dm}%&7."
  3909.  
  3910. on join:
  3911. wait 2 ticks
  3912. rankLoad(player, 1, 0)
  3913. loop all players:
  3914. updateRankAPI(loop-player)
  3915.  
  3916. on flight toggle:
  3917. if {mineplex.config.doublejump} is "true":
  3918. if {doublejump.%uuid of player%} is set:
  3919. if player's gamemode is not creative:
  3920. cancel event
  3921. delete {doublejump.%uuid of player%}
  3922. wait 0.1 tick
  3923. set player's flight state to false
  3924. push player upward at speed 0.3
  3925. push player forward at speed 0.9
  3926. play raw sound "mob.ghast.fireball" at player with pitch 2 volume 0.99
  3927. else:
  3928. stop
  3929. else:
  3930. stop
  3931. else:
  3932. stop
  3933.  
  3934. on jump:
  3935. if player's gamemode is not creative:
  3936. if {doublejump.%uuid of player%} is not set:
  3937. if block below player is not air or water:
  3938. set player's flight state to true
  3939. set {doublejump.%uuid of player%} to true
  3940. else:
  3941. stop
  3942. else:
  3943. stop
  3944. else:
  3945. stop
  3946.  
  3947. on quit:
  3948. set {mineplex.rank.uuid.%uuid of player%} to {mineplex.rank.%player%}
  3949.  
  3950. #Chat System
  3951.  
  3952. on chat:
  3953. set {_get} to getPlayerdata(player, "muted")
  3954. if {_get} is "yes":
  3955. if {muted::%player%::type} is "perm":
  3956. send "&9Punish> &7Shh, you're muted because %{muted::%player%::reason}% by %{muted::%player%::by}% for Permanent."
  3957. cancel event
  3958. stop
  3959. if {muted::%player%::type} is "temp":
  3960. set {_waited} to difference between now and {muted::%player%::when}
  3961. if {_waited} is less than {muted::%player%::time}:
  3962. send "&9Punish> &7Shh, you're muted because %{muted::%player%::reason}% by %{muted::%player%::by}% for &a%{muted::%player%::time}%."
  3963. cancel event
  3964. stop
  3965. if message contains "hack" or "hax":
  3966. cancel event
  3967. send "&9Chat> &7Accusing players of cheating in-game is against the rules. If you think someone is cheating, please gather evidence and report it at &a%{mineplex.config.website}%"
  3968. stop
  3969. if {mineplex.vanish.%player%} is false:
  3970. if {mineplex.chatslow} is set:
  3971. if player has permission "mineplex.mod":
  3972. set {_check} to mcs((player), (message))
  3973. if {_check} is less than 0:
  3974. cancel event
  3975. delete {_check}
  3976. else:
  3977. if difference between {lastChat::%player%} and now < {mineplex.chatslow}:
  3978. cancel event
  3979. send "&9Chat> &7Chat slow enabled. Please wait."
  3980. else:
  3981. set {lastChat::%player%} to now
  3982. set {_check} to mcs((player), (message))
  3983. if {_check} is less than 0:
  3984. cancel event
  3985. delete {_check}
  3986. else if {mineplex.chatsilence} is set:
  3987. if player has permission "mineplex.trainee":
  3988. set {_check} to mcs((player), (message))
  3989. if {_check} is less than 0:
  3990. cancel event
  3991. delete {_check}
  3992. else:
  3993. cancel event
  3994. send "&9Chat> &7The chat is silenced."
  3995. else:
  3996. if {party.%player%.chat} is true:
  3997. if length of message is greater than 1:
  3998. if first character of message is "@":
  3999. cancel event
  4000. set message to "%subtext of message from characters 2 to (length of message)%"
  4001. loop {party.%{party.%player%}%::*}:
  4002. message "&5&lParty &f&l%player% &d%message%" to loop-value
  4003. else:
  4004. set {_check} to mcs((player), (message))
  4005. if {_check} is less than 0:
  4006. cancel event
  4007. delete {_check}
  4008. else:
  4009. set {_check} to mcs((player), (message))
  4010. if {_check} is less than 0:
  4011. cancel event
  4012. delete {_check}
  4013. else:
  4014. set {_check} to mcs((player), (message))
  4015. if {_check} is less than 0:
  4016. cancel event
  4017. delete {_check}
  4018. else if {mineplex.vanish.%player%} is true:
  4019. send "&eYou can not chat while incognito."
  4020. cancel event
  4021. else:
  4022. set {mineplex.vanish.%player%} to false
  4023. set {_check} to mcs((player), (message))
  4024. if {_check} is less than 0:
  4025. cancel event
  4026. delete {_check}
  4027.  
  4028. #Join, Quit, and Load Handlers
  4029.  
  4030. on join:
  4031. if player has permission "mineplex.admin":
  4032. $ thread
  4033. set {_ver} to line 1 from url "http://pastebin.com/raw/LG11nc8b" parsed as a number
  4034. set {_c} to "{@MCRVER}" parsed as a number
  4035. if {_c} is greater than {_ver}:
  4036. send "&9MCR> &7You must be using some fancy indev version!"
  4037. send "&9MCR> &7or you're retarded and changed the version in the config!"
  4038. stop
  4039. else if {_c} is less than {_ver}:
  4040. send "&9MCR> &7Version &e%{_ver}% &7is ready for download"
  4041. else:
  4042. send "&9MCR> &7Your version of MCR is currently up to date!"
  4043. stop
  4044. send "&9MCR> &7Changelog:"
  4045. $ thread
  4046. set {_var1::*} to contents from url "http://pastebin.com/raw/YDB8kU1v"
  4047. loop {_var1::*}:
  4048. send "%loop-value%"
  4049.  
  4050. loop {_var::*}:
  4051. send "&9MCR> &7Version &e%loop-value% &7is ready for download"
  4052. send "&9MCR> &7End of Changelog!"
  4053. if {mineplex.gadget.enabled} is not set:
  4054. set {mineplex.gadget.enabled} to true
  4055. if {mineplex.report.id} is not set:
  4056. set {mineplex.report.id} to 1
  4057. if {mineplex.dj} is not set:
  4058. set {mineplex.dj} to true
  4059. if {mineplex.tntlauncher} is not set:
  4060. set {mineplex.tntlauncher} to true
  4061. if {poll.id.last} is not set:
  4062. set {poll.id.last} to 0
  4063. if {mineplex.ff.list::%player%} is set:
  4064. if player does not have permission "mineplex.trainee":
  4065. delete {mineplex.ff.list::%player%}
  4066. delete {mineplex.pref.ff.%player%}
  4067. if {mineplex.totalaccounts.%ip address of player%::*} does not contain "%player%":
  4068. add "%player%" to {mineplex.totalaccounts.%ip address of player%::*}
  4069.  
  4070. on load:
  4071. #set {_var::*} to contents from url "https://raw.githubusercontent.com/WheezyGold7931/Mineplex-Core/master/version.txt" Raw in GitHub does not update fast enough rip lel
  4072. set {_ver} to line 1 from url "http://pastebin.com/raw/LG11nc8b" parsed as a number
  4073. set {_c} to "{@MCRVER}" parsed as a number
  4074. if {_c} is more than {_ver}:
  4075. broadcast "&9MCR> &7You must be using some fancy indev version!"
  4076. broadcast "&9MCR> &7or you're retarded and changed the version in the config!"
  4077. stop
  4078. else if {_c} is less than {_ver}:
  4079. broadcast "&9MCR> &7Version &e%{_ver}% &7is ready for download"
  4080. else:
  4081. broadcast "&9MCR> &7Your version of MCR is currently up to date!"
  4082. broadcast "&9MCR> &7Client Version: {@MCRVER}"
  4083. broadcast "&9MCR> &7Server Version: %{_ver}%"
  4084. stop
  4085. broadcast "&9MCR> &7Changelog:"
  4086. $ thread
  4087. set {_var1::*} to contents from url "http://pastebin.com/raw/YDB8kU1v"
  4088. loop {_var1::*}:
  4089. broadcast "%loop-value%"
  4090.  
  4091. loop {_var::*}:
  4092. broadcast "&9MCR> &7Version &e%loop-value% &7is ready for download"
  4093. broadcast "&9MCR> &7End of Changelog!"
  4094. if {mineplex.gadget.enabled} is not set:
  4095. set {mineplex.gadget.enabled} to true
  4096. if {mineplex.report.id} is not set:
  4097. set {mineplex.report.id} to 1
  4098. if {mineplex.dj} is not set:
  4099. set {mineplex.dj} to true
  4100. if {mineplex.tntlauncher} is not set:
  4101. set {mineplex.tntlauncher} to true
  4102. if {poll.id.last} is not set:
  4103. set {poll.id.last} to 0
  4104.  
  4105. function runNews(p: player) :: boolean:
  4106. set {_sn} to convert string {mineplex.config.servername} to uppercase
  4107. send title from "&6&l%{_sn}%" and "%{mineplex.news.line1}%" to {_p} for 5, 70, 0
  4108. wait 3 seconds
  4109. send title from "&6&l%{_sn}%" and "%{mineplex.news.line2}%" to {_p} for 1, 70, 0
  4110. wait 3 seconds
  4111. send title from "&6&l%{_sn}%" and "%{mineplex.news.line3}%" to {_p} for 1, 70, 0
  4112. wait 3 seconds
  4113. send title from "&6&l%{_sn}%" and "%{mineplex.news.line4}%" to {_p} for 1, 60, 5
  4114.  
  4115. on join:
  4116. set join message to "&8Join> &7%player%"
  4117. updateRankAPI(player)
  4118. delete {mineplex.disguise.%player%}
  4119. execute console command "/ud %player%"
  4120. delete {mineplex.lastm.%player%}
  4121. delete {mineplex.lasta.%player%}
  4122. set tab header to "&f&l%{mineplex.config.servername}% Network &a%{mineplex.config.world}%" and footer to "&fVisit &a%{mineplex.config.website}% &ffor News, Forums and Shop" for player
  4123. if {mineplex.news.allow} is true:
  4124. runNews(player)
  4125. if {mineplex.vanish.%player%} is not set:
  4126. set {mineplex.vanish.%player%} to false
  4127. if {mineplex.overridechat} is not set:
  4128. set {mineplex.overridechat} to true
  4129. if {mineplex.vanish.%player%} is true:
  4130. send ""
  4131. send ""
  4132. send "&6&lYou are currently incognito"
  4133. send "&eThis means you are invisible to all except for those who are"
  4134. send "&4&lAdmin&f+"
  4135. send ""
  4136. send ""
  4137. if {mineplex.pref.hpv.%player%} is false:
  4138. hide all players from player
  4139. if {mineplex.pref.hpv.%player%} is not set:
  4140. set {mineplex.pref.hpv.%player%} to true
  4141. if {mineplex.pref.ff.%player%} is not set:
  4142. set {mineplex.pref.ff.%player%} to false
  4143. if {mineplex.ff.%player%} is not set:
  4144. set {mineplex.ff.%player%} to false
  4145. if {mineplex.pref.pm.%player%} is not set:
  4146. set {mineplex.pref.pm.%player%} to true
  4147. if {mineplex.pref.pc.%player%} is not set:
  4148. set {mineplex.pref.pc.%player%} to true
  4149. if {mineplex.pref.gwen.%player%} is not set:
  4150. set {mineplex.pref.gwen.%player%} to true
  4151. if {mineplex.pref.report.%player%} is not set:
  4152. set {mineplex.pref.report.%player%} to true
  4153. if {mineplex.shards.%player%} is not set:
  4154. set {mineplex.shards.%player%} to 0
  4155. if {mineplex.gems.%player%} is not set:
  4156. set {mineplex.gems.%player%} to 0
  4157. if {mineplex.particle.active.%player%} is not set:
  4158. set {mineplex.particle.active.%player%} to false
  4159. if {mineplex.arrorw.active} is not set:
  4160. set {mineplex.arrow.active} to false
  4161. if {mineplex.adminmode.%player%} is true:
  4162. set {mineplex.adminmode.%player%} to false
  4163. loop all players:
  4164. if {mineplex.vanish.%loop-player%} is true:
  4165. add loop-player to {%player%.vanishlist::*}
  4166. loop all players:
  4167. if loop-player does not have permission "mineplex.admin":
  4168. hide {%player%.vanishlist::*} from all players
  4169. delete {%player%.vanishlist::*}
  4170. delete {mineplex.tp.back.%player%}
  4171. if {mineplex.config.autoop} is "true":
  4172. if player has permission "mineplex.admin":
  4173. op the player
  4174. else:
  4175. deop the player
  4176.  
  4177. function newsinit(i: integer) :: number:
  4178. if {mineplex.mode} is "sql":
  4179. set {_get} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '1'"
  4180. if {_get} is not set:
  4181. update "INSERT INTO `newslist` (`newsPosition`, `newsString`) VALUES ('1', '§b§lMineplex Core Remake')"
  4182. update "INSERT INTO `newslist` (`newsPosition`, `newsString`) VALUES ('2', '§a§lThe best remake for Mineplex Commands')"
  4183. update "INSERT INTO `newslist` (`newsPosition`, `newsString`) VALUES ('3', '§3§lRate this on Spigot!')"
  4184. update "INSERT INTO `newslist` (`newsPosition`, `newsString`) VALUES ('4', '§c§lCheck me out on SkUnity!')"
  4185. set {mineplex.news.line1} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '1'"
  4186. set {mineplex.news.line2} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '2'"
  4187. set {mineplex.news.line3} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '3'"
  4188. set {mineplex.news.line4} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '4'"
  4189. set {mineplex.news.allow} to true
  4190. else:
  4191. set {mineplex.news.line1} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '1'"
  4192. set {mineplex.news.line2} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '2'"
  4193. set {mineplex.news.line3} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '3'"
  4194. set {mineplex.news.line4} to first element out of objects in column "newsString" from result of query "SELECT newsString FROM `newslist` WHERE newsPosition = '4'"
  4195. else:
  4196. if {mineplex.news.line1} is not set:
  4197. set {mineplex.news.line1} to "§b§lMineplex Core Remake"
  4198. set {mineplex.news.line2} to "§a§lThe best remake for Mineplex Commands"
  4199. set {mineplex.news.line3} to "§3§lRate this on Spigot!"
  4200. set {mineplex.news.line4} to "§c§lCheck me out on SkUnity!"
  4201. set {mineplex.news.allow} to true
  4202.  
  4203. #NewsINIT
  4204. on load:
  4205. newsinit(1)
  4206.  
  4207. on quit:
  4208. set quit message to "&8Quit> &7%player%"
  4209. delete {mineplex.tp.back.%player%}
  4210.  
  4211. every second:
  4212. loop all players:
  4213. add 1 to {mineplex.time.%loop-player%}
  4214.  
  4215. #Forcefield
  4216.  
  4217. every 2 ticks:
  4218. loop all players:
  4219. if {mineplex.ff.list::%loop-player%} is set:
  4220. loop players in radius 4 of loop-player:
  4221. if {mineplex.pref.ff.%loop-player-2%} is false:
  4222. if loop-player-2 is not loop-player-1:
  4223. play raw sound "mob.chicken.plop" at loop-player-2 with pitch 1 volume 10
  4224. push the loop-player-2 upwards at speed 0.3
  4225. push the loop-player-2 backwards at speed 0.45
  4226. play raw sound "mob.chicken.plop" at loop-player-2 with pitch 1 volume 10
  4227.  
  4228. #2 Factor
  4229.  
  4230. command /2fareset <player>:
  4231. permission: op
  4232. trigger:
  4233. delete {mineplex.newauth.%uuid of arg-1%}
  4234. set {mineplex.authlock.%arg-1%} to false
  4235. delete {mineplex.newauthlast.%uuid of arg-1%}
  4236.  
  4237. on join:
  4238. wait 5 ticks
  4239. if player has permission "mineplex.2fa":
  4240. if {mineplex.newauth.%uuid of player%} is set:
  4241. set {_t} to difference between {mineplex.newauthlast.%uuid of player%} and now
  4242. set {_tc} to "1 day" parsed as a timespan
  4243. if {_t} is less than {_tc}:
  4244. send "&92FA> &7Authorized for 24 hours."
  4245. else:
  4246. set {mineplex.authlock.%player%} to true
  4247. apply slowness 999 to player for 999 seconds
  4248. apply blindness 999 to player for 999 seconds
  4249. send "&92FA> &7Please enter your two-factor auth code"
  4250. send "&92FA> &c/2fa (code)"
  4251. else:
  4252. stop
  4253.  
  4254. on command:
  4255. if {mineplex.authlock.%player%} is true:
  4256. if executor is player:
  4257. if command is not "2fa":
  4258. cancel event
  4259. send "&92FA> &7Please enter your two-factor auth code"
  4260. send "&92FA> &c/2fa (code)"
  4261.  
  4262. on chat:
  4263. if {mineplex.authlock.%player%} is true:
  4264. cancel event
  4265. send "&92FA> &7Please enter your two-factor auth code"
  4266. send "&92FA> &c/2fa (code)"
  4267.  
  4268. on quit:
  4269. delete {autowarn.%player%}
  4270.  
  4271. #Mineplex Commands
  4272. command /2fa [<string>] [<string>]:
  4273. permission: mineplex.2fa
  4274. permission message: &9Permissions> &7This requires Permission Rank [&9BUILDER&7].
  4275. trigger:
  4276. if {mineplex.newauth.%uuid of player%} is not set:
  4277. if {authwarn.%player%} is not set:
  4278. send "&92FA> &7Hey There! This sets a code that you will have to remember for the rest of your life!"
  4279. send "&92FA> &7Do &e/2fa &7if you are 100%% sure!"
  4280. set {authwarn.%player%} to true
  4281. stop
  4282. else:
  4283. send "&92FA> &7Generating secret..."
  4284. set {_clientSecret} to a new two-factor base-32 secret code
  4285. send "&92FA> &7Saving secret..."
  4286. set {mineplex.newauth.%uuid of player%} to {_clientSecret}
  4287. send "&92FA> &7Secret key saved."
  4288. send "&92FA> &7You must enter this code into your Two-Factor App:%nl%&92FA> &e%{_clientSecret}%"
  4289. send "&92FA> &7Then redo /2fa with your code"
  4290. set {mineplex.authlock.%player%} to false
  4291. set {_t} to arg 1 parsed as an integer
  4292. if {_t} is a number:
  4293. send "&92FA> &7Authorized for 24 hours."
  4294. send "&92FA> &7Saving secret..."
  4295. wait 5 ticks
  4296. set {mineplex.newauth.%uuid of player%} to hashed arg 1
  4297. set {mineplex.authlock.%player%} to false
  4298. send "&92FA> &7Secret key saved."
  4299. else:
  4300. send "&92FA> &7Invalid authentication code (not a number)."
  4301. else:
  4302. set {_t} to difference between {mineplex.newauthlast.%uuid of player%} and now
  4303. set {_tc} to "1 day" parsed as a timespan
  4304. if {_t} is less than {_tc}:
  4305. send "&92FA> &7Authorized for 24 hours."
  4306. else:
  4307. set {_c} to the current two-factor code of secret code {mineplex.newauth.%uuid of player%}
  4308. set {_t} to arg 1 parsed as an integer
  4309. if {_t} is a number:
  4310. if {_c} is arg-1:
  4311. send "&92FA> &7Authorized for 24 hours."
  4312. send "&92FA> &7Saving secret..."
  4313. wait 5 ticks
  4314. remove slowness from the player
  4315. remove blindness from the player
  4316. set {mineplex.newauthlast.%uuid of player%} to now
  4317. set {mineplex.authlock.%player%} to false
  4318. send "&92FA> &7Secret key saved."
  4319. else:
  4320. send "&92FA> &7Invalid authentication code"
  4321. else:
  4322. send "&92FA> &7Invalid authentication code (not a number)."
  4323.  
  4324. command /tp [<text>] [<text>] [<text>] [<text>] [<text>]:
  4325. aliases: /teleport
  4326. permission: mineplex.mod
  4327. permission message: &9Permissions> &7This requires Permission Rank [&9MOD&7].
  4328. trigger:
  4329. if arg-1 is not set:
  4330. send "&9Teleport> &7Commands List:"
  4331. send "&6/tp <target> &7Teleport to Player &6Mod"
  4332. send "&6/tp b(ack) &7Undo Teleports &6Mod"
  4333. send "&4/tp h(ere) <player> &7Teleport Player to Self &4Admin"
  4334. send "&4/tp <player> <target> &7Teleport Player to Player &4Admin"
  4335. send "&4/tp <player> <X> <Y> <Z> &7Teleport to Location &4Admin"
  4336. send "&4/tp all &7Teleport All to Self &4Owner"
  4337. else:
  4338. if arg-2 is not set:
  4339. if arg-1 is set:
  4340. if arg-1 is not "all":
  4341. if arg-1 is not "here" or "h" or "back" or "b":
  4342. if arg-1 parsed as player is online:
  4343. set {mineplex.tp.back.%player%} to location of player
  4344. teleport player to arg-1 parsed as player's location
  4345. set {_t} to arg-1 parsed as player
  4346. send "&9Teleport> &7Teleported to &e%{_t}%&7."
  4347. stop
  4348. else:
  4349. send "&9Teleport> &7Locating &e%arg-1%&7..."
  4350. wait 5 seconds
  4351. send "&9Teleport> &7Could not locate &e%arg-1%&7."
  4352. stop
  4353. if arg-1 is "all":
  4354. if player has permission "mineplex.owner":
  4355. teleport all players to player
  4356. send "&9Teleport> &7You teleported &e%amount of players% Players &7to yourself."
  4357. broadcast "&9Teleport> &7You teleported to &e%player%&7."
  4358. stop
  4359. else:
  4360. send "&9Permissions> &7This requires Permission Rank [&9OWNER&7]."
  4361. stop
  4362. if arg 4 is set:
  4363. if arg-1 parsed as player is online:
  4364. set {_p} to arg-1 parsed as a player
  4365. set {_x} to arg-2 parsed as a number
  4366. set {_y} to arg-3 parsed as a number
  4367. set {_z} to arg-4 parsed as a number
  4368. if {_x} is not set:
  4369. send "&9Teleport> &7Invalid X-Coordinate [&e%arg-2%&7]."
  4370. stop
  4371. if {_y} is not set:
  4372. send "&9Teleport> &7Invalid Y-Coordinate [&e%arg-3%&7]."
  4373. stop
  4374. if {_z} is not set:
  4375. send "&9Teleport> &7Invalid Z-Coordinate [&e%arg-4%&7]."
  4376. stop
  4377. teleport {_p} to the location at {_x}, {_y}, {_z}
  4378. send "&9Teleport> &7Teleported &e%{_p}% &7%{_x}%, %{_y}%, %{_z}%."
  4379. else:
  4380. send "&9Teleport> &7Locating &e%arg-1%&7..."
  4381. wait 5 seconds
  4382. send "&9Teleport> &7Could not locate &e%arg-1%&7."
  4383.  
  4384. if arg-1 is "here" or "h":
  4385. if player has permission "mineplex.admin":
  4386. if arg-3 is not set:
  4387. if arg-2 is set:
  4388. if arg-2 parsed as player is online:
  4389. teleport arg-2 parsed as player to player's location
  4390. send "&9Teleport> &7%player% teleported you to self." to arg-2 parsed as player
  4391. set {_t} to arg-2 parsed as player
  4392. send "&9Teleport> &7Teleported &e%arg-2% &7to self."
  4393. stop
  4394. else:
  4395. send "&9Teleport> &7Locating &e%arg-2%&7..."
  4396. wait 5 seconds
  4397. send "&9Teleport> &7Could not locate &e%arg-2%&7."
  4398. stop
  4399. else:
  4400. send "&9Permissions> &7This requires Permission Rank [&9ADMIN&7]."
  4401. stop
  4402. if arg-2 is not set:
  4403. send "&9Teleport> &7Commands List:"
  4404. send "&6/tp <target> &7Teleport to Player &6Mod"
  4405. send "&6/tp b(ack) &7Undo Teleports &6Mod"
  4406. send "&4/tp h(ere) <player> &7Teleport Player to Self &4Admin"
  4407. send "&4/tp <player> <target> &7Teleport Player to Player &4Admin"
  4408. send "&4/tp <player> <X> <Y> <Z> &7Teleport to Location &4Admin"
  4409. send "&4/tp all &7Teleport All to Self &4Owner"
  4410. if arg-1 is "back" or "b":
  4411. if {mineplex.tp.back.%player%} is set:
  4412. set {_new} to {mineplex.tp.back.%player%}
  4413. set {mineplex.tp.back.%player%} to location of player
  4414. teleport player to {_new}
  4415. send "&9Teleport> &7You have been teleported to your previous location."
  4416. else:
  4417. send "&9Teleport> &7There is no place to teleport you back to."
  4418. stop
  4419. if arg-3 is not set:
  4420. if arg-2 is set:
  4421. if player has permission "mineplex.admin":
  4422. if arg-2 parsed as player is online:
  4423. if arg-1 parsed as player is online:
  4424. set {mineplex.tp.back.%player%} to location of player
  4425. teleport arg-1 parsed as player to arg-2 parsed as player
  4426. set {_t1} to arg-1 parsed as player
  4427. set {_t} to arg-2 parsed as player
  4428. send "&9Teleport> &e%{_t1}% &7was teleported to you." to arg-2 parsed as player
  4429. send "&9Teleport> &7You were teleported to &e%{_t}%&7." to arg-1 parsed as player
  4430. stop
  4431. else:
  4432. send "&9Teleport> &7Locating &e%arg-1%&7..."
  4433. wait 5 seconds
  4434. send "&9Teleport> &7Could not locate &e%arg-1%&7."
  4435. stop
  4436. else:
  4437. send "&9Teleport> &7Locating &e%arg-2%&7..."
  4438. wait 5 seconds
  4439. send "&9Teleport> &7Could not locate &e%arg-2%&7."
  4440. stop
  4441. else:
  4442. send "&9Permissions> &7This requires Permission Rank [&9ADMIN&7]."
  4443. stop
  4444.  
  4445. command /time [<offline player>] [<string>]:
  4446. permission: mineplex.mod
  4447. permission message: &9Permissions> &7This requires Permission Rank [&9MOD&7].
  4448. trigger:
  4449. if arg 1 is not set:
  4450. send "&9Time> &7Usage: /time <playerName>"
  4451. else:
  4452. if {mineplex.time.%arg-1%} is not set:
  4453. set {mineplex.time.%arg-1%} to 0
  4454. send "&9Time> &e%arg-1% &7has spent &e%{mineplex.time.%arg-1%}%.0 Seconds &7in game"
  4455. else:
  4456. set {_tm} to {mineplex.time.%arg-1%}
  4457. if {_tm} is less than 60:
  4458. send "&9Time> &e%arg-1% &7has spent &e%{_tm}%.0 Seconds &7in game"
  4459. stop
  4460. else if {_tm} is less than 3600:
  4461. set {_final} to {_tm} / 60
  4462. send "&9Time> &e%arg-1% &7has spent &e%{_final}% Minutes &7in game"
  4463. stop
  4464. else if {_tm} is less than 86400:
  4465. set {_final} to {_tm} / 3600
  4466. send "&9Time> &e%arg-1% &7has spent &e%{_final}% Hours &7in game"
  4467. stop
  4468. else if {_tm} is less than 604800:
  4469. set {_final} to {_tm} / 86400
  4470. send "&9Time> &e%arg-1% &7has spent &e%{_final}% Days &7in game"
  4471. stop
  4472. else:
  4473. set {_final} to {_tm} / 604800
  4474. send "&9Time> &e%arg-1% &7has spent &e%{_final}% Weeks &7in game"
  4475.  
  4476. command /disguise [<string>] [<string>]:
  4477. permission: mineplex.youtube
  4478. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  4479. trigger:
  4480. if arg 1 is not set:
  4481. if {mineplex.disguise.%player%} is set:
  4482. send "&9Disguise> &7You are no longer disguised!"
  4483. execute console command "/ud %player%"
  4484. delete {mineplex.disguise.%player%}
  4485. set player tab name to "%{mineplex.rank.%player%}%&e%player%"
  4486. updateRankAPI(player)
  4487. else:
  4488. send "&9Disguise> &7Command List:%nl%&4/disguise <player> &7Makes you appear as target player in chat and tab &4Admin"
  4489. else:
  4490. if {mineplex.disguise.%player%} is set:
  4491. send "&9Disguise> &7You are already disguised. Please undisguise by using /disguise"
  4492. else:
  4493. set {_n} to the length of arg 1
  4494. if {_n} is greater than 16:
  4495. send "&9Disguise> &7That disguise name is not permitted!"
  4496. stop
  4497. if arg-1 contains "~" or "`" or "!" or "@" or "##" or "$" or "%%" or "^" or "&" or "*" or "(" or ")" or "-" or "=" or "+" or "[" or "]" or "{" or "}" or ":" or ";" or "," or "<" or ">" or "." or "?" or "/" or "\":
  4498. send "&9Disguise> &7That disguise name is not permitted!"
  4499. stop
  4500. set {_p1} to "%arg-1%" parsed as offline player
  4501. if {_p1} is online:
  4502. send "&9Disguise> &7this name already in use!"
  4503. stop
  4504. set {_ban} to getPlayerdata({_p1}, "banned")
  4505. set {_mute} to getPlayerdata({_p1}, "muted")
  4506. if {_ban} or {_muted} is "yes":
  4507. send "&9Disguise> &7You may not disguise as people who are muted or banned."
  4508. stop
  4509. set {_rank} to getPlayerdata({_p1}, "rank")
  4510. if {_rank} is not "All" or "Ultra" or "Hero" or "Legend" or "Titan" or "Eternal":
  4511. send "&9Disguise> &7You may not disguise as users who are staff, youtubers, or twitchers."
  4512. stop
  4513. send "&9Disguise> &7Disguise Active: &f%arg-1%"
  4514. set {_localp} to arg 1 parsed as a player
  4515. rankLoad({_localp} , 2, 1)
  4516. if {mineplex.level.%arg-1%} is not set:
  4517. set {mineplex.level.%arg-1%} to "&70"
  4518. if {mineplex.rank.%arg-1%} is not set:
  4519. set {mineplex.rank.%arg-1%} to ""
  4520. execute console command "/odisguise %player% player %arg-1%"
  4521. set {mineplex.disguise.%player%} to "%arg-1%" parsed as offline player
  4522. set {_player} to arg 1
  4523. if {mineplex.rank.%{_player}%} is not set:
  4524. set {mineplex.rank.%{_player}%} to ""
  4525. set player tab name to "%{mineplex.rank.%{_player}%}%&e%arg-1%"
  4526. updateRankAPI(player)
  4527.  
  4528. command /api [<string>] [<string>] [<string>]:
  4529. trigger:
  4530. if arg 1 is not set:
  4531. send "&9API> &7Mineplex Core API"
  4532. send "&9API> &7/api (api name)"
  4533. send "&9API> &7Current API's; &adisplayrank&7, &adisplayname"
  4534. send "&9API> &7Use /api (api name) (player) to view a different players's api output"
  4535. else:
  4536. if arg 2 is set:
  4537. set {_p} to "%arg-2%"
  4538. else:
  4539. set {_p} to "%player%"
  4540. if arg 1 is "displayrank":
  4541. if {mineplex.api.displayrank.%{_p}%} is not set:
  4542. set {mineplex.api.displayrank.%{_p}%} to "null"
  4543. send "&9API> &7Raw API Output; &f%{mineplex.api.displayrank.%{_p}%}%"
  4544. else if arg 1 is "displayname":
  4545. if {mineplex.api.displayname.%{_p}%} is not set:
  4546. set {mineplex.api.displayname.%{_p}%} to "null"
  4547. send "&9API> &7Raw API Output; &f%{mineplex.api.displayname.%{_p}%}%"
  4548. else:
  4549. send "&9API> &7Invalid API!"
  4550.  
  4551. command /give [<string>] [<string>] [<string>] [<string>] [<string>]:
  4552. aliases: /g, /item, /i
  4553. permission: mineplex.admin
  4554. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  4555. trigger:
  4556. if arg 1 is not set:
  4557. send "&9Give: &7Listing Commands:"
  4558. send "&4/give (item) Admin"
  4559. send "&4/give (player) (item) (amount) Admin"
  4560. send "&4/give (player) (item) (amount) (Enchantment:level) Admin"
  4561. send "&4/give all (item) (amount) Admin"
  4562. send "&4/give all (item) (amount) (Enchantment:level) Admin"
  4563. else:
  4564. if arg 2 is not set:
  4565. set {_i1} to "%arg-1%"
  4566. replace all "_" with " " in {_i1}
  4567. set {_i} to "%{_i1}%" parsed as an item
  4568. if {_i} is an item:
  4569. send "&9Give> &7You gave &e1 %{_i}% &7to &e%player%&7."
  4570. give player {_i}
  4571. else:
  4572. send "&9Item Search> &e0 &7matches for [&e%arg-1%&7]."
  4573. send "&9Item(s) Search> &7Invalid [&e%arg-1%&7]."
  4574. if arg 2 is set:
  4575. if arg 3 is set:
  4576. if arg 1 is "all":
  4577. set {_i1} to "%arg-2%"
  4578. replace all "_" with " " in {_i1}
  4579. set {_i} to "%{_i1}%" parsed as an item
  4580. set {_a} to "%arg-3%" parsed as a number
  4581. if {_i} is an item:
  4582. if {_a} is a number:
  4583. send "&9Give> &7You gave &e%{_a}% %{_i}% &7to &eALL&7."
  4584. send "&9Give> &7You received &e%{_a}% %{_i}% &7from &e%player%&7." to all players
  4585. loop all players:
  4586. loop {_a} times:
  4587. give loop-player {_i}
  4588. else:
  4589. send "&9Give> &7Invalid Amount [%arg-3%]. Defaulting to [1]."
  4590. send "&9Give> &7You gave &e1 %{_i}% &7to &eALL&7."
  4591. send "&9Give> &7You received &e1 %{_i}% &7from &e%player%&7." to all players
  4592. loop all players:
  4593. give loop-player {_i}
  4594. else:
  4595. send "&9Item Search> &e0 &7matches for [&e%{_i1}%&7]."
  4596. send "&9Item(s) Search> &7Invalid [&e%{_i}%&7]."
  4597. else:
  4598. set {_i1} to "%arg-2%"
  4599. replace all "_" with " " in {_i1}
  4600. set {_i} to "%{_i1}%" parsed as an item
  4601. set {_a} to "%arg-3%" parsed as a number
  4602. set {_p} to "%arg-1%" parsed as a player
  4603. if {_i} is an item:
  4604. if {_p} is online:
  4605. if {_a} is a number:
  4606. send "&9Give> &7You gave &e%{_a}% %{_i}% &7to &e%{_p}%&7."
  4607. send "&9Give> &7You received &e%{_a}% %{_i}% &7from &e%player%&7." to {_p}
  4608. loop {_a} times:
  4609. give {_p} {_i}
  4610. else:
  4611. send "&9Give> &7Invalid Amount [%arg-3%]. Defaulting to [1]."
  4612. send "&9Give> &7You gave &e1 %{_i}% &7to &e%{_p}%&7."
  4613. send "&9Give> &7You received &e1 %{_i}% &7from &e%player%&7." to {_p}
  4614. give {_p} {_i}
  4615. else:
  4616. send "&9Online Player Search> &e0 &7matches for [&e%arg-1%&7]."
  4617. send "&9Online Player(s) Search> &7Invalid [&e%arg-1%&7]."
  4618. stop
  4619. else:
  4620. send "&9Item Search> &e0 &7matches for [&e%arg-2%&7]."
  4621. send "&9Item(s) Search> &7Invalid [&e%arg-2%&7]."
  4622. else:
  4623. if arg 1 is "all":
  4624. set {_i1} to "%arg-2%"
  4625. replace all "_" with " " in {_i1}
  4626. set {_i} to "%{_i1}%" parsed as an item
  4627. if {_i} is an item:
  4628. send "&9Give> &7You gave &e1 %{_i}% &7to &eALL&7."
  4629. send "&9Give> &7You received &e1 %{_i}% &7from &e%player%&7." to all players
  4630. loop all players:
  4631. give loop-player {_i}
  4632. else:
  4633. send "&9Item Search> &e0 &7matches for [&e%arg-2%&7]."
  4634. send "&9Item(s) Search> &7Invalid [&e%arg-2%&7]."
  4635. else:
  4636. set {_i1} to "%arg-2%"
  4637. replace all "_" with " " in {_i1}
  4638. set {_i} to "%{_i1}%" parsed as an item
  4639. set {_p} to "%arg-1%" parsed as a player
  4640. if {_i} is an item:
  4641. if {_p} is online:
  4642. send "&9Give> &7You gave &e1 %{_i}% &7to &e%{_p}%&7."
  4643. send "&9Give> &7You received &e1 %{_i}% &7from &e%player%&7." to {_p}
  4644. give {_p} {_i}
  4645. else:
  4646. send "&9Online Player Search> &e0 &7matches for [&e%arg-1%&7]."
  4647. send "&9Online Player(s) Search> &7Invalid [&e%arg-1%&7]."
  4648. stop
  4649. else:
  4650. send "&9Item Search> &e0 &7matches for [&e%arg-2%&7]."
  4651. send "&9Item(s) Search> &7Invalid [&e%arg-2%&7]."
  4652.  
  4653. #/givestat player stat amount
  4654. command /givestat [<offline player>] [<string>] [<string>] [<string>]:
  4655. permission: mineplex.admin
  4656. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  4657. trigger:
  4658. if arg 1 is not set:
  4659. send "&9Stats> &e/givestat (player) (stat) (amount)"
  4660. else if arg 1 is set:
  4661. if arg 2 is set:
  4662. if arg 3 parsed as a number is set:
  4663. if arg 2 is "Global.ExpEarned":
  4664. set {_lvl} to arg 3 parsed as a number
  4665. if {_lvl} is less than 0:
  4666. send "&9Stats> &7Unknown value for &eGlobal.ExpEarned&7!"
  4667. stop
  4668. else if {_lvl} is less than 20:
  4669. set {_temp} to "&7%{_lvl}%"
  4670. set {mineplex.level.%arg-1%} to "%{_temp}%"
  4671. send "&9Stats> &7Applied &e%{_lvl}% Global.ExpEarned &7to &e%arg-1%&7."
  4672. setPlayerdata(arg-1, "level", "%{_lvl}%")
  4673. stop
  4674. else if {_lvl} is less than 40:
  4675. set {_temp} to "&9%{_lvl}%"
  4676. set {mineplex.level.%arg-1%} to "%{_temp}%"
  4677. send "&9Stats> &7Applied &e%{_lvl}% Global.ExpEarned &7to &e%arg-1%&7."
  4678. setPlayerdata(arg-1, "level", "%{_lvl}%")
  4679. stop
  4680. else if {_lvl} is less than 60:
  4681. set {_temp} to "&2%{_lvl}%"
  4682. set {mineplex.level.%arg-1%} to "%{_temp}%"
  4683. send "&9Stats> &7Applied &e%{_lvl}% Global.ExpEarned &7to &e%arg-1%&7."
  4684. setPlayerdata(arg-1, "level", "%{_lvl}%")
  4685. stop
  4686. else if {_lvl} is less than 80:
  4687. set {_temp} to "&6%{_lvl}%"
  4688. set {mineplex.level.%arg-1%} to "%{_temp}%"
  4689. send "&9Stats> &7Applied &e%{_lvl}% Global.ExpEarned &7to &e%arg-1%&7."
  4690. setPlayerdata(arg-1, "level", "%{_lvl}%")
  4691. stop
  4692. else if {_lvl} is less than or equal to 100:
  4693. set {_temp} to "&c%{_lvl}%"
  4694. set {mineplex.level.%arg-1%} to "%{_temp}%"
  4695. send "&9Stats> &7Applied &e%{_lvl}% Global.ExpEarned &7to &e%arg-1%&7."
  4696. setPlayerdata(arg-1, "level", "%{_lvl}%")
  4697. stop
  4698. else if arg 2 is "Global.GemsEarned":
  4699. set {_num} to arg 3 parsed as a number
  4700. set {_get} to getPlayerdata(arg-1, "stats.global.gems")
  4701. set {_cur} to {_get} parsed as a number
  4702. add {_num} to {_cur}
  4703. setPlayerdata(arg-1, "stats.global.gems", "%{_cur}%")
  4704. send "&9Stats> &7Applied &e%{_num}% Global.GemsEarned &7to &e%arg-1%&7."
  4705. else if arg 2 is "Global.GamesPlayed":
  4706. set {_num} to arg 3 parsed as a number
  4707. set {_get} to getPlayerdata(arg-1, "stats.global.games")
  4708. set {_cur} to {_get} parsed as a number
  4709. add {_num} to {_cur}
  4710. setPlayerdata(arg-1, "stats.global.games", "%{_cur}%")
  4711. send "&9Stats> &7Applied &e%{_num}% Global.GamesPlayed &7to &e%arg-1%&7."
  4712. else if arg 2 is "Global.DailyRewards":
  4713. set {_num} to arg 3 parsed as a number
  4714. set {_get} to getPlayerdata(arg-1, "stats.global.dailyr")
  4715. set {_cur} to {_get} parsed as a number
  4716. add {_num} to {_cur}
  4717. setPlayerdata(arg-1, "stats.global.dailyr", "%{_cur}%")
  4718. send "&9Stats> &7Applied &e%{_num}% Global.DailyRewards &7to &e%arg-1%&7."
  4719. else if arg 2 is "Global.TimesVoted":
  4720. set {_num} to arg 3 parsed as a number
  4721. set {_get} to getPlayerdata(arg-1, "stats.global.voted")
  4722. set {_cur} to {_get} parsed as a number
  4723. add {_num} to {_cur}
  4724. setPlayerdata(arg-1, "stats.global.voted", "%{_cur}%")
  4725. send "&9Stats> &7Applied &e%{_num}% Global.TimesVoted &7to &e%arg-1%&7."
  4726. else if arg 2 is "Global.ChestsOpened":
  4727. set {_num} to arg 3 parsed as a number
  4728. set {_get} to getPlayerdata(arg-1, "stats.global.chests")
  4729. set {_cur} to {_get} parsed as a number
  4730. add {_num} to {_cur}
  4731. setPlayerdata(arg-1, "stats.global.chests", "%{_cur}%")
  4732. send "&9Stats> &7Applied &e%{_num}% Global.ChestsOpened &7to &e%arg-1%&7."
  4733. else:
  4734. send "&9Stats> &e/givestat (player) (stat) (amount)"
  4735. else:
  4736. send "&9Stats> &e/givestat (player) (stat) (amount)"
  4737. else:
  4738. send "&9Stats> &e/givestat (player) (stat) (amount)"
  4739.  
  4740. command /stats [<offline player>] [<string>]:
  4741. trigger:
  4742. if arg 1 is not set:
  4743. set {_p} to player
  4744. set {_good} to true
  4745. else:
  4746. if arg 1 is online:
  4747. set {_p} to arg 1
  4748. set {_good} to true
  4749. else:
  4750. send "&9Online Player Search> &e0 &7matches for [&e%arg-1%&7]."
  4751. if {_good} is true:
  4752. open chest with 5 rows named "%{_p}%'s Stats" to player
  4753. wait 1 tick
  4754. set {_tm} to {mineplex.time.%{_p}%}
  4755. if {_tm} is less than 60:
  4756. set {_global.time} to "%{_final}%.0 Seconds"
  4757. else if {_tm} is less than 3600:
  4758. set {_final} to {_tm} / 60
  4759. set {_global.time} to "%{_final}% Minutes"
  4760. else if {_tm} is less than 86400:
  4761. set {_final} to {_tm} / 3600
  4762. set {_global.time} to "%{_final}% Hours"
  4763. else if {_tm} is less than 604800:
  4764. set {_final} to {_tm} / 86400
  4765. set {_global.time} to "%{_final}% Days"
  4766. else:
  4767. set {_final} to {_tm} / 604800
  4768. set {_global.time} to "%{_final}% Weeks"
  4769. set {_global.gems} to getPlayerdata({_p}, "stats.global.gems")
  4770. set {_global.games} to getPlayerdata({_p}, "stats.global.games")
  4771. set {_global.dailyr} to getPlayerdata({_p}, "stats.global.dailyr")
  4772. set {_global.voted} to getPlayerdata({_p}, "stats.global.voted")
  4773. set {_global.chests} to getPlayerdata({_p}, "stats.global.chests")
  4774. format slot 2 of player with emerald named "&a&lGlobal" with lore "||&eGems Earned: &f%{_global.gems}%|| ||&eGames Played: &f%{_global.games}%||&eTime In Game: &f%{_global.time}%|| ||&eDaily Rewards: &f%{_global.dailyr}%||&eTimes Voted: &f%{_global.voted}%|| ||&eChests Opened: &f%{_global.chests}%" to be unstealable
  4775.  
  4776. command /mcr:
  4777. trigger:
  4778. send "&9Plugin> &7Mineplex Core"
  4779. send "&9Plugin> &7Running MCR: &e{@MCRVER}"
  4780. send "&9Plugin> &7Hotfix/Release Cycle: &e{@MCRHOTFIX}"
  4781. send "&9Plugin> &7by &aWheezyGold7931&7, &eTheSkripterDK&7, &eTorksi&7, &eY7S&7, &eOttelino, &7and &eItzRenderman"
  4782. send "&9Plugin> &7Special thanks to TonyMaster21, LimeGlass, Rezz, Citrin_, Boobah, and SomethingPlayzMC"
  4783. send "&9Plugin> &7Also, special thanks to our moderation team."
  4784. send ""
  4785. send "&9Patreon> &7Huge Thanks to my Patreons:"
  4786. send "&9Patreon> &eCitrin_"
  4787. send "&9Patreon> &eRealTME01"
  4788. send "&9Patreon> &etermanator1128"
  4789. send "&9Patreon> &eTreyRuffy"
  4790. send "&9Patreon> &exLengoBug5"
  4791. send "&9Patreon> &7If you want to be listed there than support me on Patreon!:"
  4792. send "&9Patreon> &bhttps://www.patreon.com/WheezyGold7931"
  4793.  
  4794. command /a [<text>]:
  4795. aliases: /admin
  4796. trigger:
  4797. if arg 1 is not set:
  4798. send "&9Admin> &7Corect Usage: /a (message)"
  4799. stop
  4800. if {mineplex.disguise.%player%} is set:
  4801. send "&9Admin> &7Disguised users cannot use /a while disguised!"
  4802. stop
  4803. else:
  4804. set {_p} to player
  4805. set {_get} to getPlayerdata(player, "muted")
  4806. if {_get} is "yes":
  4807. if {muted::%player%::type} is "perm":
  4808. send "&9Punish> &7Shh, you're muted because %{muted::%player%::reason}% by %{muted::%player%::by}% for Permanent."
  4809. stop
  4810. if {muted::%player%::type} is "temp":
  4811. set {_waited} to difference between {muted::%player%::when} and now
  4812. if {_waited} is less than {muted::%player%::time}:
  4813. send "&9Punish> &7Shh, you're muted because %{muted::%player%::reason}% by %{muted::%player%::by}% for &a%{muted::%player%::time}%."
  4814. stop
  4815. if {mineplex.rank.%{_p}%} is "":
  4816. set {_display} to "Player %{_p}%"
  4817. else:
  4818. set {_display} to "%{mineplex.displaya.%{_p}%}% %{_p}%"
  4819. if player has permission "mineplex.trainee":
  4820. loop all players:
  4821. if loop-player has permission "mineplex.trainee":
  4822. send "%{_display}% &d%arg-1%" to loop-player
  4823. play "NOTE_PLING" to loop-player at volume 0.5
  4824. else:
  4825. send "%{_display}% &d%arg-1%"
  4826. play "NOTE_PLING" to player at volume 0.5
  4827. loop all players:
  4828. if loop-player has permission "mineplex.trainee":
  4829. send "%{_display}% &d%arg-1%" to loop-player
  4830. play "NOTE_PLING" to loop-player at volume 0.5
  4831.  
  4832. command /ma [<player>] [<text>]:
  4833. trigger:
  4834. if {mineplex.disguise.%player%} is set:
  4835. send "&9Admin> &7Disguised users cannot use /a while disguised!"
  4836. stop
  4837. else:
  4838. set {_p} to player
  4839. if {mineplex.rank.%{_p}%} is "":
  4840. set {_display} to "&fPlayer %{_p}%"
  4841. else:
  4842. set {_display} to "%{mineplex.displaya.%{_p}%}% %{_p}%"
  4843. if {mineplex.rank.%arg-1%} is "":
  4844. set {_display2} to "&fPlayer %arg-1%"
  4845. else:
  4846. set {_display2} to "%{mineplex.displaya.%arg-1%}% %arg-1%"
  4847. if player has permission "mineplex.trainee":
  4848. if argument 1 and argument 2 is set:
  4849. send "&d-> %{_display2}% &d%arg 2%"
  4850. send "&d<- %{_display}% &d%arg 2%" to arg-1
  4851. set {mineplex.lasta.%player%} to arg-1
  4852. play "NOTE_PLING" to player at volume 0.5
  4853. play "NOTE_PLING" to arg-1 at volume 0.5
  4854. loop all players:
  4855. if loop-player has permission "mineplex.trainee":
  4856. if loop-player is not player or arg-1:
  4857. send "%{_display}% &d-> %{_display2}% &d%arg 2%" to loop-player
  4858. else:
  4859. send "&9Message> &cErr...something went wrong?"
  4860. else:
  4861. send "&9Permissions> &7This requires Permission Rank [&9TRAINEE&7]."
  4862.  
  4863. command /ra [<text>]:
  4864. permission: mineplex.trainee
  4865. permission message: &9Permissions> &7This requires Permission Rank [&9TRAINEE&7].
  4866. trigger:
  4867. if {mineplex.disguise.%player%} is set:
  4868. set {_p} to {mineplex.disguise.%player%}
  4869. else:
  4870. set {_p} to player
  4871. if {mineplex.rank.%{_p}%} is "":
  4872. set {_display} to "&fPlayer %{_p}%"
  4873. else:
  4874. set {_display} to "%{mineplex.displaya.%{_p}%}% %{_p}%"
  4875. if {mineplex.rank.%{mineplex.lasta.%player%}%} is "":
  4876. set {_display2} to "&fPlayer %{mineplex.lasta.%player%}%"
  4877. else:
  4878. set {_display2} to "%{mineplex.displaya.%{mineplex.lasta.%player%}%}% %{mineplex.lasta.%player%}%"
  4879. if {mineplex.lasta.%player%} is not set:
  4880. send "&9Message> &7You have not messaged anyone recently."
  4881. stop
  4882. else:
  4883. if argument 1 is set:
  4884. send "&d-> %{_display2}% &d%arg 1%"
  4885. send "&d<- %{_display}% &d%arg-1%" to {mineplex.lasta.%player%}
  4886. play "NOTE_PLING" to player at volume 0.5
  4887. play "NOTE_PLING" to {mineplex.lasta.%player%} at volume 0.5
  4888. loop all players:
  4889. if loop-player has permission "mineplex.trainee":
  4890. if loop-player is not player or {mineplex.lasta.%player%}:
  4891. send "%{_display}% &d-> %{_display2}% &d%arg 1%" to loop-player
  4892. else:
  4893. send "&9Message> &cErr...something went wrong?"
  4894.  
  4895. command /vanish:
  4896. aliases: /incognito
  4897. permission: mineplex.trainee
  4898. permission message: &9Permissions> &7This requires Permission Rank [&9TRAINEE&7].
  4899. trigger:
  4900. if {mineplex.vanish.%player%} is true:
  4901. loop all players:
  4902. loop-value doesn't have permission "mineplex.admin"
  4903. add loop-value to {_vanishto::*}
  4904.  
  4905. reveal player from all players
  4906. set {mineplex.vanish.%player%} to false
  4907. send "&9Moderation> &7Disabled moderator mode."
  4908. send "&9Incognito> &7You are no longer incognito. Your status will only change when you run &e/vanish &7again."
  4909. else:
  4910. loop all players:
  4911. loop-value doesn't have permission "mineplex.admin"
  4912. add loop-value to {_vanishto::*}
  4913.  
  4914. hide player from {_vanishto::*}
  4915. set {mineplex.vanish.%player%} to true
  4916. send "&9Moderation> &7Enabled moderator mode."
  4917. send "&9Incognito> &7You are now incognito. Your status will only change when you run &e/vanish &7again."
  4918.  
  4919. function friendButtons(p: player) :: number:
  4920. set {_t} to "Steve" parsed as an offline player
  4921. set slot 0 of {_p}'s current inventory to {_t}'s skull named "&fFriends" with lore ""
  4922. set slot 2 of {_p}'s current inventory to rose named "&fFriend Requests" with lore ""
  4923. set slot 4 of {_p}'s current inventory to tnt named "&fDelete Friends" with lore ""
  4924. set slot 6 of {_p}'s current inventory to book and quill named "&fSend Friend Request" with lore ""
  4925. set slot 8 of {_p}'s current inventory to sign item named "&7Toggle friends to display in chat" with lore ""
  4926.  
  4927. function friendClean(p: player) :: number:
  4928. set {_s} to 18
  4929. loop 27 times:
  4930. set slot {_s} of {_p}'s current inventory to air
  4931. add 1 to {_s}
  4932. if {_s} = 44:
  4933. exit loop
  4934. friendButtons({_p})
  4935.  
  4936. function friendMain(p: player) :: number:
  4937. open chest with 6 rows named "Friends" to {_p}
  4938. friendClean({_p})
  4939. set {_s} to 18
  4940. loop {friends.list.%{_p}%::*}:
  4941. set {_t} to "%loop-value%" parsed as offline player
  4942. if {_t} is online:
  4943. set {_a} to "&2Online"
  4944. set {_w} to "&e%{_t}'s world%"
  4945. set slot {_s} of {_p}'s current inventory to {_t}'s skull named "&f&l%{_t}%" with lore "&7&lStatus: %{_a}%||&7&lServer: %{_w}%|| ||&7Left click to teleport to their server"
  4946. else:
  4947. set {_a} to "&cOffline"
  4948. set slot {_s} of {_p}'s current inventory to {_t}'s skull named "&f&l%{_t}%" with lore "&7&lStatus: %{_a}%||&7Last seen N/A Days ago"
  4949. add 1 to {_s}
  4950. if {_s} = 44:
  4951. exit loop
  4952.  
  4953. function friendDel(p: player) :: number:
  4954. open chest with 6 rows named "Delete Friends" to {_p}
  4955. friendClean({_p})
  4956. set {_s} to 18
  4957. loop {friends.list.%{_p}%::*}:
  4958. set {_t} to "%loop-value%" parsed as offline player
  4959. if {_t} is online:
  4960. set {_a} to "&2Online"
  4961. set {_w} to "&e%{_t}'s world%"
  4962. set slot {_s} of {_p}'s current inventory to {_t}'s skull named "&f&l%{_t}%" with lore "&7&lStatus: %{_a}%||&7&lServer: %{_w}%|| ||&7Left click to teleport to their server"
  4963. else:
  4964. set {_a} to "&cOffline"
  4965. set slot {_s} of {_p}'s current inventory to {_t}'s skull named "&f&l%{_t}%" with lore "&7&lStatus: %{_a}%||&7Last seen N/A Days ago"
  4966. add 1 to {_s}
  4967. if {_s} = 44:
  4968. exit loop
  4969.  
  4970. function friendReq(p: player) :: number:
  4971. open chest with 6 rows named "Friend Requests" to {_p}
  4972. friendClean({_p})
  4973. set {_s} to 18
  4974. loop {friends.request.%{_p}%::*}:
  4975. set {_t} to "%loop-value%" parsed as offline player
  4976. set slot {_s} of {_p}'s current inventory to paper named "&7Friend request from &f&l%{_t}%" with lore "||&7Left click to accept friend request"
  4977. add 1 to {_s}
  4978. if {_s} = 44:
  4979. exit loop
  4980.  
  4981. command /friend [<string>] [<string>]:
  4982. aliases: /f
  4983. trigger:
  4984. if arg 1 is not set:
  4985. friendMain(player)
  4986. else:
  4987. if arg 1 is "%player%":
  4988. send "&9Friends> &7You cannot friend yourself!"
  4989. stop
  4990. stop
  4991. loop {friends.list.%arg-1%::*}:
  4992. if loop-value is "%player%":
  4993. set {_f} to true
  4994. loop {friends.request.%arg-1%::*}:
  4995. if loop-value is "%player%":
  4996. set {_a} to true
  4997. if {_a} is true:
  4998. send "&9Friends> &a%arg-1% &7has yet to respond to your friend request."
  4999. else if {_f} is true:
  5000. send "&9Friends> &7You are already friends with &a%arg-1%"
  5001. else:
  5002. add "%player%" to {friends.request.%arg-1%::*}
  5003. send "&9Friends> &7Added &a%arg-1% &7to your friends list!"
  5004.  
  5005. on inventory click:
  5006. if inventory name of player's current inventory is "Friends":
  5007. if clicked slot is 2:
  5008. friendReq(player)
  5009. if clicked slot is 4:
  5010. friendDel(player)
  5011. cancel event
  5012. if inventory name of player's current inventory is "Friend Requests":
  5013. if clicked slot is 0:
  5014. friendMain(player)
  5015. if clicked slot is 4:
  5016. friendDel(player)
  5017. else:
  5018. set {_n} to name of clicked item
  5019. if {_n} contains "&7Friend request from ":
  5020. replace all "&7Friend request from " with "" in {_n}
  5021. set {_f} to uncolored {_n}
  5022. remove {_f} from {friends.request.%player%::*}
  5023. add {_f} to {friends.list.%player%::*}
  5024. add "%player%" to {friends.list.%{_f}%::*}
  5025. send "&9Friends> &aYou &7and &a%{_f}% &7are now friends!"
  5026. friendReq(player)
  5027. cancel event
  5028. if inventory name of player's current inventory is "Delete Friends":
  5029. if clicked slot is 0:
  5030. friendMain(player)
  5031. if clicked slot is 2:
  5032. friendReq(player)
  5033. else:
  5034. if "%clicked item%" is "player head":
  5035. if clicked slot is not 0:
  5036. set {_n} to name of clicked item
  5037. set {_f} to uncolored {_n}
  5038. replace all " " with "" in {_f}
  5039. remove {_f} from {friends.list.%player%::*}
  5040. remove {_f} from {friends.list.%{_l}%::*}
  5041. send "&9Friends> &7Deleted &a%{_f}% &7from your friends list!"
  5042. friendDel(player)
  5043. cancel event
  5044.  
  5045. command /chatslow [<integer>]:
  5046. aliases: /cs
  5047. permission: mineplex.srmod
  5048. permission message: &9Permissions> &7This requires Permission Rank [&9SR.MOD&7].
  5049. trigger:
  5050. if {mineplex.disguise.%player%} is set:
  5051. set {_p} to {mineplex.disguise.%player%}
  5052. else:
  5053. set {_p} to player
  5054. if argument 1 is set:
  5055. if {mineplex.chatsilence} is set:
  5056. send "&9Chat> &7Chat is in silence mode. Disable silence mode to activate slow chat."
  5057. stop
  5058. else:
  5059. if {mineplex.chatslow} is not set:
  5060. set {mineplex.chatslow} to "%arg-2% seconds" parsed as timespan
  5061. send "&9Chat> &6%{_p}% &7has set the chat delay to &6%arg-1%&7 seconds." to all players
  5062. else:
  5063. set {mineplex.chatslow} to "%arg-2% seconds" parsed as timespan
  5064. send "&9Chat> &6%{_p}% &7has enabled chat slow." to all players
  5065. send "&9Chat> &6%{_p}% &7has set the chat delay to &6%arg-1%&7 seconds." to all players
  5066. else:
  5067. if {mineplex.chatsilence} is set:
  5068. send "&9Chat> &7Chat is in silence mode. Disable silence mode to activate slow chat."
  5069. stop
  5070. else:
  5071. if {mineplex.chatslow} is set:
  5072. delete {mineplex.chatslow}
  5073. send "&9Chat> &6%{_p}% &7has disabled chat slow." to all players
  5074. else:
  5075. send "&9Message> &cYou didn't enter a time limit! Defaulting to 10 seconds."
  5076. set {mineplex.chatslow} to "10 seconds" parsed as timespan
  5077. send "&9Chat> &6%{_p}% &7has enabled chat slow." to all players
  5078. send "&9Chat> &6%{_p}% &7has set the chat delay to &610 &7seconds." to all players
  5079. command /silence:
  5080. permission: mineplex.admin
  5081. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  5082. trigger:
  5083. if {mineplex.chatslow} is set:
  5084. delete {mineplex.chatslow}
  5085. send "&9Chat> &6%player% &7has disabled chat slow." to all players
  5086. set {mineplex.chatsilence} to true
  5087. send "&9Chat> &7The chat has been silenced for &aPermanent&7." to all players
  5088. stop
  5089. if {mineplex.chatsilence} is set:
  5090. delete {mineplex.chatsilence}
  5091. send "&9Chat> &7The chat is no longer silenced." to all players
  5092. else:
  5093. set {mineplex.chatsilence} to true
  5094. send "&9Chat> &7The chat has been silenced for &aPermanent&7." to all players
  5095.  
  5096. command /locate [<string>]:
  5097. aliases: /find, /where
  5098. permission: mineplex.trainee
  5099. permission message: &9Permissions> &7This requires Permission Rank [&9TRAINEE&7].
  5100. trigger:
  5101. if argument 1 is set:
  5102. set {_tmp} to arg 1 parsed as an offline player
  5103. if {_tmp} is online:
  5104. set {_mineplex.locate.temp} to "%{_tmp}'s world%"
  5105. send "&9Locate> &7Located [&e%arg-1%&7] at &9%{_mineplex.locate.temp}%"
  5106. else:
  5107. send "&9Locate> &7Failed to locate [&e%arg-1%&7]."
  5108. else:
  5109. send "&9Locate> &7Player argument missing."
  5110.  
  5111. command /updaterank [<offline player>] [<string>]:
  5112. permission: mineplex.admin
  5113. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  5114. trigger:
  5115. if argument 1 or argument 2 is not set:
  5116. send "&9Client Manager> &7Listing Rank Update Commands:"
  5117. send "&f/updaterank (player) (rank): &eupdates chosen player's rank to the chosen rank"
  5118. send ""
  5119. send "&9Rank Update> &7Listing Rank List:"
  5120. send "&9Ranks> &7ALL"
  5121. send "&9Ranks> &7ULTRA"
  5122. send "&9Ranks> &7HERO"
  5123. send "&9Ranks> &7LEGEND"
  5124. send "&9Ranks> &7TITAN"
  5125. send "&9Ranks> &7ETERNAL"
  5126. send "&9Ranks> &7TRAINEE"
  5127. send "&9Ranks> &7MODERATOR"
  5128. send "&9Ranks> &7SNR_MODERATOR"
  5129. send "&9Ranks> &7CLANS_MOD"
  5130. send "&9Ranks> &7JNR_DEV"
  5131. send "&9Ranks> &7SUPPORT"
  5132. send "&9Ranks> &7ADMIN"
  5133. send "&9Ranks> &7LEADER"
  5134. send "&9Ranks> &7DEVELOPER"
  5135. send "&9Ranks> &7OWNER"
  5136. send "&9Ranks> &7ARTIST"
  5137. send "&9Ranks> &7MAPLEAD"
  5138. send "&9Ranks> &7BUILDER"
  5139. send "&9Ranks> &7MAPPER"
  5140. send "&9Ranks> &7EVENT"
  5141. send "&9Ranks> &7TWITCH"
  5142. send "&9Ranks> &7YOUTUBE"
  5143. send "&9Ranks> &7YT"
  5144. set {_uuid} to uuid of arg-1
  5145. set {_allcap} to convert "%arg-2%" to all caps
  5146. if argument 2 is "ALL":
  5147. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5148. if {_c} is true:
  5149. set {mineplex.rank.%arg-1%} to ""
  5150. execute console command "/__mp__dp__ %arg-1%"
  5151. send "&9Client Manager> &7%arg-1%'s rank has been updated to None!"
  5152. send "&9Client Manager> &7Your rank has been updated to None!" to arg 1
  5153. set arg-1 tab name to "&e%arg-1%"
  5154. updateRankAPI(arg-1)
  5155. setPlayerdata(arg-1, "rank", "All")
  5156. else:
  5157. send "&9Client Manager> &c&lInvalid rank!"
  5158. else if argument 2 is "ULTRA":
  5159. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5160. if {_c} is true:
  5161. set {mineplex.rank.%arg-1%} to "&b&lULTRA "
  5162. execute console command "/__mp__dp__ %arg-1%"
  5163. send "&9Client Manager> &7%arg-1%'s rank has been updated to Ultra!"
  5164. send "&9Client Manager> &7Your rank has been updated to Ultra!" to arg 1
  5165. set arg-1 tab name to "&b&lULTRA &e%arg-1%"
  5166. updateRankAPI(arg-1)
  5167. setPlayerdata(arg-1, "rank", "Ultra")
  5168. else:
  5169. send "&9Client Manager> &c&lInvalid rank!"
  5170. else if argument 2 is "HERO":
  5171. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5172. if {_c} is true:
  5173. set {mineplex.rank.%arg-1%} to "&d&lHERO "
  5174. execute console command "/__mp__dp__ %arg-1%"
  5175. send "&9Client Manager> &7%arg-1%'s rank has been updated to Hero!"
  5176. send "&9Client Manager> &7Your rank has been updated to Hero!" to arg 1
  5177. set arg-1 tab name to "&d&lHERO &e%arg-1%"
  5178. updateRankAPI(arg-1)
  5179. setPlayerdata(arg-1, "rank", "Hero")
  5180. else:
  5181. send "&9Client Manager> &c&lInvalid rank!"
  5182. else if argument 2 is "LEGEND":
  5183. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5184. if {_c} is true:
  5185. set {mineplex.rank.%arg-1%} to "&a&lLEGEND "
  5186. execute console command "/__mp__dp__ %arg-1%"
  5187. add "mineplex.legend" to arg-1's permissions
  5188. send "&9Client Manager> &7%arg-1%'s rank has been updated to Legend!"
  5189. send "&9Client Manager> &7Your rank has been updated to Legend!" to arg 1
  5190. set arg-1 tab name to "&a&lLEGEND &e%arg-1%"
  5191. updateRankAPI(arg-1)
  5192. setPlayerdata(arg-1, "rank", "Legend")
  5193. else:
  5194. send "&9Client Manager> &c&lInvalid rank!"
  5195. else if argument 2 is "TITAN":
  5196. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5197. if {_c} is true:
  5198. set {mineplex.rank.%arg-1%} to "&c&lTITAN "
  5199. execute console command "/__mp__dp__ %arg-1%"
  5200. add "mineplex.legend" to arg-1's permissions
  5201. add "mineplex.titan" to arg-1's permissions
  5202. send "&9Client Manager> &7%arg-1%'s rank has been updated to Titan!"
  5203. send "&9Client Manager> &7Your rank has been updated to Titan!" to arg 1
  5204. set arg-1 tab name to "&c&lTITAN &e%arg-1%"
  5205. updateRankAPI(arg-1)
  5206. setPlayerdata(arg-1, "rank", "Titan")
  5207. else:
  5208. send "&9Client Manager> &c&lInvalid rank!"
  5209. else if argument 2 is "ETERNAL":
  5210. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5211. if {_c} is true:
  5212. set {mineplex.rank.%arg-1%} to "&3&lETERNAL "
  5213. execute console command "/__mp__dp__ %arg-1%"
  5214. add "mineplex.legend" to arg-1's permissions
  5215. add "mineplex.titan" to arg-1's permissions
  5216. send "&9Client Manager> &7%arg-1%'s rank has been updated to Eternal!"
  5217. send "&9Client Manager> &7Your rank has been updated to Eternal!" to arg 1
  5218. set arg-1 tab name to "&3&lETERNAL &e%arg-1%"
  5219. updateRankAPI(arg-1)
  5220. setPlayerdata(arg-1, "rank", "Eternal")
  5221. else:
  5222. send "&9Client Manager> &c&lInvalid rank!"
  5223. else if argument 2 is "TRAINEE":
  5224. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5225. if {_c} is true:
  5226. set {mineplex.rank.%arg-1%} to "&6&lTRAINEE "
  5227. execute console command "/__mp__dp__ %arg-1%"
  5228. add "mineplex.trainee" to arg-1's permissions
  5229. add "mineplex.legend" to arg-1's permissions
  5230. add "mineplex.titan" to arg-1's permissions
  5231. add "mineplex.2fa" to arg-1's permissions
  5232. send "&9Client Manager> &7%arg-1%'s rank has been updated to Trainee!"
  5233. send "&9Client Manager> &7Your rank has been updated to Trainee!" to arg 1
  5234. set arg-1 tab name to "&6&lTRAINEE &e%arg-1%"
  5235. updateRankAPI(arg-1)
  5236. setPlayerdata(arg-1, "rank", "Trainee")
  5237. else:
  5238. send "&9Client Manager> &c&lInvalid rank!"
  5239. else if argument 2 is "MODERATOR":
  5240. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5241. if {_c} is true:
  5242. set {mineplex.rank.%arg-1%} to "&6&lMOD "
  5243. execute console command "/__mp__dp__ %arg-1%"
  5244. add "mineplex.trainee" to arg-1's permissions
  5245. add "mineplex.mod" to arg-1's permissions
  5246. add "mineplex.legend" to arg-1's permissions
  5247. add "mineplex.2fa" to arg-1's permissions
  5248. add "mineplex.titan" to arg-1's permissions
  5249. send "&9Client Manager> &7%arg-1%'s rank has been updated to Mod!"
  5250. send "&9Client Manager> &7Your rank has been updated to Mod!" to arg 1
  5251. set arg-1 tab name to "&6&lMOD &e%arg-1%"
  5252. updateRankAPI(arg-1)
  5253. setPlayerdata(arg-1, "rank", "Mod")
  5254. else:
  5255. send "&9Client Manager> &c&lInvalid rank!"
  5256. else if argument 2 is "SNR_MODERATOR":
  5257. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5258. if {_c} is true:
  5259. set {mineplex.rank.%arg-1%} to "&6&lSR.MOD "
  5260. execute console command "/__mp__dp__ %arg-1%"
  5261. add "mineplex.trainee" to arg-1's permissions
  5262. add "mineplex.mod" to arg-1's permissions
  5263. add "mineplex.srmod" to arg-1's permissions
  5264. add "mineplex.legend" to arg-1's permissions
  5265. add "mineplex.2fa" to arg-1's permissions
  5266. add "mineplex.titan" to arg-1's permissions
  5267. send "&9Client Manager> &7%arg-1%'s rank has been updated to Sr.Mod!"
  5268. send "&9Client Manager> &7Your rank has been updated to Sr.Mod!" to arg 1
  5269. set arg-1 tab name to "&6&lSR.MOD &e%arg-1%"
  5270. updateRankAPI(arg-1)
  5271. set "rank" to "SrMod" in yaml file "plugins/Mineplex-Core-Remake/playerdata/%{_uuid}%.yml"
  5272. setPlayerdata(arg-1, "rank", "SrMod")
  5273. else:
  5274. send "&9Client Manager> &c&lInvalid rank!"
  5275. else if argument 2 is "CLANS_MOD":
  5276. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5277. if {_c} is true:
  5278. set {mineplex.rank.%arg-1%} to "&6&lC.MOD "
  5279. execute console command "/__mp__dp__ %arg-1%"
  5280. add "mineplex.trainee" to arg-1's permissions
  5281. add "mineplex.mod" to arg-1's permissions
  5282. add "mineplex.srmod" to arg-1's permissions
  5283. add "mineplex.legend" to arg-1's permissions
  5284. add "mineplex.2fa" to arg-1's permissions
  5285. add "mineplex.titan" to arg-1's permissions
  5286. send "&9Client Manager> &7%arg-1%'s rank has been updated to C.Mod!"
  5287. send "&9Client Manager> &7Your rank has been updated to C.Mod!" to arg 1
  5288. set arg-1 tab name to "&6&lC.MOD &e%arg-1%"
  5289. updateRankAPI(arg-1)
  5290. setPlayerdata(arg-1, "rank", "CMod")
  5291. else:
  5292. send "&9Client Manager> &c&lInvalid rank!"
  5293. else if argument 2 is "ADMIN":
  5294. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5295. if {_c} is true:
  5296. set {mineplex.rank.%arg-1%} to "&4&lADMIN "
  5297. execute console command "/__mp__dp__ %arg-1%"
  5298. add "mineplex.trainee" to arg-1's permissions
  5299. add "mineplex.legend" to arg-1's permissions
  5300. add "mineplex.mod" to arg-1's permissions
  5301. add "mineplex.jrdev" to arg-1's permissions
  5302. add "mineplex.youtube" to arg-1's permissions
  5303. add "mineplex.builder" to arg-1's permissions
  5304. add "mineplex.srmod" to arg-1's permissions
  5305. add "mineplex.admin" to arg-1's permissions
  5306. add "mineplex.titan" to arg-1's permissions
  5307. add "mineplex.2fa" to arg-1's permissions
  5308. send "&9Client Manager> &7%arg-1%'s rank has been updated to Admin!"
  5309. send "&9Client Manager> &7Your rank has been updated to Admin!" to arg 1
  5310. set arg-1 tab name to "&4&lADMIN &e%arg-1%"
  5311. updateRankAPI(arg-1)
  5312. setPlayerdata(arg-1, "rank", "Admin")
  5313. else:
  5314. send "&9Client Manager> &c&lInvalid rank!"
  5315. else if argument 2 is "APEX":
  5316. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5317. if {_c} is true:
  5318. set {mineplex.rank.%arg-1%} to "&9&lAPEX "
  5319. execute console command "/__mp__dp__ %arg-1%"
  5320. add "mineplex.trainee" to arg-1's permissions
  5321. add "mineplex.legend" to arg-1's permissions
  5322. add "mineplex.mod" to arg-1's permissions
  5323. add "mineplex.jrdev" to arg-1's permissions
  5324. add "mineplex.youtube" to arg-1's permissions
  5325. add "mineplex.builder" to arg-1's permissions
  5326. add "mineplex.srmod" to arg-1's permissions
  5327. add "mineplex.admin" to arg-1's permissions
  5328. add "mineplex.titan" to arg-1's permissions
  5329. add "mineplex.2fa" to arg-1's permissions
  5330. send "&9Client Manager> &7%arg-1%'s rank has been updated to Apex Minecraft Hosting!"
  5331. send "&9Client Manager> &7Your rank has been updated to Apex Minecraft Hosting!" to arg 1
  5332. set arg-1 tab name to "&9&lAPEX &e%arg-1%"
  5333. updateRankAPI(arg-1)
  5334. setPlayerdata(arg-1, "rank", "Apex")
  5335. else:
  5336. send "&9Client Manager> &c&lInvalid rank!"
  5337. else if argument 2 is "LEADER":
  5338. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5339. if {_c} is true:
  5340. set {mineplex.rank.%arg-1%} to "&4&lLEADER "
  5341. execute console command "/__mp__dp__ %arg-1%"
  5342. add "mineplex.trainee" to arg-1's permissions
  5343. add "mineplex.mod" to arg-1's permissions
  5344. add "mineplex.jrdev" to arg-1's permissions
  5345. add "mineplex.builder" to arg-1's permissions
  5346. add "mineplex.srmod" to arg-1's permissions
  5347. add "mineplex.admin" to arg-1's permissions
  5348. add "mineplex.youtube" to arg-1's permissions
  5349. add "mineplex.legend" to arg-1's permissions
  5350. add "mineplex.2fa" to arg-1's permissions
  5351. add "mineplex.leader" to arg-1's permissions
  5352. add "mineplex.titan" to arg-1's permissions
  5353. send "&9Client Manager> &7%arg-1%'s rank has been updated to Leader!"
  5354. send "&9Client Manager> &7Your rank has been updated to Leader!" to arg 1
  5355. set arg-1 tab name to "&4&lLEADER &e%arg-1%"
  5356. updateRankAPI(arg-1)
  5357. setPlayerdata(arg-1, "rank", "Leader")
  5358. else:
  5359. send "&9Client Manager> &c&lInvalid rank!"
  5360. else if argument 2 is "OWNER":
  5361. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5362. if {_c} is true:
  5363. set {mineplex.rank.%arg-1%} to "&4&lOWNER "
  5364. execute console command "/__mp__dp__ %arg-1%"
  5365. add "mineplex.trainee" to arg-1's permissions
  5366. add "mineplex.mod" to arg-1's permissions
  5367. add "mineplex.srmod" to arg-1's permissions
  5368. add "mineplex.admin" to arg-1's permissions
  5369. add "mineplex.jrdev" to arg-1's permissions
  5370. add "mineplex.dev" to arg-1's permissions
  5371. add "mineplex.youtube" to arg-1's permissions
  5372. add "mineplex.builder" to arg-1's permissions
  5373. add "mineplex.leader" to arg-1's permissions
  5374. add "mineplex.jrdev" to arg-1's permissions
  5375. add "mineplex.2fa" to arg-1's permissions
  5376. add "mineplex.owner" to arg-1's permissions
  5377. add "mineplex.legend" to arg-1's permissions
  5378. add "mineplex.titan" to arg-1's permissions
  5379. send "&9Client Manager> &7%arg-1%'s rank has been updated to Owner!"
  5380. send "&9Client Manager> &7Your rank has been updated to Owner!" to arg 1
  5381. set arg-1 tab name to "&4&lOWNER &e%arg-1%"
  5382. updateRankAPI(arg-1)
  5383. setPlayerdata(arg-1, "rank", "Owner")
  5384. else:
  5385. send "&9Client Manager> &c&lInvalid rank!"
  5386. else if argument 2 is "BUILDER":
  5387. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5388. if {_c} is true:
  5389. set {mineplex.rank.%arg-1%} to "&9&lBUILDER "
  5390. execute console command "/__mp__dp__ %arg-1%"
  5391. add "mineplex.titan" to arg-1's permissions
  5392. add "mineplex.legend" to arg-1's permissions
  5393. add "mineplex.2fa" to arg-1's permissions
  5394. send "&9Client Manager> &7%arg-1%'s rank has been updated to Builder!"
  5395. send "&9Client Manager> &7Your rank has been updated to Builder!" to arg 1
  5396. set arg-1 tab name to "&9&lBUIDLER &e%arg-1%"
  5397. updateRankAPI(arg-1)
  5398. setPlayerdata(arg-1, "rank", "Builder")
  5399. else:
  5400. send "&9Client Manager> &c&lInvalid rank!"
  5401. else if argument 2 is "MAPPER":
  5402. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5403. if {_c} is true:
  5404. set {mineplex.rank.%arg-1%} to "&9&lMAPPER "
  5405. execute console command "/__mp__dp__ %arg-1%"
  5406. add "mineplex.builder" to arg-1's permissions
  5407. add "mineplex.titan" to arg-1's permissions
  5408. add "mineplex.legend" to arg-1's permissions
  5409. add "mineplex.2fa" to arg-1's permissions
  5410. send "&9Client Manager> &7%arg-1%'s rank has been updated to Mapper!"
  5411. send "&9Client Manager> &7Your rank has been updated to Mapper!" to arg 1
  5412. set arg-1 tab name to "&9&lMAPPER &e%arg-1%"
  5413. updateRankAPI(arg-1)
  5414. setPlayerdata(arg-1, "rank", "Mapper")
  5415. else:
  5416. send "&9Client Manager> &c&lInvalid rank!"
  5417. else if argument 2 is "SUPPORT":
  5418. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5419. if {_c} is true:
  5420. set {mineplex.rank.%arg-1%} to "&9&lSUPPORT "
  5421. execute console command "/__mp__dp__ %arg-1%"
  5422. add "mineplex.trainee" to arg-1's permissions
  5423. add "mineplex.legend" to arg-1's permissions
  5424. add "mineplex.jrdev" to arg-1's permissions
  5425. add "mineplex.2fa" to arg-1's permissions
  5426. add "mineplex.mod" to arg-1's permissions
  5427. add "mineplex.youtube" to arg-1's permissions
  5428. add "mineplex.builder" to arg-1's permissions
  5429. add "mineplex.srmod" to arg-1's permissions
  5430. add "mineplex.admin" to arg-1's permissions
  5431. add "mineplex.titan" to arg-1's permissions
  5432. send "&9Client Manager> &7%arg-1%'s rank has been updated to Support!"
  5433. send "&9Client Manager> &7Your rank has been updated to Support!" to arg 1
  5434. set arg-1 tab name to "&9&lSUPPORT &e%arg-1%"
  5435. updateRankAPI(arg-1)
  5436. setPlayerdata(arg-1, "rank", "Support")
  5437. else:
  5438. send "&9Client Manager> &c&lInvalid rank!"
  5439. else if argument 2 is "ARTIST":
  5440. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5441. if {_c} is true:
  5442. set {mineplex.rank.%arg-1%} to "&9&lARTIST "
  5443. execute console command "/__mp__dp__ %arg-1%"
  5444. add "mineplex.legend" to arg-1's permissions
  5445. add "mineplex.titan" to arg-1's permissions
  5446. send "&9Client Manager> &7%arg-1%'s rank has been updated to Artist!"
  5447. send "&9Client Manager> &7Your rank has been updated to Artist!" to arg 1
  5448. set arg-1 tab name to "&9&lARTIST &e%arg-1%"
  5449. updateRankAPI(arg-1)
  5450. setPlayerdata(arg-1, "rank", "Artist")
  5451. else:
  5452. send "&9Client Manager> &c&lInvalid rank!"
  5453. else if argument 2 is "MAPLEAD":
  5454. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5455. if {_c} is true:
  5456. set {mineplex.rank.%arg-1%} to "&9&lMAPLEAD "
  5457. execute console command "/__mp__dp__ %arg-1%"
  5458. add "mineplex.builder" to arg-1's permissions
  5459. add "mineplex.2fa" to arg-1's permissions
  5460. add "mineplex.titan" to arg-1's permissions
  5461. add "mineplex.legend" to arg-1's permissions
  5462. send "&9Client Manager> &7%arg-1%'s rank has been updated to MapLead!"
  5463. send "&9Client Manager> &7Your rank has been updated to MapLead!" to arg 1
  5464. set arg-1 tab name to "&9&lMAPLEAD &e%arg-1%"
  5465. updateRankAPI(arg-1)
  5466. setPlayerdata(arg-1, "rank", "Maplead")
  5467. else:
  5468. send "&9Client Manager> &c&lInvalid rank!"
  5469. else if argument 2 is "JNR_DEV":
  5470. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5471. if {_c} is true:
  5472. set {mineplex.rank.%arg-1%} to "&6&lJR.DEV "
  5473. execute console command "/__mp__dp__ %arg-1%"
  5474. add "mineplex.trainee" to arg-1's permissions
  5475. add "mineplex.mod" to arg-1's permissions
  5476. add "mineplex.srmod" to arg-1's permissions
  5477. add "mineplex.2fa" to arg-1's permissions
  5478. add "mineplex.builder" to arg-1's permissions
  5479. add "mineplex.jrdev" to arg-1's permissions
  5480. add "mineplex.legend" to arg-1's permissions
  5481. add "mineplex.titan" to arg-1's permissions
  5482. send "&9Client Manager> &7%arg-1%'s rank has been updated to Jr.Dev!"
  5483. send "&9Client Manager> &7Your rank has been updated to Jr.Dev!" to arg 1
  5484. set arg-1 tab name to "&6&lJR.DEV &e%arg-1%"
  5485. updateRankAPI(arg-1)
  5486. setPlayerdata(arg-1, "rank", "JrDev")
  5487. else:
  5488. send "&9Client Manager> &c&lInvalid rank!"
  5489. else if argument 2 is "DEVELOPER":
  5490. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5491. if {_c} is true:
  5492. set {mineplex.rank.%arg-1%} to "&4&lDEV "
  5493. execute console command "/__mp__dp__ %arg-1%"
  5494. add "mineplex.trainee" to arg-1's permissions
  5495. add "mineplex.mod" to arg-1's permissions
  5496. add "mineplex.srmod" to arg-1's permissions
  5497. add "mineplex.jrdev" to arg-1's permissions
  5498. add "mineplex.2fa" to arg-1's permissions
  5499. add "mineplex.admin" to arg-1's permissions
  5500. add "mineplex.leader" to arg-1's permissions
  5501. add "mineplex.owner" to arg-1's permissions
  5502. add "mineplex.builder" to arg-1's permissions
  5503. add "mineplex.dev" to arg-1's permissions
  5504. add "mineplex.youtube" to arg-1's permissions
  5505. add "mineplex.admin" to arg-1's permissions
  5506. add "mineplex.legend" to arg-1's permissions
  5507. add "mineplex.titan" to arg-1's permissions
  5508. send "&9Client Manager> &7%arg-1%'s rank has been updated to Dev!"
  5509. send "&9Client Manager> &7Your rank has been updated to Dev!" to arg 1
  5510. set arg-1 tab name to "&4&lDEV &e%arg-1%"
  5511. updateRankAPI(arg-1)
  5512. setPlayerdata(arg-1, "rank", "Dev")
  5513. else:
  5514. send "&9Client Manager> &c&lInvalid rank!"
  5515. else if argument 2 is "TWITCH":
  5516. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5517. if {_c} is true:
  5518. set {mineplex.rank.%arg-1%} to "&5&lTWITCH "
  5519. execute console command "/__mp__dp__ %arg-1%"
  5520. add "mineplex.twitch" to arg-1's permissions
  5521. add "mineplex.legend" to arg-1's permissions
  5522. add "mineplex.titan" to arg-1's permissions
  5523. add "mineplex.youtube" to arg-1's permissions
  5524. send "&9Client Manager> &7%arg-1%'s rank has been updated to Twitch!"
  5525. send "&9Client Manager> &7Your rank has been updated to Twitch!" to arg 1
  5526. set arg-1 tab name to "&5&lTWITCH &e%arg-1%"
  5527. updateRankAPI(arg-1)
  5528. setPlayerdata(arg-1, "rank", "Twitch")
  5529. else:
  5530. send "&9Client Manager> &c&lInvalid rank!"
  5531. else if argument 2 is "YOUTUBE":
  5532. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5533. if {_c} is true:
  5534. set {mineplex.rank.%arg-1%} to "&c&lYOUTUBE "
  5535. execute console command "/__mp__dp__ %arg-1%"
  5536. add "mineplex.youtube" to arg-1's permissions
  5537. add "mineplex.legend" to arg-1's permissions
  5538. add "mineplex.titan" to arg-1's permissions
  5539. send "&9Client Manager> &7%arg-1%'s rank has been updated to YouTube!"
  5540. send "&9Client Manager> &7Your rank has been updated to YouTube!" to arg 1
  5541. set arg-1 tab name to "&c&lYOUTUBE &e%arg-1%"
  5542. updateRankAPI(arg-1)
  5543. setPlayerdata(arg-1, "rank", "Youtube")
  5544. else:
  5545. send "&9Client Manager> &c&lInvalid rank!"
  5546. else if argument 2 is "EVENT":
  5547. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5548. if {_c} is true:
  5549. set {mineplex.rank.%arg-1%} to "&f&lEVENT "
  5550. execute console command "/__mp__dp__ %arg-1%"
  5551. add "mineplex.youtube" to arg-1's permissions
  5552. add "mineplex.legend" to arg-1's permissions
  5553. add "mineplex.titan" to arg-1's permissions
  5554. send "&9Client Manager> &7%arg-1%'s rank has been updated to Event!"
  5555. send "&9Client Manager> &7Your rank has been updated to Event!" to arg 1
  5556. set arg-1 tab name to "&f&lEVENT &e%arg-1%"
  5557. updateRankAPI(arg-1)
  5558. setPlayerdata(arg-1, "rank", "Event")
  5559. else:
  5560. send "&9Client Manager> &c&lInvalid rank!"
  5561. else if argument 2 is "YT":
  5562. set {_c} to caseSensitive("%arg-2%", "%{_allcap}%")
  5563. if {_c} is true:
  5564. set {mineplex.rank.%arg-1%} to "&5&lYT "
  5565. execute console command "/__mp__dp__ %arg-1%"
  5566. add "mineplex.youtube" to arg-1's permissions
  5567. add "mineplex.legend" to arg-1's permissions
  5568. add "mineplex.titan" to arg-1's permissions
  5569. send "&9Client Manager> &7%arg-1%'s rank has been updated to YT!"
  5570. send "&9Client Manager> &7Your rank has been updated to YT!" to arg 1
  5571. set arg-1 tab name to "&5&lYT &e%arg-1%"
  5572. updateRankAPI(arg-1)
  5573. setPlayerdata(arg-1, "rank", "Yt")
  5574. else:
  5575. send "&9Client Manager> &c&lInvalid rank!"
  5576. else:
  5577. send "&9Client Manager> &c&lInvalid rank!"
  5578. rankLoad(arg-1, 2, 0)
  5579.  
  5580. command /powerplay [<offline player>]:
  5581. permission: mineplex.jrdev
  5582. permission message: &9Permissions> &7This requires Permission Rank [&9JR.DEV&7].
  5583. trigger:
  5584. if arg 1 is set:
  5585. if {mineplex.ppc.%arg-1%} is not set:
  5586. set {mineplex.ppc.%arg-1%} to true
  5587. send "&9PPC> &7%arg-1% Power Play: &aTrue"
  5588. else:
  5589. delete {mineplex.ppc.%arg-1%}
  5590. send "&9PPC> &7%arg-1% Power Play: &cFalse"
  5591. else:
  5592. send "&9PPC> &7/powerplay (player)"
  5593.  
  5594. command /shard [<offline player>] [<string>] [<string>]:
  5595. permission: mineplex.admin
  5596. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  5597. trigger:
  5598. if arg 1 is not set:
  5599. send "&9Shard> &7Missing Args: &e/shard <player> <amount>"
  5600. else:
  5601. if arg 2 is not set:
  5602. send "&9Shard> &7Missing Args: &e/shard <player> <amount>"
  5603. else:
  5604. if arg 1 is not online:
  5605. send "&9Shard> &7Could not find player &e%arg-1%"
  5606. else:
  5607. set {_num} to arg 2 parsed as an integer
  5608. if {_num} is an integer:
  5609. add {_num} to {mineplex.shards.%arg-1%}
  5610. send "&9Shard> &7You gave &e%arg-2% Shards &7to &e%arg-1%&7."
  5611. send "&9Shard> &e%player% &7gave you &e%arg-2% Shards&7." to arg-1
  5612. addShards(arg-1, {_num})
  5613. else:
  5614. send "&9Shard> &7Invalid Shards Amount"
  5615.  
  5616. command /gem [<offline player>] [<string>] [<string>]:
  5617. permission: mineplex.admin
  5618. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  5619. trigger:
  5620. if arg 1 is not set:
  5621. send "&9Gem> &7Missing Args: &e/gem <player> <amount>"
  5622. else:
  5623. if arg 2 is not set:
  5624. send "&9Gem> &7Missing Args: &e/gem <player> <amount>"
  5625. else:
  5626. if arg 1 is not online:
  5627. send "&9Gem> &7Could not find player &e%arg-1%"
  5628. else:
  5629. set {_num} to arg 2 parsed as an integer
  5630. if {_num} is an integer:
  5631. addGems(arg-1, {_num})
  5632. send "&9Gem> &7You gave &e%arg-2% Gems &7to &e%arg-1%&7."
  5633. send "&9Gem> &e%player% &7gave you &e%arg-2% Gems&7." to arg-1
  5634. else:
  5635. send "&9Gem> &7Invalid Gems Amount"
  5636.  
  5637. command /testrank [<offline player>] [<string>]:
  5638. permission: mineplex.srmod
  5639. permission message: &9Permissions> &7This requires Permission Rank [&6SR.MOD&7].
  5640. trigger:
  5641. if arg 1 is not set:
  5642. send "&9Client Manager> &7/testrank joeschmo ETERNAL"
  5643. send "&9Client Manager> &7TestRanks expire on login/logout!"
  5644. else:
  5645. if arg 2 is not set:
  5646. send "&9Client Manager> &7/testrank joeschmo ETERNAL"
  5647. else:
  5648. if arg 1 is online:
  5649. if {mineplex.testrank.%arg-1%} is not set:
  5650. if arg 2 is "ULTRA":
  5651. set {mineplex.testrank.%arg-1%} to {mineplex.rank.%arg-1%}
  5652. set {mineplex.rank.%arg-1%} to "&b&lULTRA "
  5653. execute console command "/__mp__dp__ %arg-1%"
  5654. set {_or} to uncolored {mineplex.testrank.%arg-1%}
  5655. send "&9Client Manager> &7%arg-1%'s rank has been updated to %arg-2%!"
  5656. send "&9Client Manager> &7%arg-1%'s rank will be reset to %{_or}%on your login!"
  5657. send "&9Client Manager> &7Your rank has been updated to %arg-2%!" to arg 1
  5658. send "&9Client Manager> &7Your rank will be reset to %{_or}%on your login!" to arg 1
  5659. set arg-1 tab name to "&b&lULTRA &e%arg-1%"
  5660. updateRankAPI(arg-1)
  5661. wait 5 ticks
  5662. rankLoad(arg-1, 2, 1)
  5663. else if arg 2 is "HERO":
  5664. set {mineplex.testrank.%arg-1%} to {mineplex.rank.%arg-1%}
  5665. set {mineplex.rank.%arg-1%} to "&d&lHERO "
  5666. execute console command "/__mp__dp__ %arg-1%"
  5667. set {_or} to uncolored {mineplex.testrank.%arg-1%}
  5668. send "&9Client Manager> &7%arg-1%'s rank has been updated to %arg-2%!"
  5669. send "&9Client Manager> &7%arg-1%'s rank will be reset to %{_or}%on your login!"
  5670. send "&9Client Manager> &7Your rank has been updated to %arg-2%!" to arg 1
  5671. send "&9Client Manager> &7Your rank will be reset to %{_or}%on your login!" to arg 1
  5672. set arg-1 tab name to "&d&lHERO &e%arg-1%"
  5673. updateRankAPI(arg-1)
  5674. wait 5 ticks
  5675. rankLoad(arg-1, 2, 1)
  5676. else if arg 2 is "LEGEND":
  5677. set {mineplex.testrank.%arg-1%} to {mineplex.rank.%arg-1%}
  5678. set {mineplex.rank.%arg-1%} to "&a&lLEGEND "
  5679. execute console command "/__mp__dp__ %arg-1%"
  5680. set {_or} to uncolored {mineplex.testrank.%arg-1%}
  5681. send "&9Client Manager> &7%arg-1%'s rank has been updated to %arg-2%!"
  5682. send "&9Client Manager> &7%arg-1%'s rank will be reset to %{_or}%on your login!"
  5683. send "&9Client Manager> &7Your rank has been updated to %arg-2%!" to arg 1
  5684. send "&9Client Manager> &7Your rank will be reset to %{_or}%on your login!" to arg 1
  5685. set arg-1 tab name to "&a&lLEGEND &e%arg-1%"
  5686. updateRankAPI(arg-1)
  5687. wait 5 ticks
  5688. rankLoad(arg-1, 2, 1)
  5689. else if arg 2 is "TITAN":
  5690. set {mineplex.testrank.%arg-1%} to {mineplex.rank.%arg-1%}
  5691. set {mineplex.rank.%arg-1%} to "&c&lTITAN "
  5692. execute console command "/__mp__dp__ %arg-1%"
  5693. set {_or} to uncolored {mineplex.testrank.%arg-1%}
  5694. send "&9Client Manager> &7%arg-1%'s rank has been updated to %arg-2%!"
  5695. send "&9Client Manager> &7%arg-1%'s rank will be reset to %{_or}%on your login!"
  5696. send "&9Client Manager> &7Your rank has been updated to %arg-2%!" to arg 1
  5697. send "&9Client Manager> &7Your rank will be reset to %{_or}%on your login!" to arg 1
  5698. set arg-1 tab name to "&c&lTITAN &e%arg-1%"
  5699. updateRankAPI(arg-1)
  5700. wait 5 ticks
  5701. rankLoad(arg-1, 2, 1)
  5702. else if arg 2 is "ETERNAL":
  5703. set {mineplex.testrank.%arg-1%} to {mineplex.rank.%arg-1%}
  5704. set {mineplex.rank.%arg-1%} to "&3&lETERNAL "
  5705. execute console command "/__mp__dp__ %arg-1%"
  5706. set {_or} to uncolored {mineplex.testrank.%arg-1%}
  5707. send "&9Client Manager> &7%arg-1%'s rank has been updated to %arg-2%!"
  5708. send "&9Client Manager> &7%arg-1%'s rank will be reset to %{_or}%on your login!"
  5709. send "&9Client Manager> &7Your rank has been updated to %arg-2%!" to arg 1
  5710. send "&9Client Manager> &7Your rank will be reset to %{_or}%on your login!" to arg 1
  5711. set arg-1 tab name to "&3&lETERNAL &e%arg-1%"
  5712. updateRankAPI(arg-1)
  5713. wait 5 ticks
  5714. rankLoad(arg-1, 2, 1)
  5715. else:
  5716. send "&9Client Manager> &c&lThis player already has a test rank!"
  5717. else:
  5718. send "&9Client Manager> &c&lInvalid rank!"
  5719.  
  5720. command /getadmin:
  5721. permission: mineplex.jrdev
  5722. permission message: &9Permissions> &7This requires Permission Rank [&9JR.DEV&7].
  5723. trigger:
  5724. if {mineplex.rank.%player%} is "&6&lJR.DEV ":
  5725. if {mineplex.disguise.%player%} is set:
  5726. set {_p} to {mineplex.disguise.%player%}
  5727. else:
  5728. set {_p} to player
  5729. if {mineplex.adminmode.%player%} is true:
  5730. remove "mineplex.admin" from player's permissions
  5731. remove "mineplex.builder" from player's permissions
  5732. remove "mineplex.youtube" from player's permissions
  5733. set {mineplex.adminmode.%player%} to false
  5734. send "&9Admin Mode> &7%{_p}% Admin Mode: &cFalse"
  5735. else:
  5736. set {mineplex.adminmode.%player%} to true
  5737. add "mineplex.admin" to player's permissions
  5738. add "mineplex.builder" to player's permissions
  5739. add "mineplex.youtube" to player's permissions
  5740. send "&9Admin Mode> &7%{_p}% Admin Mode: &aTrue"
  5741. else:
  5742. send "&9Admin Mode> &7/getadmin is only for JR.DEV!"
  5743.  
  5744. command /__mp__dp__ <player>:
  5745. executable by: console
  5746. trigger:
  5747. remove "mineplex.trainee" from arg-1's permissions
  5748. remove "mineplex.legend" from arg-1's permissions
  5749. remove "mineplex.titan" from arg-1's permissions
  5750. remove "mineplex.mod" from arg-1's permissions
  5751. remove "mineplex.srmod" from arg-1's permissions
  5752. remove "mineplex.admin" from arg-1's permissions
  5753. remove "mineplex.leader" from arg-1's permissions
  5754. remove "mineplex.owner" from arg-1's permissions
  5755. remove "mineplex.jrdev" from arg-1's permissions
  5756. remove "mineplex.dev" from arg-1's permissions
  5757. remove "mineplex.twitch" from arg-1's permissions
  5758. remove "mineplex.youtube" from arg-1's permissions
  5759. remove "mineplex.builder" from arg-1's permissions
  5760.  
  5761. function rawreport(arg1: player , arg2: player , arg3: text , arg4: text , arg5: text) :: string:
  5762. if {_arg3} is "Hacking":
  5763. set {mineplex.report.player.%{mineplex.report.id}%} to {_arg1}
  5764. set {mineplex.report.reporter.%{mineplex.report.id}%} to {_arg2}
  5765. set {mineplex.report.type.%{mineplex.report.id}%} to {_arg3}
  5766. set {mineplex.report.server.%{mineplex.report.id}%} to {_arg4}
  5767. set {mineplex.report.reason.%{mineplex.report.id}%} to {_arg5}
  5768. set {mineplex.report.open.%{mineplex.report.id}%} to true
  5769. send "&9Report ##%{mineplex.report.id}%> &aSuccessfully created report." to {_arg2}
  5770. else if {_arg3} is "Chat-Abuse":
  5771. set {mineplex.report.player.%{mineplex.report.id}%} to {_arg1}
  5772. set {mineplex.report.reporter.%{mineplex.report.id}%} to {_arg2}
  5773. set {mineplex.report.type.%{mineplex.report.id}%} to {_arg3}
  5774. set {mineplex.report.server.%{mineplex.report.id}%} to {_arg4}
  5775. set {mineplex.report.reason.%{mineplex.report.id}%} to {_arg5}
  5776. set {mineplex.report.open.%{mineplex.report.id}%} to true
  5777. send "&9Report ##%{mineplex.report.id}%> &aSuccessfully created report." to {_arg2}
  5778. else if {_arg3} is "Gameplay":
  5779. set {mineplex.report.player.%{mineplex.report.id}%} to {_arg1}
  5780. set {mineplex.report.reporter.%{mineplex.report.id}%} to {_arg2}
  5781. set {mineplex.report.type.%{mineplex.report.id}%} to {_arg3}
  5782. set {mineplex.report.server.%{mineplex.report.id}%} to {_arg4}
  5783. set {mineplex.report.reason.%{mineplex.report.id}%} to {_arg5}
  5784. set {mineplex.report.open.%{mineplex.report.id}%} to true
  5785. send "&9Report ##%{mineplex.report.id}%> &aSuccessfully created report." to {_arg2}
  5786. else:
  5787. stop
  5788. loop all players:
  5789. if loop-player has permission "mineplex.trainee":
  5790. if {mineplex.pref.report.%loop-player%} is true:
  5791. send "&9[Report ##%{mineplex.report.id}%] &7%{_arg2}% has reported %{_arg1}% for a &e%{_arg3}% &7offence with reason &e%{_arg5}%&7!" to loop-player
  5792. add 1 to {mineplex.report.id}
  5793.  
  5794. command /report [<offline player>] [<text>]:
  5795. permission: mineplex.titan
  5796. permission message: &9Report> &cThe report feature is currently in a trial phase for Titan players
  5797. trigger:
  5798. if arg-2 is set:
  5799. if arg-1 is player:
  5800. send "&9Report> &cYou cannot report yourself."
  5801. stop
  5802. open chest with 3 rows named "Report %arg-1%" to player
  5803. format slot 11 of player with iron sword named "&c&lHacking" with lore "&7X-ray, Forcefield, Speed, Fly etc" to close then run [send "&9Report ##%{mineplex.report.id}%> &aSuccessfully created report." to player]->[rawreport(arg-1, player, "Hacking", "%player's world%", arg-2)]
  5804. format slot 13 of player with book and quill named "&3&lChat Abuse" with lore "&7Verbal Abuse, Spam, Harassment, Trolling, etc" to close then run [send "&9Report ##%{mineplex.report.id}%> &aSuccessfully created report." to player]->[rawreport(arg-1, player, "Chat-Abuse", "%player's world%", arg-2)]
  5805. format slot 15 of player with ender pearl named "&fGameplay" with lore "&7Map and Bug Exploits" to close then run [send "&9Report ##%{mineplex.report.id}%> &aSuccessfully created report." to player]->[rawreport(arg-1, player, "Gameplay", "%player's world%", arg-2)]
  5806. else:
  5807. send "&9Report> &cInvalid Usage: &e/report <player> <reason>"
  5808.  
  5809. command /reporthandle [<string>] [<string>]:
  5810. aliases: /rh
  5811. permission: mineplex.mod
  5812. permission message: &9Permissions> &7This requires Permission Rank [&9MOD&7].
  5813. trigger:
  5814. if arg 1 is not set:
  5815. send "&9Report> &7Corect Usage: &e/reporthandle <report id>"
  5816. else:
  5817. set {_id} to arg-1 parsed as a number
  5818. if {_id} is a number:
  5819. if {mineplex.report.open.%{_id}%} is true:
  5820. if {mineplex.report.hand.%{_id}%} is not set:
  5821. set {mineplex.report.hand.%{_id}%} to player
  5822. set {_sus} to {mineplex.report.player.%{_id}%} parsed as an offline player
  5823. set {_ip} to ip address of {_sus}
  5824. loop {mineplex.totalaccounts.%{_ip}%::*}:
  5825. add 1 to {_accounts}
  5826. if {_accounts} is not set:
  5827. set {_accounts} to 1
  5828. send ""
  5829. send "&9Report ##%{_id}%> &bReport Overview"
  5830. send "&9Report ##%{_id}%> &bSuspect - &6%{mineplex.report.player.%{_id}%}%"
  5831. send "&9Report ##%{_id}%> &bType - &6%{mineplex.report.type.%{_id}%}%"
  5832. send "&9Report ##%{_id}%> &bTeam - &6None"
  5833. send "&9Report ##%{_id}%>"
  5834. send "&9Report ##%{_id}%> &6SoonTM &btotal reports"
  5835. send "&9Report ##%{_id}%>"
  5836. send "&9Report ##%{_id}%> &7(1) &6%{mineplex.report.reporter.%{_id}%}% ##1 &7- ""&b%{mineplex.report.reason.%{_id}%}%&7"""
  5837. send "&9Report ##%{_id}%>"
  5838. send "&9Report ##%{_id}%> &bView chat log"
  5839. mcrjson("%player%", "&9Report ##%{_id}%> ||&bClose this report||ttp:&bClick to close this report||cmd:/reportclose %{_id}% undetermined")
  5840. loop all players:
  5841. if loop-player has permission "mineplex.trainee":
  5842. if {mineplex.pref.report.%loop-player%} is true:
  5843. send "&9[Report %{_id}%] &e%player% &7is handling this report." to loop-player
  5844. else:
  5845. send "&9Report> &7This report is already being handling!"
  5846. else:
  5847. send "&9Report> &7This report has already been closed or does not exsit!"
  5848. else:
  5849. send "&9Report> &cYour arguments are inappropriate for this command!"
  5850. send "&9Report> &e/reporthandle (id)"
  5851.  
  5852. command /reportclose [<string>] [<string>] [<string>]:
  5853. aliases: /rc
  5854. permission: mineplex.mod
  5855. permission message: &9Permissions> &7This requires Permission Rank [&9MOD&7].
  5856. trigger:
  5857. if arg 1 is not set:
  5858. send "&9Report> &7Corect Usage: &e/reportclose (report id)"
  5859. send "&9Report> &7Reasons: &eUNDETERMINED MUTED BANNED ABUSE"
  5860. stop
  5861. if arg 2 is not set:
  5862. send "&9Report> &7Corect Usage: &e/reportclose (report id)"
  5863. send "&9Report> &7Reasons: &eUNDETERMINED MUTED BANNED ABUSE"
  5864. stop
  5865. else:
  5866. set {_id} to arg-1 parsed as a number
  5867. if {mineplex.report.hand.%{_id}%} is not player:
  5868. send "&9Report> &cYou can only close your own report!"
  5869. stop
  5870. if {_id} is a number:
  5871. if {mineplex.report.open.%{_id}%} is true:
  5872. if arg 2 is "UNDETERMINED":
  5873. set {_r} to "&f&lCould not determine"
  5874. set {mineplex.report.open.%{_id}%} to false
  5875. loop all players:
  5876. if loop-player has permission "mineplex.trainee":
  5877. if {mineplex.pref.report.%loop-player%} is true:
  5878. send "&9[Report %{_id}%] &e%player% &7closed this report. (%{_r}%&7)." to loop-player
  5879. else if arg 2 is "MUTED":
  5880. set {_r} to "&e&lMuted"
  5881. set {mineplex.report.open.%{_id}%} to false
  5882. loop all players:
  5883. if loop-player has permission "mineplex.trainee":
  5884. if {mineplex.pref.report.%loop-player%} is true:
  5885. send "&9[Report %{_id}%] &e%player% &7closed this report. (%{_r}%&7)." to loop-player
  5886. else if arg 2 is "BANNED":
  5887. set {_r} to "&c&lBanned"
  5888. set {mineplex.report.open.%{_id}%} to false
  5889. loop all players:
  5890. if loop-player has permission "mineplex.trainee":
  5891. if {mineplex.pref.report.%loop-player%} is true:
  5892. send "&9[Report %{_id}%] &e%player% &7closed this report. (%{_r}%&7)." to loop-player
  5893. else if arg 2 is "ABUSE":
  5894. set {_r} to "&4&lAbuse of report system"
  5895. set {mineplex.report.open.%{_id}%} to false
  5896. loop all players:
  5897. if loop-player has permission "mineplex.trainee":
  5898. if {mineplex.pref.report.%loop-player%} is true:
  5899. send "&9[Report %{_id}%] &e%player% &7closed this report. (%{_r}%&7)." to loop-player
  5900. else:
  5901. send "&9Report> &cInvalid report reason!"
  5902. else:
  5903. send "&9Report> &7This report has already been closed or does not exsit!"
  5904. else:
  5905. send "&9Report> &cYour arguments are inappropriate for this command!"
  5906. send "&9Report> &e/reportclose (report id) (reason)"
  5907. send "&9Report> &7Reasons: &eUNDETERMINED MUTED BANNED ABUSE"
  5908.  
  5909. command /s [<text>]:
  5910. permission: mineplex.mod
  5911. permission message: &9Permissions> &7This requires Permission Rank [&9MOD&7].
  5912. trigger:
  5913. if {mineplex.disguise.%player%} is set:
  5914. set {_p} to {mineplex.disguise.%player%}
  5915. else:
  5916. set {_p} to player
  5917. if argument 1 is set:
  5918. broadcast "&f&l%{_p}% &b%arg-1%"
  5919. else:
  5920. send "&9Broadcast> &7Corect Usage: /s <message>."
  5921.  
  5922. command /gm [<player>]:
  5923. permission: mineplex.builder
  5924. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  5925. trigger:
  5926. if {mineplex.disguise.%player%} is set:
  5927. set {_p} to {mineplex.disguise.%player%}
  5928. else:
  5929. set {_p} to player
  5930. if argument 1 is not set:
  5931. if player's gamemode is survival:
  5932. set the player's gamemode to creative
  5933. send "&9Game Mode> &7%{_p}% Creative Mode: &aTrue"
  5934. else:
  5935. set the player's gamemode to survival
  5936. send "&9Game Mode> &7%{_p}% Creative Mode: &cFalse"
  5937. else:
  5938. if player has permission "mineplex.admin":
  5939. if arg-1's gamemode is survival:
  5940. set the arg-1's gamemode to creative
  5941. send "&9Game Mode> &7%arg-1% Creative Mode: &aTrue"
  5942. else:
  5943. set the arg-1's gamemode to survival
  5944. send "&9Game Mode> &7%arg-1% Creative Mode: &cFalse"
  5945. else:
  5946. send "&9Permissions> &7This requires Permission Rank [&9ADMIN&7]."
  5947.  
  5948. command /ignore [<offline player>] [<string>]:
  5949. trigger:
  5950. if arg 1 is not set:
  5951. if {mineplex.ignorelist.%player%::*} is not set:
  5952. send "&b&m=====================[&f&lIgnoring&b&m]======================"
  5953. send ""
  5954. send "&fWelcome to your Ignore List!"
  5955. send ""
  5956. send "&fTo ignore people, type &a/ignore <Player Name>"
  5957. send ""
  5958. send "&fType &a/ignore &fat any time to view the ignored!"
  5959. send ""
  5960. send "&b&m====================================================="
  5961. else:
  5962. send "&b&m=====================[&f&lIgnoring&b&m]======================"
  5963. loop {mineplex.ignorelist.%player%::*}:
  5964. mcrjson("%player%", "&7Ignoring %loop-value% &f - ||&c&lUnignore||ttp:&fStop ignoring %loop-value%||cmd:/unignore %loop-value%||")
  5965. send "&b&m====================================================="
  5966. else:
  5967. loop {mineplex.ignorelist.%player%::*}:
  5968. if loop-value is "%arg-1%":
  5969. set {_pre} to true
  5970. if {_pre} is true:
  5971. send "&9Ignore> &a%arg-1% &7has already been ignored."
  5972. else:
  5973. add "%arg-1%" to {mineplex.ignorelist.%player%::*}
  5974. send "&9Ignore> &7Now ignoring &a%arg-1%"
  5975.  
  5976. command /unignore [<offline player>] [<string>]:
  5977. trigger:
  5978. if arg 1 is set:
  5979. send "&9Ignore> &7No longer ignoring &a%arg-1%"
  5980. remove "%arg-1%" from {mineplex.ignorelist.%player%::*}
  5981.  
  5982. command /message [<player>] [<text>]:
  5983. aliases: /tell, /m, /w, /msg, /whisper
  5984. trigger:
  5985. if {mineplex.disguise.%player%} is set:
  5986. set {_p} to {mineplex.disguise.%player%}
  5987. else:
  5988. set {_p} to player
  5989. set {_get} to getPlayerdata(player, "muted")
  5990. if {_get} is "yes":
  5991. if {muted::%player%::type} is "perm":
  5992. send "&9Punish> &7Shh, you're muted because %{muted::%player%::reason}% by %{muted::%player%::by}% for Permanent."
  5993. stop
  5994. if {muted::%player%::type} is "temp":
  5995. set {_waited} to difference between {muted::%player%::when} and now
  5996. if {_waited} is less than {muted::%player%::time}:
  5997. send "&9Punish> &7Shh, you're muted because %{muted::%player%::reason}% by %{muted::%player%::by}% for &a%{muted::%player%::time}%."
  5998. stop
  5999. if argument 1 is set:
  6000. if argument 2 is set:
  6001. if {mineplex.pref.pm.%arg-1%} is false:
  6002. send "&d%arg-1% has private messaging disabled."
  6003. stop
  6004. loop {mineplex.ignorelist.%player%::*}:
  6005. if loop-value is "%arg-1%":
  6006. send "&9Ignore> &7You are ignoring that player"
  6007. stop
  6008. loop {mineplex.ignorelist.%arg-1%::*}:
  6009. if loop-value is "%player%":
  6010. send "&9Ignore> &7That player is ignoring you"
  6011. stop
  6012. send "&6&l%{_p}% > %arg-1% &e&l%arg-2%"
  6013. send "&6&l%{_p}% > %arg-1% &e&l%arg-2%" to arg-1
  6014. play "NOTE_PLING" to player at volume 0.5
  6015. play "NOTE_PLING" to arg-1 at volume 0.5
  6016. set {mineplex.lastm.%player%} to "%arg-1%" parsed as player
  6017. if {mineplex.rank.%arg-1%} is "&4&lDEV ":
  6018. send "&d%arg-1% is often AFK or minimized, due to plugin development."
  6019. send "&dPlease be patient if they do not reply instantly."
  6020. else:
  6021. send "&9Message> &cErr...something went wrong?"
  6022. else:
  6023. send "&9Message> &cErr...something went wrong?"
  6024.  
  6025. command /ping:
  6026. trigger:
  6027. send "&9Chat> &7PONG!"
  6028.  
  6029. on command:
  6030. command is "minecraft:me":
  6031. send "&9Chat> &7Nope, not allowed!"
  6032. cancel event
  6033.  
  6034. command /me [<string>]:
  6035. aliases: /minecraft:me
  6036. trigger:
  6037. if arg 1 is not set:
  6038. send "&cUsage: /me <action...>"
  6039. else:
  6040. send "&9Chat> &7Nope, not allowed!"
  6041.  
  6042. command /newsconfirm <number>:
  6043. permission: mineplex.admin
  6044. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  6045. trigger:
  6046. mcrjson("%player%", "&9Hub Manager>|| &a[CONFIRM]||ttp:Are you absolutely sure???||cmd:/news delete %arg-1%|| &6News Entry %arg-1% &7deletion?")
  6047.  
  6048. command /news [<string>] [<string>] [<string>]:
  6049. permission: mineplex.admin
  6050. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  6051. trigger:
  6052. if arg 1 is not set:
  6053. send "&9News Manager> &7Available news arguments for this command:"
  6054. send "&6/news list &7Lists (numbered) stored news messages from database. &4Admin"
  6055. send "&6/news add <newsEntry> &7Adds specified news entry string to database at end of table. &4Admin"
  6056. send "&6/news delete ## &7Removes specified (numbered) news entry string from database. &4Admin"
  6057. send "&6/news set ## <newsEntry> &7Updates specified (numbered) news entry string from database. &4Admin"
  6058. send "&4*Please Note: &7Updates to server news entries from the database are on a 4 minute cycle! &4Admin"
  6059. else:
  6060. if arg 1 is "list":
  6061. send "&9Hub Manager> &7Current server news messages:"
  6062. mcrjson("%player%", "&9Hub Manager>|| &c[DELETE]||ttp:Deletes News Entry 1 : %{mineplex.news.line1}%||cmd:/newsconfirm 1|| &6News 1 &7: &f%{mineplex.news.line1}%")
  6063. mcrjson("%player%", "&9Hub Manager>|| &c[DELETE]||ttp:Deletes News Entry 2 : %{mineplex.news.line2}%||cmd:/newsconfirm 2|| &6News 2 &7: &f%{mineplex.news.line2}%")
  6064. mcrjson("%player%", "&9Hub Manager>|| &c[DELETE]||ttp:Deletes News Entry 3 : %{mineplex.news.line3}%||cmd:/newsconfirm 3|| &6News 3 &7: &f%{mineplex.news.line3}%")
  6065. mcrjson("%player%", "&9Hub Manager>|| &c[DELETE]||ttp:Deletes News Entry 4 : %{mineplex.news.line4}%||cmd:/newsconfirm 4|| &6News 4 &7: &f%{mineplex.news.line4}%")
  6066. else if arg 1 is "add":
  6067. if arg 2 is set:
  6068. set {_news} to "%arg-2%"
  6069. if arg 3 is set:
  6070. set {_news} to "%arg-2% %arg-3%"
  6071. replace all "&" with "§" in {_news}
  6072. if {mineplex.news.line1}'s length is 0:
  6073. if {mineplex.mode} is "sql":
  6074. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '1'"
  6075. set {mineplex.news.line1} to {_news}
  6076. send "&9Hub Manager> &7The news entry: &6%{_news}% &7has been added to the database!"
  6077. else if {mineplex.news.line2}'s length is 0:
  6078. if {mineplex.mode} is "sql":
  6079. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '2'"
  6080. set {mineplex.news.line2} to {_news}
  6081. send "&9Hub Manager> &7The news entry: &6%{_news}% &7has been added to the database!"
  6082. else if {mineplex.news.line3}'s length is 0:
  6083. if {mineplex.mode} is "sql":
  6084. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '3'"
  6085. set {mineplex.news.line3} to {_news}
  6086. send "&9Hub Manager> &7The news entry: &6%{_news}% &7has been added to the database!"
  6087. else if {mineplex.news.line4}'s length is 0:
  6088. if {mineplex.mode} is "sql":
  6089. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '4'"
  6090. set {mineplex.news.line4} to {_news}
  6091. send "&9Hub Manager> &7The news entry: &6%{_news}% &7has been added to the database!"
  6092. else:
  6093. send "&9Hub Manager> &c&lNo free news slots!"
  6094. else:
  6095. send "&9Hub Manager> &cYour arguments are inappropriate for this command!"
  6096. else if arg 1 is "delete":
  6097. if arg 2 is set:
  6098. if arg 2 is "1":
  6099. set {mineplex.news.line1} to ""
  6100. if {mineplex.mode} is "sql":
  6101. update "UPDATE `newslist` SET `newsString` = ' ' WHERE newsPosition = '1'"
  6102. send "&9Hub Manager> &7The news entry at position &61 &7has been deleted!"
  6103. else if arg 2 is "2":
  6104. if {mineplex.mode} is "sql":
  6105. update "UPDATE `newslist` SET `newsString` = ' ' WHERE newsPosition = '2'"
  6106. set {mineplex.news.line2} to ""
  6107. send "&9Hub Manager> &7The news entry at position &62 &7has been deleted!"
  6108. else if arg 2 is "3":
  6109. if {mineplex.mode} is "sql":
  6110. update "UPDATE `newslist` SET `newsString` = ' ' WHERE newsPosition = '3'"
  6111. set {mineplex.news.line3} to ""
  6112. send "&9Hub Manager> &7The news entry at position &63 &7has been deleted!"
  6113. else if arg 2 is "4":
  6114. if {mineplex.mode} is "sql":
  6115. update "UPDATE `newslist` SET `newsString` = ' ' WHERE newsPosition = '4'"
  6116. set {mineplex.news.line4} to ""
  6117. send "&9Hub Manager> &7The news entry at position &64 &7has been deleted!"
  6118. else:
  6119. send "&9Hub Manager> &cThe specified new position is invalid!"
  6120. else:
  6121. send "&9Hub Manager> &cYour arguments are inappropriate for this command!"
  6122. else if arg 1 is "set":
  6123. if arg 2 is set:
  6124. if arg 3 is set:
  6125. set {_news} to arg 3
  6126. replace all "&" with "§" in {_news}
  6127. if arg 2 is "1":
  6128. if {mineplex.mode} is "sql":
  6129. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '1'"
  6130. set {mineplex.news.line1} to {_news}
  6131. send "&9Hub Manager> &7The news entry at position &61 &7has been updated to: %{_news}%"
  6132. else if arg 2 is "2":
  6133. if {mineplex.mode} is "sql":
  6134. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '2'"
  6135. set {mineplex.news.line2} to {_news}
  6136. send "&9Hub Manager> &7The news entry at position &62 &7has been updated to: %{_news}%"
  6137. else if arg 2 is "3":
  6138. if {mineplex.mode} is "sql":
  6139. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '3'"
  6140. set {mineplex.news.line3} to {_news}
  6141. send "&9Hub Manager> &7The news entry at position &63 &7has been updated to: %{_news}%"
  6142. else if arg 2 is "4":
  6143. if {mineplex.mode} is "sql":
  6144. update "UPDATE `newslist` SET `newsString` = '%{_news}%' WHERE newsPosition = '4'"
  6145. set {mineplex.news.line4} to {_news}
  6146. send "&9Hub Manager> &7The news entry at position &64 &7has been updated to: %{_news}%"
  6147. else:
  6148. send "&9Hub Manager> &cThe specified new position is invalid!"
  6149. else:
  6150. send "&9Hub Manager> &cYour arguments are inappropriate for this command!"
  6151. else:
  6152. send "&9Hub Manager> &cYour arguments are inappropriate for this command!"
  6153. else:
  6154. send "&9News Manager> &7Available news arguments for this command:"
  6155. send "&6/news list &7Lists (numbered) stored news messages from database. &cAdmin"
  6156. send "&6/news add <newsEntry> &7Adds specified news entry string to database at end of table. &cAdmin"
  6157. send "&6/news delete ## &7Removes specified (numbered) news entry string from database. &cAdmin"
  6158. send "&6/news set ## <newsEntry> &7Updates specified (numbered) news entry string from database. &cAdmin"
  6159. send "&c*Please Note: &7Updates to server news entries from the database are on a 4 minute cycle! &cAdmin"
  6160.  
  6161. command /r [<text>]:
  6162. aliases: /reply
  6163. trigger:
  6164. if {mineplex.disguise.%player%} is set:
  6165. set {_p} to {mineplex.disguise.%player%}
  6166. else:
  6167. set {_p} to player
  6168. if {mineplex.lastm.%player%} is set:
  6169. if argument 1 is set:
  6170. if {mineplex.lastm.%player%} is online:
  6171. send "&6&l%{_p}% > %{mineplex.lastm.%player%}% &e&l%arg-1%"
  6172. send "&6&l%{_p}% > %{mineplex.lastm.%player%}% &e&l%arg-1%" to {mineplex.lastm.%player%}
  6173. else:
  6174. send "&9Message> &e%{mineplex.lastm.%player%}% &7is no longer online!"
  6175. else:
  6176. send "&9Message> &cErr...something went wrong?"
  6177. else:
  6178. send "&9Message> &7You have not messaged anyone recently."
  6179.  
  6180. command /party [<string>] [<player>]:
  6181. aliases: /z
  6182. trigger:
  6183. if argument 1 is not set:
  6184. send "&9Party> &7Listing Party Commands:"
  6185. send "&f/party <Player>: &eJoin/Create/Invite Player"
  6186. send "&f/party leave: &eLeave your current party"
  6187. send "&f/party kick <Player>: &eKick player from your Party"
  6188. send "&f/party info: &eDisplays info on the current Party."
  6189. else:
  6190. if argument 1 is "kick":
  6191. if {party.%player%} is not set:
  6192. message "&9Party> &7You don't have a party"
  6193. else:
  6194. if {party.%player%} is not player:
  6195. message "&9Party> &7You have to be a party leader to do this"
  6196. stop
  6197. if player arg is not set:
  6198. message "&9Party> &7Player needed. /party kick <player>"
  6199. else:
  6200. if {party.%player%::*} doesn't contain player arg:
  6201. message "&9Party> &7The player needs to be in your party"
  6202. stop
  6203. message "&9Party> &7You kicked %player arg% from the party"
  6204. message "&9Party> &7You've been kicked by %player% from his party" to player arg
  6205. loop {party.%player%::*}:
  6206. if loop-value = player arg:
  6207. delete {party.%player%::%loop-index%}
  6208. delete {party.%player arg%}
  6209. delete {party.%player arg%.chat}
  6210. else if arg 1 is "leave":
  6211. if {party.%player%} is not set:
  6212. message "&9Party> &7You don't have a party"
  6213. else:
  6214. if {party.%player%} is player:
  6215. message "&9Party> &7You can't leave if you are the leader. Do /party disband"
  6216. stop
  6217. message "&9Party> &7You left your party"
  6218. message "&9Party> &7%player% left your party" to {party.%player%}
  6219. set {party.%player%.chat} to false
  6220. loop {party.%{party.%player%}%::*}:
  6221. if loop-value = player:
  6222. delete {party.%{party.%player%}%::%loop-index%}
  6223. delete {party.%player%}
  6224. delete {party.%player%.chat}
  6225. else if arg 1 is "disband":
  6226. if {party.%player%} is not set:
  6227. message "&9Party> &cYou don't have a party"
  6228. else:
  6229. if {party.%player%} is not player:
  6230. message "&9Party> &7You have to be a party leader to do this"
  6231. stop
  6232. message "&9Party> &7You disband your party"
  6233. loop {party.%player%::*}:
  6234. loop-value is not player:
  6235. message "&9Party> &7Your party has been disbanded" to loop-value
  6236. delete {party.%loop-value%.chat}
  6237. delete {party.%loop-value%}
  6238. delete {party.%player%}
  6239. delete {party.%player%.chat}
  6240. delete {party.%player%::*}
  6241. else if arg 1 is "info":
  6242. if {party.%player%} is not set:
  6243. message "&9Party> &7You don't have a party"
  6244. else:
  6245. message "&9Party> &7Party Details:"
  6246. message "Party Leader: &7%{party.%player%}%"
  6247. set {_partyMember} to ""
  6248. loop {party.%{party.%player%}%::*}:
  6249. set {_partyMember} to "%{_partyMember}% %loop-value%"
  6250. message "Your Party: &7%{_partyMember}%"
  6251. else:
  6252. set {_mineplex.last.party} to "%arg-1%" parsed as player
  6253. if {_mineplex.last.party} is online:
  6254. if {party.%player%} is set:
  6255. add {_mineplex.last.party} to {party.%player%::*}
  6256. set {party.%player%.chat} to true
  6257. set {party.%arg-1%.chat} to true
  6258. set {party.%{_mineplex.last.party}%} to player
  6259. message "&9Party> &7You invited %{_mineplex.last.party}% to the party."
  6260. else:
  6261. set {party.%player%} to player
  6262. message "&9Party> &7Created a party."
  6263. add player to {party.%player%::*}
  6264. make player execute command "/party %arg-1%"
  6265. else:
  6266. send "&9Party> &7That player is not online."
  6267.  
  6268. command /announce [<text>]:
  6269. permission: mineplex.admin
  6270. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  6271. trigger:
  6272. if argument 1 is set:
  6273. send all players title "&eAnnouncement" with subtitle "&f%arg-1%" for 10 seconds
  6274. broadcast "&9Announcement> &b%arg-1%"
  6275. else:
  6276. send "&9Message> &cErr...something went wrong?"
  6277.  
  6278. command /global [<text>]:
  6279. permission: mineplex.jrdev
  6280. permission message: &9Permissions> &7This requires Permission Rank [&9JR.DEV&7].
  6281. trigger:
  6282. if arg 1 is not set:
  6283. send "&9Message> &cErr...something went wrong?"
  6284. else:
  6285. broadcast "&9Announcement> &b%arg-1%"
  6286.  
  6287. every 3 seconds:
  6288. set {mineplex.lag.avg.1} to tps
  6289. wait 1 second
  6290. set {mineplex.lag.avg.2} to tps
  6291. wait 1 second
  6292. set {mineplex.lag.avg.3} to tps
  6293.  
  6294. command /lag:
  6295. trigger:
  6296. if player has permission "mineplex.jrdev":
  6297. set {_avg} to {mineplex.lag.avg.1} + {mineplex.lag.avg.2} + {mineplex.lag.avg.3}
  6298. set {_avg} to {_avg} / 3
  6299. set {_tps} to tps
  6300. set {_f} to free ram
  6301. set {_m} to max ram
  6302. send "&9LagMeter> &7Live-------&e%{_tps}%"
  6303. send "&9LagMeter> &7Avg--------&e%{_avg}%"
  6304. send "&9LagMeter> &eMEM (RAM)"
  6305. send "&9LagMeter> &7Free-------&e%{_f}%MB"
  6306. send "&9LagMeter> &7Max--------&e%{_m}%MB"
  6307. else:
  6308. send "&9Chat> &7PONG!"
  6309.  
  6310. #Punish Systems/Commands
  6311.  
  6312. function punishWarn(s: player , p: offline player , r: text) :: player:
  6313. send "&9Punish> &7%{_s}% issued a friendly warning to you." to {_p}
  6314. send "&9Punish> &7&lReason: &7%{_r}%" to {_p}
  6315. add 1 to {mineplex.punish.past.warn.%{_p}%}
  6316. loop all players:
  6317. if loop-player has permission "mineplex.trainee":
  6318. send "&9Punish> &7%{_s}% issued a friendly warning to %{_p}%." to loop-player
  6319.  
  6320. function punishReportBan(s: player , p: offline player , r: text) :: player:
  6321. set {banned::%{_p}%} to true
  6322. set {banned::%{_p}%::type} to "report"
  6323. set {banned::%{_p}%::reason} to {_r}
  6324. set {banned::%{_p}%::staff} to {_s}
  6325. set {banned::%{_p}%::now} to now
  6326. setPlayerdata({_p}, "banned", "yes")
  6327. kick {_p} due to "&c&lYou are banned for Permanent by %{_s}%%nl%&f%{banned::%{_player}%::reason}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  6328. add 1 to {mineplex.punish.past.reportban.%{_p}%}
  6329. loop all players:
  6330. if loop-player has permission "mineplex.trainee":
  6331. send "&9Punish> &7%{_s}% report banned %{_p}% for Permanent." to loop-player
  6332.  
  6333. function punishBan(s: player , p: offline player , r: text) :: player:
  6334. set {banned::%{_p}%} to true
  6335. set {banned::%{_p}%::type} to "perm"
  6336. set {banned::%{_p}%::reason} to {_r}
  6337. set {banned::%{_p}%::staff} to {_s}
  6338. set {banned::%{_p}%::now} to now
  6339. setPlayerdata({_p}, "banned", "yes")
  6340. kick {_p} due to "&c&lYou are banned for Permanent by %{_s}%%nl%&f%{banned::%{_p}%::reason}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  6341. add 1 to {mineplex.punish.past.permban.%{_p}%}
  6342. loop all players:
  6343. if loop-player has permission "mineplex.trainee":
  6344. send "&9Punish> &7%{_s}% banned %{_p}% for Permanent." to loop-player
  6345.  
  6346. function punishDTempBan(s: player , p: offline player, r: text, d: number) :: player:
  6347. set {_duration} to "%{_d}% days" parsed as timespan
  6348. set {banned::%{_p}%} to true
  6349. set {banned::%{_p}%::type} to "temp"
  6350. set {banned::%{_p}%::time} to {_duration}
  6351. set {banned::%{_p}%::reason} to {_r}
  6352. set {banned::%{_p}%::staff} to {_s}
  6353. set {banned::%{_p}%::when} to now
  6354. add 1 to {mineplex.punish.past.tempban.%{_p}%}
  6355. setPlayerdata({_p}, "banned", "yes")
  6356. kick {_p} due to "&c&lYou are banned for %{banned::%{_p}%::time}% by %{_s}%%nl%&f%{banned::%{_p}%::reason}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  6357. loop all players:
  6358. if loop-player has permission "mineplex.trainee":
  6359. send "&9Punish> &7%{_s}% banned %{_p}% for %{_duration}%" to loop-player
  6360.  
  6361. function punishHTempBan(s: player , p: offline player, r: text, d: number) :: player:
  6362. set {_duration} to "%{_d}% hours" parsed as timespan
  6363. set {banned::%{_p}%} to true
  6364. set {banned::%{_p}%::type} to "temp"
  6365. set {banned::%{_p}%::time} to {_duration}
  6366. set {banned::%{_p}%::reason} to {_r}
  6367. set {banned::%{_p}%::staff} to {_s}
  6368. set {banned::%{_p}%::when} to now
  6369. setPlayerdata({_p}, "banned", "yes")
  6370. kick {_p} due to "&c&lYou are banned for %{banned::%{_p}%::time}% by %{_s}%%nl%&f%{banned::%{_p}%::reason}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  6371. add 1 to {mineplex.punish.past.tempban.%{_p}%}
  6372. loop all players:
  6373. if loop-player has permission "mineplex.trainee":
  6374. send "&9Punish> &7%{_s}% banned %{_p}% for %{_duration}%" to loop-player
  6375.  
  6376. function punishMute(s: player, p: offline player, r: text) :: player:
  6377. set {muted::%{_p}%} to true
  6378. set {muted::%{_p}%::type} to "perm"
  6379. set {muted::%{_p}%::reason} to {_r}
  6380. set {muted::%{_p}%::by} to {_s}
  6381. add 1 to {mineplex.punish.past.permmute.%{_p}%}
  6382. setPlayerdata({_p}, "muted", "yes")
  6383. send "&9Punish> &7&lReason: &r&7%{_r}%" to {_p}
  6384. send "&9Punish> &7%{muted::%{_p}%::by}% muted %{_p}% for Permanent." to {_p}
  6385. loop all players:
  6386. if loop-player has permission "mineplex.trainee":
  6387. send "&9Punish> &7%{_s}% muted %{_p}% for Permanent." to loop-player
  6388.  
  6389. function punishHTempMute(s: player, p: offline player, r: text, d: number) :: player:
  6390. set {_duration} to "%{_d}% hours" parsed as timespan
  6391. set {muted::%{_p}%} to true
  6392. set {muted::%{_p}%::type} to "temp"
  6393. set {muted::%{_p}%::reason} to {_r}
  6394. set {muted::%{_p}%::time} to {_duration}
  6395. set {muted::%{_p}%::by} to {_s}
  6396. set {muted::%{_p}%::when} to now
  6397. add 1 to {mineplex.punish.past.permmute.%{_p}%}
  6398. setPlayerdata({_p}, "muted", "yes")
  6399. send "&9Punish> &7%{_s}% muted you for %{_duration}%." to {_p}
  6400. send "&9Punish> &7&lReason: &r&7%{_r}%" to {_p}
  6401. loop all players:
  6402. if loop-player has permission "mineplex.trainee":
  6403. send "&9Punish> &7%{_s}% muted %{_p}% for %{_duration}%." to loop-player
  6404.  
  6405. function punishDTempMute(s: player, p: offline player, r: text, d: number) :: player:
  6406. set {_duration} to "%{_d}% days" parsed as timespan
  6407. set {muted::%{_p}%} to true
  6408. set {muted::%{_p}%::type} to "temp"
  6409. set {muted::%{_p}%::reason} to {_r}
  6410. set {muted::%{_p}%::time} to {_duration}
  6411. set {muted::%{_p}%::by} to {_s}
  6412. set {muted::%{_p}%::when} to now
  6413. add 1 to {mineplex.punish.past.permmute.%{_p}%}
  6414. setPlayerdata({_p}, "muted", "yes")
  6415. send "&9Punish> &7%{_s}% muted you for %{_duration}%." to {_p}
  6416. send "&9Punish> &7&lReason: &r&7%{_r}%" to {_p}
  6417. loop all players:
  6418. if loop-player has permission "mineplex.trainee":
  6419. send "&9Punish> &7%{_s}% muted %{_p}% for %{_duration}%." to loop-player
  6420.  
  6421. function punishUnban(s: string, p: string) :: player:
  6422. delete {banned::%{_p}%}
  6423. delete {banned::%{_p}%::*}
  6424. setPlayerdata({_p}, "banned", "no")
  6425.  
  6426. function punishUnmute(s: player, p: string) :: player:
  6427. delete {muted::%{_p}%}
  6428. delete {muted::%{_p}%::*}
  6429. setPlayerdata({_p}, "muted", "no")
  6430. loop all players:
  6431. if loop-player has permission "mineplex.trainee":
  6432. send "&9Punish> &7%{_s}% unmuted %{_p}%" to loop-player
  6433.  
  6434. on connect:
  6435. set {_get} to getPlayerdata(player, "banned")
  6436. if {_get} is "yes":
  6437. if player has permission "mineplex.admin":
  6438. if {mineplex.config.unbanadmin} is "true":
  6439. punishUnban("Expired", "%player%")
  6440. stop
  6441. if {banned::%player%::type} is "perm":
  6442. kick player due to "&c&lYou are banned for Permanent%nl%&f%{banned::%player%::reason}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  6443. stop
  6444. if {banned::%player%::type} is "report":
  6445. kick player due to "&c&lYou are banned for Permanent%nl%&f%{banned::%player%::reason}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  6446. stop
  6447. if {banned::%player%::type} is "temp":
  6448. set {_waited} to difference between {banned::%player%::when} and now
  6449. if {_waited} is less than {banned::%player%::time}:
  6450. kick player due to "&c&lYou are banned for %{banned::%player%::time}%%nl%&f%{banned::%player%::reason}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  6451. else:
  6452. punishUnban("Expired", "%player%")
  6453.  
  6454. on inventory click:
  6455. if inventory name of player's current inventory is " Punish":
  6456. cancel event
  6457. clicked slot >= 45
  6458. set {_clickedslot.%player%} to (clicked slot - 44)
  6459. if {reversed.p.%{punishgui.%player%::1}%::history::%{_clickedslot.%player%}%} is set:
  6460. if "%{reversed.p.%{punishgui.%player%::1}%::history::%{_clickedslot.%player%}%}%" contains "&eRemoved by: ":
  6461. send "" to console
  6462. else:
  6463. set {_reasonchanger.%player%} to "%{reversed.p.%{punishgui.%player%::1}%::history::%{_clickedslot.%player%}%}% ||||&eRemoved by: &f%player%||&eRemove Reason: &f%{punishgui.%player%::2}%"
  6464. set {reversed.p.%{punishgui.%player%::1}%::history::%{_clickedslot.%player%}%} to "%{_reasonchanger.%player%}%"
  6465. close player's inventory
  6466. delete {p.%{punishgui.%player%::1}%::history::*}
  6467. set {_slot} to 0
  6468. loop {reversed.p.%{punishgui.%player%::1}%::history::*}:
  6469. add 1 to {_slot}
  6470. set {_reversedslot} to 1
  6471. loop {reversed.p.%{punishgui.%player%::1}%::history::*}:
  6472. set {p.%{punishgui.%player%::1}%::history::%{_reversedslot}%} to "%{reversed.p.%{punishgui.%player%::1}%::history::%{_slot}%}%"
  6473. remove 1 from {_slot}
  6474. add 1 to {_reversedslot}
  6475. if "%{_reasonchanger.%player%}%" contains "ChatOffense":
  6476. punishUnmute(player, {punishgui.%player%::1})
  6477. if "%{_reasonchanger.%player%}%" contains "Hacking" or "Exploiting" or "Other":
  6478. punishUnban("memes", {punishgui.%player%::1})
  6479. if "%{_reasonchanger.%player%}%" contains "Warning":
  6480. stop
  6481.  
  6482. command /p [<offline player>] [<text>]:
  6483. aliases: /punish
  6484. permission: mineplex.trainee
  6485. permission message: &9Permissions> &7This requires Permission Rank [&9TRAINEE&7].
  6486. trigger:
  6487. if arg-2 is not set:
  6488. send "&9Punish> &7Commands List:"
  6489. send "&6/punish &7<player> <reason> &6Mod"
  6490. if arg-2 is set:
  6491. if {p.%arg-1%::Chat1} is not set:
  6492. set {p.%arg-1%::Client3} to "__mp__tempban__ %arg-1% %player% 30"
  6493. set {p.%arg-1%::ClientL3} to "&fBan Duration: &e30.0 Days"
  6494. set {p.%arg-1%::Client2} to "__mp__tempban__ %arg-1% %player% 30"
  6495. set {p.%arg-1%::ClientL2} to "&fBan Duration: &e30.0 Days"
  6496. set {p.%arg-1%::ClientL1} to "&fBan Duration: &e1.0 Days"
  6497. set {p.%arg-1%::Client1} to "__mp__tempban__ %arg-1% %player% 1"
  6498. set {p.%arg-1%::General} to "__mp__htempban__ %arg-1% 4 %player%"
  6499. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e4.0 Hours"
  6500. set {p.%arg-1%::Chat1} to "__mp__htempmute__ %arg-1% 2 %player%"
  6501. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e2.0 Hours"
  6502. set {p.%arg-1%::Chat2} to "__mp__tempmute__ %arg-1% 1 %player%"
  6503. set {p.%arg-1%::ChatL2} to "&fMute Duration: &e1.0 Days"
  6504. set {p.%arg-1%::Chat3} to "__mp__tempmute__ %arg-1% 30 %player%"
  6505. set {p.%arg-1%::ChatL3} to "&fMute Duration: &e30.0 Days"
  6506. if {p.%arg-1%::pOffences.Chat1} is 1:
  6507. set {p.%arg-1%::Chat1} to "__mp__htempmute__ %arg-1% 4 %player%"
  6508. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e4.0 Hours"
  6509. if {p.%arg-1%::pOffences.Chat1} is 2:
  6510. set {p.%arg-1%::Chat1} to "__mp__htempmute__ %arg-1% 10 %player%"
  6511. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e10.0 Hours"
  6512. if {p.%arg-1%::pOffences.Chat1} is 3:
  6513. set {p.%arg-1%::Chat1} to "__mp__tempmute__ %arg-1% 1 %player%"
  6514. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e1.0 Days"
  6515. if {p.%arg-1%::pOffences.Chat1} is 4:
  6516. set {p.%arg-1%::Chat1} to "__mp__tempmute__ %arg-1% 1 %player%"
  6517. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e1.4 Days"
  6518. if {p.%arg-1%::pOffences.Chat1} is 5:
  6519. set {p.%arg-1%::Chat1} to "__mp__tempmute__ %arg-1% 3 %player%"
  6520. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e2.8 Days"
  6521. if {p.%arg-1%::pOffences.Chat1} is 6:
  6522. set {p.%arg-1%::Chat1} to "__mp__tempmute__ %arg-1% 7 %player%"
  6523. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e7.0 Days"
  6524. if {p.%arg-1%::pOffences.Chat1} is 7:
  6525. set {p.%arg-1%::Chat1} to "__mp__tempmute__ %arg-1% 14 %player%"
  6526. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e14.0 Days"
  6527. if {p.%arg-1%::pOffences.Chat1} is 8:
  6528. set {p.%arg-1%::Chat1} to "__mp__tempmute__ %arg-1% 30 %player%"
  6529. set {p.%arg-1%::ChatL1} to "&fMute Duration: &e30.0 Days"
  6530. if {p.%arg-1%::pOffences.Chat1} is 9:
  6531. set {p.%arg-1%::Chat1} to "__mp__mute__ %arg-1% %player%"
  6532. set {p.%arg-1%::ChatL1} to "&fMute Duration: &ePermanent"
  6533. if {p.%arg-1%::pOffences.Chat2} is 1:
  6534. set {p.%arg-1%::Chat2} to "__mp__tempmute__ %arg-1% 2 %player%"
  6535. set {p.%arg-1%::ChatL2} to "&fMute Duration: &e2.0 Days"
  6536. if {p.%arg-1%::pOffences.Chat2} is 2:
  6537. set {p.%arg-1%::Chat2} to "__mp__tempmute__ %arg-1% 4 %player%"
  6538. set {p.%arg-1%::ChatL2} to "&fMute Duration: &e4.0 Days"
  6539. if {p.%arg-1%::pOffences.Chat2} is 3:
  6540. set {p.%arg-1%::Chat2} to "__mp__tempmute__ %arg-1% 7 %player%"
  6541. set {p.%arg-1%::ChatL2} to "__mp__tempmute__ %arg-1% 7 %player%"
  6542. if {p.%arg-1%::pOffences.Chat2} is 4:
  6543. set {p.%arg-1%::Chat2} to "__mp__tempmute__ %arg-1% 14 %player%"
  6544. set {p.%arg-1%::ChatL2} to "&fMute Duration: &e14.0 Days"
  6545. if {p.%arg-1%::pOffences.Chat2} is 5:
  6546. set {p.%arg-1%::Chat2} to "__mp__tempmute__ %arg-1% 30 %player%"
  6547. set {p.%arg-1%::ChatL2} to "&fMute Duration: &e30.0 Days"
  6548. if {p.%arg-1%::pOffences.Chat2} is 6:
  6549. set {p.%arg-1%::Chat2} to "__mp__mute__ %arg-1% %player%"
  6550. set {p.%arg-1%::ChatL2} to "&fMute Duration: &ePermanent"
  6551. if {p.%arg-1%::pOffences.Chat3} is 1:
  6552. set {p.%arg-1%::Chat3} to "__mp__mute__ %arg-1% %player%"
  6553. set {p.%arg-1%::ChatL3} to "&fMute Duration: &ePermanent"
  6554. if {p.%arg-1%::pOffences.General} is 1:
  6555. set {p.%arg-1%::General} to "__mp__htempban__ %arg-1% %player% 8"
  6556. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e8.0 Hours"
  6557. if {p.%arg-1%::pOffences.General} is 2:
  6558. set {p.%arg-1%::General} to "__mp__htempban__ %arg-1% %player% 16"
  6559. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e16.0 Hours"
  6560. if {p.%arg-1%::pOffences.General} is 3:
  6561. set {p.%arg-1%::General} to "__mp__tempban__ %arg-1% %player% 1"
  6562. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e1.4 Days"
  6563. if {p.%arg-1%::pOffences.General} is 4:
  6564. set {p.%arg-1%::General} to "__mp__tempban__ %arg-1% %player% 3"
  6565. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e3.0 Days"
  6566. if {p.%arg-1%::pOffences.General} is 5:
  6567. set {p.%arg-1%::General} to "__mp__tempban__ %arg-1% %player% 7"
  6568. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e7.0 Days"
  6569. if {p.%arg-1%::pOffences.General} is 6:
  6570. set {p.%arg-1%::General} to "__mp__tempban__ %arg-1% %player% 14"
  6571. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e14.0 Days"
  6572. if {p.%arg-1%::pOffences.General} is 7:
  6573. set {p.%arg-1%::General} to "__mp__tempban__ %arg-1% %player% 30"
  6574. set {p.%arg-1%::GeneralL} to "&fBan Duration: &e30.0 Days"
  6575. if {p.%arg-1%::pOffences.General} is 8:
  6576. set {p.%arg-1%::General} to "__mp__ban__ %arg-1% %player%"
  6577. set {p.%arg-1%::GeneralL} to "&fBan Duration: &ePermanent"
  6578.  
  6579. if {p.%arg-1%::pOffences.Client1} is 1:
  6580. set {p.%arg-1%::Client1} to "__mp__tempban__ %arg-1% %player% 2"
  6581. set {p.%arg-1%::ClientL1} to "&fBan Duration: &e2.0 Days"
  6582. if {p.%arg-1%::pOffences.Client1} is 2:
  6583. set {p.%arg-1%::Client1} to "__mp__tempban__ %arg-1% %player% 4"
  6584. set {p.%arg-1%::ClientL1} to "&fBan Duration: &e4.0 Days"
  6585. if {p.%arg-1%::pOffences.Client1} is 3:
  6586. set {p.%arg-1%::Client1} to "__mp__tempban__ %arg-1% %player% 7"
  6587. set {p.%arg-1%::ClientL1} to "&fBan Duration: &e7.0 Days"
  6588. if {p.%arg-1%::pOffences.Client1} is 4:
  6589. set {p.%arg-1%::Client1} to "__mp__tempban__ %arg-1% %player% 16"
  6590. set {p.%arg-1%::ClientL1} to "&fBan Duration: &e16.0 Days"
  6591. if {p.%arg-1%::pOffences.Client1} is 5:
  6592. set {p.%arg-1%::Client1} to "__mp__tempban__ %arg-1% %player% 30"
  6593. set {p.%arg-1%::ClientL1} to "&fBan Duration: &e30.0 Days"
  6594. if {p.%arg-1%::pOffences.Client1} is 6:
  6595. set {p.%arg-1%::Client1} to "__mp__ban__ %arg-1% %player%"
  6596. set {p.%arg-1%::ClientL1} to "&fBan Duration: &ePermanent"
  6597. if {p.%arg-1%::pOffences.Client2} is 1:
  6598. set {p.%arg-1%::Client2} to "__mp__ban__ %arg-1% %player%"
  6599. set {p.%arg-1%::ClientL2} to "&fBan Duration: &ePermanent"
  6600. if {p.%arg-1%::pOffences.Client3} is 1:
  6601. set {p.%arg-1%::Client3} to "__mp__ban__ %arg-1% %player%"
  6602. set {p.%arg-1%::ClientL3} to "&fBan Duration: &ePermanent"
  6603. if {p.%arg-1%::pOffences.Chat1} is not set:
  6604. set {p.%arg-1%::pOffences.Chat1} to 0
  6605. set {p.%arg-1%::pOffences.Chat2} to 0
  6606. set {p.%arg-1%::pOffences.Chat3} to 0
  6607. set {p.%arg-1%::pOffences.General} to 0
  6608. set {p.%arg-1%::pOffences.Client1} to 0
  6609. set {p.%arg-1%::pOffences.Client2} to 0
  6610. set {p.%arg-1%::pOffences.Client3} to 0
  6611. if player has permission "mineplex.trainee" or "mineplex.mod":
  6612. delete {reversed.p.%arg-1%::history::*}
  6613. set {_slot} to 0
  6614. loop {p.%arg-1%::history::*}:
  6615. add 1 to {_slot}
  6616. set {_reversedslot} to 1
  6617. loop {p.%arg-1%::history::*}:
  6618. set {reversed.p.%arg-1%::history::%{_reversedslot}%} to "%{p.%arg-1%::history::%{_slot}%}%"
  6619. remove 1 from {_slot}
  6620. add 1 to {_reversedslot}
  6621. open chest with 6 rows named " Punish" to player
  6622. wait 1 tick
  6623. format slot 4 of player with arg-1's skull named "&a&l%arg-1%" with lore "&r%arg-2%" to be unstealable
  6624.  
  6625. format slot 10 of player with book and quill named "&a&lChat Offense" with lore "&7Verbal Abuse, Spam, Harrassment, Trolling, etc" to be unstealable
  6626. format slot 19 of player with cactus green named "&a&lSeverity 1" with lore "&fPast Offences: &e%{p.%arg-1%::pOffences.Chat1}%||%{p.%arg-1%::ChatL1}%||||&7Light Spam||&f Sending the same message 2-5 times||||&7Light Advertising||&f 'anyone want to play on minecade?'||||&7Light Abuse/Harassment||&f 'you suck at this game'||||&7Hackusations||&f 'you're such a hacker!'||||&7Trolling||||&2Give Warning if 0 Past Offences and 0 Warnings." to close then run [punishHTempMute(sender, arg-1, arg-2, 4)]->[add "&ePunishment Type: &fChatOffense||&eSeverity: &f1||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]->[add 1 to {p.%arg-1%::pOffences.Chat1}]
  6627.  
  6628. format slot 12 of player with hopper named "&a&lGeneral Offense" with lore "&7Command/Map/Class/Skill exploits, etc" to be unstealable
  6629. format slot 21 of player with cactus green named "&a&lSeverity 1" with lore "&fPast Offences: &e%{p.%arg-1%::pOffences.General}%||%{p.%arg-1%::GeneralL}%||||&7Team Killing||&f Intentionally killing your team mates||||&7Trolling (Gameplay)||&f Using abilities to trap players in spawn||||&7Map/Bug Exploiting||&f Abusing an exploit to gain an advantage" to close then run [punishHTempBan(sender, arg-1, arg-2, 8)]->[add "&ePunishment Type: &fExploiting||&eSeverity: &f1||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]->[add 1 to {p.%arg-1%::pOffences.General}]
  6630. format slot 14 of player with iron sword named "&a&lClient Mod" with lore "&7X-ray, Forcefield, Speed, Fly, Inventory Hacks, etc" to be unstealable
  6631. format slot 23 of player with cactus green named "&a&lSeverity 1" with lore "&fPast Offences: &e%{p.%arg-1%::pOffences.Client1}%||%{p.%arg-1%::ClientL1}%||||&7Examples;||&f Damage Indicators||&f Player Radar" to close then run [punishDTempBan(sender, arg-1, arg-2, 1)]->[add "&ePunishment Type: &fHacking||&eSeverity: &f1||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]->[add 1 to {p.%arg-1%::pOffences.Client1}]
  6632. format slot 25 of player with paper named "&a&lWarning" with lore "||&7Example Warning Input;||&f Spam - Repeatedly writing MEOW||&f Swearing - Saying 'fuck' and 'shit'||&f Hack Accusation - Accused Tomp13 of hacking||&f Trolling - was trying to make bob angry in chat" to close then run [punishWarn(sender, arg-1, arg-2)]->[add "&ePunishment Type: &fWarning||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]
  6633. if player has permission "mineplex.mod": #Access all punishments!
  6634. format slot 28 of player with dandelion yellow named "&a&lSeverity 2" with lore "&fPast Offences: &e%{p.%arg-1%::pOffences.Chat2}%||%{p.%arg-1%::ChatL2}%||||&7Medium Spam|| &fSending the same message 6-20 times||||&7Medium Advertising;|| &f'join crap.server.net' - posted once||||&7Medium Abuse/Harassment|| &f'piss off you stupid newb'|| &f'SHIT ADMINS ARE SHIT!!!'|| &f'you're terrible, learn to play'||||&7Avoiding Chat Filter|| &f'F|_|<K YOU'" to close then run [punishDTempMute(sender, arg-1, arg-2, 2)]->[add "&ePunishment Type: &fChatOffense||&eSeverity: &f2||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]->[add 1 to {p.%arg-1%::pOffences.Chat2}]
  6635. format slot 37 of player with rose red named "&a&lSeverity 3" with lore "&fPast Offences: &e%{p.%arg-1%::pOffences.Chat3}%||%{p.%arg-1%::ChatL3}%||||&7Severe Spam|| &fSending the same message 20+ times|| &fOnly really used for a spam bot||||&7Severe Abuse/Harassment|| &f'go fucking die in a fire you fucking sack of shit'" to close then run [punishMute(sender, arg-1, arg-2)]->[add "&ePunishment Type: &fChatOffense||&eSeverity: &f3||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]->[add 1 to {p.%arg-1%::pOffences.Chat3}]
  6636.  
  6637. format slot 32 of player with dandelion yellow named "&a&lSeverity 2" with lore "&fPast Offences: &e%{p.%arg-1%::pOffences.Client2}%||%{p.%arg-1%::ClientL2}%||||&7Hacks;|| &fForcefield|| &fSpeed Hack|| &fReach Hack|| &fOther Hack||||&7Hack Reports (SR & FR);|| &fForcefield|| &fSpeed Hack|| &fReach Hack|| &fOther Hack|| &fFly Hack" to close then run [punishDTempBan(sender, arg-1, arg-2, 30)]->[add "&ePunishment Type: &fHacking||&eSeverity: &f2||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]->[add 1 to {p.%arg-1%::pOffences.Client2}]
  6638. format slot 41 of player with rose red named "&a&lSeverity 3" with lore "&fPast Offences: &e%{p.%arg-1%::pOffences.Client3}%||%{p.%arg-1%::ClientL3}%||||&7Hacks:|| &fFly Hack||||&c&lWARNING;||&cUse Severity 2 for Forum/Staff Reports" to close then run [punishDTempBan(sender, arg-1, arg-2, 30)]->[add "&ePunishment Type: &fHacking||&eSeverity: &f3||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]->[add 1 to {p.%arg-1%::pOffences.Client3}]
  6639.  
  6640. format slot 43 of player with book and quill named "&a&lPermanent Mute" with lore "&fMute Duration: &ePermanent||||&7Severe Advertising;||&f 'JOIN MINECADE! THIS SUCKS!||&f 'join crap.server.net! FREE ADMIN!||||&2Must supply detailed reason for Mute." to close then run [punishMute(sender, arg-1, arg-2)]->[add "&ePunishment Type: &fChatOffense||&eSeverity: &f4||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]
  6641. format slot 34 of player with redstone block named "&a&lPermanent Ban" with lore "&fBan Duration: &ePermanent||||&2Must supply detailed reason for Ban." to close then run [punishBan(sender, arg-1, arg-2)]->[add "&ePunishment Type: &fOther||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]
  6642. format slot 26 of player with enchanted book named "&a&lPermanent Report Ban" with lore "&fReport Ban Duration: &ePermanent||||&7Abusing Report Feature|| &r/report SomeUser THE STAFF HERE SUCK|| &r/report SomeUser MINEPLEX IS A F****** PIECE OF S***" to close then run [punishReportBan(sender, arg-1, arg-2)]->[add "&ePunishment Type: &rOther||||&eReason: &f%arg-2%||||&eStaff: &f%player%||||&eDate: &f%now%" to {p.%arg-1%::history::*}]
  6643. set {_banned} to getPlayerdata(arg-1, "banned")
  6644. set {_muted} to getPlayerdata(arg-1, "muted")
  6645. set {_slot} to 45
  6646. loop {reversed.p.%arg-1%::history::*}:
  6647. set {punishgui.%player%::*} to "%arg 1%"
  6648. add "%arg 2%" to {punishgui.%player%::*}
  6649. if "%loop-value%" contains "&ePunishment Type: &fChatOffense":
  6650. if {_muted} is true:
  6651. if "%loop-value%" does not contain "&eRemoved by: ":
  6652. set slot {_slot} of player's current inventory to shiny book and quill named "&a&lChat Offense" with lore "%loop-value%"
  6653. add 1 to {_slot}
  6654. else:
  6655. set slot {_slot} of player's current inventory to book and quill named "&a&lChat Offense" with lore "%loop-value%"
  6656. add 1 to {_slot}
  6657. else:
  6658. set slot {_slot} of player's current inventory to book and quill named "&a&lChat Offense" with lore "%loop-value%"
  6659. add 1 to {_slot}
  6660. if "%loop-value%" contains "&ePunishment Type: &fHacking":
  6661. if {_banned} is true:
  6662. if "%loop-value%" does not contain "&eRemoved by: ":
  6663. set slot {_slot} of player's current inventory to shiny iron sword named "&a&lClient Mod" with lore "%loop-value%"
  6664. add 1 to {_slot}
  6665. else:
  6666. set slot {_slot} of player's current inventory to shiny iron sword named "&a&lClient Mod" with lore "%loop-value%"
  6667. add 1 to {_slot}
  6668. else:
  6669. set slot {_slot} of player's current inventory to iron sword named "&a&lClient Mod" with lore "%loop-value%"
  6670. add 1 to {_slot}
  6671. if "%loop-value%" contains "&ePunishment Type: &fExploiting":
  6672. if {_banned} is true:
  6673. if "%loop-value%" does not contain "&eRemoved by: ":
  6674. set slot {_slot} of player's current inventory to shiny hopper named "&a&lGeneral Offense" with lore "%loop-value%"
  6675. add 1 to {_slot}
  6676. else:
  6677. set slot {_slot} of player's current inventory to hopper named "&a&lGeneral Offense" with lore "%loop-value%"
  6678. add 1 to {_slot}
  6679. else:
  6680. set slot {_slot} of player's current inventory to hopper named "&a&lGeneral Offense" with lore "%loop-value%"
  6681. add 1 to {_slot}
  6682. if "%loop-value%" contains "&ePunishment Type: &fWarning":
  6683. set slot {_slot} of player's current inventory to paper named "&a&lWarning" with lore "%loop-value%"
  6684. add 1 to {_slot}
  6685. if "%loop-value%" contains "&ePunishment Type: &fOther":
  6686. if {_banned} is true:
  6687. if "%loop-value%" does not contain "&eRemoved by: ":
  6688. set slot {_slot} of player's current inventory to shiny redstone block named "&a&lPermanent Ban" with lore "%loop-value%"
  6689. add 1 to {_slot}
  6690. else:
  6691. set slot {_slot} of player's current inventory to redstone block named "&a&lPermanent Ban" with lore "%loop-value%"
  6692. add 1 to {_slot}
  6693. else:
  6694. set slot {_slot} of player's current inventory to redstone block named "&a&lPermanent Ban" with lore "%loop-value%"
  6695. add 1 to {_slot}
  6696. if "%loop-value%" contains "&ePunishment Type: &rOther":
  6697. set slot {_slot} of player's current inventory to enchanted book named "&a&lPermanent Report Ban" with lore "%loop-value%"
  6698. add 1 to {_slot}
  6699. if {_slot} = 54:
  6700. exit loop
  6701. if {mineplex.rank.%player%} is "&6&LJR.DEV " or "&4&lDEV ":
  6702. format slot 0 of player with shiny dandelion named "&a&lDEV WARNING" with lore "&rDevelopers are advised against using the punish system||&runless permitted by LT" to be unstealable
  6703.  
  6704. #Prefs System
  6705.  
  6706. function prefsSystem(p: player , t: number) :: number:
  6707. if {_t} is 1:
  6708. if {mineplex.pref.hg.%{_p}%} is true:
  6709. set {mineplex.pref.hg.%{_p}%} to false
  6710. else:
  6711. set {mineplex.pref.hg.%{_p}%} to true
  6712. else if {_t} is 2:
  6713. if {mineplex.pref.hpv.%{_p}%} is true:
  6714. set {mineplex.pref.hpv.%{_p}%} to false
  6715. hide all players from {_p}
  6716. else:
  6717. set {mineplex.pref.hpv.%{_p}%} to true
  6718. reveal all players from {_p}
  6719. loop all players:
  6720. if {mineplex.vanish.%loop-player%} is true:
  6721. add loop-player to {%{_p}%.vanishlist::*}
  6722. loop all players:
  6723. if loop-player does not have permission "mineplex.admin":
  6724. hide {%{_p}%.vanishlist::*} from all players
  6725. delete {%{_p}%.vanishlist::*}
  6726. else if {_t} is 3:
  6727. if {mineplex.pref.pc.%{_p}%} is true:
  6728. set {mineplex.pref.pc.%{_p}%} to false
  6729. else:
  6730. set {mineplex.pref.pc.%{_p}%} to true
  6731. else if {_t} is 4:
  6732. if {mineplex.pref.pm.%{_p}%} is true:
  6733. set {mineplex.pref.pm.%{_p}%} to false
  6734. else:
  6735. set {mineplex.pref.pm.%{_p}%} to true
  6736. else if {_t} is 5:
  6737. if {mineplex.pref.gwen.%{_p}%} is true:
  6738. set {mineplex.pref.gwen.%{_p}%} to false
  6739. else:
  6740. set {mineplex.pref.gwen.%{_p}%} to true
  6741. else if {_t} is 6:
  6742. if {mineplex.pref.report.%{_p}%} is true:
  6743. set {mineplex.pref.report.%{_p}%} to false
  6744. else:
  6745. set {mineplex.pref.report.%{_p}%} to true
  6746. else if {_t} is 7:
  6747. if {mineplex.pref.ff.%{_p}%} is true:
  6748. set {mineplex.pref.ff.%{_p}%} to false
  6749. else:
  6750. set {mineplex.pref.ff.%{_p}%} to true
  6751. else if {_t} is 8:
  6752. if {mineplex.ff.%{_p}%} is true:
  6753. set {mineplex.ff.%{_p}%} to false
  6754. delete {mineplex.ff.list::%{_p}%}
  6755. else:
  6756. set {mineplex.ff.%{_p}%} to true
  6757. set {mineplex.ff.list::%{_p}%} to true
  6758. else if {_t} is 9:
  6759. if {mineplex.pref.rm.%{_p}%} is true:
  6760. set {mineplex.pref.rm.%{_p}%} to false
  6761. else:
  6762. set {mineplex.pref.rm.%{_p}%} to true
  6763. else if {_t} is 10:
  6764. if {mineplex.pref.aj.%{_p}%} is true:
  6765. set {mineplex.pref.aj.%{_p}%} to false
  6766. else:
  6767. set {mineplex.pref.aj.%{_p}%} to true
  6768. else if {_t} is 11:
  6769. if {mineplex.pref.daw.%{_p}%} is true:
  6770. set {mineplex.pref.daw.%{_p}%} to false
  6771. else:
  6772. set {mineplex.pref.daw.%{_p}%} to true
  6773. else if {_t} is 12:
  6774. if {mineplex.pref.cj.%{_p}%} is true:
  6775. set {mineplex.pref.cj.%{_p}%} to false
  6776. else:
  6777. set {mineplex.pref.cj.%{_p}%} to true
  6778. else if {_t} is 13:
  6779. if {mineplex.pref.sct.%{_p}%} is true:
  6780. set {mineplex.pref.sct.%{_p}%} to false
  6781. else:
  6782. set {mineplex.pref.sct.%{_p}%} to true
  6783. else if {_t} is 14:
  6784. if {mineplex.pref.hm.%{_p}%} is true:
  6785. set {mineplex.pref.hm.%{_p}%} to false
  6786. else:
  6787. set {mineplex.pref.hm.%{_p}%} to true
  6788. else if {_t} is 15:
  6789. if {mineplex.pref.pr.%{_p}%} is true:
  6790. set {mineplex.pref.pr.%{_p}%} to false
  6791. else:
  6792. set {mineplex.pref.pr.%{_p}%} to true
  6793. else if {_t} is 16:
  6794. if {mineplex.pref.spfr.%{_p}%} is true:
  6795. set {mineplex.pref.spfr.%{_p}%} to false
  6796. else:
  6797. set {mineplex.pref.spfr.%{_p}%} to true
  6798. else if {_t} is 17:
  6799. if {mineplex.pref.dfg.%{_p}%} is true:
  6800. set {mineplex.pref.dfg.%{_p}%} to false
  6801. else:
  6802. set {mineplex.pref.dfg.%{_p}%} to true
  6803. else if {_t} is 18:
  6804. if {mineplex.pref.sci.%{_p}%} is true:
  6805. set {mineplex.pref.sci.%{_p}%} to false
  6806. else:
  6807. set {mineplex.pref.sci.%{_p}%} to true
  6808. else if {_t} is 19:
  6809. if {mineplex.pref.dpg.%{_p}%} is true:
  6810. set {mineplex.pref.dpg.%{_p}%} to false
  6811. else:
  6812. set {mineplex.pref.dpg.%{_p}%} to true
  6813. else if {_t} is 20:
  6814. if {mineplex.pref.hif.%{_p}%} is true:
  6815. set {mineplex.pref.hif.%{_p}%} to false
  6816. else:
  6817. set {mineplex.pref.hif.%{_p}%} to true
  6818.  
  6819. function profile_system(arg1: text , arg2: text , p: player, p2: player) :: number:
  6820. set {_wither} to "MHF_WSkeleton" parsed as a player
  6821. if {_arg1} is "menu":
  6822. if {_arg2} is "profile":
  6823. wait 2 ticks
  6824. open chest with 3 rows named "My Profile" to {_p}
  6825. wait 4 ticks
  6826. format slot 11 of {_p} with {_p}'s skull named "&eStats and Achievements" with lore "&f||&fView your Statistics and Achievements||&ffor all of the games on Mineplex!||&f||&fType &a/stats &fto access this anywhere!" to run [profile_system("menu", "stats", {_p}, {_p2})]
  6827. format slot 13 of {_p} with redstone comparator item named "&ePreferences" with lore "&f||&fSet your preferences to your liking||&fso you can enjoy the game more!||&f||&fType &a/prefs &fto access this anywhere!" to run [profile_system("menu", "prefs", {_p}, {_p2})]
  6828. format slot 15 of {_p} with glistering melon named "&eMineplex Player Server" with lore "&f||&fCreate a server where you are the Host.||&fYou can Choose the game, map and much more!||&f||&fType &a/mps &fto access this anywhere!" to be unstealable
  6829. if {_arg2} is "prefs":
  6830. if {_p} has permission "mineplex.trainee":
  6831. open chest with 6 rows named "My Preferences" to {_p}
  6832. wait 3 tick
  6833. format slot 0 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6834. format slot 1 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6835. format slot 2 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6836. format slot 3 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6837. format slot 4 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6838. format slot 5 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6839. format slot 6 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6840. format slot 7 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6841. format slot 8 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6842. format slot 9 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6843. format slot 17 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6844. format slot 18 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6845. format slot 26 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6846. format slot 27 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6847. format slot 35 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6848. format slot 36 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6849. format slot 44 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6850. format slot 45 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6851. format slot 46 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6852. format slot 47 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6853. format slot 48 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6854. format slot 49 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6855. format slot 50 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6856. format slot 51 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6857. format slot 52 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6858. format slot 53 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6859. format slot 19 of {_p} with paper named "&eUser Preferences" to run [profile_system("menu", "user", {_p}, {_p2})]
  6860. format slot 21 of {_p} with diamond named "&eExclusive Preferences" to run [profile_system("menu", "staff", {_p}, {_p2})]
  6861. format slot 23 of {_p} with redstone comparator item named "&eGame Mechanic Preferences" to run [profile_system("menu", "game", {_p}, {_p2})]
  6862. format slot 25 of {_p} with compass named "&eMiscellaneous Preferences" to run [profile_system("menu", "misc", {_p}, {_p2})]
  6863. format slot 31 of {_p} with red flower named "&eSocial Preferences" to run [profile_system("menu", "social", {_p}, {_p2})]
  6864. else:
  6865. open chest with 5 rows named "My Preferences" to {_p}
  6866. wait 3 tick
  6867. format slot 0 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6868. format slot 1 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6869. format slot 2 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6870. format slot 3 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6871. format slot 4 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6872. format slot 5 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6873. format slot 6 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6874. format slot 7 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6875. format slot 8 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6876. format slot 9 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6877. format slot 17 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6878. format slot 18 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6879. format slot 26 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6880. format slot 27 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6881. format slot 35 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6882. format slot 36 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6883. format slot 37 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6884. format slot 38 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6885. format slot 39 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6886. format slot 40 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6887. format slot 41 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6888. format slot 42 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6889. format slot 43 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6890. format slot 44 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6891. format slot 19 of {_p} with paper named "&eUser Preferences" to run [profile_system("menu", "user", {_p}, {_p2})]
  6892. format slot 21 of {_p} with redstone comparator item named "&eGame Mechanic Preferences" to run [profile_system("menu", "game", {_p}, {_p2})]
  6893. format slot 23 of {_p} with compass named "&eMiscellaneous Preferences" to run [profile_system("menu", "misc", {_p}, {_p2})]
  6894. format slot 25 of {_p} with red flower named "&eSocial Preferences" to run [profile_system("menu", "social", {_p}, {_p2})]
  6895. if {_arg2} is "user":
  6896. open chest with 6 rows named "User Preferences" to {_p}
  6897. wait 3 tick
  6898. format slot 0 of {_p} with bed item named "&7← Go Back" to run [profile_system("menu", "prefs", {_p}, {_p2})]
  6899. format slot 1 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6900. format slot 2 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6901. format slot 3 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6902. format slot 4 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6903. format slot 5 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6904. format slot 6 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6905. format slot 7 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6906. format slot 8 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6907. format slot 9 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6908. format slot 17 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6909. format slot 18 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6910. format slot 26 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6911. format slot 27 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6912. format slot 35 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6913. format slot 36 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6914. format slot 44 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6915. format slot 45 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6916. format slot 46 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6917. format slot 47 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6918. format slot 48 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6919. format slot 49 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6920. format slot 50 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6921. format slot 51 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6922. format slot 52 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6923. format slot 53 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6924. if {mineplex.pref.hg.%{_p}%} is true:
  6925. format slot 10 of {_p} with fire charge named "&aHub Games" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 1)]->[profile_system("menu", "user", {_p}, {_p2})]
  6926. format slot 19 of {_p} with light green dye named "&aHub Games" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 1)]->[profile_system("menu", "user", {_p}, {_p2})]
  6927. else:
  6928. format slot 10 of {_p} with fire charge named "&cHub Games" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 1)]->[profile_system("menu", "user", {_p}, {_p2})]
  6929. format slot 19 of {_p} with gray dye named "&cHub Games" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 1)]->[profile_system("menu", "user", {_p}, {_p2})]
  6930. if {mineplex.pref.hpv.%{_p}%} is true:
  6931. format slot 12 of {_p} with eye of ender named "&aHub Player Visibility" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 2)]->[profile_system("menu", "user", {_p}, {_p2})]
  6932. format slot 21 of {_p} with light green dye named "&aHub Player Visibility" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 2)]->[profile_system("menu", "user", {_p}, {_p2})]
  6933. else:
  6934. format slot 12 of {_p} with eye of ender named "&cHub Player Visibility" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 2)]->[profile_system("menu", "user", {_p}, {_p2})]
  6935. format slot 21 of {_p} with gray dye named "&cHub Player Visibility" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 2)]->[profile_system("menu", "user", {_p}, {_p2})]
  6936. if {mineplex.pref.pc.%{_p}%} is true:
  6937. format slot 14 of {_p} with paper named "&aPlayer Chat" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 3)]->[profile_system("menu", "user", {_p}, {_p2})]
  6938. format slot 23 of {_p} with light green dye named "&aPlayer Chat" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 3)]->[profile_system("menu", "user", {_p}, {_p2})]
  6939. else:
  6940. format slot 14 of {_p} with paper named "&cPlayer Chat" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 3)]->[profile_system("menu", "user", {_p}, {_p2})]
  6941. format slot 23 of {_p} with gray dye named "&cPlayer Chat" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 3)]->[profile_system("menu", "user", {_p}, {_p2})]
  6942. if {mineplex.pref.pm.%{_p}%} is true:
  6943. format slot 16 of {_p} with map named "&aPrivate Messaging" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 4)]->[profile_system("menu", "user", {_p}, {_p2})]
  6944. format slot 25 of {_p} with light green dye named "&aPrivate Messaging" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 4)]->[profile_system("menu", "user", {_p}, {_p2})]
  6945. else:
  6946. format slot 16 of {_p} with map named "&CPrivate Messaging" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 4)]->[profile_system("menu", "user", {_p}, {_p2})]
  6947. format slot 25 of {_p} with gray dye named "&cPrivate Messaging" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 4)]->[profile_system("menu", "user", {_p}, {_p2})]
  6948. if {mineplex.pref.rm.%{_p}%} is true:
  6949. format slot 31 of {_p} with command block named "&aSend random messages" with lore "&aEnabled||&f||&fClick to Disable||&f||&7Got nothing to say? We got you covered!" to run [prefsSystem({_p}, 9)]->[profile_system("menu", "user", {_p}, {_p2})]
  6950. format slot 40 of {_p} with light green dye named "&aSend random messages" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 9)]->[profile_system("menu", "user", {_p}, {_p2})]
  6951. else:
  6952. format slot 31 of {_p} with command block named "&cSend random messages" with lore "&cDisabled||&f||&fClick to Enable||&f||&7Got nothing to say? We got you covered!" to run [prefsSystem({_p}, 9)]->[profile_system("menu", "user", {_p}, {_p2})]
  6953. format slot 40 of {_p} with gray dye named "&cSend random messages" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 9)]->[profile_system("menu", "user", {_p}, {_p2})]
  6954. if {_arg2} is "game":
  6955. open chest with 6 rows named "Game Mechanic Preference" to {_p}
  6956. wait 3 tick
  6957. format slot 0 of {_p} with bed item named "&7← Go Back" to run [profile_system("menu", "prefs", {_p}, {_p2})]
  6958. format slot 1 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6959. format slot 2 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6960. format slot 3 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6961. format slot 4 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6962. format slot 5 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6963. format slot 6 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6964. format slot 7 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6965. format slot 8 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6966. format slot 9 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6967. format slot 17 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6968. format slot 18 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6969. format slot 26 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6970. format slot 27 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6971. format slot 35 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6972. format slot 36 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6973. format slot 44 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6974. format slot 45 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6975. format slot 46 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6976. format slot 47 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6977. format slot 48 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6978. format slot 49 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6979. format slot 50 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6980. format slot 51 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6981. format slot 52 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6982. format slot 53 of {_p} with light blue stained glass pane named "&f" to be unstealable
  6983. if {mineplex.pref.aj.%{_p}%} is true:
  6984. format slot 11 of {_p} with diamond sword named "&aAuto Join Next Game" with lore "&aEnabled||&f||&fClick to Disable||&f||&7Feel like playing again?||&7Enable this, and when you're you||&7a 15 second timer will start||&7when it ends, it'll send you||&7to another game!" to run [prefsSystem({_p}, 10)]->[profile_system("menu", "game", {_p}, {_p2})]
  6985. format slot 20 of {_p} with light green dye named "&aAuto Join Next Game" with lore "&aEnabled||&f||&fClick to Disable||" to run [prefsSystem({_p}, 10)]->[profile_system("menu", "game", {_p}, {_p2})]
  6986. else:
  6987. format slot 11 of {_p} with diamond sword named "&cAuto Join Next Game" with lore "&cDisabled||&f||&fClick to Enable||&f||&7Feel like playing again?||&7Enable this, and when you're you||&7a 15 second timer will start||&7when it ends, it'll send you||&7to another game!" to run [prefsSystem({_p}, 10)]->[profile_system("menu", "game", {_p}, {_p2})]
  6988. format slot 20 of {_p} with gray dye named "&cAuto Join Next Game" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 10)]->[profile_system("menu", "game", {_p}, {_p2})]
  6989. if {mineplex.pref.daw.%{_p}%} is true:
  6990. format slot 13 of {_p} with barrier named "&aDisable Automatic Warning" with lore "&aEnabled||&f||&fClick to Disable||&f||&7Know what you're doing?||&7Disable this to not receive||&7a message warning you about Auto-Join" to run [prefsSystem({_p}, 11)]->[profile_system("menu", "game", {_p}, {_p2})]
  6991. format slot 22 of {_p} with light green dye named "&aDisable Automatic Warning" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 11)]->[profile_system("menu", "game", {_p}, {_p2})]
  6992. else:
  6993. format slot 13 of {_p} with barrier named "&cDisable Automatic Warning" with lore "&cDisabled||&f||&fClick to Enable||&f||&7Know what you're doing?||&7Disable this to not receive||&7a message warning you about Auto-Join" to run [prefsSystem({_p}, 11)]->[profile_system("menu", "game", {_p}, {_p2})]
  6994. format slot 22 of {_p} with gray dye named "&cDisable Automatic Warning" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 11)]->[profile_system("menu", "game", {_p}, {_p2})]
  6995. if {mineplex.pref.cj.%{_p}%} is true:
  6996. format slot 15 of {_p} with clock named "&aCountdown to Join" with lore "&aEnabled||&f||&fClick to Disable||&f||&7See that fancy text when you're out?||&7If you click it, and this is enabled||&7a 15 second time will countdown||&7until you are sent to a new game" to run [prefsSystem({_p}, 12)]->[profile_system("menu", "game", {_p}, {_p2})]
  6997. format slot 24 of {_p} with light green dye named "&aCountdown to Join" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 12)]->[profile_system("menu", "game", {_p}, {_p2})]
  6998. else:
  6999. format slot 15 of {_p} with clock named "&cCountdown to Join" with lore "&cDisabled||&f||&fClick to Enable||&f||&7See that fancy text when you're out?||&7If you click it, and this is enabled||&7a 15 second time will countdown||&7until you are sent to a new game" to run [prefsSystem({_p}, 12)]->[profile_system("menu", "game", {_p}, {_p2})]
  7000. format slot 24 of {_p} with gray dye named "&cCountdown to Join" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 12)]->[profile_system("menu", "game", {_p}, {_p2})]
  7001. if {_arg2} is "misc":
  7002. open chest with 6 rows named "Miscellaneous Preference" to {_p}
  7003. wait 3 tick
  7004. format slot 0 of {_p} with bed item named "&7← Go Back" to run [profile_system("menu", "prefs", {_p}, {_p2})]
  7005. format slot 1 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7006. format slot 2 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7007. format slot 3 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7008. format slot 4 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7009. format slot 5 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7010. format slot 6 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7011. format slot 7 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7012. format slot 8 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7013. format slot 9 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7014. format slot 17 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7015. format slot 18 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7016. format slot 26 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7017. format slot 27 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7018. format slot 35 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7019. format slot 36 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7020. format slot 44 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7021. format slot 45 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7022. format slot 46 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7023. format slot 47 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7024. format slot 48 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7025. format slot 49 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7026. format slot 50 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7027. format slot 51 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7028. format slot 52 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7029. format slot 53 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7030. if {mineplex.pref.sct.%{_p}%} is true:
  7031. format slot 12 of {_p} with iron sword named "&aShow Clan Tips" with lore "&aEnabled||&f||&fClick to Disable||&f||&f" to run [prefsSystem({_p}, 13)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7032. format slot 21 of {_p} with light green dye named "&aShow Clan Tips" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 13)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7033. else:
  7034. format slot 12 of {_p} with iron sword named "&cShow Clan Tips" with lore "&cDisabled||&f||&fClick to Enable||&f||&f" to run [prefsSystem({_p}, 13)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7035. format slot 21 of {_p} with gray dye named "&cShow Clan Tips" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 13)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7036. if {mineplex.pref.hm.%{_p}%} is true:
  7037. format slot 14 of {_p} with note block named "&aHub Music" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 14)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7038. format slot 23 of {_p} with light green dye named "&aHub Music" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 14)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7039. else:
  7040. format slot 14 of {_p} with note block named "&cHub Music" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 14)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7041. format slot 23 of {_p} with gray dye named "&cHub Music" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 14)]->[profile_system("menu", "misc", {_p}, {_p2})]
  7042. if {_arg2} is "social":
  7043. open chest with 6 rows named "Social Preferences" to {_p}
  7044. wait 3 tick
  7045. format slot 0 of {_p} with bed item named "&7← Go Back" to run [profile_system("menu", "prefs", {_p}, {_p2})]
  7046. format slot 1 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7047. format slot 2 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7048. format slot 3 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7049. format slot 4 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7050. format slot 5 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7051. format slot 6 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7052. format slot 7 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7053. format slot 8 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7054. format slot 9 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7055. format slot 17 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7056. format slot 18 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7057. format slot 26 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7058. format slot 27 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7059. format slot 35 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7060. format slot 36 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7061. format slot 44 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7062. format slot 45 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7063. format slot 46 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7064. format slot 47 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7065. format slot 48 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7066. format slot 49 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7067. format slot 50 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7068. format slot 51 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7069. format slot 52 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7070. format slot 53 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7071. if {mineplex.pref.pr.%{_p}%} is true:
  7072. format slot 10 of {_p} with human head named "&aParty Requests" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 15)]->[profile_system("menu", "social", {_p}, {_p2})]
  7073. format slot 19 of {_p} with light green dye named "&aParty Requests" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 15)]->[profile_system("menu", "social", {_p}, {_p2})]
  7074. else:
  7075. format slot 10 of {_p} with human head named "&cParty Requests" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 15)]->[profile_system("menu", "social", {_p}, {_p2})]
  7076. format slot 19 of {_p} with gray dye named "&cParty Requests" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 15)]->[profile_system("menu", "social", {_p}, {_p2})]
  7077. if {mineplex.pref.spfr.%{_p}%} is true:
  7078. format slot 12 of {_p} with red flower named "&aShow Pending Friend Requests" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 16)]->[profile_system("menu", "social", {_p}, {_p2})]
  7079. format slot 21 of {_p} with light green dye named "&aShow Pending Friend Requests" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 16)]->[profile_system("menu", "social", {_p}, {_p2})]
  7080. else:
  7081. format slot 12 of {_p} with red flower named "&cShow Pending Friend Requests" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 16)]->[profile_system("menu", "social", {_p}, {_p2})]
  7082. format slot 21 of {_p} with gray dye named "&cShow Pending Friend Requests" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 16)]->[profile_system("menu", "social", {_p}, {_p2})]
  7083. if {mineplex.pref.dfg.%{_p}%} is true:
  7084. format slot 14 of {_p} with chest named "&aDisplay Friend GUI" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 17)]->[profile_system("menu", "social", {_p}, {_p2})]
  7085. format slot 23 of {_p} with light green dye named "&aDisplay Friend GUI" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 17)]->[profile_system("menu", "social", {_p}, {_p2})]
  7086. else:
  7087. format slot 14 of {_p} with chest named "&cDisplay Friend GUI" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 17)]->[profile_system("menu", "social", {_p}, {_p2})]
  7088. format slot 23 of {_p} with gray dye named "&cDisplay Friend GUI" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 17)]->[profile_system("menu", "social", {_p}, {_p2})]
  7089. if {mineplex.pref.sci.%{_p}%} is true:
  7090. format slot 16 of {_p} with book named "&aShow Community Invites" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 18)]->[profile_system("menu", "social", {_p}, {_p2})]
  7091. format slot 25 of {_p} with light green dye named "&aShow Community Invites" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 18)]->[profile_system("menu", "social", {_p}, {_p2})]
  7092. else:
  7093. format slot 16 of {_p} with book named "&cShow Community Invites" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 18)]->[profile_system("menu", "social", {_p}, {_p2})]
  7094. format slot 25 of {_p} with gray dye named "&cShow Community Invites" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 18)]->[profile_system("menu", "social", {_p}, {_p2})]
  7095. if {mineplex.pref.dpg.%{_p}%} is true:
  7096. format slot 31 of {_p} with chest named "&aDisplay Parties GUI" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 19)]->[profile_system("menu", "social", {_p}, {_p2})]
  7097. format slot 40 of {_p} with light green dye named "&aDisplay Parties GUI" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 19)]->[profile_system("menu", "social", {_p}, {_p2})]
  7098. else:
  7099. format slot 31 of {_p} with chest named "&cDisplay Parties GUI" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 19)]->[profile_system("menu", "social", {_p}, {_p2})]
  7100. format slot 40 of {_p} with gray dye named "&cDisplay Parties GUI" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 19)]->[profile_system("menu", "social", {_p}, {_p2})]
  7101. if {_arg2} is "staff":
  7102. open chest with 6 rows named "Exclusive Preferences" to {_p}
  7103. wait 3 tick
  7104. format slot 0 of {_p} with bed item named "&7← Go Back" to run [profile_system("menu", "prefs", {_p}, {_p2})]
  7105. format slot 1 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7106. format slot 2 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7107. format slot 3 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7108. format slot 4 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7109. format slot 5 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7110. format slot 6 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7111. format slot 7 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7112. format slot 8 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7113. format slot 9 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7114. format slot 17 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7115. format slot 18 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7116. format slot 26 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7117. format slot 27 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7118. format slot 35 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7119. format slot 36 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7120. format slot 44 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7121. format slot 45 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7122. format slot 46 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7123. format slot 47 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7124. format slot 48 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7125. format slot 49 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7126. format slot 50 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7127. format slot 51 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7128. format slot 52 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7129. format slot 53 of {_p} with light blue stained glass pane named "&f" to be unstealable
  7130. if {mineplex.pref.hif.%{_p}%} is true:
  7131. format slot 10 of {_p} with nether star named "&aHub Invisibility & Flight" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 20)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7132. format slot 19 of {_p} with light green dye named "&aHub Invisibility & Flight" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 20)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7133. else:
  7134. format slot 10 of {_p} with nether star named "&cHub Invisibility & Flight" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 20)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7135. format slot 19 of {_p} with gray dye named "&cHub Invisibility & Flight" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 20)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7136. if {mineplex.ff.%{_p}%} is true:
  7137. format slot 12 of {_p} with slimeball named "&aHub Forcefield" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 8)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7138. format slot 21 of {_p} with light green dye named "&aHub Forcefield" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 8)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7139. else:
  7140. format slot 12 of {_p} with slimeball named "&cHub Forcefield" with lore "&cDisabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 8)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7141. format slot 21 of {_p} with gray dye named "&cHub Forcefield" with lore "&cDisabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 8)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7142. if {mineplex.pref.gwen.%{_p}%} is true:
  7143. format slot 14 of {_p} with paper named "&aGlobal GWEN Reports" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 5)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7144. format slot 23 of {_p} with light green dye named "&aGlobal GWEN Reports" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 5)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7145. else:
  7146. format slot 14 of {_p} with paper named "&cGlobal GWEN Reports" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 5)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7147. format slot 23 of {_p} with gray dye named "&cGlobal GWEN Reports" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 5)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7148. if {mineplex.pref.report.%{_p}%} is true:
  7149. format slot 16 of {_p} with book named "&aUser Reports" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 6)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7150. format slot 25 of {_p} with light green dye named "&aUser Reports" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 6)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7151. else:
  7152. format slot 16 of {_p} with book named "&cUser Reports" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 6)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7153. format slot 25 of {_p} with gray dye named "&cUser Reports" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 6)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7154. if {mineplex.pref.ff.%{_p}%} is true:
  7155. format slot 31 of {_p} with saddle named "&aIgnore Hub Velocity" with lore "&aEnabled||&f||&fClick to Disable||&f" to run [prefsSystem({_p}, 7)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7156. format slot 40 of {_p} with light green dye named "&aIgnore Hub Velocity" with lore "&aEnabled||&f||&fClick to Disable" to run [prefsSystem({_p}, 7)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7157. else:
  7158. format slot 31 of {_p} with saddle named "&cIgnore Hub Velocity" with lore "&cDisabled||&f||&fClick to Enable||&f" to run [prefsSystem({_p}, 7)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7159. format slot 40 of {_p} with gray dye named "&cIgnore Hub Velocity" with lore "&cDisabled||&f||&fClick to Enable" to run [prefsSystem({_p}, 7)]->[profile_system("menu", "staff", {_p}, {_p2})]
  7160.  
  7161. command /prefs:
  7162. trigger:
  7163. profile_system("menu", "prefs", player, player)
  7164.  
  7165. #GWEN CODING!! (Using my old plugin Shield) (I took it down as I was ripping off json.sk but wtevr) lol
  7166.  
  7167. on damage:
  7168. if "%Victim's name%" is "BeamCow" or "BeamGuar":
  7169. cancel event
  7170. on death:
  7171. if "%Victim's name%" is "BeamCow" or "BeamGuar":
  7172. clear drops
  7173.  
  7174. on quit:
  7175. delete {forcefield.past.%player%}
  7176.  
  7177. function beamGo(p: player) :: number:
  7178. apply slowness 255 to {_p} for 7 seconds
  7179. set {_p2} to location 3 blocks in front of {_p}
  7180. add 5 to y-coordinate of {_p2}
  7181. set {_p3} to location 3 blocks behind {_p}
  7182. add 5 to y-coordinate of {_p3}
  7183. set {_p4} to location 3 blocks left of {_p}
  7184. add 5 to y-coordinate of {_p4}
  7185. set {_p5} to location 3 blocks right of {_p}
  7186. add 5 to y-coordinate of {_p5}
  7187. spawn a guardian at {_p2}
  7188. add "{CustomName:""BeamCow"", NoGravity:1, Silent:1}" to nbt of last spawned entity
  7189. set {_t2} to last spawned entity
  7190. spawn a guardian at {_p3}
  7191. add "{CustomName:""BeamCow"", NoGravity:1, Silent:1}" to nbt of last spawned entity
  7192. set {_t3} to last spawned entity
  7193. spawn a guardian at {_p4}
  7194. add "{CustomName:""BeamCow"", NoGravity:1, Silent:1}" to nbt of last spawned entity
  7195. set {_t4} to last spawned entity
  7196. spawn a guardian at {_p5}
  7197. add "{CustomName:""BeamCow"", NoGravity:1, Silent:1}" to nbt of last spawned entity
  7198. set {_t5} to last spawned entity
  7199. set {_player} to {_p}
  7200. set {_r} to randomize "BHWFEAEG619"
  7201. set {_s} to "Chiss" parsed as a player
  7202. setPlayerdata({_p}, "banned", "yes")
  7203. punishBan({_s} ,{_player} , "[GWEN Cheat Detection]%nl%%nl%Ban Token:%nl%%{_r}%")
  7204. set {banned::%{_player}%} to true
  7205. set {banned::%{_player}%::type} to "perm"
  7206. set {banned::%{_player}%::reason} to "[GWEN Cheat Detection]%nl%%nl%Ban Token:%nl%%{_r}%"
  7207. set {banned::%{_player}%::staff} to "Chiss"
  7208. set {banned::%{_player}%::when} to now
  7209. add "&ePunishment Type: &fOther||||&eReason: &f[GWEN] Token: %{_r}%||||&eStaff: &fChiss||||&eDate: &f%now%" to {p.%{_player}%::history::*}
  7210. Beam({_p}, {_t2})
  7211. Beam({_p}, {_t3})
  7212. Beam({_p}, {_t4})
  7213. Beam({_p}, {_t5})
  7214. wait 5.2 seconds
  7215. broadcast "&9GWEN> &7%{_p}% has been banned. I am always watching"
  7216. kick {_player} due to "&c&lYou are banned for Permanent by %{mineplex.config.servername}% Anti-Cheat%nl%&f[GWEN Cheat Detection]%nl%%nl%Ban Token:%nl%%{_r}%%nl%&2Unfairly banned? Appeal at &a%{mineplex.config.appealwebsite}%"
  7217.  
  7218. command /gwenban <player>:
  7219. permission: mineplex.admin
  7220. permission message: &9Permissions> &7This requires Permission Rank [&9ADMIN&7].
  7221. trigger:
  7222. beamGo(arg-1)
  7223.  
  7224. on shoot:
  7225. if projectile is an arrow:
  7226. if difference between {bow.%shooter%} and now is less than 2 ticks:
  7227. gwenAlert((shooter), ("Fast Bow"))
  7228. set {bow.%shooter%} to now
  7229.  
  7230. every 4 second :
  7231. set {autoclick.check} to true
  7232. wait 3 second
  7233. set {autoclick.check} to false
  7234. loop all players :
  7235. delete {player.click.%loop-player%}
  7236.  
  7237. on left click :
  7238. {autoclick.check} is true
  7239. add 1 to {player.click.%player%}
  7240. {player.click.%player%} > 69
  7241. gwenAlert((player), ("High CPS (%{player.click.%player%} / 3% clicks/second)"))
  7242.  
  7243. on walk on water:
  7244. set {_loc} to location of player
  7245. add 2 to y-coordinate of {_loc}
  7246. if block at {_loc} is air:
  7247. add 1 to {gwen.jesus.%player%}
  7248. if {gwen.jesus.%player%} is greater than 6:
  7249. gamemode of player is survival
  7250. gwenAlert((player), ("Jesus"))
  7251. delete {gwen.jesus.%player%}
  7252.  
  7253. on consume:
  7254. if difference between {fasteat.%player%} and now is less than 10 ticks:
  7255. cancel event
  7256. set {fasteat.%player%} to now
  7257. gwenAlert((player), ("FastEat"))
  7258. set {fasteat.%player%} to now
  7259.  
  7260. on damage:
  7261. if attacker is a player:
  7262. if victim is a player:
  7263. if attacker's gamemode is survival or adventure:
  7264. damage wasn't caused by thorns or projectile:
  7265. set {_reach.%attacker%} to distance between attacker and victim
  7266. set {_ping} to attacker's ping
  7267. if {_reach.%attacker%} is greater than 5.67:
  7268. if {_ping} is greater than 350:
  7269. gwenAlert((attacker), ("Reach"))
  7270. if {_ping} is less than 350:
  7271. gwenAlert((attacker), ("Reach"))
  7272.  
  7273. on damage of a player :
  7274. block at victim is not cobweb
  7275. victim is not riding
  7276. victim is not on fire
  7277. victim's y-coordinate is greater than 5
  7278. set {_loc9} to block north east victim
  7279. set {_loc8} to block south west victim
  7280. blocks within {_loc9} to {_loc8} is air
  7281. set {_loc} to location of victim
  7282. wait 10 ticks
  7283. set {_loc2} to location of victim
  7284. distance between {_loc} and {_loc2} = 0
  7285. victim's ping < 250
  7286. gwenAlert((victim), ("Velocity"))
  7287.  
  7288. #Systems
  7289.  
  7290. on leftclick holding tnt:
  7291. if {mineplex.tntlauncher} is true:
  7292. player has 1 tnt
  7293. spawn a primed tnt 1 meter above the player
  7294. add "{Fuse:60}" to nbt of the spawned entity
  7295. push the spawned entity in direction of player at speed 0.9
  7296. push the spawned entity upwards at speed 0.2
  7297. remove 1 tnt from player
  7298.  
  7299. on rightclick holding tnt:
  7300. if {mineplex.tntlauncher} is true:
  7301. player has 1 tnt
  7302. spawn a primed tnt 1 meter above the player
  7303. add "{Fuse:60}" to nbt of the spawned entity
  7304. push the spawned entity in direction of player at speed 0.9
  7305. push the spawned entity upwards at speed 0.2
  7306. remove 1 tnt from player
  7307.  
  7308. #Command Completers
  7309.  
  7310. on tab completer for "/mineplex-core":
  7311. if argument at 1 is set:
  7312. if argument at 1 is "useChat" or "titleOnJoin" or "useScoreboard":
  7313. add "true" to completions
  7314. add "false" to completions
  7315. else if argument at 1 is "chestPoint":
  7316. add "1" to completions
  7317. add "2" to completions
  7318. add "3" to completions
  7319. add "4" to completions
  7320. else if argument at 1 is "chestPointSub":
  7321. if argument at 2 is set:
  7322. add "1" to completions
  7323. add "2" to completions
  7324. add "3" to completions
  7325. add "4" to completions
  7326. add "5" to completions
  7327. add "6" to completions
  7328. add "7" to completions
  7329. add "8" to completions
  7330. else:
  7331. add "1" to completions
  7332. add "2" to completions
  7333. add "3" to completions
  7334. add "4" to completions
  7335. if argument at 1 is not set:
  7336. add "help" to completions
  7337. add "useChat" to completions
  7338. add "setAdmin" to completions
  7339. add "chestPoint" to completions
  7340. add "chestPointSub" to completions
  7341. add "titleOnJoin" to completions
  7342. add "reload" to completions
  7343. add "useScoreboard" to completions
  7344. add "spawnCarl" to completions
  7345. add "throwableTnt" to completions
  7346.  
  7347. on tab completer for "/tp":
  7348. add "here" to completions
  7349. add "h" to completions
  7350. add "back" to completions
  7351. add "b" to completions
  7352. add "all" to completions
  7353. loop all players:
  7354. add "%loop-player%" to completions
  7355.  
  7356. on tab completer for "/give":
  7357. if player has permission "mineplex.admin":
  7358. loop all items:
  7359. add "%loop-value%" to completions
  7360. loop all players:
  7361. add "%loop-player%" to completions
  7362. add "ALL" to completions
  7363.  
  7364. #Modules
  7365.  
  7366. on load:
  7367. delete {mineplex::modules::*}
  7368. set {mineplex.modulesapi.online} to true
  7369.  
  7370. on unload:
  7371. delete {mineplex::modules::*}
  7372. set {mineplex.modulesapi.online} to false
  7373.  
  7374. command /modules:
  7375. trigger:
  7376. send "&9Modules> &7Modules API version 0.1"
  7377. send "&9Modules> &7Going to *attempt* to list modules."
  7378. send "&9Modules> &7This does not mean that your module is not loaded."
  7379. loop {mineplex::modules::*}:
  7380. send "&9Modules> &e%loop-value%"
  7381.  
  7382. #add "Bungee Module" to {mineplex::modules::*}
  7383. #remove "Bungee Module" from {mineplex::modules::*}
  7384.  
  7385. #MPS
  7386.  
  7387. #on load:
  7388. # if {wget} is not set:
  7389. # download file from "" to file "./WheezyMap.zip"
  7390.  
  7391. #command /mpsconfirm:
  7392. # permission: mineplex.op
  7393. # trigger:
  7394. # if {mineplex.mps.%player%} is not set:
  7395. # send "&9Personal Server Manager> &7%player%-1 successfully created. You will be sent to it shortly."
  7396. # send "&9Personal Server Manager> &7If you haven't been connected in 20 seconds, type /server %player%-1."
  7397. # copy dir "./mps/Mineplex" to "./mps/%player%-1/"
  7398. # load world "./mps/%player%-1"
  7399. # set {mps.%player%-1} to "yes"
  7400. # wait 20 seconds
  7401. # else:
  7402. # send "&9Personal Server Manager> &7Your server is still being created or already exists. If you haven't been connected in 20 seconds, type /server %player%-1."
  7403. #
  7404. #command /hostserver:
  7405. # permission: mineplex.op
  7406. # trigger:
  7407. # if {mineplex.mps.%player%} is not set:
  7408. # send "&9Personal Server Manager> &7%player%-1 successfully created. You will be sent to it shortly."
  7409. # send "&9Personal Server Manager> &7If you haven't been connected in 20 seconds, type /server %player%-1."
  7410. # create folder "./mps/%player%-1"
  7411. # load world "./mps/%player%-1"
  7412. # wait 20 seconds
  7413. # teleport player to spawn of "./mps/%player%-1"
  7414. # else:
  7415. # send "&9Personal Server Manager> &7Your server is still being created or already exists. If you haven't been connected in 20 seconds, type /server %player%-1."
  7416.  
  7417. #command /endserver:
  7418. # trigger:
  7419. # loop all players:
  7420. # loop-player's world is "./mps/%player%-1":
  7421. # teleport player to spawn of "%arg-1%"
  7422. # unload world "./mps/%player%-1"
  7423. # wait 2 seconds
  7424. # delete folder "./mps/%player%-1/data/"
  7425. # delete folder "./mps/%player%-1/region/"
  7426. # delete file "./mps/%player%-1/level.dat"
  7427. # delete file "./mps/%player%-1/uid.dat"
  7428. # delete file "./mps/%player%-1/session.lock"
  7429. # delete dir "./mps/%player%-1"
  7430.  
  7431. #command /tpwrd <text>:
  7432. # trigger:
  7433. # set {_w} to "world"
  7434. # teleport player to spawn of {_w}
  7435.  
  7436. #command /menu:
  7437. # trigger:
  7438. # open chest with 3 rows named "Private Server Menu" to player
  7439. # wait 1 tick
  7440. # format slot 11 of player with diamond sword named "&a&lGive Co-Host" with lore "||&e" to close then run [execute console command "say no way hosay"]
  7441. # format slot 13 of player with lava bucket named "&aRemove Player" with lore "||&e" to close then run [execute console command "kick Citrin_ lol"]
  7442. # format slot 15 of player with redstone comparator item named "&aGame Options" with lore "||&e" to close then run [execute console command "say xd"]
  7443. # format slot 20 of player with golden sword named "&a&lRemove Co-Host" with lore "||&e" to close then run [execute console command "say no way hosay"]
  7444. # format slot 22 of player with water bucket named "&a&lUn-Remove Player" with lore "||&e" to close then run [execute console command "say no way hosay"]
  7445. # format slot 24 of player with tnt named "&a&lKill Private Server" with lore "||&7Shift-Right Click to Kill Private Server" to close then run [execute console command "say xd"]
  7446.  
  7447.  
  7448. #skPerms by LimeGlass
  7449. #Thanks for Letting Me Bake This In!
  7450. options:
  7451. prefix: &6[&5SkPerms&6]
  7452. maincolour: &6
  7453. secondcolour: &7
  7454. command: /skperms
  7455. aliases: /perm, /permission
  7456. permission: skperms.admin
  7457.  
  7458. #CMD protection is basically extra security for your server. Only players inside of a list variable can use SkPerms
  7459. CMDprotection: false
  7460. CMDprotectionMsg: Unknown command. Type ""/help"" for help
  7461. #The player list is the list variable that contains players that can use SkPerms if CMDprotection is enabled
  7462. PlayerList: {example::players::*}
  7463.  
  7464. UseChat: false #use prefix and suffix in the chat
  7465. #Chat types:
  7466. #Display - Changes the player's display name (Vault will hook if installed)
  7467. #Override - !COMING SOON
  7468. ChatType: "Display"
  7469.  
  7470. version: 1.0.5
  7471.  
  7472. on script load:
  7473. if file "plugins\SkPerms" exists:
  7474. delete {skperms::config::*}
  7475. else:
  7476. set yaml value "version" from file "plugins\SkPerms\config.yml" to "{@version}"
  7477. set yaml value "useYML" from file "plugins\SkPerms\config.yml" to false
  7478. set {skperms::config::version} to yaml value "version" from file "plugins\SkPerms\config.yml"
  7479. set {skperms::config::useYML} to yaml value "useYML" from file "plugins\SkPerms\config.yml"
  7480. if {skperms::config::useYML} is true:
  7481. if {skperms::players::*} is not set:
  7482. stop
  7483. delete file "plugins\SkPerms\players.yml"
  7484. loop {skperms::players::*}:
  7485. loop {skperms::player::%loop-value%::permissions::*}:
  7486. add "%loop-value-2%" to yaml list "players.%loop-value-1%.permissions" from file "plugins\SkPerms\players.yml"
  7487. on script unload:
  7488. loop {skperms::groups::*}:
  7489. if {skperms::group::%loop-value%::*} is not set:
  7490. loop {skperms::group::%loop-value-1%::permissions::*}:
  7491. loop {skperms::players::*}:
  7492. remove "%loop-value-2%" from {skperms::player::%loop-value-3%::permissions::*}
  7493. loop {skperms::players::*}:
  7494. remove "%loop-value-1%" from {skperms::player::%loop-value-2%::groups::*}
  7495. if {skperms::player::%loop-value-2%::groups::*} is not empty:
  7496. loop {skperms::player::%loop-value-2%::groups::*}:
  7497. loop {skperms::group::%loop-value-1%::permissions::*}:
  7498. set {_p} to "%loop-value-2%" parsed as player
  7499. add "%loop-value-4%" to {_p}'s permissions
  7500. remove "%loop-value%" from {skperms::groups::*}
  7501. command {@command} [<text>] [<text>] [<text>] [<text>] [<text>]:
  7502. permission: {@permission}
  7503. aliases: {@aliases}
  7504. trigger:
  7505. if {@CMDprotection} is true:
  7506. if command sender is not console:
  7507. if {@PlayerList} doesn't contain player or "%player%":
  7508. message "{@CMDprotectionMsg}"
  7509. stop
  7510. if arg 1 is not set:
  7511. message ""
  7512. message "{@prefix} v{@version}:"
  7513. message "{@maincolour}{@command} deleteDefault"
  7514. message "{@secondcolour}Deletes default group setting (If set)"
  7515. message "{@maincolour}{@command} (d|default) (group)"
  7516. if {skperms::default} is set:
  7517. message "{@secondcolour}Set the default group {@maincolour}(&7%{skperms::default}%{@maincolour})"
  7518. else:
  7519. message "{@secondcolour}Set the default group"
  7520. message "{@maincolour}{@command} (p|player) (player) (add|remove|list) permission [permission]"
  7521. message "{@secondcolour}Add/remove/list a players permissions"
  7522. message "{@maincolour}{@command} (p|player) (player) (add|set|remove|list) group [group]"
  7523. message "{@secondcolour}Add/remove/set/list a players group"
  7524. message "{@maincolour}{@command} (g|group) (group) (add|remove|list) permission [permission]"
  7525. message "{@secondcolour}Add/remove/list a group permission"
  7526. message "{@maincolour}{@command} (g|group) (group) (add|remove|list) group [group]"
  7527. message "{@secondcolour}Add/remove/list a groups connected groups"
  7528. message "{@secondcolour}A group is created once it contains a permission"
  7529. message "{@maincolour}{@command} (g|group) (group) (prefix|suffix) set (text)"
  7530. message "{@secondcolour}Set a suffix or prefix to a group"
  7531. message ""
  7532. else if arg 1 is "deleteDefault":
  7533. delete {skperms::default}
  7534. message "{@prefix} {@maincolour}Removed default group (No group set)"
  7535. else if arg 1 is "d", "setdefault" or "default":
  7536. if arg 2 is set:
  7537. set {skperms::default} to "%arg 2%"
  7538. message "{@prefix} {@maincolour}Set default group to &l%arg 2%"
  7539. else:
  7540. message "{@prefix} {@maincolour}Error: Group not specified"
  7541. else if arg 1 is "p" or "player":
  7542. if arg 2 is not set:
  7543. message "{@prefix} {@maincolour}Error: Player not specified"
  7544. else if arg 2 is set:
  7545. if arg 3 is "a" or "add":
  7546. if arg 4 is "p", "permission" or "permissions":
  7547. if arg 5 is set:
  7548. if {skperms::groups::*} doesn't contain "%arg 2%":
  7549. add "%arg 2%" to {skperms::groups::*}
  7550. set {_player} to arg 2 parsed as player
  7551. add "%arg 5%" to {_player}'s permissions
  7552. set {skperms::player::%arg 2%::permissions::*} to {_player}'s permissions
  7553. message "{@prefix} {@maincolour}Added %arg 5% to %arg 2%'s permissions"
  7554. else:
  7555. message "{@prefix} {@maincolour}Error: Permission not specified"
  7556. else if arg 4 is "g", "group" or "groups":
  7557. if arg 5 is set:
  7558. if {skperms::groups::*} doesn't contain "%arg 2%":
  7559. add "%arg 2%" to {skperms::groups::*}
  7560. if {skperms::player::%arg 2%::groups::*} doesn't contain "%arg 5%":
  7561. add "%arg 5%" to {skperms::player::%arg 2%::groups::*}
  7562. else:
  7563. message "{@prefix} {@secondcolour}%arg 2% already has group %arg 5%"
  7564. stop
  7565. message "{@prefix} {@maincolour}Added %arg 2% to group %arg 5%"
  7566. if {@UseChat} is true:
  7567. if {@ChatType} is "Display" or "display":
  7568. loop all players:
  7569. if {skperms::player::%player%::groups::*} contains "%arg 5%":
  7570. if {skperms::group::%arg 5%::prefix} is set:
  7571. if {skperms::group::%arg 5%::suffix} is set:
  7572. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7573. else:
  7574. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%"
  7575. else if {skperms::group::%arg 5%::suffix} is set:
  7576. set loop-player's display name to coloured "%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7577. else:
  7578. set loop-player's display name to "%player%"
  7579. loop all players:
  7580. if {skperms::player::%player%::groups::*} is not set:
  7581. set loop-player's display name to "%player%"
  7582. else:
  7583. message "{@prefix} {@maincolour}Error: Group not specified"
  7584. else:
  7585. message "{@prefix} {@maincolour}Error: Type not specified"
  7586. else if arg 3 is "s" or "set":
  7587. if arg 4 is "g", "group" or "groups":
  7588. if arg 5 is set:
  7589. if {skperms::groups::*} doesn't contain "%arg 2%":
  7590. add "%arg 2%" to {skperms::groups::*}
  7591. delete {skperms::player::%arg 2%::groups::*}
  7592. add "%arg 5%" to {skperms::player::%arg 2%::groups::*}
  7593. message "{@prefix} {@maincolour}Set %arg 2% to group %arg 5%"
  7594. if {@UseChat} is true:
  7595. if {@ChatType} is "Display" or "display":
  7596. loop all players:
  7597. if {skperms::player::%player%::groups::*} contains "%arg 5%":
  7598. if {skperms::group::%arg 5%::prefix} is set:
  7599. if {skperms::group::%arg 5%::suffix} is set:
  7600. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7601. else:
  7602. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%"
  7603. else if {skperms::group::%arg 5%::suffix} is set:
  7604. set loop-player's display name to coloured "%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7605. else:
  7606. set loop-player's display name to "%player%"
  7607. loop all players:
  7608. if {skperms::player::%player%::groups::*} is not set:
  7609. set loop-player's display name to "%player%"
  7610. else:
  7611. message "{@prefix} {@maincolour}Error: Group not specified"
  7612. else:
  7613. message "{@prefix} {@maincolour}Error: Type not specified"
  7614. else if arg 3 is "r" or "remove":
  7615. if arg 4 is "p", "permission" or "permissions":
  7616. if arg 5 is set:
  7617. set {_player} to arg 2 parsed as player
  7618. remove "%arg 5%" from {_player}'s permissions
  7619. set {skperms::player::%arg 2%::permissions::*} to {_player}'s permissions
  7620. message "{@prefix} {@maincolour}Removed %arg 5% from %arg 2%'s permissions"
  7621. else:
  7622. message "{@prefix} {@maincolour}Error: Permission not specified"
  7623. else if arg 4 is "g", "group" or "groups":
  7624. if arg 5 is set:
  7625. if {skperms::player::%arg 2%::groups::*} contains "%arg 5%":
  7626. remove "%arg 5%" from {skperms::player::%arg 2%::groups::*}
  7627. message "{@prefix} {@maincolour}Removed %arg 2% from group %arg 5%"
  7628. if {@UseChat} is true:
  7629. if {@ChatType} is "Display" or "display":
  7630. loop all players:
  7631. if {skperms::player::%player%::groups::*} contains "%arg 5%":
  7632. if {skperms::group::%arg 5%::prefix} is set:
  7633. if {skperms::group::%arg 5%::suffix} is set:
  7634. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7635. else:
  7636. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%"
  7637. else if {skperms::group::%arg 5%::suffix} is set:
  7638. set loop-player's display name to coloured "%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7639. else:
  7640. set loop-player's display name to "%player%"
  7641. loop all players:
  7642. if {skperms::player::%player%::groups::*} is not set:
  7643. set loop-player's display name to "%player%"
  7644. else:
  7645. message "{@prefix} {@maincolour}Error: Player %arg 2% doesn't have that group"
  7646. else:
  7647. message "{@prefix} {@maincolour}Error: Group not specified"
  7648. else:
  7649. message "{@prefix} {@maincolour}Error: Type not specified"
  7650. else if arg 3 is "l" or "list":
  7651. if arg 4 is "p", "permission" or "permissions":
  7652. set {_player} to arg 2 parsed as player
  7653. message "{@prefix} {@maincolour}%{_player}'s permissions%"
  7654. else if arg 4 is "g", "group" or "groups":
  7655. message "{@prefix} {@maincolour}%{skperms::player::%arg 2%::groups::*}%"
  7656. else:
  7657. message "{@prefix} {@maincolour}Error: Type not specified"
  7658. else if arg 1 is "g", "group" or "groups":
  7659. if arg 2 is not set:
  7660. message "{@prefix} {@maincolour}Error: Group not specified"
  7661. else if arg 2 is set:
  7662. if arg 3 is "a" or "add":
  7663. if arg 4 is "p", "permission" or "permissions":
  7664. if arg 5 is set:
  7665. if {skperms::groups::*} doesn't contain "%arg 2%":
  7666. add "%arg 2%" to {skperms::groups::*}
  7667. add "%arg 5%" to {skperms::group::%arg 2%::permissions::*}
  7668. message "{@prefix} {@maincolour}Added %arg 5% to group %arg 2%'s permissions"
  7669. loop all players:
  7670. if {skperms::player::%player%::groups::*} contains "%arg 2%":
  7671. loop {skperms::group::%arg 2%::permissions::*}:
  7672. add "%loop-value-2%" to loop-player's permissions
  7673. else:
  7674. message "{@prefix} {@maincolour}Error: Permission not specified"
  7675. else if arg 4 is "g", "group" or "groups":
  7676. if arg 5 is set:
  7677. if {skperms::groups::*} doesn't contain "%arg 2%":
  7678. add "%arg 2%" to {skperms::groups::*}
  7679. loop {skperms::group::%arg 5%::permissions::*}:
  7680. add "%loop-value%" to {skperms::group::%arg 2%::permissions::*}
  7681. message "{@prefix} {@maincolour}Added %arg 5%'s permissions to group %arg 2%"
  7682. loop all players:
  7683. if {skperms::player::%player%::groups::*} contains "%arg 2%":
  7684. loop {skperms::group::%arg 2%::permissions::*}:
  7685. add "%loop-value-2%" to loop-player's permissions
  7686. else:
  7687. message "{@prefix} {@maincolour}Error: Group not specified"
  7688. else:
  7689. message "{@prefix} {@maincolour}Error: Type not specified"
  7690. else if arg 3 is "r" or "remove":
  7691. if arg 4 is "p", "permission" or "permissions":
  7692. if arg 5 is set:
  7693. loop all players:
  7694. if {skperms::player::%player%::groups::*} contains "%arg 2%":
  7695. loop {skperms::group::%arg 2%::permissions::*}:
  7696. remove "%loop-value-2%" from loop-player's permissions
  7697. remove "%arg 5%" from {skperms::group::%arg 2%::permissions::*}
  7698. message "{@prefix} {@maincolour}Removed %arg 5% from group %arg 2%'s permissions"
  7699. loop all players:
  7700. if {skperms::player::%player%::groups::*} contains "%arg 2%":
  7701. loop {skperms::group::%arg 2%::permissions::*}:
  7702. add "%loop-value-2%" to loop-player's permissions
  7703. else:
  7704. message "{@prefix} {@maincolour}Error: Permission not specified"
  7705. else if arg 4 is "g", "group" or "groups":
  7706. if arg 5 is set:
  7707. loop all players:
  7708. if {skperms::player::%player%::groups::*} contains "%arg 2%":
  7709. loop {skperms::group::%arg 2%::permissions::*}:
  7710. remove "%loop-value-2%" from loop-player's permissions
  7711. loop {skperms::group::%arg 5%::permissions::*}:
  7712. remove "%loop-value%" from {skperms::group::%arg 2%::permissions::*}
  7713. add 1 to {_l}
  7714. message "{@prefix} {@maincolour}Removed %{_l}% of %arg 5%'s permissions from group %arg 2%"
  7715. loop all players:
  7716. if {skperms::player::%player%::groups::*} contains "%arg 2%":
  7717. loop {skperms::group::%arg 2%::permissions::*}:
  7718. add "%loop-value-2%" to loop-player's permissions
  7719. else:
  7720. message "{@prefix} {@maincolour}Error: Group not specified"
  7721. else:
  7722. message "{@prefix} {@maincolour}Error: Type not specified"
  7723. else if arg 3 is "l" or "list":
  7724. if arg 4 is "p", "permission" or "permissions":
  7725. message "{@prefix} {@maincolour}%{skperms::group::%arg 2%::permissions::*}%"
  7726. else:
  7727. message "{@prefix} {@maincolour}Error: Type not specified"
  7728. else if arg 3 is "prefix" or "suffix":
  7729. if arg 4 is "set":
  7730. if arg 5 is set:
  7731. set {skperms::group::%arg 2%::%arg 3%} to "%arg 5%"
  7732. message "{@prefix} {@maincolour}%arg 3% set to %arg 5%"
  7733. if {@UseChat} is true:
  7734. if {@ChatType} is "Display" or "display":
  7735. loop all players:
  7736. if {skperms::player::%player%::groups::*} contains "%arg 5%":
  7737. if {skperms::group::%arg 5%::prefix} is set:
  7738. if {skperms::group::%arg 5%::suffix} is set:
  7739. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7740. else:
  7741. set loop-player's display name to coloured "%{skperms::group::%arg 5%::prefix}%%loop-player%"
  7742. else if {skperms::group::%arg 5%::suffix} is set:
  7743. set loop-player's display name to coloured "%loop-player%%{skperms::group::%arg 5%::suffix}%"
  7744. else:
  7745. set loop-player's display name to "%player%"
  7746. loop all players:
  7747. if {skperms::player::%player%::groups::*} is not set:
  7748. set loop-player's display name to "%player%"
  7749. else:
  7750. message "{@prefix} {@maincolour}Prefix/Suffix not specified"
  7751. else:
  7752. message "{@prefix} {@maincolour}Error: Type not specified (Type ""set"")"
  7753. #on quit:
  7754. # set {skperms::player::%player%::permissions::*} to player's permissions
  7755.  
  7756. on join:
  7757. loop 2 times:
  7758. remove "%player%" from {skperms::players::*}
  7759. add "%player%" to {skperms::players::*}
  7760. loop {skperms::groups::*}:
  7761. if player has permission "skperms.group.%loop-value%":
  7762. if {skperms::player::%player%::groups::*} doesn't contain "%loop-value%":
  7763. add "%loop-value%" to {skperms::player::%player%::groups::*}
  7764. if {skperms::default} is set:
  7765. loop {skperms::group::%{skperms::default}%::permissions::*}:
  7766. add "%loop-value%" to player's permissions
  7767. loop {skperms::player::%player%::permissions::*}:
  7768. add "%loop-value%" to player's permissions
  7769. if {skperms::player::%player%::groups::*} is not empty:
  7770. loop {skperms::player::%player%::groups::*}:
  7771. loop {skperms::group::%loop-value%::permissions::*}:
  7772. add "%loop-value-2%" to player's permissions
  7773. if {@UseChat} is true:
  7774. if {@ChatType} is "Display" or "display":
  7775. if {skperms::group::%loop-index%::prefix} is set:
  7776. if {skperms::group::%loop-index%::suffix} is set:
  7777. set player's display name to coloured "%{skperms::group::%loop-index%::prefix}%%player%%{skperms::group::%loop-index%::suffix}%"
  7778. else:
  7779. set player's display name to coloured "%{skperms::group::%loop-index%::prefix}%%player%"
  7780. else if {skperms::group::%loop-index%::suffix} is set:
  7781. set player's display name to coloured "%player%%{skperms::group::%loop-index%::suffix}%"
  7782. else:
  7783. set player's display name to "%player%"
  7784. loop all players:
  7785. if {skperms::player::%player%::groups::*} is not set:
  7786. set loop-player's display name to "%player%"
  7787.  
  7788. on load:
  7789. set {_time} to difference between {mineplex.starttime} and now
  7790. broadcast "&9MCR> &7Mineplex Core &e{@MCRVER} &7has been loaded! (%{_time}%)"
Add Comment
Please, Sign In to add comment