示例#1
0
        protected override void On_GAME_GameStarted(AbstractGameMode gameMode)
        {
            base.On_GAME_GameStarted(gameMode);

            // TODO : Very dirty fix due to AI spawning late
            StartCoroutine(LateOnInitializePlayerStats(gameMode));
        }
示例#2
0
 public void Invoke_GAME_SetPlayersScores(AbstractGameMode gameMode)
 {
     if (GAME_SetPlayersScores != null)
     {
         GAME_SetPlayersScores.Invoke(gameMode);
     }
     DebugLog("Set Players Scores");
 }
示例#3
0
 public void Invoke_GAME_GameEnded(AbstractGameMode gameMode, bool wasAborted = false)
 {
     if (GAME_GameEnded != null)
     {
         GAME_GameEnded.Invoke(gameMode, wasAborted);
     }
     DebugLog("Game ended : " + gameMode.GameModeType + ". Aborted : " + wasAborted.ToString());
 }
示例#4
0
 public void Invoke_GAME_GameUnPaused(AbstractGameMode gameMode)
 {
     if (GAME_GameUnPaused != null)
     {
         GAME_GameUnPaused.Invoke(gameMode);
     }
     DebugLog("Game unpaused : " + gameMode.GameModeType);
 }
示例#5
0
        private IEnumerator LateOnInitializePlayerStats(AbstractGameMode gameMode)
        {
            yield return(new WaitForEndOfFrame());

            if (GameModeType == gameMode.GameModeType)
            {
                Debug.Log("Initializing player stats for : " + gameMode.GameModeType);
                InitializePlayerStats();
            }
        }
示例#6
0
 private void On_GAME_GameEnded(AbstractGameMode gameMode, bool wasAborted)
 {
     UpdateState(EAppState.IN_GAME_IN_OVER);
 }
示例#7
0
 private void On_GAME_GameUnPaused(AbstractGameMode gameMode)
 {
     UpdateState(EAppState.IN_GAME_IN_RUNNING);
 }
示例#8
0
 private void On_GAME_GamePaused(AbstractGameMode gameMode)
 {
     UpdateState(EAppState.IN_GAME_IN_PAUSED);
 }