SteamWar/FightSystem
Archiviert
13
1

Fix NametagVisibility
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Lixfel 2023-03-11 21:14:19 +01:00
Ursprung bdb708a7a8
Commit 896665a405
2 geänderte Dateien mit 8 neuen und 1 gelöschten Zeilen

Datei anzeigen

@ -26,6 +26,7 @@ import de.steamwar.fightsystem.fight.Fight;
import de.steamwar.fightsystem.fight.FightTeam;
import de.steamwar.fightsystem.states.FightState;
import de.steamwar.fightsystem.states.StateDependentListener;
import de.steamwar.fightsystem.utils.BountifulWrapper;
import de.steamwar.fightsystem.utils.FlatteningWrapper;
import net.md_5.bungee.api.ChatMessageType;
import org.bukkit.Bukkit;
@ -47,11 +48,17 @@ import org.bukkit.event.inventory.InventoryPickupItemEvent;
import org.bukkit.event.player.*;
import org.bukkit.event.weather.WeatherChangeEvent;
import org.bukkit.event.world.WorldLoadEvent;
import org.bukkit.scoreboard.NameTagVisibility;
import org.bukkit.scoreboard.Team;
public class Permanent implements Listener {
private static final Team spectatorTeam = FightScoreboard.getBukkitTeam("Spectator");
static {
BountifulWrapper.impl.setNametagVisibility(spectatorTeam);
spectatorTeam.setNameTagVisibility(NameTagVisibility.NEVER);
}
public static Team getSpectatorTeam() {
return spectatorTeam;
}

Datei anzeigen

@ -70,7 +70,7 @@ public class PacketProcessor implements Listener {
private static final org.bukkit.scoreboard.Team team = FightScoreboard.getBukkitTeam("Replay");
static {
BountifulWrapper.impl.setNametagVisibility(team);
team.setNameTagVisibility(NameTagVisibility.HIDE_FOR_OTHER_TEAMS);
team.setNameTagVisibility(NameTagVisibility.NEVER);
}
private static PacketProcessor currentProcessor = null;