mIRC Homepage
Posted By: Jamezzz mass pm script - 07/09/08 04:15 PM
mass pm script

hey could anyone supply me with a script that would PM (/msg) everyone on a certain channel, whom are voiced and above?
a command such as /masspm #channel <message>

thanks in advance smile
Posted By: Solo1 Re: mass pm script - 08/09/08 10:44 AM
Code:
alias masspm {
  if (!$3) { echo $color(info) -a * /masspm: insufficient parameters | return }
  var %i = 1,%msg = $3-
  while ($nick(#,%i,a,r)) { .msg $v1 %msg | inc %i }
  echo -a -> masspm $+(#,:) %msg $iif((%i > 10),4You have mass messaged more then ten users which may result in you flooding off the server.)
}
Posted By: Jamezzz Re: mass pm script - 14/09/08 06:03 PM
what's the syntax for this?
Posted By: Darmadia Re: mass pm script - 14/09/08 07:03 PM
Code:
alias masspm {
  ;$1 is channel, $2- is message
  var %a = 1
  var %b
  while (%a <= $nick($1,0)) {
    %b = %b $+ $nick($1,%a) $+ $chr(44)
    if ($calc(%a % 10) == 0) {
      /timer 1 $calc((%a - 10) * 3) $($+(msg,$chr(32),$left(%b,-1),$chr(32),$2-))
      %b = $null
    }
    inc %a
  }
  if (%b && %a > 10) {
    /timer 1 $calc((%a - 9) * 3) $($+(msg,$chr(32),$left(%b,-1),$chr(32),$2-))
  }
  else if (%b && %a <= 10) {
    $($+(msg,$chr(32),$left(%b,-1),$chr(32),$2-))
  }
}


using it: /masspm MESSAGE
© mIRC Discussion Forums