Don't register MobType class

This commit is contained in:
fullwall 2022-03-15 10:11:36 +08:00
parent 4bf4dc0651
commit 577dc72101
1 changed files with 3 additions and 2 deletions

View File

@ -354,9 +354,10 @@ public class CitizensNPC extends AbstractNPC {
@Override
public String toString() {
return getId() + "{" + getName() + ", " + getOrAddTrait(MobType.class).getType() + "}";
EntityType mobType = hasTrait(MobType.class) ? getTraitNullable(MobType.class).getType() : null;
return getId() + "{" + getName() + ", " + mobType + "}";
}
@Override
public void update() {
try {