Ejemplo n.º 1
0
        public static void HandleExchangeObjectTransfertExistingToInv(ExchangeObjectTransfertExistingToInvMessage message, WorldClient client)
        {
            AbstractTradeExchange   dialog          = client.Character.GetDialog <AbstractTradeExchange>();
            IEnumerable <ItemStack> allPresentItems = dialog.GetAllPresentItems();
            List <uint>             characterItems  = client.Character.Inventory.GetItems().ToList().ConvertAll(x => x.UId);

            foreach (ItemStack itemStack in allPresentItems)
            {
                if (characterItems.Contains(itemStack.ItemUId))
                {
                    dialog.MoveItem(itemStack.ItemUId, -1 * (int)itemStack.Quantity);
                }
            }
        }
Ejemplo n.º 2
0
        public static void HandleExchangeObjectTransfertExistingToInvMessage(WorldClient client, ExchangeObjectTransfertExistingToInvMessage message)
        {
            var bank = client.Character.Dialog as BankDialog;

            if (bank == null)
            {
                return;
            }

            bank.Customer.MoveItems(false, new int[0], false, true);
        }