mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2025-01-16 21:21:23 +01:00
Call super remove(), fix trait loading bug
This commit is contained in:
parent
d0575e3e22
commit
4c022b1a37
Binary file not shown.
@ -101,6 +101,7 @@ public abstract class CitizensNPC extends AbstractNPC {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void remove() {
|
public void remove() {
|
||||||
|
super.remove();
|
||||||
manager.remove(this);
|
manager.remove(this);
|
||||||
if (isSpawned())
|
if (isSpawned())
|
||||||
despawn();
|
despawn();
|
||||||
|
@ -77,7 +77,7 @@ public class CitizensTraitManager implements TraitManager {
|
|||||||
if (clazz == null)
|
if (clazz == null)
|
||||||
return null;
|
return null;
|
||||||
Trait t = getTrait(clazz, npc);
|
Trait t = getTrait(clazz, npc);
|
||||||
t.setName(name);
|
//t.setName(name);
|
||||||
return (T) t;
|
return (T) t;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user