public void setEntityDead() { super.setEntityDead(); inventorySlots.onCraftGuiClosed(this); if (craftingInventory != null) { craftingInventory.onCraftGuiClosed(this); } }