Reputation: 21
I'm currently trying to map out my inventory by using steamapi and python to put all items into a file. but some items have a custom textures that would also be needed, but i cant seem to find a way to get these urls. And i don't mean the pictures for the items themselves. websites like tf2b.com and backpack.tf2 can show you these pictures, item id and decal id. but there is very poor documentation.
If anyone knows anything, help is appreciated!
Upvotes: 0
Views: 28
Reputation: 21
turns out, im impatient as hell. so i brute forced it!
any item with a custom texture has these two attributes : (defindex:152) hi and (defindex:227) lo
Its the decal id split into 32 bits (32 high bits,32 lower bits)
you can reconstruct it like this:
def reverse_seed(lo, hi):
# Combine the high and low parts to reconstruct the original seed
seed = (lo << 32) + hi
return seed
Pretty easy! then you have to pass it through https://api.steampowered.com/ISteamRemoteStorage/GetUGCFileDetails/v1/?key={STEAM_API_KEY}&ugcid={seed}&appid=440 To get the full url!
there's probably an easier way, but i don't care. it works.
Upvotes: 1