Beispiel #1
0
 public DictDrop(ulong id, ushort dropType, DictMapPairValue rewards, string rewardsText, string desc)
 {
     this.id          = id;
     this.dropType    = dropType;
     this.rewards     = rewards;
     this.rewardsText = rewardsText;
     this.desc        = desc;
 }
Beispiel #2
0
 public DictDrop()
 {
     id          = 0;
     dropType    = 0;
     rewards     = new DictMapPairValue();
     rewardsText = "";
     desc        = "";
 }
Beispiel #3
0
 public int __decode(byte[] binData, ref int pos)
 {
     this.id       = Proto4z.BaseProtoObject.decodeUI64(binData, ref pos);
     this.dropType = Proto4z.BaseProtoObject.decodeUI16(binData, ref pos);
     this.rewards  = new DictMapPairValue();
     this.rewards.__decode(binData, ref pos);
     this.rewardsText = Proto4z.BaseProtoObject.decodeString(binData, ref pos);
     this.desc        = Proto4z.BaseProtoObject.decodeString(binData, ref pos);
     return(pos);
 }
Beispiel #4
0
        public System.Collections.Generic.List <byte> __encode()
        {
            var data = new System.Collections.Generic.List <byte>();

            data.AddRange(Proto4z.BaseProtoObject.encodeUI64(this.id));
            data.AddRange(Proto4z.BaseProtoObject.encodeUI16(this.dropType));
            if (this.rewards == null)
            {
                this.rewards = new DictMapPairValue();
            }
            data.AddRange(this.rewards.__encode());
            data.AddRange(Proto4z.BaseProtoObject.encodeString(this.rewardsText));
            data.AddRange(Proto4z.BaseProtoObject.encodeString(this.desc));
            return(data);
        }