Trigger - Add to Unit is Attacked <gen> the event (Unit - (Triggering unit) Is attacked)
Unit is Attacked
Trigger:
Events
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Triggering unit) has buff Reflect) Equal to True
Then - Actions
Set HitsTaken[(Player number of (Owner of (Triggering unit)))] = (HitsTaken[(Player number of (Owner of (Triggering unit)))] + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
HitsTaken[(Player number of (Owner of (Triggering unit)))] Equal to 5
Then - Actions
Set TempPoint = (Position of (Triggering unit))
Unit - Cause (Triggering unit) to damage circular area after 0.00 seconds of radius 400.00 at TempPoint, dealing 100.00 damage of attack type Spells and damage type Normal
Special Effect - Create a special effect at TempPoint using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
Special Effect - Destroy (Last created special effect)
you can also add a bunch of other ifs thens and elses to this trigger for other abilities that trigger upon attack
notes:
-"hits taken" is an integer with an array of 12, I asumed that eaach player wold only have one unit casting this ability
-"temp point" is used to prevent lag, it is removed with the custom script
-neutral building explosion is listed under spawned effects, it would be a good effect for this ability imo "BOOM!" hehe
-Triggering unit is the correct function for "unit is attacked" btw, this is not a mistake
you order it to cast the spell wich you based your spell of. e.g. if you have a skill URSKILL, based of thunder clap, you order human - mountain king - thunder clap
This is the map you need exactly just copy triggers variables and spells.If you need your ability to be cast just change the buff of the trigger to the buff that your skill gives.
Our new website went up early yesterday. Health Empowers You. 200 smoothie recipe guide and soon we will have detox, cognitive enhancement, weightloss teas and some coffee blends. https://healthempowersyou.net/products/smoothie-recipe-guide
It never fails that as soon as I say something about the bots they come back - this time they are under a whole new IP range - one thing in common though, Chinese!
I am working on getting access to the old news portal under a different URL for those that would rather use that for news before we get a different news view.