on *:START: {
set %pdeactivity 0
set %pdewait 1
set %rawblocked 0
.timerremovewait 1 10800 { %pdewait = 0 }
}
on *:INPUT:#PDE: {
if (/* !iswm $1) {
inc %pdeactivity
.timer 1 10800 { dec %pdeactivity }
}
}
on *:TEXT:*:#PDE: {
if ($nick != ChanServ) {
inc %pdeactivity
.timer 1 10800 { dec %pdeactivity }
}
if ($1- == !activity && !%rawblocked) {
if (!%pdewait) {
%rawblocked = 1
if (%pdeactivity < 1) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (No activity)
}
elseif (%pdeactivity < 30) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (Very very low activity)
}
elseif (%pdeactivity < 75) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (Very low activity)
}
elseif (%pdeactivity < 100) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (Low activity)
}
elseif (%pdeactivity < 200) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (Average activity)
}
elseif (%pdeactivity < 350) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (High activity)
}
elseif (%pdeactivity < 500) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (Very high activity)
}
elseif (%pdeactivity < 700) {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (Very very high activity)
}
else {
notice $nick 14[12Automated message14] In the last 3 hours I recorded %pdeactivity messages being sent to this channel. (WALLOFTEXT)
}
.timer 1 2 { %rawblocked = 0 }
}
else {
notice $nick 14[12Automated message14] Sorry, but I have been in this channel for less than 3 hours, so I cannot hand out precise activity information, yet. I have logged %pdeactivity messages being sent to this channel so far, though.
}
}
}