Results 1 to 1 of 1

Thread: mIRC: WHOIS script

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Rizon Staff darkex's Avatar
    Join Date
    Sep 2009
    Location
    Australia
    Posts
    117

    Default mIRC: WHOIS script

    This is some very basic code that translates the confusing WHOIS outputs into a simpler format.

    It should work for all RAW WHOIS outputs from Rizon, (nag me if I've missed any!) and most unmodified Unreal (including custom SwiftIRC IRCd) and InspIRCd servers.

    Note: I've included the +g and +G modes, but to show them in a WHOIS output you'll most likely need to do /whois <nick> <nick> to reveal that information.

    Code below goes into Remotes obviously, Alt+R and copy+paste.

    Code:
    raw 311:*: {
      set %whois 1
      echo -a 4 $+ $2 $+  Address: $3 $+ $chr(64) $+ $4
      echo -a 4 $+ $2 $+  Realname: $6
      haltdef
    }
    
    raw 378:*is connecting*: {
      echo -a 4 $+ $2 $+  Host: $6
      echo -a 4 $+ $2 $+  IP: $7
      haltdef
    }
    
    raw 338:*is actually*: {
      echo -a 4 $+ $2 $+  Host: $5
      echo -a 4 $+ $2 $+  IP: $remove($6,$chr(91),$chr(93))
      haltdef
    }
    
    raw 307:*: {
      echo -a 4 $+ $2 $+  is a registered nick
      haltdef
    }
    
    raw 319:*: {
      echo -a 4 $+ $2 $+  Channels: $3-
      haltdef
    }
    
    raw 312:*: {
      echo -a 4 $+ $2 $+  Server: $3 $4-
      haltdef
    }
    
    raw 716:*server side ignore*: {
      if ($5 === +G) {
        echo -a 4 $+ $2 $+  $5 $+ : Soft server side ignore
        haltdef
      }
      elseif ($5 === +g) {
        echo -a 4 $+ $2 $+  $5 $+ : Server side ignore
        haltdef
      }
    }
    
    raw 310:*is using modes*: {
      echo -a 4 $+ $2 $+  Modes: $6-
      haltdef
    }
    
    raw 313:*is a*: {
      if (service isin $3-) {
        echo -a 4 $+ $2 $+  is a network service
        haltdef
      }
      elseif (bot isin $3-) {
        echo -a 4 $+ $2 $+  is a network service
        haltdef
      }
      elseif ($5 == IRC) && ($6 == Operator) && ($7) && ($network == Rizon) {
        echo -a 4 $+ $2 $+  IRCOp: ( $+ $8- $+ )
        haltdef
      }
      elseif (!$7) && ($network == Rizon) {
        echo -a 4 $+ $2 $+  IRCOp: ( $+ IRC Operator $+ )
        haltdef
      }
      else {
        echo -a 4 $+ $2 $+  IRCOp: ( $+ $5- $+ )
        haltdef
      }
    }
    
    raw 310:*is available for help.: {
      echo -a 4 $+ $2 $+  is available for help
      haltdef
    }
    
    raw 335:*: {
      echo -a 4 $+ $2 $+  is a bot on $network
      haltdef
    }
    
    raw 671:*secure connection*: {
      echo -a 4 $+ $2 $+  is using a secure connection
      haltdef
    }
    
    raw 672:*cgi*irc*: {
      echo -a 4 $+ $2 $+  is a CGI:IRC client
      haltdef
    }
    
    raw 317:*seconds idle*signon time*: {
      echo -a 4 $+ $2 $+  Idle: $duration($3)
      echo -a 4 $+ $2 $+  On IRC: $asctime($4)
      haltdef
    }
    
    
    raw 330:*is logged in as*: {
      echo -a 4 $+ $2 $+  is logged in as $3
      haltdef
    }
    
    raw 320:*is using a secure connection: {
      echo -a 4 $+ $2 $+  is using a secure connection
      haltdef
    }
    
    raw 379:*is using modes*: {
      echo -a 4 $+ $2 $+  Modes: $6-
      haltdef
    }
    
    raw 301:*: {
      echo -a 4 $+ $2 $+  Away: $3-
      haltdef
    }
    
    raw 537:*is currently immune to filtering*: {
      echo -a 4 $+ $2 $+  is immune to filtering
      haltdef
    }
    
    raw 401:*no such nick*channel*: {
      echo -a 4 $+ $2 $+  No such nickname.
      haltdef
    }
    
    raw 318:*end of*: {
      echo -a 4 $+ $2 $+  End of WHOIS.
      echo -a -
      unset %whois
      haltdef
    }
    Last edited by darkex; 10-15-2009 at 03:29 AM. Reason: small edit

Similar Threads

  1. Multi-owner script
    By twilightNoir in forum IRC client scripts and addons
    Replies: 4
    Last Post: 04-15-2019, 09:59 AM
  2. RizonIRPG Script for mIRC
    By Locotes in forum #RizonIRPG
    Replies: 4
    Last Post: 09-15-2011, 10:10 AM
  3. mIRC: Anti-Flood Script
    By Jason in forum IRC client scripts and addons
    Replies: 1
    Last Post: 12-30-2009, 12:53 AM
  4. Bomb script
    By Danfire0 in forum IRC client scripts and addons
    Replies: 3
    Last Post: 08-18-2009, 08:17 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •