Beispiel #1
0
 public void Write(DWriter wtr)
 {
     wtr.Write((byte)this.StatsType);
     if (IsUTFData())
     {
         wtr.WriteUTF(this.obf2);
     }
     else
     {
         wtr.Write(this.obf1);
     }
 }
Beispiel #2
0
        public void Write(DWriter wtr)
        {
            wtr.Write(Id);
            Position.Write(wtr);

            wtr.Write((short)Stats.Length);
            foreach (var i in Stats)
            {
                wtr.Write((byte)i.Key);
                if (i.Value is string)
                {
                    wtr.WriteUTF(i.Value as string);
                }
                else
                {
                    wtr.Write((int)i.Value);
                }
            }
        }