public void AddHealth(int amount) { enemy.AddHealth(amount); if (enemy.GetHealth() < enemy.GetMaxHealth() && healthBar == null) { healthBar = Instantiate(healthBarPrefab, Game.progressCanvas.transform); healthBar.GetComponent <HealthScript>().healthable = enemy; } }
public static void AddHealth(int amount) { // Enemy.AddHealth(amount); EnemyInstance.AddHealth(amount); }