globals
This commit is contained in:
parent
dfb6cfd598
commit
24120b41b4
|
|
@ -35,6 +35,7 @@ try
|
|||
$clientUserAgent = "Roblox/WinInet";
|
||||
$ROBLOXAssetAPI = "https://assetdelivery.roblox.com/v1/asset/?id=";
|
||||
$ROBLOXProductInfoAPI = "https://api.roblox.com/marketplace/productinfo?assetId=";
|
||||
$ROBLOXAssetThumbnailAPI = "https://thumbnails.roblox.com/v1/assets?assetIds=";
|
||||
|
||||
//default character hashes
|
||||
$defaultOutfitHash = "e335382cb0ef996df9053df58adcbe95"; //default render hash for characters
|
||||
|
|
|
|||
|
|
@ -3540,6 +3540,11 @@ function getUserGearsAccoutrements($userid) //ghetto
|
|||
return $gears;
|
||||
}
|
||||
|
||||
function getRobloxAssetThumbnail($assetid, $width, $height, $fileformat)
|
||||
{
|
||||
return json_decode(file_get_contents($GLOBALS['ROBLOXAssetThumbnailAPI'].$assetid."&size=".$width."x".$height."&format=".$fileformat."&isCircular=false"))->data[0]->imageUrl;
|
||||
}
|
||||
|
||||
function getRobloxProductInfo($assetid)
|
||||
{
|
||||
$json = file_get_contents($GLOBALS['ROBLOXProductInfoAPI'].$assetid);
|
||||
|
|
|
|||
|
|
@ -71,6 +71,5 @@ if ($check->rowCount() > 0) //asset exists on Alphaland
|
|||
}
|
||||
else
|
||||
{
|
||||
$json = json_decode(file_get_contents("https://thumbnails.roblox.com/v1/assets?assetIds=".$aid."&size=".$wd."x".$ht."&format=".$fmt."&isCircular=false"));
|
||||
redirect($json->data[0]->imageUrl);
|
||||
redirect(getRobloxAssetThumbnail($aid, $wd, $ht, $fmt));
|
||||
}
|
||||
Loading…
Reference in New Issue