Latest Posts

Changes in GameHelpMultiplayer

Editor Comment

removed link


Revision Differences of Revision 25

[TOC] ¶

# Multiplayer Game ¶

Widelands can be played either over a LAN or across the Internet. This functionality is designed for multiple players games, but can be used for any other players configurations (even AI-only games). ¶

# Menu ¶

![multiplayer_menu.png](/wlmedia/wlimages/multiplayer_menu.png) ¶

Multiplayer menu contains two buttons: ¶

* Internet game, where you can connect with metaserver lobby and host a game open for players all over the World ¶
* LAN / Direct IP, where you can find games set as local ones, connect with known IP address and host this games ¶

# Login into metaserver lobby ¶

![metaserver_login.png](/wlmedia/wlimages/metaserver_login_1.png) ¶

This window will collect information needed to log into your personal account. Nickname is needed and it will be your name in the lobby. If the name is already taken (somebody is logged into or the name is the same as registered user on Widelands site), simple number will be added to the end of a nickname. For example if you want to log as *myNick* and there will be already a player with the same name, you will get the name *myNick1*. Next player with the same logs will get name *myNick2*. ¶

Password is required only when you want to log as a registered user. ¶

In order to set it, go to your Profile Page and select the [Gaming Password](/ggz/changepw) tab. There you can set a password that is only used for gaming. Enter this password in Widelands and you'll be able to use your forum name. The password is stored with sha1 encryption. The password isn't stored in plain text; we already changed this misleading text in trunk. Only a hash gets stored and transmitted to the server. ¶

Checking *Log in to a registered account* will lead to logging as registered user. Don't check it if you don't have generated password yet. Registered user is not necessary to host or join a game! ¶

*Automatically use this login information from now on.* can be useful option for most of players. It will hide this window in the future and after clicking *Internet game* in multiplayer menu, you will log into the lobby directly with no further questions. After accepting this option, green button ![continue.png](/wlmedia//wlimages/continue.png) will be displayed on multiplayer menu. After clicking on it, you will have a possibility to change anything about nickname, password or other login options. ¶

# Metaserver lobby ¶

[![metaserver_lobby.png](/wlmedia/wlimages/metaserver_lobby.png)](/wlmedia/wlimages/metaserver_lobby.png) ¶

This part of a menu is directly connected via Internet to Widelands server. User interface is divided into few parts: ¶

* [[ GameHelpMultiplayer#list-of-players | list of players ]] ¶
* [[ GameHelpMultiplayer#metaserver-chat | metaserver chat ]] ¶
* [[ GameHelpMultiplayer#list-of-games | list of games ]] ¶
* [[ GameHelpMultiplayer#menu-for-hosting-a-game | menu for hosting a game ]] ¶

## List of players ¶

This part contains a list of all logged users. The names are preceded by a coloured sign (used as road slopes indicators in the game). The red one means that the player is not registered at all. Yellow is for standard, registered by Widelands site users. Green ones are used only for Widelands administrators. ¶

The list contains *Points* section which is controversial in several ways. Forum contains some ideas (f.e. [here](/forum/topic/417/)), but there was no clear consensus about it. In theory all players will have a possibility to points their games. Number of points will show how strong is the player. Currenlty there is no idea how to solve all connected problems. ¶

The list also contains *Game* position, which tells who is currently playing and which game (from the games list). If somebody is connected to any game, he or she can not read or write anything to the metaserver chat. ¶

## Metaserver chat ¶

This part is a simple chat that allow players to communicate. Also messages from metaserver are sent here. First message is about logging in: ¶

*** Server offset is X seconds ¶

This is only pure information. offset of 0 seconds means perfect time synchronizing between your and metaserver clocks. Huge offset (f.e. 3600 seconds) usually means that you have different time zone. Metaserver clock is syncronized with central european time (CET or CEST). ¶

Other messages here are about informing players about recent events or other info. Standard text is: ¶

*** For hosting a game, please take a look at the notes at: ¶
*** http://wl.widelands.org/wiki/InternetGaming ¶

**Writing messages** ¶

There are two typos of messages: ¶

* general, which are readable to all users ¶
* personal, which are readable only to specific recipient and sender ¶

To write a general message you can type anything on the line in the bottom. I will show up in a last row in the chat window. To write a personal message, precede `@Nickname` the text and it will be sent only to one recipient. Also it is possible to choose a person from List of players, double click on the name, and then correct syntax will be provided in the line on the bottom. All private messages are marked and if you send message like: ¶

@yourNick My message to you! ¶

You will see: ¶

myNick @ yourNick: My message to you! ¶

Also there is a possibility to add your name at the beginning of the message. If you write: ¶

/me is writing ¶

It will be changed to: ¶

yourNick is writing ¶

**Beep sound** ¶

For a some time all messages sent in the chat are also indicated by a short beep sound. Now you can wait for other players and leave Widelands window in a background. When somebody will ask you for anything - you will hear a signal. ¶

**IRC channel** ¶

Also IRC channel (#widelands, [chat here](/webchat/)) is connected to metaserver chat. All messages sent there are shown in the chat window and all messages sent by players are shown to IRC clients. ¶

## List of games ¶

This part of layout contains all games that are available on metaserver. There are major three types of games and all of them are indicated by special marks: ¶

![continue.png](/wlmedia//wlimages/continue.png) ¶
This mark means that the game is properly connected to the metaserver and you should be able to connect to the game. ¶

![different.png](/wlmedia/wlimages/different.png) ¶
This mark means that the game is properly connected to the metaserver, but the Widelands version is different than yours. Depending on changes between versions, it is possible or not to connect the host and play the game. ¶

![stop.png](/wlmedia//wlimages/stop.png) ¶
This mark means that the host is unable to join. There are two major reasons for that: the game is already started (there is no chance to join running game) or the host is not connected to the metaserver (there is no chance to join unreachable host). ¶

**Possible problems** ¶

1. **Can't join open game (green button).** Some antivirus programs are stopping any connection from outside (except standard protocols & ports). When you are trying to join a host that have such a antivirus, your Widelands game will wait for some (long) time, send warning message and probably crash. From host point of view, there will be a player joining and suddenly exiting from the hosted server. There should be message left, that the player wanted to join, but it failed. To avoid such a situation, antivirus program should be configured to let people join the server. If you are not experienced with advanced configuration, it is also possible to temporary disabling antivirus, then wait for fellows that want to play and after they join - enable antivirus. That should work too. ¶

2. **Can't join server with "?" sign.** Using different versions of Wildelands is always a risk. Most of times it is working well if the version number is almost the same. (We are talking about development version, not released ones ;) .) But sometimes between builds there are changes in code that don't allow play with the same conditions. Most common problems were with missing files or scripts (in older ones, some files haven't existed, while newer ones had them). Some changes that differ gameplay (not user interface!) can be detected just after starting the game and then desyncs message is sent and the player is kicked out (see [below](#desync-messages)). ¶

## Menu for hosting a game ¶

This menu is very easy: you can type name of server/game you want to host, then press the button "*open a new game*". After that you should be able to choose a map and players, like in [[ GameHelpSinglePlayer/#standard-game | Single Player mode ]] with some additions. ¶

**Bug/ feature** ¶
The name of the game can contain whitespaces only or can be even blank string. The name will be still valid. But for the players (humans), the *Game* position will be unrecognizable from free players. Accidentally you can write to somebody who is already playing. That is why you should give a *readable* names for games. ¶

# Multiplayer game setup ¶

[![multiplayer_game_setup.png](/wlmedia/wlimages/multiplayer_game_setup.png)](/wlmedia/wlimages/multiplayer_game_setup.png) ¶

This part contains few parts: ¶

* [[ GameHelpMultiplayer#clients-list | clients list ]] ¶
* [[ GameHelpMultiplayer#players-list | players list ]] ¶
* [[ GameHelpMultiplayer#map-details | map details ]] ¶
* [[ GameHelpMultiplayer#win-conditions | win conditions ]] ¶
* [[ GameHelpMultiplayer#ingame-chat | ingame chat ]] ¶

## clients list ¶

Clients list contains all clients name and their role in future gameplay. The role can be: ¶

![menu_tab_watch.png](/wlmedia//wlimages/menu_tab_watch.png) ¶
This means that the client is a spectator. He or she can see all the map and the players around with no fog of war. ¶

![genstats_enable_plr_01.png](/wlmedia//wlimages/genstats_enable_plr_01.png) ![genstats_enable_plr_02.png](/wlmedia//wlimages/genstats_enable_plr_02.png) ![genstats_enable_plr_03.png](/wlmedia//wlimages/genstats_enable_plr_03.png) ![genstats_enable_plr_04.png](/wlmedia//wlimages/genstats_enable_plr_04.png) ![genstats_enable_plr_05.png](/wlmedia//wlimages/genstats_enable_plr_05.png) ![genstats_enable_plr_06.png](/wlmedia//wlimages/genstats_enable_plr_06.png) ![genstats_enable_plr_07.png](/wlmedia//wlimages/genstats_enable_plr_07.png) ![genstats_enable_plr_08.png](/wlmedia//wlimages/genstats_enable_plr_08.png) ¶
This means that the client is a player and he or she will be listed in players list. ¶

## players list ¶

This is the place where you can see all players that are playing. AI players are marked as a face on a screen, human players are marked as a person icon. Tribes emblems are showing the tribe the player will play. All properties are similar to [[ [[ GameHelpSinglePlayer ]]/#selecting-ais-playing-with-you | single player game start window ]]. ¶

## map details ¶

Map details is explaining what type of map and win conditions are used in the game. Small icon of map moves you to map choosing window. If you don't chose the one while hosting the game, you are able to do that any time you want. ¶

You can choose any of saved multiplayer games or begin brand new with any map you have on proper directories of Widelands. If any player doesn't have a map you selected, the map will be transfered via Widelands game itself. Also all selected saved games will be transfered too. The transmission is peer to peer (your computer is connected directly with another one) and the files are usually spliited into smaller parts. Progress of sending the files is shown on chat window with proper messages. ¶

## win conditions ¶

As it is in [[ GameHelpSinglePlayer#win-conditions | single player ]], you can choose the win conditions between given list by clicking on a button under *Type of game* title. ¶

## ingame chat ¶

This is very similar part to [[ #metaserver-chat | metaserver chat ]], but you should rememeber that there are few differences: ¶

* the chat is completely independent from metaserver chat (you can't write to anyone connected to metaserver only and you can't read their messages), ¶
* the chat is coloring names of players according to players' positions, ¶
* spectator is colored in gray, ¶
* all messages will be readable on ingame chat too (the chat will stay at it is) ¶

## lack of connection message ¶

If you don't have clear connection with Metaserver, the game will throw an error visible in chat: ¶

*** METASERVER: ERROR: The metaserver was unable to connect to your game. Most likely it can't be connected to from the internet! Please take a look at [[ InternetGaming ]] to lear how to set up your internet connection for hosting a game online. ¶

## wrong version message ¶

If the player has too old (or too new) version of Widelands and failed connections, the messages are similar to below: ¶

*** WARNING: nickName uses version: bzrXXXX[trunk], while Host uses version: bzrYYYY[trunk] ¶
*** nickName has joined the game ¶
*** nickName has left the game (Something went wrong: [/build/path/to/a/file/script.h:99] The script 'something:path/to/a/script was not found!) ¶

After that client name `\<free\>` with no role is visible on Clients list ¶

# Multiplayer game ¶

When you begin the game, and you open the ingame chat (**Enter**), the window can look like below: ¶

[![multiplayer_game_800_600.png](/wlmedia/wlimages/multiplayer_game_800_600.png)](/wlmedia/wlimages/multiplayer_game_800_600.png) ¶

As you can see, it is very similar to single player mode. There are few minor differences. ¶

## Bottom menu ¶

Bottom menu in standard game is almost the same as it is with single player mode. The only exception is that you can open there a multiplayer ingame chat. The window also appear after pressing **Enter**. ¶

## Players controls ¶

## Playing speed control ¶

## Spectators controls ¶

## Ingame chat ¶

## Disconnect error ¶

![multiplayer_disconnect.png](/wlmedia/wlimages/multiplayer_disconnect.png) ¶

# Playing on a local network (LAN) ¶

Before starting a LAN-game take care that your firewall allows acces to the ports 7394, 7395 and 7396. Than start widelands, go into multiplayer-menu - you now may change your name here -, click on "host a new game" and select a map you would like to play. After clicking on OK, you just need to wait for the other players to join ¶

All other clients connected to the network should now find the server and list it, as soon as those people enter multiplayer-menu. ¶

When all player are ready, just click on "Start game". ¶

# Playing on the Internet ¶

Widelands provides internet games via our metaserver. The user interface should easily lead you through the steps for opening a game.
If you are on Build 19 and older, the player who is hosting the game will also need to do port forwarding through their router - see [[ InternetGaming ]] for more information. Build 20 will use our new relay server, so port forwarding will no longer be necessary.

Alternatively, you can use the LAN-game menu and open up a server (as host) or manually type in the IP of the open server (as client). ¶

# Desync Messages ¶

"Desyncs" are bugs which occur when host and client are not synchronized anymore. Of course there still might be some bugs in widelands code that lead to such desyncs, but in most known cases the problem is based on different widelands-versions. ¶

If you get several desyncs all the time at direct beginning of the game, there's properly something wrong with the versions of widelands in use. If both server and client use the same version, make sure that no other older version of widelands or older widelands data is installed on your system (like you installed a newer version over an old one on windows / you've installed different versions of widelands via apt-get/rpm) Only if server and client have got absolutely the same version and same data, you can be sure to have a minimum danger to get desyncs.