Trackmania
From MonsterLANWiki
Trackmania Server Setup
1. Download the dedicated server zip or tarball. Here is the forum topic where we provide mirrors to download the dedicated server: http://www.tm-forum.com/viewtopic.php?t=1350
2. Extract the contents of these files into the representative folders for the game(s) you own. c:\program files\trackmania nations eswc
3. Inspect that you have dedicated.cfg (your server configuration file) + trackmaniaserver.exe or: the file trackmaniaserver + a .sh script file for linux users. These files need to be available in the server dir. Then in the subdirs gamedata/tracks/matchsettings/ there should be directories with files that will have the match settings and challenges definition for your game. and your challenges (maps) should be in the /gamedata/tracks/challenges subdir of the server directory. Also do not forget the file DedicatedTrackMania.TrackMania.gbx file which has to be locaded inside the GameData subdir.
All these files are included in the package but the mentioned files are the skeleton selection of files that have to be available in order to run the server. (You can disregard/delete everything else in the server package unless you are going to experiment with application building, )
Ingame Setup
The folowing steps are to be done in the game as if you are setting up a listen server.
1. Launch your game, (client, not the server)
2. Edit your desired server mode and time. click OK (right below) and start choosing the maps you want to have in your server: The thing is that when you selected all your maps you can save it into a txt (xml) file. choose the save function below
3. save it as a txt file to your liking (you dont have to add the .txt) just save it as you want without the extention. in this example stunt.txt
Thats what you need to do in the game...
4. You may close down your game.. or alt tab out of it to the desktop.
The file will now be located in trackmania nations c:\program files\trackmania \gamedata\tracks\matchsettings
The file basicly contains all the server's advanced settings and map settings you selected.
NOTE: If you have a dedicated server directory of it's own: move the maps and directories over starting from the challenges folder. You need to move it over to the corresponding challenges map in the dedicated server directory :
c:\program files\trackmania nations eswc\gamedata\tracks\challenges (with all it's subdirs and maps) has to be moved to c:\tmdedicatedserver\gamedata\tracks\challenges (with all it's subdirs and maps)
5. Now open the map where you have your trackmaniaserver.exe in, press ALT, while dragging the file to your desktop with the mouse
6. Rename the short cut to "server start" or something like that
7. Choose the properties of the shortcut (rightclick the icon > select properties
8. The short cut (target) properties will eventually have to look like this
TrackMania Nations ESWC
"C:\Program Files\trackmania nations eswc\trackmaniaserver.exe" /game=nations /dedicated_cfg=dedicated.cfg /game_settings=MatchSettings/stunt.txt /lan
NOTE: The dedicated.cfg or what ever you want to call it later must be found in the same dir that your trackmaniaserver.exe resides in (to keep things simple), the matchsettings at least in the gamedata/matchsettings dir of your dedicated server repertoire, the challenges in the tracks/challenges dir or subdir etc ...
Also when creating the shortcut, Pay attention to the "'s .
in target: only the executable "C:\YourDedicatedServerDir\trackmaniaserver.exe" is between s , the rest (configuration) is outside the "s ....
If you are finally ready, click ok for the properties and view your shortcut to the server on the desktop,
9. Let's breakdown the functions here... We did:
/game=nations Choose what game you want to play, original, sunrise or nations /dedicated_cfg=dedicated.cfg configuration of the basic server settings /game_settings=MatchSettings/stunt.txt sets the server according your created and saved ingame server settings /internet or /lan (says to the server that it has to be an internet server), but you can join it as lan user as well...
c:\program files\TrackMania Nations ESWC\gamedata\tracks\matchsettings (for trackmania nations)
Again remember to move this file over to c:\tmdedicatedserver\gamedata\tracks\matchsettings when you use a sepparate dir for the server.
Note: In the shortcut, It's no error that the whole directory structure for the match settings isn't visible in the command line option.. The server will look in any directory you specify which is relative to the matchsettings directory, the hard coding of the server sees that as the "base" directory to put your matchsetting files in. Also later on when you see the specifications for the tracks within this match settings file, you'll see that the server will also think the "tracks" directory is the base dir from where you specify subsequent dirs where the tracks (challenge.gbx) files go..
For example when you have a file in c:\tmdedicatedserver\GameData\Tracks\Challenges\my challenges\mymap.challenge.gbx , then the server will only need the specification like this "challenges/my challenges/mymap.challenge.gbx
This is functional when you are going to place the dedicated server on a remote box with windows server or something like that..
so, remember your saved file from the in game menu ? (in this case its stunt.txt) but i color it because you can choose any name you want, this is just an example for you to interpret and do your own thing with...
so the relative designation for your file and map becomes MatchSettings/stunt.txt
Server .cfg Setup
Lets now inspect the dedicated.cfg in c:\YourDedicatedServerDir\
<?xml version="1.0" encoding="utf-8" ?> <dedicated> <authorization_levels> <level> <name>SuperAdmin</name> <password>SuperAdmin</password> </level> <level> <name>Admin</name> <password>Admin</password> </level> <level> <name>User</name> <password>User</password> </level> </authorization_levels> <masterserver_account> <login>YourAccountName</login> <password>YourPassWord</password> <nation>USA</nation> </masterserver_account> <server_options> <name>MonsterLAN Server</name> <comment>www.monsterlan.com The greastest LAN EVER!!!</comment> <max_players>32</max_players> <password></password> <max_spectators>3</max_spectators> <password_spectator></password_spectator> <ladder_mode>forced</ladder_mode> <enable_p2p_upload>True</enable_p2p_upload> <enable_p2p_download>True</enable_p2p_download> <callvote_timeout>60000</callvote_timeout> <callvote_ratio>0.5</callvote_ratio> <allow_challenge_download>True</allow_challenge_download> </server_options> ---- '''You do not need to change anything in the section after this in the config.'''
To make life a whole bunch easier just use servermaina. http://cyrlaur.free.fr/ServerMania/
A couple of careful considerations.
1. Make sure you have .net 2.0 2. Make sure you use the dedicated they link from their site. 3. Make sure you have some sort of config to start with.
Servermaina will give you the ability to check scores and also keeps the top times.
