- Joined
- May 15, 2009
- Messages
- 192
I have tried to create a trigger that, when you activate an ability, switches the hero for another one. That hero will then be able to switch back. I want to retain the levels of the abilities that each hero has learned, for starters I just used a Death Knight and a Paladin.
I have two problems, first of all the unit group doesn't seem to work. And second of all, the levels of the abilities are never applied.
Help appreciated
I have two problems, first of all the unit group doesn't seem to work. And second of all, the levels of the abilities are never applied.
-
Shift On
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Side Shift Channel (DK)
-
Actions
- Set Spell1_Level = (Level of Holy Light for (Triggering unit))
- Set Spell2_Level = (Level of Divine Shield for (Triggering unit))
- Set Spell3_Level = (Level of Devotion Aura for (Triggering unit))
- Custom script: set bj_wantDestroyGroup = true
-
Unit Group - Pick every unit in (Units in (Playable map area) matching ((Unit-type of (Matching unit)) Equal to Death Knight)) and do (Actions)
-
Loop - Actions
- Unit - Set level of Death Coil for (Picked unit) to Spell1_Level
- Unit - Set level of Death Pact for (Picked unit) to Spell2_Level
- Unit - Set level of Unholy Aura for (Picked unit) to Spell3_Level
- Unit - Change ownership of (Picked unit) to Player 1 (Red) and Change color
- Unit - Unhide (Picked unit)
- Unit - Make (Picked unit) Vulnerable
-
Loop - Actions
- Unit - Change ownership of (Triggering unit) to Neutral Passive and Change color
- Unit - Make (Triggering unit) Invulnerable
- Unit - Hide (Triggering unit)
-
Events
Help appreciated