Controlling targets in Chain/Forked Lightning

Status
Not open for further replies.
Level 11
Joined
Feb 14, 2009
Messages
883
So, here's the deal. I want to make a spell based on either Chain Lightning or Forked Lightning (both will suit me, so I don't really mind) and I want to be able to CHOOSE each of the spell's target. Let me describe what I want to do. I'm making a TD map, and mobs spawn at 4 different locations. Mobs spawned on one location have a different index number than mobs spawned in another location. The spell I'm talking about should kill mobs with a specific index number other than all of them. I was thinking of creating two dummy units that would be teleported between two mobs and create a chain lightning effect between them, as if the mob itself was hit, BUT this solution isn't neat. Chain Lightning uses a "smart" way to find its next target, meaning that it will pick the closest to its current target rather than the random unit triggers will pick.

Thank you.
 
Aha, so all I have to do is to add a check on chainFilter for the index number, right? There are a few other things that I need to include, but I think I can handle it.
JASS:
requires SpellHelper
Do I only need to include the script and SpellHelper for the spell to work, or are there any other requirements?
 
Status
Not open for further replies.
Back
Top