Skip to content

Commit

Permalink
Add some scoreboard team debug
Browse files Browse the repository at this point in the history
  • Loading branch information
fullwall committed Sep 13, 2023
1 parent bec5329 commit 2931f95
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
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;

Expand Down Expand Up @@ -72,6 +73,7 @@ public void createTeam(String entityName) {
clearClientTeams(team);
}
team.addEntry(entityName);
Messaging.debug("Created team", teamName, "with entity", entityName);
}

public ChatColor getColor() {
Expand Down Expand Up @@ -107,8 +109,10 @@ public void onDespawn(DespawnReason reason) {
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);
}
Expand All @@ -129,7 +133,6 @@ public void onSpawn() {
SUPPORT_TAGS = false;
}
}

}

public void setColor(ChatColor color) {
Expand Down

0 comments on commit 2931f95

Please sign in to comment.