Skip to content

Commit

Permalink
GitBook: [#289] No subject
Browse files Browse the repository at this point in the history
  • Loading branch information
dgibbs64 authored and gitbook-bot committed Jun 6, 2022
1 parent 9e74cdc commit c159f72
Showing 1 changed file with 12 additions and 13 deletions.
25 changes: 12 additions & 13 deletions game-servers/call-of-duty-4.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,29 @@ After investigating this issue, it was found that it is possible to run a server

`cod4server` uses CoD4x project for its server, rather than the original, as it fixes various bugs and adds a few features over the vanilla server.

[https://cod4x.me](https://cod4x.me)
[https://cod4x.ovh](https://cod4x.ovh)

### Updating CoD4x

CoD4x has its own update functionality. It will automatically check for updates and does not require LinuxGSM to check for updates.

### CoD4x Master Server

CoD4x game servers \(since version 17.6\) require a server token to be listed on the CoD4x master server.
CoD4x game servers (since version 17.6) require a server token to be listed on the CoD4x master server.

To generate a token visit [here](https://cod4master.cod4x.me/index.php?token_generator=true).
To generate a token visit [here](https://cod4master.cod4x.me/index.php?token\_generator=true).

Once a token is generated add it to the `sv_authtoken` cvar in `server.cfg` or command-line parameters.

#### server.cfg

```text
```
set sv_authtoken "mytokenhere"`
```

#### command-line parameters

```text
```
+set sv_authtoken "mytokenhere"
```

Expand All @@ -50,7 +50,7 @@ Mods for Call of Duty 4 have to be manually added to the game server.

To run a mod the servers `fs_game` variable must be set correctly. Mods reside in the `mods` folder inside `fs_homepath`. Example directory tree:

```text
```
mods/
├── pml220
│ ├── mod.ff
Expand All @@ -60,15 +60,15 @@ mods/

To start the server with a mod set the `fs_game` variable accordingly.

```text
```
parms="+set sv_punkbuster 0 +set fs_basepath ${serverfiles} +set dedicated 1 +set net_ip ${ip} +set net_port ${port} +set sv_maxclients ${maxplayers} +exec ${servercfg} +map ${defaultmap} +set fs_game "mods/pml220""
```

## Custom Maps

Modded CoD4 servers have the ability to run with user-created maps. To run a server with a custom map, it has to first be placed in the `usermaps` directory \(if missing simply create it yourself\).
Modded CoD4 servers have the ability to run with user-created maps. To run a server with a custom map, it has to first be placed in the `usermaps` directory (if missing simply create it yourself).

```text
```
├── usermaps
│ ├── mp_nuketown
│ │ ├── mp_nuketown.ff
Expand All @@ -82,7 +82,7 @@ Typically, maps are prefixed by mp\_ following the maps name.

Running custom maps on unmodded servers is not supported, but there is a neat workaround to still load custom maps. First, create a mods folder and some empty folder inside it.

```text
```
├── mods
│ ├── myemptymod
```
Expand All @@ -93,7 +93,7 @@ Now set `fs_game` to `mods/myemptymod` and you will be able to run custom maps.

[Fast download](../commands/fastdl.md) is possible with CoD4 to allow custom maps and mods to be hosted on a webserver.

```text
```
set sv_allowDownload "1" // allow clients to download gamefiles
set sv_wwwDownload "1" // enable download redirection
set sv_wwwBaseURL "http://domain.tld/cod4fastdl/" // defines url to download from
Expand All @@ -104,7 +104,7 @@ here `sv_wwwBaseURL` has to point to a URL served by your web server.

An example directory tree for a served folder may look as below:

```text
```
cod4fastdl/
├── mods
│ ├── pml220
Expand All @@ -117,4 +117,3 @@ An example directory tree for a served folder may look as below:
│ │ ├── mp_nuketown.iwd
│ │ ├── mp_nuketown_load.ff
```

0 comments on commit c159f72

Please sign in to comment.