How can i increase enemies health over time?
I currently have a game where I spawn in 5 hoardes of enemies every 10 seconds. However, they do not get stronger as time goes on. How would I achieve this?
public const float maxHealth = 100;
public float currentHealth = maxHealth;
I was thinking I could just call the script from the spawner and multiply the maxHealth by a multiplier and be done with it. I can't figure out a work around. Any help would be appreciated..
Comment
Answer by powernocx · Mar 30, 2019 at 10:27 PM
public double HPs = 200;
void Update () {
HPs = HPs + 0.01;
}
is that the right answer ?
Your answer
![](https://koobas.hobune.stream/wayback/20220612194558im_/https://answers.unity.com/themes/thub/images/avi.jpg)