mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2024-11-26 12:46:04 +01:00
Add some scoreboard team debug
This commit is contained in:
parent
bec532952a
commit
2931f95939
@ -22,6 +22,7 @@ import net.citizensnpcs.api.npc.NPC;
|
||||
import net.citizensnpcs.api.persistence.Persist;
|
||||
import net.citizensnpcs.api.trait.Trait;
|
||||
import net.citizensnpcs.api.trait.TraitName;
|
||||
import net.citizensnpcs.api.util.Messaging;
|
||||
import net.citizensnpcs.util.NMS;
|
||||
import net.citizensnpcs.util.Util;
|
||||
|
||||
@ -72,6 +73,7 @@ public class ScoreboardTrait extends Trait {
|
||||
clearClientTeams(team);
|
||||
}
|
||||
team.addEntry(entityName);
|
||||
Messaging.debug("Created team", teamName, "with entity", entityName);
|
||||
}
|
||||
|
||||
public ChatColor getColor() {
|
||||
@ -107,8 +109,10 @@ public class ScoreboardTrait extends Trait {
|
||||
if (team.getSize() == 1) {
|
||||
clearClientTeams(team);
|
||||
team.unregister();
|
||||
Messaging.debug("Removed team", teamName);
|
||||
} else {
|
||||
team.removeEntry(name);
|
||||
Messaging.debug("Removed team entry", name, "from", teamName);
|
||||
}
|
||||
}, reason == DespawnReason.DEATH && npc.getEntity() instanceof LivingEntity ? 20 : 2);
|
||||
}
|
||||
@ -129,7 +133,6 @@ public class ScoreboardTrait extends Trait {
|
||||
SUPPORT_TAGS = false;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public void setColor(ChatColor color) {
|
||||
|
Loading…
Reference in New Issue
Block a user