HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Hero Defense - Best wa to do it?

03-16-2008, 10:52 AM#1
z3ryu
Hey all!
I just started mapping again and want to try something easy, like a hero defense.
Now i wonder whats the best way to check if all spawned units are dead and the next wave is supposed to spawn. I know there are multiple ways but i wanna know which is the easiest and best one to do it ^^
03-16-2008, 10:56 AM#2
RolePlaynGamer
Use an integer variable with the value of the creeps, and then when a unit die, set the integer to -1. Then use an if/then/else statement to do your actions if the integer is under a desired value.
03-16-2008, 10:58 AM#3
z3ryu
Okay guessed so ^^
Thanks for the fast answer,+rep
03-16-2008, 10:59 AM#4
RolePlaynGamer
Thanks =) Just pm me if you want a code or something.
03-16-2008, 01:48 PM#5
Pyrogasm
Using food is easier. Have each unit use 1 food, then when the food used of the player that controls the spawns is 0, start a new wave.
03-16-2008, 02:29 PM#6
Rising_Dusk
I agree, food is a cleaner and easier solution. I also find it funner if units spawn on a set timer rather than when the previous wave dies, it makes things more intense because there's a sense of immediacy and urgency added to the mix. I've always felt Hero D's should have those aspects to them.
03-16-2008, 02:44 PM#7
Pyrogasm
One thing I always thought might be interesting to do is have each type of unit maybe cost a differing amount of food depending on how "tough" it is to kill. So in a wave maybe you have 5 monsters that use 5 food each with 10 other monsters that use 2 food each.

Then say the trigger activates when food <= 5. So then you've got options as to which units to kill to complete the wave.