steam-game-path
TypeScript icon, indicating that this package has built-in type declarations

2.2.0 • Public • Published

Steam Game Path

How does it work?

It looks for the path with given game id, and returns both steam installation path and game's.

Installing

npm install steam-game-path

Example #1

import { getGamePath } from 'steam-game-path';

const data = getGamePath(730);

Exports

Method Description Example Returned objects
getGamePath(gameId, findExecutable: boolean) Function that takes game id and returns getGamePath(730) Path Object
getSteamPath() Function that returns steam install path or null getSteamPath() //"E:\Program Files (x86)\Steam" string

Path Object Example

{
    game: {
        path: 'C:\\SteamLibrary\\steamapps\\common\\Counter-Strike Global Offensive',
        name: 'Counter-Strike: Global Offensive',
        executable?: Promise
    },
    steam: {
        path: 'E:\\Program Files (x86)\\Steam',
        libraries: [
            'C:\\SteamLibrary\\steamapps',
            'D:\\SteamLibrary\\steamapps',
            'E:\\Program Files (x86)\\Steam\\steamapps'
        ]
    }
}

Readme

Keywords

none

Package Sidebar

Install

npm i steam-game-path

Weekly Downloads

43

Version

2.2.0

License

GPL-3.0

Unpacked Size

49.2 kB

Total Files

9

Last publish

Collaborators

  • osztenkurden