Very simple triggers so why the heck they don't work ?
1) Event: Unit - A unit is attacked
Actions: If((Owner of (attacked unit)) Equal to play 1 (Red)) then do (Floating Text - Create floating text that reads (String((Integar((Damage taken))))) above (Attacked unit) with Z offset 0.00, using font size 10.00, color (100.00%,0.00%,0.00%), and 40% transparency
This for some reason just shows "0" when a unit gets hit.
2) I tried to make a system that will make a unit take damage from spells according to attackers intelegence.
this is how I made it:
FIRST TRIGGER
Event: Every 0.01 sec
Actions: Set HeroIntelligence[1] = (Intelligence of Hero[1] (Include Bonuses))
SECOND TRIGGER
Event: A unit finishes casting an ability
Actions: Set CastingTarget = (Target unit of ability being cast)
If ((Ability being cast) Equal to Fire Ball)) then do (Unit - Set life of CastingTarget to ((Life of Casting Target)-(Real(HeroIntelligence[1]x2))))) else (Do nothing)
For some reason this does no damage to the spell target
Can someone help me please ?
PS: im very sorry I just forgot how to put triggers in the good way
1) Event: Unit - A unit is attacked
Actions: If((Owner of (attacked unit)) Equal to play 1 (Red)) then do (Floating Text - Create floating text that reads (String((Integar((Damage taken))))) above (Attacked unit) with Z offset 0.00, using font size 10.00, color (100.00%,0.00%,0.00%), and 40% transparency
This for some reason just shows "0" when a unit gets hit.
2) I tried to make a system that will make a unit take damage from spells according to attackers intelegence.
this is how I made it:
FIRST TRIGGER
Event: Every 0.01 sec
Actions: Set HeroIntelligence[1] = (Intelligence of Hero[1] (Include Bonuses))
SECOND TRIGGER
Event: A unit finishes casting an ability
Actions: Set CastingTarget = (Target unit of ability being cast)
If ((Ability being cast) Equal to Fire Ball)) then do (Unit - Set life of CastingTarget to ((Life of Casting Target)-(Real(HeroIntelligence[1]x2))))) else (Do nothing)
For some reason this does no damage to the spell target
Can someone help me please ?
PS: im very sorry I just forgot how to put triggers in the good way