Package l2p.gameserver.model.items

Examples of l2p.gameserver.model.items.PcInventory.destroyItem()


            }
            if(item.isEquipped())
            {
              inv.unEquipItemInSlot(item.getEquipSlot());
            }
            inv.destroyItem(item, count, true);
          }
          else if(id.getId() == L2Item.ITEM_ID_CLAN_REPUTATION_SCORE)
          {
            activeChar.getClan().incReputation((int) -count, false, "MultiSell" + _listId);
            activeChar.sendPacket(new SystemMessage(SystemMessage.S1_POINTS_HAVE_BEEN_DEDUCTED_FROM_THE_CLAN_REPUTATION_SCORE).addNumber(count));
View Full Code Here


      return;
    }
    L2ItemInstance removedScroll, removedCatalyst = null;
    synchronized(inventory)
    {
      removedScroll = inventory.destroyItem(scroll.getObjectId(), 1, true);
      if(catalyst != null)
      {
        removedCatalyst = inventory.destroyItem(catalyst.getObjectId(), 1, true);
      }
    }
View Full Code Here

    synchronized(inventory)
    {
      removedScroll = inventory.destroyItem(scroll.getObjectId(), 1, true);
      if(catalyst != null)
      {
        removedCatalyst = inventory.destroyItem(catalyst.getObjectId(), 1, true);
      }
    }
    //tries enchant without scrolls
    if(removedScroll == null || catalyst != null && removedCatalyst == null)
    {
View Full Code Here

      {
        if(itemToEnchant.isEquipped())
        {
          inventory.unEquipItemInSlot(itemToEnchant.getEquipSlot());
        }
        L2ItemInstance destroyedItem = inventory.destroyItem(itemToEnchant.getObjectId(), 1, true);
        if(destroyedItem == null)
        {
          _log.warning("failed to destroy " + itemToEnchant.getObjectId() + " after unsuccessful enchant attempt by char " + activeChar.getName());
          activeChar.sendActionFailed();
          return;
View Full Code Here

    }
    Log.add(activeChar.getName() + "|Trying to attribute enchant|" + itemToEnchant.getItemId() + "|attribute:" + stone.getEnchantAttributeStoneElement(itemType2 == L2Item.TYPE2_SHIELD_ARMOR) + "|" + itemToEnchant.getObjectId(), "enchants");
    L2ItemInstance removedStone;
    synchronized(inventory)
    {
      removedStone = inventory.destroyItem(stone.getObjectId(), 1, true);
    }
    if(removedStone == null)
    {
      activeChar.sendActionFailed();
      return;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.