public void Read (TProtocol iprot) { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 10: if (field.Type == TType.I64) { MonsterUniqueId = iprot.ReadI64(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 20: if (field.Type == TType.List) { { DropItemList = new List<NetFramework.Auto.ItemInfo>(); TList _list76 = iprot.ReadListBegin(); for( int _i77 = 0; _i77 < _list76.Count; ++_i77) { NetFramework.Auto.ItemInfo _elem78 = new NetFramework.Auto.ItemInfo(); _elem78 = new NetFramework.Auto.ItemInfo(); _elem78.Read(iprot); DropItemList.Add(_elem78); } iprot.ReadListEnd(); } } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); }
public void Read (TProtocol iprot) { TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 10: if (field.Type == TType.I32) { TemplateId = iprot.ReadI32(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 20: if (field.Type == TType.I64) { UniqueId = iprot.ReadI64(); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 30: if (field.Type == TType.Struct) { Pos = new Common.Auto.ThriftVector3(); Pos.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 40: if (field.Type == TType.Struct) { Rot = new Common.Auto.ThriftVector3(); Rot.Read(iprot); } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 50: if (field.Type == TType.List) { { DropItemList = new List<NetFramework.Auto.ItemInfo>(); TList _list0 = iprot.ReadListBegin(); for( int _i1 = 0; _i1 < _list0.Count; ++_i1) { NetFramework.Auto.ItemInfo _elem2 = new NetFramework.Auto.ItemInfo(); _elem2 = new NetFramework.Auto.ItemInfo(); _elem2.Read(iprot); DropItemList.Add(_elem2); } iprot.ReadListEnd(); } } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); }