ON $*:TEXT:/[!@.](Pest|PCW) off/Si:#:{
if ($readini(PCW.ini,$chan,Status) == OFF) {
notice $nick You cant turn something off that is not on.
halt
}
if ($nick isop $chan || $nick ishop $chan || $address($nick,2) == $address($me,2)) {
remini PCW.ini $chan
writeini PCW.ini $chan Status OFF
msg $chan The PestControl services have been halted by $nick
halt
}
else {
notice $nick You must be Halfop Plus to use this command.
}
}
ON $*:TEXT:/[!@.](Pest|PCW) On/Si:#:{
if (($nick isop $chan || $nick ishop $chan || $nick isvoice $chan || $address($nick,2) == $address($me,2)) && ($readini(PCW.ini,$chan,Status) == OFF)) {
remini PCW.ini $chan
msg $chan The PestControl services have been continued by $nick
halt
}
if ($readini(PCW.ini,$chan,Status) != OFF) {
notice $nick You cant turn ON whats not off.
halt
}
else {
notice $nick You must be Halfop Plus to use this command.
}
}
ON $*:TEXT:/[!@.]Set(PCW|world)/Si:#:{
if ($readini(PCW.ini,$chan,Status) == OFF) { halt }
if ($nick isop $chan || $nick ishop $chan || $nick isvoice $chan && ($2 isnum 2-140)) {
if ($2 == $readini(PCW.ini,$chan,world)) { notice $nick haha nice try | halt }
inc %changed [ $+ [ $nick ] ] 1
writeini PCW.ini $chan World $2
writeini PCW.ini $chan Nick $nick
writeini PCW.ini $chan Time $CTime
msg $chan The PestControl world has been changed by $nick $+ .
if ($2 > 140) {
notice $nick The world must be Between 2 and 40
halt
}
}
}
else {
notice $nick A PestControl world must be a number.
}
ON $*:TEXT:/[!@.]StopPCW/Si:#:{
if ($readini(PCW.ini,$chan,Status) == OFF) { halt }
if ($nick isop $chan || $nick ishop $chan || $nick isvoice $chan || $address($nick,2) == $address($me,2)) {
remini PCW.ini $chan
msg $chan All PestControl files for $chan have been deleted.
halt
}
}
if ($readini(PCW.ini,$chan,World) == $null) {
notice $nick
}
ON $*:TEXT:/^[!@.](Suggest|SugWorld)/Si:#:{
writeini PCW.ini $chan Worldz $2
writeini PCW.ini $chan Nickz $nick
writeini PCW.ini $chan Time $CTime
msg $chan The suggested world is » $readini(PCW.ini,$chan,worldz) « suggested by $readini(PCW.ini,$chan,Nickz).
halt
}
ON $*:TEXT:/^[!@.](Pcw|W|World)/Si:#:{
if ($nick isvoice $chan || $nick ishop $chan || $nick isop $chan) {
if ($readini(PCW.ini,$chan,Status) == OFF) { halt }
notice $nick The pcw is » $readini(PCW.ini,$chan,world) « set by $readini(PCW.ini,$chan,nick) .
halt
}
}
ON $*:TEXT:/^[!@.](Sw|Sworld|Suggested)/Si:#: {
if ($nick isvoice $chan || $nick ishop $chan || $nick isop $chan) {
notice $nick Last suggested world is » $readini(PCW.ini,$chan,world) « suggested by $readini(PCW.ini,$chan,Nickz) .
halt
}
}
on *:text:!sets*:#:{
if ($readini(PCW.ini,$chan,Status) == OFF) { halt }
if (!$2) {
if ($nick isreg $chan) { Halt }
if (%changed [ $+ [ $nick ] ] == $null) {
msg $chan You haven't set any worlds yet! | Halt
}
if ($nick isreg $chan) { Halt }
elseif (%changed [ $+ [ $nick ] ] != $null) {
msg $chan $+ $nick has set %changed [ $+ [ $nick ] ] worlds | Halt
}
}
else {
if ($nick isreg $chan) { Halt }
if (%changed [ $+ [ $2 ] ] == $null) {
msg $chan $+ $2 hasnt set any worlds | Halt
}
if ($nick isreg $chan) { Halt }
elseif (%changed [ $+ [ $2 ] ] != $null) {
msg $chan $+ $2 has set %changed [ $+ [ $2 ] ] worlds
}
}
}
}