Esempio n. 1
0
        public Behavior()
        {
            coroutines = new List <Coroutine>();

            if (HasMethod("Awake"))
            {
                Invoke("Awake");
            }

            BehaviorManager.SharedInstance().AddBehavior(this);
            this.started = false;
            this.enabled = true;
        }
Esempio n. 2
0
 public void Destroy()
 {
     //Remove from the behavior manager effectively killing this behavior
     BehaviorManager.SharedInstance().RemoveBehavior(this);
 }