Some identifiers to make scripting a bit easier.
Some uses:
if ($owner(nickname)) { ... } ;checks if nickname is an owner
if ($admin) { ... } ;checks if you're an admin
msg # $nick has been idle $idle($nick)
msg # Random nickname: $rnick
It's all fairly straightforward.
alias owner { return $nick(#,$iif($1,$1,$me),~) }
alias admin { return $nick(#,$iif($1,$1,$me),&) }
alias op { return $nick(#,$iif($1,$1,$me),o) }
alias halfop { return $nick(#,$iif($1,$1,$me),h) }
alias voice { return $nick(#,$iif($1,$1,$me),v) }
alias rnick { return $nick(#,$r(1,$nick(#,0))) }
alias idle { return $duration($nick(#,$iif($1,$1,$me)).idle) }
Version History of mIRC 5.61
* Fixed lock dialog password bug.
* Improved support for IRCX servers:
Added property $nick().owner, isowner if comparison, and q\r property to $nick(#,N,aohvrq,aohvrq) where q is for owners.
Added on OWNER/DEOWNER events, work the same as on OP/DEOP, and $mode().owner/deowner properties.
mIRC also now automatically sends /ircx to the IRCX server the moment it connects. Perhaps this only works for ircx related servers. And $rnick() has not been deprecated and is still usable. Though it seems obsolete at best.
Because you didn't read the introduction, nor the code itself. Your problem not mine. Next time before you comment, at least read the code.If you can write what I've quoted above, I'm sure you know darn well the insult was not necessary in the first place. But you had to be insulting. That, I suppose, is one of your shortcomings.
You went off rambling about nothing. If his code is fine, don't go off on something else that is 100% irrelevant. I don't care if the information is correct or not, it's of no use to the author who never requested that you go into "A History of mIRC".I can accept what you've stated here, Armand, gladly. But, what you wrote in the very beginning of going back to 1st grade and people can't read was epic idiotic, ignorant of you.
You don't go around illiterate people and shout out, "you all can't read and should go back to 1st grade, do you?" Have some respect or you don't have one for yourself.
@Jethro_
You went off rambling about nothing. If his code is fine, don't go off on something else that is 100% irrelevant. I don't care if the information is correct or not, it's of no use to the author who never requested that you go into "A History of mIRC".
@Master-Of-Death
Go kiss ass elsewhere. And you really should read below.
Read the code, if it has issues, then comment. Don't add stuff that a) makes the code worse or b) has nothing to do with the author's original intent. If you really wish to assist users, you'd make an attempt to understand what they are trying to code, and then you comment with relevant information.
@gooshie
You give perfect example of a useful comment, thanks for not failing
Armand who are you to be so rude to Jethro no offence but Jethro is one of the best coders i know and for this /rnick rubbish you can just use.
alias rnick { .set %a $nick(#,0)
.set %b $rand(1,%a)
.echo -a $nick(#,%b)
or use
.echo -a $nick(#,$rand(1,$nick(#,0)))
simple, oh and Jethro_'s information is correct.
There was a misunderstanding between my post about the $rnick() identifier and your rnick alias. If you had done some research, you'd know what I was talking about. In other words, I wasn't pinpointing your rnick alias. There's actually a $rnick identifier introduced by mirc back in the older version of 5.5. It may seem I was off-topic, but in actuality I was giving the info about the official identifier is all. Period.
P.S. I do apologize my heated posts in reply to Armand's. I just didn't appreciate his disparaging remarks.
alias owner { return $nick(#,$iif($1,$1,$me),~) }
alias admin { return $nick(#,$iif($1,$1,$me),&) }
alias op { return $nick(#,$iif($1,$1,$me),o) }
alias halfop { return $nick(#,$iif($1,$1,$me),h) }
alias voice { return $nick(#,$iif($1,$1,$me),v) }
The $iif $true $false not really needed if you're only
going to use it as in your example. You would only
really need the $true $false returned if you wanted
to echo out or msg or by whatever means see the words
$true or $false. If so then do as follows:
alias owner { return $iif($nick(#,$iif($1,$1,$me),~),$true,$false) }
alias admin { return $iif($nick(#,$iif($1,$1,$me),&),$true,$false) }
alias op { return $iif($nick(#,$iif($1,$1,$me),o),$true,$false) }
alias halfop { return $iif($nick(#,$iif($1,$1,$me),h),$true,$false) }
alias voice { return $iif($nick(#,$iif($1,$1,$me),v),$true,$false) }
Dude, just read the damn code. Where does he imply that $rnick(chan,#) is its usage here?
alias rnick { return $nick(#,$r(1,$nick(#,0))) }
Read the code. And you're not benefitting anyone by not reading what is going on in the code. Don't blindly go and call someone out if you haven't even looked at it.
Armand, who are you to tell people to go back to 1st grade? Who are you to tell people they can't read? Please have some ethic in replying to people with decency. We are here to encourage each other with what we know, and get benefited from what we gather about scripting, to the best of our knowledge. Please don't be an arrogant prick.