84 lines
No EOL
3.2 KiB
Markdown
84 lines
No EOL
3.2 KiB
Markdown
# SteamRPC
|
|
|
|
SteamRPC pulls your game and presence from Steam and puts it onto discord.
|
|
|
|
## Table of Contents
|
|
- [Setup](#setup)
|
|
- [Downloading the repository](#downloading-the-repository)
|
|
- [Discord Setup](#discord-setup)
|
|
- [Steam Setup](#steam-setup)
|
|
- [Running it](#running-it)
|
|
- [Customization](#customization)
|
|
- [Notes](#notes)
|
|
|
|
## Setup
|
|
|
|
### Downloading the repository
|
|
Simply run:
|
|
```bash
|
|
git clone https://codeberg.org/Bingus_Violet/SteamRPC
|
|
cd SteamRPC
|
|
```
|
|
|
|
In order for SteamRPC to run, you need to give it 2 environment variables. <br> Example:
|
|
```bash
|
|
CLIENT_ID=1234567890 STEAM_ID=12345678 node index.js
|
|
```
|
|
|
|
Below you can find documentation for how to get the Discord Client ID and the Steam ID.
|
|
|
|
### Discord Setup
|
|
|
|
1. Navigate to the [Discord Developer Portal](https://discord.com/developers/) and sign in.
|
|
2. In the top right, hit the button that says "New Application". You can name this application whatever you want, but I recommend SteamRPC.
|
|
3. Copy the application ID.
|
|
|
|
And thats pretty much it! Now just fill the CLIENT_ID environment variable in with your newly obtained Application ID
|
|
|
|
### Steam Setup
|
|
|
|
Getting your Steam ID is a much simpler process.
|
|
1. Navigate to Steam and login if you haven't already (You can do this both in the app or on the web)
|
|
2. Hover on your username at the top and go to "friends"
|
|
3. Navigate to the "Add a friend page" on the left
|
|
4. Copy your friend code
|
|
|
|
Now replace the STEAM_ID environment variable with the SteamID you just got.
|
|
|
|
Although this isn't nessacarily the most sophisticated method for getting your steam ID, its the one I find the easiest.
|
|
|
|
## Customization
|
|
|
|
### By default, you may notice that the games have no images
|
|
This is sadly a limitation of Discord, and I currently do not believe there is an easy method around it. For now, I have developed an easy alternative.
|
|
|
|
1. Go back to the [Discord Developer Portal](https://discord.com/developers) and navigate to the page for your newly made application.
|
|
2. On the left, click on "Rich Presence" and go to "Art Assets"
|
|
3. Click `Add Image(s)` and upload the icon you want for your game
|
|
4. Name it the name of your game **Without Spaces or caps**
|
|
|
|
* Please note that images do need to be 256x256, but you can easily find some application to upscale it if you so desire.
|
|
|
|
And your done!
|
|
Here is an example of my current setup: <br>
|
|
![A photo of my setup, with Gunfire Reborn and Risk of rain 2. The Gunfire Reborn is simply named "gunfirereborn" and Risk of Rain 2 is named "riskofrain2"](docs/images/setupExample.png)
|
|
|
|
### Running it
|
|
Lastly, all you need to do, is open a terminal and run
|
|
```
|
|
CLIENT_ID=[your discord client ID] STEAM_ID=[your steam id] node index.js
|
|
```
|
|
|
|
There are also option environment variables:
|
|
- `UPDATE_TIME=[number of seconds to update]`
|
|
- **this HAS TO BE over 15 seconds**
|
|
|
|
If everything is setup properly, it should look something like this!:<br>
|
|
![Alt text](docs/examples/image.png)<br>
|
|
![Alt text](docs/examples/image-1.png)<br>
|
|
![Alt text](docs/examples/image-2.png)<br>
|
|
![Alt text](docs/examples/image-3.png)<br>
|
|
|
|
|
|
## Notes
|
|
This project was never meant to be public, but I decided there was no reason not to. Please do report any problems you encounter, and if there are any issues with the documentation, please let me know! |