Quote:
I had to comment out the break in the line. It was calling my !break remote action. Which was weird.
That can't possibly happen, a command cannot trigger an event whose trigger is that command, I suppose you had a bracket mismatch, which may result in what is below your code to be executed as command:

Code:
alias test {
/echo -a some stuff
/if (1 == 1 {
/more stuff..
/if (2 == 2) {

}

}

/this is actually executed


/on *:text:!break:#:{
/stuff
/if (1 == 1 {
/more stuff..
/if (2 == 2) {

}
}
}
}
In this case, the { } bracket are incorrect, the alias is missing its closing }, which is actually at the end of the event, causing everything to be executed as a command.

You can use control + h in the editor to check for bracket mismatch, although if you have the correct number of { and } but misplaced, it would still be wrong and not detected.
/break allows to break the loop, we're using all these variables as array, %a is the Nth element in the array, %range is an array of range, from the smallest to biggest and we check each time if we are in the current range, if so, we don't need to check any more range so we must exit the loop. Note that by the nature and the logic of the code, it couldn't possibly match two ranges, so not using break would be the exact same thing, but using break make the script faster, especially if we consider you have thousand of range to check for and the first one already matched.

The 1 5 6 stuff is related to the previous code, for these range (for the range of the 1st 5th and 6th element in the array) you were playing a sound file. Not all range were playing a sound file, which is why we must do that $istok check (it's equal to 'if (%a == 1) || (%a == 5) || (%a == 6) {')

Code:
The only issue I found with that is I would also need to remove character32/space. Since the mp3 files don't have one.
Yes, good catch, I missed this!

Also, you should use mslDev, an IDE for the language, which helps with any kind of error: there is a website, msldev.com, but long story short is that it's currently not updated anymore and this is the last stable release made, which is not available on the website: http://rly.cc/8YM59

You're welcome, check my signature and feel free to come by the channel if you have a lot of quick questions like that smile


#mircscripting @ irc.swiftirc.net == the best mIRC help channel