mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-12-01 17:36:46 +01:00
Step two
This commit is contained in:
parent
ccdab96650
commit
f9a73c38d8
@ -8,6 +8,7 @@ import org.bukkit.event.Listener;
|
||||
|
||||
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
|
||||
import com.gmail.nossr50.util.player.UserManager;
|
||||
import com.gmail.nossr50.util.scoreboards.ScoreboardManager;
|
||||
|
||||
import org.kitteh.tag.AsyncPlayerReceiveNameTagEvent;
|
||||
|
||||
@ -32,6 +33,7 @@ public class TagListener implements Listener {
|
||||
|
||||
if (colorlessTag.equals(player.getName()) && (mcMMOPlayer.getNameTag() == null || !mcMMOPlayer.getNameTag().equals(tag))) {
|
||||
mcMMOPlayer.setNameTag(tag);
|
||||
ScoreboardManager.tagUpdate(player);
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -224,6 +224,15 @@ public class ScoreboardManager {
|
||||
}
|
||||
}
|
||||
|
||||
// Called by internal TagAPI event listener
|
||||
public static void tagUpdate(Player player) {
|
||||
String playerName = player.getName();
|
||||
|
||||
if (Config.getInstance().getPowerLevelTagsEnabled() && !dirtyPowerLevels.contains(playerName)) {
|
||||
dirtyPowerLevels.add(playerName);
|
||||
}
|
||||
}
|
||||
|
||||
// **** Setup methods **** //
|
||||
|
||||
public static void enablePlayerSkillScoreboard(Player player, SkillType skill) {
|
||||
|
Loading…
Reference in New Issue
Block a user