Command | Arguments | Description | Permissions |
---|---|---|---|
!? , !help |
- | Displays the help output for the bot commands and use | All |
!about |
- | Display information about the bot | All |
!alerts |
- | Display the pending alerts that are scheduled in the bot | Admins |
!announce |
- | Announce a new bot upgrade to the main Discord channel | Admins |
!events |
- | displays all pending community events | All |
!flight list |
- | Display all pickup flights pending | All |
!flight create |
sim (BMS or DCS), HH:MM zulu, MM/DD, ...details | Create a new pickup flight for the argued SIM to take place on the argued zulu time and date with any extra details | All |
!flight join |
flight_id | Join an existing pickup flight by the argued ID | All |
!flight delete |
flight_id | Delete a pickup flight that you have created by its ID | All (flight owner) |
!role add |
group_name | Join the argued group if it exists and have permission | All |
!role remove |
group_name | Leave the argued group if it exists and you're a member | All |
!lfg list |
- | Display all group entities looking for players | All |
!lfg create |
#_needed, name | Create a new group with a designated name and amount of players looking for | All |
!lfg join |
group_id | Join a group by it's ID that is looking for players | All |
!lfg delete |
group_id | Delete a group that you have create by its ID | All (group owner) |
!missions |
name | Search for mission on the forums API with names that fully or partially match the argued name | All |
!polls |
- | Get a list of active polls/voting threads on the forums | Deprecated |
!ratio |
total, a, b | Calculate the player ratio for teams with A:B players | All |
!ready |
"count" OR # to wait for | Receive a one-time alert from the bot when the primary server reaches a certain player count, or see how many users are waiting with "count" | All |
!shutdown |
- | Turns off the Discord bot | Admins |
!sqf |
cmd | Search the BIS wiki for information about an SQF command | All |
!sqfp |
cmd | Search BIS wiki for information about an SQF command and post the result publicly | All |
!stats |
- | View runtime statistics about the bot | Admins |
!user |
username | Get authentication information about a user | Admins |
A Dockerfile
is provided in the repository is you wish to use Docker, otherwise:
*
-prefixed variable names are available to changed via the !config
admin command
- Node.js 10.8.0 or higher
.env
file at the root project level with the following variables setBOT_ID
: client ID of the bot received in the developer portalBOT_SECRET
: client secret of the bot received in the developer portalBOT_TOKEN
: client token of the bot received in the developer portalBOT_PERMISSIONS
: integer value of the sum of the bot's permissionsDISCORD_SERVER_ID
: ID of the server being deployed toDISCORD_LOG_CHANNEL
: ID of the channel designated for bot audit logsDISCORD_MAIN_CHANNEL
: ID of the main channel in the serverDISCORD_LFG_CHANNEL
: ID of the channel to post looking for group notifications toDISCORD_REGULARS_CHANNEL
: ID of the channel designated for Regulars discussionDISCORD_ARMA_CHANNEL
: ID of the channel designated for ArmA 3DISCORD_BMS_CHANNEL
: ID of the channel designated for BMSDISCORD_ALLOWED_GROUPS
: comma deliminated list of groups/roles user's are allowed to join- *
DISCORD_ARMA_PLAYER_ROLE
: the role designated for Arma 3 players - *
DISCORD_BMS_PLAYER_ROLE
: the role designated for BMS players ALERT_TIMES
: comma deliminated list of "time untils" to post reminder notifications for calendar events. Hold the format of<amt> <time_type>
(7 days, 12 hours)- *
NUM_PLAYERS_FOR_ALERT
: the minimum player count on the server to initial an alert HOURS_TO_REFRESH_FROM_FORUMS
: number of hours between updating data from API requests to the forumADMIN_ROLES
: roles permitted to run the admin only commands for the botFORUMS_API_BASE
: base url for the forum's REST APIFORUMS_API_KEY
: API key provided by forums admin for access to the REST APIAUTH_API_BASE
: base url for the UO authentication system APIAUTH_API_KEY
: API key provided for access to UO authenticatino system API callsGRPC_PORT
: port for the lightweight gRPC server to run on
Permissions for the bot should be configured as:
The "Permissions Integer" at the bottom is the value for the environment variable BOT_PERMISSIONS
.
-
In the "OAuth2" tab of the developer portal, give the application only the
bot
scope, then configure with the permission set above. -
Copy and paste the generated OAuth2 URL into the browser and select the Discord server to give access to the bot to join.
-
Insert all sensitive authentication data into the environment variables file from the developer portal.
-
You can copy the IDs of the server and channels by right clicking on them while in Discord's Developer Mode, and place them with the appropriate environment variables in the
.env
file -
Go into the Discord server options,
Server Settings > Roles
, and ensure the that the role for the bot is placed above all other roles in the list -
If the
ARMA_CHANNEL
,BMS_CHANNEL
, orMAIN_CHANNEL
are locked, make sure to give special permission to the bot's role for the channel:- Read Messages
- Send Messages
- Send TTS Messages
- Manage Messages
- Embed Links
-
Once the
Node.js
application is running, the bot will appear as "Online" on the Discord server and ready to handle requests