0.3.5 • Published 11 months ago

liithworks.js v0.3.5

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months ago

Liithworks.js

An implementation of the Steamworks SDK for HTML/JS and NodeJS based applications.

API

const liithworks = require('liithworks.js')

// You can pass an appId, or don't pass anything and use a steam_appid.txt file
const client = liithworks.init(480)

// Print Steam username
console.log(client.localplayer.getName())

// Tries to activate an achievement
if (client.achievement.activate('ACHIEVEMENT')) {

}

You can refer to the declarations file to check the API support and get more detailed documentation of each function.

Installation

To use Liithworks.js you don't have to build anything, just install it from npm:

$: npm i liithworks.js

Electron

Liithworks.js is a native module and cannot be used by default in the renderer process. To enable the usage of native modules on the renderer process, the following configurations should be made on main.js:

const mainWindow = new BrowserWindow({
    webPreferences: {
        contextIsolation: false,
        nodeIntegration: true
    }
})

To make the steam overlay working, call the electronEnableSteamOverlay on the end of your main.js file:

require('Liithworks.js').electronEnableSteamOverlay()
0.3.5

11 months ago

0.3.3

11 months ago

0.3.2

12 months ago