mIRC Home    About    Download    Register    News    Help

Print Thread
#20148 20/04/03 08:35 AM
Joined: Jan 2003
Posts: 87
T
Tat Offline OP
Babel fish
OP Offline
Babel fish
T
Joined: Jan 2003
Posts: 87
I needed to know if a specific user was voiced in any channel I was also in. Its for one of my adblocker script, so it doesn't block ads from voiced people as its doubtful that they are spammers. I tried an if like:
if ($calc($comchan($nick,0).voice + $comchan($nick,0).op + $comchan($nick,0).help)) return
After a very short period of time I realized this was not how comchan worked, regardless that it seemed so natively correct. $comchan($nick,0).voice is the same as $comchan($nick,0). My suggestion is to make the .voice .op .help suffixes work by providing the number of common channels where the user has that mode.

#20149 20/04/03 11:36 AM
Joined: Dec 2002
Posts: 774
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 774
alias comchan_notreg {
var %i = $comchan($1,0)
while ( %i ) {
if ( $nick($comchan($1,%i),$1,ohv) ) return $true
dec %i
}

returns $true if the nick in $1 is op/halfop/voice on any channels you're on...


Code:
//if ( khaled isgod ) echo yes | else echo no

Link Copied to Clipboard