I'm not sure. I didn't think to try that out, but I did figure out a solution to the problem. I'll post them here.
There are many triggers, one each for the train, research, and revive "begins" and "cancels" commands, and one for all three "finish" commands.
Quote:
Code:
Ziggurat researching begins
Events
Unit - A unit Begins research
Conditions
(Race of (Owner of (Researching unit))) Equal to Orc
Actions
Set techArrayZigguratResearch[(Player number of (Owner of (Researching unit)))] = (Researched tech-type)
-------- research = 1, training = 2, reviving = 3 --------
Set intArrayTownHallEffect[(Player number of (Owner of (Researching unit)))] = 1
Wait 0.50 game-time seconds
Special Effect - Create a special effect attached to the origin of (Researching unit) using Abilities\Spells\Items\HealingSalve\HealingSalveTarget.mdl
Set specialEffectArrayTownHall[(Player number of (Owner of (Researching unit)))] = (Last created special effect)
|
Quote:
Code:
Ziggurat researching cancels
Events
Unit - A unit Cancels research
Conditions
(Researched tech-type) Equal to techArrayZigguratResearch[(Player number of (Owner of (Researching unit)))]
intArrayTownHallEffect[(Player number of (Owner of (Researching unit)))] Equal to 1
Actions
Special Effect - Destroy specialEffectArrayTownHall[(Player number of (Owner of (Researching unit)))]
|
Quote:
Code:
Ziggurat training begins
Events
Unit - A unit Begins training a unit
Conditions
(Race of (Owner of (Triggering unit))) Equal to Orc
Actions
Set unitArrayZigguratTraining[(Player number of (Owner of (Triggering unit)))] = (Unit-type of (Trained unit))
-------- research = 1, training = 2, reviving = 3 --------
Set intArrayTownHallEffect[(Player number of (Owner of (Triggering unit)))] = 2
Wait 0.50 game-time seconds
Special Effect - Create a special effect attached to the origin of (Triggering unit) using Abilities\Spells\Items\HealingSalve\HealingSalveTarget.mdl
Set specialEffectArrayTownHall[(Player number of (Owner of (Triggering unit)))] = (Last created special effect)
|
Quote:
Code:
Ziggurat training cancels
Events
Unit - A unit Cancels training a unit
Conditions
(Unit-type of (Trained unit)) Equal to unitArrayZigguratTraining[(Player number of (Owner of (Triggering unit)))]
intArrayTownHallEffect[(Player number of (Owner of (Trained unit)))] Equal to 2
Actions
Special Effect - Destroy specialEffectArrayTownHall[(Player number of (Owner of (Trained unit)))]
|
Quote:
Code:
Ziggurat reviving begins
Events
Unit - A unit Begins reviving
Conditions
(Race of (Owner of (Reviving Hero))) Equal to Orc
Actions
Set unitArrayZigguratTraining[(Player number of (Owner of (Reviving Hero)))] = (Unit-type of (Reviving Hero))
-------- research = 1, training = 2, reviving = 3 --------
Set intArrayTownHallEffect[(Player number of (Owner of (Reviving Hero)))] = 3
Wait 0.50 game-time seconds
Unit Group - Pick every unit in (Units owned by (Owner of (Reviving Hero)) matching (((Matching unit) is A structure) Equal to True)) and do (Actions)
Loop - Actions
Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Items\HealingSalve\HealingSalveTarget.mdl
Set specialEffectArrayTownHall[(Player number of (Owner of (Reviving Hero)))] = (Last created special effect)
|
Quote:
Code:
Ziggurat reviving cancels
Events
Unit - A unit Cancels reviving
Conditions
(Unit-type of (Reviving Hero)) Equal to unitArrayZigguratTraining[(Player number of (Owner of (Reviving Hero)))]
intArrayTownHallEffect[(Player number of (Owner of (Reviving Hero)))] Equal to 3
Actions
Special Effect - Destroy specialEffectArrayTownHall[(Player number of (Owner of (Reviving Hero)))]
|
Quote:
Code:
Ziggurat finishes
Events
Unit - A unit Finishes research
Unit - A unit Finishes training a unit
Unit - A unit Finishes reviving
Conditions
(Race of (Owner of (Triggering unit))) Equal to Orc
Actions
Special Effect - Destroy specialEffectArrayTownHall[(Player number of (Owner of (Triggering unit)))]
|
These seven triggers work flawlessly. However, if you're playing in a map where there's more than one structure, you'll want to have slightly different conditions. Also, if your building can train normal units, the training trigger will be insufficient, because you can cancel units that are the same unit-type as the unit currently under production.
However, for my purposes, it's ridiculously flaw-free, and I'm very happy with it.