HL Response

By Savage_CL on Jul 20, 2010

This is my first post. It is a very simple script.

line 1: put your main nick where it says NICK HERE Line 2: (optional change) 10 represents the amount of seconds the script should wait before responding to a particular nick a second time. Line 5: (optional change) What $nick $+ ? is the actual text that mIRC outputs.

on *:TEXT:NICK HERE:*:{
  inc -u10 %cspam. [ $+ [ $nick ] ]
  if (%cspam. [ $+ [ $nick ] ] <= 1) {
    if (%color == $null) { set %color 2 }
    if (%color != $null) { timer 1 1 msg #  $+ [ %color ] What $nick $+ ? }
    if (%color == 2) { set %color 3 | halt }
    if (%color == 3) { set %color 4 | halt }
    if (%color == 4) { set %color 7 | halt }
    if (%color == 7) { set %color 9 | halt }
    if (%color == 9) { set %color 10 | halt }
    if (%color == 10) { set %color 11 | halt }
    if (%color == 11) { set %color 13 | halt }
    if (%color == 13) { set %color 2 | halt }
  }
}

Comments

Sign in to comment.
amlette   -  Oct 28, 2010

an other way

on *:TEXT:*:*:{
  ; if my nickname is in the line
  if ($me isin $1-) {
    inc -u10 %cspam. [ $+ [ $nick ] ]
    if (%cspam. [ $+ [ $nick ] ] <= 1) {
      ; %panel is for colors you want use
      ; %target is for reply to nick (for querys) or chan
      var %panel = 2 3 4 7 9 10 11 13, %target = $iif($chan,$chan,$nick)
      ; %color isn't a color, but a token num for the gettok %panel
      if (!%color) { set %color = 1 }
      ; if %color exists, inc the token. if %color > nbr of color in %panel, restart
      else { inc %color | if (%color > $gettok(%panel,0,32)) { set %color 1 } }
      msg %target $+(,$gettok(%panel,%color,32),What,$chr(32),$nick,?) 
    }
  }
}
More
 Respond  
Lucius   -  Oct 27, 2010

If you don't want to add all the halts, just try putting the if's in reverse order for the colour change. That way it's already past the line it would change the next time round.

    if (%color == 13) { unset %color }
    if (%color == 11) { set %color 13 }
    if (%color == 10) { set %color 11 }
    if (%color == 9) { set %color 10 }
    if (%color == 7) { set %color 9 }
    if (%color == 4) { set %color 7 }
    if (%color == 3) { set %color 4 }
    if (%color == 2) { set %color 3 } 
More
 Respond  
Savage_CL   -  Jul 21, 2010

Yea lol, not much of an advanced script, just an auto-response that rotates through colors. I couldn't get it to work with the variable, IDK why, and if I don't put in that halts, it will just keep cycling through. endlessly.

More
 Respond  
Jethro   -  Jul 21, 2010

You don't have to put "NICK HERE." Just do:

on :TEXT:$( $+ $mnick $+ )::{

Or use $me

Though I'd recommend the use of regex for this.

And may I ask why all the halts?

I'm a little confused as to what it actually does too.

More
 Respond  
Jamiie   -  Jul 20, 2010

Decently written, what is it for might I ask? Just an auto response?

More
 Respond  
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.