Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Options:
- Bannednavne: "´","Fuck","Ingen","None","<none>","Nigg",".",",","Lort","Server","pik","fisse","dick","dic","*","_","&","-","'"," ","+","?","=","]","[","{","}","(",")","^",":",";","O","@"," ","%%"," ","/" or "Nigger"
- p: &8&l| &b&lTEAM &8&l| &f
- command /tc [<text>]:
- aliases: /bruhnetwork:tc, /bruhnetwork:teamchat, /teamchat
- trigger:
- if arg-1 is set:
- if {team::%uuid of player%} is set:
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- set {_prefix} to "&8[&aLeder&8] &a"
- else:
- set {_prefix} to "&8[&cMedlem&8] &c"
- loop all players:
- if {team::%uuid of player%} is {team::%uuid of loop-player%}:
- message "&8&l[&b&lTeam Chat&8&l] %{_prefix}%%player% &8»&f %arg text%" to loop-player
- else:
- send "{@p}Du skal skrive en besked."
- command /team [<text>] [<text>] [<text>]:
- aliases: /bruhnetwork:team, /bruhnetwork:teams, /teams
- #permission: team.test
- trigger:
- if arg-1 is not set:
- if {team::%uuid of player%} is not set:
- execute player command "team hjælp"
- stop
- if {team::%uuid of player%} is set:
- execute player command "team start"
- else if arg-1 is "hjælp" or "help":
- open chest with 5 rows named "Team Hjælp" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Hjælp":
- #----------------------------------------------------------------
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to white stained glass pane named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to light blue stained glass pane named ""
- #----------------------------------------------------------------
- if {team::%uuid of player%} is set:
- 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."
- else:
- 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»-->"
- else if arg-1 is "opret" or "create":
- if {team::%uuid of player%} is set:
- send "{@p}Du er allerede med i et team &8(&b%{team::%uuid of player%}%&8)"
- send "{@p}Du kan altid forlade dit team via &b/team forlad"
- stop
- else:
- if arg-2 is set:
- if player's balance is greater or equal to 2500:
- set {_arg2} to arg-2
- if arg 3 is set:
- send "{@p}Der må ikke være mellemrum i dit team navn."
- stop
- if length of {_arg2} is between -9999999999999 and 1:
- send "{@p}Dit team navn skal være længere end 1 bogstav."
- stop
- if length of {_arg2} is above 8:
- send "{@p}Dit team navn må ikke være længere end &b8 &fbogstaver!"
- stop
- if arg-2 contains {@Bannednavne}:
- send "{@p}Dette må dit team ikke hedde."
- stop
- 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 "å":
- send "{@p}Dette må dit team ikke hedde."
- stop
- if {team::%arg-2%} is set:
- send "{@p}Der er allerede et team med dette navn."
- stop
- add 1 to {team.ID}
- set {team::%uuid of player%} to arg-2
- set {team::%arg-2%} to arg-2
- set {team::%arg-2%::lvl} to 1
- set {team::%arg-2%::lavet} to now
- set {team::%arg-2%::lvlkills} to 300
- set {team::%arg-2%::maxmem} to 3
- set {kills.team::%arg-2%} to 0
- set {deaths.team::%arg-2%} to 0
- set {bank.team::%arg-2%} to 0
- set {team::%arg-2%::adgang.til.chest1} to false
- set {team::%arg-2%::adgang.til.chest2} to false
- set {team::%arg-2%::adgang.til.chest3} to false
- set {team::%arg-2%::levelup.1.farve1} to false
- set {team::%arg-2%::levelup.1.chest1} to false
- set {team::%arg-2%::levelup.2.chest2} to false
- set {team::%arg-2%::levelup.2.medlem2} to false
- set {team::%arg-2%::antal.farver} to 0
- set {team::%arg-2%::ejer} to uuid of player
- set {team::%arg-2%::adgangtil.shop} to "Ejer"
- set {team::%arg-2%::adgangtil.farve} to "Ejer"
- set {team::%arg-2%::teamdamaga} to false
- set {team::%arg-2%::ejernavn} to "%player%"
- set {team::%{team::%uuid of player%}%::farve} to "&7"
- add "%{team::%arg-2%}%" to {teams::*}
- set {navn::%uuid of player%} to "%player%"
- set {uuid::%player%} to uuid of player
- set {team::%arg-2%::lavet} to now
- set {team::%arg-2%::id} to {team.ID}
- add uuid of player to {team::%{team::%uuid of player%}%::medlemmer::*}
- set {team::%arg-2%::motto} to "Sammen er vi stærkere"
- set {team::%arg-2%::antal.farver} to 0
- set {team::%arg-2%::farve.blå} to false
- set {team::%arg-2%::farve.grøn} to false
- set {team::%arg-2%::farve.rød} to false
- set {team::%arg-2%::farve.orange} to false
- set {team::%arg-2%::farve.magenta} to false
- set {team::%arg-2%::mission.1} to "Igang"
- set {team::%arg-2%::mission.2} to "Låst"
- set {team::%arg-2%::mission.3} to "Låst"
- set {team::%arg-2%::mission.4} to "Låst"
- set {team::%arg-2%::mission.5} to "Låst"
- set {team::%arg-2%::mission.6} to "Låst"
- set {team::%arg-2%::mission.7} to "Låst"
- set {team::%arg-2%::mission.8} to "Låst"
- set {team::%arg-2%::mission.9} to "Låst"
- set {team::%arg-2%::mission.10} to "Låst"
- set {team::%arg-2%::mission.11} to "Låst"
- set {team::%arg-2%::mission.12} to "Låst"
- set {team::%arg-2%::mission.13} to "Låst"
- set {team::%arg-2%::mission.14} to "Låst"
- set {team::%arg-2%::mission.15} to "Låst"
- set {team::%arg-2%::mission.16} to "Låst"
- set {team::%arg-2%::mission.17} to "Låst"
- set {team::%arg-2%::mission.18} to "Låst"
- set {team::%arg-2%::mission.19} to "Låst"
- set {team::%arg-2%::mission.20} to "Låst"
- set {team::%arg-2%::mission.21} to "Låst"
- set {team::%arg-2%::mission.22} to "Låst"
- set {team::%arg-2%::mission.23} to "Låst"
- set {team::%arg-2%::mission.24} to "Låst"
- subtract 2500 from player's balance
- message "{@p}Du har lavet et teamet &b%arg-2%"
- else:
- send "{@p}Du har ikke nok penge. Et team koster &b2500,-"
- else:
- send "{@p}Forkert brug af kommandoen. &b/team opret &bnavn"
- if arg-1 is "list" or "liste":
- if player has permission "*":
- send "&8&m---------&r &3&lTEAM &8&m---------"
- send "&bListe over alle teams:"
- loop {teams::*}:
- send "&8- &b%loop-value%"
- #if arg-1 is "clear":
- # clear {teams::*}
- if arg-1 is "forlad" or "leave":
- if {team::%uuid of player%} is not set:
- message "{@p}Du er ikke medlem af noget team."
- message "{@p}Opret et via &b/team opret"
- stop
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- set {_team} to {team::%uuid of player%}
- message "{@p}Du har slettet teamet &b%{_team}%"
- remove "%{team::%{_team}%}%" from {teams::*}
- loop {team::%{_team}%::medlemmer::*}:
- delete {team::%loop-value%}
- remove loop-value from {team::%{team::%loop-value%}%::medlemmer::*}
- delete {team::%{_team}%::lvlkills}
- delete {team::%{_team}%::lvl}
- delete {kills.team::%{_team}%}
- delete {deaths.team::%{_team}%}
- delete {team::%{_team}%::deaths}
- delete {team::%{_team}%::ejer}
- delete {team::%{_team}%}
- clear {team::%{_team}%::medlemmer::*}
- delete {team::%uuid of player%}
- if {team::%uuid of player%} is set:
- message "{@p}Der er sket en fejl, kontakt &bFlupMC&f"
- else:
- loop all players:
- if {team::%uuid of player%} is {team::%uuid of loop-player%}:
- if player isn't loop-player:
- message "{@p}&b%player% &fhar forladt teamet." to loop-player
- send "{@p}Du har forladt teamet &b%{team::%uuid of player%}%"
- remove uuid of player from {team::%{team::%uuid of player%}%::medlemmer::*}
- delete {team::%uuid of player%}
- stop
- if arg 1 is "invite" or "inviter":
- if {team::%uuid of player%} is not set:
- message "{@p}Du er ikke medlem af noget team."
- message "{@p}Opret et via &b/team opret"
- stop
- else:
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- set {_size} to "%size of {team::%{team::%uuid of player%}%::medlemmer::*}%"
- if {team::%{uuid::%arg-2%}%} is set:
- message "{@p}&b%arg 2%&f er allerede medlem af et team."
- stop
- if {team::%player%::invite} is set:
- message "{@p}&b%arg 2%&f er allerede inviteret til et team."
- send "{@p}Få spilleren til at afvise sin invitation med &b/team afvis"
- stop
- if size of {team::%{team::%uuid of player%}%::medlemmer::*} is greater or equal to {team::%{team::%uuid of player%}%::maxmem}:
- send "{@p}Du kan maksimalt have &b%{team::%{team::%uuid of player%}%::maxmem}% medlemmer"
- send "{@p}Du kan købe ekstra medlemspladser i teamshoppen."
- stop
- set {_player} to arg 2 parsed as a player
- set {_playeruuid} to uuid of {_player}
- set {_uuidplayer} to "%{_playeruuid}%" parsed as a player
- if {team.status::%{_player}%} is "online":
- if {team::%{team::%uuid of player%}%::ejer} is not uuid of player:
- message "{@p}Det er kun ejeren af teamet der kan invitere flere."
- stop
- else:
- if arg 2 is not set:
- message "{@p}Forkert brug af kommandoen. &b/team inviter <navn>"
- stop
- else:
- if {team::%{_player}%::invite} is set:
- 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."
- stop
- else:
- if {team::%{_uuidplayer}%} is set:
- message "{@p}&7%{_player}% &fer allerede med i et team."
- stop
- else:
- set {team::%{_player}%::invite} to "%{team::%uuid of player%}%"
- message "{@p}Du er blevet inviteret til teamet &3%{team::%uuid of player%}%" to {_player}
- #message "{@p}&b&lKLIK HER&f for at joine." to {_player}
- execute console command "json %{_player}% {@p}||&b&lKLIK HER||ttp:&b/team accepter||cmd:/team join||&f for at joine."
- message "{@p}Du har inviteret &b%{_player}% &ftil teamet."
- message "{@p}Spilleren har 30 sekunder til at acceptere."
- wait 30 seconds
- delete {team::%{_player}%::invite}
- stop
- else:
- message "{@p}Du kan kun invitere spillere der er online."
- stop
- else:
- send "{@p}Det er kun ejeren af teamet der kan invitere flere."
- stop
- if arg-1 is "afvis" or "deny":
- if {team::%uuid of player%} is not set:
- if {team::%player%::invite} is set:
- message "{@p}Du afviste invitationen fra teamet &b%{team::%player%::invite}%"
- loop all players:
- if {team::%{team::%player%::invite}%::ejer} is uuid of loop-player:
- message "{@p}&b%player% &fhar afvist invitationen." to loop-player
- delete {team::%player%::invite}
- stop
- else:
- message "{@p}Du er ikke blevet inviteret til et team!"
- stop
- else:
- send "{@p}Du er allerede medlem af teamet &b%{team::%uuid of player%}%"
- if arg 1 is "join", "accept" or "accepter":
- if {team::%uuid of player%} is set:
- send "{@p}Du er allerede medlem af teamet &b%{team::%uuid of player%}%"
- stop
- else:
- if {team::%player%::invite} is set:
- if size of {team::%{team::%player%::invite}%::medlemmer::*} isn't greater or equal to {team::%{team::%player%::invite}%::maxmem}:
- set {team::%uuid of player%} to {team::%player%::invite}
- loop all players:
- if {team::%uuid of player%} is {team::%uuid of loop-player%}:
- if player isn't loop-player:
- send "{@p}&b%player%&f har joinet teamet." to loop-player
- add uuid of player to {team::%{team::%player%::invite}%::medlemmer::*}
- message "{@p}Du har joinet teamet &b%{team::%player%::invite}%"
- set {navn::%uuid of player%} to "%player%"
- set {uuid::%player%} to uuid of player
- delete {team::%player%::invite}
- stop
- else:
- send "{@p}Teamet har ikke plads til flere spillere."
- delete {team::%player%::invite}
- stop
- else:
- send "{@p}Du er ikke blevet inviteret til et team."
- stop
- if arg 1 is "kick":
- if {team::%uuid of player%} is not set:
- message "{@p}Du er ikke medlem af noget team."
- message "{@p}Opret et via &b/team opret"
- stop
- else:
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- if arg 2 is not set:
- message "{@p}Forkert brug af kommandoen. &b/team kick <navn>"
- stop
- set {_player} to arg 2 parsed as a player
- message "{@p}Du har smidt &b%arg 2% &fud af teamet."
- remove {uuid::%arg 2%} from {team::%{team::%uuid of player%}%::medlemmer::*}
- message "{@p}Du er blevet smidt ud af teamet &b%{team::%uuid of player%}%" to {_player}
- delete {team::%{uuid::%arg-2%}%}
- loop all players:
- if {team::%uuid of player%} is {team::%uuid of loop-player%}:
- if player isn't loop-player:
- send "{@p}&b%arg-2%&f er blevet smidt ud af teamet." to loop-player
- stop
- else:
- message "{@p}Det er kun ejeren af teamet der kan smide folk ud."
- stop
- if arg-1 is "info":
- if arg-2 is not set:
- if {team::%uuid of player%} is set:
- execute player command "team start"
- stop
- else:
- send "{@p}Forkert brug af kommandoen. &b/team info <navn>"
- stop
- if arg-2 is set:
- if {team::%arg-2%} is set:
- open chest with 5 rows named "Team Info" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Info":
- #----------------------------------------------------------------
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to white stained glass pane named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to blue stained glass pane named ""
- #----------------------------------------------------------------
- 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%}%}%"
- #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}%"
- if {team::%{team::%arg-2%}%::lvl} is 1:
- if {team::%{team::%arg-2%}%::levelup.1.chest1} is true:
- set {_krav1} to "&8 - &aKøbt teamkiste 1"
- else:
- set {_krav1} to "&8 - &cKøbt teamkiste 1"
- if {team::%{team::%arg-2%}%::levelup.1.farve1} is true:
- set {_krav2} to "&8 - &aKøbt en teamfarve"
- else:
- set {_krav2} to "&8 - &cKøbt en teamfarve"
- if {kills.team::%{team::%arg-2%}%} is greater or equal to 300:
- set {_krav3} to "&8 - &a300 kills i teamet"
- else:
- set {_krav3} to "&8 - &c300 kills i teamet"
- set slot 20 of player's current inventory to emerald named "&2&lLevelup" with lore "&7Krav:||%{_krav1}%||%{_krav2}%||%{_krav3}%"
- loop {team::%{team::%arg-2%}%::medlemmer::*}:
- if loop-value isn't {team::%{team::%arg-2%}%::ejer}:
- add "&8 - &a%{navn::%loop-value%}%||" to {_medlemmer1::*}
- set {_medlemmer} to "%{_medlemmer1::*}%"
- if {_medlemmer} is "<none>":
- set {_medlemmer} to "&8 - &cIngen"
- replace all " and " with "" in {_medlemmer}
- replace all ", " with "" in {_medlemmer}
- set slot 24 of player's current inventory to 386 named "&a&lMedlemmer" with lore "&7Ejer: &a%{team::%{team::%arg-2%}%::ejernavn}%||&7Medlemmer:||%{_medlemmer}%"
- else:
- set {_arg} to {uuid::%arg-2%}
- if {team::%{_arg}%} is set:
- open chest with 5 rows named "Team Info" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Info":
- #----------------------------------------------------------------
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to white stained glass pane named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to light blue stained glass pane named ""
- #----------------------------------------------------------------
- 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}%}%}%"
- #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}%"
- if {team::%{team::%{_arg}%}%::lvl} is 1:
- if {team::%{team::%{_arg}%}%::levelup.1.chest1} is true:
- set {_krav1} to "&8 - &aKøbt teamkiste 1"
- else:
- set {_krav1} to "&8 - &cKøbt teamkiste 1"
- if {team::%{team::%{_arg}%}%::levelup.1.farve1} is true:
- set {_krav2} to "&8 - &aKøbt en teamfarve"
- else:
- set {_krav2} to "&8 - &cKøbt en teamfarve"
- if {kills.team::%{team::%{_arg}%}%} is greater or equal to 300:
- set {_krav3} to "&8 - &a300 kills i teamet"
- else:
- set {_krav3} to "&8 - &c300 kills i teamet"
- set slot 20 of player's current inventory to emerald named "&2&lLevelup" with lore "&7Krav:||%{_krav1}%||%{_krav2}%||%{_krav3}%"
- loop {team::%{team::%{_arg}%}%::medlemmer::*}:
- if loop-value isn't {team::%{team::%{_arg}%}%::ejer}:
- add "&8 - &a%{navn::%loop-value%}%||" to {_medlemmer1::*}
- set {_medlemmer} to "%{_medlemmer1::*}%"
- if {_medlemmer} is "<none>":
- set {_medlemmer} to "&8 - &cIngen"
- replace all " and " with "" in {_medlemmer}
- replace all ", " with "" in {_medlemmer}
- set slot 24 of player's current inventory to 386 named "&a&lMedlemmer" with lore "&7Ejer: &a%{team::%{team::%{_arg}%}%::ejernavn}%||&7Medlemmer:||%{_medlemmer}%"
- else:
- send "{@p}Dette er ikke et team."
- if arg-1 is "indsæt", "add" or "bank":
- if {team::%uuid of player%} is not set:
- message "{@p}Du er ikke medlem af noget team."
- message "{@p}Opret et via &b/team opret"
- stop
- else:
- if arg-2 is set:
- set {_bal} to arg-2 parsed as a number
- if player's balance is greater or equal to {_bal}:
- subtract {_bal} from player's balance
- add {_bal} to {bank.team::%{team::%uuid of player%}%}
- send "{@p}Du tilføjede &b%arg-2%,-&f til jeres team &8(&b%{bank.team::%{team::%uuid of player%}%}%,- ialt&8)"
- else:
- send "{@p}Du har ikke penge nok til dette."
- else:
- message "{@p}Forkert brug af kommandoen. &b/team indsæt <antal>"
- stop
- if arg-1 is "start":
- if {team::%uuid of player%} is set:
- open chest with 5 rows named "Team Menu" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Menu":
- #----------------------------------------------------------------
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to white stained glass pane named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to light blue stained glass pane named ""
- if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
- set {_kiste1} to "&7Adgang til teamkiste 1: &aJa"
- else:
- set {_kiste1} to "&7Adgang til teamkiste 1: &cNej"
- if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
- set {_kiste2} to "&7Adgang til teamkiste 2: &aJa"
- else:
- set {_kiste2} to "&7Adgang til teamkiste 2: &cNej"
- if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
- set {_kiste3} to "&7Adgang til teamkiste 3: &aJa"
- else:
- set {_kiste3} to "&7Adgang til teamkiste 3: &cNej"
- 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"
- loop {team::%{team::%uuid of player%}%::medlemmer::*}:
- if loop-value isn't {team::%{team::%uuid of player%}%::ejer}:
- add "&8 - &a%{navn::%loop-value%}%||" to {_medlemmer1::*}
- set {_medlemmer} to "%{_medlemmer1::*}%"
- if {_medlemmer} is "<none>":
- set {_medlemmer} to "&8 - &cIngen"
- replace all " and " with "" in {_medlemmer}
- replace all ", " with "" in {_medlemmer}
- 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}%"
- #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}%"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- 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"
- else:
- set slot 24 of player's current inventory to 166 named "&4&lIKKE ADGANG" with lore "&7Kun ejeren kan købe i shoppen"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
- 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"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
- set {_indstilliger1} to "&7Adgang til shop: &aKun ejer"
- else:
- set {_indstilliger1} to "&7Adgang til shop: &aAlle"
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
- set {_indstilliger2} to "&7Adgang til teamfarver: &aKun ejer"
- else:
- set {_indstilliger2} to "&7Adgang til teamfarver: &aAlle"
- if {team::%{team::%uuid of player%}%::teamdamaga} is false:
- set {_indstilliger3} to "&7Team damage: &cFra"
- else:
- set {_indstilliger3} to "&7Team damage: &aTil"
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- set {_indstilliger4} to "&7Klik for at ændre"
- else:
- set {_indstilliger4} to "&cKun ejeren kan ændre"
- set slot 40 of player's current inventory to tripwire hook named "&7&lINDSTILLINGER" with lore "%{_indstilliger1}%||%{_indstilliger2}%||%{_indstilliger3}%||&r||%{_indstilliger4}%"
- if {team::%{team::%uuid of player%}%::lvl} is 1:
- if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
- set {_krav1} to "&8 - &aKøbt teamkiste 1"
- else:
- set {_krav1} to "&8 - &cKøbt teamkiste 1"
- if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
- set {_krav2} to "&8 - &aKøbt en teamfarve"
- else:
- set {_krav2} to "&8 - &cKøbt en teamfarve"
- if {kills.team::%{team::%uuid of player%}%} is greater or equal to 300:
- set {_krav3} to "&8 - &a300 kills i teamet"
- else:
- set {_krav3} to "&8 - &c300 kills i teamet"
- set {_krav4} to "&cKun ejeren kan levelup"
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- set {_krav4} to "&cDu har ikke klaret alt"
- if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
- if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
- if {kills.team::%{team::%uuid of player%}%} is greater or equal to 300:
- set {_krav4} to "&7Klik for at levelup"
- if {team::%{team::%uuid of player%}%::lvl} is 2:
- if {team::%{team::%uuid of player%}%::levelup.2.chest2} is true:
- set {_krav1} to "&8 - &aKøbt teamkiste 2"
- else:
- set {_krav1} to "&8 - &cKøbt teamkiste 2"
- if {team::%{team::%uuid of player%}%::levelup.2.medlem2} is true:
- set {_krav2} to "&8 - &aKøbt 2 ekstra medlem"
- else:
- set {_krav2} to "&8 - &aKøbt 2 ekstra medlem"
- if {kills.team::%{team::%uuid of player%}%} is greater or equal to 1500:
- set {_krav3} to "&8 - &a1500 kills i teamet"
- else:
- set {_krav3} to "&8 - &c1500 kills i teamet"
- set {_krav4} to "&cKun ejeren kan levelup"
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- set {_krav4} to "&cDu har ikke klaret alt"
- if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
- if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
- if {kills.team::%{team::%uuid of player%}%} is greater or equal to 1500:
- set {_krav4} to "&7Klik for at levelup"
- set slot 22 of player's current inventory to emerald named "&2&lLevelup" with lore "&7Krav:||%{_krav1}%||%{_krav2}%||%{_krav3}%||&r||%{_krav4}%"
- if {team::%{team::%uuid of player%}%::lvl} is 3:
- set slot 22 of player's current inventory to emerald named "&2&lLevelup" with lore "&aMaks level."
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- 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"
- else:
- set slot 26 of player's current inventory to 166 named "&4&lIKKE ADGANG" with lore "&7Kun ejeren kan ændre teamfarven"
- else:
- 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"
- 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%}%}%"
- if arg-1 is "chest":
- if {team::%uuid of player%} is not set:
- message "{@p}Du er ikke medlem af noget team."
- message "{@p}Opret et via &b/team opret"
- stop
- else:
- open chest with 1 rows named "&6&lTEAM KISTER" to player
- wait 3 ticks
- if inventory name of player's current inventory is "&6&lTEAM KISTER":
- if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
- set slot 2 of player's current inventory to chest named "&6&lTEAM KISTE ##1"
- else:
- set slot 2 of player's current inventory to chest named "&4&lTEAM KISTE ##1" with lore "&7Køb adgang i teamshoppen"
- if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
- set slot 4 of player's current inventory to chest named "&6&lTEAM KISTE ##2"
- else:
- set slot 4 of player's current inventory to chest named "&4&lTEAM KISTE ##2" with lore "&7Køb adgang i teamshoppen"
- if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
- set slot 6 of player's current inventory to chest named "&6&lTEAM KISTE ##3"
- else:
- set slot 6 of player's current inventory to chest named "&4&lTEAM KISTE ##3" with lore "&7Køb adgang i teamshoppen"
- if arg-1 is "top53235":
- if arg-2 is "kills" or "drab":
- loop {kills.team::*}:
- add 1 to {_size}
- if {_low.to.high.list::%loop-value%} is not set:
- set {_low.to.high.list::%loop-value%} to loop-index
- else:
- set {_n} to 0
- loop {_size} times:
- set {_n} to {_n}+1
- {_low.to.high.list::%loop-value-1%.%{_n}%} is not set
- set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
- stop loop
- wait 1 tick
- set {_n} to size of {_low.to.high.list::*}
- loop {_low.to.high.list::*}:
- set {_high.to.low.list::%{_n}%} to loop-value
- set {_n} to {_n}-1
- wait 1 tick
- send "&8&m-------&r &3&lTEAMTOP &8&m-------"
- send ""
- set {_result} to 0
- loop {_high.to.low.list::*}:
- add 1 to {_result}
- set {_navn} to {team::%loop-value%}
- 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)"
- if {_result} is 10:
- stop
- if arg-2 is "deaths" or "døde":
- loop {deaths.team::*}:
- add 1 to {_size}
- if {_low.to.high.list::%loop-value%} is not set:
- set {_low.to.high.list::%loop-value%} to loop-index
- else:
- set {_n} to 0
- loop {_size} times:
- set {_n} to {_n}+1
- {_low.to.high.list::%loop-value-1%.%{_n}%} is not set
- set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
- stop loop
- wait 1 tick
- set {_n} to size of {_low.to.high.list::*}
- loop {_low.to.high.list::*}:
- set {_high.to.low.list::%{_n}%} to loop-value
- set {_n} to {_n}-1
- wait 1 tick
- send "&8&m-------&r &3&lTEAMTOP &8&m-------"
- send ""
- set {_result} to 0
- loop {_high.to.low.list::*}:
- add 1 to {_result}
- set {_navn} to {team::%loop-value%}
- 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)"
- if {_result} is 10:
- stop
- if arg-2 is "bank" or "penge":
- loop {bank.team::*}:
- add 1 to {_size}
- if {_low.to.high.list::%loop-value%} is not set:
- set {_low.to.high.list::%loop-value%} to loop-index
- else:
- set {_n} to 0
- loop {_size} times:
- set {_n} to {_n}+1
- {_low.to.high.list::%loop-value-1%.%{_n}%} is not set
- set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
- stop loop
- wait 1 tick
- set {_n} to size of {_low.to.high.list::*}
- loop {_low.to.high.list::*}:
- set {_high.to.low.list::%{_n}%} to loop-value
- set {_n} to {_n}-1
- wait 1 tick
- send "&8&m-------&r &3&lTEAMTOP &8&m-------"
- send ""
- set {_result} to 0
- loop {_high.to.low.list::*}:
- add 1 to {_result}
- set {_navn} to {team::%loop-value%}
- send "&3%{_result}% &8» &b%{_navn}% &8- &b%{bank.team::%loop-value%}%,-"
- if {_result} is 10:
- stop
- on inventory click:
- if inventory name of player's current inventory is "&6&lTEAM KISTER":
- cancel event
- if name of clicked item is "&6&lTEAM KISTE ##1":
- if {team::%{team::%uuid of player%}%.kiste1.åben} is not set:
- invoke "team.page1" from player
- set {team::%{team::%uuid of player%}%.kiste1.åben} to true
- stop
- else:
- send "{@p}Der er allerede en spiller i kisten &8(&b1&8)"
- close player's inventory
- stop
- if name of clicked item is "&6&lTEAM KISTE ##2":
- if {team::%{team::%uuid of player%}%.kiste2.åben} is not set:
- invoke "team.page2" from player
- set {team::%{team::%uuid of player%}%.kiste2.åben} to true
- stop
- else:
- send "{@p}Der er allerede en spiller i kisten &8(&b2&8)"
- close player's inventory
- stop
- if name of clicked item is "&6&lTEAM KISTE ##3":
- if {team::%{team::%uuid of player%}%.kiste3.åben} is not set:
- invoke "team.page3" from player
- set {team::%{team::%uuid of player%}%.kiste3.åben} to true
- stop
- else:
- send "{@p}Der er allerede en spiller i kisten &8(&b3&8)"
- close player's inventory
- stop
- on inventory close:
- if inventory name of player's current inventory is "&6&lTEAM KISTE &e##1":
- set {_slot} to 0
- loop 54 times:
- set {team::1::%{_slot}%::%{team::%uuid of player%}%} to slot {_slot} of player's current inventory
- add 1 to {_slot}
- delete {team::%{team::%uuid of player%}%.kiste1.åben}
- if inventory name of player's current inventory is "&6&lTEAM KISTE &e##2":
- set {_slot} to 0
- loop 54 times:
- set {team::2::%{_slot}%::%{team::%uuid of player%}%} to slot {_slot} of player's current inventory
- add 1 to {_slot}
- delete {team::%{team::%uuid of player%}%.kiste2.åben}
- if inventory name of player's current inventory is "&6&lTEAM KISTE &e##3":
- set {_slot} to 0
- loop 54 times:
- set {team::3::%{_slot}%::%{team::%uuid of player%}%} to slot {_slot} of player's current inventory
- add 1 to {_slot}
- delete {team::%{team::%uuid of player%}%.kiste3.åben}
- sub "team.page1":
- wait 3 ticks
- set {_p} to parameter 1
- open chest with 6 rows named "&6&lTEAM KISTE &e##1" to {_p}
- set {_slot} to 0
- loop 54 times:
- set slot {_slot} of {_p}'s current inventory to {team::1::%{_slot}%::%{team::%uuid of parameter 1%}%}
- add 1 to {_slot}
- sub "team.page2":
- wait 3 ticks
- set {_p} to parameter 1
- open chest with 6 rows named "&6&lTEAM KISTE &e##2" to {_p}
- set {_slot} to 0
- loop 54 times:
- set slot {_slot} of {_p}'s current inventory to {team::2::%{_slot}%::%{team::%uuid of parameter 1%}%}
- add 1 to {_slot}
- sub "team.page3":
- wait 3 ticks
- set {_p} to parameter 1
- open chest with 6 rows named "&6&lTEAM KISTE &e##3" to {_p}
- set {_slot} to 0
- loop 54 times:
- set slot {_slot} of {_p}'s current inventory to {team::3::%{_slot}%::%{team::%uuid of parameter 1%}%}
- add 1 to {_slot}
- command /tk:
- aliases: /bruhnetwork:tk, /bruhnetwork:teamkiste, /teamkiste
- trigger:
- execute player command "team chest"
- on inventory close:
- loop all items in the player's inventory:
- if name of loop-item is "&6&lShop" or "&4&lTeam Damage" or "&f&lTeam Farver":
- remove loop-item from the player
- on inventory click:
- if inventory name of player's current inventory is "Team Indstillinger":
- cancel event
- if name of clicked item is "&6&lShop":
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
- set {team::%{team::%uuid of player%}%::adgangtil.shop} to "Ejer"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
- set {_inds1} to "&7Adgang: &eAlle"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
- set {_inds1} to "&7Adgang: &eKun ejer"
- set slot 20 of player's current inventory to gold nugget named "&6&lShop" with lore "%{_inds1}%||&r||&7Klik for at ændre"
- stop
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
- set {team::%{team::%uuid of player%}%::adgangtil.shop} to "Alle"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
- set {_inds1} to "&7Adgang: &eAlle"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
- set {_inds1} to "&7Adgang: &eKun ejer"
- set slot 20 of player's current inventory to gold nugget named "&6&lShop" with lore "%{_inds1}%||&r||&7Klik for at ændre"
- stop
- if name of clicked item is "&4&lTeam Damage":
- if {team::%{team::%uuid of player%}%::teamdamaga} is false:
- set {team::%{team::%uuid of player%}%::teamdamaga} to true
- if {team::%{team::%uuid of player%}%::teamdamaga} is false:
- set {_inds2} to "&7Aktiveret: &cFra"
- if {team::%{team::%uuid of player%}%::teamdamaga} is true:
- set {_inds2} to "&7Aktiveret: &cTil"
- set slot 22 of player's current inventory to redstone named "&4&lTeam Damage" with lore "%{_inds2}%||&r||&7Klik for at ændre"
- stop
- if {team::%{team::%uuid of player%}%::teamdamaga} is true:
- set {team::%{team::%uuid of player%}%::teamdamaga} to false
- if {team::%{team::%uuid of player%}%::teamdamaga} is false:
- set {_inds2} to "&7Aktiveret: &cFra"
- if {team::%{team::%uuid of player%}%::teamdamaga} is true:
- set {_inds2} to "&7Aktiveret: &cTil"
- set slot 22 of player's current inventory to redstone named "&4&lTeam Damage" with lore "%{_inds2}%||&r||&7Klik for at ændre"
- stop
- if name of clicked item is "&f&lTeam Farver":
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
- set {team::%{team::%uuid of player%}%::adgangtil.farve} to "Ejer"
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
- set {_inds3} to "&7Aktiveret: &fAlle"
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
- set {_inds3} to "&7Aktiveret: &fEjer"
- set slot 24 of player's current inventory to bonemeal named "&f&lTeam Farver" with lore "%{_inds3}%||&r||&7Klik for at ændre"
- stop
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
- set {team::%{team::%uuid of player%}%::adgangtil.farve} to "Alle"
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
- set {_inds3} to "&7Adgang: &fAlle"
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
- set {_inds3} to "&7Adgang: &fEjer"
- set slot 24 of player's current inventory to bonemeal named "&f&lTeam Farver" with lore "%{_inds3}%||&r||&7Klik for at ændre"
- stop
- if name of clicked item is "&4&lTILBAGE":
- wait 1 tick
- execute player command "team start"
- stop
- on inventory click:
- if inventory name of player's current inventory is "Team Shop":
- cancel event
- if name of clicked item is "&4&lTILBAGE":
- wait 1 tick
- execute player command "team start"
- stop
- if name of clicked item is "&3&l+1 MEDLEM":
- if {team::%{team::%uuid of player%}%::maxmem} is 3:
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 10000:
- subtract 10000 from {bank.team::%{team::%uuid of player%}%}
- add 1 to {team::%{team::%uuid of player%}%::maxmem}
- send "{@p}Du købte &b1 ekstra&f plads i teamet &8(&b%{team::%{team::%uuid of player%}%::maxmem}% pladser&8)"
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- if {team::%{team::%uuid of player%}%::maxmem} is 4:
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 25000:
- subtract 25000 from {bank.team::%{team::%uuid of player%}%}
- add 1 to {team::%{team::%uuid of player%}%::maxmem}
- set {team::%{team::%uuid of player%}%::levelup.2.medlem2} to true
- send "{@p}Du købte &b1 ekstra&f plads i teamet &8(&b%{team::%{team::%uuid of player%}%::maxmem}% pladser&8)"
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- if name of clicked item is "&3&l+1 TEAMKISTE":
- if {team::%{team::%uuid of player%}%::adgang.til.chest1} is false:
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 5000:
- subtract 5000 from {bank.team::%{team::%uuid of player%}%}
- set {team::%{team::%uuid of player%}%::levelup.1.chest1} to true
- set {team::%{team::%uuid of player%}%::adgang.til.chest1} to true
- send "{@p}Du købte adgang til &bteam kiste 1"
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- close player's inventory
- stop
- if {team::%{team::%uuid of player%}%::adgang.til.chest2} is false:
- if {team::%{team::%uuid of player%}%::lvl} isn't 1:
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 15000:
- subtract 15000 from {bank.team::%{team::%uuid of player%}%}
- set {team::%{team::%uuid of player%}%::adgang.til.chest2} to true
- set {team::%{team::%uuid of player%}%::levelup.2.chest2} to true
- send "{@p}Du købte adgang til &bteam kiste 2"
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- close player's inventory
- stop
- else:
- send "{@p}Lås op for dette i level 2."
- close player's inventory
- stop
- if {team::%{team::%uuid of player%}%::adgang.til.chest3} is false:
- if {team::%{team::%uuid of player%}%::lvl} is 3:
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 30000:
- subtract 30000 from {bank.team::%{team::%uuid of player%}%}
- set {team::%{team::%uuid of player%}%::adgang.til.chest3} to true
- send "{@p}Du købte adgang til &bteam kiste 3"
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- close player's inventory
- stop
- else:
- send "{@p}Lås op for dette i level 3."
- close player's inventory
- stop
- if name of clicked item is "&a&lGRØN TEAMFARVE":
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 7000:
- subtract 7000 from {bank.team::%{team::%uuid of player%}%}
- set {team::%{team::%uuid of player%}%::farve.grøn} to true
- add 1 to {team::%{team::%uuid of player%}%::antal.farver}
- send "{@p}Du købte &agrøn &7teamfarve!"
- set {team::%{team::%{team::%uuid of player%}%}%::levelup.1.farve1} to true
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- close player's inventory
- stop
- if name of clicked item is "&b&lBLÅ TEAMFARVE":
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 15000:
- subtract 15000 from {bank.team::%{team::%uuid of player%}%}
- set {team::%{team::%uuid of player%}%::farve.blå} to true
- add 1 to {team::%{team::%uuid of player%}%::antal.farver}
- set {team::%{team::%{team::%uuid of player%}%}%::levelup.1.farve1} to true
- send "{@p}Du købte &bblå &fteamfarve!"
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- close player's inventory
- stop
- if name of clicked item is "&c&lRØD TEAMFARVE":
- if {bank.team::%{team::%uuid of player%}%} is greater or equal to 22000:
- subtract 22000 from {bank.team::%{team::%uuid of player%}%}
- set {team::%{team::%uuid of player%}%::farve.rød} to true
- add 1 to {team::%{team::%uuid of player%}%::antal.farver}
- set {team::%{team::%{team::%uuid of player%}%}%::levelup.1.farve1} to true
- send "{@p}Du købte &crød &fteamfarve!"
- close player's inventory
- stop
- else:
- send "{@p}Dit team har ikke nok penge."
- close player's inventory
- stop
- on inventory click:
- if inventory name of player's current inventory is "Team Menu":
- cancel event
- if name of clicked item is "&2&lLevelup":
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- if {team::%{team::%uuid of player%}%::lvl} is 1:
- if {team::%{team::%uuid of player%}%::levelup.1.chest1} is true:
- if {team::%{team::%uuid of player%}%::levelup.1.farve1} is true:
- if {kills.team::%{team::%uuid of player%}%} is greater or equal to 300:
- set {team::%{team::%uuid of player%}%::lvl} to 2
- set {team::%{team::%uuid of player%}%::farve.orange} to true
- add 1 to {team::%{team::%uuid of player%}%::antal.farver}
- broadcast "{@p}Teamet &b&l%{team::%uuid of player%}%&f er steget i level &b%{team::%{team::%uuid of player%}%::lvl}%"
- close player's inventory
- stop
- if {team::%{team::%uuid of player%}%::lvl} is 2:
- if {team::%{team::%uuid of player%}%::levelup.2.chest2} is true:
- if {team::%{team::%uuid of player%}%::levelup.2.medlem2} is true:
- if {kills.team::%{team::%uuid of player%}%} is greater or equal to 1500:
- set {team::%{team::%uuid of player%}%::lvl} to 3
- set {team::%{team::%uuid of player%}%::farve.magenta} to true
- add 1 to {team::%{team::%uuid of player%}%::antal.farver}
- broadcast "{@p}Teamet &b&l%{team::%uuid of player%}%&f er steget i level &b%{team::%{team::%uuid of player%}%::lvl}%"
- close player's inventory
- stop
- if {team::%{team::%uuid of player%}%::lvl} is 3:
- close player's inventory
- stop
- else:
- send "{@p}Kun ejeren kan levelup teamet."
- close player's inventory
- stop
- if name of clicked item is "&f&lTeam Farver":
- open chest with 5 rows named "Team Farver" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Farver":
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to 160 named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to 160:3 named ""
- set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
- set slot 13 of player's current inventory to gray dye named "&7&lGrå" with lore "&7Klik for at aktiverer"
- if {team::%{team::%uuid of player%}%::farve.orange} is true:
- set slot 20 of player's current inventory to orange dye named "&6&lOrange" with lore "&7Klik for at aktiverer"
- else:
- set slot 20 of player's current inventory to orange dye named "&6&lOrange" with lore "&7Fås i level 2"
- if {team::%{team::%uuid of player%}%::farve.magenta} is true:
- set slot 21 of player's current inventory to magenta dye named "&d&lMagenta" with lore "&7Klik for at aktiverer"
- else:
- set slot 21 of player's current inventory to magenta dye named "&d&lMagenta" with lore "&7Fås i level 3"
- if {team::%{team::%uuid of player%}%::farve.grøn} is true:
- set slot 22 of player's current inventory to light green dye named "&a&lGrøn" with lore "&7Klik for at aktiverer"
- else:
- set slot 22 of player's current inventory to light green dye named "&a&lGrøn" with lore "&7Fås i teamshoppen."
- if {team::%{team::%uuid of player%}%::farve.blå} is true:
- set slot 23 of player's current inventory to light blue dye named "&b&lBlå" with lore "&7Klik for at aktiverer"
- else:
- set slot 23 of player's current inventory to light blue dye named "&b&lBlå" with lore "&7Fås i teamshoppen."
- if {team::%{team::%uuid of player%}%::farve.rød} is true:
- set slot 24 of player's current inventory to rose red named "&c&lRød" with lore "&7Klik for at aktiverer"
- else:
- set slot 24 of player's current inventory to rose red named "&c&lRød" with lore "&7Fås i teamshoppen."
- stop
- if name of clicked item is "&6&lTeam Kister":
- wait 1 ticks
- execute player command "tk"
- stop
- if name of clicked item is "&e&lTeam Shop":
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
- open chest with 5 rows named "Team Shop" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Shop":
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to white stained glass pane named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to light blue stained glass pane named ""
- set slot 4 of player's current inventory to book named "&3&lTEAM BANK" with lore "&7Bank: &b%{bank.team::%{team::%uuid of player%}%}%,-"
- set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
- if {team::%{team::%uuid of player%}%::maxmem} is 3:
- set {_pris} to "&7Pris&8: &a10000,-"
- if {team::%{team::%uuid of player%}%::maxmem} is 4:
- set {_pris} to "&7Pris&8: &a25000,-"
- 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}%"
- if {team::%{team::%uuid of player%}%::maxmem} is 5:
- set slot 19 of player's current inventory to book named "&4&lMAKS" with lore "&cDu har købt adgang til maks antal medlemmer."
- if {team::%{team::%uuid of player%}%::adgang.til.chest1} is false:
- 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,-"
- if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
- if {team::%{team::%uuid of player%}%::lvl} is 1:
- set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 2."
- else:
- 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,-"
- if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
- if {team::%{team::%uuid of player%}%::lvl} isn't 3:
- set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 3."
- else:
- 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,-"
- if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
- set slot 20 of player's current inventory to chest named "&4&lMAKS" with lore "&cDu har låst op for maks team kister."
- if {team::%{team::%uuid of player%}%::farve.grøn} is false:
- 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,-"
- else:
- set slot 21 of player's current inventory to light green dye named "&a&lGRØN TEAMFARVE!" with lore "&7Allerede købt"
- if {team::%{team::%uuid of player%}%::farve.blå} is false:
- 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,-"
- else:
- set slot 22 of player's current inventory to light blue dye named "&b&lBLÅ TEAMFARVE!" with lore "&7Allerede købt"
- if {team::%{team::%uuid of player%}%::farve.rød} is false:
- 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,-"
- else:
- set slot 23 of player's current inventory to rose red named "&c&lRØD TEAMFARVE!" with lore "&7Allerede købt"
- set slot 24 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
- set slot 25 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
- stop
- else:
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- open chest with 5 rows named "Team Shop" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Shop":
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to white stained glass pane named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to light blue stained glass pane named ""
- set slot 4 of player's current inventory to book named "&3&lTEAM BANK" with lore "&7Bank: &b%{bank.team::%{team::%uuid of player%}%}%,-"
- set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
- if {team::%{team::%uuid of player%}%::maxmem} is 3:
- set {_pris} to "&7Pris&8: &a10000,-"
- if {team::%{team::%uuid of player%}%::maxmem} is 4:
- set {_pris} to "&7Pris&8: &a25000,-"
- 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}%"
- if {team::%{team::%uuid of player%}%::maxmem} is 5:
- set slot 19 of player's current inventory to book named "&4&lMAKS" with lore "&cDu har købt adgang til maks antal medlemmer."
- if {team::%{team::%uuid of player%}%::adgang.til.chest1} is false:
- 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,-"
- if {team::%{team::%uuid of player%}%::adgang.til.chest1} is true:
- if {team::%{team::%uuid of player%}%::lvl} is 1:
- set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 2."
- else:
- 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,-"
- if {team::%{team::%uuid of player%}%::adgang.til.chest2} is true:
- if {team::%{team::%uuid of player%}%::lvl} isn't 3:
- set slot 20 of player's current inventory to chest named "&c&l+1 TEAMKISTE" with lore "&7Lås op i level 3."
- else:
- 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,-"
- if {team::%{team::%uuid of player%}%::adgang.til.chest3} is true:
- set slot 20 of player's current inventory to chest named "&4&lMAKS" with lore "&cDu har låst op for maks team kister."
- if {team::%{team::%uuid of player%}%::farve.grøn} is false:
- 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,-"
- else:
- set slot 21 of player's current inventory to light green dye named "&a&lGRØN TEAMFARVE!" with lore "&7Allerede købt"
- if {team::%{team::%uuid of player%}%::farve.blå} is false:
- 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,-"
- else:
- set slot 22 of player's current inventory to light blue dye named "&b&lBLÅ TEAMFARVE!" with lore "&7Allerede købt"
- if {team::%{team::%uuid of player%}%::farve.rød} is false:
- 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,-"
- else:
- set slot 23 of player's current inventory to rose red named "&c&lRØD TEAMFARVE!" with lore "&7Allerede købt"
- set slot 24 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
- set slot 25 of player's current inventory to 166 named "&4&lKOMMER SNART" with lore "&7Har du forslag? Så skriv dem på discord!"
- stop
- else:
- send "{@p}Det er kun ejeren det kan købe i shoppen."
- close player's inventory
- stop
- if name of clicked item is "&7&lINDSTILLINGER":
- if {team::%{team::%uuid of player%}%::ejer} is uuid of player:
- open chest with 5 rows named "Team Indstillinger" to player
- wait 3 ticks
- if inventory name of player's current inventory is "Team Indstillinger":
- #----------------------------------------------------------------
- loop integers from 0 to 8:
- set slot loop-integer of player's current inventory to 160 named ""
- loop integers from 36 to 44:
- set slot loop-integer of player's current inventory to 160:3 named ""
- set slot 40 of player's current inventory to 166 named "&4&lTILBAGE" with lore "&7Klik for at komme tilbage"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Alle":
- set {_inds1} to "&7Adgang: &eAlle"
- if {team::%{team::%uuid of player%}%::adgangtil.shop} is "Ejer":
- set {_inds1} to "&7Adgang: &eKun ejer"
- set slot 20 of player's current inventory to gold nugget named "&6&lShop" with lore "%{_inds1}%||&r||&7Klik for at ændre"
- if {team::%{team::%uuid of player%}%::teamdamaga} is false:
- set {_inds2} to "&7Aktiveret: &cFra"
- if {team::%{team::%uuid of player%}%::teamdamaga} is true:
- set {_inds2} to "&7Aktiveret: &cTil"
- set slot 22 of player's current inventory to redstone named "&4&lTeam Damage" with lore "%{_inds2}%||&r||&7Klik for at ændre"
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Alle":
- set {_inds3} to "&7Adgang: &fAlle"
- if {team::%{team::%uuid of player%}%::adgangtil.farve} is "Ejer":
- set {_inds3} to "&7Adgang: &fEjer"
- set slot 24 of player's current inventory to bonemeal named "&f&lTeam Farver" with lore "%{_inds3}%||&r||&7Klik for at ændre"
- stop
- else:
- send "{@p}Kun ejeren af teamet, kan ændre i indstillingerne."
- on inventory click:
- if inventory name of player's current inventory is "Team Farver":
- cancel event
- if name of clicked item is "&7&lGrå":
- set {team::%{team::%uuid of player%}%::farve} to "&7"
- send "{@p}Du ændrede jeres teamfarve til &7grå"
- close player's inventory
- stop
- if name of clicked item is "&6&lOrange":
- if {team::%{team::%uuid of player%}%::farve.orange} is true:
- set {team::%{team::%uuid of player%}%::farve} to "&6"
- send "{@p}Du ændrede jeres teamfarve til &6orange"
- close player's inventory
- stop
- else:
- send "{@p}Du har ikke adgang til denne farve."
- close player's inventory
- stop
- if name of clicked item is "&d&lMagenta":
- if {team::%{team::%uuid of player%}%::farve.magenta} is true:
- set {team::%{team::%uuid of player%}%::farve} to "&d"
- send "{@p}Du ændrede jeres teamfarve til &dmagenta"
- close player's inventory
- stop
- else:
- send "{@p}Du har ikke adgang til denne farve."
- close player's inventory
- stop
- if name of clicked item is "&a&lGrøn":
- if {team::%{team::%uuid of player%}%::farve.grøn} is true:
- set {team::%{team::%uuid of player%}%::farve} to "&a"
- send "{@p}Du ændrede jeres teamfarve til &agrøn"
- close player's inventory
- stop
- else:
- send "{@p}Du har ikke adgang til denne farve."
- close player's inventory
- stop
- if name of clicked item is "&b&lBlå":
- if {team::%{team::%uuid of player%}%::farve.blå} is true:
- set {team::%{team::%uuid of player%}%::farve} to "&b"
- send "{@p}Du ændrede jeres teamfarve til &bblå"
- close player's inventory
- stop
- else:
- send "{@p}Du har ikke adgang til denne farve."
- close player's inventory
- stop
- if name of clicked item is "&c&lRød":
- if {team::%{team::%uuid of player%}%::farve.rød} is true:
- set {team::%{team::%uuid of player%}%::farve} to "&c"
- send "{@p}Du ændrede jeres teamfarve til &crød"
- close player's inventory
- stop
- else:
- send "{@p}Du har ikke adgang til denne farve."
- close player's inventory
- stop
- if name of clicked item is "&4&lTILBAGE":
- wait 1 tick
- execute player command "team start"
- stop
- on inventory click:
- if inventory name of player's current inventory is "Team Hjælp":
- cancel event
- close player's inventory
- if inventory name of player's current inventory contains "Team Info":
- cancel event
- close player's inventory
- On death:
- if {team::%uuid of attacker%} is {team::%uuid of victim%}:
- stop
- else:
- If {team::%uuid of attacker%} is set:
- add 1 to {kills.team::%{team::%uuid of attacker%}%}
- If {team::%uuid of victim%} is set:
- add 1 to {deaths.team::%{team::%uuid of victim%}%}
- on damage:
- if {team::%uuid of attacker%} is {team::%uuid of victim%}:
- if {team::%{team::%uuid of attacker%}%::teamdamaga} is false:
- cancel event
- on join:
- set {team.status::%player%} to "online"
- on quit:
- set {team.status::%player%} to "offline"
- command /teamdisband <text>:
- aliases: /bruhnetwork:teamdisband
- permission: *
- trigger:
- if player is op:
- send "{@p}Du fjernede teamet &b%arg-1%"
- remove arg-1 from {teams::*}
- delete {team::%arg-1%::lvlkills}
- delete {team::%arg-1%::lvl}
- delete {team::%arg-1%::kills}
- delete {team::%arg-1%::deaths}
- delete {team::%arg-1%::ejer}
- loop {team::%arg-1%::medlemmer::*}:
- remove loop-value from {team::%{team::%loop-value%}%::medlemmer::*}
- delete {team::%loop-value%}
- delete {team::%arg-1%}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement