I got a problem with the GetUserStatsForGame Api. I used
http://api.steampowered.com/ISteamUserStats/GetUserStatsForGame/v0002/?appid=730&key=<<KEY>>&steamid=<<PROFILEID>>
.
How can i get the the playerstats?
I already tried this but it dosent work :/
if(!$_SESSION['steamid'] == ""){
include("settings.php");
if (empty($_SESSION['steam_uptodate']) or $_SESSION['steam_uptodate'] == false or empty($_SESSION['steam_personaname'])) {
@ $url = file_get_contents("http://api.steampowered.com/ISteamUserStats/GetUserStatsForGame/v0002/?appid=730&key=".$steamauth['apikey']."&steamids=".$_SESSION['steamid']);
$content = json_decode($url, true);
$_SESSION['total_kills'] = $content['playerstats']['stats']['total_kills'][0]['value'];
$_SESSION['steam_steamid'] = $content['response']['players'][0]['steamid'];
}
$csgoprofile['total_kills'] = $_SESSION['total_kills'];
}
Please help!