I need help with this map I'm making. Obviously. Anyways, this map is going to be a part of a campaign I am creating and the map is very similar to Aeon of Strife. Lots of action, blood, etc.
I'm having trouble figuring out what to do to make units respawn at certain intervals at a time. Like I don't want units to keep respawning every 1 or 2 seconds, but at every 4-6 seconds instead. I used always as my condition and my actions were create this unit for this player at this location and preserve trigger.
Also, I want it so that say there is a Command Center and units respawn near it. If that particular CC is destroyed then the units stop respawning there. How do you do this?
Well set your condition for what ever you want then:
Creat x units at location y.
Wait 4-6 seconds
Preserve trigger.
And for your second question make it a switch.
to make your units respawn every 4-6 seconds, make this trigger:
| Trigger |
| Description: |
| yay! the units repswan every 5 seconds! |
|
| Players: |
| ¤ what ever player controls the units |
| Conditions: |
| ¤ always |
| Actions: |
¤ create x unit(s) at location y
|
¤ wait 5000 milliseconds (ms)
|
| ¤ preserve trigger |
This should answer your first question.
For your second question, you can use a switch, but it might complicate things. There is more than one way to do this, but for best results, use the trigger blow:
| Trigger |
| Description: |
| this trigger is a must if you want the trigger below to work properly. Please note this trigger will center on what ever command center is closest to the left side of the map, so I suggest you keep the current player from owning more than one cc at any given time. |
|
| Conditions: |
¤ elaspted time is at least 2 seconds
|
| ¤ current player brings at least 1 cc to "anywhere" |
| Actions: |
¤ center location on current player's cc
|
| ¤ preserve trigger |
| Trigger |
null| Players: |
| ¤ the player that owns the cc where you want the units to respawn |
| Conditions: |
| ¤ current player brings 1 cc to location "respawn" |
| Actions: |
¤ create unit x at location "respawn"
|
¤ wait x millieseconds (ms)
|
| ¤ preserve trigger |
you may want to use death counters to prevent an overlap of long waits.
now why the :

: would you want to do that? The triggers I listed won't have any wait overlaps.
well because of the fact that hes bound to have other waits running at the same time. using death counters would just resolve wait block problems hed encounter later in his map.
Thanks for the help! It works pretty good. How would I use the death counters though along with the triggers?
death counters would most likely complicate the problem and you may have to have multiple triggers. but since you got it working i dont think ill explain them.
Don't use Death Counters unless you are hypering the map and even then, you should only attempt such a thing if you are an advanced map maker for it is quite complicated. There is however a tutorial on the use of Death Counters.
http://www.staredit.net/index.php?act=tuto...eath%20CountersHere it is!
if you don't use death counters, the waits of different spawning places and units will stack up. In my Uprising, I had so many units that it took forever for them to spawn because of the waits. When I switched to death counters, everything was fine.