• Check out the results of the Techtree Contest #19!
  • Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

Cropse Target

Status
Not open for further replies.
"Dead" units could be reincarnating units or stuff that is still alive so this is impossible
 
Reicarnate? Mostly improbable. Mostly heroes reincarnate (though it obviously can be used on normal unit). However, here is a simple yet efficient method:

Use channel with 0.01 duration and make it target a point. And now:

Event - An Unit Begins Casting an Ability
Conditions - Ability Being Cast equal to YourAbility

set var = pick a random unit within 50 range of the point matching condition ((Matching Unit) is Dead equal to true and (Matching Unit) is a Hero equal to false and (matching Unit) is a Structure equal to false)

And then you can of course check if var is null. And if it is you stop the caster immediately and write an error message. If not you remove var unit and do your spell. Don't forget to set var to null at the end of the trigger.

~Daelin
 
How bout this, make spell based on target-position spell (e.g. Carrion Swarm) then when a unit start casting an ability, do:

set var = pick a random unit within 50 range of the target point of ability being cast matching condition ((Matching Unit) is Dead equal to true and (Matching Unit) is a Hero equal to false and (matching Unit) is a Structure equal to false)
/* same with Daelin though */

if var not equal to nothing then
--------spell action--------
else
--------message-------------


Just to make it clear.
 
Status
Not open for further replies.
Back
Top