mIRC Homepage
Posted By: Solo1 check if user isop - 16/07/08 02:34 PM
Hi again blush

How does mIRC know who is an operator on a channel using the identifier isop? i have tried looking at IRC in its raw format and found nothing in the users text (PRIVMSG) that would tell mIRC its an opped user talking.
Am i right in supposing that mIRC would keep track of every user thats opped by parsing the raw (example :Solo1!Solo1@address.com MODE #main +o solo1) and saves it somewhere and deletes it when the user is deopped or leaves the channel?

Thanks
Posted By: Joe_Dean Re: check if user isop - 16/07/08 02:42 PM
if ($nick isop $chan) { msg $chan You are an Operator. }
else { msg $chan You are NOT an Operator. }
Posted By: Joe_Dean Re: check if user isop - 16/07/08 02:45 PM
Or, I believe you could stick an @ symbol in any of your events (an access level). e.g.:

on @:text:*blah*:#: { msg $chan You are an Operator! }

Not sure about that one though - my advice is use isop. I don't use the access levels much, but I'm pretty sure you could put an @ sign in there... try it out.
Posted By: Joe_Dean Re: check if user isop - 16/07/08 02:48 PM
Sorry for triple post, but you said something about a PM? Well, technically no one can be an OP in a PM, so if you wanted to check if that user was an OP, you'd have to include the channel to check in the script. e.g.:

if ($nick isop #mychan) { .msg $nick You are an operator in #mychan }
Posted By: Wims Re: check if user isop - 16/07/08 03:42 PM
The @ prefix always mean that you ($me) have to be an op.
Posted By: Horstl Re: check if user isop - 16/07/08 03:59 PM
Afaik mIRC is parsing the raw like you guessed, and does a /names #chan on join to get not only the nicks but their channel status as well.

A check for "isop" is sufficient to check for nick x having op on chan y.
To track "mode changes" of modes that may vary depending on the ircd used, like +a = "protect", you'd have to parse the "on rawmode" event on your own. In addition, you may compare a $nick(y,x).pnick to $prefix to $nickmode.

Posted By: Solo1 Re: check if user isop - 16/07/08 07:10 PM
I know how to use the isop operator. My question was how mIRC parsed the raw sent to the client by the server.

Horst answered my question thank you
Posted By: Lpfix5 Re: check if user isop - 18/07/08 03:20 AM
mIRC does not store the information through RAW events or store it at all whatsoever,

ISOP is used to compare regular listed nicks has regular users or users with the SYMBOL @ inclusive in their nick from the server side.

Has you join a channel example #mirc with let's say 50% of users op'ed at no point in time does mIRC store the information anywhere, at most a names list check is performed.

So again mIRC does no store this information and ISOP is used to compare users in your list for which one has symbol @ <"Or equivelant"> in their nick.

Server has this information ready for the client "MIRC" to use.
Posted By: RoCk Re: check if user isop - 18/07/08 03:21 PM

I'm not quite sure exactly what you're saying, but I'll take a stab at it. Yes mIRC does store this information internally. If a nick is opped and then gets voiced and mIRC sees it, then the .pnick property for the $nick() identifier will show both @+ even though the nick is only prefixed with @ in the nick list. Also, ISVOICE would be true as well as ISOP.
Posted By: Lpfix5 Re: check if user isop - 18/07/08 09:40 PM
That only occurs if the client is sitting there to see it, else if you join the channel at no time is it stored to mirc.
© mIRC Discussion Forums