on *:TEXT:*!pestcontroloff*:#: {
if (%pestcontroloffon [ $+ [ $chan ] ] == off) { .notice $nick The pestcontrol script for $chan is already off }
if (%pestcontroloffon [ $+ [ $chan ] ] == off) { halt }
if (($nick isop $chan) || ($nick ishop $chan) || ($nick == aturner44)) { set %pestcontroloffon $+ $chan off }
{ .msg $chan The pestcontrol script for $chan is now off }
}
on *:TEXT:*!pestcontrolon*:#: {
if (%pestcontroloffon [ $+ [ $chan ] ] == on) { .notice $nick The pestcontrol script for $chan is already on }
if (%pestcontroloffon [ $+ [ $chan ] ] == on) { halt }
if (($nick isop $chan) || ($nick ishop $chan) || ($nick == aturner44)) { set %pestcontroloffon $+ $chan on }
{ .msg $chan The pestcontrol script for $chan is now on }
}
on $*:TEXT:/^([!@]setpcw|[!@]setworld)/Si:#:{
/illegalcheck $1-
if ($chan == #bots) { HALT }
if (%pestcontroloffon [ $+ [ $chan ] ] == OFF) { HALT }
if ($nick isreg $chan) { notice $nick Sorry you have to be (+)/(%)/(@) to do that. | halt }
if (%pm1 [ $+ [ $chan ] ] == on && $nick isvoice $chan || $nick isreg $chan) { notice $nick Sorry you have to be (%)/(@) to do that. | halt }
if ($2- !isnum) { notice $nick Sorry you have to set a numerical world! | halt }
set %pcwnickname [ $+ [ $chan ] ] $nick
if ($nick isop $chan || $nick ishop $chan || $nick isvoice $chan) {
writeini -n world.ini pcw $chan pcw
$iif($2 != $null,writeini -n world.ini pc $chan $2,writeini -n world.ini pc $chan No world set)
writeini -n world.ini time $chan $ctime
.msg $chan The pc world has been updated by $nick
if (%pcwtimer [ $+ [ $chan ] ] == on) {
timerpcw [ $+ [ $chan ] ] off
timerpcw [ $+ [ $chan ] ] 0 30 msg $chan [World]: $readini(world.ini,n,pc,$chan) [Suggested]: $readini(suggest.ini,n,sugest,$chan) [Set bye]: %pcwnickname [ $+ [ $chan ] ]
}
}
}
on $*:TEXT:/^([!@]pcw|[!@]world)/Si:#:{
if (%pcwtimer [ $+ [ $chan ] ] == on) { notice $nick Please dont use the !pcw command as the pcw world is shown every 30 seconds! | halt }
/illegalcheck $1-
if (%pestcontroloffon [ $+ [ $chan ] ] == OFF) { HALT }
if ($readini(world.ini,n,pcw,$chan)) {
notice $nick [World]: $readini(world.ini,n,pc,$chan) [Suggested]: $readini(suggest.ini,n,sugest,$chan) [Set by]: %pcwnickname [ $+ [ $chan ] ]
}
}