Exemple #1
0
        //called when all of the missions in the scenario are completed
        public void OnSuccess()
        {
            currMissionID--; //so we can see the last mission on the UI menu
            RefreshUI();

            status = ScenarioStatus.success;
            CustomEvents.OnScenarioSuccess(scenario); //trigger custom event

            gameMgr.WinGame();                        //player wins the game

            if (save)                                 //if saving is enabled
            {
                MissionSaveLoad.SaveScenario(scenario.GetCode(), true);
            }
        }