Volkof
Well-Known Member
- Reaction score
- 31
hello everyone,
I have this trigger which detects that when a hero with the item Lightning Spear attacks a target, that target will be chain lightninged.
It works if the Hero attacks, but it also fires when the Hero cast a damaging spell. Is there any way to make it only work for attacks and not spells?
Thanks in adv. (By th way. I dont want to use Orb of Lightning New)
I have this trigger which detects that when a hero with the item Lightning Spear attacks a target, that target will be chain lightninged.
It works if the Hero attacks, but it also fires when the Hero cast a damaging spell. Is there any way to make it only work for attacks and not spells?
Trigger:
- Lightning Spear Attack
- Events
- Unit - A unit Is attacked
- Conditions
- ((Attacking unit) has an item of type Lightning Spear) Equal to True
- ((Attacked unit) belongs to an enemy of (Owner of (Attacking unit))) Equal to True
- ((Attacked unit) is A structure) Equal to False
- ((Attacked unit) is in LightningSpear_TargetGroup) Equal to False
- Actions
- Game - Display to (All players) the text: Atack
- Set LightningSpear_TargetUnit = (Attacked unit)
- Trigger - Add to Lightning Spear Lightning <gen> the event (Unit - LightningSpear_TargetUnit Takes damage)
- Unit Group - Add LightningSpear_TargetUnit to LightningSpear_TargetGroup
- Events
Trigger:
- Lightning Spear Lightning
- Events
- Conditions
- ((Damage source) has an item of type Lightning Spear) Equal to True
- Actions
- Game - Display to (All players) the text: Lightning
- Unit - Create 1 Dummy Unit for (Owner of (Damage source)) at (Position of (Damage source)) facing Default building facing degrees
- Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
- Unit - Add Chain Lightning [Lightning Spear] to (Last created unit)
- Unit - Order (Last created unit) to Orc Far Seer - Chain Lightning (Attacked unit)
Thanks in adv. (By th way. I dont want to use Orb of Lightning New)