Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ON !*:TEXT:!uptime:#: {
- var %s = upt_ $+ $ticks $+ $rand(1,1000000)
- if ($sock(%s)) { sockclose %s }
- sockopen %s nightdev.com 80
- sockmark %s $nick $chan
- }
- ON *:SOCKOPEN:upt_*: {
- if ($sockerr) {
- var %n = $gettok($sock($sockname).mark,1,32)
- var %c = $gettok($sock($sockname).mark,2,32)
- if ($me ison %c) && (%n ison %c) { .msg %c ( $+ %n $+ ): Error, There was an connection opening error to the nightdev.com website! }
- sockclose $sockname
- return
- }
- sockwrite -n $sockname GET /hosted/uptime.php?channel=riotgames2 HTTP/1.1
- sockwrite -n $sockname Host: $sock($sockname).addr
- sockwrite -n $sockname User-Agent: */*
- sockwrite -n $sockname Connection: close
- sockwrite -n $sockname $crlf
- }
- ON *:SOCKREAD:upt_*: {
- if ($sockerr) {
- var %n = $gettok($sock($sockname).mark,1,32)
- var %c = $gettok($sock($sockname).mark,2,32)
- if ($me ison %c) && (%n ison %c) { .msg %c ( $+ %n $+ ): Error, There was an connection reading error to the nightdev.com website! }
- sockclose $sockname
- return
- }
- var %r
- sockread %r
- var %n = $gettok($sock($sockname).mark,1,32)
- var %c = $gettok($sock($sockname).mark,2,32)
- if ($chr(44) isin %r) && (*date* !iswm %r) {
- if ($me ison %c) && (%n ison %c) { .msg %c ( $+ %n $+ ): RiotGames2 Uptime: %r }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement