Closed CriticalFlaw closed 6 years ago
Sorry, just realized you said TF2 is working but others aren't. I'll investigate others.
I changed the PcRequirements
, MacRequirements,
and LinuxRequirements
properties to dynamic
since it appears that the Steam Web API returns an object or an array for these fields depending on the game. The latest nuget package should fix this issue. Let me know. Thanks.
Downloaded the latest nuget package, it fixed the problem, thanks! Sometimes, when GetStoreAppDetailsAsync is called it'll return a null object reference exception, not sure what that's related to, so I've put it in a loop until a valid game is returned: https://github.com/CriticalFlaw/FlawBOT/commit/8dc088eb0b3b6f5ea6dafff7daf6e2077785610d
I'm making a command for a Discord bot that pulls a random game from Steam. It gets a random AppID from a preloaded list then calls GetStoreAppDetailsAsync to get the game information. For certain games, namely Team Fortress 2 it works fine but for most others it throws an error, screenshot below.
Apologies if this is a newbie question, I'm fairly new to working with JSON and APIs.
Thanks!