Recognize

By SweeTCooL on Aug 21, 2008

This snippet Called Recognize, 2 know What nickname user did use be4 when they join da Channel
like that :
«10:27 am» * Joins: Nickname (ident@3912A91B.C139CAEF.DD493E3E.IP)
«10:27 am» « Nickname Has Useed:(4) nick cool blah loser »

on *:Load:{ /hmake recognize 50 | /echo -a Script Loaded - Ty for Using SweeTCooL Script, Recognization. | if ($exists($findfile($mircdir,reco.hsh,1)) != $null} { /hload recognized reco.hsh } }
on *:Start:{ /hmake recognize 50 | /hload recognize reco.hsh }
on *:exit:{ /hsave recognize reco.hsh | /hfree recognize }

Menu Menubar {
  -
  Recognize
  .On:{
    /.enable #recognize | /set %recognize.c $?="What color would you like the nicknames to echo as? $crlf CTRL+K brings up the color dialog. $crlf Hit escape to, NOT, set a color."
    if ($exists(reco.hsh) = $true) { /hload recognized reco.hsh }
  }
  .Off:/.disable #recognize | /unset %recognize.c | /hsave -o recognize reco.hsh | /hfree recognize
}
#recognize on
ON *:JOIN:#:{
  if ($nick != $me) {
    if ($nick isin $hget(recognize,$address($nick,2))) || (Guest isin $nick) { goto echo }
    else { //hadd recognize $address($nick,2) $hget(recognize,$address($nick,2)) $nick | goto echo }
    :echo
    if ($numtok($hget(recognize,$address($nick,2)),32) >= 20) {
      echo $chan $timestamp  $+ %recognize.c $+ « $nick Has Used:( $+ $numtok($hget(recognize,$address($nick,2)),32) $+ ) $Replace($gettok($hget(recognize,$address($nick,2)),$calc($numtok($hget(recognize,$address($nick,2)),32) - 20) $+ -,32),$chr(32) $+ $nick $+ $chr(32),$chr(32)) » 
    }
    else {
      echo $chan $timestamp  $+ %recognize.c $+ « $nick Has Used:( $+ $numtok($hget(recognize,$address($nick,2)),32) $+ ) $Replace($hget(recognize,$address($nick,2)),$chr(32) $+ $nick $+ $chr(32),$chr(32)) »
    }
  }
}
on *:Nick:{ 
  if ($newnick isin $hget(recognize,$address($newnick,2))) || (Guest isin $nick) { return }
  elseif ($newnick != $me) { //hadd recognize $address($newnick,2) $hget(recognize,$address($newnick,2)) $newnick }
}
#recognize end
alias recognized {
  if ($hget(recognize,*!*@ $+ $1) = $null) { /echo -a  $+ %recognize.c $+ $1 has not been added as another nickname. }
  if ($hget(recognize,*!*@ $+ $1) != $null) { /echo -a  $+ %recognize.c $+ $1 Previously was $hget(recognize,*!*@ $+ $1) }
}

Comments

Sign in to comment.
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.