I've got a couple of trigger design to hide a particular building and spawn a unit for that building, then after a condition is met the building is to reappear and the unit is to be removed. The triggers I have work fine when they first run, but on the second time around they don't hide the structure, but they still spawn the unit and I'm a little confused to why it won't hide them again.
Here is a look at a sample trigger:
Here is a look at a sample trigger:
Trigger:
- Spawn
- Events
- Conditions
- Actions
- pick every unit in Entire map owned by any plater Required: Structure Exclude dead missile Hidden.
- Actions
- If
- picked unit == marine (structure)
- then
- hide picked unit
- create 1 marine (unit) for owner of picked unit at position of picked unit
- else
- If
- create 10 larva for player 5 at center of region Spawn
- variable - set flag == 1
Trigger:
- Check Spawn
- Events
- every 5.0 sec Game Time
- Conditions
- and
- player 5 supply == 0
- player 10 supply == 0
- and
- Actions
- if
- flag == 1
- then
- pick every unit in Entire map owned by any player Exclude: dead missile, hidden, invulnerable, structure
- actions
- remove picked unit
- actions
- pick every unit in Entire Map owned by any player Required: hidden Exclude: missile dead
- actions
- show picked unit
- actions
- pick every unit in Entire map owned by any player Exclude: dead missile, hidden, invulnerable, structure
- variable - set flag = 0
- else
- if
- if
- counter == 12
- then
- run trigger Spawn Don't Wait
- else
- Variable - Set counter = (counter+1)
- Events