Nicklist Info

By sk68 on Jul 08, 2010

Uses information from a /who command and adds a menu option to display it in the nicklist pop-up menu

Requests are open for any information that should be added, just keep in mind a /who is NOT the same as /whois

Multi-network support
Some new events to keep the hash table(s) cleaner
Keeps track of nick changes

If you are using a BNC you may have some issues as it seems channels are joined before the CONNECT event is triggered, if anyone has a fix for this it would be appreciated

Click a field to copy it to the clipboard

on *:LOAD:{ hmake nickinfo 1000
  echo $color(info) -a *** Nicklist info loaded
  echo $color(info) -a *** Please rejoin ALL channels for this script to take effect

on *:JOIN:#:{ if ($nick == $me) .who $chan
  elseif (!$hget(nickinfo [ $+ [ $network ] ],$nick)) { .who $nick }

raw 352:*:{ 
  hadd nickinfo [ $+ [ $network  ] ] $6 $3 $4 $5 $iif(r isin $7,1,0) $iif($chr(42) isin $7,1,0) $9-

raw 315:*:{ haltdef }

on *:QUIT:{ hdel nickinfo [ $+ [ $network ] ] $nick }

on *:PART:{ if (!$comchan($nick,0)) hdel nickinfo [ $+ [ $network ] ] $nick }

on *:NICK:{ hadd nickinfo [ $+ [ $network ] ] $newnick $hget(nickinfo [ $+ [ $network ] ],$nick)
  hdel nickinfo [ $+ [ $network ] ] $nick

on *:CONNECT:{ if (!$hget(nickinfo [ $+ [ $network ] ])) hmake nickinfo [ $+ [ $network ] ] 1000
  .timer 0 3600 { var %n $hget(nickinfo [ $+ [ $network ] ],0).item
    while (%n) { 
      if (!$comchan($hget(nickinfo [ $+ [ $network ] ],%n).item))) hdel nickinfo [ $+ [ $network ] ] $hget(nickinfo [ $+ [ $network ] ],%n).item)
      dec %n
menu nicklist { 
  Quick Info 
  .Ident $+ $chr(58) $getinfo($1,$network).ident:clipboard $getinfo($1,$network).ident
  .Host $+ $chr(58) $getinfo($1,$network).host:clipboard $getinfo($1,$network).host
  .Realname $+ $chr(58) $getinfo($1,$network).name:clipboard $getinfo($1,$network).name
  .Server $+ $chr(58) $getinfo($1,$network).server:clipboard $getinfo($1,$network).server
  .Class $+ $chr(58) $getinfo($1,$network).class:clipboard $getinfo($1,$network).class
  .$1 is $iif(!$getinfo($1,$network).reg,not) registered:clipboard $1 is $iif(!$getinfo($1,$network).reg,not) registered

alias -l getinfo { 
  var %nick $1,%net $2
  tokenize 32 $hget(nickinfo [ $+ [ %net ] ],%nick) 

  if ($prop == ident) return $1
  elseif ($prop == host) return $2
  elseif ($prop == server) return $3
  elseif ($prop == reg) return $4
  elseif ($prop == class) return $iif($5,IRCop,Normal)
  elseif ($prop == name) return $6-

on *:SNOTICE:* did a /whois on you.:{ if ($comchan($2,0) && !%nowhois. [ $+ [ $2 ] ]) { 
    set -u60 %nowhois. [ $+ [ $2 ] ] 1
    describe $comchan($2,$comchan($2,0)) tackles $2
    .timer 1 1 msg $comchan($2,$comchan($2,0)) no /whois for j00! >:O


Sign in to comment.
rebel9   -  Apr 20, 2014

For people using BNC, you would have to ask them to turn off the "chansaver" setting module as it remembers every channel from the networks you join. Hence the name. You can fix it in the BNC webadmin section. just FYI, //who is a VERY commonly used command especially by IRCops who want to see the people that arent in channels, to view the people on the network in its entirety. There are other ways to go about it, and better ways, but i use "//who !*" type of commands all the time to try and find where the person with that host is, because some people aren't wanted on nets or need to be found. Just a little helpful information, use it if you want.

sk68   -  Sep 10, 2010


sk68   -  Jul 09, 2010

true, its not a common way to do it, but /who is not a commonly used command to begin with, at least not that Ive seen. The information from a /who command is easier to handle than /whois, if someone has issues with the script I will gladly change it to work for everyone, but for now I think I will stick to the wise words of "If it ain't broke, don't fix it" :)

Jethro   -  Jul 09, 2010

@Jethro_ /who $nick works fine on the networks I useWell, perhaps I've never come across the use of /who $nick, because to me, it's rather uncommon. If a network doesn't support that, the code may need to be modified to /whois instead. I think it'd be great to have both options available just in case.

sk68   -  Jul 09, 2010

@WorldDMT Thanks Ill add that with the next update

@Jethro_ /who $nick works fine on the networks I use

Jethro   -  Jul 08, 2010

Your on join event doesn't make sense. How are you supposed to /who $nick when a user joins? It's supposed to be /whois $nick. It should have been:> on *:join:#:{ $iif($nick == $me,who $chan,whois $nick) }Then you're still missing raw 311 in conjunction with the /whois command.

I believe what you wanted was this instead:

on me:*:join:#:{ who $chan }
WorldDMT   -  Jul 08, 2010

remember ON NICK event

Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.