Example #1
0
        public override void Read()
        {
            CustomizeInfo                   = new CharCustomizeInfo();
            CustomizeInfo.CharGUID          = _worldPacket.ReadPackedGuid();
            CustomizeInfo.SexID             = (Gender)_worldPacket.ReadUInt8();
            CustomizeInfo.SkinID            = _worldPacket.ReadUInt8();
            CustomizeInfo.HairColorID       = _worldPacket.ReadUInt8();
            CustomizeInfo.HairStyleID       = _worldPacket.ReadUInt8();
            CustomizeInfo.FacialHairStyleID = _worldPacket.ReadUInt8();
            CustomizeInfo.FaceID            = _worldPacket.ReadUInt8();

            for (var i = 0; i < CustomizeInfo.CustomDisplay.GetLimit(); ++i)
            {
                CustomizeInfo.CustomDisplay[i] = _worldPacket.ReadUInt8();
            }

            CustomizeInfo.CharName = _worldPacket.ReadString(_worldPacket.ReadBits <uint>(6));
        }
Example #2
0
        public override void Read()
        {
            CustomizeInfo          = new CharCustomizeInfo();
            CustomizeInfo.CharGUID = _worldPacket.ReadPackedGuid();
            CustomizeInfo.SexID    = (Gender)_worldPacket.ReadUInt8();
            var customizationCount = _worldPacket.ReadUInt32();

            for (var i = 0; i < customizationCount; ++i)
            {
                CustomizeInfo.Customizations[i] = new ChrCustomizationChoice()
                {
                    ChrCustomizationOptionID = _worldPacket.ReadUInt32(),
                    ChrCustomizationChoiceID = _worldPacket.ReadUInt32()
                };
            }

            CustomizeInfo.Customizations.Sort();

            CustomizeInfo.CharName = _worldPacket.ReadString(_worldPacket.ReadBits <uint>(6));
        }