Code / mIRC / Auto Check Access Upon X Kick

  1. ; This is a small snippet that i was asked to write a while
  2. ; ago for a friend. If you are kicked, it msg's X to see
  3. ; their access.
  4.  
  5. on *:kick:#: {
  6.  
  7.         ; Okay, first we check to see if the kick was by X
  8.         if ($nick == X) {
  9.         ; Now we check to see if X is on that channel.. should
  10.         ; be if X kicked you, but this just saves hassle if not=P
  11.         if (X ison $chan) {
  12.         ; This will set the variable %thisnick to the
  13.         ; actual nickname $1 will be (nick) so all we
  14.         ; do, is use $left and $right set as -1 to strip
  15.         ; the end charactors off the nickname. This was a
  16.         ; stupid thing no to realise, and i tried like 5
  17.         ; million things beforehand=P
  18.         .set %thisnick $right($left($1,-1),-1)
  19.         ; Just to let you know whats going on
  20.         .echo -a You were kicked with X by %thisnick
  21.         ; Now lets message X and find out who it was..
  22.         .msg x access $chan %thisnick -modif
  23.         }
  24.     }
  25. }

Download as Text : January 6th, 2009