{
L2ItemInstance rhand = getInventory().getPaperdollItem(Inventory.PAPERDOLL_RHAND);
if (rhand != null)
{
L2ItemInstance[] unequipped = getInventory().unEquipItemInBodySlotAndRecord(rhand.getItem().getBodyPart());
InventoryUpdate iu = new InventoryUpdate();
for (L2ItemInstance element : unequipped)
iu.addModifiedItem(element);
sendPacket(iu);
}
}
// Remove Item CHEST
if(Config.REMOVE_CHEST_SUBCLASS)
{
L2ItemInstance chest = getInventory().getPaperdollItem(Inventory.PAPERDOLL_CHEST);
if (chest != null)
{
L2ItemInstance[] unequipped = getInventory().unEquipItemInBodySlotAndRecord(chest.getItem().getBodyPart());
InventoryUpdate iu = new InventoryUpdate();
for (L2ItemInstance element : unequipped)
iu.addModifiedItem(element);
sendPacket(iu);
}
}
// Remove Item LEG
if(Config.REMOVE_LEG_SUBCLASS)
{
L2ItemInstance legs = getInventory().getPaperdollItem(Inventory.PAPERDOLL_LEGS);
if (legs != null)
{
L2ItemInstance[] unequipped = getInventory().unEquipItemInBodySlotAndRecord(legs.getItem().getBodyPart());
InventoryUpdate iu = new InventoryUpdate();
for (L2ItemInstance element : unequipped)
iu.addModifiedItem(element);
sendPacket(iu);
}
}
if(getTotalSubClasses() == Config.ALLOWED_SUBCLASS || classIndex == 0)