예제 #1
0
 public void Read (TProtocol iprot)
 {
   TField field;
   iprot.ReadStructBegin();
   while (true)
   {
     field = iprot.ReadFieldBegin();
     if (field.Type == TType.Stop) { 
       break;
     }
     switch (field.ID)
     {
       case 1:
         if (field.Type == TType.I32) {
           Id = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 2:
         if (field.Type == TType.String) {
           Name = iprot.ReadString();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 3:
         if (field.Type == TType.String) {
           Desc = iprot.ReadString();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 4:
         if (field.Type == TType.I32) {
           SkillType = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 5:
         if (field.Type == TType.I32) {
           Level = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 6:
         if (field.Type == TType.I32) {
           MaxLevel = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 7:
         if (field.Type == TType.I32) {
           NextSkillId = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 8:
         if (field.Type == TType.I32) {
           ComperhendAble = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 9:
         if (field.Type == TType.I32) {
           TriggerId = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 10:
         if (field.Type == TType.I32) {
           TriggerRate = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 11:
         if (field.Type == TType.I32) {
           CostMP = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 12:
         if (field.Type == TType.List) {
           {
             SkillConditionList = new List<SkillBattleConditionData>();
             TList _list0 = iprot.ReadListBegin();
             for( int _i1 = 0; _i1 < _list0.Count; ++_i1)
             {
               SkillBattleConditionData _elem2 = new SkillBattleConditionData();
               _elem2 = new SkillBattleConditionData();
               _elem2.Read(iprot);
               SkillConditionList.Add(_elem2);
             }
             iprot.ReadListEnd();
           }
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 13:
         if (field.Type == TType.List) {
           {
             EnemyTargetList = new List<SkillTargetGetterData>();
             TList _list3 = iprot.ReadListBegin();
             for( int _i4 = 0; _i4 < _list3.Count; ++_i4)
             {
               SkillTargetGetterData _elem5 = new SkillTargetGetterData();
               _elem5 = new SkillTargetGetterData();
               _elem5.Read(iprot);
               EnemyTargetList.Add(_elem5);
             }
             iprot.ReadListEnd();
           }
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 14:
         if (field.Type == TType.List) {
           {
             FriendTargetList = new List<SkillTargetGetterData>();
             TList _list6 = iprot.ReadListBegin();
             for( int _i7 = 0; _i7 < _list6.Count; ++_i7)
             {
               SkillTargetGetterData _elem8 = new SkillTargetGetterData();
               _elem8 = new SkillTargetGetterData();
               _elem8.Read(iprot);
               FriendTargetList.Add(_elem8);
             }
             iprot.ReadListEnd();
           }
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 15:
         if (field.Type == TType.List) {
           {
             EffectList = new List<SkillBattleEffectData>();
             TList _list9 = iprot.ReadListBegin();
             for( int _i10 = 0; _i10 < _list9.Count; ++_i10)
             {
               SkillBattleEffectData _elem11 = new SkillBattleEffectData();
               _elem11 = new SkillBattleEffectData();
               _elem11.Read(iprot);
               EffectList.Add(_elem11);
             }
             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 1:
         if (field.Type == TType.I32) {
           Id = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 2:
         if (field.Type == TType.String) {
           Name = iprot.ReadString();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 3:
         if (field.Type == TType.String) {
           Desc = iprot.ReadString();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 4:
         if (field.Type == TType.I32) {
           ExtraCDRound = iprot.ReadI32();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 5:
         if (field.Type == TType.String) {
           ExtraCDDesc = iprot.ReadString();
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 6:
         if (field.Type == TType.List) {
           {
             EnemyTargetList = new List<SkillTargetGetterData>();
             TList _list16 = iprot.ReadListBegin();
             for( int _i17 = 0; _i17 < _list16.Count; ++_i17)
             {
               SkillTargetGetterData _elem18 = new SkillTargetGetterData();
               _elem18 = new SkillTargetGetterData();
               _elem18.Read(iprot);
               EnemyTargetList.Add(_elem18);
             }
             iprot.ReadListEnd();
           }
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 7:
         if (field.Type == TType.List) {
           {
             FriendTargetList = new List<SkillTargetGetterData>();
             TList _list19 = iprot.ReadListBegin();
             for( int _i20 = 0; _i20 < _list19.Count; ++_i20)
             {
               SkillTargetGetterData _elem21 = new SkillTargetGetterData();
               _elem21 = new SkillTargetGetterData();
               _elem21.Read(iprot);
               FriendTargetList.Add(_elem21);
             }
             iprot.ReadListEnd();
           }
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       case 8:
         if (field.Type == TType.List) {
           {
             EffectList = new List<SkillBattleEffectData>();
             TList _list22 = iprot.ReadListBegin();
             for( int _i23 = 0; _i23 < _list22.Count; ++_i23)
             {
               SkillBattleEffectData _elem24 = new SkillBattleEffectData();
               _elem24 = new SkillBattleEffectData();
               _elem24.Read(iprot);
               EffectList.Add(_elem24);
             }
             iprot.ReadListEnd();
           }
         } else { 
           TProtocolUtil.Skip(iprot, field.Type);
         }
         break;
       default: 
         TProtocolUtil.Skip(iprot, field.Type);
         break;
     }
     iprot.ReadFieldEnd();
   }
   iprot.ReadStructEnd();
 }