alias lista {
;Set %lnn as the amount of ops in the room and %lnp as 1
var -s %lnn $nick(#,0,o), %lnp 1
;Start the while loop, it will stop when %lnp is greater than %lnn
while (%lnp !> %lnn) {
;Add the first/next op's name into the %listops token
var %listops $addtok(%listops,$nick(#,%lnp,o),32)
;increase the %lnp variable by one
inc %lnp
}
;The loop is done now and this next line checks if the %listops token has any names in it and if it does it echos the names.
$iif(%listops,echo -a $v1)
}