Hey all,
I was making an ability similar to Backtrack (faceless void from dota) and i wanted that when spell is cast on target it will have higher chance to trigger and i wanted it to remove all negative buffs from target. But this seems work strange sometimes it triggers randomly sometime it triggers as attack deflect then spell is cast and other way. I cant find what cause this problem.
Game - Display to (All players) the text: Works attack!
Is just to check which part of trigger works
I was making an ability similar to Backtrack (faceless void from dota) and i wanted that when spell is cast on target it will have higher chance to trigger and i wanted it to remove all negative buffs from target. But this seems work strange sometimes it triggers randomly sometime it triggers as attack deflect then spell is cast and other way. I cant find what cause this problem.
-
Reverse 1
-
Events
- Unit - A unit Learns a skill
-
Conditions
- (Learned Hero Skill) Equal to Reverse Time
-
Actions
- Set ReverseLearn = (Learning Hero)
- Trigger - Add to Reverse 4 <gen> the event (Unit - ReverseLearn Takes damage)
- Trigger - Turn off (This trigger)
-
Events
-
Reverse 2
-
Events
- Unit - A unit Begins casting an ability
-
Conditions
- (Target unit of ability being cast) Equal to ReverseLearn
-
Actions
- Set ReverseTarget = (Target unit of ability being cast)
- Set ReverseChance[2] = ((Level of Reverse Time for ReverseTarget) x 10)
-
Events
-
Reverse 3
-
Events
- Unit - A unit Is attacked
-
Conditions
- (Attacked unit) Equal to ReverseLearn
-
Actions
- Set ReverseAttacked = (Attacked unit)
- Set ReverseChance[1] = ((Level of Reverse Time for ReverseAttacked) x 5)
-
Events
-
Reverse 4
- Events
- Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- ReverseAttacked Equal to ReverseLearn
- (Random integer number between 1 and 100) Less than or equal to ReverseChance[1]
-
Then - Actions
- Unit - Set life of ReverseAttacked to ((Life of ReverseAttacked) + (Damage taken))
- Special Effect - Create a special effect attached to the origin of ReverseAttacked using Abilities\Spells\NightElf\Blink\BlinkTarget.mdl
- Special Effect - Destroy (Last created special effect)
- Set ReverseAttacked = No unit
- Game - Display to (All players) the text: Works attack!
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- ReverseTarget Equal to ReverseLearn
- (Random integer number between 1 and 100) Less than or equal to ReverseChance[2]
-
Then - Actions
- Unit - Set life of ReverseTarget to ((Life of ReverseTarget) + (Damage taken))
- Special Effect - Create a special effect attached to the origin of ReverseTarget using Abilities\Spells\NightElf\Blink\BlinkTarget.mdl
- Special Effect - Destroy (Last created special effect)
- Unit - Remove Negative buffs from ReverseTarget
- Set ReverseTarget = No unit
- Game - Display to (All players) the text: Works spell!
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Game - Display to (All players) the text: Works attack!
Is just to check which part of trigger works