mirror of
https://github.com/songoda/UltimateModeration.git
synced 2024-11-13 22:05:17 +01:00
Added spy permission for staff chat.
This commit is contained in:
parent
11e0d7e631
commit
1709251803
@ -107,7 +107,9 @@ public class GUIPunishments extends AbstractGUI {
|
||||
if (appliedPunishment.getPunishmentType() != PunishmentType.KICK) {
|
||||
lore.add("");
|
||||
lore.add(plugin.getLocale().getMessage("gui.punishments.duration"));
|
||||
lore.add("&7" + (appliedPunishment.getDuration() != -1 ? Methods.makeReadable(appliedPunishment.getDuration()) : plugin.getLocale().getMessage("gui.general.permanent")));
|
||||
lore.add("&7" + (appliedPunishment.getDuration() != -1
|
||||
? Methods.makeReadable(appliedPunishment.getDuration())
|
||||
: plugin.getLocale().getMessage("gui.general.permanent")));
|
||||
lore.add("");
|
||||
lore.add(plugin.getLocale().getMessage("gui.punishments.punisher"));
|
||||
lore.add("&7" + (appliedPunishment.getPunisher() == null ? "Console" : Bukkit.getOfflinePlayer(appliedPunishment.getPunisher()).getName()));
|
||||
|
@ -51,9 +51,8 @@ public class StaffChannel {
|
||||
|
||||
private void messageAll(String message) {
|
||||
chatLog.add(message);
|
||||
for (UUID uuid : members) {
|
||||
Player player = Bukkit.getPlayer(uuid);
|
||||
if (player == null) continue;
|
||||
for (Player player : Bukkit.getOnlinePlayers()) {
|
||||
if (!members.contains(player.getUniqueId()) && !player.hasPermission("um.staffchat.spy")) continue;
|
||||
player.sendMessage(Methods.formatText(message));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user