- Joined
- Feb 27, 2007
- Messages
- 5,578
- Don't use the Unit - Damage Area function. It is target-agnostic and will damage the caster as well as allied units in the area like a ground attack from catapults. Additionally the damage dealt is actually N*SpellDmg where N is the number of units in the group, because your trigger tells the caster to damage the entire area once for each unit inside it. I assume you did not intend this. Change the damage line to Unit - Damage Target instead. There's also no target filtering right now; when you set the group variable you should use some Matching... commands to only grab nearby units hostile to the caster that are not spell-immune rather than just grabbing all units nearby.
- Why use a dummy unit to follow the target around when you could just reduce the armor of the target directly with something like inner fire? (there are other options too)
- Even if having a dummy unit was the best way, simply ordering it to follow the target is not an acceptable implementation. What if the target jumps over a wall? What if it has a spell that teleports it somewhere else on the map? Etc. If you're going to do it that way you'll need to manually move the dummy unit to the target's position on a low-timeout periodic timer. This brings me to my fourth point:
- This is not MUI, and using a timer to move the unit would make it even less so. It needs to use dynamic indexing; read this for more information: Visualize: Dynamic Indexing
- What exactly is the point of CL_Debuff_Group? Nothing is ever added to it so I don't see how it does anything. In any case you're erroneously destroying CL_Debuff_Group in the periodic trigger, which means after the first time it runs the group can't have any units added to it and is doubly pointless. You can replace the group destroy line with a Unit Group - Remove all units command, but I'm still not sure that that should happen there at all.
- What if the caster dies while the spell is in effect? Currently it will stop dealing damage (well, unless dead units can deal damage but not sure on that one and in any case if the unit was explicitly removed from the map the damage every 2 seconds would fail).
- The spell's tooltip says nothing about armor reduction or periodic damage that follows the target.
Last edited: