Originally Posted By: STING
Originally Posted By: RusselB
Aside from correcting the ON TEXT events so that they use the correct format, the 2nd structure could use if/elseif/else rather than several if's with halt's.


alias blah {
if ($1 == 1) { blah }
if ($1 == 2) { blah }
if ($1 == 3) { blah }
}

alias blah {
if ($1 == 1) { blah }
elseif ($1 == 2) { blah }
elseif ($1 == 3) { blah }
}

I use elseif mainly for stacking if-statements, does is have any added value in this scenario?


it only serves to prevent mIRC from going through subsequent if conditions should one of them succeed which, if you're using /halt in each of them, doesn't happen anyway. if you aren't, the elseif approach provides a comfortable way of including a default case (else {})


"The only excuse for making a useless script is that one admires it intensely" - Oscar Wilde