All pastes #204410 Raw Edit

Miscellany

public text v1 · immutable
#204410 ·published 2006-10-15 22:58 UTC
rendered paste body
on *:text:!autovoice on*:#: {
  if ($me !isop $chan) { notice $nick 4 $+ ERROR - I will only function on channels where i am opped | .halt }
  if ($nick !isop $chan) { msg $chan 4 $+ ERROR - You are not authorized for this command | .halt }
  if (% [ $+ autovoice. $+ [ $chan ] ] == on) { msg $chan 4 $+ ERROR - Autovoice for $chan is already on | .halt }
  .set % [ $+ autovoice. $+ [ $chan ] ] on
  msg $chan 7 $+ Autovoice for $chan is now on
}

on *:text:!autovoice off*:#: {
  if ($me !isop $chan) { notice $nick 4 $+ ERROR - I will only function on channels where i am opped | .halt }
  if ($nick !isop $chan) { msg $chan 4 $+ ERROR - You are not authorized for this command | .halt }
  if (% [ $+ autovoice. $+ [ $chan ] ] == off) { msg $chan 4 $+ ERROR - Autovoice for $chan is already off | .halt }
  .set % [ $+ autovoice. $+ [ $chan ] ] off
  msg $chan 7 $+ Autovoice for $chan is now off
}

on *:text:!autovoice status:#: {
  if ($me !isop $chan) { notice $nick 4 $+ ERROR - I will only function on channels where i am opped | .halt }
  if ($nick !isop $chan) { msg $chan 4 $+ ERROR - You are not authorized for this command | .halt }
  if (% [ $+ autovoice. $+ [ $chan ] ] == on) { msg $chan 7 $+ Autovoice for $chan is on | .halt }
  if (% [ $+ autovoice. $+ [ $chan ] ] == off) { msg $chan 7 $+ Autovoice for $chan is off | .halt }
  if (% [ $+ autovoice. $+ [ $chan ] ] == $null) { msg $chan 7 $+ Autovoice for $chan is not set | .halt }
}

on *:text:!autovoice help:#: {
  if ($me !isop $chan) { notice $nick 4 $+ ERROR - I will only function on channels where i am opped | .halt }
  notice $nick :: AUTOVOICE HELP ::
  notice $nick !autovoice on
  notice $nick !autovoice off
  notice $nick !autovoice status
  notice $nick :: Autovoice help ::
}

on *:join:#: {
  if ($me isop $chan) {
    if (% [ $+ autovoice. $+ [ $chan ] ] == on) {
      .mode $chan +v $nick
    }
  }
}