mirror of
https://github.com/amalthea-mc/ShopChest.git
synced 2024-11-22 18:32:24 +00:00
Kill armor stands when removing
This commit is contained in:
parent
e6637b546e
commit
e359c3b21a
@ -173,6 +173,8 @@ public class ArmorStandWrapper {
|
|||||||
Method addEntityMethod = worldServerClass.getDeclaredMethod(Utils.getMajorVersion() == 8 ? "b" : "c", entityClass);
|
Method addEntityMethod = worldServerClass.getDeclaredMethod(Utils.getMajorVersion() == 8 ? "b" : "c", entityClass);
|
||||||
addEntityMethod.setAccessible(true);
|
addEntityMethod.setAccessible(true);
|
||||||
addEntityMethod.invoke(worldServerClass.cast(nmsWorld), entity);
|
addEntityMethod.invoke(worldServerClass.cast(nmsWorld), entity);
|
||||||
|
|
||||||
|
entityClass.getMethod("die").invoke(entity);
|
||||||
} catch (ReflectiveOperationException e) {
|
} catch (ReflectiveOperationException e) {
|
||||||
plugin.getLogger().severe("Could not remove hologram");
|
plugin.getLogger().severe("Could not remove hologram");
|
||||||
plugin.debug("Could not remove armor stand from entity lists");
|
plugin.debug("Could not remove armor stand from entity lists");
|
||||||
|
Loading…
Reference in New Issue
Block a user