Steam

Steam

Not enough ratings
SourceForts v1.9.4.1 Server Setup
By i drive and 2 collaborators
A guide on how to setup a SourceForts v1.9.4.1 server on Windows and Linux
   
Award
Favorite
Favorited
Unfavorite
Questions? Problems?
If you have any questions or problems during setting up your server, feel free to:
Ask me on Steam
or on Discord: Melectrome#0293

You can also ask someone on the SourceForts 2 Discord Server if I'm unavailable!
Link: SourceForts 2 Discord Server[discord.gg]
INSTALLATION
LINUX
This section of the guide wouldn't exist without Danct12's help. He helped me with getting things to run with Wine on Linux. Massive shoutouts to him!
Linux requirements
System requirements for hosting SourceForts v1.9.4.1 on Linux:
  • A somewhat good CPU (no specifics, an average VPS CPU will do)
  • Minimum 256MB RAM
  • Minimum 4GB free disk space (you may need a bit more if you dont have the packages listed in this guide installed)
  • (OPTIONAL) SourceForts v1.9.4.1 for clients installed on your local PC

Software requirements:
  • Wine - latest version (3.0.2 and higher)
  • Winbind
    • You can get it from your distro package manager.
  • OpenSSL, libssl1.0/1.1, ca-certificates
    • You can get them from your distro package manager. I recommend to install both libssl1.0 and libssl1.1 just for safety.
  • Unzip, or some other way of unzipping zip archives
    • You can get unzip from your distro package manager.
  • Xvfb
    • You only need this if you're on command-line-only without a real screen. You can get it from your distro package manager.
  • RCON-cli or other way of RCONing commands
    • RCON-cli download[github.com]
      You only need this if you're on command-line-only without a real screen.
      You'll need RCON to send commands to the server and to shut it down. If you don't want to install any linux rcon tool you can rcon from your local sourceforts game install.
1. Download Windows SteamCMD
Make a folder for SteamCMD on Wine's virtual filesystem with the following command:
wine cmd /c mkdir C:\\steamcmd

Download the Windows version of SteamCMD.
You can find it here: https://steamcdn-a.akamaihd.net/client/installer/steamcmd.zip

Unzip the zip archive and move the steamcmd.exe file that comes out of it into your steamcmd folder in Wine's C drive (/drive_c/steamcmd/).
2. Install SDK 2006 SRCDS and HL2:DM DS
Run steamcmd.exe with Wine by using the following command:
wine steamcmd.exe
You will most likely see some errors, but it's safe to ignore them.
Once everything updates and the
Steam>
line shows up, you can start typing commands.

Type in the following commands, one by one in order:
login anonymous force_install_dir .\sourceforts\ app_update 232370 validate app_update 205 validate
Note, wait for every command to finish before you type the next. When a command finishes, you should see the
Steam>
show up again.

When you've typed in all of the commands, simply type:
quit
and wait for it to close.
3. Place SourceForts v1.9.4.1 files
Now is the part you'll need your local SourceForts v1.9.4.1 for clients installation.
If you don't have one, download one from here: https://melectro.me/sourceforts.zip

If you're using your local installation:
Find it on your PC, it should be a folder named "sourceforts" that's in your \steamapps\sourcemods\ folder.
You'll need to upload it to the server someway (e.g. with SFTP)
Once you've uploaded it, move the "sourceforts" folder (the one you just uploaded) into the path:
/drive_c/steamcmd/sourceforts/

If you're using the installation from the link above:
Unzip the file you downloaded. It should contain a "sourceforts" folder with a bunch of files and other folders.
Move the "sourceforts" folder (that came out of the zip with a bunch of other files inside of it) into the path:
/drive_c/steamcmd/sourceforts/
4. Done! (almost)
Congratulations, you should now be able to run your very own SourceForts v1.9.4.1 server!
Question, how to?

To run the server, go into your srcds.exe directroy (/drive_c/steamcmd/sourceforts/) and run the following commands:
Xvfb :1 -screen 0 800x600x8 & export DISPLAY=:1 wine start srcds.exe -console -game sourceforts -ip 20.30.40.60 -port 27015 -secured +map sf_sphinx
If you have an actual screen (i.e. you're not on command-line-only), you don't have to use the first two commands.
In the "wine start srcds.exe" command, you can use any launch options you want. You can see more launch options later in this guide in the "CONFIGURATION" section. Make sure to keep the "-console -game sourceforts" launch options!

To stop the server:
If you have an actual screen, simply type "quit" in the srcds.exe window to shut it down.
If you're on command-line-only you'll have to use RCON-cli or other way to RCON the command "quit" to the server (you can also rcon from your own game install):
./rcon-cli --host 20.30.40.60 --port 27015 --password 'yourPassHere' quit
(Example RCON-cli command, replace the IP, port and password if you want to use it)
After you've sent the command, type this in the terminal:
pkill -15 Xvfb

That's it!
WINDOWS
This section of the guide (and this guide as a whole) wouldn't exist without phit's help. He made the original windows server setup guide on SourceForts' steam group discussions and he filled me in on some info about SourceForts server hosting. Shoutouts to him as well!
Windows requirements
System requirements for hosting SourceForts v1.9.4.1 on Windows:
  • A somewhat good CPU (no specifics, an average VPS CPU will do)
  • Minimum 256MB RAM
  • Minimum 4GB free disk space
  • (OPTIONAL) SourceForts v1.9.4.1 for clients installed on your local PC

For this section of the guide, I'll be using a Windows Server.
1. Download Windows SteamCMD
You can find it here: https://developer.valvesoftware.com/wiki/SteamCMD
(Scroll down to "Downloading SteamCMD - Windows")
If you want a direct download link, here: https://steamcdn-a.akamaihd.net/client/installer/steamcmd.zip

Create a folder wherever you want and name it whatever you want to.
Unzip steamcmd.zip and put the steamcmd.exe that should come out of it into the folder you created.
2. Install SDK 2006 SRCDS and HL2:DM DS
Run steamcmd.exe.
Wait for it to update.
When it finishes, the console should look something like this.

You'll also notice that the folder it was in has some new files and folders.

Now, type in the following commands in steamcmd, one by one in order:
login anonymous force_install_dir .\sourceforts\ app_update 232370 validate app_update 205 validate
Note, wait for every command to finish before you type the next. When a command finishes, you should see the
Steam>
show up again.

When you've typed in all of the commands, simply type:
quit
3. Place SourceForts v1.9.4.1 files
Now is the part you'll need your local SourceForts v1.9.4.1 for clients installation.
If you don't have one, download one from here: https://melectro.me/sourceforts.zip

If you're using your local installation:
Find it on your PC, it should be a folder named "sourceforts" that's in your \steamapps\sourcemods\ folder.
You'll need to upload it to the server (if you're hosting on a windows server).
Then, move the "sourceforts" folder (the one from your local installtion, from your pc) into the path:
\<folder of your steamcmd.exe>\sourceforts\

If you're using the installation from the link above:
Upload the zip file to the server or download it on the server itself (if you're hosting on a windows server).
Unzip it. A "sourceforts" folder should come out of it.
Move the "sourceforts" folder that came out of the zip into the path:
\<folder of your steamcmd.exe>\sourceforts\

Your folder with steamcmd.exe should now look something like this:


And the folder "sourceforts" inside that steamcmd.exe folder should look something like this:


And the folder "sourceforts" inside that "sourceforts" folder should look something like this:
4. Done! (almost)
Congratulations, you should now be able to run your very own SourceForts v1.9.4.1 server!
Question, how to?
Simple!

Find srcds.exe. It should be in \<your steamcmd.exe folder>\sourceforts\


Create a shortcut wherever you want (someplace easily accessible, with it you'll be able to run the server).


Now, in the menu that pops up, click "Browse..."


And in the next popup find srcds.exe you located earlier in this step:


Click OK on that popup.
Inside the "Type the location of the item" box, at the end add a space and add the launch options you want, like so:


The launch options are completely up to you. If you don't know anything about launch options, you can read up about them online.
Make sure you include the
eforts\srcds.exe -console -game sourceforts
launch options!

Click Next, and type the name for your shortcut. This can be anything.
Then click Finish.

Now to run your server double click on that shortcut.
That's it!
CONFIGURATION
Launch options
There are a lot of launch options for srcds, but in this guide we'll cover the most important ones.
  • -ip - Binds to a specific IP. By default, listens on all network interfaces.
  • -port - Binds to a different port (By default this is 27015)
  • -secured - Makes the server VAC secured.
  • -insecure - Opposite of -secured, disables VAC.
  • -strictportbind - If a server is already running on the specified port, the server will stop.
  • +randommap - Runs a random map on startup, replaces the +map launch option.
  • +map - Run a specific map on startup.
  • +maxplayers - Specifies the max amount of players that can be on the server at the same time.
  • +log on - Enables server logging (logs console text to log files in /logs/ directory)
  • +clientport - Changes the client port (Default is 27005). Change only if you are running multiple servers on the same machine.
  • -sport - Changes the steam port (Default is 26900). Change only if you are running multiple servers on the same machine.
Basic server configuration
There are three configuration files you should focus on: server.cfg (main server config file), phase_build.cfg and phase_combat.cfg.

phase_build.cfg and phase_combat.cfg are config files that are executed when build phase or combat phase begins. The important thing is to change the "hostname" parameter in those config files to your normal hostname.

server.cfg is the main config file. In it you'll find a few settings already, like mp_sfbanlist, sf_forcebalance, rcon_password etc.
Edit the file to whatever you want to. I personally recommend to just change the hostname, rcon_password (for remote connections), the gameplay settings (if you want) and add some commands of yours.
Here is my server config as an example

If you have more maps or want to not include some maps in your map rotation, simply edit the mapcycle.txt and maplist.txt files in your mod folder. Make sure to make a copy of them in the /cfg/ folder (you can make a symlink if you're on linux).
Metamod: Source, Sourcemod and custom server plugins.
To get custom server plugins, you'll have to get Metamod: Source and Sourcemod first.
Pick the latest dev builds for both! Because of a bug in stable builds, Sourcemod won't work if you don't pick the dev builds.
How to install Metamod: Source:
https://wiki.alliedmods.net/Installing_Metamod:Source
How to install Sourcemod:
https://wiki.alliedmods.net/Installing_SourceMod

Here is a list of plugins that I highly recommend to install:
  • Team change exploit fix
    This plugin fixes two game-breaking exploits that involve using the jointeam console command by blocking it.
    Download link[drive.google.com]
  • SourceForts Game Description Fix
    Because SourceForts 1.9.4.1 had only script fixes and the binaries were not updated, the default game description (the game name in the server browser) is "SourceForts 1.9.4" which is obviously wrong. This plugin provides a simple fix for that.
    Download link[drive.google.com]
  • FreezeStatus
    A plugin that lets you see who last freezed a block. To use, aim at a block and type in chat !freezestatus.
    Download link[forums.alliedmods.net]
  • SourceForts roundsleft
    This plugin shows how many combat rounds are left when you type in the roundsleft message in chat. This helps players that just joined know what part of the match they joined.
    Download link[forums.alliedmods.net]
  • No Block
    This plugin disables collisions for teammates.
    Download link[forums.alliedmods.net]