Ejemplo n.º 1
0
        //Bank
        public void SendBankQuery()
        {
            PacketWriter writer = new PacketWriter(Opcodes.SMSG_GuildBankQuery);

            uint itemcount = 0; //temp
            uint tabcount  = (uint)BankTabList.Count();

            writer.WriteBit(false); //unk
            writer.WriteBits(itemcount, 20);
            writer.WriteBits(tabcount, 22);

            //for (var i = 0; i < itemcount; ++i)
            //enchants[i] = packet.ReadBits(24); // Number of Enchantments ?
            foreach (BankTab tab in BankTabList)
            {
                writer.WriteBits(tab.Icon.Length, 9);
                writer.WriteBits(tab.Text.Length, 7);
            }

            foreach (BankTab tab in BankTabList)
            {
                writer.WriteString(tab.Icon);
                writer.WriteUInt32(tab.TabId);//index
                writer.WriteString(tab.Text);
            }

            writer.WriteUInt64(BankMoney);

            for (var i = 0; i < itemcount; ++i)
            {
                for (var j = 0; j < 0; ++j) //enchants number
                {
                    //packet.ReadUInt32("Enchantment Slot Id?", i, j);
                    //packet.ReadUInt32("Enchantment Id?", i, j);
                }
                //packet.ReadUInt32("Unk UInt32 1", i); // Only seen 0
                //packet.ReadUInt32("Unk UInt32 2", i); // Only seen 0
                //packet.ReadUInt32("Unk UInt32 3", i); // Only seen 0
                //packet.ReadUInt32("Stack Count", i);
                //packet.ReadUInt32("Slot Id", i);
                //packet.ReadEnum<UnknownFlags>("Unk mask", TypeCode.UInt32, i);
                //packet.ReadEntryWithName<Int32>(StoreNameType.Item, "Item Entry", i);
                //packet.ReadInt32("Random Item Property Id", i);
                //packet.ReadUInt32("Spell Charges", i);
                //packet.ReadUInt32("Item Suffix Factor", i);
            }
            writer.WriteUInt32(0); //Tab ?
            writer.WriteUInt32(0); //remaining withdraw for the member
        }
Ejemplo n.º 2
0
 public int GetBankTabSize()
 {
     return(BankTabList.Count());
 }