Example #1
0
 private void OnDestroy()
 {
     if (_current == this)
     {
         _current = null;
     }
 }
	void Awake()
	{
		if (_current == null)
		{
			_current = this;
		}
	}
Example #3
0
 private void OnDestroy()
 {
     if (RadicalRoutineHelper._current == this)
     {
         RadicalRoutineHelper._current = null;
     }
 }
 void Awake()
 {
     if (_current == null)
     {
         _current = this;
     }
 }
Example #5
0
 public void Run(string methodName, object target)
 {
     this.Method = methodName;
     this.Target = target;
     if (this.trackedObject != null)
     {
         RadicalRoutineHelper radicalRoutineHelper = this.trackedObject.GetComponent <RadicalRoutineHelper>() ?? this.trackedObject.gameObject.AddComponent <RadicalRoutineHelper>();
         radicalRoutineHelper.Run(this);
     }
     else
     {
         RadicalRoutineHelper.Current.Run(this);
     }
 }
 void OnDestroy()
 {
     if(_current == this)
         _current = null;
 }