on $*:TEXT:/^[!@]price/Si:#: { if ($2- == $null) { $iif($left($1,1) $+(=,=) @ && $istok($readini(botinfo.ini,n,IgnoreChannel,Channels),$chan,32) $+(=,=) $false,msg $chan,notice $nick) *** $+($chr(91),$c1($nick,Price),$chr(93),:) $c2($nick,You must specify an item to lookup.) halt } var %x 1 while ($sock(price. $+ %x)) { inc %x } sockopen $+(price.,%x) zybez.net 80 sockmark $+(price.,%x) 0 $+ ~ $+ $iif($left($1,1) == @ && $istok($readini(botinfo.ini,n,IgnoreChannel,Channels),$chan,32) $+(=,=) $false,msg $chan,notice $nick)nick) $+ ~ $+ $replace($2-,$chr(32),$chr(43)) $+ ~ $+ $nick } on *:SOCKOPEN:price.*: { sockwrite -nt $sockname GET /priceguide.php?search_terms= $+ $gettok($sock($sockname).mark,3,126) $+ &search_area=1&price_low=&price_high=&member=1 HTTP/1.1 sockwrite -nt $sockname Host: www.zybez.net sockwrite -nt $sockname $crlf } on *:SOCKREAD:price.*: { var %read,%price,%name var %price sockread %read if (*>= %attstr,$v2,N/A) $iif($calc(198 - $calc($4 + $5)) >= %defhit,$v2,N/A) $iif($calc(99 - $7) >= %pray,$v2,N/A) $iif($calc(99 - $9) >= %summon,$v2,N/A) } alias -l FNL2 return $bytes($ceil($calc($1 / $2)),db) alias -l c1 return $+($chr(3),$iif($readini(botinfo.ini,n,defcolor,$address($1,3)),$v1,07),$2-,$chr(3)) alias -l c2 { if ($readini(botinfo.ini,n,defcolor2,$address($1,3))) { return $+($chr(3),$v1,$2-,$chr(3)) } else { return $2- } } alias -l htmlfree { var %x, %i = $regsub($1-,/(^[^<]*>|<[^>]*>|<[^>]*$)/g,$null,%x), %x = $remove(%x, ) return %x }