Esempio n. 1
0
 public void UpdateFrame()
 {
     if (this.isReplay)
     {
         for (byte i = 0; i < Singleton <FrameSynchr> .GetInstance().FrameSpeed; i = (byte)(i + 1))
         {
             if (!MonoSingleton <GameLoader> .GetInstance().isLoadStart)
             {
                 CSPkg pkg;
                 CSDT_FRAPBOOT_INFO csdt_frapboot_info;
                 if (this.LoadMsg(out pkg, out csdt_frapboot_info))
                 {
                     if (csdt_frapboot_info != null)
                     {
                         uint dwKFrapsNo = csdt_frapboot_info.dwKFrapsNo;
                         FrameWindow.HandleFraqBootInfo(csdt_frapboot_info);
                         if (this.replayStream == null)
                         {
                             Singleton <FrameSynchr> .GetInstance().SetKeyFrameIndex(dwKFrapsNo + 150);
                         }
                     }
                     else if (pkg != null)
                     {
                         this.DirectHandleMsg(pkg);
                     }
                     continue;
                 }
                 this.StopReplay();
             }
             break;
         }
     }
 }
 public void UpdateFrame()
 {
     if (!this.IsReplaying)
     {
         return;
     }
     for (byte b = 0; b < Singleton <FrameSynchr> .GetInstance().FrameSpeed; b += 1)
     {
         if (MonoSingleton <GameLoader> .GetInstance().isLoadStart)
         {
             break;
         }
         CSPkg cSPkg;
         CSDT_FRAPBOOT_INFO cSDT_FRAPBOOT_INFO;
         if (!this.LoadMsg(out cSPkg, out cSDT_FRAPBOOT_INFO))
         {
             this.StopReplay();
             break;
         }
         if (cSDT_FRAPBOOT_INFO != null)
         {
             uint dwKFrapsNo = cSDT_FRAPBOOT_INFO.dwKFrapsNo;
             FrameWindow.HandleFraqBootInfo(cSDT_FRAPBOOT_INFO);
             if (this.replayStream == null)
             {
                 Singleton <FrameSynchr> .GetInstance().SetKeyFrameIndex(dwKFrapsNo + 150u);
             }
         }
         else if (cSPkg != null)
         {
             this.DirectHandleMsg(cSPkg);
         }
     }
 }