예제 #1
0
 public static void WritePlayerLiteInfo(this PacketWriter writer, PlayerLiteInfo info)
 {
     writer.WritePlayerID(info.PlayerID);
     writer.WriteUInt16(info.SummonorLevel);
     writer.WriteUInt32(info.SummonorSpell1);
     writer.WriteUInt32(info.SummonorSpell2);
     writer.WriteByte(info.Bitfield);
     writer.WriteTeamID(info.TeamId);
     writer.WriteFixedString(info.BotName, 64);
     writer.WriteFixedString(info.BotSkinName, 64);
     writer.WriteFixedString(info.EloRanking, 16);
     writer.WriteInt32(info.BotSkinID);
     writer.WriteInt32(info.BotDifficulty);
     writer.WriteInt32(info.ProfileIconId);
     writer.WriteByte(info.AllyBadgeID);
     writer.WriteByte(info.EnemyBadgeID);
 }
예제 #2
0
        public static PlayerLiteInfo ReadPlayerLiteInfo(this PacketReader reader)
        {
            var info = new PlayerLiteInfo();

            info.PlayerID       = reader.ReadPlayerID();
            info.SummonorLevel  = reader.ReadUInt16();
            info.SummonorSpell1 = reader.ReadUInt32();
            info.SummonorSpell2 = reader.ReadUInt32();
            info.Bitfield       = reader.ReadByte();
            info.TeamId         = reader.ReadTeamID();
            info.BotName        = reader.ReadFixedString(64);
            info.BotSkinName    = reader.ReadFixedString(64);
            info.EloRanking     = reader.ReadFixedString(16);
            info.BotSkinID      = reader.ReadInt32();
            info.BotDifficulty  = reader.ReadInt32();
            info.ProfileIconId  = reader.ReadInt32();
            info.AllyBadgeID    = reader.ReadByte();
            info.EnemyBadgeID   = reader.ReadByte();
            return(info);
        }