Exemplo n.º 1
0
 public void Deinitilize()
 {
     if (_timeObject != null)
     {
         _timeObject.OnTimeUpdateHandler -= TimeUpdate;
         _timeObject.OnForwardHandler    -= OnForward;
         _timeObject.OnBackwardHandler   -= OnBackward;
         _timeObject.OnPauseHandler      -= OnPause;
         _timeObject = null;
     }
 }
Exemplo n.º 2
0
 public void Initilize()
 {
     if (_timeObject == null)
     {
         _timeObject = gameObject.GetComponent <TimeObjectComponent>();
         _timeObject.OnTimeUpdateHandler += TimeUpdate;
         _timeObject.OnForwardHandler    += OnForward;
         _timeObject.OnBackwardHandler   += OnBackward;
         _timeObject.OnPauseHandler      += OnPause;
     }
 }