A discord bot to run a points system on your server.
Say "!help" at any time to print the list of commands.
Print the scores
Awards points. You can award any number of points.
Format: !give {number} points to {user}[...]
For example:
!give 100 points to @user
!give 0.0000001 points to @user for participating
This bot is not set to public, but you can set up your own instance by following these instructions.
- Node.js 12.0.0 or newer
- PostgreSQL
The app needs the following environment variables to be set:
- DISCORD_TOKEN - the token for the bot you created in the step above
- PGHOST - database host (default: 'localhost')
- PGUSER - database user (default: process.env.USER)
- PGDATABASE - database name (default: process.env.USER)
- PGPASSWORD - database password (default: null)
- PGPORT - database port (default: 5432)
For a development environment, you can set these in a .env
file:
DISCORD_TOKEN=xxxx
PGDATABASE=mydatabasename
...
Run the app with:
node index.js
For a development environment, you may want to run with nodemon for auto-reloading:
nodemon index.js