steamworks-ts
v0.0.32
Published
<h1 align="center">steamworks-ts</h1> <p align="center"> This package provides typed NodeJS bindings to the <a href="https://partner.steamgames.com/doc/sdk">Steamworks SDK</a>. <br><br> <a href="https://www.npmjs.com/package/steamworks-ts"> <img src="ht
Readme
Usage
import { SteamClient } from 'steamworks-ts';
const steam = new SteamClient();
const { steamId, accountId, name, loggedOn } = steam.getCurrentUser();Building locally
You must have a Rust Toolchain and NodeJS:
$ npm i
$ npm run devThis should produce steamworks-ts.<platform>-<arch>.node.
The steam_appid.txt File
Steamworks requires a file named steam_appid.txt containing the AppID of the Steam app Steamworks is meant to interact with. If this file doesn't exist, you'll get a warning and one will be created automatically:
$ npx tsx examples/user_info.ts
Warning, creating default steam_appid.txt with 480 (Spacewar)
...Spacewar is an example application used to help developers understand the usage of the Steamworks API.
Examples
After building locally, you can run examples with tsx:
bash
$ npx tsx examples/user_info.tsLicense
This package is licensed under MIT.
Help, I can't run my game/tool!
If you are seeing errors like STATUS_DLL_NOT_FOUND, Image not found etc. your platform is not likely supported by steamworks-ts or you forgot to build.
