on $*:text:/^[!@]stats (-s)?.{1,12}$/Si:#:{ if ($sock(stats).status != $null) { notice $nick Stats Script is in use. Try again.... now! | halt } if ($left($1,1) == @) && ($left($remove($chan(#).mode,+),1) === c) || ($right($left($remove($chan(#).mode,+),2),1) === c) { set %stats.cstrip on } if ($2 == $null) && ($readini($scriptdirnamedb.ini,RS-Names,$address($nick,3)) == $null) { notice $nick Please Store your RSN via $1 -s your-rsn | halt } set %stats.nick $nick | set %stats.send $iif($left($1,1) == @,.msg $chan,.notice $nick) if ($2 == -s) { writeini namedb.ini RS-Names $address($nick,3) $replace($3-,$chr(32),+) | %stats.msg Name Stored Successfully. | unset %stats.* | halt } if ($2- != -s) { set %stats.rsn $replace($2-,$chr(32),+) } if ($2- == $null) && ($readini($scriptdirnamedb.ini,RS-Names,$address($nick,3)) != $null) { set %stats.rsn $replace($readini($scriptdirnamedb.ini,RS-Names,$address($nick,3)),$chr(32),+) } sockopen stats vulcan.ueuo.com 80 ;msg color 1; set %stats.color1 $+($chr(3),14) ;msg color 2; set %stats.color2 $+($chr(3),10) } on *:sockopen:stats:{ if ($sockerr) { .notice %stats.nick Stats Script SockOpen Error: $sock(stats).wsmsg | echo -s Stats Script SockOpen Error: $sock(stats).wsmsg | unset %stats.* | return } sockwrite -nt $sockname GET /geniestats.php?rsname= $+ %stats.rsn HTTP/1.0 sockwrite -nt $sockname Host: vulcan.ueuo.com $+ $str($crlf,2) } on *:sockread:stats:{ if ($sockerr > 0) { .notice %stats.nick Stats Script SockRead Error: $sock(stats).wsmsg | echo -s Stats Script SockRead Error: $sock(stats).wsmsg | unset %stats.* | return } var %stats.read | sockread %stats.read if (Personal isin %stats.read) { set %stats.name $remove(%stats.read,Personal $+ $chr(32),Scores $+ $chr(32),For $+ $chr(32),,) | set %stats.text $remove(%stats.read,,) | set %stats.text $left(%stats.text,- $+ $len(%stats.name)) } tokenize 124 $remove(%stats.read,Genie:) if ($0 == 4) { set %stats.printline1 %stats.printline1 $eval($+(%stats.color1,$1,:,%stats.color2),2) $3 } } on *:sockclose:stats:{ stat_check } alias -l stat_check { if (%stats.printline1 != $null) { %stats.send $iif(%stats.cstrip != $null,%stats.text %stats.name,$+(%stats.color1,%stats.text,%stats.color2) %stats.name) | %stats.send %stats.printline1 | unset %stats.* | halt } else { %stats.send $iif(%stats.cstrip != $null,This person doesnt appear in any skill listed on the hiscores,%stats.color1 $+ This person doesnt appear in any skill listed on the hiscores.) | unset %stats.* | halt } } on $*:TEXT:/^[!@](math|calc) .*$/Si:#:{ if ($left($1,1) == @) && ($left($remove($chan(#).mode,+),1) === c) || ($left($remove($chan(#).mode,+),2) === c) { set %math.color.strip on } if ($remove($2-,+,-,/,*,x,^,$chr(40),$chr(41),$chr(44),$chr(46),m,k,b,t) !isnum) { unset %math.* | halt } set %math.send $iif($left($1,1) == @,.msg $chan,.notice $nick) | set %math $remove($replace($2-,k,000,m,000000,b,000000000,t,000000000000,x,*),$chr(44),$chr(46)) | %math.send $iif(%math.color.strip != $null,$2- = $bytes($calc(%math),bd),14 $+ $2- =07 $bytes($calc(%math),bd)) | unset %math | unset %math.send | halt } on $*:text:/^[!@](rs2|server|serv) .{1,4}$/Si:#:{ if ($sock(server).status != $null) { notice $nick Please Try Again In a Minute. | halt } if ($left($1,1) == @) && ($left($remove($chan(#).mode,+),1) === c) || ($right($left($remove($chan(#).mode,+),2),1) === c) { set %rs2.color.strip on } set %rs2.nick $nick | set %rs2.send $iif($left($1,1) == @,.msg $chan,.notice $nick) | set %rs2.server $2 | set %rs2.color1 $+($chr(3),14) | set %rs2.color2 $+($chr(3),10)) if (%rs2.server < 1) || (%rs2.server > 132) { .notice $nick Choose an RS2 Server Between 1-132 | unset %rs2.* | halt } sockopen server vulcan.ueuo.com 80 } on *:sockopen:server:{ if ($sockerr) { echo -s Rs2 Server Population Script SockOpen Error: $sock(server).wsmsg | .notice %rs2.nick Rs2 Server Population Script SockOpen Error: $sock(server).wsmsg | break } sockwrite -nt $sockname GET /genieserv2.php?world= $+ %rs2.server HTTP/1.1 sockwrite -nt $sockname Host: vulcan.ueuo.com $+ $str($crlf,2) } on *:sockread:server:{ if ($sockerr) { echo -s Rs2 Server Population Script SockRead Error: $sock(server).wsmsg | .notice %rs2.nick Rs2 Server Population Script SockRead Error: $sock(server).wsmsg | break } var %read | sockread %read tokenize 124 $remove(%read,Genie:) if ($0 == 6) { set %rs2.servernum $1 | set %rs2.players $2 | set %rs2.location $3 | set %rs2.servertype $4 | set %rs2.serverpct $5 | set %rs2.totalplayers $6 } } on *:sockclose:server:{ if (%rs2.players == 2000) { %rs2.output = %rs2.color1 $+ World $+ %rs2.color2 %rs2.servernum %rs2.color1 $+ is a %rs2.color2 $+ %rs2.servertype %rs2.color1 $+ World located in $+ %rs2.color2 %rs2.location %rs2.color1 $+ . This World Is Currently %rs2.color2 $+ FULL $+ %rs2.color1 $+ . %rs2.color2 $+ %rs2.serverpct %rs2.color1 $+ Of The %rs2.color2 $+ $bytes(%rs2.totalplayers,b) %rs2.color1 $+ RS Players Can Be Found On This World. } if (%rs2.players < 2000) { %rs2.output = %rs2.color1 $+ World $+ %rs2.color2 %rs2.servernum %rs2.color1 $+ is a %rs2.color2 $+ %rs2.servertype %rs2.color1 $+ World located in $+ %rs2.color2 %rs2.location $+ %rs2.color1 $+ . You Can Find $+ %rs2.color2 $bytes(%rs2.players,b) %rs2.color1 $+ ( $+ %rs2.color2 $+ $calc((%rs2.players /2000)*100) $+ % Full $+ %rs2.color1 $+ ) Players On This World Which Is About %rs2.color2 $+ %rs2.serverpct %rs2.color1 $+ Of The %rs2.color2 $+ $bytes(%rs2.totalplayers,b) %rs2.color1 $+ RS Players. } %rs2.send $iif(%rs2.color.strip != $null,$strip(%rs2.output,c),%rs2.output) | unset %rs2.* | halt }