The 'Unable to initialize Steam' box comes from the server's first start after an install, with or without Steam running; the registry workaround was not the fix. Co-Authored-By: Claude Opus 5.5 <[email protected]>
cs16-dm-server
A Counter-Strike 1.6 deathmatch server you can set up without knowing anything about servers. It runs on a Windows PC (for playing with friends tonight) or on a Linux machine (for a server that's always on).
What you get:
- Free-for-all deathmatch: instant respawn, gun menu, no rounds. GunGame is one menu option away.
- Bots that fill the server when it's empty and leave as people join.
- Damage numbers, killstreak announcer, +HP per kill, rock-the-vote (
rtv),/rankand/top15. - An all-time kill counter.
- Players can join with the Steam version or a non-Steam client.
Windows
You need 64-bit Windows 10 or 11 and about 1.5 GB of free space.
- Click Download ZIP on this page and unzip it (Downloads is fine).
- Double-click
setup.cmd. Answer the questions or press Enter to keep the defaults. It downloads the game (about 600 MB) and starts the server in its own window. Say Yes when Windows asks for admin permission: that lets your friends through the firewall. - Setup then asks how your friends will join and helps with that (see below).
The server is installed in Documents\cs16 (or C:\Users\<you>\cs16 if your Documents folder is synced by OneDrive). From then on, double-click cs.cmd in that folder to start or stop the server, change the map or mode, set the bots, or see the kill counter. Closing the server window stops the server.
Running setup.cmd again is safe: it keeps your settings. setup.cmd -Update also updates the game files.
This was tested on Windows 10. Windows 11 should work the same way.
Linux
For a server that stays on. You need an x86-64 machine (no Raspberry Pi: the game server is 32-bit x86), Docker with the compose plugin, git and python3. With 6 bots it uses about 10% of one core and 100 MB of RAM.
git clone https://git.userevolt.app/esef/cs16-dm-server.git
cd cs16-dm-server
./setup.sh # asks: server name, join password, port, mode, bots
./scripts/install-cron.sh # optional: restarts a hung server, nightly backups
Run it as a normal user in the docker group, not as root. Then use ./cs for the menu:
./cs menu
./cs status who's on, map, mode
./cs map de_inferno change map
./cs mode gg GunGame (./cs mode dm goes back)
./cs bots 6 fill up to 6 players with bots (0 = none)
./cs kills kill counter
./rcon server console
How friends join
Everyone opens Counter-Strike 1.6, presses ~ for the console and types connect <address>. Which address depends on where they are:
| Where your friends are | What to do | They connect to |
|---|---|---|
| Same house | nothing | the LAN address setup shows, e.g. 192.168.1.20:27015 |
| Anywhere, easiest | free playit.gg account, add a UDP tunnel to 127.0.0.1:27015 |
the address playit gives you, e.g. name.ply.gg:12345 |
| Anywhere, no extra app | forward UDP 27015 on your router to this PC | your public IP, e.g. 203.0.113.5:27015 |
| A fixed group | everyone installs Tailscale or ZeroTier | your VPN address |
On Windows, setup walks you through these, and cs.cmd → 10 brings it back. Port forwarding doesn't work on some connections (mobile internet, many dorms, some fiber providers). If friends can't connect after forwarding, use playit.
With playit, every player arrives from playit's address, so never ban by IP: it would kick everyone.
More for players (Steam and non-Steam): docs/PLAYERS.md.
When something goes wrong
- Setup stopped with an error. Fix what it says (usually the internet connection) and run it again. It continues where it stopped.
- Friends can't connect, but you can. On Windows, run
cs.cmd→ 10 → 1 and accept the admin prompt so the firewall lets them in. If they're not in your house, check the playit tunnel or the port forward. - "Unable to initialize Steam" (Windows). This can happen once, on the first start after installing;
cs.cmdand setup retry by themselves. If you startedhlds.exeyourself, close the box and start the server withcs.cmd→ 9. - The server window closes right away, or setup says files are missing. Your antivirus probably removed a file. Allow the install folder in it and run
setup.cmdagain. - The port is taken. Setup offers the next free port. Your friends then need that port in the address.
Settings
Windows keeps them in settings.txt, Linux in .env (same names). After a change, restart the server (cs.cmd → 7 on Windows, ./cs apply on Linux).
| Setting | Default | |
|---|---|---|
CS_HOSTNAME |
CS 1.6 Deathmatch |
name in the server browser |
CS_PASSWORD |
empty | join password; empty = anyone can join |
CS_MAXPLAYERS |
16 |
|
CS_PORT |
27015 |
game port (UDP) |
CS_MAP |
de_dust2 |
first map, then mapcycle.txt |
CS_MODE |
dm |
dm or gg on the first install; after that the menu remembers it |
CS_BOTS |
6 |
bots fill the server up to this many players; 0 = none |
CS_BOT_DIFFICULTY |
2 |
0 easy to 4 expert |
CS_NAME |
cs16 |
Docker container name (Linux only) |
Anything else goes in hlds/cstrike/custom.cfg, which setup never overwrites. It has examples inside (time limit, alltalk, HP per kill, sounds).
| Deathmatch | GunGame | |
|---|---|---|
| Respawn | 0.7 s, 2 s spawn protection | 1 s |
| Weapons | gun menu on spawn | glock, pistols, shotguns, SMGs, rifles, M249, HE, knife; 2 kills per level |
| Map time | 20 min | 30 min, 30 s knife warmup |
Both are free for all, with spawn points for the 11 stock maps in the default mapcycle. Admins, custom maps, fast downloads and backups: docs/ADMIN.md. How it's put together: docs/HOW-IT-WORKS.md.
Updating
Linux: git pull && ./setup.sh (add --update to also update the game). Windows: download the new ZIP and run its setup.cmd; it updates your existing install. Your settings, passwords, admins, mapcycle, custom.cfg, stats and kill counter are kept.
Credits
Setup downloads these from their own projects. Each file is checked against a pinned checksum; some have a backup copy on this Gitea in case their site is down.
- ReHLDS, ReGameDLL_CS, Metamod-R, ReAPI, ReUnion
- AMX Mod X
- CSDM-ReAPI
- YaPB
- GunGame by Avalanche
- DM spawn points from CSDM 2.1 by Arkshine
- Announcer sounds from hpoon/HLDS-CS1.6
Counter-Strike belongs to Valve. The game files come from Steam (SteamCMD, anonymous login). The scripts, configs and plugins here are MIT licensed (LICENSE).