Role
The GameServer runs the actual game world. Each sub server is its own GameServer folder (4.1.GameServer_NON-PVP, 4.2.GameServer_PVP...) with its own GameServer.conf file (section [GameServer]). The GameServer reads Data\game_common.conf first (shared configuration), then reads its own GameServer.conf; if a key has the same name, GameServer.conf wins.
The player port, the IP sent to the client and the PvP type of the sub are not set here but in Data\ServerMap.xml: the GameServer finds its own line in that file by ServerCode.
Keys
| Key | Sample value | Meaning |
|---|---|---|
ServerName |
"Regular NonPvP" |
Name shown on the server window and the START tab. Note: for the 3 special subs, the GameServer identifies the sub by this very name (case-insensitive): "Event" (Event sub), "Siege" (Castle Siege sub), "ArkaWar" (Arka War sub). Regular subs can be named freely but must not duplicate these 3 names. |
ServerCode |
0 |
Server code, which must match exactly 1 ServerCode line in Data\ServerMap.xml (the port, IP and display name are taken from there). Each GameServer needs its own code; two GameServers with the same code on the same machine will not be allowed to run (the program creates a mutex per ServerCode; if duplicates ran, they would fight over characters with ConnectServer / ServerLink). |
DataPath |
"" |
Dedicated Data folder for this GameServer. Empty = use the shared ..\Data like every sub. If set: any file that exists in the dedicated folder is used, and any that does not exist is taken from the shared ..\Data. So you only need to copy in the files you want to differ, keeping the subfolder structure (for example Monster\MonsterSpawn.xml, Item\Drop\...). The folder name is up to you; a relative path is counted from the GameServer folder, or you can write a full path. Examples: DataPath = "Data", DataPath = "..\Data_VIP". LoginServer / ConnectServer still read the shared Data (ServerMap.xml, Common.ini [Account], the VIPServers section of VIPSystem.xml...). |
ServerType |
0 |
GameServer type: 0 = regular (leveling, PK...), 1 = Castle Siege, 2 = Event, 3 = Arka War. Different from ServerType in ServerMap.xml (PvP / Gold type, see Sub server & ServerMap). |
Client.ListenIP |
"192.168.1.128" |
The network card that opens the port for players (the ServerPort in ServerMap.xml). "0.0.0.0" = all network cards, use this when running online (recommended). A LAN IP = only the network card with that IP. "127.0.0.1" = only accepts clients running on the server machine itself; outside players cannot connect. Default when the key is omitted: 0.0.0.0. The sample value is the LAN IP of the development machine, so you must change it. |
SS22.Client |
1 |
Present in the sample file (note: 1 = client 22.1.2, 0 = client 21.1.3). In version 1.3 the program no longer reads this key (it always runs for the Season 22 client). Keep 1. |
ShutdownSaveSeconds |
120 |
Present in the sample file but no longer read: when shutting down, the GameServer always waits until all characters / items are saved to the database before exiting. You can leave it as is. |
ShutdownTimeoutSeconds |
60 |
Forces exit when the GameServer has been silent (making no progress) for more than this many seconds during shutdown (a real hang). It does not force exit based on total time: if it is still waiting on the database save and making progress, it keeps waiting. Minimum effective value is 60; 0 = disable the mechanism. |
Panel |
1 |
1 = show the management window; 0 = black console only. When launched from START it is always shown in the START tab. |
Logskill |
1 |
1 = enable skill log: sends logs written by the skill Lua scripts (the log functions in the scripts) to the GameServer window and START ("Log skill" button). 0 or missing = off. Only present in the sample file of the Non-PvP sub. |
The database connection keys (
GameDB, AccountDB, LogDB) and the ConnectServer / LoginServer / ServerLink addresses are not written in GameServer.conf but in Data\game_common.conf. If you want a sub to use a different database or address, write that key again in the sub's GameServer.conf (if a key has the same name, GameServer.conf wins).Sample values for the 6 subs
| Folder | ServerName |
ServerCode |
ServerType (conf) |
|---|---|---|---|
4.1.GameServer_NON-PVP |
"Regular NonPvP" |
0 | 0 |
4.2.GameServer_PVP |
"Regular PvP" |
1 | 0 |
4.2.GameServer_VIP |
"Regular PvP" (rename it to tell them apart easily, for example "Regular VIP") |
2 | 0 |
5.GameServer_Siege |
"Siege" |
19 | 1 |
6.GameServer_Event |
"Event" |
18 | 2 |
7.GameServer_ArkaWar |
"ArkaWar" |
17 | 3 |
GameServer.conf example
[GameServer]
ServerName = "Regular NonPvP"
ServerCode = 0
DataPath = ""
ServerType = 0
Client.ListenIP = "0.0.0.0"
ShutdownTimeoutSeconds = 60
Panel = 1
Logskill = 1
Adding a new sub
- Copy an existing GameServer folder as is, and give it a name with a leading number so START sorts it correctly (for example
4.3.GameServer_PVP2). START reads this number to know the launch order; with the same main number (4), folders 4.1, 4.2, 4.3 are launched in turn. - Edit
ServerNameandServerCode(an unused code). - Add 1 matching
<Server .../>line toData\ServerMap.xml(a new, unused port). See Sub server & ServerMap. - Open the new port on the firewall (Open ports / firewall).
- In START: Settings → Rescan (or Add exe...) so START picks up the new server, enable this entry and click Save settings.