我一直在尝试在tf2中删除某个奇怪的项目,但我的结果总是返回空白。关于这是如何执行的,有什么线索吗?
这是我目前得到的:
$userBackpack = json_decode(file_get_contents($backpackURL), true);
<?php
foreach($userBackpack['result']['items'] as $ind=>$item)
{
if($item['defindex'] == 999)
{
$totalkills = $userBackpack['result']['items'][0]['attributes'][0]['defindex'];
if($item['attributes'][0]['defindex'] == "214")
{
echo $item['attributes'][0]['value'];
}
}
else { }
}
?>
214是API中奇怪杀戮的定义索引。
"attributes": [
{
"defindex": 189,
"value": 1093664768,
"float_value": 11
},
{
"defindex": 211,
"value": 1424797755,
"float_value": 8132551507968
},
{
"defindex": 214,
Looking for S kills -->`"value": 1000,
"float_value": 1.4012984643248171e-042
}
]