{"id":13534198,"url":"https://github.com/larsiusprime/SteamWrap","last_synced_at":"2025-04-01T22:31:17.888Z","repository":{"id":141083825,"uuid":"51186322","full_name":"larsiusprime/SteamWrap","owner":"larsiusprime","description":"Haxe native extension for the Steam API","archived":false,"fork":false,"pushed_at":"2023-09-20T00:46:31.000Z","size":3464,"stargazers_count":113,"open_issues_count":14,"forks_count":48,"subscribers_count":15,"default_branch":"master","last_synced_at":"2025-02-25T02:46:10.387Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Haxe","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/larsiusprime.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2016-02-06T02:35:15.000Z","updated_at":"2025-02-21T16:38:18.000Z","dependencies_parsed_at":"2024-04-12T15:03:28.983Z","dependency_job_id":"7c6084d2-c48b-439f-bb97-3b662e5a4247","html_url":"https://github.com/larsiusprime/SteamWrap","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/larsiusprime%2FSteamWrap","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/larsiusprime%2FSteamWrap/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/larsiusprime%2FSteamWrap/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/larsiusprime%2FSteamWrap/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/larsiusprime","download_url":"https://codeload.github.com/larsiusprime/SteamWrap/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246720536,"owners_count":20822914,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T07:01:27.762Z","updated_at":"2025-04-01T22:31:17.431Z","avatar_url":"https://github.com/larsiusprime.png","language":"Haxe","funding_links":[],"categories":["Libraries","Miscellaneous"],"sub_categories":["Haxe","3rd party API"],"readme":"SteamWrap\n---------\nSimple Haxe native extension Steam API wrapper. This code originally shipped in [Papers, Please](http://papersplea.se) and the changes in this fork were made for the PC release of [rymdkapsel](http://rymdkapsel.com). Windows, OS X and Linux/SteamOS builds are supported.\n\n#### Current Features:\n\n- Achievements \u0026 Leaderboards\n- Steam Controller Support\n- UGC (user generated content)\n- Stats (not well-tested)\n\n~~This repository comes with prebuilt binaries, which means it should work \"out of the box\".~~\n\n(I'm in the process of updating the binaries, right now all it has is Windows)\n\n#### Dependencies / Requirements:\n\n- Haxe 3.2 or greater\n- hxcpp 3.2.205 or greater\n- OpenFL 3.6 or greater\n- lime 2.8.3 or greater\n\nProbably works with NME as well but I'm unsure of the requirements there. Ask Hugh.\n\n#### To include steamwrap.ndll in your OpenFL or NME project:\n\n1. Install the library:\n\n    latest git version:\n```haxelib git steamwrap https://github.com/larsiusprime/SteamWrap```\n    \n2. Add the following nodes to your project.xml (assumes OpenFL or NME for now):\n ```\n    \u003c!-- Replace the question marks with your Steam App ID --\u003e\n    \u003csetenv name=\"STEAM_APP_ID\" value=\"??????\" /\u003e\n\n    \u003c!-- OS X only: Set this value to the same value as the file property of your \u003capp\u003e node, this is needed to embed things into the generated .app file --\u003e\n    \u003c!-- Setting this for other platforms won't do any harm, so you can safely leave it enabled for everything --\u003e\n    \u003cset name=\"APP_FILE\" value=\"??????\" /\u003e\n    \n    \u003chaxelib name=\"steamwrap\"/\u003e\n ```\n \n3. If you are doing non-Steam builds as well, it is practical to wrap this in a conditional. Run your builds as: `openfl test \u003cplatform\u003e -Dsteam` to enable it, for example: `openfl test windows -Dsteam`.\n ```\n\t\u003csection if=\"steam\"\u003e\n\t\t\u003c!-- Steam specifics go here --\u003e\n\t\u003c/section\u003e\n ```\n\n\t**!!!!!!!!!!!!!!!!! IMPORTANT !!!!!!!!!!!!!!!!!!!**\n\t\n\t**This extension will automatically create a steam_appid.txt in your binary folder.**\n\t**Do not ship your game with this file. Make sure it's stripped during the publishing stage.**\n\t\n\t**Compiling with the \"-Dfinal\" flag should suppress creation of the steam_appid.txt**\n\t\n\t```openfl test windows -Dsteam -Dfinal``` (for instance)\n\t\n\t**!!!!!!!!!!!!!!!!! IMPORTANT !!!!!!!!!!!!!!!!!!!**\n\n4. Platform specific notes:\n\n**Linux**\n - Make sure libsteam_api.so is sitting next to steamwrap.ndll\n - You will need a launch script to ensure libraries are loaded from the righ location. An example (Test.sh) is provided in the example folder\n   - When you release your game on Steam, set this launch script as your executable, NOT the raw linux binary itself\n\n\n#### Usage:\n\nSee steamwrap/example/Test.hx for a basic example.\n\n#### To build steamwrap.ndll from source:\n\n**Automatic steps**\n\n1. Run setup.bat (windows) or setup.sh (mac/linux) and enter the values it asks you for\n\nOr you can set it up manually:\n\n------------\n\n**Manual steps:**\n\n1. Copy the hxcpp headers:\n    \t\n\t\tHAXE_DIR/lib/hxcpp/VERSION/include/hx/*.h -\u003e STEAMWRAP_DIR/native/include/hx/*.h\n\n2. Copy the Steam SDK headers and libs:\n\t\t\n\t\tSTEAMSDK_DIR/public/steam/*.h -\u003e native/include/steam/*.h\n\t\tSTEAMSDK_DIR/redistributable_bin/steam_api.dll -\u003e native/lib/win32/\n\t\tSTEAMSDK_DIR/redistributable_bin/steam_api.lib -\u003e native/lib/win32/\n\t\tSTEAMSDK_DIR/redistributable_bin/win64/steam_api64.dll -\u003e native/lib/win64/\n\t\tSTEAMSDK_DIR/redistributable_bin/win64/steam_api64.lib -\u003e native/lib/win64/\n\t\tSTEAMSDK_DIR/redistributable_bin/osx32/libsteam_api.dylib -\u003e native/lib/osx64/\n\t\tSTEAMSDK_DIR/redistributable_bin/linux32/libsteam_api.so -\u003e native/lib/linux32/\n\t\tSTEAMSDK_DIR/redistributable_bin/linux64/libsteam_api.so -\u003e native/lib/linux64/\n\n3. Put some files in the build dir:\n\n\tWindows:\n\t```\n\t\tndll/Windows/steam_appid.txt\n\t\tSTEAMSDK_DIR/redistributable_bin/steam_api.dll -\u003e ndll/Windows/\n\n\t\tndll/Windows64/steam_appid.txt\n\t\tSTEAMSDK_DIR/redistributable_bin/steam_api64.dll -\u003e ndll/Windows64/\n\t```\n\n\tMac:\n\t```\n\t\tndll/Mac64/steam_appid.txt\n\t\tSTEAMSDK_DIR/redistributable_bin/steam_api.lib -\u003e ndll/Mac64/\n\t```\n\n\tLinux:\n\t```\n\t\tndll/Linux/steam_appid.txt\n\t\tSTEAMSDK_DIR/redistributable_bin/steam_api.so -\u003e ndll/Linux/\n\t\t\n\t\tndll/Linux64/steam_appid.txt\n\t\tSTEAMSDK_DIR/redistributable_bin/steam_api.so -\u003e ndll/Linux64/\n\t```\n\n\t**WHAT THIS DOES:**\n\t\n\tThe steam_api dll/dylib/so file must be next to your platform's steamwrap.ndll file in order for the extension to \t\twork. The dll/dylib/so file has all of the actual Steam API functionality, and the ndll file allows your Haxe \t\t\tproject to communicate with it.\n\t\n\tAs for the `steam_appid.txt` file, it's only there to make the \"Test\" program work. That's because the \"Test\" program \twill appear in your platform's ndll/\u003cPlatform\u003e folder when you use the \"build.bat\" or \"build\" script to compile it.\n\t\n\tIn order for your test program to work it must be able to find:\n\t  - steamwrap.ndll (so Haxe can talk to Steam)\n\t  - steam_api.dll/dylib/so (to provide the Steam API)\n\t  - steam_appid.txt (to make the Steam Client recognize your app as a particular Steam Game when testing)\n\t  \n------------\n\n**Final Steps:**\n\n1. Run the \"build\" script (it's a basic haxelib command shortcut). \n\tsteamwrap.ndll will be output to ndll/[PLATFORM]\n\nNote: For linux you should have `g++-multilib` installed.\n  \nThat's great, but we want to make sure it works! Let's run something with it. If you run the Test program now, you'll notice it exits immediately, asking you to supply an app ID.\n\n2. Edit steamwrap/example/Test.hx to include your Steam App ID and achievement ID's, etc.\n\n\tNow you are ready to compile example/Test.hx. Run the build script again.\n\n3. Start the Steam client, leave it open in the background, and run the Test app to make sure it connects.\n\nNote: If you're running on Linux, you should run the \"Test.sh\" launcher script, not the \"Test\" binary directory\n\n\t\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flarsiusprime%2FSteamWrap","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flarsiusprime%2FSteamWrap","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flarsiusprime%2FSteamWrap/lists"}