Skip to content

Bobagi/Avarice

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Avarice - Discord Bot

Welcome to the Avarice Discord Bot repository! This bot is designed to integrate Discord with a Project Zomboid server and provide enhanced functionality through GPT AI interactions.

JavaScript ChatGPT Discord Steam

Prerequisites

Before you begin, ensure you have the following requirements met:

  • Node.js (Download and installation instructions: Node.js)
  • A Discord Bot Token (Guide on creating a bot and getting a token: Discord Developer Portal)
  • Access to your Project Zomboid server's RCON
  • An OpenAI API key (Obtain from OpenAI)

Installation

To set up the bot, follow these steps:

  1. Clone the repository to your local machine or server.
  2. Navigate to the project directory and create a .env file.
cd opt/Avarice
touch .env
  1. Open the .env file in a text editor and insert your credentials (replace the placeholders with your actual data):
TOKEN=<Your-Discord-Bot-Token>
RCON_PASSWORD=<Your-RCON-Password>
OPENAI_KEY=<Your-OpenAI-Key>
  1. Install the dependencies.
npm install

Running the Bot

To start the bot, simply run:

npm start

The bot should now be running and ready to connect to both your Discord and Project Zomboid server.

If you want to keep the bot running even closing the terminal, start a new screen before run the code above:

screen -S avarice

To detach from the screen session (and keep the bot running in the background), press Ctrl + A, then D.

And for attach the screen again:

screen -r avarice

Usage

  • !help - To get all commands registered.

Contributing

If you would like to contribute to the bot's development, please consider the following guidelines:

  • Fork the repository and create a new branch for your feature or fix.
  • Write clear and descriptive commit messages.
  • Ensure that your code adheres to the existing style to maintain consistency.
  • Open a pull request with a comprehensive description of your changes.

Security

Your .env file contains sensitive information that should never be shared or committed to version control. Ensure that your .env file is listed in your .gitignore.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.