mIRC Homepage
Posted By: ST3V3 Channels in a variable - 15/03/04 04:39 PM
Can someone please tell me how to set all the channels on the current server to a variable in this format:
#chan1 #chan2 #chan3 #chan4 #chan5

Thanks,
Posted By: tidy_trax Re: Channels in a variable - 15/03/04 04:44 PM
unset %chans
var %i 1
while $chan(%i) {
set %chans %chans $chan(%i)
inc %i
}
Posted By: ST3V3 Re: Channels in a variable - 15/03/04 04:52 PM
Sorry but i dont think i explained properly i mean all the channels on the server, the ones that show up when you type /list smile

Thanks,
Posted By: tidy_trax Re: Channels in a variable - 15/03/04 04:59 PM
Code:
raw 321:*:{ 
unset %channels 
;window -c "channels list"
;haltdef
}
raw 322:*:{ 
set %channels %channels $2 
;haltdef
}

still have to type /list
edit: uncomment (remote the ;'s) the script if you don't want the channel list window to show.
© mIRC Discussion Forums