Exemplo n.º 1
0
 /// <summary>
 /// Called on object enable. Resets all variables to their default values
 /// to ensure AI runs properly
 /// </summary>
 private void OnEnable()
 {
     states = GetComponent <ZarStates>();
     health = 10f;
     states.currentState = ZarStates.ZStates.SPAWN;
     target = GameObject.Find("PFB_Player");
 }
Exemplo n.º 2
0
 private void OnEnable()
 {
     projectile = Resources.Load <GameObject>("BasicProjectile");
     states     = transform.parent.parent.GetComponent <ZarStates>();
 }
Exemplo n.º 3
0
    private void OnEnable()
    {
        statesParent = GetComponent <ZarStates>();

        health = 100f;
    }