mIRC Home    About    Download    Register    News    Help

Print Thread
Checking if the initiator of a command is an OP... #68964 22/01/04 10:26 PM
Joined: Jan 2004
Posts: 15
J
jONEz Offline OP
Pikka bird
OP Offline
Pikka bird
J
Joined: Jan 2004
Posts: 15
I know that's a really dumb question, but I'm just learning IRC (about 2 days now) and I'm writing a PUGServ type Bot, I've figured out hash tables and have most of it working but one thing I can't find much documentation on is how to tell if the initiator of a command is an op...

Reading through the FAQ on here I came up with this;
if ($level($address) >= 75) blah blah

But that isn't right, or it doesn't seem to work, can someone help me out? Thanks,

Re: Checking if the initiator of a command is an OP... #68965 22/01/04 10:29 PM
Joined: Oct 2003
Posts: 273
E
EVH Offline
Fjord artisan
Offline
Fjord artisan
E
Joined: Oct 2003
Posts: 273
if they're an op on the channel ?
if ($nick isop #) { command(s) }

or

if ($ulevel >= 75) { command(s) }

or

on 75:TEXT:!command*:#: { command(s) }

Last edited by EVH; 22/01/04 10:40 PM.
Re: Checking if the initiator of a command is an OP... #68966 22/01/04 10:42 PM
Joined: Jan 2004
Posts: 15
J
jONEz Offline OP
Pikka bird
OP Offline
Pikka bird
J
Joined: Jan 2004
Posts: 15
Thanks! Damn that was fast too!

I figured it was something easy, I can't believe I missed that, anyway thanks for the help!