All pastes #819029 Raw Edit

Untitled

public text v1 · immutable
·published 2007-12-16 19:00 UTC
rendered paste body
set vPubchar "."

proc pPubchar {} {
  global vPubchar
  return $vPubchar
}

bind PUB lo|lo [pPubchar]add pAdduser

proc pAdduser {nick uhost hand chan text} {
  set arguments [split [string trim $text]]
  if {[llength $arguments] == 1} {
    set who [join [lindex $arguments 0]]
    if {[onchan $who]} {
      adduser $who
    } else {putserv "PRIVMSG $chan :$nick is not on a bot channel"}
  } else {putserv "PRIVMSG $chan :correct syntax is [pPubchar] <nick>"}
}