I'm also not an expert on Action Sequences, only been trying them out lately, but I see that you're using the action effect command to do your skill's damage. I assume your skill does damage multiple times (otherwise, there's no reason to do what you're trying to do) and I'm not sure if it's possible to check if the target is dead while the action effect command is going off. How I've handled this in my sequences is that I use Eval commands to deal my skill's damage and resolve its effects, and in between instances of damage, I can check if the enemy is dead and if it is, get a new random target for the rest of the sequence to go on.
There would be different ways of doing that depending on how your skill is supposed to work, but here's how I made it work for mine.
Spoiler: Action
Code:
<setup action>
clear battle log
Eval: user.lockOn = target
action animation: target
wait for animation
</setup action>
<target action>
Eval: user.group1 = $gameTroop.aliveMembers()
if user.orbs.length > 2 && user.orbs[2].type == "plasma" && user.group1.includes(user.lockOn)
Eval: user.lockOn.startAnimation(152)
Eval: user.lockOn.gainHp(-8)
Eval: user.lockOn.startDamagePopup()
wait: 20
Eval: user.orbs[2].duration = user.orbs[2].duration -1
Eval: if ($gameActors.actor(2).orbs.length > 2 && $gameActors.actor(2).orbs[2].duration == 0) {$gameActors.actor(2).orbs.splice(2,1);}
else if user.orbs.length > 2 && user.orbs[2].type == "plasma" && !user.group1.includes(user.lockOn)
Eval: user.targeted = user.group1[Math.floor(Math.random() * user.group1.length)]
Eval: user.targeted.startAnimation(152);
Eval: user.targeted.gainHp(-8)
Eval: user.targeted.startDamagePopup()
wait: 20
Eval: user.orbs[2].duration = user.orbs[2].duration -1
Eval: if ($gameActors.actor(2).orbs.length > 2 && $gameActors.actor(2).orbs[2].duration == 0) {$gameActors.actor(2).orbs.splice(2,1);}
end
.
.
.
You can ignore most of the weird stuff in there as they pertain to my specific skill, but what I basically do is I save the skill's target, check the alive members of the enemy troop before each instance of damage, see if my target is still in there (they won't be if they're dead), and if they are, deal damage to that target and if they're not, then choose a random target from amongst the remaining members of the enemy troop.