
It looks like you're new here. If you want to get involved, click one of these buttons!
After following the tower defense tutorial, i want increase the enemy health after a certain amount of waves passed, for example after 10 waves, the enemy health will increase by 50.
Answers
Check if waves passed >= 10 then enemy.health += 50
//set a variable to set after how many waves you have to change the health
//Set a variable to count how much health to add
//Every wave you add 1 to a wave counter
local_wave++;
//Check if you passed enough waves, add some health to the enemy's max health and set the wave count to 0 again
If (local_wave >= wavesBeforeIncrease)
{
Enemy.MaxHealth+= HealthToIncrease;
local_wave = 0;
}