Scenario manager This class is meant to be extended, and its Scenario() method overridden to describe your own level's scenario.
More...
|
| virtual void | StopScenario () |
| | Use this method to stop the scenario from being evaluated.
|
|
| virtual void | Awake () |
| | On Awake, we initialize our scenario.
|
| virtual void | Start () |
| | On start, we create and fill the scenario.
|
| virtual void | Scenario () |
| | Describes the scenario.
|
| virtual void | AddTimeEvent (string timeInStringNotation, Action action, string eventName="") |
| | Adds an event to the scenario that will be triggered at the specified time.
|
| virtual void | AddScoreEvent (float startScore, Action action, string eventName="") |
| | Adds the score event.
|
| virtual void | EvaluateScenario () |
| | Evaluates the scenario, triggering events every time the level's running time is higher than their start time.
|
| virtual void | TestMethod (string someMessage) |
| | A test method that just displays the string passed as an argument. Just used for demo purposes.
|
Scenario manager This class is meant to be extended, and its Scenario() method overridden to describe your own level's scenario.
◆ AddScoreEvent()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.AddScoreEvent |
( |
float | startScore, |
|
|
Action | action, |
|
|
string | eventName = "" ) |
|
protectedvirtual |
Adds the score event.
- Parameters
-
| startScore | the minimum score for this event to happen. |
| action | Action. |
| eventName | The name of the MMEvent to trigger when that event is met. |
◆ AddTimeEvent()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.AddTimeEvent |
( |
string | timeInStringNotation, |
|
|
Action | action, |
|
|
string | eventName = "" ) |
|
protectedvirtual |
Adds an event to the scenario that will be triggered at the specified time.
- Parameters
-
| timeInStringNotation | Time in hh:mm:ss:SSS string notation. |
| action | Action. |
| eventName | The name of the MMEvent to trigger when that event is met. |
◆ Awake()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.Awake |
( |
| ) |
|
|
protectedvirtual |
On Awake, we initialize our scenario.
◆ EvaluateScenario()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.EvaluateScenario |
( |
| ) |
|
|
protectedvirtual |
Evaluates the scenario, triggering events every time the level's running time is higher than their start time.
◆ Scenario()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.Scenario |
( |
| ) |
|
|
protectedvirtual |
◆ Start()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.Start |
( |
| ) |
|
|
protectedvirtual |
On start, we create and fill the scenario.
◆ StopScenario()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.StopScenario |
( |
| ) |
|
|
virtual |
Use this method to stop the scenario from being evaluated.
◆ TestMethod()
| virtual void MoreMountains.InfiniteRunnerEngine.ScenarioManager.TestMethod |
( |
string | someMessage | ) |
|
|
protectedvirtual |
A test method that just displays the string passed as an argument. Just used for demo purposes.
- Parameters
-
◆ _scenario
| List<ScenarioEvent> MoreMountains.InfiniteRunnerEngine.ScenarioManager._scenario |
|
protected |
◆ EvaluationFrequency
| float MoreMountains.InfiniteRunnerEngine.ScenarioManager.EvaluationFrequency = 1 |
The frequency at which the scenario will be evaluated, in seconds.
◆ UseEventManager
| bool MoreMountains.InfiniteRunnerEngine.ScenarioManager.UseEventManager = true |
The documentation for this class was generated from the following file: