I still hope someone can help just tiny bit here, got it changed alot now, using a £gettok parser to find whatever i need.
alias parser {
return $gettok($gettok($1,-3,$asc(<)),2,$asc(>)) }
alias mpuktf2 {
if ($sock(mpuktf2)) { sockclose mpuktf2 }
sockopen mpuktf2 tf2.multiplay.co.uk 80
set %chan $chan
set %playerid $1-
set %host_url /hlstats/hlstats.php?mode=playerinfo&player= $+ %playerid
}
on *:SOCKOPEN:mpuktf2: {
sockwrite -n $sockname GET %host_url HTTP/1.1
sockwrite -n $sockname Host: tf2.multiplay.co.uk
sockwrite -n $sockname Connection: Keep-Alive
sockwrite -n $sockname $crlf
}
on *:sockread:mpuktf2: {
if ($sockerr > 0) return
:nextread
var %x
sockread %x
if ($sockbr == 0) return
if (%x == $null) return
goto nextread
if (*Rank:* iswm %x) {
echo -a %chan Rank: $parser(%x)
}
sockclose mpuktf2
}
But this still doesn't seem to work as intented.
If i put the if before the goto nextread, i echoes:
Rank: Rank:
Rank:
But no rank what so ever, it just wont get that number for me.
Any hints?