Okay, I'm (still) trying to make my custom spell, Dark Infusion, it goes like this:
A friendly target is infused with dark power, draining it's lif by 8% per second, but gives an high bonus damage. WHen the unit dies, it will restore mana to nearby friendly units, and deal damage to nearby enemy units equal 100 x the level of the ability.
But my "explode-trigger" won't seem to work.
Periodic Damage-Trigger ... works.
Damage Bonus-Trigger ... works (Note that "DamageBonus (DarkInfusion)" is an item-aility)
Explode-Trigger ... won't work.
Also, I'd like to have tips about making some cool graphics for it ... thank you!
A friendly target is infused with dark power, draining it's lif by 8% per second, but gives an high bonus damage. WHen the unit dies, it will restore mana to nearby friendly units, and deal damage to nearby enemy units equal 100 x the level of the ability.
But my "explode-trigger" won't seem to work.
Periodic Damage-Trigger ... works.
Code:
DarkInfusion
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
Unit Group - Pick every unit in (Units in (Playable map area) matching (((Matching unit) has buff Dark Infusion ) Equal to True)) and do (Actions)
Loop - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) - ((Max life of (Picked unit)) x 0.08))
Damage Bonus-Trigger ... works (Note that "DamageBonus (DarkInfusion)" is an item-aility)
Code:
DarkInfusionCast
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Dark Infusion (Necrolord)
Actions
Unit - Add DamageBonus (DarkInfusion) to (Target unit of ability being cast)
Unit - Set level of DamageBonus (DarkInfusion) for (Target unit of ability being cast) to (Level of (Ability being cast) for (Casting unit))
Explode-Trigger ... won't work.
Code:
DarkInfusionDead
Events
Unit - A unit Dies
Conditions
((Dying unit) has buff Dark Infusion ) Equal to True
Actions
Unit Group - Pick every unit in (Units within 450.00 of (Position of (Dying unit)) matching ((Owner of (Matching unit)) Equal to (Owner of (Dying unit)))) and do (Actions)
Loop - Actions
Unit - Set life of (Picked unit) to ((Mana of (Picked unit)) + (100.00 x (Real((Level of DamageBonus (DarkInfusion) for (Triggering unit))))))
Unit Group - Pick every unit in (Units within 450.00 of (Position of (Dying unit)) matching ((Owner of (Matching unit)) Not equal to (Owner of (Dying unit)))) and do (Actions)
Loop - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) - (100.00 x (Real((Level of DamageBonus (DarkInfusion) for (Triggering unit))))))
Also, I'd like to have tips about making some cool graphics for it ... thank you!