I try to make spell likes Penitence in DotA and this is my GUI trigger
and second trigger
However its often cause my map lack and error. Can anyone help me turn it into JASS or make it less lack?
Code:
Impending Doom 1
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to [COLOR="Red"]Impending Doom [/COLOR]
Actions
Set [COLOR="red"]ImpendingDoom[/COLOR] = (Target unit of ability being cast)
Set [COLOR="red"]Impending[/COLOR] = (Casting unit)
Trigger - Add to Impending Doom 2 <gen> the event (Unit - ImpendingDoom Takes damage)
and second trigger
Code:
Impending Doom 2
Events
Conditions
And - All (Conditions) are true
Conditions
((Owner of (Damage source)) is an enemy of (Owner of ImpendingDoom)) Equal to True
([COLOR="red"]ImpendingDoom[/COLOR] has buff Impending Doom ) Equal to True
(Damage taken) Greater than 0.00
Actions
Special Effect - Create a special effect attached to the origin of ImpendingDoom using Abilities\Spells\Human\Feedback\SpellBreakerAttack.mdl
Unit - Create 1 Caster Dummy Small for (Owner of (Damage source)) at (Position of ImpendingDoom) facing (Position of ImpendingDoom)
Unit - Cause (Last created unit) to damage ImpendingDoom, dealing ((Damage taken) x (0.05 x (1.00 + (Real((Level of Hoof Stomp for Impending)))))) damage of attack type Spells and damage type Death
Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
However its often cause my map lack and error. Can anyone help me turn it into JASS or make it less lack?