From f52444f6e529978ed7022b2d1086e398d27b2eda Mon Sep 17 00:00:00 2001 From: yoyosource Date: Sun, 24 Apr 2022 15:02:03 +0200 Subject: [PATCH 1/6] Add some new punishments after talking with mods --- src/de/steamwar/bungeecore/BungeeCore.java | 2 ++ .../steamwar/bungeecore/commands/PunishmentCommand.java | 3 +++ src/de/steamwar/bungeecore/commands/TeamCommand.java | 9 +++++---- src/de/steamwar/bungeecore/sql/Punishment.java | 2 ++ src/de/steamwar/messages/BungeeCore.properties | 8 ++++++++ 5 files changed, 20 insertions(+), 4 deletions(-) diff --git a/src/de/steamwar/bungeecore/BungeeCore.java b/src/de/steamwar/bungeecore/BungeeCore.java index ffef144..a367b5d 100644 --- a/src/de/steamwar/bungeecore/BungeeCore.java +++ b/src/de/steamwar/bungeecore/BungeeCore.java @@ -135,6 +135,8 @@ public class BungeeCore extends Plugin { new PunishmentCommand("noschemsubmitting", Punishment.PunishmentType.NoSchemSubmitting); new PunishmentCommand("nodev", Punishment.PunishmentType.NoDevServer); new PunishmentCommand("nofight", Punishment.PunishmentType.NoFightServer); + new PunishmentCommand("noteamserver", Punishment.PunishmentType.NoTeamServer); + new PunishmentCommand("note", Punishment.PunishmentType.Note); if(!EVENT_MODE){ new BauCommand(); diff --git a/src/de/steamwar/bungeecore/commands/PunishmentCommand.java b/src/de/steamwar/bungeecore/commands/PunishmentCommand.java index ccb6f06..a02b48f 100644 --- a/src/de/steamwar/bungeecore/commands/PunishmentCommand.java +++ b/src/de/steamwar/bungeecore/commands/PunishmentCommand.java @@ -63,6 +63,9 @@ public class PunishmentCommand { Message.team(punishmentType.getTeamMessage(), new Message("PREFIX"), target.getUserName(), sender.getName(), new Message((isPerma ? "PUNISHMENT_PERMA" : "PUNISHMENT_UNTIL"), banTime), msg); } }; + if (punishmentType.getUnpunishmentMessage() == null) { + return; + } String antiCommand = "un" + command; new BasicCommand(antiCommand, "bungeecore.ban") { @Override diff --git a/src/de/steamwar/bungeecore/commands/TeamCommand.java b/src/de/steamwar/bungeecore/commands/TeamCommand.java index d92b5da..20b4b95 100644 --- a/src/de/steamwar/bungeecore/commands/TeamCommand.java +++ b/src/de/steamwar/bungeecore/commands/TeamCommand.java @@ -23,10 +23,8 @@ import de.steamwar.bungeecore.Message; import de.steamwar.bungeecore.Storage; import de.steamwar.bungeecore.inventory.SWItem; import de.steamwar.bungeecore.inventory.SWListInv; -import de.steamwar.bungeecore.sql.Event; -import de.steamwar.bungeecore.sql.SteamwarUser; -import de.steamwar.bungeecore.sql.Team; -import de.steamwar.bungeecore.sql.TeamTeilnahme; +import de.steamwar.bungeecore.sql.*; +import de.steamwar.messages.ChatSender; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.CommandSender; import net.md_5.bungee.api.ProxyServer; @@ -594,6 +592,9 @@ public class TeamCommand extends BasicCommand { private void server(ProxiedPlayer player, SteamwarUser user, Team team, String[] args){ if(notLeader(player, user, team)) return; + if (user.isPunishedWithMessage(ChatSender.of(player), Punishment.PunishmentType.NoTeamServer)) { + return; + } if (args.length < 2) { Message.send("TEAM_SERVER_USAGE", player); return; diff --git a/src/de/steamwar/bungeecore/sql/Punishment.java b/src/de/steamwar/bungeecore/sql/Punishment.java index d53d6e3..a8fcc0c 100644 --- a/src/de/steamwar/bungeecore/sql/Punishment.java +++ b/src/de/steamwar/bungeecore/sql/Punishment.java @@ -142,6 +142,8 @@ public class Punishment { NoSchemSubmitting(true, "NOSCHEMSUBMITTING_TEAM", "NOSCHEMSUBMITTING_PERMA", "NOSCHEMSUBMITTING_UNTIL", "UNNOSCHEMSUBMITTING_ERROR", "UNNOSCHEMSUBMITTING"), NoDevServer(true, "NODEVSERVER_TEAM", "NODEVSERVER_PERMA", "NODEVSERVER_UNTIL", "UNNODEVSERVER_ERROR", "UNNODEVSERVER"), NoFightServer(false, "NOFIGHTSERVER_TEAM", "NOFIGHTSERVER_PERMA", "NOFIGHTSERVER_UNTIL", "UNNOFIGHTSERVER_ERROR", "UNNOFIGHTSERVER"), + NoTeamServer(true, "NOTEAMSERVER_TEAM", "NOTEAMSERVER_PERMA", "NOTEAMSERVER_UNTIL", "UNNOTEAMSERVER_ERROR", "UNNOTEAMSERVER"), + Note(false, "NOTE_TEAM", null, null, null, null), ; private final boolean needsAdmin; diff --git a/src/de/steamwar/messages/BungeeCore.properties b/src/de/steamwar/messages/BungeeCore.properties index 15615e8..224c31c 100644 --- a/src/de/steamwar/messages/BungeeCore.properties +++ b/src/de/steamwar/messages/BungeeCore.properties @@ -162,6 +162,14 @@ NOFIGHTSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lKämpfen§7 ausgeschl UNNOFIGHTSERVER_ERROR=§cDer Spieler ist nicht vom Kämpfen ausgeschlossen. UNNOFIGHTSERVER=§e{0} §7darf nun wieder §e§lKämpfen§7 beitreten§8. +NOTEAMSERVER_TEAM={0} §e{1} §7wurde von §e{2} {3} §7vom §e§lTeamserver§7 setzten ausgeschlossen§8. §7Grund§8: §f{4} +NOTEAMSERVER_PERMA=§7Du bist §epermanent §7vom §e§lTeamserver§7 setzten ausgeschlossen§8. §7Grund§8: §e{0} +NOTEAMSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lTeamserver§7 setzten ausgeschlossen§8. §7Grund§8: §e{1} +UNNOTEAMSERVER_ERROR=§cDer Spieler ist nicht vom Teamserver setzten ausgeschlossen. +UNNOTEAMSERVER=§e{0} §7darf nun wieder §e§lTeamserver§7 setzten§8. + +NOTE_TEAM={0} §e{1} §7erhielt von §e{2} {3} §7die §e§lNotiz§7§8: §f{4} + #BugCommand BUG_MESSAGE=§7Dein Bugreport wurde gespeichert. From 2ef6901f8e2402dc9e07afd8f5866d5e0c3ae421 Mon Sep 17 00:00:00 2001 From: yoyosource Date: Mon, 25 Apr 2022 11:09:08 +0200 Subject: [PATCH 2/6] Update WhoisCommand Add mutlie note punishments --- .../bungeecore/commands/WhoisCommand.java | 38 +++++++++---------- .../steamwar/bungeecore/sql/Punishment.java | 5 ++- 2 files changed, 21 insertions(+), 22 deletions(-) diff --git a/src/de/steamwar/bungeecore/commands/WhoisCommand.java b/src/de/steamwar/bungeecore/commands/WhoisCommand.java index bbb1af5..10c0316 100644 --- a/src/de/steamwar/bungeecore/commands/WhoisCommand.java +++ b/src/de/steamwar/bungeecore/commands/WhoisCommand.java @@ -29,7 +29,9 @@ import net.md_5.bungee.api.connection.ProxiedPlayer; import java.sql.Timestamp; import java.text.DecimalFormat; +import java.util.HashSet; import java.util.List; +import java.util.Set; public class WhoisCommand extends BasicCommand { public WhoisCommand(){ @@ -94,28 +96,22 @@ public class WhoisCommand extends BasicCommand { Message.send("WHOIS_TEAM", player, Message.parse("WHOIS_TEAM_HOVER", player, team.getTeamName()), new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/team info " + team.getTeamKuerzel()), team.getTeamColor(), team.getTeamKuerzel(), team.getTeamName()); Message.send("WHOIS_PUNISHMENTS", player); - if(all) { - List punishmentList = Punishment.getAllPunishmentsOfPlayer(user.getId()); - if(punishmentList.isEmpty()) { - Message.send("WHOIS_NO_ALL_PUNISHMENT", player); - return; - } - for (Punishment punishment : punishmentList) { - Message.sendPrefixless("WHOIS_PUNISHMENT", player, SteamwarUser.get(punishment.getPunisher()).getUserName(), punishment.getType().name(), punishment.getBantime(punishment.getStartTime(), false), punishment.getBantime(punishment.getEndTime(), punishment.isPerma()), punishment.getReason()); - } - } else { - boolean isPunished = false; - for (Punishment.PunishmentType punishmentType : Punishment.PunishmentType.values()) { - if(!user.isPunished(punishmentType)) { - continue; - } - Punishment punishment = user.getPunishment(punishmentType); - isPunished = true; - Message.sendPrefixless("WHOIS_PUNISHMENT", player, SteamwarUser.get(punishment.getPunisher()).getUserName(), punishment.getType().name(), punishment.getBantime(punishment.getStartTime(), false), punishment.getBantime(punishment.getEndTime(), punishment.isPerma()), punishment.getReason()); - } - if(!isPunished) { - Message.send("WHOIS_NO_PUNISHMENT", player); + List punishmentList = Punishment.getAllPunishmentsOfPlayer(user.getId()); + if (punishmentList.isEmpty()) { + Message.send(all ? "WHOIS_NO_ALL_PUNISHMENT" : "WHOIS_NO_PUNISHMENT", player); + return; + } + Set found = new HashSet<>(); + boolean isPunished = false; + for (Punishment punishment : punishmentList) { + if (!all && !punishment.getType().isMulti() && !found.add(punishment.getType())) { + continue; } + Message.sendPrefixless("WHOIS_PUNISHMENT", player, SteamwarUser.get(punishment.getPunisher()).getUserName(), punishment.getType().name(), punishment.getBantime(punishment.getStartTime(), false), punishment.getBantime(punishment.getEndTime(), punishment.isPerma()), punishment.getReason()); + isPunished = true; + } + if (!all && !isPunished) { + Message.send("WHOIS_NO_PUNISHMENT", player); } } } diff --git a/src/de/steamwar/bungeecore/sql/Punishment.java b/src/de/steamwar/bungeecore/sql/Punishment.java index a8fcc0c..a2a1085 100644 --- a/src/de/steamwar/bungeecore/sql/Punishment.java +++ b/src/de/steamwar/bungeecore/sql/Punishment.java @@ -21,6 +21,7 @@ package de.steamwar.bungeecore.sql; import lombok.AllArgsConstructor; import lombok.Getter; +import lombok.RequiredArgsConstructor; import java.sql.ResultSet; import java.sql.SQLException; @@ -133,6 +134,7 @@ public class Punishment { } @AllArgsConstructor + @RequiredArgsConstructor @Getter public enum PunishmentType { Ban(false, "BAN_TEAM", "BAN_PERMA", "BAN_UNTIL", "UNBAN_ERROR", "UNBAN"), @@ -143,7 +145,7 @@ public class Punishment { NoDevServer(true, "NODEVSERVER_TEAM", "NODEVSERVER_PERMA", "NODEVSERVER_UNTIL", "UNNODEVSERVER_ERROR", "UNNODEVSERVER"), NoFightServer(false, "NOFIGHTSERVER_TEAM", "NOFIGHTSERVER_PERMA", "NOFIGHTSERVER_UNTIL", "UNNOFIGHTSERVER_ERROR", "UNNOFIGHTSERVER"), NoTeamServer(true, "NOTEAMSERVER_TEAM", "NOTEAMSERVER_PERMA", "NOTEAMSERVER_UNTIL", "UNNOTEAMSERVER_ERROR", "UNNOTEAMSERVER"), - Note(false, "NOTE_TEAM", null, null, null, null), + Note(false, "NOTE_TEAM", null, null, null, null, true), ; private final boolean needsAdmin; @@ -152,5 +154,6 @@ public class Punishment { private final String playerMessageUntil; private final String usageNotPunished; private final String unpunishmentMessage; + private boolean multi = false; } } From cc86aa16a05a7ee8f68cee737a2ba2074b7dabe5 Mon Sep 17 00:00:00 2001 From: yoyosource Date: Tue, 26 Apr 2022 15:21:09 +0200 Subject: [PATCH 3/6] Update stuff --- src/de/steamwar/bungeecore/commands/WhoisCommand.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/de/steamwar/bungeecore/commands/WhoisCommand.java b/src/de/steamwar/bungeecore/commands/WhoisCommand.java index 10c0316..da6a631 100644 --- a/src/de/steamwar/bungeecore/commands/WhoisCommand.java +++ b/src/de/steamwar/bungeecore/commands/WhoisCommand.java @@ -97,10 +97,6 @@ public class WhoisCommand extends BasicCommand { Message.send("WHOIS_PUNISHMENTS", player); List punishmentList = Punishment.getAllPunishmentsOfPlayer(user.getId()); - if (punishmentList.isEmpty()) { - Message.send(all ? "WHOIS_NO_ALL_PUNISHMENT" : "WHOIS_NO_PUNISHMENT", player); - return; - } Set found = new HashSet<>(); boolean isPunished = false; for (Punishment punishment : punishmentList) { @@ -110,8 +106,8 @@ public class WhoisCommand extends BasicCommand { Message.sendPrefixless("WHOIS_PUNISHMENT", player, SteamwarUser.get(punishment.getPunisher()).getUserName(), punishment.getType().name(), punishment.getBantime(punishment.getStartTime(), false), punishment.getBantime(punishment.getEndTime(), punishment.isPerma()), punishment.getReason()); isPunished = true; } - if (!all && !isPunished) { - Message.send("WHOIS_NO_PUNISHMENT", player); + if (!isPunished) { + Message.send(all ? "WHOIS_NO_ALL_PUNISHMENT" : "WHOIS_NO_PUNISHMENT", player); } } } From 9a281734968a6f9ef8156a9954376be6f6dcc97c Mon Sep 17 00:00:00 2001 From: yoyosource Date: Tue, 26 Apr 2022 15:21:44 +0200 Subject: [PATCH 4/6] Update stuff --- src/de/steamwar/messages/BungeeCore.properties | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/de/steamwar/messages/BungeeCore.properties b/src/de/steamwar/messages/BungeeCore.properties index 224c31c..ee300bf 100644 --- a/src/de/steamwar/messages/BungeeCore.properties +++ b/src/de/steamwar/messages/BungeeCore.properties @@ -162,11 +162,11 @@ NOFIGHTSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lKämpfen§7 ausgeschl UNNOFIGHTSERVER_ERROR=§cDer Spieler ist nicht vom Kämpfen ausgeschlossen. UNNOFIGHTSERVER=§e{0} §7darf nun wieder §e§lKämpfen§7 beitreten§8. -NOTEAMSERVER_TEAM={0} §e{1} §7wurde von §e{2} {3} §7vom §e§lTeamserver§7 setzten ausgeschlossen§8. §7Grund§8: §f{4} -NOTEAMSERVER_PERMA=§7Du bist §epermanent §7vom §e§lTeamserver§7 setzten ausgeschlossen§8. §7Grund§8: §e{0} -NOTEAMSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lTeamserver§7 setzten ausgeschlossen§8. §7Grund§8: §e{1} +NOTEAMSERVER_TEAM={0} §e{1} §7wurde von §e{2} {3} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §f{4} +NOTEAMSERVER_PERMA=§7Du bist §epermanent §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{0} +NOTEAMSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{1} UNNOTEAMSERVER_ERROR=§cDer Spieler ist nicht vom Teamserver setzten ausgeschlossen. -UNNOTEAMSERVER=§e{0} §7darf nun wieder §e§lTeamserver§7 setzten§8. +UNNOTEAMSERVER=§e{0} §7darf nun wieder §e§lTeamserver§7 setzen§8. NOTE_TEAM={0} §e{1} §7erhielt von §e{2} {3} §7die §e§lNotiz§7§8: §f{4} From f61fcde5c9274bd3b0e751c075830a0f91e9b78a Mon Sep 17 00:00:00 2001 From: yoyosource Date: Tue, 26 Apr 2022 18:18:27 +0200 Subject: [PATCH 5/6] Update stuff --- src/de/steamwar/bungeecore/BungeeCore.java | 2 +- src/de/steamwar/bungeecore/commands/TeamCommand.java | 2 +- src/de/steamwar/bungeecore/sql/Punishment.java | 2 +- src/de/steamwar/messages/BungeeCore.properties | 10 +++++----- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/de/steamwar/bungeecore/BungeeCore.java b/src/de/steamwar/bungeecore/BungeeCore.java index a367b5d..1e3db21 100644 --- a/src/de/steamwar/bungeecore/BungeeCore.java +++ b/src/de/steamwar/bungeecore/BungeeCore.java @@ -135,7 +135,7 @@ public class BungeeCore extends Plugin { new PunishmentCommand("noschemsubmitting", Punishment.PunishmentType.NoSchemSubmitting); new PunishmentCommand("nodev", Punishment.PunishmentType.NoDevServer); new PunishmentCommand("nofight", Punishment.PunishmentType.NoFightServer); - new PunishmentCommand("noteamserver", Punishment.PunishmentType.NoTeamServer); + new PunishmentCommand("noteamserver", Punishment.PunishmentType.NoTeamServerSet); new PunishmentCommand("note", Punishment.PunishmentType.Note); if(!EVENT_MODE){ diff --git a/src/de/steamwar/bungeecore/commands/TeamCommand.java b/src/de/steamwar/bungeecore/commands/TeamCommand.java index 20b4b95..d81110d 100644 --- a/src/de/steamwar/bungeecore/commands/TeamCommand.java +++ b/src/de/steamwar/bungeecore/commands/TeamCommand.java @@ -592,7 +592,7 @@ public class TeamCommand extends BasicCommand { private void server(ProxiedPlayer player, SteamwarUser user, Team team, String[] args){ if(notLeader(player, user, team)) return; - if (user.isPunishedWithMessage(ChatSender.of(player), Punishment.PunishmentType.NoTeamServer)) { + if (user.isPunishedWithMessage(ChatSender.of(player), Punishment.PunishmentType.NoTeamServerSet)) { return; } if (args.length < 2) { diff --git a/src/de/steamwar/bungeecore/sql/Punishment.java b/src/de/steamwar/bungeecore/sql/Punishment.java index a2a1085..e320d73 100644 --- a/src/de/steamwar/bungeecore/sql/Punishment.java +++ b/src/de/steamwar/bungeecore/sql/Punishment.java @@ -144,7 +144,7 @@ public class Punishment { NoSchemSubmitting(true, "NOSCHEMSUBMITTING_TEAM", "NOSCHEMSUBMITTING_PERMA", "NOSCHEMSUBMITTING_UNTIL", "UNNOSCHEMSUBMITTING_ERROR", "UNNOSCHEMSUBMITTING"), NoDevServer(true, "NODEVSERVER_TEAM", "NODEVSERVER_PERMA", "NODEVSERVER_UNTIL", "UNNODEVSERVER_ERROR", "UNNODEVSERVER"), NoFightServer(false, "NOFIGHTSERVER_TEAM", "NOFIGHTSERVER_PERMA", "NOFIGHTSERVER_UNTIL", "UNNOFIGHTSERVER_ERROR", "UNNOFIGHTSERVER"), - NoTeamServer(true, "NOTEAMSERVER_TEAM", "NOTEAMSERVER_PERMA", "NOTEAMSERVER_UNTIL", "UNNOTEAMSERVER_ERROR", "UNNOTEAMSERVER"), + NoTeamServerSet(true, "NOTEAMSERVERSET_TEAM", "NOTEAMSERVERSET_PERMA", "NOTEAMSERVERSET_UNTIL", "UNNOTEAMSERVERSET_ERROR", "UNNOTEAMSERVERSET"), Note(false, "NOTE_TEAM", null, null, null, null, true), ; diff --git a/src/de/steamwar/messages/BungeeCore.properties b/src/de/steamwar/messages/BungeeCore.properties index ee300bf..3dd9704 100644 --- a/src/de/steamwar/messages/BungeeCore.properties +++ b/src/de/steamwar/messages/BungeeCore.properties @@ -162,11 +162,11 @@ NOFIGHTSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lKämpfen§7 ausgeschl UNNOFIGHTSERVER_ERROR=§cDer Spieler ist nicht vom Kämpfen ausgeschlossen. UNNOFIGHTSERVER=§e{0} §7darf nun wieder §e§lKämpfen§7 beitreten§8. -NOTEAMSERVER_TEAM={0} §e{1} §7wurde von §e{2} {3} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §f{4} -NOTEAMSERVER_PERMA=§7Du bist §epermanent §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{0} -NOTEAMSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{1} -UNNOTEAMSERVER_ERROR=§cDer Spieler ist nicht vom Teamserver setzten ausgeschlossen. -UNNOTEAMSERVER=§e{0} §7darf nun wieder §e§lTeamserver§7 setzen§8. +NOTEAMSERVERSET_TEAM={0} §e{1} §7wurde von §e{2} {3} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §f{4} +NOTEAMSERVERSET_PERMA=§7Du bist §epermanent §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{0} +NOTEAMSERVERSET_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{1} +UNNOTEAMSERVERSET_ERROR=§cDer Spieler ist nicht vom Teamserver setzten ausgeschlossen. +UNNOTEAMSERVERSET=§e{0} §7darf nun wieder §e§lTeamserver§7 setzen§8. NOTE_TEAM={0} §e{1} §7erhielt von §e{2} {3} §7die §e§lNotiz§7§8: §f{4} From 93dcb0d202fcf0fb4dd08a3ac193ba01f146f4be Mon Sep 17 00:00:00 2001 From: yoyosource Date: Tue, 26 Apr 2022 19:25:32 +0200 Subject: [PATCH 6/6] Revert "Update stuff" This reverts commit f61fcde5c9274bd3b0e751c075830a0f91e9b78a. --- src/de/steamwar/bungeecore/BungeeCore.java | 2 +- src/de/steamwar/bungeecore/commands/TeamCommand.java | 2 +- src/de/steamwar/bungeecore/sql/Punishment.java | 2 +- src/de/steamwar/messages/BungeeCore.properties | 10 +++++----- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/de/steamwar/bungeecore/BungeeCore.java b/src/de/steamwar/bungeecore/BungeeCore.java index 1e3db21..a367b5d 100644 --- a/src/de/steamwar/bungeecore/BungeeCore.java +++ b/src/de/steamwar/bungeecore/BungeeCore.java @@ -135,7 +135,7 @@ public class BungeeCore extends Plugin { new PunishmentCommand("noschemsubmitting", Punishment.PunishmentType.NoSchemSubmitting); new PunishmentCommand("nodev", Punishment.PunishmentType.NoDevServer); new PunishmentCommand("nofight", Punishment.PunishmentType.NoFightServer); - new PunishmentCommand("noteamserver", Punishment.PunishmentType.NoTeamServerSet); + new PunishmentCommand("noteamserver", Punishment.PunishmentType.NoTeamServer); new PunishmentCommand("note", Punishment.PunishmentType.Note); if(!EVENT_MODE){ diff --git a/src/de/steamwar/bungeecore/commands/TeamCommand.java b/src/de/steamwar/bungeecore/commands/TeamCommand.java index d81110d..20b4b95 100644 --- a/src/de/steamwar/bungeecore/commands/TeamCommand.java +++ b/src/de/steamwar/bungeecore/commands/TeamCommand.java @@ -592,7 +592,7 @@ public class TeamCommand extends BasicCommand { private void server(ProxiedPlayer player, SteamwarUser user, Team team, String[] args){ if(notLeader(player, user, team)) return; - if (user.isPunishedWithMessage(ChatSender.of(player), Punishment.PunishmentType.NoTeamServerSet)) { + if (user.isPunishedWithMessage(ChatSender.of(player), Punishment.PunishmentType.NoTeamServer)) { return; } if (args.length < 2) { diff --git a/src/de/steamwar/bungeecore/sql/Punishment.java b/src/de/steamwar/bungeecore/sql/Punishment.java index e320d73..a2a1085 100644 --- a/src/de/steamwar/bungeecore/sql/Punishment.java +++ b/src/de/steamwar/bungeecore/sql/Punishment.java @@ -144,7 +144,7 @@ public class Punishment { NoSchemSubmitting(true, "NOSCHEMSUBMITTING_TEAM", "NOSCHEMSUBMITTING_PERMA", "NOSCHEMSUBMITTING_UNTIL", "UNNOSCHEMSUBMITTING_ERROR", "UNNOSCHEMSUBMITTING"), NoDevServer(true, "NODEVSERVER_TEAM", "NODEVSERVER_PERMA", "NODEVSERVER_UNTIL", "UNNODEVSERVER_ERROR", "UNNODEVSERVER"), NoFightServer(false, "NOFIGHTSERVER_TEAM", "NOFIGHTSERVER_PERMA", "NOFIGHTSERVER_UNTIL", "UNNOFIGHTSERVER_ERROR", "UNNOFIGHTSERVER"), - NoTeamServerSet(true, "NOTEAMSERVERSET_TEAM", "NOTEAMSERVERSET_PERMA", "NOTEAMSERVERSET_UNTIL", "UNNOTEAMSERVERSET_ERROR", "UNNOTEAMSERVERSET"), + NoTeamServer(true, "NOTEAMSERVER_TEAM", "NOTEAMSERVER_PERMA", "NOTEAMSERVER_UNTIL", "UNNOTEAMSERVER_ERROR", "UNNOTEAMSERVER"), Note(false, "NOTE_TEAM", null, null, null, null, true), ; diff --git a/src/de/steamwar/messages/BungeeCore.properties b/src/de/steamwar/messages/BungeeCore.properties index 3dd9704..ee300bf 100644 --- a/src/de/steamwar/messages/BungeeCore.properties +++ b/src/de/steamwar/messages/BungeeCore.properties @@ -162,11 +162,11 @@ NOFIGHTSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lKämpfen§7 ausgeschl UNNOFIGHTSERVER_ERROR=§cDer Spieler ist nicht vom Kämpfen ausgeschlossen. UNNOFIGHTSERVER=§e{0} §7darf nun wieder §e§lKämpfen§7 beitreten§8. -NOTEAMSERVERSET_TEAM={0} §e{1} §7wurde von §e{2} {3} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §f{4} -NOTEAMSERVERSET_PERMA=§7Du bist §epermanent §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{0} -NOTEAMSERVERSET_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{1} -UNNOTEAMSERVERSET_ERROR=§cDer Spieler ist nicht vom Teamserver setzten ausgeschlossen. -UNNOTEAMSERVERSET=§e{0} §7darf nun wieder §e§lTeamserver§7 setzen§8. +NOTEAMSERVER_TEAM={0} §e{1} §7wurde von §e{2} {3} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §f{4} +NOTEAMSERVER_PERMA=§7Du bist §epermanent §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{0} +NOTEAMSERVER_UNTIL=§7Du bist §ebis zum {0} §7vom §e§lTeamserver§7 setzen ausgeschlossen§8. §7Grund§8: §e{1} +UNNOTEAMSERVER_ERROR=§cDer Spieler ist nicht vom Teamserver setzten ausgeschlossen. +UNNOTEAMSERVER=§e{0} §7darf nun wieder §e§lTeamserver§7 setzen§8. NOTE_TEAM={0} §e{1} §7erhielt von §e{2} {3} §7die §e§lNotiz§7§8: §f{4}