Documentation for the Unity C# Library
Loading...
Searching...
No Matches
StopTimer.cs
Go to the documentation of this file.
1using System;
2using System.Collections;
3using System.Collections.Generic;
4using UnityEngine;
5
6namespace PixoVR.Event
7{
11 public class StopTimer : IStep
12 {
13 public event Action OnFunctionFinished;
14 public void StartStep(StepItem stepItem, StepFunction function, List<InteractableClass> interactables = null, Action onStepSkipped = null)
15 {
16 if(interactables == null) return;
17
18 foreach (var interactable in interactables)
19 {
20 interactable.StopTimer();
21 }
22
24 }
25
26 public void FunctionFinished()
27 {
28 OnFunctionFinished?.Invoke();
29 }
30 }
31}
[Serializable]
Definition StepItem.cs:12
Stop function of cyclically launching the method after some time specified in the steplist.
Definition StopTimer.cs:12
void FunctionFinished()
Called to end current step and start a next one.
Definition StopTimer.cs:26
void StartStep(StepItem stepItem, StepFunction function, List< InteractableClass > interactables=null, Action onStepSkipped=null)
Definition StopTimer.cs:14
Basic interface of functions. (Please note that iStep is a wrong name)
Definition IStep.cs:10