473 lines
21 KiB
TOML
473 lines
21 KiB
TOML
# Read more about configuration here: https://github.com/denisnumb/discord-chat-mod/wiki
|
|
#
|
|
# Bot access token
|
|
# [!] Make sure all Privileged Gateway Intents are enabled on https://discord.com/developers/applications/<your_app_id>/bot
|
|
# [!] Make sure the bot has the following permissions on the server:
|
|
# [!] - VIEW_CHANNEL
|
|
# [!] - MESSAGE_SEND
|
|
# [!] - MESSAGE_SEND_IN_THREADS
|
|
# [!] - MESSAGE_EMBED_LINKS
|
|
# [!] - MESSAGE_ATTACH_FILES
|
|
# [!] - PIN_MESSAGES
|
|
# [!] - MESSAGE_HISTORY
|
|
discordBotToken = ""
|
|
# Mod locale
|
|
modLocale = "en_us"
|
|
# The offset of the current time from UTC in hours.
|
|
# Used to generate timestamps for message style configurations.
|
|
# Default: 0
|
|
# Range: -12 ~ 14
|
|
utcOffsetHours = 0
|
|
# If true, the bot's Discord presence (custom status) will display the current online player count, e.g. "Online: 3/20".
|
|
# Set to false to disable the presence status entirely (the bot will appear without a custom status).
|
|
enableBotPresenceStatus = true
|
|
# If true, Discord bots are included in the @-autocomplete shown in Minecraft chat and can be mentioned from the server.
|
|
# Set to false to hide bots from the autocomplete and stop resolving "@botname" in player messages into a Discord mention.
|
|
mentionBots = true
|
|
|
|
[logsConfig]
|
|
# Do logging to the server console messages from discord
|
|
logDiscordMessages = true
|
|
# Notify about internal Discord interaction errors in the server's in-game chat
|
|
logDiscordErrorsToServerChat = true
|
|
# If logDiscordErrorsToServerChat=true, then the errors in the chat will be seen by players with the specified selector
|
|
# By default, "@a" — all players. You can specify a specific nickname or attribute, for example, "@a[tag=admin]"
|
|
discordErrorsChatPlayerSelector = "@a"
|
|
# Enable sending server logs to Discord
|
|
# [!] When enabling, you must also specify a serverLogsChannelId in the guilds section
|
|
serverLogsToDiscordEnabled = false
|
|
# The minimum level of logs that will be sent to Discord.
|
|
# Possible values: ERROR, WARN, INFO
|
|
serverLogsToDiscordLoggingLevel = "INFO"
|
|
# Log4j pattern for formatting server logs sent to Discord.
|
|
# Common placeholders: %d{HH:mm:ss} (time), %t (thread), %level (level), %logger{1} (class), %msg (message), %n (newline)
|
|
# Example (clean): "[%d{HH:mm:ss}] %msg%n"
|
|
# Example (verbose): "[%d{HH:mm:ss}] [%t/%level] (%logger{1}) %msg%n"
|
|
serverLogsPattern = "[%d{HH:mm:ss}] [%t/%level] (%logger{1}) %msg%n"
|
|
# Enable logging of commands executed by players to a Discord channel (Guild defaultChannel by default).
|
|
# Command log channel can be overridden for each guild in the guilds.channelOverrides section.
|
|
# Only commands from players whose permission level is at least commandLogMinPermissionLevel are logged.
|
|
commandLogEnabled = false
|
|
# Minimum permission level required for a player's commands to be logged (0-4).
|
|
# 0 = all players, 2 = operators (default), 3 = admins, 4 = owners.
|
|
commandLogMinPermissionLevel = 2
|
|
# Comma-separated list of root command names to skip (without the leading /).
|
|
# Matching is case-insensitive. Example: ["msg", "tell", "w", "help", "list"]
|
|
# Leave blank to log every command that passes the permission level filter.
|
|
commandLogIgnoredCommands = []
|
|
|
|
[webhookModeConfig]
|
|
# If true, server and player messages will be sent in webhook mode.
|
|
# [!] Webhook mode works only in regular channels (Threads does not work)
|
|
# [!] The bot must have Manage Webhooks permission
|
|
enableWebhookMode = false
|
|
# Webhook name for displaying server messages
|
|
webhookServerName = "Minecraft Server"
|
|
# Avatar url for the webhook for displaying server messages
|
|
# Leave blank to display the connected bot's avatar
|
|
webhookServerAvatarUrl = ""
|
|
# If true, then all players will have access to the /set_avatar_url <url> command to set a custom avatar, which will be used instead of the webhookPlayerAvatarUrl parameter.
|
|
# The /remove_avatar_url command will also be available to remove an avatar.
|
|
enableSetAvatarUrlCommand = true
|
|
# Url to get the player's display avatar
|
|
# You can specify a link with dynamic parameters <uuid>, <name> and <texture>, which will be automatically substituted when requesting an image
|
|
# <uuid> - player's UUID
|
|
# <name> - player's nickname
|
|
# <texture> - texture hash from the player's GameProfile (works with skin mods like Fabric Tailor or SkinRestorer that write into the server-side profile). Example: https://mc-heads.net/avatar/<texture>
|
|
# Default: https://mc-heads.net/avatar/<name>.png
|
|
webhookPlayerAvatarUrl = "https://mc-heads.net/avatar/<name>.png"
|
|
# Url to get the player's display avatar if dynamic link is invalid
|
|
# Default: https://mc-heads.net/avatar/steve_head_png
|
|
webhookPlayerDefaultAvatarUrl = "https://mc-heads.net/avatar/steve_head_png"
|
|
|
|
[discordProxyConfig]
|
|
# Configuring the HTTP proxy when connecting with Discord. Do not modify if you don't understand what this is.
|
|
proxyHostname = ""
|
|
# Default: 1234
|
|
# Range: 0 ~ 65535
|
|
proxyPort = 1234
|
|
# Leave blank if no certificate required.
|
|
proxyUser = ""
|
|
proxyPassword = ""
|
|
|
|
[minecraftChatStyle]
|
|
# If true, messages in the game chat will be formatted in the formats specified below.
|
|
# For each format, you can use dynamic parameters specified in the comment above the parameter.
|
|
# Global parameters available for all styles listed below:
|
|
# {HH}, {MM}, {SS} — Hours, minutes, and seconds at the time the message was sent. Example usage: "[{HH}:{MM}] <{player}> {message}"
|
|
# {x}, {y}, {z}, {dimension} — the player's coordinates and dimension name
|
|
# You can read more about this configuration section and see examples here: https://github.com/denisnumb/discord-chat-mod/wiki/Minecraft-Chat-Customization
|
|
# [!] If enabled, make sure you don't have any other chat styling mods installed.
|
|
enableMinecraftChatCustomization = false
|
|
# Color of links in game chat
|
|
minecraftChatLinkColor = "#00b7ff"
|
|
# Style for displaying Discord messages in game chat
|
|
# Parameters: {guild}, {member}, {message}
|
|
# Default: "**<#5f78d9>[discord]<#5f78d9/>** <{member}> {message}"
|
|
minecraftDiscordMessagesStyle = "**<#5f78d9>[discord]<#5f78d9/>** <{member}> {message}"
|
|
# Chat message from player
|
|
# Parameters: {player}, {message}
|
|
# Default: "<{player}> {message}"
|
|
minecraftPlayerMessageStyle = "<{player}> {message}"
|
|
# Player joined the game
|
|
# Parameters: {player}, {multiplayer.player.joined}
|
|
# Default: "<yellow>{player} {multiplayer.player.joined}<yellow/>"
|
|
minecraftPlayerJoinedStyle = "<yellow>{player} {multiplayer.player.joined}<yellow/>"
|
|
# Player left the game
|
|
# Parameters: {player}, {multiplayer.player.left}
|
|
# Default: "<yellow>{player} {multiplayer.player.left}<yellow/>"
|
|
minecraftPlayerLeftStyle = "<yellow>{player} {multiplayer.player.left}<yellow/>"
|
|
# Player death message
|
|
# Death messages are composite and contain: Player Name, Cause of Death, Second Entity (optional), Murder Weapon (optional).
|
|
# You can customize them separately using the configuration fields below.
|
|
# Parameters: {death_cause}, {player}, {second_entity}, {item}
|
|
minecraftPlayerDeathCauseStyle = "{death_cause}"
|
|
minecraftPlayerDeathNameStyle = "{player}"
|
|
minecraftPlayerDeathSecondEntityNameStyle = "{second_entity}"
|
|
minecraftPlayerDeathWeaponStyle = "{item}"
|
|
# Player has made the advancement
|
|
# Parameters: {player}, {chat.type.advancement.task}, {advancement}
|
|
# Default: "{player} {chat.type.advancement.task} <green>{advancement}<green/>"
|
|
minecraftPlayerAdvancementTaskStyle = "{player} {chat.type.advancement.task} <green>{advancement}<green/>"
|
|
# Player has reached the goal
|
|
# Parameters: {player}, {chat.type.advancement.goal}, {advancement}
|
|
# Default: "{player} {chat.type.advancement.goal} <green>{advancement}<green/>"
|
|
minecraftPlayerAdvancementGoalStyle = "{player} {chat.type.advancement.goal} <green>{advancement}<green/>"
|
|
# Player has completed the challenge
|
|
# Parameters: {player}, {chat.type.advancement.challenge}, {advancement}
|
|
# Default: "{player} {chat.type.advancement.challenge} <darkpurple>{advancement}<darkpurple/>"
|
|
minecraftPlayerAdvancementChallengeStyle = "{player} {chat.type.advancement.challenge} <darkpurple>{advancement}<darkpurple/>"
|
|
# Team message sent by the player
|
|
# Parameters: {team}, {player}, {message}
|
|
# Default: "-> {team} <{player}> {message}"
|
|
minecraftTeamMessageSentStyle = "-> {team} <{player}> {message}"
|
|
# Team message received from any player
|
|
# Parameters: {team}, {player}, {message}
|
|
# Default: "{team} <{player}> {message}"
|
|
minecraftTeamMessageReceivedStyle = "{team} <{player}> {message}"
|
|
# Private message sent by the player using /tell or /msg command
|
|
# Parameters: {commands.message.display.outgoing}, {receiver}, {message}
|
|
# Default: "<grey>*{commands.message.display.outgoing} {receiver}: {message}*<grey/>"
|
|
minecraftTellMessageSentStyle = "<grey>*{commands.message.display.outgoing} {receiver}: {message}*<grey/>"
|
|
# Private message received from any player who used the /tell or /msg command
|
|
# Parameters: {sender}, {commands.message.display.incoming}, {message}
|
|
# Default: "<grey>*{sender} {commands.message.display.incoming}: {message}*<grey/>"
|
|
minecraftTellMessageReceivedStyle = "<grey>*{sender} {commands.message.display.incoming}: {message}*<grey/>"
|
|
# Chat message from player sent using /say command
|
|
# Parameters: {player}, {message}
|
|
# Default: "[{player}] {message}"
|
|
minecraftSayCommandStyle = "[{player}] {message}"
|
|
# Chat message from player sent using /me command
|
|
# Parameters: {player}, {message}
|
|
# Default: "* {player} {message}"
|
|
minecraftMeCommandStyle = "* {player} {message}"
|
|
|
|
[discordChatStyle]
|
|
# The configuration settings below determine how messages sent from Minecraft to Discord will be formatted.
|
|
# The message format is specified in JSON format. You can remove the parameter from the configuration to get the default value
|
|
# For each format, you can use dynamic parameters specified in the comment above the parameter.
|
|
# Global parameters available for all styles listed below:
|
|
# {player_avatar_url} — link to the player's avatar (available wherever the {player} parameter is present)
|
|
# {x}, {y}, {z}, {dimension} — the player's coordinates and dimension name (available wherever the {player} parameter is present)
|
|
# {timestamp} — current number of seconds in the system. It's convenient to substitute when using Discord timestamps, for example: <t:{timestamp}:R>
|
|
# {datetime} — A string with the current date and time in the format "2025-11-02T10:00:00.000Z". May be useful for embed timestamps.
|
|
# You can read more about this configuration section and see examples here: https://github.com/denisnumb/discord-chat-mod/wiki/Discord-Chat-Customization
|
|
#
|
|
# Chat message from player
|
|
# Parameters: {player}, {message}
|
|
discordPlayerMessageStyle = """
|
|
{
|
|
"content": "`<{player}>` {message}"
|
|
}
|
|
"""
|
|
# Chat message from player (if webhook mode is enabled)
|
|
# Parameters: {player}, {message}
|
|
discordPlayerMessageWebhookStyle = """
|
|
{
|
|
"content": "{message}"
|
|
}
|
|
"""
|
|
# Player joined the game
|
|
# Parameters: {player}, {multiplayer.player.joined}
|
|
discordPlayerJoinedStyle = """
|
|
{
|
|
"embed": {
|
|
"author": {
|
|
"name": "{player} {multiplayer.player.joined}",
|
|
"icon_url": "{player_avatar_url}"
|
|
},
|
|
"color": "#2ECC71"
|
|
}
|
|
}
|
|
"""
|
|
# Player left the game
|
|
# Parameters: {player}, {multiplayer.player.left}
|
|
discordPlayerLeftStyle = """
|
|
{
|
|
"embed": {
|
|
"author": {
|
|
"name": "{player} {multiplayer.player.left}",
|
|
"icon_url": "{player_avatar_url}"
|
|
},
|
|
"color": "#E74C3C"
|
|
}
|
|
}
|
|
"""
|
|
# You can apply Markdown to individual components of the death message using the parameters below.
|
|
# They will ultimately be compiled into the {death_message} substitution parameter, which you can use to form the final message in Discord.
|
|
discordPlayerDeathCauseStyle = "{death_cause}"
|
|
discordPlayerDeathNameStyle = "{player}"
|
|
discordPlayerDeathSecondEntityStyle = "{second_entity}"
|
|
discordPlayerDeathWeaponStyle = "{item}"
|
|
# Player death message (configure parameters above)
|
|
# Parameters: {player}, {death_message}
|
|
discordPlayerDeathMessageStyle = """
|
|
{
|
|
"embed": {
|
|
"author": {
|
|
"name": "{death_message}",
|
|
"icon_url": "{player_avatar_url}"
|
|
}
|
|
}
|
|
}
|
|
"""
|
|
# Player has made the advancement
|
|
# Parameters: {player}, {chat.type.advancement.task}, {advancement}, {description}, {icon_url}
|
|
discordPlayerAdvancementTaskStyle = """
|
|
{
|
|
"embed": {
|
|
"title": "**{advancement}**",
|
|
"description": "{description}",
|
|
"color": "#F1C40F",
|
|
"author": {
|
|
"name": "{player} {chat.type.advancement.task}",
|
|
"icon_url": "{player_avatar_url}"
|
|
},
|
|
"thumbnail": {
|
|
"url": "{icon_url}"
|
|
}
|
|
}
|
|
}
|
|
"""
|
|
# Player has reached the goal
|
|
# Parameters: {player}, {chat.type.advancement.goal}, {advancement}, {description}, {icon_url}
|
|
discordPlayerAdvancementGoalStyle = """
|
|
{
|
|
"embed": {
|
|
"title": "**{advancement}**",
|
|
"description": "{description}",
|
|
"color": "#F1C40F",
|
|
"author": {
|
|
"name": "{player} {chat.type.advancement.goal}",
|
|
"icon_url": "{player_avatar_url}"
|
|
},
|
|
"thumbnail": {
|
|
"url": "{icon_url}"
|
|
}
|
|
}
|
|
}
|
|
"""
|
|
# Player has completed the challenge
|
|
# Parameters: {player}, {chat.type.advancement.challenge}, {advancement}, {description}, {icon_url}
|
|
discordPlayerAdvancementChallengeStyle = """
|
|
{
|
|
"embed": {
|
|
"title": "**{advancement}**",
|
|
"description": "{description}",
|
|
"color": "#A700A7",
|
|
"author": {
|
|
"name": "{player} {chat.type.advancement.challenge}",
|
|
"icon_url": "{player_avatar_url}"
|
|
},
|
|
"thumbnail": {
|
|
"url": "{icon_url}"
|
|
}
|
|
}
|
|
}
|
|
"""
|
|
# Chat message from player sent using /say command
|
|
# Parameters: {player}, {message}
|
|
discordSayCommandStyle = """
|
|
{
|
|
"content": "`[{player}]` {message}"
|
|
}
|
|
"""
|
|
# Chat message from player sent using /me command
|
|
# Parameters: {player}, {message}
|
|
discordMeCommandStyle = """
|
|
{
|
|
"content": "* {player} {message}"
|
|
}
|
|
"""
|
|
# Chat message from player sent using /me command (if webhook mode is enabled)
|
|
# Parameters: {player}, {message}
|
|
discordMeCommandWebhookStyle = """
|
|
{
|
|
"content": "> {message}"
|
|
}
|
|
"""
|
|
# Chat message from send using /tellraw @a command
|
|
# Parameters: {message}
|
|
discordTellrawCommandStyle = """
|
|
{
|
|
"content": "{message}"
|
|
}
|
|
"""
|
|
# Command executed by a player above the configured permission level
|
|
# Parameters: {player}, {command}
|
|
discordCommandLogStyle = """
|
|
{
|
|
"embed": {
|
|
"description": "`{command}`",
|
|
"color": "#F1C40F",
|
|
"author": {
|
|
"name": "{player}",
|
|
"icon_url": "{player_avatar_url}"
|
|
},
|
|
"timestamp": "{datetime}"
|
|
}
|
|
}
|
|
"""
|
|
# Screenshot from player
|
|
# Parameters: {player}, {screenshot_url}
|
|
discordScreenshotMessageStyle = """
|
|
{
|
|
"content": "`<{player}>`"
|
|
}
|
|
"""
|
|
# Screenshot from player (if webhook mode is enabled)
|
|
# Parameters: {player}, {screenshot_url}
|
|
discordScreenshotMessageWebhookStyle = """
|
|
{
|
|
"content": ""
|
|
}
|
|
"""
|
|
# Server started message
|
|
# Parameters: {discord_chat_mod.server.started}
|
|
discordServerStartedMessageStyle = """
|
|
{
|
|
"embed": {
|
|
"description": "{discord_chat_mod.server.started} <t:{timestamp}:R>",
|
|
"color": "#2ECC71"
|
|
}
|
|
}
|
|
"""
|
|
# Local server started message
|
|
# Parameters: {discord_chat_mod.server.local_started}, {server_port}
|
|
discordLocalServerStartedMessageStyle = """
|
|
{
|
|
"embed": {
|
|
"description": "{discord_chat_mod.server.local_started} <t:{timestamp}:R>",
|
|
"color": "#2ECC71"
|
|
}
|
|
}
|
|
"""
|
|
# Server closed message
|
|
# Parameters: {discord_chat_mod.server.closed}
|
|
discordServerClosedMessageStyle = """
|
|
{
|
|
"embed": {
|
|
"description": "{discord_chat_mod.server.closed} <t:{timestamp}:R>",
|
|
"color": "#E74C3C"
|
|
}
|
|
}
|
|
"""
|
|
# Pinned server status message when server is unavailable
|
|
# Parameters: {discord_chat_mod.server.status.unavailable}
|
|
discordPinnedStatusMessageServerUnavailableStyle = """
|
|
{
|
|
"embed": {
|
|
"description": "{discord_chat_mod.server.status.unavailable}",
|
|
"color": "#E74C3C"
|
|
}
|
|
}
|
|
"""
|
|
# Pinned server status message when server is available but there are no players
|
|
# Parameters: {discord_chat_mod.server.status.available}
|
|
discordPinnedStatusMessageServerAvailableStyle = """
|
|
{
|
|
"embed": {
|
|
"description": "{discord_chat_mod.server.status.available}",
|
|
"color": "#1F8B4C"
|
|
}
|
|
}
|
|
"""
|
|
# The characters separating player nicknames in the {player_list} parameter for the pinned status message style
|
|
discordPinnedStatusMessagePlayerListDelimiter = "\n"
|
|
# Style of a single nickname in the {player_list} parameter of a pinned status message
|
|
# Parameters: {player}, {counter} — can be used to number players in order
|
|
discordPinnedStatusMessagePlayerListNicknameStyle = "{player}"
|
|
# Pinned server status message when there are players on the server
|
|
# Parameters: {discord_chat_mod.server.status.online_players}, {player_list}, {player_count}, {max_players}
|
|
discordPinnedStatusMessageStyle = """
|
|
{
|
|
"embed": {
|
|
"title": "{discord_chat_mod.server.status.online_players}",
|
|
"description": "{player_list}",
|
|
"color": "#2ECC71"
|
|
}
|
|
}
|
|
"""
|
|
# The username displayed in Discord when forwarding a message from another guild
|
|
# Parameters: {member}, {user}, {guild}
|
|
discordGuildForwardedMessageUserNameStyle = "{user} ({guild})"
|
|
|
|
[[guilds]]
|
|
# The [[guilds]] section is used to define the main and additional channels within a specific discord guild.
|
|
# You can copy this section entirely and define another discord guild in the configuration.
|
|
# In the guildId field you must specify the identifier of the discord guild to which all the channels listed below belong.
|
|
guildId = ""
|
|
# Discord channel ID for messaging with MineCraft
|
|
# [!] Make sure the bot has access to the channel and all the permissions listed above.
|
|
defaultChannelId = ""
|
|
# Discord channel ID for logs from Minecraft Server console
|
|
# Leave blank if you don't want to send server logs to this guild.
|
|
serverLogsChannelId = ""
|
|
# Create a pinned message with the current server status and player list
|
|
enablePinnedStatusMessage = true
|
|
|
|
[guilds.slashCommands]
|
|
# If true, slash commands will be enabled for this guild (/list, /uptime, /tps, /cmd)
|
|
enableSlashCommands = true
|
|
# List of Discord role IDs or role names that are allowed to use the /cmd slash command.
|
|
# The /cmd command lets users execute Minecraft server commands from Discord.
|
|
# If empty, /cmd is disabled for everyone. /list, /uptime, and /tps are always available.
|
|
# Example: ["Admin", "Moderator"] or ["123456789012345678"]
|
|
slashCommandAllowedRoles = []
|
|
|
|
[guilds.channelOverrides]
|
|
# If true, messages will still be sent to the main channel, but will also be duplicated to the specified channels.
|
|
duplicateMessages = false
|
|
# Overrides the default channel for pinned server status message. If empty, uses defaultChannelId.
|
|
pinnedStatusMessageChannelId = ""
|
|
# Overrides the default channel for player death messages. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending death messages to Discord
|
|
deathsChannelId = ""
|
|
# Overrides the default channel for player advancement messages. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending player advancement messages to Discord
|
|
advancementsChannelId = ""
|
|
# Overrides the default channel for server started/closed messages. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending server started/closed messages to Discord
|
|
serverStartStopChannelId = ""
|
|
# Overrides the default channel for player join/leave messages. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending player join/leave messages to Discord
|
|
playerJoinLeaveChannelId = ""
|
|
# Overrides the default channel for messages from players in Minecraft chat. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending messages from Minecraft players chat to Discord
|
|
playerChatMessagesChannelId = ""
|
|
# Overrides the default channel for screenshots sent from Minecraft. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending screenshots from Minecraft to Discord
|
|
screenshotsChannelId = ""
|
|
# Overrides the default channel for messages sent using /tellraw @a command. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending messages sent using /tellraw @a command to Discord
|
|
tellrawChannelId = ""
|
|
# Overrides the default channel for messages sent using /say command. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending messages send using /say command to Discord
|
|
sayChannelId = ""
|
|
# Overrides the default channel for messages sent using /me command. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending messages send using /me command to Discord
|
|
meChannelId = ""
|
|
# Overrides the default channel for logged player commands. If empty, uses defaultChannelId.
|
|
# Specify "-1" to disable sending command log messages to Discord
|
|
commandLogChannelId = ""
|