Skip to content
This repository has been archived by the owner on Sep 1, 2021. It is now read-only.

Commands

Lloyd Dilley edited this page Feb 24, 2021 · 2 revisions

How to Use Commands

Commands are submitted from a Discord text channel using the command prefix. The Discord channel is set in terracord.xml by defining the channel ID:

<!-- Discord channel ID -->
<channel id="123" />

The channel ID can be obtained using these instructions.

The command prefix is also set in terracord.xml and can consist of one or more characters:

<!-- Bot command prefix -->
<command prefix="!" />

You can additionally control whether or not commands sent from Discord are displayed to players in game by configuring the following option in terracord.xml:

<!-- Relay bot commands from Discord to players -->
<relay commands="true" />

Built-in Discord Bot Commands

Command Description
help Display command list
playerlist Display online players
serverinfo Display server details
setgame [status] Set Discord bot game/playing status
uptime Display plugin uptime

TShock Commands

⚠️ Ensure that you only allow trusted roles to execute remote TShock commands as this feature may pose a security risk otherwise.

If remote commands are enabled, the owner and any authorized role(s) can submit commands to TShock from a Discord text channel. The relevant options for controlling this behavior can be found in terracord.xml:

<!-- Toggle execution of TShock commands submitted remotely by Discord bot owner -->
<remote commands="true" />

<!-- List of space-separated Discord roles authorized to execute TShock commands remotely -->
<authorized roles="Administrators Moderators" />

Remote execution applies to any TShock command (including commands from loaded plugins).

Clone this wiki locally