Hey i was bored so i checked this out and edited a bit for you.
All you have to do is load this on mIRC and input your channel name where it says INPUT_CHAN_HERE
The script will start checking for stream state when mIRC starts and you can also use /decapi to toggle the checking on or off.
alias livestream {
sockopen -e decapi decapi.me 443
}
alias decapi {
if ($timer(decapi).secs) { .timerdecapi off | echo -at The Stream Checker is now off }
elseif (!$timer(decapi).secs) { .timerdecapi 0 200 livestream | echo -at The Stream Checker is now on }
}
alias mytchan { return INPUT_CHAN_HERE }
on *:SOCKOPEN:decapi: {
sockwrite -nt $sockname GET $+(/twitch/uptime.php?channel=,$mytchan) HTTP/1.1
sockwrite -nt $sockname Host: decapi.me
sockwrite $sockname $crlf
}
on *:SOCKREAD:decapi: {
var %decapi
sockread %decapi
while ($sockbr) {
sockread %decapi
}
}
on *:sockclose:decapi: {
var %decapi
sockread -f %decapi
if (*not live* iswm %decapi) {
if (!%streamisoff) {
set -e %streamisoff 1
msg $+($chr(35),$mytchan) Stream is now off...
unset %streamison
}
}
else {
if (!%streamison) {
set -e %streamison 1
msg $+($chr(35),$mytchan) Stream is now on!
unset %streamisoff
}
}
}
ON *:START: { .timerdecapi 0 200 livestream }
I tested it and it works!
Enjoy!