on *:join:#pball: .timertuptime 0 3600 tuptime
on *:part:#pball: .timertuptime off
on *:text:!uptime:#pball: tuptime
alias tuptime {
if (%tuptimespam) halt
else set -u10 %tuptimespam 1
sockopen tuptime nightdev.com 80
}
on *:sockopen:tuptime: {
sockwrite -nt $sockname GET /hosted/uptime.php?channel=obeewnn HTTP/1.1
sockwrite -nt $sockname Host: nightdev.com
sockwrite -n $sockname
}
on *:sockread:tuptime: {
sockread %tuptime.result
while ($sockbr) {
if (not live isin %tuptime.result) msg #pball The streaming is currently offline.
elseif (minute isin %tuptime.result) msg #pball oBeE has been streaming for %tuptime.result
sockread %tuptime.result
}
}