Latest Posts

Changes in DedicatedServer

Editor Comment

note


Revision Differences of Revision 3

# Dedicated Server ¶

#### Contents ¶
[TOC] ¶


## How does it work ¶
From Build 16 on, the main Widelands executable supports a terminal based "dedicated server modus". Following is a short description how this modus works: ¶

* To start Widelands in dedicated Modus, run Widelands in a terminal like this: _widelands --dedicated=<path to default map>_ ¶
* Server starts up, connects to the metaserver and opens a game with the default map. ¶
* The clients can now connect set up the server via chat commands and can start the game. ¶
* Once started the game runs until the last player left. Afterwards, the dedicated server closes the game, reconnects to the metaserver and reopens a new game with the default map. ¶

## How to compile ¶
_If you have any notes on how one can ease the compilation of Widelands as dedicated server without X server or similiar stuff, please add here_ ¶

## Start up commands ¶

## Commands at runtime ¶
There are several commands you can give a dedicated server by sending a private message (e.g. "@dedicated start") ¶

### General ¶
These commands can be executed during set up time and in a running game. ¶

* _help_ : Shows all available commands (same as this paragraph). ¶
* _host_ : Runs a host command like "/announce <msg>", "/warn <user> <msg>" or "/kick <user> <reason>" ¶

### During game setup ¶

* _start_ : Starts the game ¶
* _ls_maps_ : Shows a list of available/selectable maps on the host. ¶
* _ls_saved_games_ : Shows a list of available/selectable saved games on the host. ¶
* _switch_map $_ : Switch to map $ (full name with .wmf) ¶
* _switch_save $_ : Switch to saved game $ (full name with .wgf) ¶
* _toggle_type #_ : Toggle type of player # ¶
* _toggle_tribe #_ : Toggle tribe of player # ¶
* _toggle_init #_ : Toggle initialization of player # ¶
* _toggle_win_con_ : Toggles the win condition ¶