Discord2FivePY is a Python Discord bot that runs ESX admin commands on your FiveM server. Staff with the right Discord role type commands in one channel, and the bot sends them to the server over RCON and reports back in Discord.
Commands
=status– server status=revive– revive a player=giveaccountmoney– give account money=giveitem– give an item=giveweapon– give a weapon=refresh– refresh resources=start,=stop,=restart– start, stop or restart a resource=setjob– set a player’s job=kick– kick a player=announce– send an announcement
Configuration
- All embeds the bot sends are customizable: server name, website, logo and colours
- Webhook that reports error messages and confirmations
- Command channel, allowed Discord role and command prefix
- Revive event (
esx_ambulancejob:reviveby default)
Requirements
- Python 3.9.2 with discord.py, numpy and requests (pyrcon is included)
- FXServer with an RCON password set
- ESX 1.1 or older
Installation
- Install Python 3.9.2 to PATH and the Python packages listed in the README with
pip install. - Copy
fivem/discord2fivepyinto your resources and addensure discord2fivepyto your server.cfg. - Fill in
config.lua(FiveM) andpython/config.json(bot token, channel, role, RCON host, password and port). - Start the bot with
run.bat.