Example #1
0
 public override void Update(UI.IInvalidator invalidator, Model.LiveSplitState state, float width, float height, UI.LayoutMode mode)
 {
     if (info != null && !info.GameProcess.HasExited)
     {
         info.Update();
         if (state.CurrentSplitIndex + 1 < eventList.Length && eventList[state.CurrentSplitIndex + 1].HasOccured(info))
         {
             if (state.CurrentPhase == TimerPhase.NotRunning)
             {
                 state.IsGameTimePaused = false;
                 model.Start();
             }
             else
             {
                 model.Split();
             }
         }
         
         if (settings.PauseGameTime)
         {
             state.IsGameTimePaused = !info.InGame || info.InIntermission;
         }
     }
     else
     {
         Process gameProcess = Process.GetProcessesByName("q2pro").FirstOrDefault();
         if (gameProcess != null && !gameProcess.HasExited)
         {
             info = new GameInfo(gameProcess);
         }
         else
         {
             info = null;
         }
     }
 }
Example #2
0
 public override bool HasOccured(GameInfo info)
 {
     return (info.PrevGameState != 7) && info.InGame && (info.CurrMap == map.name);
 }
Example #3
0
 public override bool HasOccured(GameInfo info)
 {
     return false;
 }
Example #4
0
 public abstract bool HasOccured(GameInfo info);