The tutorials deal with auto-casting abilities using either unit is attacked / ability is being cast event.
This works nice if the unit in question feels threatened. "Inner fire" and "Raise dead" appears to be working fine if the enemy units are just "passing by" (they are issued a move to point command using triggers). But the "Curse" dummy ability wouldn't trigger, unless a unit becomes a target of attack ("feel threatened").
I think there are several ways to trigger a "Curse" auto-cast here:
Since I'm creating a TD map with ~1000 possible towers and ~1'500 enemies present, limiting the amount of triggers (and the code therein) is preferable.
What would you recommend?
This works nice if the unit in question feels threatened. "Inner fire" and "Raise dead" appears to be working fine if the enemy units are just "passing by" (they are issued a move to point command using triggers). But the "Curse" dummy ability wouldn't trigger, unless a unit becomes a target of attack ("feel threatened").
I think there are several ways to trigger a "Curse" auto-cast here:
- Make a unit feel threatened (using a simple AI command or something like this)
- Get an auto-casting ability that targets and triggers on every passing enemy
- Trigger and check on each unit attack if we can cast an ability or not (extremely power hungry)
- Add a damaging aura (dealing close to 0 points of damage) on each enemy unit (undesirable)
Attack a friendly unit from afar (doesn't work if the acquisition range is lower than a distance to the attacking tower)- Play around with a "Channel" ability (don't have enough knowledge to make it work)
- Add auto-casting units to related groups, then check each 10 seconds whether they should attack or not (extremely performance hungry)
- Use one of the above mentioned spells, "Inner fire", catch it using triggers, then pick an enemy in a group if it is present, then create a dummy unit / order cast, then cleanup (highly undesirable)
Since I'm creating a TD map with ~1000 possible towers and ~1'500 enemies present, limiting the amount of triggers (and the code therein) is preferable.
What would you recommend?
Last edited: