示例#1
0
        private void OnBidHouseItemRemoved(BidHouseItem item, BidHouseCategory category, bool categoryDeleted)
        {
            if (!Types.Contains((int)item.Template.TypeId))
            {
                return;
            }

            if (!BidHouseManager.Instance.GetBidHouseCategories(item.Template.Id, MaxItemLevel).Any())
            {
                CurrentViewedItem = 0;
                InventoryHandler.SendExchangeBidHouseGenericItemRemovedMessage(Character.Client, item);
                UpdateCurrentViewedItem(item.Template.Id);

                return;
            }

            if (CurrentViewedItem != item.Template.Id)
            {
                return;
            }

            if (categoryDeleted)
            {
                InventoryHandler.SendExchangeBidHouseInListRemovedMessage(Character.Client, category);
            }
            else
            {
                InventoryHandler.SendExchangeBidHouseInListUpdatedMessage(Character.Client, category);
            }
        }
示例#2
0
 public static void SendExchangeBidHouseInListUpdatedMessage(IPacketReceiver client, BidHouseCategory category)
 {
     client.Send(new ExchangeBidHouseInListUpdatedMessage(category.Id, category.TemplateId, category.Effects.Select(x => x.GetObjectEffect()), category.GetPrices()));
 }
示例#3
0
 public static void SendExchangeBidHouseInListRemovedMessage(IPacketReceiver client, BidHouseCategory category)
 {
     client.Send(new ExchangeBidHouseInListRemovedMessage(category.Id));
 }