Skip to content
On this page

Main Config

Filename discordconnector.cfg

OptionDefaultDescription
Webhook URL(none)The main Discord webhook URL to send notifications/messages to.
Webhook EventsALLSemi-colon separated list of which events to send to the primary webhook.
Secondary Webhook URL(none)The main Discord webhook URL to send notifications/messages to.
Secondary Webhook Events(none)Semi-colon separated list of which events to send to the primary webhook.
Use fancier discord messagesfalseSet to true to enable using embeds in the Discord messages. If left false, all messages will remain plain strings (except for the leaderboard).
Allow positions to be senttrueSet to false to prevent any positions/coordinates from being sent. If this is true, it can be overridden per message in the toggles config file.
Ignored players(none)List of player names to never send a discord message for (they also won't be tracked in stats). This list should be semicolon (;) separated.
Ignored players (Regex)(none)Regex which player names are matched against to determine to not send a discord message for (they also won't be tracked in stats)
Collect statstrueWhen this setting is enabled, DiscordConnector will record basic stats (leave, join, ping, shout, death) about players.
Send leaderboard updatesfalseIf you set this to true, that will enable DiscordConnector to send a leaderboard for stats to Discord on the set interval
Leaderboard update interval600Time in minutes between each leaderboard update sent to Discord.
Announce Player FirststrueDisable this setting to disable all extra announcements the first time each player does something. (Overwrites any individual setting.)
How many places to list in the top ranking leaderboards3Set how many places (1st, 2nd, 3rd by default) to display when sending the ranked leaderboard.
Send Non-Player Shouts to DiscordfalseEnable this setting to have shouts which are performed by other mods/the server/non-players to be sent to Discord as well.

"Stat Collection Details"

Stat collection will create a file in the discordconnector config directory records.db, where it will record the number of times each player joins, leaves, dies, shouts or pings.

If this is set to false, DiscordConnector will not keep a record of number of times each player does something it alerts to.

If this is false, it takes precedent over the "Send leader board updates" setting and no leader boards will get sent.

The stat collection database uses the LiteDB library and if you are so inclined they offer a database gui which you can use to view/modify this database. (Find the LiteDB Editor on their site.)

Webhook Events

Here is a list of every accepted event for inclusion in the 'webhook event' settings. These correspond pretty directly to the configurations in the messages config.

"Specifying Events ≠ Enabling Messages"

Adding an event to be send for a webhook does not enable Discord Connector to send that event. It only tells Discord Connector where to send the event message.

Messages for these events have to be enabled in the toggles config file (as they were previously). Any of these messages which are enabled by default are notated as such in the 'Enabled by Default' column.

Take note that by default, the webhooks are set to 'ALL' which takes any messages which happen and sends them.

Event CodeCorresponding TriggerEnabled by Default
serverLaunchServer begins starting upYes
serverStartWorld has been loadedYes
serverStopServer beings stoppingYes
serverShutdownServer has stoppedYes
serverSaveThe world has been savedYes
eventStartAn event startsYes
eventPausedAn event pausesYes
eventResumedAn event resumesYes
eventStopAn event finishesYes
playerJoinA player joins the serverYes
playerLeaveA player joins the serverYes
playerShoutA player joins the serverYes
playerPingA player joins the serverYes
playerDeathA player joins the serverYes
playerFirstJoinA new player joins the serverYes
playerFirstLeaveA player leaves the server for the first timeNo
playerFirstShoutA player shouts in chat for the first timeNo
playerFirstPingA player pings the map for the first timeNo
playerFirstDeathA player dies for the first timeYes

Leaderboard Events

These are events which represent sending the leaderboards

Event CodeCorresponding TriggerEnabled by Default
activePlayersThe active players leaderboardNo
leaderboard1The custom leaderboard 1No
leaderboard2The custom leaderboard 2No
leaderboard3The custom leaderboard 3No
leaderboard4The custom leaderboard 4No
leaderboard5The custom leaderboard 5No

3rd Party Events

It's possible for other mods to hook into Discord Connector to send messages to Discord. As more get added to this list, they will be able to be specifically attached to a certain webhook.

Event CodeCorresponding Trigger
cronjobOutput from cronjob

Special Case Events

These are shorthand to represent multiple events.

Event CodeCorresponding TriggerEnabled by Default
ALLAll messages get sent to this webhookN/A
serverLifecycleAny server launch, start, stop, shutdown messages are sent to this webhookN/A
eventLifecycleAny event start, pause, resume, or stop/end messages are sent to this webhookN/A
playerAllAny messages about player's activity are sent to this webhookN/A
playerFirstAllAny message about a player's first X are sent to this webhookN/A
leaderboardsAllAny message for a leaderboard are sent to this webhookN/A
otherA few other mods/plugins utilize Discord Connector's webhook to send messages. Those get tagged as 'Other' events.N/A