All pastes #511535 Raw Edit

Untitled

public text v1 · immutable
#511535 ·published 2007-05-26 14:33 UTC
rendered paste body
on *:TEXT:!bpcoff:#pc: {
  if (%pcscript == off) { halt }
  elseif ($nick isop $chan || $nick ishop $chan || $nick isvoice $chan) {
    set %pcscript off
    msg $chan 8,1Pestcontrol script turned off blame 9,1 $nick $+ .
  }
}
on *:TEXT:!bpcon:#pc: {
  if (%pcscript == on) { halt }
  elseif ($nick isop $chan || $nick ishop $chan || $nick isvoice $chan) {
    set %pcscript on
    msg $chan 8,1Pestcontrol script turned on thank 9,1 $nick .
  }
}

on $*:text:/^[!](change|setworld|setpcw) */Si:#pc: {
  if (%pcscript == off) { halt }
  else {
    if ($nick isop $chan || $nick ishop $chan || $nick isvoice $chan) && ($2 isnum 2-144) {
      set %pcw $2
      set %pcname $nick
      set %pctime $ctime
      msg $chan 8,1The pcworld has been changed to9,1 %pcw 8,1by9,1 $nick
    }
  }
}
on $*:text:/^[!](pcw|world)/Si:#pc: {
  if (%pcscript == off) { halt }
  else {
    inc %pcused
    notice $nick 8,1The current pcw is9,1 %pcw 8,1set by 9,1 %pcname 8,1 set9,1 $duration($calc($ctime - %pctime)) 8,1 ago. This command has been used %pcused times.
  }
}


on $*:TEXT:/^[!@](wsuggest|suggest|worldsuggest|sworld|suggestworld).*/Si:#pc: {
  if (%pcscript == off) { halt }  
  if ($null == %suggest. [ $+ [ $nick ] ]) {
    if ($2 isnum 1-144) {
      if ($2 !isin $read(freeworlds.txt, w, $2)) {
        if ($2 != %pc) {
          inc %suggests. [ $+ [ $2 ] ]
          set %lastsuggest $2
          if (15 == %suggests. [ $+ [ %lastsuggest ] ]) {
            set %pcw %lastsuggest
            set %pcnick suggestions
            set %pctime $ctime
            msg #pc 9,1The new PC world is:8,1 %pcw $+ . 9,1 Suggest a new one with !suggest world number. Example: !suggest 79 9,1(set by suggestions)
            unset %suggests.*
            unset %suggest.*
            unset %lastsuggest
            halt
          }
          set -z %suggest. [ $+ [ $nick ] ] 600
          .notice $nick Your suggestion for world change has been noted. World3 $2 needs3 $calc(15 - $+(%,suggests.,$2)) more votes to be changed.
          halt
        }
        else {
          .notice $nick The world you suggested is the current world.
          halt
        }
      }
      else {
        .notice $nick The world you suggested is f2p.
        halt
      }
    }
    else {
      .notice $nick The world can only be from 1-144.
      halt
    }
  }
  else {
    .notice $nick You have suggested recently, please wait before suggesting again.
    halt
  }
}
ctcp *:worldsay:?: msg #pc 9,1The current pcworld is8,1 %pcw $+ .
raw 438:?:{
  quit RESTARTING UC.
  server irc.swiftirc.net +6697
}