JustArchiNET / ArchiSteamFarm

C# application with primary purpose of farming Steam cards from multiple accounts simultaneously.
Apache License 2.0
11.27k stars 1.05k forks source link

ASF "plays" region locked game but does not drop cards and no play time is counted #2980

Closed JustArchi closed 1 year ago

JustArchi commented 1 year ago

Discussed in https://github.com/JustArchiNET/ArchiSteamFarm/discussions/2979

Originally posted by **shigutso** August 4, 2023 My Steam account is from South America, but I am temporarily living in another region. One of my games that has cards to drop is region locked and I cannot install it from my current country even if my account has the game (see image below). The region I am in has support for the game, but my game was activated using a Humble Bundle key that looks like is only compatible with South American Steam accounts. Steam detects I am not in my home country and does not let me install the game. This only happens with a few games. I can play 99% of my games without any issues, Even games that do not exist in my current country. Game: Road 96 https://steamdb.info/app/1466640/ ![image](https://github.com/JustArchiNET/ArchiSteamFarm/assets/5687102/1dce04c9-6310-4b07-b43e-d34e5d553b29) The issue is that ASF detects the game has card drops remaining and it says it's playing the game, but when I go to my profile, game time is never added and no cards are obtained even after several hours of idling: ``` 2023-08-02 18:53:43|ArchiSteamFarm-12345|INFO|user|Init() Logging in to ISteamUserAuth... 2023-08-02 18:53:43|ArchiSteamFarm-12345|INFO|user|Init() Success! 2023-08-02 18:53:46|ArchiSteamFarm-12345|INFO|user|IsAnythingToFarm() Checking first badge page... 2023-08-02 18:53:47|ArchiSteamFarm-12345|INFO|user|Farm() We have a total of 1 games (4 cards) left to farm (~5 hours remaining)... 2023-08-02 18:53:47|ArchiSteamFarm-12345|INFO|user|Farm() Chosen farming algorithm: Complex 2023-08-02 18:53:48|ArchiSteamFarm-12345|INFO|user|FarmMultiple() Now farming: 1466640 (Road 96) 2023-08-02 18:53:48|ArchiSteamFarm-12345|INFO|user|FarmHours() Still farming: 1466640 ``` I am not sure if this is a bug with ASF that needs to be reported or if this is an issue that I can fix with a config option. Is it possible for ASF to ignore this game, or is there a workaround to be able to drop the cards? I tried connecting to a VPN to my home country but looks like Steam is smart enough to detect I am using a VPN and the same issue happens: ASF thinks it's playing the game but it is not and the Steam client doesn't allow me to install the game. Thanks in advance
JustArchi commented 1 year ago

@shigutso This looks like a bug to me. ASF currently does not check if we can play the game since, as stated in the FAQ, it used to work automagically just fine and backend didn't deny the request.

Perhaps this mechanism changed, maybe recently, maybe a while ago and nobody reported it. In any case, Steam client somehow knows if we can play the game or not in currently connected instance, ASF needs the same logic, which currently simply isn't available.

This will take a while, probably longer while, since it requires some reverse-engineering of finding out how Steam determines that first, and only then coding logic for it. I recommend you to use ibadd command to blacklist that appID for now - you can find more info about this on the wiki.

shigutso commented 1 year ago

Thanks for the quick reply. I will try connecting to a temporary remote machine to drop these cards for this specific game. Let me know if you need more info from my side.

JustArchi commented 1 year ago

I'll most likely need a verification that the method I implement works as it should by determining your road 96 is unavailable to idle, but don't worry about that, not now since I don't have solution yet, neither time at the moment to dig into this.

JustArchi commented 1 year ago

If anybody is interested in digging into this for me, be my guest, I don't have much time lately for reverse-engineering matters.

JustArchi commented 1 year ago

@shigutso I'll need your help to go forward with this issue.

Please enable debug mode in ASF by setting Debug global config property to true, you can read more about debug mode on the wiki.

Afterwards, launch ASF with the affected (region locked) bot instance, let it log in and find stuff to idle, once it detects your faulty app and tries to idle it (and fails), simply close the app. If you don't have that game available for idling anymore, that's not a problem at this point, simply wait for it to start idling something else or for it to state that nothing is available to idle and then you can close the app.

In ASF directory there will be newly-generated debug directory, pack this whole folder to a zip file, then send to my e-mail address: JustArchi[at]JustArchi[dot]net. Please note that this folder and therefore zip file contains sensitive information, as stated on the wiki, therefore ensure you send it privately and NOT attach e.g. to this GitHub issue.

This will allow me to dig more into the data Steam sent you and try to guess what it uses to claim that app is restricted, as I have no access to region restricted apps myself.

shigutso commented 1 year ago

Hi, sorry for the super late reply.

I got 2 more games with the same issue. I used "GamesPlayedWhileIdle" to force them to idle even without cards to drop. The following games are: https://store.steampowered.com/app/1577120/The_Quarry/ https://store.steampowered.com/app/1466640/Road_96/ https://store.steampowered.com/app/1286680/Tiny_Tinas_Wonderlands/

I sent you an email with the debug zip, as requested.

Good news is that after some web searches looks like region locked games on Steam are "unlocked" after 3 months, probably just to prevent people from abusing the regional prices of some countries. So eventually ASF would be able to drop the cards.

JustArchi commented 1 year ago

Alright, thanks a lot for your help, this took me extraordinary effort to code it in, but with the details you provided (especially debug zip), I believe I got all the parts right and ASF is now able to detect the situation above and gracefully skip apps that we're not allowed to idle at this point.

Whether it works properly or not, we'll find out, it did work properly when I faked your situation with your provided debug logs, so I'm optimistic about that - introduced firstly in V5.4.13.3.