Exemple #1
0
 public static void Skip(BinaryReader aBinaryReader, int aVersion)
 {
     if (aVersion >= 100)
     {
         aBinaryReader.ReadBoolean();
         int num = aBinaryReader.ReadInt16();
         for (int i = 0; i < num; i++)
         {
             aBinaryReader.ReadString();
             LevelWord.Skip(aBinaryReader, aVersion);
         }
         num = aBinaryReader.ReadInt16();
         for (int j = 0; j < num; j++)
         {
             aBinaryReader.ReadString();
         }
         aBinaryReader.ReadInt16();
         aBinaryReader.ReadInt16();
         aBinaryReader.ReadInt16();
         aBinaryReader.ReadBoolean();
         aBinaryReader.ReadInt16();
     }
     if (aVersion >= 101)
     {
         aBinaryReader.ReadInt16();
     }
 }
Exemple #2
0
 public void Load(BinaryReader aBinaryReader, int aVersion)
 {
     if (aVersion >= 100)
     {
         isCompleted = aBinaryReader.ReadBoolean();
         int num = aBinaryReader.ReadInt16();
         for (int i = 0; i < num; i++)
         {
             string value = aBinaryReader.ReadString();
             bool   flag  = true;
             foreach (LevelWord word in words)
             {
                 if (word.word.Equals(value))
                 {
                     word.Load(aBinaryReader, aVersion);
                     flag = false;
                     break;
                 }
             }
             if (flag)
             {
                 LevelWord.Skip(aBinaryReader, aVersion);
             }
         }
         num = aBinaryReader.ReadInt16();
         for (int j = 0; j < num; j++)
         {
             extraWords.Add(aBinaryReader.ReadString());
         }
         stats.coins        = aBinaryReader.ReadInt16();
         stats.pointsNormal = aBinaryReader.ReadInt16();
         stats.pointsExtra  = aBinaryReader.ReadInt16();
         stats.isPerfect    = aBinaryReader.ReadBoolean();
         stats.valid        = aBinaryReader.ReadInt16();
     }
     if (aVersion >= 101)
     {
         hintTipIndex = aBinaryReader.ReadInt16();
     }
 }