samsface / godot-steam-api

Godot Steam integration using GDNative.
403 stars 16 forks source link

Add Leaderboard Entry Count #46

Closed hamoom closed 4 months ago

hamoom commented 4 months ago

I wanted to have entry count so that I could go to the bottom of my leaderboard. If you dont know the exact entry count and you put a random (large) number you end up with an empty array as a result.

I added the dylib and dll but i could only compile the dll in debug mode (prob why it came out so much bigger)

I noticed it only added about 600k when built into my game though.

I'm open to input on this.

samsface commented 4 months ago

Merged and built a new release. Can find the new .dll, .dylib and .so in the mater of this repo. Thanks for the PR.

If you do another commit, you don't need to commit the shared libraries (.dll, .dylib, .so). The pipeline builds those in a nice secure github vm. Any binary file, I'll just assume it's malicious.

hamoom commented 3 months ago

For whatever reason when i used the new compiled dll from your GHA i was getting this issue on PC

Godot Engine v3.5.3.stable.official.6c814135b - https://godotengine.org
OpenGL ES 3.0 Renderer: Parallels using Apple M1 Max (Compat)
Async. shader compilation: OFF

ERROR: Can't open dynamic library: addons/steam_api/steamsdk-godot.dll, error: Error 127: The specified procedure could not be found.
.
   at: open_dynamic_library (platform/windows/os_windows.cpp:2372) - Condition "!p_library_handle" is true. Returned: ERR_CANT_OPEN
ERROR: No valid library handle, can't get symbol from GDNative object
   at: get_symbol (modules/gdnative/gdnative.cpp:510) - No valid library handle, can't get symbol from GDNative object
ERROR: No nativescript_init in "res://addons/steam_api/steamsdk-godot.dll" found
   at: init_library (modules/gdnative/nativescript/nativescript.cpp:1503) - No nativescript_init in "res://addons/steam_api/steamsdk-godot.dll" found
ERROR: Failed to init steam api. Is Steam running? Is the plugin activated? Did you do the setup in ProjectSettings > SteamAPI
   at: call (modules/gdscript/gdscript_functions.cpp:775) - Failed to init steam api. Is Steam running? Is the plugin activated? Did you do the setup in ProjectSettings > SteamAPI
ERROR: You're running an exported build. Steam integration will only work if the game is launched by Steam. Either upload this build to Steam or create a file in the same directory as your exported build named 'steam_appid.txt' with just your steam app id in it.
   at: call (modules/gdscript/gdscript_functions.cpp:775) - You're running an exported build. Steam integration will only work if the game is launched by Steam. Either upload this build to Steam or create a file in the same directory as your exported build named 'steam_appid.txt' with just your steam app id in it.

i had to use the big chunky one i attached to this PR. i would double check :)

samsface commented 3 months ago

Possibly. But anyone reading this thread, please don’t download/run the DLL from this pr. Be safe.

tameem-hamoui commented 3 months ago

yeah i'm just mentioning it here to make sure the new dll isn't breaking your addon