steamworks.gml icon indicating copy to clipboard operation
steamworks.gml copied to clipboard

LoadLibraryA failed with error code 126

Open HanaThough opened this issue 5 years ago • 5 comments

(edit) Okay originally I was having issues with the .dll file not existing, but I've now realized that I needed to compile that myself through visual studio. I've done that and got it working 100% on the demo project, but now for some reason every time I try to run the extension (making no changes) on my actual project I get "LoadLibraryA failed with error code 126" errors spammed in the logs, followed by "Initializing steamworks.gml with app_id -1..." and "Steamworks.gml binary is not loaded." I'm not sure what is causing this, any help is appreciated!

HanaThough avatar Sep 20 '20 06:09 HanaThough

Did you enable Steam in your project? You'll need to both tick the "enable steam" under Windows and enter a valid App ID (that your logged on user has permissions for) in Main Options image

YellowAfterlife avatar Sep 20 '20 12:09 YellowAfterlife

Oh I can't believe I missed the Enable Steam button in the windows settings! It's working now, thank you! I have another issue though, I'm trying to set up sandboxie so that I can test two instances of the game at once. And I got it functioning to a point where I have two instances of the game running at once, one in the sandbox and one outside of it. But with the one in the sandbox it doesn't seem to be working properly even though I have steam open in the sandbox. The one outside of the sandbox work's fine, but the one in the sandbox doesn't give me any issues with calling "steam_net_check_version()" however it doesn't seem to register as logged in with steam. When I use the "steam_get_persona_name()" it returns an empty string.

HanaThough avatar Sep 21 '20 05:09 HanaThough

Make sure that sandboxed Steam is functioning correctly - if your library view is black or the friends list is missing / showing you as offline, it is not functioning correctly and you might have to run sandboxed Steam as an administrator.

Also note that steam_get_persona_name is a built-in GM function rather than something from this extension.

YellowAfterlife avatar Sep 21 '20 11:09 YellowAfterlife

I'm aware, after further testing I found out that your extension doesn't give any issues when using "steam_net_check_version()" but trying to call any other commands doesn't behave properly. And built-in GM functions like "steam_get_persona_name()" aren't working either. Sorry for asking so many questions, but I would really like to use this extension and I can't do network testing till I get two versions running side by side. Do you know of anything else that could be causing issues? Maybe some settings I should/shouldn't enable for Sandboxie? When I run steam in Sandboxie it seems to function properly, no black screen, friends list is working, etc; but only the second window of my game that is running in Sandboxie isn't working. The main window works fine.

HanaThough avatar Sep 21 '20 20:09 HanaThough

Hard to tell, really - I just tried compiling an empty project from GMS2.2.5 and GMS2.3 and both work fine in Sandboxie (drawing steam_initialised and steam_get_persona_name) image My sandboxed Steam shortcut has -inhibitbootstrap and is marked as "run as administrator". I don't think I've done any other setup for this.

YellowAfterlife avatar Sep 22 '20 08:09 YellowAfterlife