mirror of
https://github.com/EssentialsX/Essentials.git
synced 2025-03-02 11:11:58 +01:00
Merge pull request #380 from Skylexia/2.9
[Feature] Broadcast unbans to online staff.
This commit is contained in:
commit
5cfb9326f6
@ -395,6 +395,11 @@ is divided into following sections:
|
||||
</and>
|
||||
</condition>
|
||||
</target>
|
||||
<target name="-init-test-properties">
|
||||
<property name="test.binaryincludes" value="<nothing>"/>
|
||||
<property name="test.binarytestincludes" value=""/>
|
||||
<property name="test.binaryexcludes" value=""/>
|
||||
</target>
|
||||
<target if="${nb.junit.single}" name="-init-macrodef-junit-single" unless="${nb.junit.batch}">
|
||||
<macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
|
||||
<attribute default="${includes}" name="includes"/>
|
||||
@ -418,7 +423,7 @@ is divided into following sections:
|
||||
</sequential>
|
||||
</macrodef>
|
||||
</target>
|
||||
<target if="${nb.junit.batch}" name="-init-macrodef-junit-batch" unless="${nb.junit.single}">
|
||||
<target depends="-init-test-properties" if="${nb.junit.batch}" name="-init-macrodef-junit-batch" unless="${nb.junit.single}">
|
||||
<macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
|
||||
<attribute default="${includes}" name="includes"/>
|
||||
<attribute default="${excludes}" name="excludes"/>
|
||||
@ -432,6 +437,9 @@ is divided into following sections:
|
||||
<fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
|
||||
<filename name="@{testincludes}"/>
|
||||
</fileset>
|
||||
<fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">
|
||||
<filename name="${test.binarytestincludes}"/>
|
||||
</fileset>
|
||||
</batchtest>
|
||||
<syspropertyset>
|
||||
<propertyref prefix="test-sys-prop."/>
|
||||
@ -559,7 +567,7 @@ is divided into following sections:
|
||||
</sequential>
|
||||
</macrodef>
|
||||
</target>
|
||||
<target if="${nb.junit.batch}" name="-init-macrodef-junit-debug-batch">
|
||||
<target depends="-init-test-properties" if="${nb.junit.batch}" name="-init-macrodef-junit-debug-batch">
|
||||
<macrodef name="junit-debug" uri="http://www.netbeans.org/ns/j2se-project/3">
|
||||
<attribute default="${includes}" name="includes"/>
|
||||
<attribute default="${excludes}" name="excludes"/>
|
||||
@ -573,6 +581,9 @@ is divided into following sections:
|
||||
<fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
|
||||
<filename name="@{testincludes}"/>
|
||||
</fileset>
|
||||
<fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">
|
||||
<filename name="${test.binarytestincludes}"/>
|
||||
</fileset>
|
||||
</batchtest>
|
||||
<syspropertyset>
|
||||
<propertyref prefix="test-sys-prop."/>
|
||||
@ -952,7 +963,7 @@ is divided into following sections:
|
||||
<target if="has.persistence.xml" name="-copy-persistence-xml">
|
||||
<mkdir dir="${build.classes.dir}/META-INF"/>
|
||||
<copy todir="${build.classes.dir}/META-INF">
|
||||
<fileset dir="${meta.inf.dir}" includes="persistence.xml"/>
|
||||
<fileset dir="${meta.inf.dir}" includes="persistence.xml orm.xml"/>
|
||||
</copy>
|
||||
</target>
|
||||
<target name="-post-compile">
|
||||
|
@ -4,8 +4,8 @@ build.xml.stylesheet.CRC32=28e38971@1.38.2.45
|
||||
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
|
||||
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
|
||||
nbproject/build-impl.xml.data.CRC32=a830bc14
|
||||
nbproject/build-impl.xml.script.CRC32=7c507372
|
||||
nbproject/build-impl.xml.stylesheet.CRC32=6ddba6b6@1.53.1.46
|
||||
nbproject/build-impl.xml.script.CRC32=21ffdddf
|
||||
nbproject/build-impl.xml.stylesheet.CRC32=c6d2a60f@1.56.1.46
|
||||
nbproject/profiler-build-impl.xml.data.CRC32=ab78ce15
|
||||
nbproject/profiler-build-impl.xml.script.CRC32=abda56ed
|
||||
nbproject/profiler-build-impl.xml.stylesheet.CRC32=f10cf54c@1.11.1
|
||||
|
@ -1,10 +1,12 @@
|
||||
package com.earth2me.essentials.commands;
|
||||
|
||||
import com.earth2me.essentials.Console;
|
||||
import static com.earth2me.essentials.I18n._;
|
||||
import com.earth2me.essentials.User;
|
||||
import org.bukkit.OfflinePlayer;
|
||||
import org.bukkit.Server;
|
||||
import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
|
||||
public class Commandunban extends EssentialsCommand
|
||||
@ -21,25 +23,33 @@ public class Commandunban extends EssentialsCommand
|
||||
{
|
||||
throw new NotEnoughArgumentsException();
|
||||
}
|
||||
|
||||
String name;
|
||||
try
|
||||
{
|
||||
final User user = getPlayer(server, args, 0, true);
|
||||
name = user.getName();
|
||||
user.setBanned(false);
|
||||
user.setBanTimeout(0);
|
||||
sender.sendMessage(_("unbannedPlayer"));
|
||||
}
|
||||
catch (NoSuchFieldException e)
|
||||
{
|
||||
final OfflinePlayer player = server.getOfflinePlayer(args[0]);
|
||||
if (player.isBanned())
|
||||
name = player.getName();
|
||||
if (!player.isBanned())
|
||||
{
|
||||
player.setBanned(false);
|
||||
sender.sendMessage(_("unbannedPlayer"));
|
||||
return;
|
||||
}
|
||||
|
||||
throw new Exception(_("playerNotFound"), e);
|
||||
throw new Exception(_("playerNotFound"), e);
|
||||
}
|
||||
player.setBanned(false);
|
||||
}
|
||||
|
||||
final String senderName = sender instanceof Player ? ((Player)sender).getDisplayName() : Console.NAME;
|
||||
for (Player onlinePlayer : server.getOnlinePlayers())
|
||||
{
|
||||
final User onlineUser = ess.getUser(onlinePlayer);
|
||||
if (onlinePlayer == sender || onlineUser.isAuthorized("essentials.ban.notify"))
|
||||
{
|
||||
onlinePlayer.sendMessage(_("playerUnbanned", senderName, name));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a76To deny this request, type \u00a7c/tpdeny\u00a76.
|
||||
typeWorldName=\u00a76You can also type the name of a specific world.
|
||||
unableToSpawnMob=\u00a74Unable to spawn mob.
|
||||
unbannedIP=\u00a76Unbanned IP address.
|
||||
unbannedPlayer=\u00a76Unbanned player.
|
||||
unignorePlayer=\u00a76You are not ignoring player\u00a7c {0} \u00a76anymore.
|
||||
unknownItemId=\u00a74Unknown item id:\u00a7r {0}\u00a74.
|
||||
unknownItemInList=\u00a74Unknown item {0} in {1} list.
|
||||
@ -520,3 +519,4 @@ year=year
|
||||
years=years
|
||||
youAreHealed=\u00a76You have been healed.
|
||||
youHaveNewMail=\u00a76You have\u00a7c {0} \u00a76messages! Type \u00a7c/mail read\u00a76 to view your mail.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -459,7 +459,6 @@ typeTpdeny=\u00a77Pokud chces odmitnout zadost napis \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Muzes take napsat specificky nazev sveta.
|
||||
unableToSpawnMob=Nemozne spawnout moba.
|
||||
unbannedIP=Unbanovana IP adresa.
|
||||
unbannedPlayer=Hrac odbanovan.
|
||||
unignorePlayer=Prestal jsi ignorovat hrace {0}.
|
||||
unknownItemId=Nezname ID itemu: {0}
|
||||
unknownItemInList=Neznamy item {0} v {1} seznamu.
|
||||
@ -523,3 +522,4 @@ year=rok
|
||||
years=roky
|
||||
youAreHealed=\u00a77Byl jsi uzdraven.
|
||||
youHaveNewMail=\u00a7cMas {0} zprav!\u00a7f Napis \u00a77/mail read\u00a7f aby jsi si precetl sve zpravy.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77For at n\u00e6gte denne anmodning om teleport, skriv \u00a7c/t
|
||||
typeWorldName=\u00a77Du kan ogs\u00e5 skrive navnet p\u00e5 en specifik verden.
|
||||
unableToSpawnMob=Kunne ikke spawne mob.
|
||||
unbannedIP=Tilgav IP addressen; er ikke l\u00e6ngere bannet.
|
||||
unbannedPlayer=Tilgav spilleren; er ikke l\u00e6ngere bannet.
|
||||
unignorePlayer=Du ignorerer ikke spiller {0} mere.
|
||||
unknownItemId=Ukendt ting id: {0}
|
||||
unknownItemInList=Ukendt ting {0} i {1} listen.
|
||||
@ -520,3 +519,4 @@ year=\u00e5r
|
||||
years=\u00e5r
|
||||
youAreHealed=\u00a77Du er blevet healed. Halleluja!
|
||||
youHaveNewMail=\u00a7cDu har {0} flaskeposter!\u00a7f Type \u00a77/mail read for at se din flaskepost.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Um diese Anfrage abzulehnen, schreibe \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Du kannst auch den Namen der Welt eingeben.
|
||||
unableToSpawnMob=Fehler beim Erzeugen eines Monster.
|
||||
unbannedIP=Verbannung von IP-Adresse r\u00fcckg\u00e4ngig gemacht.
|
||||
unbannedPlayer=Verbannung von Spieler r\u00fcckg\u00e4ngig gemacht.
|
||||
unignorePlayer=Du ignorierst Spieler {0} nicht mehr.
|
||||
unknownItemId=Unbekannte Item-Id: {0}
|
||||
unknownItemInList=Unbekannter Gegenstand {0} in Liste {1}.
|
||||
@ -520,3 +519,4 @@ year=Jahr
|
||||
years=Jahre
|
||||
youAreHealed=\u00a77Du wurdest geheilt.
|
||||
youHaveNewMail=\u00a7cDu hast {0} Nachrichten!\u00a7f Schreibe \u00a77/mail read\u00a7f um deine Nachrichten anzuzeigen.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a76To deny this request, type \u00a7c/tpdeny\u00a76.
|
||||
typeWorldName=\u00a76You can also type the name of a specific world.
|
||||
unableToSpawnMob=\u00a74Unable to spawn mob.
|
||||
unbannedIP=\u00a76Unbanned IP address.
|
||||
unbannedPlayer=\u00a76Unbanned player.
|
||||
unignorePlayer=\u00a76You are not ignoring player\u00a7c {0} \u00a76anymore.
|
||||
unknownItemId=\u00a74Unknown item id:\u00a7r {0}\u00a74.
|
||||
unknownItemInList=\u00a74Unknown item {0} in {1} list.
|
||||
@ -520,3 +519,4 @@ year=year
|
||||
years=years
|
||||
youAreHealed=\u00a76You have been healed.
|
||||
youHaveNewMail=\u00a76You have\u00a7c {0} \u00a76messages! Type \u00a7c/mail read\u00a76 to view your mail.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Para denegar esta peticion, escribe \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Tu tambien puedes escribir el nombre de un mundo especifico.
|
||||
unableToSpawnMob=No se puede generar Mobs.
|
||||
unbannedIP=Direccion IP desbaneada.
|
||||
unbannedPlayer=Jugador desbaneado.
|
||||
unignorePlayer=Ya no estas ignorando al jugador {0}.
|
||||
unknownItemId=ID de objeto desconocido: {0}
|
||||
unknownItemInList=Objeto desconocido {0} en {1} lista.
|
||||
@ -520,3 +519,4 @@ year=ano
|
||||
years=anos
|
||||
youAreHealed=\u00a77Has sido curado.
|
||||
youHaveNewMail=\u00a7cTienes {0} mensajes!\u00a7f Pon \u00a77/mail read\u00a7f para ver tus emails no leidos!.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Kielt\u00e4\u00e4ksesi, kirjoita \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Voit my\u00f6s laittaa maailman nimen.
|
||||
unableToSpawnMob=Ei voida luoda mobia.
|
||||
unbannedIP=Unbanned IP osoite.
|
||||
unbannedPlayer=Unbanned pelaaja.
|
||||
unignorePlayer=Otat taas huomioon pelaajan {0}.
|
||||
unknownItemId=Tuntematon tavaran ID: {0}
|
||||
unknownItemInList=Tuntematon tavara {0} listassa {1}.
|
||||
@ -520,3 +519,4 @@ year=vuosi
|
||||
years=vuosia
|
||||
youAreHealed=\u00a77Sinut on parannettu.
|
||||
youHaveNewMail=\u00a7cSinulla on {0} viesti(\u00e4)!\u00a7f Kirjoita \u00a77/mail read\u00a7f lukeaksesi viestit.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Pour d\u00e9cliner cette demande, utilisez \u00a7c/tpdeny\u00a
|
||||
typeWorldName=\u00a77Vous pouvez aussi taper le nom d'un monde sp\u00e9cifique.
|
||||
unableToSpawnMob=Incapable d'invoquer un cr\u00e9ature.
|
||||
unbannedIP=Adresse IP d\u00e9bannie.
|
||||
unbannedPlayer=Joueur d\u00e9banni.
|
||||
unignorePlayer=Vous n''ignorez plus {0}.
|
||||
unknownItemId=Num\u00e9ro d''objet inconnu : {0}
|
||||
unknownItemInList=L''objet {0} est inconnu dans la liste {1}.
|
||||
@ -520,3 +519,4 @@ year=ann\u00e9e
|
||||
years=ann\u00e9es
|
||||
youAreHealed=\u00a77Vous avez \u00e9t\u00e9 soign\u00e9.
|
||||
youHaveNewMail=\u00a7cVous avez {0} messages ! \u00a7fEntrez \u00a77/mail read\u00a7f pour voir votre courrier.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Per rifiutare il teletrasporto, digita \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Puoi digitare anche il nome di un mondo.
|
||||
unableToSpawnMob=Impossibile generare il mob.
|
||||
unbannedIP=IP address abilitato.
|
||||
unbannedPlayer=Player abilitato.
|
||||
unignorePlayer=Non stai piu'' ignorando il player {0}.
|
||||
unknownItemId=ID oggetto sconosciuto: {0}
|
||||
unknownItemInList=Oggetto {0} sconosciuto nella lista {1}.
|
||||
@ -520,3 +519,4 @@ year=anno
|
||||
years=anni
|
||||
youAreHealed=\u00a77Sei stato curato.
|
||||
youHaveNewMail=\u00a7cHai {0} messaggi!\u00a7f digita \u00a77/mail read\u00a7f per consultare la tua mail.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Om te weigeren, type \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Je kan ook de exacte naam van de wereld typen.
|
||||
unableToSpawnMob=De mob kan niet gespawned worden.
|
||||
unbannedIP=IP adres ontbannen.
|
||||
unbannedPlayer=Speler ontbannen.
|
||||
unignorePlayer=Je negeert {0} niet meer.
|
||||
unknownItemId=Onbekend voorwerp id: {0}
|
||||
unknownItemInList=Onbekend voorwerp {0} in {1} lijst.
|
||||
@ -520,3 +519,4 @@ year=jaar
|
||||
years=jaren
|
||||
youAreHealed=\u00a77Je bent genezen.
|
||||
youHaveNewMail=\u00a7cJe hebt {0} berichten!\u00a7f Type \u00a77/mail read\u00a7f om je berichten te bekijken.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Aby odmowic teleportacji, wpisz \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Mozesz rowniez wpisac nazwe danego swiata.
|
||||
unableToSpawnMob=\u00a74Nie udalo sie stworzyc potwora.
|
||||
unbannedIP=\u00a77Odbanowana gracza o danym adresie IP.
|
||||
unbannedPlayer=\u00a77Odbanowano gracza.
|
||||
unignorePlayer=\u00a77Nie ignorujesz juz gracza \u00a7c{0}\u00a77.
|
||||
unknownItemId=\u00a74Nieznane id przedmiotu:\u00a7r {0}\u00a74.
|
||||
unknownItemInList=\u00a74Nieznany przedmiot {0} w liscie {1} .
|
||||
@ -520,3 +519,4 @@ year=rok
|
||||
years=lat
|
||||
youAreHealed=\u00a77Zostales/as uleczony/na.
|
||||
youHaveNewMail=\u00a77Masz\u00a7c {0} \u00a77wiadomosci! Wpisz \u00a7c/mail read\u00a77 aby je przeczytac.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77Para recusar o teleporte, digite \u00a7c/tpdeny\u00a77.
|
||||
typeWorldName=\u00a77Voc\u00ea tambem pode digitar o nome do mundo.
|
||||
unableToSpawnMob=Incapaz de gerar o mob.
|
||||
unbannedIP=Endereco de IP desbanido.
|
||||
unbannedPlayer=Jogador desbanido.
|
||||
unignorePlayer=Agora voc\u00ea nao esta mais ignorando o {0}.
|
||||
unknownItemId=ID do item desconhecido: {0}
|
||||
unknownItemInList=Item desconhecido {0} em {1} lista.
|
||||
@ -520,3 +519,4 @@ year=ano
|
||||
years=anos
|
||||
youAreHealed=\u00a77Voc\u00ea foi curado.
|
||||
youHaveNewMail=\u00a7cVoc\u00ea tem {0} mensagens!\u00a7f Digite \u00a77/mail read\u00a7f para ver seu email.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
@ -456,7 +456,6 @@ typeTpdeny=\u00a77F\u00f6r att neka denna f\u00f6rfr\u00e5gan, skriv \u00a7c/tpd
|
||||
typeWorldName=\u00a77Du kan ocks\u00e5 skriva namnet av en specifik v\u00e4rld.
|
||||
unableToSpawnMob=Kunde inte spawna moben.
|
||||
unbannedIP=Tog bort bannlysningen fr\u00e5n IP-adress.
|
||||
unbannedPlayer=Tog bort bannlysningen fr\u00e5n spelaren.
|
||||
unignorePlayer=Du ignorerar inte spelaren {0} l\u00e4ngre.
|
||||
unknownItemId=Ok\u00e4nt objekt-ID: {0}
|
||||
unknownItemInList=Ok\u00e4nt objekt {0} i listan {1}.
|
||||
@ -520,3 +519,4 @@ year=\u00e5r
|
||||
years=\u00e5r
|
||||
youAreHealed=\u00a77Du har blivit l\u00e4kt.
|
||||
youHaveNewMail=\u00a7cDu har {0} meddelanden!\u00a7f Skriv \u00a77/mail read\u00a7f f\u00f6r att l\u00e4sa dina meddelanden.
|
||||
playerUnbanned=\u00a76Player\u00a7c {0} \u00a76unbanned {1}.
|
||||
|
Loading…
Reference in New Issue
Block a user