I am currently working for my custom spells in the items. I don't understand why it won't attack/damage picked units. Help me
, I'm just a newbie.
-
AHoD
-

Events
-


Unit - A unit Uses an item
-
-

Conditions
-


(Item-type of (Item being manipulated)) Equal to Arznot'c Hood of Destruction
-
-

Actions
-


Game - Display to (All players) the text: Spotted complete
-


Set AHoD_CreatedUnit = (Last created unit)
-


Set AHoD_PickedUnits = (Picked unit)
-


Set AHoD_UnitsManipulated = (Hero manipulating item)
-


Set AHoD_UnitsPosition = origin
-


Set AHoD_HealEffect = Abilities\Spells\Undead\VampiricAura\VampiricAuraTarget.mdl
-


Set AHoD_Enemys = (Units within (Random real number between 625.00 and 700.00) of (Position of AHoD_UnitsManipulated) matching ((AHoD_UnitsManipulated belongs to an enemy of (Owner of AHoD_PickedUnits)) Equal to True))
-


Set AHoD_EnemysCount = (Real((Number of units in AHoD_Enemys)))
-


Floating Text - Create floating text that reads (|c00FF0000 + ((String(AHoD_EnemysCount)) + |r)) above AHoD_UnitsManipulated with Z offset 0.00, using font size 12.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
-


Floating Text - Change (Last created floating text): Disable permanence
-


Floating Text - Change the lifespan of (Last created floating text) to 3.50 seconds
-


Floating Text - Change the fading age of (Last created floating text) to 0.00 seconds
-


Floating Text - Set the velocity of (Last created floating text) to 18.00 towards 90.00 degrees
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




AHoD_EnemysCount Greater than 10.00
-
-



Then - Actions
-




Unit - Set life of AHoD_UnitsManipulated to ((Life of AHoD_UnitsManipulated) + (10.00 x AHoD_EnemysCount))
-




Special Effect - Create a special effect attached to the AHoD_UnitsPosition of AHoD_UnitsManipulated using AHoD_HealEffect
-




Special Effect - Destroy (Last created special effect)
-




Game - Display to (All players) the text: heal
-
-



Else - Actions
-
-


Unit Group - Pick every unit in AHoD_Enemys and do (Actions)
-



Loop - Actions
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






(AHoD_PickedUnits belongs to an enemy of (Owner of AHoD_UnitsManipulated)) Equal to True
-
-





Then - Actions
-






Unit - Create 1 Dummy (Arcz) for (Owner of AHoD_UnitsManipulated) at (Position of AHoD_PickedUnits) facing (Position of AHoD_UnitsManipulated)
-






Unit - Cause AHoD_CreatedUnit to damage AHoD_PickedUnits, dealing (175.00 + (15.00 x AHoD_EnemysCount)) damage of attack type Chaos and damage type Normal
-






Special Effect - Create a special effect attached to the overhead of AHoD_PickedUnits using Abilities\Spells\Undead\DarkRitual\DarkRitualTarget.mdl
-






Special Effect - Destroy (Last created special effect)
-






Game - Display to (All players) the text: damage
-
-





Else - Actions
-
-
-
-


Unit Group - Remove all units from AHoD_Enemys
-


Game - Display to (All players) the text: remove complete
-
-
