6970717273747576777879
for (ItemStack item : inventory) { if (item != null) { getHuman().dropItem(item); } } inventory.clear(); //Do not call super-close, DefaultWindow only pseudo-closes if (!(getPlayer().getEngine() instanceof Server)) { super.close(); }