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