gamevault-app icon indicating copy to clipboard operation
gamevault-app copied to clipboard

Steam Integration Issue

Open Sixdd6 opened this issue 1 year ago • 11 comments

Describe the bug When launching a game through Steam the game opens in the background. Steam also doesn't recognize that the game is running so you can't use steam to stop the game either. I'm guessing that it has something to do with launching the games through a uri rather than linking to the executable but I'm no programmer so who knows.

To Reproduce Steps to reproduce the behavior:

  1. Install a game in GameVault
  2. Restart steam to refresh games
  3. Launch your game though Steam (I tested with Cuphead and Bomb Rush Cyberfunk)
  4. Game will start but will be in the background

Expected behavior Game should start focused in the foreground.

Desktop (please complete the following information):

  • OS: Windows 11
  • Browser: Brave (chromium)
  • GameVault Version: 1.14.0

Sixdd6 avatar Jan 05 '25 01:01 Sixdd6

Did some further thesting, this is definitely related to launching through the gamevault uri. If you add the game executable to steam rather than the uri it launches properly and steam can recognize the process running.

Hopefully this info is helpful.

Sixdd6 avatar Jan 05 '25 01:01 Sixdd6

Steam opens Gamevault via the URI protocol, that is correct. The reason for this is that Gamevault itself should perform the launch of the game, as other actions can be executed in addition to the actual launch of the game.

I have tested with my own games, but have not yet been able to reproduce the problem. I will try again with the games you mentioned.

“Game will start but will be in the background” what exactly does that mean in your case? Is there an app that pushes itself into the foreground? E.g. Steam or Gamevault itself?

Yelo420 avatar Jan 06 '25 14:01 Yelo420

I went ahead and recorded a video showing what I'm seeing on my end. In the video I start by showing the steam shortcut to the link that gamevault created and launch it, then I show the shortcut I made directly to the exe and launch it. The difference is that the link gamevault creates causes steam to stay in the foreground but the one linking directly to the exe opens the game with steam in the background. This is also the behaviour I experience with all games added by gamevault, not just a few.

https://youtu.be/ADcKPkW_KNY

Sixdd6 avatar Jan 06 '25 18:01 Sixdd6

Thanks for the video. Seems to be a known issue with Steam pushing itself to the foreground. Does this happen with all your games without exception? I'll take a closer look at this.

Yelo420 avatar Jan 06 '25 18:01 Yelo420

It only happens to games from gamevault. Anything that I have added from steam rom manager are fine as well as native steam games themselves are fine.

EDIT1: Out of curiosity, are you on the Steam beta branch? I'm not and I wonder if that would fix the issue. EDIT2: Tried the beta just now and no change.

Sixdd6 avatar Jan 06 '25 18:01 Sixdd6

Do you have the same problem if you start the games directly via GameVault?

Yelo420 avatar Jan 07 '25 09:01 Yelo420

Launching through Gamevault directly works as intended.

Sixdd6 avatar Jan 07 '25 09:01 Sixdd6

@Sixdd6

It's really a pain in the ass to analyze the cause. It definitely has something to do with the URL protocol and how Steam tries to force itself to the foreground and attaches to the launched process to track it's running or something. We've just shipped some slight tweaks regarding this issue. Currently, I see four scenarios:

  1. GameVault is running in the background, and you launch the game via Steam Desktop.
  2. GameVault is not running in the background, and you launch the game via Steam Desktop.
  3. GameVault is running in the background, and you launch the game via Steam Big Picture.
  4. GameVault is not running in the background, and you launch the game via Steam Big Picture.

In any case the game should launch in the Foreground ofc. We just shipped some tweaks in the latest version and will try to solve as many of these scenarios as possible. Could you try and tell me what the outcomes of these scenarios are on your system with Client Version 1.15.0.0?

We use the URL Protocol to be independent of where Microsoft installs your GameVault Updates. It is quite handy.

Alfagun74 avatar Feb 26 '25 09:02 Alfagun74

Here are the results of the tests.

  1. Success, game started without issue and in the foreground
  2. Fail, Gamevault started but didn't open the game and Steam was stuck saying the game was running (most likely attached to the gv process rather than the game)
  3. Success, did have to press play twice but it worked fine the second time
  4. Fail, Gamevault did start but Steam was stuck trying to start the game and stopped responding to controls. After alt-F4 on Big Picture steam desktop reloaded and showed the game a Playing even though the game never launched (probably same issue as scenario 2)

Sixdd6 avatar Feb 27 '25 01:02 Sixdd6

@Sixdd6 Does the new version of steam fix this issue? Update Notes " Fixed Steam Client window focusing multiple times on startup."

Toylerrr avatar Apr 01 '25 23:04 Toylerrr

I dont believe that Steam update fixed it, as I was still experiencing this as of a week or so ago.

KairuByte avatar Oct 14 '25 16:10 KairuByte