Traductions possibles :
  • English
  • Français (French)
The translation of this page isn't finished yet.

Install the game in local network

This page is especially for computer amateurs so the network and system's part are light not to overload the user with technical stuff.

However these details will be essential in the second tutorial (not written yet) which will be about installing of a web server.

In this tutorial, you are going to learn how to quickly and easily install Simutrans in order to play in a small local network with a couple of computers.

Prerequisite

Computers'side

First you need a minimum of two computers (Windwos, Linux or MacOS):

  • One will work as a server
  • One will be used by another player

Network's side

Obviously the computers must be connected together by a network, with an ethernet connection for example.

  1. Wire : All the computers are either connected together by a network cable or directly connected if there are only two (crossed cable in this case) or by a switch. Search for tutorials on the Internet to create such networks.
  2. wifi : You can connect the computers by a wireless network too. It's basically the same.

http://www.commentcamarche.net/contents/pratique/lan.php3

Note: Present ISP often include these services.

Adress of the server

Also you have to check the IP adress of the computer which is going to be the server.

The way to find it :

Windows

Open a command line :

Start menu → run → type “cmd”

In the new window type : “ipconfig”

Write down the IP adress, for example : 192.168.0.12

Linux :

Open a terminal (the opening process may be different between some versions … with Gnome >2 it's in applications → accessories)

Type ifconfig and write down the IP adress, for example :

mega@sid6:~$ ifconfig
eth9 Link encap:Ethernet HWaddr 00:26:b9:a4:7b:31
inet adr:192.168.0.5 Bcast:192.168.0.255
Masque:255.255.255.0

MacOSX :
Same as Linux.

Note: with wire connection the network card will be of type ethxx whereas in wireless connection it will be wlanxx

Server setup

Once you took the IP adress of the server machine …

Download

http://www.simutrans.com/download.htm
and pak wich corresponding,e.g pak128 2.0 here :
http://sourceforge.net/projects/simutrans/files/pak128/pak128%20for%20111-0/

Download the last Simutrans'release (for example realease 111) on the official website :

Installation

Install Simutrans by classical method.

Configuration

You can modify parameters in file simuconf.tab as single game.

Quickly run game

You can diretly run the game on command line terminal without any modified parameters of simuconf.tab file. Open windows termina, move in repository of Simutrans like that :

On Windows :
cd \<My home directory>\simutrans
So write following command to run game on server mode :
simutrans -server 13356
On Linux :
cd /<my home directory>/simutrans
Write following command to run game in server mode:
./simutrans -server 13356

Game normally works; choose your pak and run choosed game as single mode.

Notice: number 13356 indicates listening port of server to be able to connect itself since a machine by network. By default this one is fixed at: 13353. It is advised to use another of them.

Few tests :

We can easily test that server runs and listens on good port. For that with Linux, always on command line, Write :
netstat -a |grep 13356
Result :
tcp 0 0 *:13356 *:*
LISTEN tcp6 0 0 [::]:13356 [::]:*
LISTEN
We can also test since gamer's machine that server

on peut aussi s'assurer depuis la machine du joueur que le serveur est bien joignable sur le bon port. quelque soit l'OS , en ligne de comande taper :
telnet <adresse_ip_du server> <numero_du_port_choisi> Exemple : telnet 192.168.0.30 13356 One can also check from the player's computer that the server can be joined on the right port. Wathever the OS, type in command line :
telnet <server_ip> <chosen_port_number> Example : telnet 192.168.0.30 13356

Launch the player's post

Installation

On the player's computer, install simutrans (obviously, it must be the same release as before and the same pakset as before).

Join the game

  • 1. Launch the game as usual.
  • 2. In the opening menu, choose join a game.

  • 3. In this box, choose [add server] on the first time.

  • 4. Type in the right field (where <enter adress> is written) the ip adress of the server and the port number
    for example 192.168.0.5:13356. Then, hit [enter] on your keyboard.
  • 5. The button [join the game], which was gray, now becomes clickable. Click it to join the distant game.

Customize the player

  • Open the list of players by hitting [k]
  • Click the green button right to the field [human player]

  • Then, type a name and a password.
  • Hit [enter].

A new player is noticeable on the server (open the player list as well).

Note: the red button indicates that the player is protected with a password.

Common problems

  • The button [join the game] is still gray although is accessible (relevant telnet…)

Versions of the pakset or addons probably don't match. There is a button [find mismatch] to find out the differences between the server and the player's game.

  • The server is not accessible although the network is okay (same range of IP adress…)

A local firewall installed on your computer is likely to prevent Simutrans from connecting. So you have to autorize in and out flows on the chosen ports. The process depends on your OS, google how to autorize a software in the firewall on your OS.

Advanced settings

To be continued.