Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Changelog:
- # - Fixed one bug in /f dominar <3
- #Meta 2018:
- # - Conhecer a Sophia Lilis por internet e depois talvez in real life. [POSSÍVEL]
- command /teste1:
- trigger:
- set {_FactionTag} to value "%player%.FactionTag" get of "plugins/Factions/data.yml"
- set {_it::*} to configuration section "Terras" get of "plugins/Factions/claimdata.yml"
- loop {_it::*}:
- set {_n} to yml value "Terras.%loop-value%.%{_FactionTag}%" of file "plugins/Factions/claimdata.yml"
- if "%{_n}%" = "%{_FactionTag}%":
- delete yml nodes "Terras.%loop-value%" from file "plugins/Factions/claimdata.yml"
- on damage of player:
- set {_FactionV} to value "%victim%.FactionTag" get of "plugins/Factions/claimdata.yml"
- set {_FactionA} to value "%attacker%.FactionTag" get of "plugins/Factions/claimdata.yml"
- if {_FactionA} is equal to {_FactionV}:
- cancel event
- on damage:
- set {_Claim} to value "Terras.%chunk at victim%" get of "plugins/Factions/claimdata.yml"
- if {_Claim} is "safezone":
- cancel event
- on death of player:
- if attacker is player:
- set {_FactionTag} to value "%attacker%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRole} to value "%attacker%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionRole} is "LEADER":
- set {_Role} to "##"
- if {_FactionRole} is "OFFICER":
- set {_Role} to "*"
- if {_FactionRole} is "MEMBER":
- set {_Role} to "+"
- if {_FactionRole} is "RECRUIT":
- set {_Role} to "-"
- set {_FactionTagV} to value "%victim%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%victim%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionRoleV} is "LEADER":
- set {_RoleV} to "##"
- if {_FactionRoleV} is "OFFICER":
- set {_RoleV} to "*"
- if {_FactionRoleV} is "MEMBER":
- set {_RoleV} to "+"
- if {_FactionRoleV} is "RECRUIT":
- set {_RoleV} to "-"
- if {_FactionTagV} is "null":
- set {_Victim} to "%victim%"
- else:
- set {_Victim} to "[%{_RoleV}%%{_FactionTagV}%] %victim%"
- if {_FactionTag} is "null":
- set {_Attacker} to "%victim%"
- else:
- set {_Attacker} to "[%{_Role}%%{_FactionTag}%] %attacker%"
- loop all players in radius 16 of player:
- add 1 to {_n}
- set {_players::%{_n}%} to loop-player
- send "&3%{_Victim}% &cfoi morto por &3%{_Attacker}%." to {_players::%{_n}%}
- set {_Abates} to value "%attacker%.Abates" get of "plugins/Factions/data.yml"
- set {_Mortes} to value "%victim%.Mortes" get of "plugins/Factions/data.yml"
- set {_Abates} to {_Abates} parsed as integer
- add 1 to {_Abates}
- set "%attacker%.Abates" to "%{_Abates}%" in yaml file "plugins/Factions/data.yml"
- set {_Mortes} to {_Mortes} parsed as integer
- add 1 to {_Mortes}
- set "%victim%.Mortes" to "%{_Mortes}%" in yaml file "plugins/Factions/data.yml"
- command /c [<text>]:
- trigger:
- if sender is console:
- send "&cVocê não está permitido utilizar esta ferramenta."
- else:
- if arg 1 is set:
- set {_FactionTag} to value "%player%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRole} to value "%player%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionRole} is "LEADER":
- set {_Tag} to "##"
- if {_FactionRole} is "OFFICER":
- set {_Tag} to "*"
- if {_FactionRole} is "MEMBER":
- set {_Tag} to "+"
- if {_FactionRole} is "RECRUIT":
- set {_Tag} to "-"
- if {_FactionTag} is "null":
- send "&cVocê não tem uma facção."
- else:
- loop all players:
- set {_FactionTagV} to value "%loop-player%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTag} is equal to {_FactionTagV}:
- send "&a%{_Tag}%&f%player%: &b%arg 1%" to loop-player
- else:
- send "&cUtilize /c <mensagem>."
- on right click:
- set {_FactionTag} to value "%player%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRole} to value "%player%.FactionRole" get of "plugins/Factions/data.yml"
- set {_Claim} to value "Terras.%chunk of event-block%" get of "plugins/Factions/claimdata.yml"
- if {_Claim} is "warzone" or "safezone":
- stop
- if {_Claim} is "%{_FactionTag}%":
- if {_FactionRole} is "RECRUIT":
- send "&cRecrutas não podem interagir com blocos nas terras da facção."
- else:
- stop
- if {_Claim} is "%{_FactionTag}%-PROTECTION":
- if {_FactionRole} is "RECRUIT":
- send "&cRecrutas não podem interagir com blocos nas terras da facção."
- else:
- stop
- if {_Claim} is set:
- loop {FactionList::*}:
- set {_FactionTagV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagV} is equal to {_Claim}:
- set {_FactionV} to value "%loop-value%.Faction" get of "plugins/Factions/data.yml"
- send "&cEste bloco pertence a facção [%{_Claim}%] %{_FactionV}%, você não pode interagir com ele."
- stop
- on break:
- set {_Admin} to value "%player%.Admin" get of "plugins/Factions/data.yml"
- if {_Admin} is "true":
- stop
- set {_FactionTag} to value "%player%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRole} to value "%player%.FactionRole" get of "plugins/Factions/data.yml"
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- if {_Claim} isn't set:
- stop
- if {_Claim} is "warzone" or "safezone":
- cancel event
- if {_Claim} is "%{_FactionTag}%-PROTECTION":
- if {_FactionRole} is "RECRUIT":
- stop
- if {_Claim} is "%{_FactionTag}%":
- if {_FactionRole} is "RECRUIT":
- stop
- else:
- cancel event
- on place:
- set {_Admin} to value "%player%.Admin" get of "plugins/Factions/data.yml"
- if {_Admin} is "true":
- stop
- set {_FactionTag} to value "%player%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRole} to value "%player%.FactionRole" get of "plugins/Factions/data.yml"
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- if {_Claim} isn't set:
- stop
- if {_Claim} is "warzone" or "safezone":
- cancel event
- if {_Claim} is "%{_FactionTag}%-PROTECTION":
- if {_FactionRole} is "RECRUIT":
- stop
- if {_Claim} is "%{_FactionTag}%":
- if {_FactionRole} is "RECRUIT":
- stop
- else:
- cancel event
- on load:
- if file "plugins/Factions/geradoresdata.yml" doesn't exists:
- create file "plugins/Factions/geradoresdata.yml"
- if file "plugins/Factions/claimdata.yml" doesn't exists:
- create file "plugins/Factions/claimdata.yml"
- if file "plugins/Factions/data.yml" doesn't exists:
- create file "plugins/Factions/data.yml"
- on join:
- set "%player%.isOnline" to "Online" in yml file "plugins/Factions/data.yml"
- on disconnect:
- set "%player%.isOnline" to "Offline" in yml file "plugins/Factions/data.yml"
- on quit:
- set {_tmpO} to now
- set {_dia} to day of month from date {_tmpO}
- if {_dia} is "0":
- set {_dia} to "00"
- if {_dia} is "1":
- set {_dia} to "01"
- if {_dia} is "2":
- set {_dia} to "02"
- if {_dia} is "3":
- set {_dia} to "03"
- if {_dia} is "4":
- set {_dia} to "04"
- if {_dia} is "5":
- set {_dia} to "05"
- if {_dia} is "6":
- set {_dia} to "06"
- if {_dia} is "7":
- set {_dia} to "07"
- if {_dia} is "8":
- set {_dia} to "08"
- if {_dia} is "9":
- set {_dia} to "09"
- set {_mes} to month from date {_tmpO}
- if {_mes} is "1":
- set {_mes} to "01"
- if {_mes} is "2":
- set {_mes} to "02"
- if {_mes} is "3":
- set {_mes} to "03"
- if {_mes} is "4":
- set {_mes} to "04"
- if {_mes} is "5":
- set {_mes} to "05"
- if {_mes} is "6":
- set {_mes} to "06"
- if {_mes} is "7":
- set {_mes} to "07"
- if {_mes} is "8":
- set {_mes} to "08"
- if {_mes} is "9":
- set {_mes} to "09"
- set {_ano} to year from date {_tmpO}
- set {_horas} to hours from date {_tmpO}
- if {_horas} is "0":
- set {_horas} to "00"
- if {_horas} is "1":
- set {_horas} to "01"
- if {_horas} is "2":
- set {_horas} to "02"
- if {_horas} is "3":
- set {_horas} to "03"
- if {_horas} is "4":
- set {_horas} to "04"
- if {_horas} is "5":
- set {_horas} to "05"
- if {_horas} is "6":
- set {_horas} to "06"
- if {_horas} is "7":
- set {_horas} to "07"
- if {_horas} is "8":
- set {_horas} to "08"
- if {_horas} is "9":
- set {_horas} to "09"
- set {_minutes} to minutes from date {_tmpO}
- if {_minutes} is "0":
- set {_minutes} to "00"
- if {_minutes} is "1":
- set {_minutes} to "01"
- if {_minutes} is "2":
- set {_minutes} to "02"
- if {_minutes} is "3":
- set {_minutes} to "03"
- if {_minutes} is "4":
- set {_minutes} to "04"
- if {_minutes} is "5":
- set {_minutes} to "05"
- if {_minutes} is "6":
- set {_minutes} to "06"
- if {_minutes} is "7":
- set {_minutes} to "07"
- if {_minutes} is "8":
- set {_minutes} to "08"
- if {_minutes} is "9":
- set {_minutes} to "09"
- set "%player%.LastDate" to "%{_dia}%/%{_mes}%/%{_ano}% %{_horas}%:%{_minutes}%" in yml file "plugins/Factions/data.yml"
- on disconnect:
- loop all players:
- set {_Faction} to value "%player%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionL} to value "%loop-player%.Faction" get of "plugins/Factions/data.yml"
- if {_Faction} is "null":
- stop
- if {_FactionL} is equal to {_Faction}:
- if loop-player isn't player:
- send "&c%player% saiu." to loop-player
- stop
- on join:
- loop all players:
- set {_Faction} to value "%player%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionL} to value "%loop-player%.Faction" get of "plugins/Factions/data.yml"
- if {_Faction} is "null":
- stop
- if {_FactionL} is equal to {_Faction}:
- if loop-player isn't player:
- send "&a%player% entrou." to loop-player
- stop
- on first join:
- add player to {FactionList::*}
- set {_tmpO} to now
- set {_dia} to day of month from date {_tmpO}
- if {_dia} is "1":
- set {_dia} to "01"
- if {_dia} is "2":
- set {_dia} to "02"
- if {_dia} is "3":
- set {_dia} to "03"
- if {_dia} is "4":
- set {_dia} to "04"
- if {_dia} is "5":
- set {_dia} to "05"
- if {_dia} is "6":
- set {_dia} to "06"
- if {_dia} is "7":
- set {_dia} to "07"
- if {_dia} is "8":
- set {_dia} to "08"
- if {_dia} is "9":
- set {_dia} to "09"
- set {_mes} to month from date {_tmpO}
- if {_mes} is "1":
- set {_mes} to "01"
- if {_mes} is "2":
- set {_mes} to "02"
- if {_mes} is "3":
- set {_mes} to "03"
- if {_mes} is "4":
- set {_mes} to "04"
- if {_mes} is "5":
- set {_mes} to "05"
- if {_mes} is "6":
- set {_mes} to "06"
- if {_mes} is "7":
- set {_mes} to "07"
- if {_mes} is "8":
- set {_mes} to "08"
- if {_mes} is "9":
- set {_mes} to "09"
- set {_ano} to year from date {_tmpO}
- set {_horas} to hours from date {_tmpO}
- if {_horas} is "0":
- set {_horas} to "00"
- if {_horas} is "1":
- set {_horas} to "01"
- if {_horas} is "2":
- set {_horas} to "02"
- if {_horas} is "3":
- set {_horas} to "03"
- if {_horas} is "4":
- set {_horas} to "04"
- if {_horas} is "5":
- set {_horas} to "05"
- if {_horas} is "6":
- set {_horas} to "06"
- if {_horas} is "7":
- set {_horas} to "07"
- if {_horas} is "8":
- set {_horas} to "08"
- if {_horas} is "9":
- set {_horas} to "09"
- set {_minutes} to minutes from date {_tmpO}
- if {_minutes} is "0":
- set {_minutes} to "00"
- if {_minutes} is "1":
- set {_minutes} to "01"
- if {_minutes} is "2":
- set {_minutes} to "02"
- if {_minutes} is "3":
- set {_minutes} to "03"
- if {_minutes} is "4":
- set {_minutes} to "04"
- if {_minutes} is "5":
- set {_minutes} to "05"
- if {_minutes} is "6":
- set {_minutes} to "06"
- if {_minutes} is "7":
- set {_minutes} to "07"
- if {_minutes} is "8":
- set {_minutes} to "08"
- if {_minutes} is "9":
- set {_minutes} to "09"
- set "%player%.Admin" to "false" in yml file "plugins/Factions/data.yml"
- set "%player%.NickName" to "%player%" in yml file "plugins/Factions/data.yml"
- set "%player%.Faction" to "null" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionPower" to "5" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionMaxPower" to "5" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionRole" to "null" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionTag" to "null" in yml file "plugins/Factions/data.yml"
- set "%player%.isOnline" to "Online" in yml file "plugins/Factions/data.yml"
- set "%player%.Group" to "Default" in yml file "plugins/Factions/data.yml"
- set "%player%.LastDate" to "%{_dia}%/%{_mes}%/%{_ano}% %{_horas}%:%{_minutes}%" in yml file "plugins/Factions/data.yml"
- set "%player%.Cadastrado" to "%{_dia}%/%{_mes}%/%{_ano}% %{_horas}%:%{_minutes}%" in yml file "plugins/Factions/data.yml"
- set "%player%.Mortes" to "0" in yml file "plugins/Factions/data.yml"
- set "%player%.Abates" to "0" in yml file "plugins/Factions/data.yml"
- set "%player%.Wins" to "0" in yml file "plugins/Factions/data.yml"
- set "%player%.Level" to "0" in yml file "plugins/Factions/data.yml"
- #send json of "&a&l[Facções] &71 facção acaba de ser desfeita por inatividade!" to all players
- command /f [<text>] [<text>] [<text>] [<text>]:
- aliases: /f:f
- trigger:
- if player have permission "master.group":
- set {_Tag} to "&6[Master]"
- if player have permission "gerente.group":
- set {_Tag} to "&4[Gerente]"
- if player have permission "admin.group":
- set {_Tag} to "&c[Admin]"
- if player have permission "moderador.group":
- set {_Tag} to "&2[Moderador]"
- if player have permission "ajudante.group":
- set {_Tag} to "&e[Ajudante]"
- if player have permission "youtuber.group":
- set {_Tag} to "&c[YT]"
- if player have permission "imperador.group":
- set {_Tag} to "&b[Imperador]"
- if player have permission "supremo.group":
- set {_Tag} to "&4[Supremo]"
- if player have permission "lendario.group":
- set {_Tag} to "&2[Lendário]"
- if player have permission "heroi.group":
- set {_Tag} to "&5[Herói]"
- if player have permission "campeao.group":
- set {_Tag} to "&3[Campeão]"
- if player have permission "default.group":
- set {_Tag} to "&7"
- set {_Admin} to value "%player%.Admin" get of "plugins/Factions/data.yml"
- set {_IsOnline} to value "%player%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionPower} to value "%player%.FactionPower" get of "plugins/Factions/data.yml"
- set {_Faction} to value "%player%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRole} to value "%player%.FactionRole" get of "plugins/Factions/data.yml"
- set {_FactionTag} to value "%player%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionMaxPower} to value "%player%.FactionMaxPower" get of "plugins/Factions/data.yml"
- set {_LastDate} to value "%player%.LastDate" get of "plugins/Factions/data.yml"
- set {_Abates} to value "%player%.Abates" get of "plugins/Factions/data.yml"
- set {_Mortes} to value "%player%.Mortes" get of "plugins/Factions/data.yml"
- set {_Wins} to value "%player%.Wins" get of "plugins/Factions/data.yml"
- set {_Abates} to {_Abates} parsed as integer
- set {_Mortes} to {_Mortes} parsed as integer
- if arg 1 isn't set:
- if {_Faction} is "null":
- open chest with 5 rows named "%player%" to player
- format slot 10 of player with skull of ("%player%" parsed as an offline player) named "%{_Tag}%%player%" with lore "&fPoder: &7%{_FactionPower}%/%{_FactionMaxPower}%||&fCargo: &7%{_Role}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fMortes: &7%{_Mortes}%||&fStatus: &7%{_Status}%" to be unstealable
- if arg 1 is "aceitar":
- if arg 2 isn't set:
- send "&cUtilize /f aceitar convite <tag>."
- stop
- if arg 2 is set:
- if arg 3 isn't set:
- send "&cUtilize /f aceitar convite <tag>."
- stop
- else:
- if file "plugins/Factions/faction-%arg 3%.yml" exists:
- if {Convite::%arg 3%::%player%::*} is true:
- loop {FactionList::*}:
- set {_FactionTagV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagV} is equal to arg 3:
- add 1 to {_m}
- if {_m} >= 15:
- send "&cOps! Esta facção atingiu o limite máximo de jogadores."
- stop
- send "&aVocê juntou-se a facção %arg 3%!"
- delete {Convite::%arg 3%::%player%::*}
- set "%player%.FactionRole" to "RECRUIT" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionTag" to "%arg 3%" in yml file "plugins/Factions/data.yml"
- loop all players:
- set {_FactionTagA} to value "%loop-player%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagA} is equal to {_FactionTag}:
- send "&a%player% é mais novo membro desta facção!" to loop-player
- loop {FactionList::*}:
- set {_FactionTagA} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagA} is equal to arg 3:
- set {_FactionA} to value "%loop-value%.Faction" get of "plugins/Factions/data.yml"
- set "%player%.Faction" to "%{_FactionA}%" in yml file "plugins/Factions/data.yml"
- stop
- else:
- send "&cOxi! Você não foi convidado para entrar na facção ""%arg 3%""."
- stop
- else:
- send "&cOps! A facção informada não existe."
- stop
- if arg 1 is "convidarmenugui1177":
- if arg 2 isn't set:
- send "&cUtilize /f convidar <jogador>."
- if arg 2 is set:
- if {Convite::%{_FactionTag}%::%arg 2%} is true:
- send "&cHey! Você já enviou um convite de facção para este jogador!"
- stop
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- set {_IsOnline} to value "%arg 2%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionA} to value "%arg 2%.Faction" get of "plugins/Factions/data.yml"
- if {_IsOnline} is "Offline":
- send "&cEste usuário não está online."
- stop
- if {_IsOnline} is "Online":
- if {_FactionA} is "null":
- loop {FactionList::*}:
- set {_FactionV} to value "%loop-value%.NickName" get of "plugins/Factions/data.yml"
- if {_FactionV} is equal to arg 2:
- set {_Leader} to loop-value
- loop all players:
- if loop-player is "%arg 2%":
- send "&aVocê foi convidado para entrar na facção ""%{_FactionTag}%""." to loop-player
- send json of "&eClique" then " &e&lAQUI" run "/f convites" then " &epara ver seus convites." to loop-player
- send "&aVocê convidou %arg 2% para a sua facção."
- set {Convite::%{_FactionTag}%::%arg 2%::*} to true
- else:
- send "&cO jogador ""%arg 2%"" já faz parte de outra facção."
- stop
- else:
- send "&cEste usuário não existe."
- stop
- if arg 1 is "convidar":
- if arg 2 isn't set:
- send "&cUtilize /f convidar <jogador>."
- if arg 2 is set:
- if {Convite::%{_FactionTag}%::%arg 2%} is true:
- send "&cHey! Você já enviou um convite de facção para este jogador!"
- stop
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- set {_IsOnline} to value "%arg 2%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionTagA} to value "%arg 2%.FactionTag" get of "plugins/Factions/data.yml"
- if {_IsOnline} is "Offline":
- send "&cO jogador ""%arg 2%"" não está online!"
- stop
- if {_FactionTagA} isn't set:
- send "&cEste usuário não existe."
- stop
- if {_IsOnline} is "Online":
- if {_FactionTagA} is "null":
- loop {FactionList::*}:
- set {_FactionTagV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTag} is equal to {_FactionTagV}:
- add 1 to {_m}
- if {_m} is 15:
- send "&cOps! Sua facção atingiu o limite máximo de jogadores."
- stop
- set {_FactionV} to value "%loop-value%.NickName" get of "plugins/Factions/data.yml"
- if {_FactionV} is equal to arg 2:
- set {_Leader} to loop-value
- loop all players:
- if loop-player is "%arg 2%":
- send "&aVocê foi convidado para entrar na facção ""%{_FactionTag}%""." to loop-player
- send json of "&eClique" then " &e&lAQUI" run "/f convites" then " &epara ver seus convites." to loop-player
- send "&aVocê convidou ""%arg 2%"" para a sua facção."
- set {Convite::%{_FactionTag}%::%arg 2%::*} to true
- else:
- send "&cO jogador ""%arg 2%"" já faz parte de outra facção."
- stop
- if arg 1 is "base":
- if arg 2 isn't set:
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- set {_Base} to value "location.enabled" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_x} to yml value "location.x" from file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_y} to yml value "location.y" from file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_z} to yml value "location.z" from file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_loc.x} to {_x} parsed as number
- set {_loc.y} to {_y} parsed as number
- set {_loc.z} to {_z} parsed as number
- if {_Base} is "true":
- set {_location} to location ({_loc.x}, {_loc.y}, {_loc.z})
- set {_Claim} to value "Terras.%chunk at {_location}%" get of "plugins/Factions/claimdata.yml"
- if {_Claim} is "%{_FactionTag}%":
- send "&aTeleportado para a base da sua facção."
- teleport sender to location ({_loc.x}, {_loc.y}, {_loc.z})
- stop
- else:
- send "&cO local da sua base não pertence mais a sua facção."
- set "location.enabled" to "false" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- stop
- if {_Base} is "false":
- send "&cHum... Sua facção ainda não está com sua base definida."
- stop
- if arg 2 is "remover":
- set "location.enabled" to "false" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set "location.x" to "%player's X coordinate%" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set "location.y" to "%player's Y coordinate%" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set "location.z" to "%player's Z coordinate%" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- send "&aBase removida com sucesso!"
- stop
- if arg 2 is "definir":
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- if {_Claim} is "%{_FactionTag}%" or "%{_FactionTag}%-PROTECTION":
- set "location.enabled" to "true" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set "location.x" to "%player's X coordinate%" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set "location.y" to "%player's Y coordinate%" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set "location.z" to "%player's Z coordinate%" in yml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- send "&aLocalização de base alterada com sucesso."
- stop
- else:
- send "&cVocê só pode definir bases dentro das terras da sua facção."
- if arg 1 is "membros":
- if arg 2 isn't set:
- if {_Faction} is "null":
- send "&cVocê não faz parte de nenhum facção, utilize /f membros <tag>."
- stop
- else:
- open chest with 6 rows named "%{_Faction}% - Membros" to player
- format slot 11 of player with player head named "&7Vago" to be unstealable
- format slot 12 of player with player head named "&7Vago" to be unstealable
- format slot 13 of player with player head named "&7Vago" to be unstealable
- format slot 14 of player with player head named "&7Vago" to be unstealable
- format slot 15 of player with player head named "&7Vago" to be unstealable
- format slot 20 of player with player head named "&7Vago" to be unstealable
- format slot 21 of player with player head named "&7Vago" to be unstealable
- format slot 22 of player with player head named "&7Vago" to be unstealable
- format slot 23 of player with player head named "&7Vago" to be unstealable
- format slot 24 of player with player head named "&7Vago" to be unstealable
- format slot 29 of player with player head named "&7Vago" to be unstealable
- format slot 30 of player with player head named "&7Vago" to be unstealable
- format slot 31 of player with player head named "&7Vago" to be unstealable
- format slot 32 of player with player head named "&7Vago" to be unstealable
- format slot 33 of player with player head named "&7Vago" to be unstealable
- set {_s} to 11
- if {_s} is 15:
- set {_s} to 20
- if {_s} is 24:
- set {_s} to 29
- loop {FactionList::*}:
- set {_FactionTagL} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagL} is equal to {_FactionTag}:
- set {_IsOnlineV} to value "%loop-value%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionPowerV} to value "%loop-value%.FactionPower" get of "plugins/Factions/data.yml"
- set {_FactionV} to value "%loop-value%.Faction" get of "plugins/Factions/data.yml"
- set {_GroupV} to value "%loop-value%.Group" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value%.FactionRole" get of "plugins/Factions/data.yml"
- set {_FactionTagV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionMaxPowerV} to value "%loop-value%.FactionMaxPower" get of "plugins/Factions/data.yml"
- set {_LastDateV} to value "%loop-value%.LastDate" get of "plugins/Factions/data.yml"
- set {_AbatesV} to value "%loop-value%.Abates" get of "plugins/Factions/data.yml"
- set {_MortesV} to value "%loop-value%.Mortes" get of "plugins/Factions/data.yml"
- set {_WinsV} to value "%loop-value%.Wins" get of "plugins/Factions/data.yml"
- if {_GroupV} is "Default":
- set {_TagV} to "&7"
- if {_GroupV} is "Master":
- set {_TagV} to "&6[Master] "
- if {_GroupV} is "Gerente":
- set {_TagV} to "&4[Gerente] "
- if {_GroupV} is "Admin":
- set {_TagV} to "&c[Admin] "
- if {_GroupV} is "Moderador":
- set {_TagV} to "&2[Moderador] "
- if {_GroupV} is "Ajudante":
- set {_TagV} to "&e[Ajudante] "
- if {_GroupV} is "Supremo":
- set {_TagV} to "&4[Supremo] "
- if {_GroupV} is "Lendario":
- set {_TagV} to "&2[Lendário] "
- if {_GroupV} is "Heroi":
- set {_TagV} to "&5[Herói] "
- if {_GroupV} is "Campeao":
- set {_TagV} to "&3[Campeão] "
- if {_GroupV} is "Youtuber":
- set {_TagV} to "&c[YT] "
- if {_GroupV} is "Imperador":
- set {_TagV} to "&b[Imperador] "
- if {_FactionRoleV} is "LEADER":
- set {_RoleV} to "##Líder"
- if {_FactionRoleV} is "OFFICER":
- set {_RoleV} to "*Capitão"
- if {_FactionRoleV} is "MEMBER":
- set {_RoleV} to "+Membro"
- if {_FactionRoleV} is "RECRUIT":
- set {_RoleV} to "-Recruta"
- if {_IsOnlineV} is "Online":
- set {_OnlineV} to "&aOnline"
- if {_IsOnlineV} is "Offline":
- set {_OnlineV} to "&cOffline"
- format slot {_s} of player with skull of loop-value named "%{_TagV}%%loop-value%" with lore "&fPoder: &7%{_FactionPowerV}%/%{_FactionMaxPowerV}%||&fCargo: &7%{_RoleV}%||&fKDR: &70.0||&fAbates: &7%{_AbatesV}%||&fMortes: &7%{_MortesV}%||&fGuerras ganhas: &7%{_WinsV}%||&fStatus: &7%{_OnlineV}%||&fÚltimo login: &7%{_LastDateV}%" to be unstealable
- add 1 to {_s}
- else:
- if file "plugins/Factions/faction-%arg 2%.yml" exists:
- open chest with 6 rows named "%{_Faction}% - Membros" to player
- format slot 11 of player with player head named "&7Vago" to be unstealable
- format slot 12 of player with player head named "&7Vago" to be unstealable
- format slot 13 of player with player head named "&7Vago" to be unstealable
- format slot 14 of player with player head named "&7Vago" to be unstealable
- format slot 15 of player with player head named "&7Vago" to be unstealable
- format slot 20 of player with player head named "&7Vago" to be unstealable
- format slot 21 of player with player head named "&7Vago" to be unstealable
- format slot 22 of player with player head named "&7Vago" to be unstealable
- format slot 23 of player with player head named "&7Vago" to be unstealable
- format slot 24 of player with player head named "&7Vago" to be unstealable
- format slot 29 of player with player head named "&7Vago" to be unstealable
- format slot 30 of player with player head named "&7Vago" to be unstealable
- format slot 31 of player with player head named "&7Vago" to be unstealable
- format slot 32 of player with player head named "&7Vago" to be unstealable
- format slot 33 of player with player head named "&7Vago" to be unstealable
- set {_s} to 11
- if {_s} is 15:
- set {_s} to 20
- if {_s} is 24:
- set {_s} to 29
- loop {FactionList::*}:
- set {_FactionTagL} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagL} is equal to arg 2:
- set {_IsOnlineV} to value "%loop-value%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionPowerV} to value "%loop-value%.FactionPower" get of "plugins/Factions/data.yml"
- set {_FactionV} to value "%loop-value%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value%.FactionRole" get of "plugins/Factions/data.yml"
- set {_FactionTagV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionMaxPowerV} to value "%loop-value%.FactionMaxPower" get of "plugins/Factions/data.yml"
- set {_LastDateV} to value "%loop-value%.LastDate" get of "plugins/Factions/data.yml"
- set {_AbatesV} to value "%loop-value%.Abates" get of "plugins/Factions/data.yml"
- set {_MortesV} to value "%loop-value%.Mortes" get of "plugins/Factions/data.yml"
- set {_WinsV} to value "%loop-value%.Wins" get of "plugins/Factions/data.yml"
- set {_AbatesV} to {_AbatesV} parsed as integer
- set {_MortesV} to {_MortesV} parsed as integer
- if loop-value have permission "default.group":
- set {_TagV} to "&7"
- if loop-value have permission "master.group":
- set {_TagV} to "&6[Master]"
- if loop-value have permission "gerente.group":
- set {_TagV} to "&4[Gerente]"
- if loop-value have permission "admin.group":
- set {_TagV} to "&c[Admin]"
- if loop-value have permission "moderador.group":
- set {_TagV} to "&2[Moderador]"
- if loop-value have permission "ajudante.group":
- set {_TagV} to "&e[Ajudante]"
- if loop-value have permission "supremo.group":
- set {_TagV} to "&4[Supremo]"
- if loop-value have permission "lendario.group":
- set {_TagV} to "&2[Lendário]"
- if loop-value have permission "heroi.group":
- set {_TagV} to "&5[Herói]"
- if loop-value have permission "campeao.group":
- set {_TagV} to "&3[Campeão]"
- if loop-value have permission "youtuber.group":
- set {_TagV} to "&c[YT]"
- if loop-value have permission "imperador.group":
- set {_TagV} to "&b[Imperador]"
- if {_FactionRoleV} is "LEADER":
- set {_RoleV} to "##Líder"
- if {_FactionRoleV} is "OFFICER":
- set {_RoleV} to "*Capitão"
- if {_FactionRoleV} is "MEMBER":
- set {_RoleV} to "+Membro"
- if {_FactionRoleV} is "RECRUIT":
- set {_RoleV} to "-Recruta"
- if {_IsOnlineV} is "Online":
- set {_OnlineV} to "&aOnline"
- if {_IsOnlineV} is "Offline":
- set {_OnlineV} to "&cOffline"
- format slot {_s} of player with skull of loop-value named "%{_TagV}% %loop-value%" with lore "&fPoder: &7%{_FactionPowerV}%/%{_FactionMaxPowerV}%||&fCargo: &7%{_RoleV}%||&fKDR: &70.0||&fAbates: &7%{_AbatesV}%||&fMortes: &7%{_MortesV}%||&fGuerras ganhas: &7%{_WinsA}%||&fStatus: &7%{_OnlineV}%||&fÚltimo login: &7%{_LastDateV}%" to be unstealable
- add 1 to {_s}
- else:
- send "&cEsta facção não existe."
- if arg 1 is "listar":
- loop all players:
- set {_FactionTagL} to value "%loop-player%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionL} to value "%loop-player%.Faction" get of "plugins/Factions/data.yml"
- loop {FactionList::*}:
- set {_FactionV} to value "%loop-value-2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionOnlineV} to value "%loop-value-2%.isOnline" get of "plugins/Factions/data.yml"
- if {_FactionV} is equal to {_FactionL}:
- if {_FactionOnlineV} is "Online":
- add 1 to {_maa}
- add 1 to {_ma}
- if {_FactionL} isn't "null":
- send " &eFacções Online - (1/1)"
- send " &a%{_FactionL}% &8- &7%{_FactionTagL}% &8- &f%{_maa}%/%{_ma}% &7online &8- &f0/0&7/0"
- else:
- send "&cNão há facções online no momento."
- stop
- if arg 1 is "perfil":
- if arg 2 is set:
- set {_NickNameA} to value "%arg 2%.NickName" get of "plugins/Factions/data.yml"
- set {_IsOnlineA} to value "%arg 2%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionPowerA} to value "%arg 2%.FactionPower" get of "plugins/Factions/data.yml"
- set {_FactionA} to value "%arg 2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRoleA} to value "%arg 2%.FactionRole" get of "plugins/Factions/data.yml"
- set {_FactionTagA} to value "%arg 2%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionMaxPowerA} to value "%arg 2%.FactionMaxPower" get of "plugins/Factions/data.yml"
- set {_Group} to value "%arg 2%.Group" get of "plugins/Factions/data.yml"
- set {_LastDateA} to value "%arg 2%.LastDate" get of "plugins/Factions/data.yml"
- set {_AbatesA} to value "%arg 2%.Abates" get of "plugins/Factions/data.yml"
- set {_MortesA} to value "%arg 2%.Mortes" get of "plugins/Factions/data.yml"
- set {_WinsA} to value "%arg 2%.Wins" get of "plugins/Factions/data.yml"
- set {_AbatesA} to {_AbatesA} parsed as integer
- set {_MortesA} to {_MortesA} parsed as integer
- if {_IsOnlineA} is "Online" or "Offline":
- send ""
- if {_Group} is "Default":
- set {_Tag} to ""
- if {_Group} is "Master":
- set {_Tag} to "&6[Master]"
- if {_Group} is "Gerente":
- set {_Tag} to "&4[Gerente]"
- if {_Group} is "Admin":
- set {_Tag} to "&c[Admin]"
- if {_Group} is "Moderador":
- set {_Tag} to "&2[Moderador]"
- if {_Group} is "Ajudante":
- set {_Tag} to "&e[Ajudante]"
- if {_Group} is "Youtuber":
- set {_Tag} to "&c[YT]"
- if {_Group} is "Imperador":
- set {_Tag} to "&b[Imperador]"
- if {_Group} is "Supremo":
- set {_Tag} to "&4[Supremo]"
- if {_Group} is "Lendario":
- set {_Tag} to "&2[Lendário]"
- if {_Group} is "Heroi":
- set {_Tag} to "&5[Herói]"
- if {_Group} is "Campeao":
- set {_Tag} to "&3[Campeão]"
- if {_Group} is "Default":
- set {_Tag} to ""
- if {_FactionRoleA} is "LEADER":
- set {_RoleAA} to "##"
- if {_FactionRoleA} is "OFFICER":
- set {_RoleAA} to "*"
- if {_FactionRoleA} is "MEMBER":
- set {_RoleAA} to "+"
- if {_FactionRoleA} is "RECRUIT":
- set {_RoleAA} to "-"
- if {_FactionRoleA} is "LEADER":
- set {_RoleA} to "##Líder"
- if {_FactionRoleA} is "OFFICER":
- set {_RoleA} to "*Capitão"
- if {_FactionRoleA} is "MEMBER":
- set {_RoleA} to "+Membro"
- if {_FactionRoleA} is "RECRUIT":
- set {_RoleA} to "-Recruta"
- if {_FactionA} is "null":
- send " %{_Tag}% &e%arg 2%"
- else:
- send " %{_Tag}% &e%{_FactionTagA}% %{_RoleAA}%%arg 2%"
- send ""
- send "&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%"
- if {_FactionA} is "null":
- send "&fFacção: &7Nenhuma"
- else:
- send "&fFacção: &7%{_FactionTagA}% - %{_FactionA}%"
- if {_FactionRoleA} is "null":
- send "&fCargo: &7Nenhum"
- else:
- send "&fCargo: &7%{_RoleA}%"
- send "&fKDR: &70.0"
- send "&fAbates: &7%{_AbatesA}%"
- send "&fMortes: &7%{_MortesA}%"
- send "&fGuerras ganhas: &7%{_WinsA}%"
- if {_isOnlineA} is "Online":
- send "&fStatus: &aOnline"
- if {_IsOnlineA} is "Offline":
- send "&fStatus: &cOffline"
- if {_Tag} is "" or "&3[Campeão]" or "&5[Herói]" or "&2[Lendário]" or "&4[Supremo]" or "&b[Imperador]":
- send "&fÚltimo login: &7%{_LastDateA}%"
- send ""
- else:
- send "&cEste usuário não existe."
- stop
- if arg 2 isn't set:
- send ""
- if player have permission "master.group":
- set {_Tag} to "&6[Master]"
- if player have permission "gerente.group":
- set {_Tag} to "&4[Gerente]"
- if player have permission "admin.group":
- set {_Tag} to "&c[Admin]"
- if player have permission "moderador.group":
- set {_Tag} to "&2[Moderador]"
- if player have permission "ajudante.group":
- set {_Tag} to "&e[Ajudante]"
- if player have permission "youtuber.group":
- set {_Tag} to "&c[YT]"
- if player have permission "imperador.group":
- set {_Tag} to "&b[Imperador]"
- if player have permission "supremo.group":
- set {_Tag} to "&4[Supremo]"
- if player have permission "lendario.group":
- set {_Tag} to "&2[Lendário]"
- if player have permission "heroi.group":
- set {_Tag} to "&5[Herói]"
- if player have permission "campeao.group":
- set {_Tag} to "&3[Campeão]"
- if player have permission "default.group":
- set {_Tag} to ""
- if {_FactionRole} is "LEADER":
- set {_Role} to "Líder"
- if {_FactionRole} is "OFFICER":
- set {_Role} to "Capitão"
- if {_FactionRole} is "MEMBER":
- set {_Role} to "Membro"
- if {_FactionRole} is "RECRUIT":
- set {_Role} to "Recruta"
- if {_FactionRole} is "LEADER":
- set {_RoleY} to "##"
- if {_FactionRole} is "OFFICER":
- set {_RoleY} to "*"
- if {_FactionRole} is "MEMBER":
- set {_RoleY} to "+"
- if {_FactionRole} is "RECRUIT":
- set {_RoleY} to "-"
- if {_Faction} is "null":
- send " %{_Tag}% &e%player%"
- else:
- send " %{_Tag}% &e%{_FactionTag}% %{_RoleY}%%player%"
- send ""
- send "&fPoder: &7%{_FactionPower}%/%{_FactionMaxPower}%"
- if {_Faction} is "null":
- send "&fFacção: &7Nenhuma"
- else:
- send "&fFacção: &7%{_FactionTag}% - %{_Faction}%"
- if {_FactionRole} is "null":
- send "&fCargo: &7Nenhum"
- else:
- send "&fCargo: &7%{_RoleY}%%{_Role}%"
- send "&fKDR: &70.0"
- send "&fAbates: &7%{_Abates}%"
- send "&fMortes: &7%{_Mortes}%"
- send "&fGuerras ganhas: &7%{_Wins}%"
- if {_isOnline} is "Online":
- send "&fStatus: &aOnline"
- if {_IsOnline} is "Offline":
- send "&fStauts: &cOffline"
- if {_Tag} is "" or "&3[Campeão]" or "&5[Herói]" or "&2[Lendário]" or "&4[Supremo]" or "&b[Imperador]":
- send "&fÚltimo login: &7%{_LastDate}%"
- send ""
- if arg 1 is "info":
- if arg 2 isn't set:
- if sender is console:
- send "&cUtilize /f info <facção=tag>."
- stop
- else:
- if {_Faction} is "null":
- send "&cOps! Aparentemente você não possui nenhuma facção!"
- stop
- else:
- send ""
- send " &e%{_FactionTag}% - %{_Faction}%"
- send "&2Terras/&4Poder&2/&4Poder máximo&2: &7"
- loop {FactionList::*}:
- set {_FactionFactionV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is equal to {_FactionTag}:
- if {_FactionRoleV} is "LEADER":
- set {_Leader} to loop-value
- send "&2Líder: &7%{_Leader}%"
- loop {FactionList::*}:
- set {_FactionFactionV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is {_FactionTag}:
- add 1 to {_m}
- loop all players:
- set {_FactionFactionL} to value "%loop-player%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionFactionL} is equal to {_FactionTag}:
- set {_FactionRoleL} to value "%loop-player%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionRoleL} is "LEADER":
- set {_mrole} to "##"
- if {_FactionRoleL} is "OFFICER":
- set {_mrole} to "*"
- if {_FactionRoleL} is "MEMBER":
- set {_mrole} to "+"
- if {_FactionRoleL} is "RECRUIT":
- set {_mrole} to "-"
- add 1 to {_mon}
- add "%{_mrole}%%loop-player%" to {_monl::*}
- send "&2Membros: &7%{_m}%"
- send "&2Membros online: &7%{_mon}%"
- send " &7%{_monl::*}%"
- send "&2Banco: &70"
- send "&2KDR: &70.0"
- send "&2Abates: &70"
- send "&2Mortes: &70"
- set {_FactionAlly} to value "Faction.Ally" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- if {_FactionAlly} is "null":
- send "&2Aliados: &7Nenhum"
- else:
- send "&2Aliados: &7%{_FactionAlly}%"
- set {_FactionEnemy} to value "Faction.Enemy" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- if {_FactionEnemy} is "null":
- send "&2Inimigos: &7Nenhum"
- else:
- send "&2Inimigos: &7%{_FactionEnemy}%"
- send "&eBatalhas:"
- set {_FactionWins} to value "Faction.Wins" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_FactionLoses} to value "Faction.Loses" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_FactionKills} to value "Faction.Kills" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_FactionDeaths} to value "Faction.Deaths" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- send " &2Vitórias: &7%{_FactionWins}%"
- send " &2Derrotas: &7%{_FactionLoses}%"
- send " &2Abates: &7%{_FactionKills}%"
- send " &2Mortes: &7%{_FactionDeaths}%"
- else:
- if file "plugins/Factions/faction-%arg 2%.yml" exists:
- loop {FactionList::*}:
- set {_FactionFactionV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionV} to value "%loop-value%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is equal to arg 2:
- if {_FactionRoleV} is "LEADER":
- set {_Leader} to loop-value
- set {_Tag} to "%{_FactionFactionV}%"
- set {_Name} to "%{_FactionV}%"
- send ""
- send " &e%{_Tag}% - %{_Name}%"
- send "&2Terras/&4Poder&2/&4Poder máximo&2: &7"
- send "&2Líder: &7%{_Leader}%"
- if {_FactionFactionV} is equal to arg 2:
- add 1 to {_m}
- loop all players:
- set {_FactionFactionL} to value "%loop-player%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionFactionL} is equal to arg 2:
- set {_FactionRoleL} to value "%loop-player%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionRoleL} is "LEADER":
- set {_mrole} to "##"
- if {_FactionRoleL} is "OFFICER":
- set {_mrole} to "*"
- if {_FactionRoleL} is "MEMBER":
- set {_mrole} to "+"
- if {_FactionRoleL} is "RECRUIT":
- set {_mrole} to "-"
- add 1 to {_mon}
- add "%{_mrole}%%loop-player%" to {_monll::*}
- send "&2Membros: &7%{_m}%"
- if {_mon} isn't set:
- send "&2Membros online: &70"
- else:
- set {_mensagem} to "%{_monll::*}%"
- replace "and " with " " in {_mensagem}
- replace ", " with " " in {_mensagem}
- send "&2Membros online: &7%{_mon}%"
- send " &7%{_mensagem}%"
- send "&2Banco: &70"
- send "&2KDR: &70.0"
- send "&2Abates: &70"
- send "&2Mortes: &70"
- set {_FactionAlly} to value "Faction.Ally" get of "plugins/Factions/faction-%arg 2%.yml"
- if {_FactionAlly} is "null":
- send "&2Aliados: &7Nenhum"
- else:
- send "&2Aliados: &7%{_FactionAlly}%"
- set {_FactionEnemy} to value "Faction.Enemy" get of "plugins/Factions/faction-%arg 2%.yml"
- if {_FactionEnemy} is "null":
- send "&2Inimigos: &7Nenhum"
- else:
- send "&2Inimigos: &7%{_FactionEnemy}%"
- send "&eBatalhas:"
- set {_FactionWins} to value "Faction.Wins" get of "plugins/Factions/faction-%arg 2%.yml"
- set {_FactionLoses} to value "Faction.Loses" get of "plugins/Factions/faction-%arg 2%.yml"
- set {_FactionKills} to value "Faction.Kills" get of "plugins/Factions/faction-%arg 2%.yml"
- set {_FactionDeaths} to value "Faction.Deaths" get of "plugins/Factions/faction-%arg 2%.yml"
- send " &2Vitórias: &7%{_FactionWins}%"
- send " &2Derrotas: &7%{_FactionLoses}%"
- send " &2Abates: &7%{_FactionKills}%"
- send " &2Mortes: &7%{_FactionDeaths}%"
- else:
- send "&cFacção não encontrada!"
- stop
- if arg 1 is "desfazer":
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- else:
- if arg 2 isn't set:
- if {_FactionRole} is "LEADER":
- open chest with 3 rows named "Confirmação" to player
- format slot 11 of player with light green wool named "&aAceitar (Leia abaixo)" with lore "&7Tem certeza que deseja terminar a facção %{_Faction}%?" to close then run [make player execute command "/f desfazer confirm"]
- format slot 15 of player with red wool named "&cNegar" with lore "&7Cancelar esta operação." to close
- if {_FactionRole} is "OFFICER" or "MEMBER" or "RECRUIT":
- send "&cVocê não tem permissão para executar este comando."
- if arg 2 is "confirm":
- delete yml nodes "Terras.%{_FactionTag}%" from file "plugins/Factions/claimdata.yml"
- send "&aA facção %{_Faction}% foi terminada com sucesso!"
- delete yml list "Geradores.%{_FactionTag}%" from file "plugins/Factions/geradoresdata.yml"
- remove {_FactionTag} from {FactionsList::*}
- remove {_Faction} from {FactionsNameList::*}
- delete file "plugins/Factions/faction-%{_FactionTag}%.yml"
- set "%player%.Faction" to "null" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionRole" to "null" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionTag" to "null" in yml file "plugins/Factions/data.yml"
- loop {FactionList::*}:
- set {_FactionTagL} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagL} is equal to {_FactionTag}:
- set "%loop-value%.Faction" to "null" in yml file "plugins/Factions/data.yml"
- set "%loop-value%.FactionRole" to "null" in yml file "plugins/Factions/data.yml"
- set "%loop-value%.FactionTag" to "null" in yml file "plugins/Factions/data.yml"
- if arg 1 is "criar":
- if arg 2 isn't set:
- send "&cUtilize /f criar <tag> <nome>"
- stop
- if arg 2 is set:
- if arg 3 isn't set:
- send "&cUtilize /f criar <tag> <nome>."
- stop
- if arg 3 is set:
- set {_Faction} to value "%player%.Faction" get of "plugins/Factions/data.yml"
- if {_Faction} isn't "null":
- send "&cVocê não tem permissão para usar este comando."
- stop
- else:
- set {_l} to length of the arg-2
- set {_l2} to length of the arg-3
- set {_Tag} to "%arg 2%"
- replace "a" with "A" in {_Tag}
- replace "b" with "B" in {_Tag}
- replace "c" with "C" in {_Tag}
- replace "d" with "D" in {_Tag}
- replace "e" with "E" in {_Tag}
- replace "f" with "F" in {_Tag}
- replace "g" with "G" in {_Tag}
- replace "h" with "H" in {_Tag}
- replace "i" with "I" in {_Tag}
- replace "j" with "J" in {_Tag}
- replace "k" with "K" in {_Tag}
- replace "l" with "L" in {_Tag}
- replace "m" with "M" in {_Tag}
- replace "n" with "N" in {_Tag}
- replace "o" with "O" in {_Tag}
- replace "p" with "P" in {_Tag}
- replace "q" with "Q" in {_Tag}
- replace "r" with "R" in {_Tag}
- replace "s" with "S" in {_Tag}
- replace "t" with "T" in {_Tag}
- replace "u" with "U" in {_Tag}
- replace "v" with "V" in {_Tag}
- replace "w" with "W" in {_Tag}
- replace "x" with "X" in {_Tag}
- replace "y" with "Y" in {_Tag}
- replace "z" with "Z" in {_Tag}
- if {_l} is more than 3:
- send "&cA tag da facção deve conter 3 caracteres."
- stop
- if {_l} is less than 3:
- send "&cA tag da facção deve conter 3 caracteres."
- stop
- if {_l2} is more than 20:
- send "&cO nome de sua facção deve conter de 5 a 20 caracteres."
- stop
- if {_l2} is less than 5:
- send "&cO nome de sua facção deve conter de 5 a 20 caracteres."
- stop
- loop {FactionsList::*}:
- if loop-value is "%arg 2%":
- send "&cOps! Já existe outra facção utilizando a tag ""%arg 2%""."
- stop
- loop {FactionsNameList::*}:
- if loop-value is "%arg 3%":
- send "&cJá existe outra facção utilizando o nome ""%arg 3%""."
- stop
- if arg-2 contain "a" or "b" or "c" or "d" or "e" or "f" or "g" or "h" or "i" or "j" or "k" or "l" or "m" or "n" or "o" or "p" or "q" or "r" or "s" or "t" or "u" or "v" or "w" or "x" or "y" or "z" or "1" or "2" or "3" or "4" or "5" or "6" or "7" or "8" or "9":
- if arg-3 contain "a" or "b" or "c" or "d" or "e" or "f" or "g" or "h" or "i" or "j" or "k" or "l" or "m" or "n" or "o" or "p" or "q" or "r" or "s" or "t" or "u" or "v" or "w" or "x" or "y" or "z" or "1" or "2" or "3" or "4" or "5" or "6" or "7" or "8" or "9":
- add "%{_Tag}%" to {FactionsList::*}
- add "%arg 3%" to {FactionsNameList::*}
- set "%player%.Faction" to "%arg 3%" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionRole" to "LEADER" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionTag" to "%{_Tag}%" in yml file "plugins/Factions/data.yml"
- create file "plugins/Factions/faction-%{_Tag}%.yml"
- set yml value "Geradores.%{_Tag}%" from file "plugins/Factions/geradoresdata.yml" to true
- add "FactionGeradores" to yml list "Geradores.%{_Tag}%" from file "plugins/Factions/geradoresdata.yml"
- set "Claims.Quantity" to "0" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Claims.Quantity" to "0" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "location.enabled" to "false" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Faction.Ally" to "null" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Faction.Neutral" to "null" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Faction.Enemy" to "null" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Faction.Wins" to "0" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Faction.Loses" to "0" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Faction.Kills" to "0" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "Faction.Deaths" to "0" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "location.x" to "%player's X coordinate%" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "location.y" to "%player's Y coordinate%" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- set "location.z" to "%player's Z coordinate%" in yml file "plugins/Factions/faction-%{_Tag}%.yml"
- send "&eYAY! Sua facção foi criada com sucesso!"
- else:
- send "&cO nome da facção não pode conter caracteres especiais."
- stop
- else:
- send "&cA tag da facção não pode conter caracteres especiais."
- stop
- if arg 1 is "expulsar":
- if arg 2 isn't set:
- send "&cUtilize /f expulsar <jogador>."
- stop
- else:
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- if {_FactionRole} is "LEADER" or "OFFICER":
- set {_NickNameA} to value "%arg 2%.NickName" get of "plugins/Factions/data.yml"
- set {_isOnlineA} to value "%arg 2%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionPowerA} to value "%arg 2%.FactionPower" get of "plugins/Factions/data.yml"
- set {_FactionA} to value "%arg 2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRoleA} to value "%arg 2%.FactionRole" get of "plugins/Factions/data.yml"
- set {_FactionTagA} to value "%arg 2%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionMaxPowerA} to value "%arg 2%.FactionMaxPower" get of "plugins/Factions/data.yml"
- set {_AbatesA} to value "%arg 2%.Mortes" get of "plugins/Factions/data.yml"
- set {_MortesA} to value "%arg 2%.Abates" get of "plugins/Factions/data.yml"
- if {_IsOnlineA} is "Online" or "Offline":
- if arg 2 is player:
- send "&cErrr.. Você não pode se auto-expulsar de sua facção!"
- stop
- if {_FactionA} is equal to {_Faction}:
- if {_FactionRoleA} is "LEADER":
- set {_RoleA} to "##Líder"
- if {_FactionRoleA} is "OFFICER":
- set {_RoleA} to "*Capitão"
- if {_FactionRoleA} is "MEMBER":
- set {_RoleA} to "+Membro"
- if {_FactionRoleA} is "RECRUIT":
- set {_RoleA} to "-Recruta"
- if {_FactionTagA} is equal to {_FactionTag}:
- open chest with 4 rows named "Confirmação" to player
- if {_isOnlineA} is "Online":
- set {_Status} to "&aOnline"
- if {_isOnlineA} is "Offline":
- set {_Status} to "&cOffline"
- format slot 13 of player with skull of player named "%arg 2%" with lore " ||&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%||&fCargo: &7%{_RoleA}%||&fKDR: &70.0||&fAbates: &7%{_AbatesA}%||&fMortes: &7%{_MortesA}%||&fStatus: &7%{_Status}%||&fÚltimo login: &7" to be unstealable
- format slot 20 of player with light green wool named "&aAceitar (leia abaixo)" with lore "&cDeseja remover %arg 2%?" to close then run [make player execute command "/f expulsar %arg 2% confirm"]
- format slot 24 of player with red wool named "&cNegar" to close
- if arg 3 is "confirm":
- set "%arg 2%.Faction" to "null" in yml file "plugins/Factions/data.yml"
- set "%arg 2%.FactionRole" to "null" in yml file "plugins/Factions/data.yml"
- set "%arg 2%.FactionTag" to "null" in yml file "plugins/Factions/data.yml"
- loop all players:
- if loop-player is arg 2:
- set {_Player} to loop-player
- send "&aO jogador ""%{_Player}%"" foi expulso de sua facção!"
- else:
- send "&cEsse jogador não faz parte da sua facção."
- stop
- else:
- send "&cEste usuário não existe."
- stop
- else:
- send "&cVocê não tem permissão para executar este comando."
- stop
- if arg 1 is "sair":
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- else:
- if {_FactionRole} is "LEADER":
- send "&cO líder da facção não pode abandoná-la. Caso queira deletá-la, utilize /f desfazer."
- stop
- if {_FactionRole} is "OFFICER" or "MEMBER" or "RECRUIT":
- if arg 2 isn't set:
- open chest with 3 rows named "Confirmação" to player
- format slot 11 of player with light green wool named "&aAceitar (Leia abaixo)" with lore "&7Tem certeza que deseja abandonar a facção %{_Faction}%?" to close then run [make player execute command "/f sair confirm"]
- format slot 15 of player with red wool named "&cNegar" with lore "&7Cancelar esta operação." to close
- if arg 2 is "confirm":
- loop all players:
- set {_FactionA} to value "%loop-player%.Faction" get of "plugins/Factions/data.yml"
- if {_FactionA} is equal to {_Faction}:
- send "&a%player% deixou de fazer parte de sua facção." to loop-player
- send "&aVocê abandonou a facção [%{_FactionTag}%] %{_Faction}%."
- set "%player%.Faction" to "null" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionRole" to "null" in yml file "plugins/Factions/data.yml"
- set "%player%.FactionTag" to "null" in yml file "plugins/Factions/data.yml"
- if arg 1 is "transferir":
- if arg 2 isn't set:
- send "&cUtilize /f transferir <jogador>."
- else:
- if arg 2 is player:
- send "&cVocê não pode alterar seu próprio cargo."
- stop
- set {_FactionA} to value "%arg 2%.Faction" get of "plugins/Factions/data.yml"
- set {_isOnlineA} to value "%arg 2%.isOnline" get of "plugins/Factions/data.yml"
- if {_IsOnlineA} is "Online" or "Offline":
- if {_FactionA} is equal to {_Faction}:
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- else:
- if {_FactionRole} is "LEADER":
- loop all players:
- if loop-player is arg 2:
- set {_NewLeader} to loop-player
- send "&aVocê transferiu a liderança da [%{_FactionTag}%] %{_Faction}% para %{_NewLeader}%."
- loop all players:
- set {_FactionL} to value "%loop-player%.Faction" get of "plugins/Factions/data.yml"
- if {_FactionL} is equal to {_Faction}:
- send "&aAgora o líder da facção é %arg 2% , deem parabéns a ele!" to loop-player
- set "%player%.FactionRole" to "RECRUIT" in yml file "plugins/Factions/data.yml"
- set "%arg 2%.FactionRole" to "LEADER" in yml file "plugins/Factions/data.yml"
- else:
- send "&cVocê não tem permissão para executar este comando."
- else:
- send "&cEste jogador não faz parte da sua facção."
- stop
- else:
- send "&cEste usuário não existe."
- stop
- if arg 1 is "rebaixar":
- if arg 2 isn't set:
- send "&cUtilize /f rebaixar <jogador>."
- else:
- if arg 2 is player:
- send "&cVocê não pode alterar seu próprio cargo."
- stop
- if {_FactionRole} is "LEADER" or "OFFICER":
- set {_FactionA} to value "%arg 2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRoleA} to value "%arg 2%.FactionRole" get of "plugins/Factions/data.yml"
- set {_isOnlineA} to value "%arg 2%.isOnline" get of "plugins/Factions/data.yml"
- if {_IsOnlineA} is "Online" or "Offline":
- if {_FactionA} is equal to {_Faction}:
- if {_FactionRole} is "LEADER":
- if {_FactionRoleA} is "RECRUIT":
- send "&cVocê não pode alterar o cargo desse jogador porque ele já é Recruta."
- send "&cUse /f expulsar <jogador> se deseja expulsá-lo de sua facção."
- stop
- if {_FactionRoleA} is "MEMBER":
- set "%arg 2%.FactionRole" to "RECRUIT" in yml file "plugins/Factions/data.yml"
- send "&aJogador rebaixado para Recruta."
- stop
- if {_FactionRoleA} is "OFFICER":
- set "%arg 2%.FactionRole" to "MEMBER" in yml file "plugins/Factions/data.yml"
- send "&aJogador rebaixado para Membro."
- stop
- if {_FactionRole} is "OFFICER":
- if {_FactionRoleA} is "RECRUIT":
- send "&cVocê não pode alterar o cargo desse jogador porque ele já é Recruta."
- send "&cUse /f expulsar <jogador> se deseja expulsa-lo de sua facção."
- stop
- if {_FactionRoleA} is "MEMBER":
- set "%arg 2%.FactionRole" to "RECRUIT" in yml file "plugins/Factions/data.yml"
- send "&aJogador rebaixado para Recruta."
- stop
- if {_FactionRoleA} is "OFFICER":
- send "&cO jogador possui cargo igual ou superior ao seu."
- stop
- else:
- send "&cEste jogador não existe ou não faz parte da sua facção."
- stop
- else:
- send "&cEste usuário não existe."
- if arg 1 is "promover":
- if arg 2 isn't set:
- send "&cUtilize /f promover <jogador>."
- else:
- if arg 2 is player:
- send "&cVocê não pode alterar seu próprio cargo."
- stop
- if {_FactionRole} is "LEADER" or "OFFICER":
- set {_FactionA} to value "%arg 2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRoleA} to value "%arg 2%.FactionRole" get of "plugins/Factions/data.yml"
- set {_isOnlineA} to value "%arg 2%.isOnline" get of "plugins/Factions/data.yml"
- if {_IsOnlineA} is "Online" or "Offline":
- if {_FactionA} is equal to {_Faction}:
- if {_FactionRole} is "LEADER":
- if {_FactionRoleA} is "RECRUIT":
- set "%arg 2%.FactionRole" to "MEMBER" in yml file "plugins/Factions/data.yml"
- send "&aJogador promovido a Membro da facção."
- loop all players:
- if loop-player is arg 2:
- send "&aVocê foi promovido a Membro da facção."
- stop
- if {_FactionRoleA} is "MEMBER":
- set "%arg 2%.FactionRole" to "OFFICER" in yml file "plugins/Factions/data.yml"
- send "&aJogador promovido a Capitão da facção."
- loop all players:
- if loop-player is arg 2:
- send "&aVocê foi promovido a Capitão da facção."
- stop
- if {_FactionRoleA} is "OFFICER":
- send "&cO cargo informado não pode ser igual ou superior ao seu."
- stop
- if {_FactionRole} is "OFFICER":
- if {_FactionRoleA} is "RECRUIT":
- set "%arg 2%.FactionRole" to "MEMBER" in yml file "plugins/Factions/data.yml"
- send "&aJogador promovido a Membro da facção."
- loop all players:
- if loop-player is arg 2:
- send "&aVocê foi promovido a Membro da facção."
- stop
- if {_FactionRoleA} is "MEMBER":
- send "&cO cargo informado não pode ser igual ou superior ao seu."
- stop
- if {_FactionRoleA} is "OFFICER":
- send "&cO jogador possui cargo igual ou superior ao seu."
- stop
- else:
- send "&cEste jogador não existe ou não faz parte da sua facção."
- stop
- else:
- send "&cEste usuário não existe."
- stop
- else:
- send "&cVocê não tem permissão para executar este comando."
- stop
- if arg 1 is "dominar":
- if world of player is "mine-1":
- stop
- if arg 2 is "warzone":
- if {_Admin} is "true":
- set "Terras.%chunk at player%" to "warzone" in yml file "plugins/Factions/claimdata.yml"
- send "&aVocê dominou esta terra com sucesso!"
- stop
- else:
- send "&cVocê não tem permissão para executar este comando."
- stop
- if arg 2 is "safezone":
- if {_Admin} is "true":
- set "Terras.%chunk at player%" to "safezone" in yml file "plugins/Factions/claimdata.yml"
- send "&aVocê dominou esta terra com sucesso!"
- stop
- else:
- send "&cVocê não tem permissão para executar este comando."
- stop
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- loop {FactionList::*}:
- set {_FactionTagV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagV} is equal to {_FactionTag}:
- set {_PoderV} to value "%loop-value%.FactionPower" get of "plugins/Factions/data.yml"
- set {_PoderV} to {_PoderV} parsed as integer
- add {_PoderV} to {_TotalPower}
- set {_FactionClaims} to value "Claims.Quantity" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_FactionClaims} to {_FactionClaims} parsed as integer
- if {_FactionClaims} is {_TotalPower}:
- send "&cSua facção não tem poder suficiente para dominar esta terra."
- stop
- #send "&cAs seguintes facções estão próximas: %{_ClaimA}%. Portanto não foi possível dominar esta terra."
- if {_Claim} is "safezone":
- send "&cVocê não pode dominar Zona Protegida"
- stop
- if {_Claim} is "warzone":
- send "&cVocê não pode dominar Zona de Guerra"
- stop
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- else:
- if {_Claim} is set:
- if {_Claim} isn't "%{_FactionTag}%":
- loop {FactionList::*}:
- set {_FactionTagV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionTagV} is equal to {_Claim}:
- set {_FactionV} to value "%loop-value%.Faction" get of "plugins/Factions/data.yml"
- send "&eOps! A facção &e[%{_Claim}%] %{_FactionV}% possui poder suficiente para manter esta terra."
- stop
- if {_Claim} is "%{_FactionTag}%":
- send "&aEsta terra já está dominada por sua facção!"
- stop
- if {_FactionRole} is "OFFICER" or "LEADER":
- set "Terras.%chunk at player%" to "%{_FactionTag}%" in yml file "plugins/Factions/claimdata.yml"
- set {_FactionClaims} to value "Claims.Quantity" get of "plugins/Factions/faction-%{_Claim}%.yml"
- set {_FactionClaims} to {_FactionClaims} parsed as integer
- add 1 to {_FactionClaims}
- set "Claims.Quantity" to "%{_FactionClaims}%" in yml file "plugins/Factions/faction-%{_Claim}%.yml"
- send "&aVocê dominou esta terra com sucesso!"
- if {_FactionRole} is "MEMBER" or "RECRUIT":
- send "&cVocê não tem permissão para executar este comando."
- stop
- if arg 1 is "proteger":
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- else:
- if arg 2 isn't set:
- if {_Claim} is "%{_FactionTag}%":
- send "&aVocê só pode dominar terrenos livres"
- stop
- if {_Claim} is set:
- if {_Claim} isn't "%{_FactionTag}%":
- send "&aVocê só pode dominar terrenos livres"
- stop
- else:
- open chest with 4 rows named "Confirmação" to player
- format slot 13 of player with grass named "Deseja proteger este terreno?" to be unstealable
- format slot 20 of player with light green wool named "&aAceitar (leia abaixo)" with lore "&cSerá cobrado 20.000 coins de você." to close then run [make player execute command "/f proteger confirm"]
- format slot 24 of player with red wool named "&cNegar" to close then run [make player execute command "/f proteger cancel"]
- if arg 2 is "cancel":
- play "VILLAGER_NO" to player at volume 0.2
- send "&cTentativa de proteção cancelada"
- if arg 2 is "confirm":
- set {_x} to player's x-coordinate
- set {_y} to player's y-coordinate
- set {_z} to player's z-coordinate
- set {_loc.x} to {_x} parsed as number
- set {_loc.y} to {_y} parsed as number
- set {_loc.z} to {_z} parsed as number
- set {_location} to location ({_loc.x}, {_loc.y}, {_loc.z})
- if {_FactionRole} is "OFFICER" or "LEADER":
- if {_Claim} is "%{_FactionTag}%":
- send "&aVocê só pode dominar terrenos livres"
- stop
- if {_Claim} is set:
- if {_Claim} isn't "%{_FactionTag}%":
- send "&aVocê só pode dominar terrenos livres"
- stop
- if {_Claim} isn't set:
- #http://prntscr.com/hjhvmt
- if player's money >= 20000:
- set "Terras.%chunk at {_location}%" to "%{_FactionTag}%-PROTECTION" in yml file "plugins/Factions/claimdata.yml"
- set "TerrasProtegidas.%chunk at {_location}%" to "%{_location}%" in yml file "plugins/Factions/claimdata.yml"
- set "TerrasProtegidasTimeSeconds.%chunk at {_location}%" to "60" in yml file "plugins/Factions/claimdata.yml"
- set "TerrasProtegidasTimeMinutes.%chunk at {_location}%" to "30" in yml file "plugins/Factions/claimdata.yml"
- set {_ClaimA} to chunk at player
- send "&aVocê protegeu esta terra com sucesso!"
- remove 20000 from player's money
- wait 30 minutes
- delete yml nodes "Terras.%chunk at {_location}%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidas.%chunk at {_location}%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidasTimeSeconds.%chunk at {_location}%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidasTimeMinutes.%chunk at {_location}%" from file "plugins/Factions/claimdata.yml"
- else:
- send "&cSaldo insuficiente para proteger este terreno."
- stop
- if {_FactionRole} is "MEMBER" or "RECRUIT":
- send "&cVocê não tem permissão para executar este comando."
- stop
- if arg 1 is "geradores":
- set {_Geradores::*} to value list "Geradores.%{_FactionTag}%" get of "plugins/Factions/geradoresdata.yml"
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- else:
- if arg 2 isn't set:
- if {_FactionRole} is "LEADER" or "OFFICER" or "MEMBER" or "RECRUIT":
- open chest with 6 rows named "[%{_FactionTag}%] Geradores" to player
- format slot 13 of player with empty map named "&aInformações" with lore " ||&fQuantidade atual de geradores: &7|| " to be unstealable
- set {_s} to 28
- loop {_Geradores::*}:
- if loop-value is "FactionGeradores":
- stop
- set {_quantidade::*} to loop-value split at "-"
- set {_quantidadespawners} to {_quantidade::2}
- if loop-value is "Zombie-%{_quantidadespawners}%":
- set {_Name} to "Zumbi"
- set {_NameHead} to "Zombie"
- if loop-value is "MHF_Cow-%{_quantidadespawners}%":
- set {_Name} to "Vaca"
- set {_NameHead} to "MHF_Cow"
- if loop-value is "MHF_Chicken-%{_quantidadespawners}%":
- set {_Name} to "Galinha"
- set {_NameHead} to "MHF_Chicken"
- if loop-value is "MHF_Spider-%{_quantidadespawners}%":
- set {_Name} to "Aranha"
- set {_NameHead} to "MHF_Spider"
- if loop-value is "MHF_Skeleton-%{_quantidadespawners}%":
- set {_Name} to "Esqueleto"
- set {_NameHead} to "MHF_Skeleton"
- if loop-value is "MHF_Slime-%{_quantidadespawners}%":
- set {_Name} to "Slime"
- set {_NameHead} to "MHF_Slime"
- if loop-value is "MHF_Blaze-%{_quantidadespawners}%":
- set {_Name} to "Blaze"
- set {_NameHead} to "MHF_Blaze"
- if loop-value is "MHF_PigZombie-%{_quantidadespawners}%":
- set {_Name} to "Porco Zumbi"
- set {_NameHead} to "MHF_PigZombie"
- if loop-value is "MHF_LavaSlime-%{_quantidadespawners}%":
- set {_Name} to "Cubo de Magma"
- set {_NameHead} to "MHF_LavaSlime"
- if loop-value is "MHF_Golem-%{_quantidadespawners}%":
- set {_Name} to "Golem de Ferro"
- set {_NameHead} to "MHF_Golem"
- if loop-value is "Whiter-%{_quantidadespawners}%":
- set {_Name} to "Whiter"
- set {_NameHead} to "MHF_WSkeleton"
- format slot {_s} of player with skull of ("%{_NameHead}%" parsed as an offline player) named "&e%{_quantidadespawners}% Gerador de %{_name}%." with lore "&fBotão esquerdo: &7Coletar gerador." to be unstealable
- if {_s} is 34:
- set {_s} to 36
- add 1 to {_s}
- if arg 1 is "relacao":
- if arg 2 isn't set:
- send "&cUtilize /f relacao <facção>."
- else:
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- if arg 2 is "%{_FactionTag}%" or "%{_Faction}%":
- send "&cNão é possível definir uma relação com a sua própria facção."
- stop
- loop {FactionsList::*}:
- if loop-value is "%arg 2%":
- if arg 3 isn't set:
- open chest with 3 rows named "Relações - %{_FactionTag}% » %arg 2%" to player
- format slot 11 of player with leather chestplate coloured blue named "&aAliada" to run [make player execute command "/f relacao %arg 2% ally"]
- format slot 13 of player with leather chestplate coloured white named "&fNeutra" to run [make player execute command "/f relacao %arg 2% neutral"]
- format slot 15 of player with leather chestplate coloured red named "&cInimiga" to run [make player execute command "/f relacao %arg 2% enemy"]
- stop
- if arg 3 is "enemy":
- loop {FactionList::*}:
- set {_FactionV} to value "%loop-value-2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionFactionV} to value "%loop-value-2%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value-2%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is equal to arg 2:
- if {_FactionRoleV} is "LEADER":
- set {_FactionVV} to {_FactionV}
- send "&aAgora a facção %{_FactionVV}% é Inimiga."
- stop
- if arg 3 is "neutral":
- loop {FactionList::*}:
- set {_FactionV} to value "%loop-value-2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionFactionV} to value "%loop-value-2%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value-2%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is equal to arg 2:
- if {_FactionRoleV} is "LEADER":
- set {_Leader} to loop-value-2
- set {_FactionVV} to {_FactionV}
- set {_isOnlineV} to value "%loop-value-2%.isOnline" get of "plugins/Factions/data.yml"
- if {_isOnlineV} is "Online":
- #agora a facção fac é Aliada.
- send "&aVocê recebeu uma proposta de 'Neutro' da facção %{_Faction}% digite '/f menu' para mais informações." to {_Leader}
- send "&aUm pedido de 'Neutro' foi enviado para %{_FactionVV}%"
- stop
- else:
- send "&cO lider da facção %{_FactionVV}% precisa estar online para aceitar este pedido."
- stop
- if arg 3 is "ally":
- loop {FactionList::*}:
- set {_FactionV} to value "%loop-value-2%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionFactionV} to value "%loop-value-2%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value-2%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is equal to arg 2:
- if {_FactionRoleV} is "LEADER":
- set {_Leader} to loop-value-2
- set {_FactionVV} to {_FactionV}
- set {_isOnlineV} to value "%loop-value-2%.isOnline" get of "plugins/Factions/data.yml"
- if {_isOnlineV} is "Online":
- send "&aVocê recebeu uma proposta de 'Aliada' da facção %{_Faction}% digite '/f menu' para mais informações." to {_Leader}
- send "&aUm pedido de 'Aliada' foi enviado para %{_FactionVV}%"
- stop
- else:
- send "&cO lider da facção %{_FactionVV}% precisa estar online para aceitar este pedido."
- stop
- else:
- send "&c%arg 2% não é uma facção existente."
- stop
- if arg 1 is "admin":
- if sender is console:
- send "&cVocê já está no modo desenvolvedor."
- stop
- else:
- if player have permission "faction.admin":
- if {_Admin} is "false":
- set "%player%.Admin" to "true" in yml file "plugins/Factions/data.yml"
- send "&aModo admin ligado."
- stop
- if {_Admin} is "true":
- set "%player%.Admin" to "false" in yml file "plugins/Factions/data.yml"
- send "&cModo admin desligado."
- stop
- else:
- send "&cVocê não tem permissão para usar este comando."
- if arg 1 is "abandonar":
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- if {_Faction} is "null":
- send "&cVocê não tem permissão para executar este comando."
- stop
- else:
- if arg 2 isn't set:
- if {_Claim} is "safezone":
- send "&eEsta terra não pertence a você."
- stop
- if {_Claim} is "warzone":
- send "&eEsta terra não pertence a você."
- stop
- if {_Claim} isn't set:
- send "&eEsta terra não pertence a você."
- stop
- if {_Claim} is set:
- if {_Claim} isn't "%{_FactionTag}%" or "%{_FactionTag}%-PROTECTION":
- send "&eEsta terra não pertence a você."
- stop
- if {_Claim} is set:
- if {_Claim} is "%{_FactionTag}%" or "%{_FactionTag}%-PROTECTION":
- open chest with 4 rows named "Confirmação" to player
- format slot 13 of player with grass named "Deseja abandonar a terra?" to be unstealable
- format slot 20 of player with light green wool named "&aAceitar (leia abaixo)" to close then run [make player execute command "/f abandonar confirm"]
- format slot 24 of player with red wool named "&cNegar" with lore "&7Cancelar esta operação" to close then run [make player execute command "/f abandonar cancel"]
- if arg 2 is "cancel":
- play "VILLAGER_NO" to player at volume 0.2
- if arg 2 is "todas":
- send "&cEste comando está desabilitado temporariamente."
- stop
- if arg 2 is "confirm":
- if {_Admin} is "true":
- if {_Claim} isn't set:
- send "&cA seguinte facção tem imunidade."
- stop
- else:
- send "&aA facção %{_Claim}% perdeu esta terra."
- set {_FactionClaims} to value "Claims.Quantity" get of "plugins/Factions/faction-%{_Claim}%.yml"
- set {_FactionClaims} to {_FactionClaims} parsed as integer
- remove 1 from {_FactionClaims}
- set "Claims.Quantity" to "%{_FactionClaims}%" in yaml file "plugins/Factions/faction-%{_Claim}%.yml"
- delete yml nodes "Terras.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidas.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidasTimeSeconds.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidasTimeMinutes.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- stop
- if {_FactionRole} is "OFFICER" or "LEADER":
- if {_Claim} is "%{_FactionTag}%" or "%{_FactionTag}%-PROTECTION":
- send "&aTerra perdida com sucesso."
- set {_FactionClaims} to value "Claims.Quantity" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_FactionClaims} to {_FactionClaims} parsed as integer
- remove 1 from {_FactionClaims}
- set "Claims.Quantity" to "%{_FactionClaims}%" in yaml file "plugins/Factions/faction-%{_FactionTag}%.yml"
- delete yml nodes "Terras.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidas.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidasTimeSeconds.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- delete yml nodes "TerrasProtegidasTimeMinutes.%chunk at player%" from file "plugins/Factions/claimdata.yml"
- stop
- if {_FactionRole} is "MEMBER" or "RECRUIT":
- send "&cVocê não tem permissão para executar este comando."
- stop
- else:
- if arg 2 isn't "todas":
- send "&a/f abandonar &8- &7Abandonar a terra atual."
- send "&a/f abandonar todas &8- &7Abandona todas as terras da sua facção."
- stop
- if arg 1 is "mapa":
- send ""
- set {_mapX} to 9
- set {_mapY} to 9
- set {_m} to ""
- loop 19 times:
- loop 19 times:
- set {_x} to {_mapX} * 16
- set {_y} to {_mapY} * 16
- set {_chunk} to chunk at block {_y} blocks north {_x} blocks west of player
- set {_Claim} to value "Terras.%{_chunk}%" get of "plugins/Factions/claimdata.yml"
- if {_Claim} isn't set:
- set {_result} to ""
- else:
- set {_result} to "%{_Claim}%"
- if {_chunk} is chunk at player:
- set {_m} to "%{_m}%&e█"
- else if {_result} is {_FactionTag}:
- set {_m} to "%{_m}%&8█"
- else if {_result} is "":
- set {_m} to "%{_m}%&7█"
- else if {_result} is "warzone":
- set {_m} to "%{_m}%&4█"
- else if {_result} is "safezone":
- set {_m} to "%{_m}%&6█"
- else:
- set {_m} to "%{_m}%&f█"
- add -1 to {_mapX}
- send "&l%{_m}%" to player
- set {_m} to ""
- add -1 to {_mapY}
- set {_mapX} to 9
- if arg 1 is "voar":
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- if player have permission "claim.fly":
- if {_FactionTag} isn't "null":
- if {_Claim} is "%{_FactionTag}%":
- if player's fly mode is false:
- set player's fly mode to true
- send "&aModo de voo ativado dentro das suas terras."
- stop
- if player's fly mode is true:
- set player's fly mode to false
- send "&aModo de voo desativado dentro das suas terras."
- stop
- else:
- send "&cVocê precisa estar no terreno de sua facção."
- else:
- send "&cOps! Você precisa ter uma facção para poder voar em seu terreno de sua facção."
- stop
- else:
- send "&cVocê precisa do grupo &2Lendário &cou superior para executar este comando."
- if arg 1 is "ajuda":
- send ""
- send "&2Comandos disponíveis:"
- send ""
- if player have permission "faction.admin":
- send "&a/f admin &8- &7Modo admin."
- send "&a/f aceitar convite <tag> &8- &7Utilize para aceitar convites de facções!"
- send "&a/f convites &8- &7Utilize para ver seus convites de facção."
- send "&a/f criar <tag> <nome> &8- &7Crie sua própria facção."
- send "&a/f geradores &8- &7Utilize para ver o geradores da sua facção."
- send "&a/f info <tag> &8- &7Utilize para ver informações sobre uma facção."
- send "&a/f listar &8- &7Utilize para ver todas as facções online."
- send "&a/f mapa &8- &7Utilize para ver o mapa."
- send "&a/f membros <tag> &8- &7Utilize para listar membros de uma facção."
- send "&a/f perfil <jogador> &8- &7Mostrar as informações de um jogador."
- send "&a/f verterras &8- &7Mostrar delimitações das terras."
- if {_FactionRole} is "LEADER":
- send "&a/f desfazer &8- &7Utilize para terminar sua facção."
- if {_FactionRole} is "LEADER" or "OFFICER":
- send "&a/f convidar <jogador> &8- &7Utilize para enviar convites de facções."
- send "&a/f dominar &8- &7Utilize para dominar uma terra."
- send "&a/f expulsar <jogador> &8- &7Utilize para expulsar membros de sua facção."
- send "&a/f promover <jogador> &8- &7Promove o jogador de cargo."
- send "&a/f proteger &8- &7Utilize para proteger um terreno temporariamente."
- send "&a/f rebaixar <jogador> &8- &7Demover um jogador."
- send "&a/f relacao <facção> &8- &7Gerenciar relação com outras facções."
- send "&a/f sair &8- &7Utilize para abandonar sua facção."
- send "&a/f transferir <jogador> &8- &7Transfere a liderança da facção para outro jogador."
- if {_FactionTag} isn't "null":
- send "&a/f voar &8- &7Habilite ou desabilite voar nos seus terrenos."
- if arg 1 isn't "voar" or "base" or "convidarmenugui1177" or "aceitar" or "admin" or "convites" or "criar" or "info" or "listar" or "mapa" or "membros" or "perfil" or "verterras" or "desfazer" or "convidar" or "dominar" or "expulsar" or "promover" or "proteger" or "rebaixar" or "relacao" or "sair" or "transferir" or "abandonar" or "ajuda":
- if sender is console:
- send "&cNão há esta opção na versão de desenvolvedor, utilize /f ajuda."
- else:
- set {_Claim} to value "Terras.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- set {_Owner} to value "TerrasProtegidas.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- set {_Seconds} to value "TerrasProtegidasTimeSeconds.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- set {_Minutes} to value "TerrasProtegidasTimeMinutes.%chunk at player%" get of "plugins/Factions/claimdata.yml"
- set {_GroupA} to value "%arg 1%.Group" get of "plugins/Factions/data.yml"
- if player have permission "master.group":
- set {_Tag} to "&6[Master] "
- if player have permission "gerente.group":
- set {_Tag} to "&4[Gerente] "
- if player have permission "admin.group":
- set {_Tag} to "&c[Admin] "
- if player have permission "moderador.group":
- set {_Tag} to "&2[Moderador] "
- if player have permission "ajudante.group":
- set {_Tag} to "&e[Ajudante] "
- if player have permission "imperador.group":
- set {_Tag} to "&b[Imperador] "
- if player have permission "supremo.group":
- set {_Tag} to "&4[Supremo] "
- if player have permission "lendario.group":
- set {_Tag} to "&2[Lendário] "
- if player have permission "heroi.group":
- set {_Tag} to "&5[Herói] "
- if player have permission "campeao.group":
- set {_Tag} to "&3[Campeão] "
- if player have permission "default.group":
- set {_Tag} to "&7"
- if {_GroupA} is "Master":
- set {_TagA} to "&6[Master] "
- if {_GroupA} is "Gerente":
- set {_TagA} to "&4[Gerente] "
- if {_GroupA} is "Admin":
- set {_TagA} to "&c[Admin] "
- if {_GroupA} is "Moderador":
- set {_TagA} to "&2[Moderador] "
- if {_GroupA} is "Ajudante":
- set {_TagA} to "&e[Ajudante] "
- if {_GroupA} is "Youtuber":
- set {_TagA} to "&c[YT] "
- if {_GroupA} is "Imperador":
- set {_TagA} to "&b[Imperador] "
- if {_GroupA} is "Supremo":
- set {_TagA} to "&4[Supremo] "
- if {_GroupA} is "Lendario":
- set {_TagA} to "&2[Lendário] "
- if {_GroupA} is "Heroi":
- set {_TagA} to "&5[Herói] "
- if {_GroupA} is "Campeao":
- set {_TagA} to "&3[Campeão] "
- if {_GroupA} is "Default":
- set {_TagA} to "&7"
- set {_AdminA} to value "%arg 1%.Admin" get of "plugins/Factions/data.yml"
- set {_IsOnlineA} to value "%arg 1%.isOnline" get of "plugins/Factions/data.yml"
- set {_FactionPowerA} to value "%arg 1%.FactionPower" get of "plugins/Factions/data.yml"
- set {_FactionA} to value "%arg 1%.Faction" get of "plugins/Factions/data.yml"
- set {_FactionRoleA} to value "%arg 1%.FactionRole" get of "plugins/Factions/data.yml"
- set {_FactionTagA} to value "%arg 1%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionMaxPowerA} to value "%arg 1%.FactionMaxPower" get of "plugins/Factions/data.yml"
- set {_LastDateA} to value "%arg 1%.LastDate" get of "plugins/Factions/data.yml"
- set {_AbatesA} to value "%arg 1%.Abates" get of "plugins/Factions/data.yml"
- set {_MortesA} to value "%arg 1%.Mortes" get of "plugins/Factions/data.yml"
- set {_WinsA} to value "%arg 1%.Wins" get of "plugins/Factions/data.yml"
- if {_FactionRole} is "LEADER":
- set {_Role} to "##Líder"
- if {_FactionRole} is "OFFICER":
- set {_Role} to "*Capitão"
- if {_FactionRole} is "MEMBER":
- set {_Role} to "+Membro"
- if {_FactionRole} is "RECRUIT":
- set {_Role} to "-Recruta"
- if {_FactionRoleA} is "LEADER":
- set {_RoleA} to "##Líder"
- if {_FactionRoleA} is "OFFICER":
- set {_RoleA} to "*Capitão"
- if {_FactionRoleA} is "MEMBER":
- set {_RoleA} to "+Membro"
- if {_FactionRoleA} is "RECRUIT":
- set {_RoleA} to "-Recruta"
- if {_FactionRole} is "null":
- set {_Role} to "Nenhum"
- if {_FactionRoleA} is "null":
- set {_RoleA} to "Nenhum"
- if {_IsOnline} is "Online":
- set {_Status} to "&aOnline"
- if {_IsOnline} is "Offline":
- set {_Status} to "&cOffline"
- if {_IsOnlineA} is "Offline":
- set {_StatusA} to "&cOffline"
- if {_IsOnlineA} is "Online":
- set {_StatusA} to "&aOnline"
- if {_Claim} isn't set:
- set {_Claim} to "Zona Livre"
- if {_Claim} is "warzone":
- set {_Claim} to "Zona de Guerra"
- if {_Claim} is "safezone":
- set {_Claim} to "Zona Protegida"
- if {_Claim} is "%{_FactionTag}%-PROTECTION":
- set {_Claim} to "PROTECTION"
- if {_IsOnlineA} is "Online" or "Offline":
- if {_FactionTagA} is "null":
- open chest with 5 rows named "%arg 1%" to player
- else:
- open chest with 5 rows named "[%{_FactionTagA}%] %arg 1%" to player
- if {_FactionTag} is "null":
- if player have permission "master.group" or "gerente.group" or "admin.group" or "moderador.group":
- format slot 12 of player with skull of ("%player%" parsed as an offline player) named "%{_Tag}%%player%" with lore "&fPoder: &7%{_FactionPower}%/%{_FactionMaxPower}%||&fCargo: &7%{_Role}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fMortes: &7%{_Mortes}%||&fGuerras ganhas: &7%{_Wins}%||&fStatus: &7%{_Status}%" to be unstealable
- else:
- format slot 12 of player with skull of ("%player%" parsed as an offline player) named "%{_Tag}%%player%" with lore "&fPoder: &7%{_FactionPower}%/%{_FactionMaxPower}%||&fCargo: &7%{_Role}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fMortes: &7%{_Mortes}%||&fGuerras ganhas: &7%{_Wins}%||&fStatus: &7%{_Status}%||&fÚltimo login: &7%{_LastDate}%" to be unstealable
- if {_Claim} is "Zona Livre":
- format slot 14 of player with a dirt named "&aTerreno da %{_Claim}%" to be unstealable
- if {_Claim} is "PROTECTION":
- format slot 14 of player with a dirt:2 named "&aTerreno da sua facção" with lore "&fBotão esquerdo: &7Abandonar||&fProtegida por: &7%{_Owner}%||&7A proteção acaba em %{_Minutes}%m %{_Seconds}%sec" to close then run [make player execute command "f abandonar confirm"]
- if {_Claim} is "%{_FactionTag}%":
- format slot 14 of player with a grass named "&aTerreno da sua facção" with lore "&fBotão esquerdo: &7Abandonar" to close then run [make player execute command "f abandonar confirm"]
- if {_Claim} is set:
- if {_Claim} isn't "%{_FactionTag}%":
- if {_Claim} isn't "Zona Livre":
- if {_Claim} isn't "PROTECTION":
- format slot 14 of player with a grass named "&aTerreno da %{_Claim}%" to be unstealable
- else:
- loop {FactionList::*}:
- set {_FactionFactionV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is equal to {_FactionTag}:
- if {_FactionRoleV} is "LEADER":
- set {_Leader} to loop-value
- loop {FactionList::*}:
- set {_FactionFactionV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is {_FactionTag}:
- add 1 to {_m}
- loop all players:
- set {_FactionFactionL} to value "%loop-player%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionFactionL} is equal to {_FactionTag}:
- set {_FactionRoleL} to value "%loop-player%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionRoleL} is "LEADER":
- set {_mrole} to "##"
- if {_FactionRoleL} is "OFFICER":
- set {_mrole} to "*"
- if {_FactionRoleL} is "MEMBER":
- set {_mrole} to "+"
- if {_FactionRoleL} is "RECRUIT":
- set {_mrole} to "-"
- add 1 to {_mon}
- add "%{_mrole}%%loop-player%" to {_monl::*}
- set {_FactionAlly} to value "Faction.Ally" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- set {_FactionEnemy} to value "Faction.Enemy" get of "plugins/Factions/faction-%{_FactionTag}%.yml"
- if {_FactionAlly} is "null":
- set {_FactionAllyY} to "Nenhum"
- if {_FactionEnemy} is "null":
- set {_FactionEnemyY} to "Nenhum"
- if player have permission "master.group" or "gerente.group" or "admin.group" or "moderador.group":
- format slot 11 of player with skull of ("%player%" parsed as an offline player) named "%{_Tag}%%player%" with lore "&fPoder: &7%{_FactionPower}%/%{_FactionMaxPower}%||&fCargo: &7%{_Role}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fMortes: &7%{_Mortes}%||&fGuerras ganhas: &7%{_Wins}%||&fStatus: &7%{_Status}%" to be unstealable
- else:
- format slot 11 of player with skull of ("%player%" parsed as an offline player) named "%{_Tag}%%player%" with lore "&fPoder: &7%{_FactionPower}%/%{_FactionMaxPower}%||&fCargo: &7%{_Role}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fMortes: &7%{_Mortes}%||&fGuerras ganhas: &7%{_Wins}%||&fStatus: &7%{_Status}%||&fÚltimo login: &7%{_LastDate}%" to be unstealable
- format slot 13 of player with white named "&e%{_FactionTag}% - %{_Faction}%" with lore "&fTerras: &70||&fPoder: &75||&fPoder máximo: &75||&fLíder: &7[%{_FactionTag}%] &f%{_Leader}%||&fMembros: &7%{_m}%/15||&fMembros online: &7%{_monl::*}%||&fKDR: &70.0||&fAbates: &70||&fMortes: &70||&fAliados: &7%{_FactionAllyY}%||&fInimigos: &7%{_FactionEnemyY}%" to be unstealable
- if {_Claim} is "Zona Livre":
- format slot 15 of player with a dirt named "&aTerreno da %{_Claim}%" to be unstealable
- if {_Claim} is "PROTECTION":
- format slot 15 of player with a dirt:2 named "&aTerreno da sua facção" with lore "&fBotão esquerdo: &7Abandonar||&fProtegida por: &7%{_Owner}%||&7A proteção acaba em %{_Minutes}%m %{_Seconds}%sec" to close then run [make player execute command "f abandonar confirm"]
- if {_Claim} is "%{_FactionTag}%":
- format slot 15 of player with a grass named "&aTerreno da sua facção" with lore "&fBotão esquerdo: &7Abandonar" to close then run [make player execute command "f abandonar confirm"]
- if {_Claim} is set:
- if {_Claim} isn't "%{_FactionTag}%":
- if {_Claim} isn't "Zona Livre":
- if {_Claim} isn't "PROTECTION":
- format slot 15 of player with a grass named "&aTerreno da %{_Claim}%" to be unstealable
- if {_FactionTagA} is "null":
- if {_FactionRole} is "LEADER" or "OFFICER":
- if {_TagA} is "&6[Master] " or "&4[Gerente] " or "&c[Admin] " or "&2[Moderador] ":
- format slot 30 of player with skull of ("%arg 1%" parsed as an offline player) named "%{_TagA}%%arg 1%" with lore "&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%||&fCargo: &7%{_RoleA}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fGuerras ganhas: &7%{_WinsA}%||&fMortes: &7%{_Mortes}%||&fStatus: &7%{_StatusA}%" to be unstealable
- else:
- format slot 30 of player with skull of ("%arg 1%" parsed as an offline player) named "%{_TagA}%%arg 1%" with lore "&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%||&fCargo: &7%{_RoleA}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fGuerras ganhas: &7%{_WinsA}%||&fMortes: &7%{_Mortes}%||&fStatus: &7%{_StatusA}%" to be unstealable
- format slot 32 of player with paper named "&aConvidar" with lore "&7Convidar para entrar na facção." to run [make player execute command "f convidarmenugui1177 %arg 1%"]
- else:
- if {_TagA} is "&6[Master] " or "&4[Gerente] " or "&c[Admin] " or "&2[Moderador] ":
- format slot 31 of player with skull of ("%arg 1%" parsed as an offline player) named "%{_TagA}%%arg 1%" with lore "&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%||&fCargo: &7%{_RoleA}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fGuerras ganhas: &7%{_WinsA}%||&fMortes: &7%{_Mortes}%||&fStatus: &7%{_StatusA}%" to be unstealable
- else:
- format slot 31 of player with skull of ("%arg 1%" parsed as an offline player) named "%{_TagA}%%arg 1%" with lore "&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%||&fCargo: &7%{_RoleA}%||&fKDR: &70.0||&fAbates: &7%{_Abates}%||&fMortes: &7%{_Mortes}%||&fStatus: &7%{_StatusA}%||&fÚltimo login: &7%{_LastDateA}%" to be unstealable
- else:
- set {_TagV} to value "%arg 1%.FactionTag" get of "plugins/Factions/data.yml"
- set {_AbatesV} to value "%arg 1%.Abates" get of "plugins/Factions/data.yml"
- set {_MortesV} to value "%arg 1%.Mortes" get of "plugins/Factions/data.yml"
- set {_NameV} to value "%arg 1%.Faction" get of "plugins/Factions/data.yml"
- loop {FactionList::*}:
- set {_FactionFactionV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- set {_FactionRoleV} to value "%loop-value%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is equal to {_TagV}:
- if {_FactionRoleV} is "LEADER":
- set {_LeaderV} to loop-value
- loop {FactionList::*}:
- set {_FactionFactionV} to value "%loop-value%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionFactionV} is {_TagV}:
- add 1 to {_mV}
- loop all players:
- set {_FactionFactionL} to value "%loop-player%.FactionTag" get of "plugins/Factions/data.yml"
- if {_FactionFactionL} is equal to {_TagV}:
- set {_FactionRoleL} to value "%loop-player%.FactionRole" get of "plugins/Factions/data.yml"
- if {_FactionRoleL} is "LEADER":
- set {_mroleV} to "##"
- if {_FactionRoleL} is "OFFICER":
- set {_mroleV} to "*"
- if {_FactionRoleL} is "MEMBER":
- set {_mroleV} to "+"
- if {_FactionRoleL} is "RECRUIT":
- set {_mroleV} to "-"
- add 1 to {_monV}
- add "%{_mrole}%%loop-player%" to {_monlV::*}
- set {_FactionAllyVV} to value "Faction.Ally" get of "plugins/Factions/faction-%{_TagV}%.yml"
- set {_FactionEnemyVV} to value "Faction.Enemy" get of "plugins/Factions/faction-%{_TagV}%.yml"
- if {_FactionAllyVV} is "null":
- set {_FactionAllyV} to "Nenhum"
- else:
- set {_FactionAllyV} to "%{_FactionAllyVV}%"
- if {_FactionEnemyVV} is "null":
- set {_FactionEnemyV} to "Nenhum"
- else:
- set {_FactionEnemyV} to "%{_FactionEnemyVV}%"
- set {_FactionEnemyVV} to value "Faction.Enemy" get of "plugins/Factions/faction-%{_TagV}%.yml"
- if {_TagA} is "&6[Master] " or "&4[Gerente] " or "&c[Admin] " or "&2[Moderador] ":
- format slot 30 of player with skull of ("%arg 1%" parsed as an offline player) named "%{_TagA}%%arg 1%" with lore "&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%||&fCargo: &7%{_RoleA}%||&fKDR: &70.0||&fAbates: &7%{_AbatesA}%||&fMortes: &7%{_MortesA}%||&fGuerras ganhas: &7%{_WinsA}%||&fStatus: &7%{_StatusA}%" to be unstealable
- else:
- format slot 30 of player with skull of ("%arg 1%" parsed as an offline player) named "%{_TagA}%%arg 1%" with lore "&fPoder: &7%{_FactionPowerA}%/%{_FactionMaxPowerA}%||&fCargo: &7%{_RoleA}%||&fKDR: &70.0||&fAbates: &7%{_AbatesA}%||&fMortes: &7%{_MortesA}%||&fGuerras ganhas: &7%{_WinsA}%||&fStatus: &7%{_StatusA}%||&fÚltimo login: &7%{_LastDateA}%" to be unstealable
- if {_monlV::*} isn't set:
- set {_monlV::*} to "Nenhum"
- format slot 32 of player with white named "&e%{_TagV}% - %{_NameV}%" with lore "&fTerras: &70||&fPoder: &75||&fPoder máximo: &75||&fLíder: &7[%{_TagV}%] &f%{_LeaderV}%||&fMembros: &7%{_mV}%/15||&fMembros online: &7%{_monlV::*}%||&fKDR: &70.0||&fAbates: &70||&fMortes: &70||&fAliados: &7%{_FactionAllyV}%||&fInimigos: &7%{_FactionEnemyV}%" to be unstealable
- else:
- send "&cEste usuário não existe."
Advertisement
Add Comment
Please, Sign In to add comment