The Set Loopcounter = 10 will make it go on forever. I think you meant Loopcounter = Loopcounter +1?
And yeah that will work but for only one unit at a time. A hacky way to do it (though it'll require local variables, which are a tiiiny bit of jass but not that much) is to give EMP Periodic no events, use a Run Trigger action to run EMP Periodic from EMP Main, and have EMP Periodic run itself again after a wait, until you don't want to run it anymore. Don't do that trick too much in your map though since excessive numbers of waits cause lag and are inaccurate.