With the right configuration, you can turn your Barotrauma game server into exactly the server your crew is looking for: give it a custom name, set a password, make it public or private, and choose the game mode, respawn rules, karma system, and mods from the Steam Workshop. In this guide, we’ll show you which settings are available, where to find them in ZapX, and what you can adjust directly in the configuration file.
Barotrauma reads its server settings from the serversettings.xml file in the config folder. You don’t need to change the most important values manually, though: you can find them in ZapX under the Configuration tab, in Startup parameters.
Whenever your server starts, it writes the values from the startup parameters to the corresponding places in serversettings.xml. Everything else, such as the game mode, respawn, or voting settings, remains unchanged and can be edited directly in the file. You can open the file in the Configuration tab or in the Files tab, in the config folder.
Always change values that are available as startup parameters in Startup Parameters, not directly in serversettings.xml. Any changes made to the file will be overwritten the next time the server starts with the values from the startup parameters.
After you save the startup parameters, ZapX will prompt you to restart the server. Your changes won’t take effect until the server has restarted.
| Startup parameter | Meaning |
|---|---|
| Server name | Your server’s name in the in-game server list. Default: ZapX Barotrauma Server |
| Server password | Password required to join. Leave this blank for an open server. |
| Publicly visible | Shows your server in Barotrauma’s public server list. Default: enabled. If disabled, your server won’t appear in the list, but players can still join directly using its IP address and port. |
You can’t set the maximum number of players yourself: each time your server starts, it writes the number of slots for your server as MaxPlayers in serversettings.xml. ZapX also sets the ports (port and queryport) automatically at every startup. See Connect to the server to learn how to connect using the IP address and port.
All settings are listed in serversettings.xml as attributes of the <serversettings ...> entry, for example, KarmaEnabled="True". Write yes/no values as True or False.
Barotrauma rewrites serversettings.xml when the server shuts down. If you edit the file while your server is running, your changes will be lost the next time it stops or restarts. So stop your server from the Overview before editing the file, save it, and then start the server again.
These are the settings most commonly changed:
| Setting | Meaning |
|---|---|
GameModeIdentifier | The game mode new rounds start with: sandbox, multiplayercampaign (campaign), pvp, or mission |
RandomizeSeed | True generates a new random level in every round |
RespawnInterval | The interval, in seconds, at which dead players return to the game |
UseRespawnShuttle | True makes dead players return in a shuttle instead of appearing directly at the submarine |
KarmaEnabled | True enables the karma system, which automatically restricts disruptive players (friendly fire, sabotage) |
TraitorProbability | The probability, from 0 to 1, that a traitor event will start in a round |
StartWhenClientsReady | True automatically starts the round once enough players are marked as “Ready” |
AllowVoteKick | True allows players to vote to kick another player |
KickVoteRequiredRatio | The proportion of players, from 0 to 1, who must vote to kick someone |
AllowEndVoting | True allows players to vote to end the current round |
RequireAuthentication | True only allows players with a valid Steam login to join the server |
BanAfterWrongPassword | True temporarily bans players if they enter the password incorrectly too many times. Set the number of attempts with MaxPasswordRetriesBeforeBan |
The PvP game mode also has PvpTeamSelectionMode (PlayerPreference or Random), PvpAutoBalanceThreshold (the player count difference at which teams are balanced), and PvPSpawnMonsters (True allows monsters to spawn in PvP rounds as well).
The file contains many other values, such as time limits, kick and ban durations, and submarine selection. You don’t need to edit the <campaignsettings> entry: a new campaign uses the settings chosen in-game when the campaign starts, while an existing save uses the settings from that save.
You can also change many settings directly in-game if you have the appropriate permissions on your server. For example, you need ManageSettings for server settings, SelectMode for the game mode, and SelectSub for the submarine. When the server shuts down, it saves these changes to serversettings.xml, so they’re retained. Only the server name, password, visibility, player count, and ports are reset to the ZapX values the next time the server starts.
See Become an admin on your own server to learn how to grant yourself these permissions and what permissions are available.
Add Barotrauma mods in the Workshop tab. Under Add Workshop items, enter the item IDs or links for the mods from the Steam Workshop, separated by commas, and click Add. You can add up to 50 Workshop items.
Your Workshop changes will be applied the next time the server starts: it will download the mods, place each one in its own zapws_<ID> folder in LocalMods, and activate them in the config_player.xml file in the config folder. If you remove a mod from the list, your server will delete it the next time it starts.
To upload your own non-Workshop mods, use the Files tab to upload them as folders to LocalMods. To have your server load them, stop the server and add them to <regularpackages> in config_player.xml, for example, <package path="LocalMods/MeineMod/filelist.xml" />. The Workshop feature won’t change these entries.
Your server’s save files are stored in the saves folder. See Manage save games to learn how to download, upload, and back them up.
You’ve now configured your Barotrauma server to suit your needs. See Become an admin on your own server to learn how to grant yourself admin rights. If something isn’t working as expected, our guide to Common issues can help. If you have any other questions, our support team is available every day! 🙂
