mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Jan 2003
Posts: 237
X
xrn0id Offline OP
Fjord artisan
OP Offline
Fjord artisan
X
Joined: Jan 2003
Posts: 237
how would I Get the value of the number of the people in the channel?



;Check for Life

if (%life == $null) {
goto getlife
}
Joined: Dec 2002
Posts: 3,138
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
$nick(#channel,0)

Joined: Dec 2002
Posts: 1,321
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Dec 2002
Posts: 1,321
$nick($chan,0) or $nick($chan,0,a) for the total number of nicks in $chan
$nick($chan,0,r) for the number of regular (non-opped/voiced/half-opped) users
$nick($chan,0,o) for the number of ops
$nick($chan,0,v) for the number of voiced users
$nick($chan,0,ov) for the number of ops + voiced users
$nick($chan,0,h) for the number of halfops
$nick($chan,0,hv) for the number of halfops + voiced users
$nick($chan,0,ohv) or $nick($chan,0,a,r) for all non-regular users


DALnet: #HelpDesk and #m[color:#FF0000]IR[color:#EEEE00]C
Joined: Jan 2003
Posts: 237
X
xrn0id Offline OP
Fjord artisan
OP Offline
Fjord artisan
X
Joined: Jan 2003
Posts: 237
$nick($chan,0,a) say not enough parameters, and $nick($chan,1,a) says the first person in the channel



;Check for Life

if (%life == $null) {
goto getlife
}
Joined: Dec 2002
Posts: 1,321
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Dec 2002
Posts: 1,321
You must be in a channel in order for $chan to mean anything. Therefore, it won't work if you are in your status window, in a custom @window or in a query/chat window.


DALnet: #HelpDesk and #m[color:#FF0000]IR[color:#EEEE00]C
Joined: Jan 2003
Posts: 237
X
xrn0id Offline OP
Fjord artisan
OP Offline
Fjord artisan
X
Joined: Jan 2003
Posts: 237
i type //echo $nick($chan,0,a) in the channel window, it heys not enough parameters



;Check for Life

if (%life == $null) {
goto getlife
}
Joined: Dec 2002
Posts: 3,138
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
I have no idea why it does that, but it worked fine for me when I added a -a in (//echo -a $nick($chan,0,a)).

Joined: Dec 2002
Posts: 395
M
Fjord artisan
Offline
Fjord artisan
M
Joined: Dec 2002
Posts: 395
It does that because $nick($chan,0,a) returns a number, and /echo syntax is:

/echo [color number] [params/window] <text>

Use -a, as Collective suggested.


Link Copied to Clipboard