On its own you can't really see what that does. $slice must be a custom identifier, it's not internal with mIRC. This is obviously just a small bit of a larger script.
It uses a GOTO loop, see /help goto loops and if statements, /help if then else.
For further info on that script, please talk to the author.
Regards,