Code:
NEC Unholy Pact
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to NEC Unholy Pact
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Life of (Casting unit)) Greater than ((Max life of (Casting unit)) x 0.15)
Then - Actions
Unit - Set life of (Casting unit) to ((Life of (Casting unit)) - ((Max life of (Casting unit)) x 0.15))
Unit - Set mana of (Casting unit) to ((Mana of (Casting unit)) + ((Max mana of (Casting unit)) x 0.15))
Else - Actions
Game - Display to (All players) the text: You do not have enough hit points to cast this spell.
Unit - Remove NEC Unholy Pact from (Casting unit)
Unit - Add NEC Unholy Pact to (Casting unit)
when the hero has less than 15% hp it says "You do not have enough hit points to cast this spell." and NEC Unholy Pact is removed from the unit but it is not being added again. what wrong?


