*
Login 
  Saturday, September 04, 2010  * Server Setup & Admin Guides MOH & COD * Desktop MOHAA Dedicated Server Launch  
  Navigation 

Launching a Dedicated MOHAA Server

Though this guide speaks of Medal of Honor, other games that run on the Quake engine
are very similar in setup and operation, including Call of Duty. 
See the Call of Duty guides for the specific differences.

If you have an extra computer you would like to dedicate as a game host machine (dedicated server), this instruction will walk you through the setup steps.   If the machine cannot support MOHAA, due to an inadequate video card, this instruction will also help since the dedicated server does not require a high-end video card.   

This instruction will walk you through the setup processes, first creating the short cut for launching the server from the desktop or start menu, and then the steps for creating your server configuration file or config (.cfg).  >

LAN vs Internet games. To run a game for LAN (local area network) or on the internet for anyone to join, the process is exactly the same.  The only difference between LAN and internet gaming is that you must open the internet connections for internet gaming, such as to open firewall ports, configure routers, etc.   See the other guides on this site for more information regarding ports and routers, or click here to read a forum post for more details of the difference.

Getting started...

Before starting this process, you should have at least installed the game on the computer that you wish to use as the dedicated machine.   Also, download and install patch 1.11 since this is required for the following instruction.   You do not need to launch the game or do any other in game setup, only install the game and the patch. 

 If you would like to open or download a printable version of this page
 see the Download section of this site

The Launch Command
Make it easy for yourself!   

I do not bother to use the in-game server launch menu, I launch the server with the desired config file from a single icon or shortcut from the computer desktop.   I think you will find this fast, easy to operate, and easy to change & save game settings.

IMPORTANT:   For this instruction to work, you need to first download and install patch 1.11    This patch allows for stand-alone game server that runs without the CD and it provides you with the file mohaa_server.exe which is reqired.   See my downloads page.   

Create a shortcut
In your MOHAA directory, there is a file named MOHAA_server.exe
(if you loaded patch 1.11).   Locate this file with windows explorer, it is most likely in directory  c:\Program Files\EA GAMES\MOHAA and then right click on this file.   With right click, a small menu will appear and then select Create Shortcut.    A shortcut file will then be added to this same directory with the name of  "Shortcut to MOHAA_server.exe".

Add the game launch commands
On this newly created shortcut file, right click on it and select Properties.   In the target field, you will notice that it shows the path for the game such as   "C:\Program Files\EA GAMES\MOHAA\MOHAA_server.exe" with the quotes and all.   DO NOT change this, but you do need to add commands at the end of this line, and it is important that you place these additions AFTER the quotes not within the quotes.

After the quotes, followed by one space (important) type in the following with spaces and all:

 +set dedicated 1 +set ui_console 1 +set g_gametype2 +set sv_maxclients 10 +exec server02.cfg

Important notes about above line:

  1. Some people use dedicated 1 and others use dedicated 2 but I haven't been able to tell the difference.

  2. For g_gametype, place the number of the game type you want  g_gametype2 is for team match.   1 is for Free For All,  3 is round based, and 4 is Objective games.

  3. sv_maxclients is the number of players allowed on your server.  This is also found in the config file but I learned to put it here and can't remember the importance.   If it works, I don't mess with it :)     I do suggest you start with a lower number like 8 or 10 players to make sure your box and connection can handle the number of players.  You can always change this later.  I keep mine at 10 for maximum performance.

  4. IMPORTANT... server02.cfg in this command line is the file name for your server config file.    In the above example, I use server02.cfg but you can leave it just server.cfg or name it something else.   Just make sure you have the file name in this command line the exact same as your config file in the MOHAA/Main directory (more on the config file below).

Once you are sure you have the command line correct exit an then move the shortcut to where you like.   I place mine on the desktop so I do not need to look for it.    Since the my computer is dedicated for running the MOHAA server alone, it is nearly the only icon needed, so it shows on screen when the computer is turned on..

Setup for Multiple game types   
If you want to change your server around often, such as with different game types, keep it really simple.   I am too lazy to edit the files each time I want to change, so I just created separate shortcuts and configurations for each game type.

In the example above,  I have named my shortcut "TeamMatch" since it has gametype2 and server02.cfg in the command line.   The config file server02 in my MOHAA/Main directory is setup for gametype 2 or Team Match.    

I then made a  copy of the TeamMatch shortcut and edited it, naming it to "Objective", changed the command line to game type 4 and config file name to server04.cfg.   I then copied my server02.cfg file to server04.cfg and edited it for objective based games (such as for map rotation or other settings).   

Now when I turn on the computer for the server, I just select the short cut desired and the server launches.   Too easy, right? 

The Server Config File 
The Server Config file must be placed in your MOHAA\main directory.    With a fresh install of MOHAA, you will not have a server config file.  You can download the one attached below, or create your own.

I am no technical expert here, but to edit a config file, you may have problems if you use a word processing tool like MS Word because you need to save it in a manner that doesn't add hidden codes that many word processors put in.   What to be safe?   Copy another .cfg, file from within MOHAA and paste the copy into your MOHAA\main directory or just download mine.  Rename the file to server.cfg (or server01.cfg like I did), and then edit it with Notepad editor to change the content.   This way you do not have to worry about hidden codes, extension, or the format.

Note for the beginners:   Any time a line in the config file starts with the hash marks //,  the line is a comment or ignored by the computer.   Therefore, you will see many lines in my config file starting with // because I try to keep notes on what each command does.  You can also disable a command (not use it) by placing // in front of the command which I have done in some cases. 

You can use my config file, which has Team Match settings
Place the file into your MOHAA/main directory, rename as you want, and edit the settings for your server.  If you are following my instructions exactly, rename this config file to the same name you are using in the shortcut, such as server01.cfg.

 TitleOwnerCategoryLast UpdatedSize (KB) 
TMM's Server Config file (click on "Download" to right) TMMworld Admin 11/27/2008 4.36 Download

Contents of file:

// Edit to fit your preferences. 
// <- Slash marks for comments in this file, ignored by program 

// server name that will show up on the game browser, gamespy, or other server browser tools. 
// Put YOUR server name in the quotes (unless you want to promote TMMworld)
seta sv_hostname "TMMworld.com Servers"

// Public Information
// following four fields do not show up in gamespy, but they will in All-Seeing-Eye, possibly other tools
Sets "Admin" "Your Name"
Sets "Clan" "Your Clan Name"
Sets "Connection" "Cable"
Sets "URL" "http://www.tmmworld.com"
Sets "email" "email address"
Sets "Location" "here"
Sets "CPU" "P4 2Ghz"
Sets "Plug" "Visit TMMworld.com today!"

// Remote Console, or RCON passoword allows for remote server administration 
// a password is also used if running tools such as counter intelligence
seta rconpassword "xxxxxxxx"

// maximum number of players allowed
sv_maxclients "12"


// If you have multiple machines behind the router and want to point to a specific machine
// you would enter the internal IP address for the machine here. just remove the hash marks (//) and
// update with the IP of your machine. If you don't know what this is, don't change anything.
// set net_IP 192.168.1.100

// Sets aside private slots so if server fills, you can still get into the game. 
// You enter the password from your game, within the console and the join the server
// If maxclients is 12, setting this to 1 leaves 11 public. You can have as many 
// private slots as you like, as long as it doesn't exceed the max clients number.
set sv_privateClients "1"
set sv_privatepassword "ZZZZZZZ"

// game type 1=DM Free For All 2=DM Teammatch 3=roundbased 4=objective
g_gametype 2

// minimum ping? why bother? unless you want to keep low ping players out, including yourself.
sv_minping "0"

//sv pure pak checker, if on, should not allow clients to use PAK files the server does not have
//0=off 1=on Not so sure this works with MOHAA
sv_pure 0

// Flooding of messages from other clients too many too fast, this will help stop it
sv_floodProtect 1
sv_flood_waitdelay 10
sv_flood_persecond 4
sv_flood_msg 5

//max ping keeps anyone with a higher ping than this value from connecting
sv_maxping "300"

// team damage friendly fire 0=off 1=on
g_teamdamage "0"

// allows Gamespy browser 1=yes 0=no
sv_gamespy "1"

// inactive spectate is seconds of inactivity before moved to spectator 
g_inactiveSpectate "120"

// inactive kick is seconds that a client will be kicked for inactivity
g_inactiveKick "300"

// max data transmit rate by clients on the server - depends on network
sv_maxrate 6000

// sv_fps 20

// allow downloads 0=off 1=on But does not seem to work in MOHAA
sv_allowDownload 1

// time limit for game 0=no limit (in minutes)
timelimit "20"

//set frag limit to end game. 0=none
fraglimit "0"

//net-niopx disallows IPX connections, TCP only net port 12203
net_niopx 1

// sets the UDP port. If you need to direct to a different port, you can change this but
// if you do not know what you are doing, I suggest you just leave it alone. :)
net_port 12203


// You can play with some of these settings if you dare, but if you have a dedicated server running and
// see only the console, you can pass in game chat to the console. Prepare for alot of data! 
// Remove hash marks if you dare :)
// set developer 2
// set chat 1
// seta sv_chatter 1

// you can also send the chatter to a log if you wish... again... a flood of data. The log file below
// is set to append already, set the g_logsync to 1 when adding the chat

// set log files
seta g_log "myserverlog.log"
seta logfile 3 // console log 0=no 1=buffered 2=continuous 3=append to existing
seta g_logsync 0

// map rotation for the server. this is the list of standard DM maps. If you want to have
// custom maps, you can insert them here as long as you know the proper name. See the FAQ section
// on TMMworld.com for a tip how to get the proper map name needed here.
sv_maplist "dm/mohdm1 dm/mohdm2 dm/mohdm3 dm/mohdm5 dm/mohdm4 dm/mohdm6 dm/mohdm7"

// starting map when launched
map dm/mohdm1


Once you have completed and saved the above, click on your shortcut and launch that server.   

Since this is a dedicated server, the game will not run on this machine, you will only see the game console so do not panic.   You will see the following window on your screen only which is the console for the server.    From the console you can see others join, check status of players, change some game settings while the server is running, and also kick players if required.

Image of console

Note:   In the console, you may get some error messages like "box corrupt" and messages like "Add the following line to *_precache.scr or other.    Do not worry, many people see these messages and to date, have not experienced problems.  Your game is running :) 

Also, you may see a “Hitch Warning“.   This is also normal for the server.  If you want more information on Hitch Warnings, they are explained on the FAQ Page. 

 

For more about the console and commands available, click here.



Please let me know if find this information in error!!!



Copyright 2002-2008 TMMworld.com
All Rights Reserved  (
read more)


 

Have Questions?   No problem, but please post them in the forum!

Copyright ©© 2002-2010 TMMworld
*
Powerd by TMMworld Dot Net Services   Terms Of Use   Privacy Statement