Advertisement
FlupMC

team skript

Jun 6th, 2020
511
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 61.35 KB | None | 0 0
  1. Options:
  2. Bannednavne: "´","Fuck","Ingen","None","<none>","Nigg",".",",","Lort","Server","pik","fisse","dick","dic","*","_","&","-","'"," ","+","?","=","]","[","{","}","(",")","^",":",";","O","@"," ","%%"," ","/" or "Nigger"
  3. p: &8&l| &b&lTEAM &8&l| &f
  4.  
  5. command /tc [<text>]:
  6. aliases: /bruhnetwork:tc, /bruhnetwork:teamchat, /teamchat
  7. trigger:
  8. if arg-1 is set:
  9. if {team::%uuid of player%} is set:
  10. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  11. set {_prefix} to "&8[&aLeder&8] &a"
  12. else:
  13. set {_prefix} to "&8[&cMedlem&8] &c"
  14. loop all players:
  15. if {team::%uuid of player%} is {team::%uuid of loop-player%}:
  16. message "&8&l[&b&lTeam Chat&8&l] %{_prefix}%%player% &8»&f %arg text%" to loop-player
  17. else:
  18. send "{@p}Du skal skrive en besked."
  19. command /team [<text>] [<text>] [<text>]:
  20. aliases: /bruhnetwork:team, /bruhnetwork:teams, /teams
  21. #permission: team.test
  22. trigger:
  23. if arg-1 is not set:
  24. if {team::%uuid of player%} is not set:
  25. execute player command "team hjælp"
  26. stop
  27. if {team::%uuid of player%} is set:
  28. execute player command "team start"
  29. else if arg-1 is "hjælp" or "help":
  30. open chest with 5 rows named "Team Hjælp" to player
  31. wait 3 ticks
  32. if inventory name of player's current inventory is "Team Hjælp":
  33. #----------------------------------------------------------------
  34. loop integers from 0 to 8:
  35. set slot loop-integer of player's current inventory to white stained glass pane named ""
  36. loop integers from 36 to 44:
  37. set slot loop-integer of player's current inventory to light blue stained glass pane named ""
  38. #----------------------------------------------------------------
  39. if {team::%uuid of player%} is set:
  40. set slot 22 of player's current inventory to paper named "&b&m»---------&r &3&lINFO &b&m---------" with lore "&8» &7/team hjælp &8- &7Viser denne menu.||&8» &7/team opret (navn) &8- &7Koster &a2500,-||&8» &7/team accepter &8- &7Joiner det team du er inviteret til.||&8» &7/team afvis &8- &7Afviser en invitation fra et team.||&8» &7/team info (navn) &8- &7Viser information om et team.||&b&m»-->||&8» &7/team inviter (navn) &8- &7Invitere en person til dit team.||&8» &7/team fjern (navn) &8- &7Fjerner en person fra dit team.||&8» &7/team indsæt (antal) &8- &7Indsætter penge i dit team.||&8» &7/tc &8- &7Skriver en besked i teamchatten.||&8» &7/tk &8- &7Viser dig jeres teamkister."
  41. else:
  42. set slot 22 of player's current inventory to paper named "&b&m»---------&r &3&lINFO &b&m---------" with lore "&8» &7/team hjælp &8- &7Viser denne menu.||&8» &7/team opret (navn) &8- &7Koster &a2500,-||&8» &7/team accepter &8- &7Joiner det team du er inviteret til.||&8» &7/team afvis &8- &7Afviser en invitation fra et team.||&8» &7/team info (navn) &8- &7Viser information om et team.||&b&m»-->"
  43.  
  44. else if arg-1 is "opret" or "create":
  45. if {team::%uuid of player%} is set:
  46. send "{@p}Du er allerede med i et team &8(&b%{team::%uuid of player%}%&8)"
  47. send "{@p}Du kan altid forlade dit team via &b/team forlad"
  48. stop
  49. else:
  50. if arg-2 is set:
  51. if player's balance is greater or equal to 2500:
  52. set {_arg2} to arg-2
  53. if arg 3 is set:
  54. send "{@p}Der må ikke være mellemrum i dit team navn."
  55. stop
  56. if length of {_arg2} is between -9999999999999 and 1:
  57. send "{@p}Dit team navn skal være længere end 1 bogstav."
  58. stop
  59. if length of {_arg2} is above 8:
  60. send "{@p}Dit team navn må ikke være længere end &b8 &fbogstaver!"
  61. stop
  62. if arg-2 contains {@Bannednavne}:
  63. send "{@p}Dette må dit team ikke hedde."
  64. stop
  65. if arg-2 do not contain "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "æ", "ø" or "å":
  66. send "{@p}Dette må dit team ikke hedde."
  67. stop
  68. if {team::%arg-2%} is set:
  69. send "{@p}Der er allerede et team med dette navn."
  70. stop
  71. add 1 to {team.ID}
  72. set {team::%uuid of player%} to arg-2
  73. set {team::%arg-2%} to arg-2
  74. set {team::%arg-2%::lvl} to 1
  75. set {team::%arg-2%::lavet} to now
  76. set {team::%arg-2%::lvlkills} to 300
  77. set {team::%arg-2%::maxmem} to 3
  78. set {kills.team::%arg-2%} to 0
  79. set {deaths.team::%arg-2%} to 0
  80. set {bank.team::%arg-2%} to 0
  81. set {team::%arg-2%::adgang.til.chest1} to false
  82. set {team::%arg-2%::adgang.til.chest2} to false
  83. set {team::%arg-2%::adgang.til.chest3} to false
  84. set {team::%arg-2%::levelup.1.farve1} to false
  85. set {team::%arg-2%::levelup.1.chest1} to false
  86. set {team::%arg-2%::levelup.2.chest2} to false
  87. set {team::%arg-2%::levelup.2.medlem2} to false
  88. set {team::%arg-2%::antal.farver} to 0
  89. set {team::%arg-2%::ejer} to uuid of player
  90. set {team::%arg-2%::adgangtil.shop} to "Ejer"
  91. set {team::%arg-2%::adgangtil.farve} to "Ejer"
  92. set {team::%arg-2%::teamdamaga} to false
  93. set {team::%arg-2%::ejernavn} to "%player%"
  94. set {team::%{team::%uuid of player%}%::farve} to "&7"
  95. add "%{team::%arg-2%}%" to {teams::*}
  96. set {navn::%uuid of player%} to "%player%"
  97. set {uuid::%player%} to uuid of player
  98. set {team::%arg-2%::lavet} to now
  99. set {team::%arg-2%::id} to {team.ID}
  100. add uuid of player to {team::%{team::%uuid of player%}%::medlemmer::*}
  101.  
  102.  
  103. set {team::%arg-2%::motto} to "Sammen er vi stærkere"
  104.  
  105. set {team::%arg-2%::antal.farver} to 0
  106. set {team::%arg-2%::farve.blå} to false
  107. set {team::%arg-2%::farve.grøn} to false
  108. set {team::%arg-2%::farve.rød} to false
  109. set {team::%arg-2%::farve.orange} to false
  110. set {team::%arg-2%::farve.magenta} to false
  111.  
  112.  
  113. set {team::%arg-2%::mission.1} to "Igang"
  114. set {team::%arg-2%::mission.2} to "Låst"
  115. set {team::%arg-2%::mission.3} to "Låst"
  116. set {team::%arg-2%::mission.4} to "Låst"
  117. set {team::%arg-2%::mission.5} to "Låst"
  118. set {team::%arg-2%::mission.6} to "Låst"
  119. set {team::%arg-2%::mission.7} to "Låst"
  120. set {team::%arg-2%::mission.8} to "Låst"
  121. set {team::%arg-2%::mission.9} to "Låst"
  122. set {team::%arg-2%::mission.10} to "Låst"
  123. set {team::%arg-2%::mission.11} to "Låst"
  124. set {team::%arg-2%::mission.12} to "Låst"
  125. set {team::%arg-2%::mission.13} to "Låst"
  126. set {team::%arg-2%::mission.14} to "Låst"
  127. set {team::%arg-2%::mission.15} to "Låst"
  128. set {team::%arg-2%::mission.16} to "Låst"
  129. set {team::%arg-2%::mission.17} to "Låst"
  130. set {team::%arg-2%::mission.18} to "Låst"
  131. set {team::%arg-2%::mission.19} to "Låst"
  132. set {team::%arg-2%::mission.20} to "Låst"
  133. set {team::%arg-2%::mission.21} to "Låst"
  134. set {team::%arg-2%::mission.22} to "Låst"
  135. set {team::%arg-2%::mission.23} to "Låst"
  136. set {team::%arg-2%::mission.24} to "Låst"
  137.  
  138. subtract 2500 from player's balance
  139. message "{@p}Du har lavet et teamet &b%arg-2%"
  140. else:
  141. send "{@p}Du har ikke nok penge. Et team koster &b2500,-"
  142. else:
  143. send "{@p}Forkert brug af kommandoen. &b/team opret &bnavn"
  144. if arg-1 is "list" or "liste":
  145. if player has permission "*":
  146. send "&8&m---------&r &3&lTEAM &8&m---------"
  147. send "&bListe over alle teams:"
  148. loop {teams::*}:
  149. send "&8- &b%loop-value%"
  150. #if arg-1 is "clear":
  151. # clear {teams::*}
  152. if arg-1 is "forlad" or "leave":
  153. if {team::%uuid of player%} is not set:
  154. message "{@p}Du er ikke medlem af noget team."
  155. message "{@p}Opret et via &b/team opret"
  156. stop
  157. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  158. set {_team} to {team::%uuid of player%}
  159. message "{@p}Du har slettet teamet &b%{_team}%"
  160. remove "%{team::%{_team}%}%" from {teams::*}
  161. loop {team::%{_team}%::medlemmer::*}:
  162. delete {team::%loop-value%}
  163. remove loop-value from {team::%{team::%loop-value%}%::medlemmer::*}
  164. delete {team::%{_team}%::lvlkills}
  165. delete {team::%{_team}%::lvl}
  166. delete {kills.team::%{_team}%}
  167. delete {deaths.team::%{_team}%}
  168. delete {team::%{_team}%::deaths}
  169. delete {team::%{_team}%::ejer}
  170. delete {team::%{_team}%}
  171. clear {team::%{_team}%::medlemmer::*}
  172. delete {team::%uuid of player%}
  173.  
  174. if {team::%uuid of player%} is set:
  175. message "{@p}Der er sket en fejl, kontakt &bFlupMC&f"
  176. else:
  177. loop all players:
  178. if {team::%uuid of player%} is {team::%uuid of loop-player%}:
  179. if player isn't loop-player:
  180. message "{@p}&b%player% &fhar forladt teamet." to loop-player
  181. send "{@p}Du har forladt teamet &b%{team::%uuid of player%}%"
  182. remove uuid of player from {team::%{team::%uuid of player%}%::medlemmer::*}
  183. delete {team::%uuid of player%}
  184. stop
  185. if arg 1 is "invite" or "inviter":
  186. if {team::%uuid of player%} is not set:
  187. message "{@p}Du er ikke medlem af noget team."
  188. message "{@p}Opret et via &b/team opret"
  189. stop
  190. else:
  191. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  192. set {_size} to "%size of {team::%{team::%uuid of player%}%::medlemmer::*}%"
  193. if {team::%{uuid::%arg-2%}%} is set:
  194. message "{@p}&b%arg 2%&f er allerede medlem af et team."
  195. stop
  196. if {team::%player%::invite} is set:
  197. message "{@p}&b%arg 2%&f er allerede inviteret til et team."
  198. send "{@p}Få spilleren til at afvise sin invitation med &b/team afvis"
  199. stop
  200. if size of {team::%{team::%uuid of player%}%::medlemmer::*} is greater or equal to {team::%{team::%uuid of player%}%::maxmem}:
  201. send "{@p}Du kan maksimalt have &b%{team::%{team::%uuid of player%}%::maxmem}% medlemmer"
  202. send "{@p}Du kan købe ekstra medlemspladser i teamshoppen."
  203. stop
  204. set {_player} to arg 2 parsed as a player
  205. set {_playeruuid} to uuid of {_player}
  206. set {_uuidplayer} to "%{_playeruuid}%" parsed as a player
  207. if {team.status::%{_player}%} is "online":
  208. if {team::%{team::%uuid of player%}%::ejer} is not uuid of player:
  209. message "{@p}Det er kun ejeren af teamet der kan invitere flere."
  210. stop
  211. else:
  212. if arg 2 is not set:
  213. message "{@p}Forkert brug af kommandoen. &b/team inviter <navn>"
  214. stop
  215. else:
  216. if {team::%{_player}%::invite} is set:
  217. message "{@p}&b%arg 2% &fer allerede blevet inviteret til et team, få spilleren til at afvise den anden invitation med &b/team afvis&f."
  218. stop
  219. else:
  220. if {team::%{_uuidplayer}%} is set:
  221. message "{@p}&7%{_player}% &fer allerede med i et team."
  222. stop
  223. else:
  224. set {team::%{_player}%::invite} to "%{team::%uuid of player%}%"
  225. message "{@p}Du er blevet inviteret til teamet &3%{team::%uuid of player%}%" to {_player}
  226. #message "{@p}&b&lKLIK HER&f for at joine." to {_player}
  227. execute console command "json %{_player}% {@p}||&b&lKLIK HER||ttp:&b/team accepter||cmd:/team join||&f for at joine."
  228. message "{@p}Du har inviteret &b%{_player}% &ftil teamet."
  229. message "{@p}Spilleren har 30 sekunder til at acceptere."
  230. wait 30 seconds
  231. delete {team::%{_player}%::invite}
  232. stop
  233. else:
  234. message "{@p}Du kan kun invitere spillere der er online."
  235. stop
  236. else:
  237. send "{@p}Det er kun ejeren af teamet der kan invitere flere."
  238. stop
  239.  
  240. if arg-1 is "afvis" or "deny":
  241. if {team::%uuid of player%} is not set:
  242. if {team::%player%::invite} is set:
  243. message "{@p}Du afviste invitationen fra teamet &b%{team::%player%::invite}%"
  244. loop all players:
  245. if {team::%{team::%player%::invite}%::ejer} is uuid of loop-player:
  246. message "{@p}&b%player% &fhar afvist invitationen." to loop-player
  247. delete {team::%player%::invite}
  248. stop
  249. else:
  250. message "{@p}Du er ikke blevet inviteret til et team!"
  251. stop
  252. else:
  253. send "{@p}Du er allerede medlem af teamet &b%{team::%uuid of player%}%"
  254.  
  255.  
  256.  
  257. if arg 1 is "join", "accept" or "accepter":
  258. if {team::%uuid of player%} is set:
  259. send "{@p}Du er allerede medlem af teamet &b%{team::%uuid of player%}%"
  260. stop
  261. else:
  262. if {team::%player%::invite} is set:
  263. if size of {team::%{team::%player%::invite}%::medlemmer::*} isn't greater or equal to {team::%{team::%player%::invite}%::maxmem}:
  264. set {team::%uuid of player%} to {team::%player%::invite}
  265. loop all players:
  266. if {team::%uuid of player%} is {team::%uuid of loop-player%}:
  267. if player isn't loop-player:
  268. send "{@p}&b%player%&f har joinet teamet." to loop-player
  269. add uuid of player to {team::%{team::%player%::invite}%::medlemmer::*}
  270. message "{@p}Du har joinet teamet &b%{team::%player%::invite}%"
  271. set {navn::%uuid of player%} to "%player%"
  272. set {uuid::%player%} to uuid of player
  273. delete {team::%player%::invite}
  274. stop
  275. else:
  276. send "{@p}Teamet har ikke plads til flere spillere."
  277. delete {team::%player%::invite}
  278. stop
  279. else:
  280. send "{@p}Du er ikke blevet inviteret til et team."
  281. stop
  282.  
  283. if arg 1 is "kick":
  284. if {team::%uuid of player%} is not set:
  285. message "{@p}Du er ikke medlem af noget team."
  286. message "{@p}Opret et via &b/team opret"
  287. stop
  288.  
  289. else:
  290. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  291. if arg 2 is not set:
  292. message "{@p}Forkert brug af kommandoen. &b/team kick <navn>"
  293. stop
  294. set {_player} to arg 2 parsed as a player
  295. message "{@p}Du har smidt &b%arg 2% &fud af teamet."
  296. remove {uuid::%arg 2%} from {team::%{team::%uuid of player%}%::medlemmer::*}
  297. message "{@p}Du er blevet smidt ud af teamet &b%{team::%uuid of player%}%" to {_player}
  298. delete {team::%{uuid::%arg-2%}%}
  299. loop all players:
  300. if {team::%uuid of player%} is {team::%uuid of loop-player%}:
  301. if player isn't loop-player:
  302. send "{@p}&b%arg-2%&f er blevet smidt ud af teamet." to loop-player
  303. stop
  304. else:
  305. message "{@p}Det er kun ejeren af teamet der kan smide folk ud."
  306. stop
  307. if arg-1 is "info":
  308. if arg-2 is not set:
  309. if {team::%uuid of player%} is set:
  310. execute player command "team start"
  311. stop
  312. else:
  313. send "{@p}Forkert brug af kommandoen. &b/team info <navn>"
  314. stop
  315. if arg-2 is set:
  316. if {team::%arg-2%} is set:
  317. open chest with 5 rows named "Team Info" to player
  318. wait 3 ticks
  319. if inventory name of player's current inventory is "Team Info":
  320. #----------------------------------------------------------------
  321. loop integers from 0 to 8:
  322. set slot loop-integer of player's current inventory to white stained glass pane named ""
  323. loop integers from 36 to 44:
  324. set slot loop-integer of player's current inventory to blue stained glass pane named ""
  325. #----------------------------------------------------------------
  326. set slot 4 of player's current inventory to sign named "&b&lINFORMATION" with lore "&7Navn&8: &f%{team::%arg-2%}%||&7Motto&8: &f%{team::%{team::%arg-2%}%::motto}%||&7ID&8: &f%{team::%{team::%arg-2%}%::id}%||&7Level&8: &f%{team::%{team::%arg-2%}%::lvl}%||&7Størrelse&8: &a%size of {team::%{team::%arg-2%}%::medlemmer::*}%&8/&c%{team::%{team::%arg-2%}%::maxmem}%||&7Saldo&8: &a$&f%{bank.team::%{team::%arg-2%}%}%||||&7Dræbte&8: &f%{kills.team::%{team::%arg-2%}%}%||&7Dødsfald&8: &f%{deaths.team::%{team::%arg-2%}%}%||&7KDR&8: &f%{kills.team::%{team::%arg-2%}%} / {deaths.team::%{team::%arg-2%}%}%"
  327. #set slot 20 of player's current inventory to book named "&d&lStats" with lore "&7Drab: &d%{kills.team::%{team::%arg-2%}%}%||&7Dødsfald: &d%{deaths.team::%{team::%arg-2%}%}%||&7K/D Ratio: &d%{kills.team::%{team::%arg-2%}%} / {deaths.team::%{team::%arg-2%}%}%||&7Team Level: &d%{team::%{team::%arg-2%}%::lvl}%"
  328. if {team::%{team::%arg-2%}%::lvl} is 1:
  329. if {team::%{team::%arg-2%}%::levelup.1.chest1} is true:
  330. set {_krav1} to "&8 - &aKøbt teamkiste 1"
  331. else:
  332. set {_krav1} to "&8 - &cKøbt teamkiste 1"
  333. if {team::%{team::%arg-2%}%::levelup.1.farve1} is true:
  334. set {_krav2} to "&8 - &aKøbt en teamfarve"
  335. else:
  336. set {_krav2} to "&8 - &cKøbt en teamfarve"
  337. if {kills.team::%{team::%arg-2%}%} is greater or equal to 300:
  338. set {_krav3} to "&8 - &a300 kills i teamet"
  339. else:
  340. set {_krav3} to "&8 - &c300 kills i teamet"
  341. set slot 20 of player's current inventory to emerald named "&2&lLevelup" with lore "&7Krav:||%{_krav1}%||%{_krav2}%||%{_krav3}%"
  342. loop {team::%{team::%arg-2%}%::medlemmer::*}:
  343. if loop-value isn't {team::%{team::%arg-2%}%::ejer}:
  344. add "&8 - &a%{navn::%loop-value%}%||" to {_medlemmer1::*}
  345. set {_medlemmer} to "%{_medlemmer1::*}%"
  346. if {_medlemmer} is "<none>":
  347. set {_medlemmer} to "&8 - &cIngen"
  348. replace all " and " with "" in {_medlemmer}
  349. replace all ", " with "" in {_medlemmer}
  350. set slot 24 of player's current inventory to 386 named "&a&lMedlemmer" with lore "&7Ejer: &a%{team::%{team::%arg-2%}%::ejernavn}%||&7Medlemmer:||%{_medlemmer}%"
  351. else:
  352. set {_arg} to {uuid::%arg-2%}
  353. if {team::%{_arg}%} is set:
  354. open chest with 5 rows named "Team Info" to player
  355. wait 3 ticks
  356. if inventory name of player's current inventory is "Team Info":
  357. #----------------------------------------------------------------
  358. loop integers from 0 to 8:
  359. set slot loop-integer of player's current inventory to white stained glass pane named ""
  360. loop integers from 36 to 44:
  361. set slot loop-integer of player's current inventory to light blue stained glass pane named ""
  362. #----------------------------------------------------------------
  363. set slot 4 of player's current inventory to sign named "&b&lINFORMATION" with lore "&7Navn&8: &f%{team::%{_arg}%}%||&7Motto&8: &f%{team::%{team::%{_arg}%}%::motto}%||&7ID&8: &f%{team::%{team::%{_arg}%}%::id}%||&7Level&8: &f%{team::%{team::%{_arg}%}%::lvl}%||&7Størrelse&8: &a%size of {team::%{team::%{_arg}%}%::medlemmer::*}%&8/&c%{team::%{team::%{_arg}%}%::maxmem}%||&7Saldo&8: &a$&f%{bank.team::%{team::%{_arg}%}%}%||||&7Dræbte&8: &f%{kills.team::%{team::%{_arg}%}%}%||&7Dødsfald&8: &f%{deaths.team::%{team::%{_arg}%}%}%||&7KDR&8: &f%{kills.team::%{team::%{_arg}%}%} / {deaths.team::%{team::%{_arg}%}%}%"
  364. #set slot 20 of player's current inventory to book named "&d&lStats" with lore "&7Drab: &d%{kills.team::%{team::%{_arg}%}%}%||&7Dødsfald: &d%{deaths.team::%{team::%{_arg}%}%}%||&7K/D Ratio: &d%{kills.team::%{team::%{_arg}%}%} / {deaths.team::%{team::%{_arg}%}%}%||&7Team Level: &d%{team::%{team::%{_arg}%}%::lvl}%"
  365. if {team::%{team::%{_arg}%}%::lvl} is 1:
  366. if {team::%{team::%{_arg}%}%::levelup.1.chest1} is true:
  367. set {_krav1} to "&8 - &aKøbt teamkiste 1"
  368. else:
  369. set {_krav1} to "&8 - &cKøbt teamkiste 1"
  370. if {team::%{team::%{_arg}%}%::levelup.1.farve1} is true:
  371. set {_krav2} to "&8 - &aKøbt en teamfarve"
  372. else:
  373. set {_krav2} to "&8 - &cKøbt en teamfarve"
  374. if {kills.team::%{team::%{_arg}%}%} is greater or equal to 300:
  375. set {_krav3} to "&8 - &a300 kills i teamet"
  376. else:
  377. set {_krav3} to "&8 - &c300 kills i teamet"
  378. set slot 20 of player's current inventory to emerald named "&2&lLevelup" with lore "&7Krav:||%{_krav1}%||%{_krav2}%||%{_krav3}%"
  379. loop {team::%{team::%{_arg}%}%::medlemmer::*}:
  380. if loop-value isn't {team::%{team::%{_arg}%}%::ejer}:
  381. add "&8 - &a%{navn::%loop-value%}%||" to {_medlemmer1::*}
  382. set {_medlemmer} to "%{_medlemmer1::*}%"
  383. if {_medlemmer} is "<none>":
  384. set {_medlemmer} to "&8 - &cIngen"
  385. replace all " and " with "" in {_medlemmer}
  386. replace all ", " with "" in {_medlemmer}
  387. set slot 24 of player's current inventory to 386 named "&a&lMedlemmer" with lore "&7Ejer: &a%{team::%{team::%{_arg}%}%::ejernavn}%||&7Medlemmer:||%{_medlemmer}%"
  388. else:
  389. send "{@p}Dette er ikke et team."
  390. if arg-1 is "indsæt", "add" or "bank":
  391. if {team::%uuid of player%} is not set:
  392. message "{@p}Du er ikke medlem af noget team."
  393. message "{@p}Opret et via &b/team opret"
  394. stop
  395. else:
  396. if arg-2 is set:
  397. set {_bal} to arg-2 parsed as a number
  398. if player's balance is greater or equal to {_bal}:
  399. subtract {_bal} from player's balance
  400. add {_bal} to {bank.team::%{team::%uuid of player%}%}
  401. send "{@p}Du tilføjede &b%arg-2%,-&f til jeres team &8(&b%{bank.team::%{team::%uuid of player%}%}%,- ialt&8)"
  402. else:
  403. send "{@p}Du har ikke penge nok til dette."
  404. else:
  405. message "{@p}Forkert brug af kommandoen. &b/team indsæt <antal>"
  406. stop
  407. if arg-1 is "start":
  408. if {team::%uuid of player%} is set:
  409. open chest with 5 rows named "Team Menu" to player
  410. wait 3 ticks
  411. if inventory name of player's current inventory is "Team Menu":
  412. #----------------------------------------------------------------
  413. loop integers from 0 to 8:
  414. set slot loop-integer of player's current inventory to white stained glass pane named ""
  415. loop integers from 36 to 44:
  416. set slot loop-integer of player's current inventory to light blue stained glass pane named ""
  417.  
  418. if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
  419. set {_kiste1} to "&7Adgang til teamkiste 1: &aJa"
  420. else:
  421. set {_kiste1} to "&7Adgang til teamkiste 1: &cNej"
  422. if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
  423. set {_kiste2} to "&7Adgang til teamkiste 2: &aJa"
  424. else:
  425. set {_kiste2} to "&7Adgang til teamkiste 2: &cNej"
  426. if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
  427. set {_kiste3} to "&7Adgang til teamkiste 3: &aJa"
  428. else:
  429. set {_kiste3} to "&7Adgang til teamkiste 3: &cNej"
  430. set slot 18 of player's current inventory to chest named "&6&lTeam Kister" with lore "%{_kiste1}%||%{_kiste2}%||%{_kiste3}%||&r||&7Klik for at åbne dine teamkister"
  431. loop {team::%{team::%uuid of player%}%::medlemmer::*}:
  432. if loop-value isn't {team::%{team::%uuid of player%}%::ejer}:
  433. add "&8 - &a%{navn::%loop-value%}%||" to {_medlemmer1::*}
  434. set {_medlemmer} to "%{_medlemmer1::*}%"
  435. if {_medlemmer} is "<none>":
  436. set {_medlemmer} to "&8 - &cIngen"
  437. replace all " and " with "" in {_medlemmer}
  438.  
  439. replace all ", " with "" in {_medlemmer}
  440.  
  441. set slot 20 of player's current inventory to 386 named "&a&lMedlemmer &8(&a%size of {team::%{team::%uuid of player%}%::medlemmer::*}%&7/&a%{team::%{team::%uuid of player%}%::maxmem}%&8)" with lore "&7Ejer: &a%{team::%{team::%uuid of player%}%::ejernavn}%||&7Medlemmer:||%{_medlemmer}%"
  442. #set slot 13 of player's current inventory to book named "&d&lStats" with lore "&7Drab: &d%{kills.team::%{team::%uuid of player%}%}%||&7Dødsfald: &d%{deaths.team::%{team::%uuid of player%}%}%||&7K/D Ratio: &d%{kills.team::%{team::%uuid of player%}%} / {deaths.team::%{team::%uuid of player%}%}%||&7Team Level: &d%{team::%{team::%uuid of player%}%::lvl}%"
  443. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
  444. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  445. set slot 24 of player's current inventory to gold ingot named "&e&lTeam Shop" with lore "&7Bank: &e%{bank.team::%{team::%uuid of player%}%}%,-||&r||&7Klik for at købe ting til dit team"
  446. else:
  447. set slot 24 of player's current inventory to 166 named "&4&lIKKE ADGANG" with lore "&7Kun ejeren kan købe i shoppen"
  448. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
  449. set slot 24 of player's current inventory to gold ingot named "&e&lTeam Shop" with lore "&7Bank: &e%{bank.team::%{team::%uuid of player%}%}%,-||&r||&7Klik for at købe ting til dit team"
  450. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
  451. set {_indstilliger1} to "&7Adgang til shop: &aKun ejer"
  452. else:
  453. set {_indstilliger1} to "&7Adgang til shop: &aAlle"
  454. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
  455. set {_indstilliger2} to "&7Adgang til teamfarver: &aKun ejer"
  456. else:
  457. set {_indstilliger2} to "&7Adgang til teamfarver: &aAlle"
  458. if {team::%{team::%uuid of player%}%::teamdamaga} is false:
  459. set {_indstilliger3} to "&7Team damage: &cFra"
  460. else:
  461. set {_indstilliger3} to "&7Team damage: &aTil"
  462. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  463. set {_indstilliger4} to "&7Klik for at ændre"
  464. else:
  465. set {_indstilliger4} to "&cKun ejeren kan ændre"
  466.  
  467. set slot 40 of player's current inventory to tripwire hook named "&7&lINDSTILLINGER" with lore "%{_indstilliger1}%||%{_indstilliger2}%||%{_indstilliger3}%||&r||%{_indstilliger4}%"
  468. if {team::%{team::%uuid of player%}%::lvl} is 1:
  469. if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
  470. set {_krav1} to "&8 - &aKøbt teamkiste 1"
  471. else:
  472. set {_krav1} to "&8 - &cKøbt teamkiste 1"
  473. if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
  474. set {_krav2} to "&8 - &aKøbt en teamfarve"
  475. else:
  476. set {_krav2} to "&8 - &cKøbt en teamfarve"
  477. if {kills.team::%{team::%uuid of player%}%} is greater or equal to 300:
  478. set {_krav3} to "&8 - &a300 kills i teamet"
  479. else:
  480. set {_krav3} to "&8 - &c300 kills i teamet"
  481. set {_krav4} to "&cKun ejeren kan levelup"
  482. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  483. set {_krav4} to "&cDu har ikke klaret alt"
  484. if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
  485. if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
  486. if {kills.team::%{team::%uuid of player%}%} is greater or equal to 300:
  487. set {_krav4} to "&7Klik for at levelup"
  488. if {team::%{team::%uuid of player%}%::lvl} is 2:
  489. if {team::%{team::%uuid of player%}%::levelup.2.chest2} is true:
  490. set {_krav1} to "&8 - &aKøbt teamkiste 2"
  491. else:
  492. set {_krav1} to "&8 - &cKøbt teamkiste 2"
  493. if {team::%{team::%uuid of player%}%::levelup.2.medlem2} is true:
  494. set {_krav2} to "&8 - &aKøbt 2 ekstra medlem"
  495. else:
  496. set {_krav2} to "&8 - &aKøbt 2 ekstra medlem"
  497. if {kills.team::%{team::%uuid of player%}%} is greater or equal to 1500:
  498. set {_krav3} to "&8 - &a1500 kills i teamet"
  499. else:
  500. set {_krav3} to "&8 - &c1500 kills i teamet"
  501. set {_krav4} to "&cKun ejeren kan levelup"
  502. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  503. set {_krav4} to "&cDu har ikke klaret alt"
  504. if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
  505. if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
  506. if {kills.team::%{team::%uuid of player%}%} is greater or equal to 1500:
  507. set {_krav4} to "&7Klik for at levelup"
  508.  
  509. set slot 22 of player's current inventory to emerald named "&2&lLevelup" with lore "&7Krav:||%{_krav1}%||%{_krav2}%||%{_krav3}%||&r||%{_krav4}%"
  510. if {team::%{team::%uuid of player%}%::lvl} is 3:
  511. set slot 22 of player's current inventory to emerald named "&2&lLevelup" with lore "&aMaks level."
  512. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
  513. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  514. set slot 26 of player's current inventory to bonemeal named "&f&lTEAM FARVER" with lore "&7I har låst op for &a%{team::%{team::%uuid of player%}%::antal.farver}%&7/&25&7 farver||&r||&7Klik for at ændre jeres teamfarve"
  515. else:
  516. set slot 26 of player's current inventory to 166 named "&4&lIKKE ADGANG" with lore "&7Kun ejeren kan ændre teamfarven"
  517. else:
  518. set slot 26 of player's current inventory to bonemeal named "&f&lTEAM FARVER" with lore "&7I har låst op for &a%{team::%{team::%uuid of player%}%::antal.farver}%&7/&25&7 farver||&r||&7Klik for at ændre jeres teamfarve"
  519. set slot 4 of player's current inventory to sign named "&b&lINFORMATION" with lore "&7Navn&8: &f%{team::%uuid of player%}%||&7Motto&8: &f%{team::%{team::%uuid of player%}%::motto}%||&7ID&8: &f%{team::%{team::%uuid of player%}%::id}%||&7Level&8: &f%{team::%{team::%uuid of player%}%::lvl}%||&7Størrelse&8: &a%size of {team::%{team::%uuid of player%}%::medlemmer::*}%&8/&c%{team::%{team::%uuid of player%}%::maxmem}%||&7Saldo&8: &a$&f%{bank.team::%{team::%uuid of player%}%}%||||&7Dræbte&8: &f%{kills.team::%{team::%uuid of player%}%}%||&7Dødsfald&8: &f%{deaths.team::%{team::%uuid of player%}%}%||&7KDR&8: &f%{kills.team::%{team::%uuid of player%}%} / {deaths.team::%{team::%uuid of player%}%}%"
  520.  
  521. if arg-1 is "chest":
  522. if {team::%uuid of player%} is not set:
  523. message "{@p}Du er ikke medlem af noget team."
  524. message "{@p}Opret et via &b/team opret"
  525. stop
  526. else:
  527. open chest with 1 rows named "&6&lTEAM KISTER" to player
  528. wait 3 ticks
  529. if inventory name of player's current inventory is "&6&lTEAM KISTER":
  530. if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
  531. set slot 2 of player's current inventory to chest named "&6&lTEAM KISTE ##1"
  532. else:
  533. set slot 2 of player's current inventory to chest named "&4&lTEAM KISTE ##1" with lore "&7Køb adgang i teamshoppen"
  534.  
  535. if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
  536. set slot 4 of player's current inventory to chest named "&6&lTEAM KISTE ##2"
  537. else:
  538. set slot 4 of player's current inventory to chest named "&4&lTEAM KISTE ##2" with lore "&7Køb adgang i teamshoppen"
  539.  
  540. if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
  541. set slot 6 of player's current inventory to chest named "&6&lTEAM KISTE ##3"
  542. else:
  543. set slot 6 of player's current inventory to chest named "&4&lTEAM KISTE ##3" with lore "&7Køb adgang i teamshoppen"
  544. if arg-1 is "top53235":
  545. if arg-2 is "kills" or "drab":
  546. loop {kills.team::*}:
  547. add 1 to {_size}
  548. if {_low.to.high.list::%loop-value%} is not set:
  549. set {_low.to.high.list::%loop-value%} to loop-index
  550. else:
  551. set {_n} to 0
  552. loop {_size} times:
  553. set {_n} to {_n}+1
  554. {_low.to.high.list::%loop-value-1%.%{_n}%} is not set
  555. set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
  556. stop loop
  557. wait 1 tick
  558. set {_n} to size of {_low.to.high.list::*}
  559. loop {_low.to.high.list::*}:
  560. set {_high.to.low.list::%{_n}%} to loop-value
  561. set {_n} to {_n}-1
  562. wait 1 tick
  563. send "&8&m-------&r &3&lTEAMTOP &8&m-------"
  564. send ""
  565. set {_result} to 0
  566. loop {_high.to.low.list::*}:
  567. add 1 to {_result}
  568. set {_navn} to {team::%loop-value%}
  569. send "&3%{_result}% &8» &b%{_navn}% &8- &b%{kills.team::%loop-value%}% &7drab &8(&bK/D: %{kills.team::%loop-value%} / {deaths.team::%loop-value%}%&8)"
  570. if {_result} is 10:
  571. stop
  572. if arg-2 is "deaths" or "døde":
  573. loop {deaths.team::*}:
  574. add 1 to {_size}
  575. if {_low.to.high.list::%loop-value%} is not set:
  576. set {_low.to.high.list::%loop-value%} to loop-index
  577. else:
  578. set {_n} to 0
  579. loop {_size} times:
  580. set {_n} to {_n}+1
  581. {_low.to.high.list::%loop-value-1%.%{_n}%} is not set
  582. set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
  583. stop loop
  584. wait 1 tick
  585. set {_n} to size of {_low.to.high.list::*}
  586. loop {_low.to.high.list::*}:
  587. set {_high.to.low.list::%{_n}%} to loop-value
  588. set {_n} to {_n}-1
  589. wait 1 tick
  590. send "&8&m-------&r &3&lTEAMTOP &8&m-------"
  591. send ""
  592. set {_result} to 0
  593. loop {_high.to.low.list::*}:
  594. add 1 to {_result}
  595. set {_navn} to {team::%loop-value%}
  596. send "&3%{_result}% &8» &b%{_navn}% &8- &b%{kills.team::%loop-value%}% &7dødsfald &8(&bK/D: %{kills.team::%loop-value%} / {deaths.team::%loop-value%}%&8)"
  597. if {_result} is 10:
  598. stop
  599. if arg-2 is "bank" or "penge":
  600. loop {bank.team::*}:
  601. add 1 to {_size}
  602. if {_low.to.high.list::%loop-value%} is not set:
  603. set {_low.to.high.list::%loop-value%} to loop-index
  604. else:
  605. set {_n} to 0
  606. loop {_size} times:
  607. set {_n} to {_n}+1
  608. {_low.to.high.list::%loop-value-1%.%{_n}%} is not set
  609. set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
  610. stop loop
  611. wait 1 tick
  612. set {_n} to size of {_low.to.high.list::*}
  613. loop {_low.to.high.list::*}:
  614. set {_high.to.low.list::%{_n}%} to loop-value
  615. set {_n} to {_n}-1
  616. wait 1 tick
  617. send "&8&m-------&r &3&lTEAMTOP &8&m-------"
  618. send ""
  619. set {_result} to 0
  620. loop {_high.to.low.list::*}:
  621. add 1 to {_result}
  622. set {_navn} to {team::%loop-value%}
  623. send "&3%{_result}% &8» &b%{_navn}% &8- &b%{bank.team::%loop-value%}%,-"
  624. if {_result} is 10:
  625. stop
  626. on inventory click:
  627. if inventory name of player's current inventory is "&6&lTEAM KISTER":
  628. cancel event
  629. if name of clicked item is "&6&lTEAM KISTE ##1":
  630. if {team::%{team::%uuid of player%}%.kiste1.åben} is not set:
  631. invoke "team.page1" from player
  632. set {team::%{team::%uuid of player%}%.kiste1.åben} to true
  633. stop
  634. else:
  635. send "{@p}Der er allerede en spiller i kisten &8(&b1&8)"
  636. close player's inventory
  637. stop
  638. if name of clicked item is "&6&lTEAM KISTE ##2":
  639. if {team::%{team::%uuid of player%}%.kiste2.åben} is not set:
  640. invoke "team.page2" from player
  641. set {team::%{team::%uuid of player%}%.kiste2.åben} to true
  642. stop
  643. else:
  644. send "{@p}Der er allerede en spiller i kisten &8(&b2&8)"
  645. close player's inventory
  646. stop
  647. if name of clicked item is "&6&lTEAM KISTE ##3":
  648. if {team::%{team::%uuid of player%}%.kiste3.åben} is not set:
  649. invoke "team.page3" from player
  650. set {team::%{team::%uuid of player%}%.kiste3.åben} to true
  651. stop
  652. else:
  653. send "{@p}Der er allerede en spiller i kisten &8(&b3&8)"
  654. close player's inventory
  655. stop
  656.  
  657.  
  658.  
  659.  
  660. on inventory close:
  661. if inventory name of player's current inventory is "&6&lTEAM KISTE &e##1":
  662. set {_slot} to 0
  663. loop 54 times:
  664. set {team::1::%{_slot}%::%{team::%uuid of player%}%} to slot {_slot} of player's current inventory
  665. add 1 to {_slot}
  666. delete {team::%{team::%uuid of player%}%.kiste1.åben}
  667. if inventory name of player's current inventory is "&6&lTEAM KISTE &e##2":
  668. set {_slot} to 0
  669. loop 54 times:
  670. set {team::2::%{_slot}%::%{team::%uuid of player%}%} to slot {_slot} of player's current inventory
  671. add 1 to {_slot}
  672. delete {team::%{team::%uuid of player%}%.kiste2.åben}
  673. if inventory name of player's current inventory is "&6&lTEAM KISTE &e##3":
  674. set {_slot} to 0
  675. loop 54 times:
  676. set {team::3::%{_slot}%::%{team::%uuid of player%}%} to slot {_slot} of player's current inventory
  677. add 1 to {_slot}
  678. delete {team::%{team::%uuid of player%}%.kiste3.åben}
  679. sub "team.page1":
  680. wait 3 ticks
  681. set {_p} to parameter 1
  682. open chest with 6 rows named "&6&lTEAM KISTE &e##1" to {_p}
  683. set {_slot} to 0
  684. loop 54 times:
  685. set slot {_slot} of {_p}'s current inventory to {team::1::%{_slot}%::%{team::%uuid of parameter 1%}%}
  686. add 1 to {_slot}
  687. sub "team.page2":
  688. wait 3 ticks
  689. set {_p} to parameter 1
  690. open chest with 6 rows named "&6&lTEAM KISTE &e##2" to {_p}
  691. set {_slot} to 0
  692. loop 54 times:
  693. set slot {_slot} of {_p}'s current inventory to {team::2::%{_slot}%::%{team::%uuid of parameter 1%}%}
  694. add 1 to {_slot}
  695. sub "team.page3":
  696. wait 3 ticks
  697. set {_p} to parameter 1
  698. open chest with 6 rows named "&6&lTEAM KISTE &e##3" to {_p}
  699. set {_slot} to 0
  700. loop 54 times:
  701. set slot {_slot} of {_p}'s current inventory to {team::3::%{_slot}%::%{team::%uuid of parameter 1%}%}
  702. add 1 to {_slot}
  703.  
  704.  
  705.  
  706.  
  707.  
  708.  
  709.  
  710. command /tk:
  711. aliases: /bruhnetwork:tk, /bruhnetwork:teamkiste, /teamkiste
  712. trigger:
  713. execute player command "team chest"
  714. on inventory close:
  715. loop all items in the player's inventory:
  716. if name of loop-item is "&6&lShop" or "&4&lTeam Damage" or "&f&lTeam Farver":
  717. remove loop-item from the player
  718. on inventory click:
  719. if inventory name of player's current inventory is "Team Indstillinger":
  720. cancel event
  721. if name of clicked item is "&6&lShop":
  722. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
  723. set {team::%{team::%uuid of player%}%::adgangtil.shop} to "Ejer"
  724. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
  725. set {_inds1} to "&7Adgang: &eAlle"
  726. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
  727. set {_inds1} to "&7Adgang: &eKun ejer"
  728. set slot 20 of player's current inventory to gold nugget named "&6&lShop" with lore "%{_inds1}%||&r||&7Klik for at ændre"
  729. stop
  730. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
  731. set {team::%{team::%uuid of player%}%::adgangtil.shop} to "Alle"
  732. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
  733. set {_inds1} to "&7Adgang: &eAlle"
  734. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
  735. set {_inds1} to "&7Adgang: &eKun ejer"
  736. set slot 20 of player's current inventory to gold nugget named "&6&lShop" with lore "%{_inds1}%||&r||&7Klik for at ændre"
  737. stop
  738. if name of clicked item is "&4&lTeam Damage":
  739. if {team::%{team::%uuid of player%}%::teamdamaga} is false:
  740. set {team::%{team::%uuid of player%}%::teamdamaga} to true
  741. if {team::%{team::%uuid of player%}%::teamdamaga} is false:
  742. set {_inds2} to "&7Aktiveret: &cFra"
  743. if {team::%{team::%uuid of player%}%::teamdamaga} is true:
  744. set {_inds2} to "&7Aktiveret: &cTil"
  745. set slot 22 of player's current inventory to redstone named "&4&lTeam Damage" with lore "%{_inds2}%||&r||&7Klik for at ændre"
  746. stop
  747. if {team::%{team::%uuid of player%}%::teamdamaga} is true:
  748. set {team::%{team::%uuid of player%}%::teamdamaga} to false
  749. if {team::%{team::%uuid of player%}%::teamdamaga} is false:
  750. set {_inds2} to "&7Aktiveret: &cFra"
  751. if {team::%{team::%uuid of player%}%::teamdamaga} is true:
  752. set {_inds2} to "&7Aktiveret: &cTil"
  753. set slot 22 of player's current inventory to redstone named "&4&lTeam Damage" with lore "%{_inds2}%||&r||&7Klik for at ændre"
  754. stop
  755. if name of clicked item is "&f&lTeam Farver":
  756. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
  757. set {team::%{team::%uuid of player%}%::adgangtil.farve} to "Ejer"
  758. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
  759. set {_inds3} to "&7Aktiveret: &fAlle"
  760. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
  761. set {_inds3} to "&7Aktiveret: &fEjer"
  762. set slot 24 of player's current inventory to bonemeal named "&f&lTeam Farver" with lore "%{_inds3}%||&r||&7Klik for at ændre"
  763. stop
  764. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
  765. set {team::%{team::%uuid of player%}%::adgangtil.farve} to "Alle"
  766. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
  767. set {_inds3} to "&7Adgang: &fAlle"
  768. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
  769. set {_inds3} to "&7Adgang: &fEjer"
  770. set slot 24 of player's current inventory to bonemeal named "&f&lTeam Farver" with lore "%{_inds3}%||&r||&7Klik for at ændre"
  771. stop
  772. if name of clicked item is "&4&lTILBAGE":
  773. wait 1 tick
  774. execute player command "team start"
  775. stop
  776. on inventory click:
  777. if inventory name of player's current inventory is "Team Shop":
  778. cancel event
  779. if name of clicked item is "&4&lTILBAGE":
  780. wait 1 tick
  781. execute player command "team start"
  782. stop
  783. if name of clicked item is "&3&l+1 MEDLEM":
  784. if {team::%{team::%uuid of player%}%::maxmem} is 3:
  785. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 10000:
  786. subtract 10000 from {bank.team::%{team::%uuid of player%}%}
  787. add 1 to {team::%{team::%uuid of player%}%::maxmem}
  788. send "{@p}Du købte &b1 ekstra&f plads i teamet &8(&b%{team::%{team::%uuid of player%}%::maxmem}% pladser&8)"
  789. close player's inventory
  790. stop
  791. else:
  792. send "{@p}Dit team har ikke nok penge."
  793. if {team::%{team::%uuid of player%}%::maxmem} is 4:
  794. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 25000:
  795. subtract 25000 from {bank.team::%{team::%uuid of player%}%}
  796. add 1 to {team::%{team::%uuid of player%}%::maxmem}
  797. set {team::%{team::%uuid of player%}%::levelup.2.medlem2} to true
  798. send "{@p}Du købte &b1 ekstra&f plads i teamet &8(&b%{team::%{team::%uuid of player%}%::maxmem}% pladser&8)"
  799. close player's inventory
  800. stop
  801. else:
  802. send "{@p}Dit team har ikke nok penge."
  803. if name of clicked item is "&3&l+1 TEAMKISTE":
  804. if {team::%{team::%uuid of player%}%::adgang.til.chest1} is false:
  805. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 5000:
  806. subtract 5000 from {bank.team::%{team::%uuid of player%}%}
  807. set {team::%{team::%uuid of player%}%::levelup.1.chest1} to true
  808. set {team::%{team::%uuid of player%}%::adgang.til.chest1} to true
  809. send "{@p}Du købte adgang til &bteam kiste 1"
  810. close player's inventory
  811. stop
  812. else:
  813. send "{@p}Dit team har ikke nok penge."
  814. close player's inventory
  815. stop
  816. if {team::%{team::%uuid of player%}%::adgang.til.chest2} is false:
  817. if {team::%{team::%uuid of player%}%::lvl} isn't 1:
  818. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 15000:
  819. subtract 15000 from {bank.team::%{team::%uuid of player%}%}
  820. set {team::%{team::%uuid of player%}%::adgang.til.chest2} to true
  821. set {team::%{team::%uuid of player%}%::levelup.2.chest2} to true
  822. send "{@p}Du købte adgang til &bteam kiste 2"
  823. close player's inventory
  824. stop
  825. else:
  826. send "{@p}Dit team har ikke nok penge."
  827. close player's inventory
  828. stop
  829. else:
  830. send "{@p}Lås op for dette i level 2."
  831. close player's inventory
  832. stop
  833. if {team::%{team::%uuid of player%}%::adgang.til.chest3} is false:
  834. if {team::%{team::%uuid of player%}%::lvl} is 3:
  835. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 30000:
  836. subtract 30000 from {bank.team::%{team::%uuid of player%}%}
  837. set {team::%{team::%uuid of player%}%::adgang.til.chest3} to true
  838. send "{@p}Du købte adgang til &bteam kiste 3"
  839. close player's inventory
  840. stop
  841. else:
  842. send "{@p}Dit team har ikke nok penge."
  843. close player's inventory
  844. stop
  845. else:
  846. send "{@p}Lås op for dette i level 3."
  847. close player's inventory
  848. stop
  849. if name of clicked item is "&a&lGRØN TEAMFARVE":
  850. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 7000:
  851. subtract 7000 from {bank.team::%{team::%uuid of player%}%}
  852. set {team::%{team::%uuid of player%}%::farve.grøn} to true
  853. add 1 to {team::%{team::%uuid of player%}%::antal.farver}
  854. send "{@p}Du købte &agrøn &7teamfarve!"
  855. set {team::%{team::%{team::%uuid of player%}%}%::levelup.1.farve1} to true
  856. close player's inventory
  857. stop
  858. else:
  859. send "{@p}Dit team har ikke nok penge."
  860. close player's inventory
  861. stop
  862. if name of clicked item is "&b&lBLÅ TEAMFARVE":
  863. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 15000:
  864. subtract 15000 from {bank.team::%{team::%uuid of player%}%}
  865. set {team::%{team::%uuid of player%}%::farve.blå} to true
  866. add 1 to {team::%{team::%uuid of player%}%::antal.farver}
  867. set {team::%{team::%{team::%uuid of player%}%}%::levelup.1.farve1} to true
  868. send "{@p}Du købte &bblå &fteamfarve!"
  869. close player's inventory
  870. stop
  871. else:
  872. send "{@p}Dit team har ikke nok penge."
  873. close player's inventory
  874. stop
  875. if name of clicked item is "&c&lRØD TEAMFARVE":
  876. if {bank.team::%{team::%uuid of player%}%} is greater or equal to 22000:
  877. subtract 22000 from {bank.team::%{team::%uuid of player%}%}
  878. set {team::%{team::%uuid of player%}%::farve.rød} to true
  879. add 1 to {team::%{team::%uuid of player%}%::antal.farver}
  880. set {team::%{team::%{team::%uuid of player%}%}%::levelup.1.farve1} to true
  881. send "{@p}Du købte &crød &fteamfarve!"
  882. close player's inventory
  883. stop
  884. else:
  885. send "{@p}Dit team har ikke nok penge."
  886. close player's inventory
  887. stop
  888. on inventory click:
  889. if inventory name of player's current inventory is "Team Menu":
  890. cancel event
  891. if name of clicked item is "&2&lLevelup":
  892. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  893. if {team::%{team::%uuid of player%}%::lvl} is 1:
  894. if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
  895. if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
  896. if {kills.team::%{team::%uuid of player%}%} is greater or equal to 300:
  897. set {team::%{team::%uuid of player%}%::lvl} to 2
  898. set {team::%{team::%uuid of player%}%::farve.orange} to true
  899. add 1 to {team::%{team::%uuid of player%}%::antal.farver}
  900. broadcast "{@p}Teamet &b&l%{team::%uuid of player%}%&f er steget i level &b%{team::%{team::%uuid of player%}%::lvl}%"
  901. close player's inventory
  902. stop
  903. if {team::%{team::%uuid of player%}%::lvl} is 2:
  904. if {team::%{team::%uuid of player%}%::levelup.2.chest2} is true:
  905. if {team::%{team::%uuid of player%}%::levelup.2.medlem2} is true:
  906. if {kills.team::%{team::%uuid of player%}%} is greater or equal to 1500:
  907. set {team::%{team::%uuid of player%}%::lvl} to 3
  908. set {team::%{team::%uuid of player%}%::farve.magenta} to true
  909. add 1 to {team::%{team::%uuid of player%}%::antal.farver}
  910. broadcast "{@p}Teamet &b&l%{team::%uuid of player%}%&f er steget i level &b%{team::%{team::%uuid of player%}%::lvl}%"
  911. close player's inventory
  912. stop
  913. if {team::%{team::%uuid of player%}%::lvl} is 3:
  914. close player's inventory
  915. stop
  916. else:
  917. send "{@p}Kun ejeren kan levelup teamet."
  918. close player's inventory
  919. stop
  920.  
  921. if name of clicked item is "&f&lTeam Farver":
  922. open chest with 5 rows named "Team Farver" to player
  923. wait 3 ticks
  924. if inventory name of player's current inventory is "Team Farver":
  925. loop integers from 0 to 8:
  926. set slot loop-integer of player's current inventory to 160 named ""
  927. loop integers from 36 to 44:
  928. set slot loop-integer of player's current inventory to 160:3 named ""
  929. set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
  930. set slot 13 of player's current inventory to gray dye named "&7&lGrå" with lore "&7Klik for at aktiverer"
  931. if {team::%{team::%uuid of player%}%::farve.orange} is true:
  932. set slot 20 of player's current inventory to orange dye named "&6&lOrange" with lore "&7Klik for at aktiverer"
  933. else:
  934. set slot 20 of player's current inventory to orange dye named "&6&lOrange" with lore "&7Fås i level 2"
  935. if {team::%{team::%uuid of player%}%::farve.magenta} is true:
  936. set slot 21 of player's current inventory to magenta dye named "&d&lMagenta" with lore "&7Klik for at aktiverer"
  937. else:
  938. set slot 21 of player's current inventory to magenta dye named "&d&lMagenta" with lore "&7Fås i level 3"
  939. if {team::%{team::%uuid of player%}%::farve.grøn} is true:
  940. set slot 22 of player's current inventory to light green dye named "&a&lGrøn" with lore "&7Klik for at aktiverer"
  941. else:
  942. set slot 22 of player's current inventory to light green dye named "&a&lGrøn" with lore "&7Fås i teamshoppen."
  943. if {team::%{team::%uuid of player%}%::farve.blå} is true:
  944. set slot 23 of player's current inventory to light blue dye named "&b&lBlå" with lore "&7Klik for at aktiverer"
  945. else:
  946. set slot 23 of player's current inventory to light blue dye named "&b&lBlå" with lore "&7Fås i teamshoppen."
  947. if {team::%{team::%uuid of player%}%::farve.rød} is true:
  948. set slot 24 of player's current inventory to rose red named "&c&lRød" with lore "&7Klik for at aktiverer"
  949. else:
  950. set slot 24 of player's current inventory to rose red named "&c&lRød" with lore "&7Fås i teamshoppen."
  951. stop
  952. if name of clicked item is "&6&lTeam Kister":
  953. wait 1 ticks
  954. execute player command "tk"
  955. stop
  956. if name of clicked item is "&e&lTeam Shop":
  957. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
  958. open chest with 5 rows named "Team Shop" to player
  959. wait 3 ticks
  960. if inventory name of player's current inventory is "Team Shop":
  961. loop integers from 0 to 8:
  962. set slot loop-integer of player's current inventory to white stained glass pane named ""
  963. loop integers from 36 to 44:
  964. set slot loop-integer of player's current inventory to light blue stained glass pane named ""
  965. set slot 4 of player's current inventory to book named "&3&lTEAM BANK" with lore "&7Bank: &b%{bank.team::%{team::%uuid of player%}%}%,-"
  966. set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
  967. if {team::%{team::%uuid of player%}%::maxmem} is 3:
  968. set {_pris} to "&7Pris&8: &a10000,-"
  969. if {team::%{team::%uuid of player%}%::maxmem} is 4:
  970. set {_pris} to "&7Pris&8: &a25000,-"
  971. set slot 19 of player's current inventory to book named "&3&l+1 MEDLEM" with lore "&7Køb adgang til 1 ekstra medlem||&r||%{_pris}%"
  972. if {team::%{team::%uuid of player%}%::maxmem} is 5:
  973. set slot 19 of player's current inventory to book named "&4&lMAKS" with lore "&cDu har købt adgang til maks antal medlemmer."
  974. if {team::%{team::%uuid of player%}%::adgang.til.chest1} is false:
  975. set slot 20 of player's current inventory to chest named "&3&l+1 TEAMKISTE" with lore "&7Køb adgang til 1 ekstra team kiste||&r||&7Pris&8: &a5000,-"
  976. if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
  977. if {team::%{team::%uuid of player%}%::lvl} is 1:
  978. set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 2."
  979. else:
  980. set slot 20 of player's current inventory to chest named "&3&l+1 TEAMKISTE" with lore "&7Køb adgang til 1 ekstra team kiste||&r||&7Pris&8: &a15000,-"
  981. if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
  982. if {team::%{team::%uuid of player%}%::lvl} isn't 3:
  983. set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 3."
  984. else:
  985. set slot 20 of player's current inventory to chest named "&3&l+1 TEAMKISTE" with lore "&7Køb adgang til 1 ekstra team kiste||&r||&7Pris&8: &a30000,-"
  986. if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
  987. set slot 20 of player's current inventory to chest named "&4&lMAKS" with lore "&cDu har låst op for maks team kister."
  988.  
  989. if {team::%{team::%uuid of player%}%::farve.grøn} is false:
  990. set slot 21 of player's current inventory to light green dye named "&a&lGRØN TEAMFARVE" with lore "&7Køb adgang til &agrøn&7 teamfarve||&r||&7Pris&8:&a 7000,-"
  991. else:
  992. set slot 21 of player's current inventory to light green dye named "&a&lGRØN TEAMFARVE!" with lore "&7Allerede købt"
  993. if {team::%{team::%uuid of player%}%::farve.blå} is false:
  994. set slot 22 of player's current inventory to light blue dye named "&b&lBLÅ TEAMFARVE" with lore "&7Køb adgang til &bblå&7 teamfarve||&r||&7Pris&8:&a 15000,-"
  995. else:
  996. set slot 22 of player's current inventory to light blue dye named "&b&lBLÅ TEAMFARVE!" with lore "&7Allerede købt"
  997. if {team::%{team::%uuid of player%}%::farve.rød} is false:
  998. set slot 23 of player's current inventory to rose red named "&c&lRØD TEAMFARVE" with lore "&7Køb adgang til &crød&7 teamfarve||&r||&7Pris&8:&a 22000,-"
  999. else:
  1000. set slot 23 of player's current inventory to rose red named "&c&lRØD TEAMFARVE!" with lore "&7Allerede købt"
  1001. set slot 24 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
  1002. set slot 25 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
  1003. stop
  1004. else:
  1005. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  1006. open chest with 5 rows named "Team Shop" to player
  1007. wait 3 ticks
  1008. if inventory name of player's current inventory is "Team Shop":
  1009. loop integers from 0 to 8:
  1010. set slot loop-integer of player's current inventory to white stained glass pane named ""
  1011. loop integers from 36 to 44:
  1012. set slot loop-integer of player's current inventory to light blue stained glass pane named ""
  1013. set slot 4 of player's current inventory to book named "&3&lTEAM BANK" with lore "&7Bank: &b%{bank.team::%{team::%uuid of player%}%}%,-"
  1014. set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
  1015. if {team::%{team::%uuid of player%}%::maxmem} is 3:
  1016. set {_pris} to "&7Pris&8: &a10000,-"
  1017. if {team::%{team::%uuid of player%}%::maxmem} is 4:
  1018. set {_pris} to "&7Pris&8: &a25000,-"
  1019. set slot 19 of player's current inventory to book named "&3&l+1 MEDLEM" with lore "&7Køb adgang til 1 ekstra medlem||&r||%{_pris}%"
  1020. if {team::%{team::%uuid of player%}%::maxmem} is 5:
  1021. set slot 19 of player's current inventory to book named "&4&lMAKS" with lore "&cDu har købt adgang til maks antal medlemmer."
  1022. if {team::%{team::%uuid of player%}%::adgang.til.chest1} is false:
  1023. set slot 20 of player's current inventory to chest named "&3&l+1 TEAMKISTE" with lore "&7Køb adgang til 1 ekstra team kiste||&r||&7Pris&8: &a5000,-"
  1024. if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
  1025. if {team::%{team::%uuid of player%}%::lvl} is 1:
  1026. set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 2."
  1027. else:
  1028. set slot 20 of player's current inventory to chest named "&3&l+1 TEAMKISTE" with lore "&7Køb adgang til 1 ekstra team kiste||&r||&7Pris&8: &a15000,-"
  1029. if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
  1030. if {team::%{team::%uuid of player%}%::lvl} isn't 3:
  1031. set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 3."
  1032. else:
  1033. set slot 20 of player's current inventory to chest named "&3&l+1 TEAMKISTE" with lore "&7Køb adgang til 1 ekstra team kiste||&r||&7Pris&8: &a30000,-"
  1034. if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
  1035. set slot 20 of player's current inventory to chest named "&4&lMAKS" with lore "&cDu har låst op for maks team kister."
  1036.  
  1037. if {team::%{team::%uuid of player%}%::farve.grøn} is false:
  1038. set slot 21 of player's current inventory to light green dye named "&a&lGRØN TEAMFARVE" with lore "&7Køb adgang til &agrøn&7 teamfarve||&r||&7Pris&8:&a 7000,-"
  1039. else:
  1040. set slot 21 of player's current inventory to light green dye named "&a&lGRØN TEAMFARVE!" with lore "&7Allerede købt"
  1041. if {team::%{team::%uuid of player%}%::farve.blå} is false:
  1042. set slot 22 of player's current inventory to light blue dye named "&b&lBLÅ TEAMFARVE" with lore "&7Køb adgang til &bblå&7 teamfarve||&r||&7Pris&8:&a 15000,-"
  1043. else:
  1044. set slot 22 of player's current inventory to light blue dye named "&b&lBLÅ TEAMFARVE!" with lore "&7Allerede købt"
  1045. if {team::%{team::%uuid of player%}%::farve.rød} is false:
  1046. set slot 23 of player's current inventory to rose red named "&c&lRØD TEAMFARVE" with lore "&7Køb adgang til &crød&7 teamfarve||&r||&7Pris&8:&a 22000,-"
  1047. else:
  1048. set slot 23 of player's current inventory to rose red named "&c&lRØD TEAMFARVE!" with lore "&7Allerede købt"
  1049. set slot 24 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
  1050. set slot 25 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
  1051. stop
  1052. else:
  1053. send "{@p}Det er kun ejeren det kan købe i shoppen."
  1054. close player's inventory
  1055. stop
  1056. if name of clicked item is "&7&lINDSTILLINGER":
  1057. if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
  1058. open chest with 5 rows named "Team Indstillinger" to player
  1059. wait 3 ticks
  1060. if inventory name of player's current inventory is "Team Indstillinger":
  1061. #----------------------------------------------------------------
  1062. loop integers from 0 to 8:
  1063. set slot loop-integer of player's current inventory to 160 named ""
  1064. loop integers from 36 to 44:
  1065. set slot loop-integer of player's current inventory to 160:3 named ""
  1066. set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
  1067. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
  1068. set {_inds1} to "&7Adgang: &eAlle"
  1069. if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
  1070. set {_inds1} to "&7Adgang: &eKun ejer"
  1071. set slot 20 of player's current inventory to gold nugget named "&6&lShop" with lore "%{_inds1}%||&r||&7Klik for at ændre"
  1072.  
  1073.  
  1074.  
  1075. if {team::%{team::%uuid of player%}%::teamdamaga} is false:
  1076. set {_inds2} to "&7Aktiveret: &cFra"
  1077. if {team::%{team::%uuid of player%}%::teamdamaga} is true:
  1078. set {_inds2} to "&7Aktiveret: &cTil"
  1079. set slot 22 of player's current inventory to redstone named "&4&lTeam Damage" with lore "%{_inds2}%||&r||&7Klik for at ændre"
  1080.  
  1081.  
  1082. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
  1083. set {_inds3} to "&7Adgang: &fAlle"
  1084. if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
  1085. set {_inds3} to "&7Adgang: &fEjer"
  1086. set slot 24 of player's current inventory to bonemeal named "&f&lTeam Farver" with lore "%{_inds3}%||&r||&7Klik for at ændre"
  1087.  
  1088. stop
  1089. else:
  1090. send "{@p}Kun ejeren af teamet, kan ændre i indstillingerne."
  1091.  
  1092.  
  1093. on inventory click:
  1094. if inventory name of player's current inventory is "Team Farver":
  1095. cancel event
  1096. if name of clicked item is "&7&lGrå":
  1097. set {team::%{team::%uuid of player%}%::farve} to "&7"
  1098. send "{@p}Du ændrede jeres teamfarve til &7grå"
  1099. close player's inventory
  1100. stop
  1101. if name of clicked item is "&6&lOrange":
  1102. if {team::%{team::%uuid of player%}%::farve.orange} is true:
  1103. set {team::%{team::%uuid of player%}%::farve} to "&6"
  1104. send "{@p}Du ændrede jeres teamfarve til &6orange"
  1105. close player's inventory
  1106. stop
  1107. else:
  1108. send "{@p}Du har ikke adgang til denne farve."
  1109. close player's inventory
  1110. stop
  1111. if name of clicked item is "&d&lMagenta":
  1112. if {team::%{team::%uuid of player%}%::farve.magenta} is true:
  1113. set {team::%{team::%uuid of player%}%::farve} to "&d"
  1114. send "{@p}Du ændrede jeres teamfarve til &dmagenta"
  1115. close player's inventory
  1116. stop
  1117. else:
  1118. send "{@p}Du har ikke adgang til denne farve."
  1119. close player's inventory
  1120. stop
  1121. if name of clicked item is "&a&lGrøn":
  1122. if {team::%{team::%uuid of player%}%::farve.grøn} is true:
  1123. set {team::%{team::%uuid of player%}%::farve} to "&a"
  1124. send "{@p}Du ændrede jeres teamfarve til &agrøn"
  1125. close player's inventory
  1126. stop
  1127. else:
  1128. send "{@p}Du har ikke adgang til denne farve."
  1129. close player's inventory
  1130. stop
  1131. if name of clicked item is "&b&lBlå":
  1132. if {team::%{team::%uuid of player%}%::farve.blå} is true:
  1133. set {team::%{team::%uuid of player%}%::farve} to "&b"
  1134. send "{@p}Du ændrede jeres teamfarve til &bblå"
  1135. close player's inventory
  1136. stop
  1137. else:
  1138. send "{@p}Du har ikke adgang til denne farve."
  1139. close player's inventory
  1140. stop
  1141. if name of clicked item is "&c&lRød":
  1142. if {team::%{team::%uuid of player%}%::farve.rød} is true:
  1143. set {team::%{team::%uuid of player%}%::farve} to "&c"
  1144. send "{@p}Du ændrede jeres teamfarve til &crød"
  1145. close player's inventory
  1146. stop
  1147. else:
  1148. send "{@p}Du har ikke adgang til denne farve."
  1149. close player's inventory
  1150. stop
  1151. if name of clicked item is "&4&lTILBAGE":
  1152. wait 1 tick
  1153. execute player command "team start"
  1154. stop
  1155. on inventory click:
  1156. if inventory name of player's current inventory is "Team Hjælp":
  1157. cancel event
  1158. close player's inventory
  1159.  
  1160. if inventory name of player's current inventory contains "Team Info":
  1161. cancel event
  1162. close player's inventory
  1163.  
  1164. On death:
  1165. if {team::%uuid of attacker%} is {team::%uuid of victim%}:
  1166. stop
  1167. else:
  1168. If {team::%uuid of attacker%} is set:
  1169. add 1 to {kills.team::%{team::%uuid of attacker%}%}
  1170. If {team::%uuid of victim%} is set:
  1171. add 1 to {deaths.team::%{team::%uuid of victim%}%}
  1172.  
  1173. on damage:
  1174. if {team::%uuid of attacker%} is {team::%uuid of victim%}:
  1175. if {team::%{team::%uuid of attacker%}%::teamdamaga} is false:
  1176. cancel event
  1177.  
  1178.  
  1179.  
  1180. on join:
  1181. set {team.status::%player%} to "online"
  1182.  
  1183. on quit:
  1184. set {team.status::%player%} to "offline"
  1185.  
  1186.  
  1187.  
  1188.  
  1189.  
  1190.  
  1191.  
  1192. command /teamdisband <text>:
  1193. aliases: /bruhnetwork:teamdisband
  1194. permission: *
  1195. trigger:
  1196. if player is op:
  1197. send "{@p}Du fjernede teamet &b%arg-1%"
  1198. remove arg-1 from {teams::*}
  1199. delete {team::%arg-1%::lvlkills}
  1200. delete {team::%arg-1%::lvl}
  1201. delete {team::%arg-1%::kills}
  1202. delete {team::%arg-1%::deaths}
  1203. delete {team::%arg-1%::ejer}
  1204. loop {team::%arg-1%::medlemmer::*}:
  1205. remove loop-value from {team::%{team::%loop-value%}%::medlemmer::*}
  1206. delete {team::%loop-value%}
  1207. delete {team::%arg-1%}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement