Examples of addModifiedItem()


Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

          L2ItemInstance removedItem = _player.getInventory().destroyItemByItemId("", _itemId, 1, _player, null);
          if (!Config.FORCE_INVENTORY_UPDATE)
          {
            InventoryUpdate iu = new InventoryUpdate();
            if (removedItem.getCount() == 0) iu.addRemovedItem(removedItem);
            else iu.addModifiedItem(removedItem);

            _player.sendPacket(iu);
          }
          else _player.sendPacket(new ItemList(_player, true));
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

            item.setCustomType2(_cost[priceId - 1] / 100);
            player.getInventory().addItem("Race", item, player, this);
            InventoryUpdate iu = new InventoryUpdate();
            iu.addItem(item);
            L2ItemInstance adenaupdate = player.getInventory().getItemByItemId(57);
            iu.addModifiedItem(adenaupdate);
            player.sendPacket(iu);
            return;
        }
        html.replace("1race", String.valueOf(_raceNumber));
        html.replace("%objectId%", String.valueOf(getObjectId()));
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

      // Add item to Inventory and adjust update packet
      L2ItemInstance item = player.getInventory().addItem("Buy", seedId,
          count, player, target);

      if (item.getCount() > count)
        playerIU.addModifiedItem(item);
      else
        playerIU.addNewItem(item);

      // Send Char Buy Messages
      SystemMessage sm = null;
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

            removeItem(item.getObjectId(), -1, item.getCount());

            // Add changes to inventory update packets
            if (oldItem.getCount() > 0 && oldItem != newItem) ownerIU.addModifiedItem(oldItem);
            else ownerIU.addRemovedItem(oldItem);
            if (newItem.getCount() > item.getCount()) playerIU.addModifiedItem(newItem);
            else playerIU.addNewItem(newItem);

            // Send messages about the transaction to both players
            if (newItem.isStackable())
            {
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

            L2ItemInstance newItem = playerInventory.transferItem("PrivateStore", item.getObjectId(), item.getCount(), ownerInventory, player, _owner);
            if (newItem == null) return false;
            removeItem(-1, item.getItemId(), item.getCount());

            // Add changes to inventory update packets
            if (oldItem.getCount() > 0 && oldItem != newItem) playerIU.addModifiedItem(oldItem);
            else playerIU.addRemovedItem(oldItem);
            if (newItem.getCount() > item.getCount()) ownerIU.addModifiedItem(newItem);
            else ownerIU.addNewItem(newItem);

            // Send messages about the transaction to both players
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

    for (int i = 0; i < unequiped.length; i++)
    {
            activeChar.checkSSMatch(null, unequiped[i]);

      iu.addModifiedItem(unequiped[i]);
    }

    activeChar.sendPacket(iu);

    activeChar.abortAttack();
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

                if (item.isEquipped())
                {
                    InventoryUpdate iu = new InventoryUpdate();
                    for (int i = 0; i < unequiped.length; i++)
                    {
                        iu.addModifiedItem(unequiped[i]);
                    }
                    activeChar.sendPacket(iu);
               
                    activeChar.broadcastUserInfo();
                }
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

   
                if (!Config.FORCE_INVENTORY_UPDATE)
                {
                    InventoryUpdate iu = new InventoryUpdate();
                    if (destroyItem.getCount() == 0) iu.addRemovedItem(destroyItem);
                    else iu.addModifiedItem(destroyItem);
                    iu.addItem(crystals);
                   
                    activeChar.sendPacket(iu);
                }
                else activeChar.sendPacket(new ItemList(activeChar, true));
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

              continue;
            }

            if (playerIU != null)
            {
              if (oldItem.getCount() > 0 && oldItem != newItem) playerIU.addModifiedItem(oldItem);
              else playerIU.addRemovedItem(oldItem);
            }
    }

        // Send updated item list to the player
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.InventoryUpdate.addModifiedItem()

      InventoryUpdate iu = new InventoryUpdate();
      for (int i = 0; i < unequiped.length; i++)
      {
        activeChar.checkSSMatch(null, unequiped[i]);

        iu.addModifiedItem(unequiped[i]);
      }
      activeChar.sendPacket(iu);
      activeChar.broadcastUserInfo();

      ItemList il = new ItemList(activeChar, true);
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.