void Start() { adrenaline = gameObject.AddComponent<StatBar>(); adrenaline.Setup(100, 100, "Adrenaline"); health = gameObject.AddComponent<StatBar>(); health.Setup(100, 100, "Health"); aggression = gameObject.AddComponent<StatBar>(); aggression.Setup(100, 0, "Aggression"); }
void Awake() { enemyHealth = gameObject.AddComponent<StatBar>(); enemyHealth.Setup(100, 100, "Health"); spriteRenderer = spriteObj.GetComponent<SpriteRenderer>(); }