This spell has similar issues to the previous one. Starting from the whole, you should structure the spell in the following ways:
1. A configurable trigger, where the user sets up his desirable values that affect the spell overall.
2. A cast trigger, when the unit casts the ability, turns periodic trigger on if it's the first index of the spell.
3. A periodic trigger, where the spell has effects per interval, it can also have stages or phases. Includes deindexing when the spell ends.
4. You also might have a cancel trigger, depending on the spell.
Waits are inaccurate at low intervals, no one has control over how much time it actually waits. I don't even understand why there's a 0.01s wait before doing anything else, the spell would be fine if there was none there.
Onto the specifics:
Kind of Obfuscated variable names such as LS_Int_Cast_1 and LS_Int_Cast_2. They're not very descriptive, but they appear to be related to the amount of special effects as well as reaching the end point with lightning.
You're creating the lightning effect from the hero position to the end position with several intermediate lightning effects, but the result is that the closer someone looks to the hero, the more spammy and redish it looks, whereas at the end location it's more clear. You just need to create 1 lightning effect from the hero position to the end position with no stacked lightnings, which can be done inside the loop integer B, but outside of loop integer A.
You're leaking the "cancel death" effect, and also a lot of location (points) and groups (unit groups) leaks.
-
Unit - For Unit (Casting unit), Set cooldown of ability (Ability being cast), Level: (Integer B) to 99.00
This isn't doing anything at the moment since "Ability being cast" is null after any waits.
Probably would be a good idea to add to your description how long the pulses last, or how many pulses per second. But that would require you to have more structured triggers since periodic triggers are usually 0.02s~0.03s
I would also suggest probably adding some kind of effect as in "debuff" for the units affected in the line, armor reduction or something. So it adds more something to the spell other than just damage.