Ver código fonte

Added The Forest xml

- Windows support only
- It is tested under Linux/Wine v3.6 and v3.7
- Oxide mod is included to the installation, because it fixes some basic game server issues
Rocco27 8 anos atrás
pai
commit
7a9a1149a8

BIN
images/icons/theforest.png


+ 77 - 0
modules/config_games/server_configs/theforest_win32.xml

@@ -0,0 +1,77 @@
+<game_config>
+  <game_key>theforest_win32</game_key>
+  <protocol>lgsl</protocol>
+  <lgsl_query_name>theforest</lgsl_query_name>
+  <installer>steamcmd</installer>
+  <game_name>The Forest (Oxide mod incl.)</game_name>
+  <server_exec_name>TheForestDedicatedServer.exe</server_exec_name>
+  <cli_template>-batchmode %IP% %PORT% %QUERY_PORT% %STEAM_PORT% %HOSTNAME% %PLAYERS% %CONTROL_PASSWORD% %IT% %SLOT% %SSA% %VAC% -nographics</cli_template>
+  <cli_params>
+    <cli_param id="IP" cli_string="-serverip" options="s" />
+    <cli_param id="PORT" cli_string="-servergameport" options="s" />
+    <cli_param id="PLAYERS" cli_string="-serverplayers" options="s" />
+    <cli_param id="HOSTNAME" cli_string="-servername" options="sq" />
+    <cli_param id="CONTROL_PASSWORD" cli_string="-serverpassword_admin" options="sq" />
+  </cli_params>
+  <reserve_ports>
+    <port type="add" id="QUERY_PORT" cli_string="-serverqueryport" options="s">1</port>
+  </reserve_ports>
+  <console_log>logs/output_log.txt</console_log>
+  <max_user_amount>100</max_user_amount>
+  <mods>
+    <mod key="default">
+      <name>None</name>
+      <installer_name>556450</installer_name>
+      <installer_login>anonymous</installer_login>
+    </mod>
+  </mods>
+  <server_params>
+    <param key="-serversteamport" type="text" id="STEAM_PORT">
+      <default>8766</default>
+      <options>s</options>
+      <access>admin</access>
+      <desc>This is used to authenticate Steam accounts.</desc>
+    </param>
+    <param key="-serversteamaccount" type="text" id="SSA">
+      <caption>Steam Account Login Token</caption>
+      <desc>Manage your Steam tokens &lt;a href=&quot;https://steamcommunity.com/dev/managegameservers&quot; target=&quot;_blank&quot;&gt;here&lt;/a&gt;.</desc>
+    </param>
+    <param key="-inittype" type="select" id="IT">
+      <option value="New">New</option>
+      <option value="Continue">Continue</option>
+      <options>s</options>
+      <desc>New or continue a game.</desc>
+    </param>
+    <param key="-slot" type="select" id="SLOT">
+      <option value="1">1</option>
+      <option value="2">2</option>
+      <option value="3">3</option>
+      <option value="4">4</option>
+      <option value="5">5</option>
+      <options>s</options>
+      <desc>Slot to save the game.</desc>
+    </param>
+    <param key="-serverautosaveinterval" type="text" id="SAVEINTERNAL">
+      <default>15</default>
+      <options>s</options>
+      <desc>Set the autosave interval in minutes.</desc>
+    </param>
+    <param key="-enableVAC" type="checkbox_key_value" id="VAC">
+      <desc>Enable Valve Anti-Cheat.</desc>
+    </param>
+  </server_params>
+  <post_install>
+    if [ -s "TheForestDedicatedServer_Data/Managed/Oxide.TheForest.dll" ]
+      then
+        echo "Oxide mod found. OK!"
+      else
+        echo "Oxide mod not found."
+        echo "Installing Oxide mod!"
+        wget https://github.com/OxideMod/Oxide/releases/download/latest/Oxide-TheForest.zip
+        unzip -o Oxide-TheForest.zip
+    fi
+  </post_install>
+  <configuration_files>
+    <file description="Server Configurations">Server.cfg</file>
+  </configuration_files>
+</game_config>

+ 6 - 2
protocol/lgsl/lgsl_protocol.php

@@ -140,6 +140,7 @@ if (!function_exists('lgsl_version')) { // START OF DOUBLE LOAD PROTECTION
 		"swat4"			=> "SWAT 4",
 		"test"			=> "Test ( For PHP Developers )",
 		"teeworlds"		=> "Teeworlds",
+		"theforest"		=> "The Forest",
 		"tribes"		=> "Tribes ( Starsiege )",
 		"tribes2"		=> "Tribes 2",
 		"tribesv"		=> "Tribes Vengeance",
@@ -200,7 +201,7 @@ if (!function_exists('lgsl_version')) { // START OF DOUBLE LOAD PROTECTION
 		"crysiswars"	=> "06",
 		"cs2d"			=> "29",
 		"cube"			=> "24",
-		"dayzmod"  => "05",
+		"dayzmod"		=> "05",
 		"doomskulltag"	=> "27",
 		"doomzdaemon"	=> "28",
 		"doom3"			=> "10",
@@ -291,6 +292,7 @@ if (!function_exists('lgsl_version')) { // START OF DOUBLE LOAD PROTECTION
 		"swat4"			=> "03",
 		"test"			=> "01",
 		"teeworlds"		=> "21",
+		"theforest"		=> "05",
 		"tribes"		=> "23",
 		"tribes2"		=> "25",
 		"tribesv"		=> "09",
@@ -354,7 +356,7 @@ if (!function_exists('lgsl_version')) { // START OF DOUBLE LOAD PROTECTION
 		"crysiswars"	=> "qtracker://{IP}:{S_PORT}?game=CrysisWars&action=show",
 		"cs2d"			=> "http://www.cs2d.com",
 		"cube"			=> "http://cubeengine.com",
-		"dayzmod"          => "steam://connect/{IP}:{S_PORT}",
+		"dayzmod"		=> "steam://connect/{IP}:{S_PORT}",
 		"doomskulltag"	=> "http://skulltag.com",
 		"doomzdaemon"	=> "http://www.zdaemon.org",
 		"doom3"			=> "qtracker://{IP}:{S_PORT}?game=Doom3&action=show",
@@ -439,6 +441,7 @@ if (!function_exists('lgsl_version')) { // START OF DOUBLE LOAD PROTECTION
 		"swat4"			=> "qtracker://{IP}:{S_PORT}?game=SWAT4&action=show",
 		"test"			=> "http://www.greycube.com",
 		"teeworlds"		=> "http://www.teeworlds.com",
+		"theforest"		=> "steam://connect/{IP}:{Q_PORT}",
 		"tribes"		=> "qtracker://{IP}:{S_PORT}?game=Tribes&action=show",
 		"tribes2"		=> "qtracker://{IP}:{S_PORT}?game=Tribes2&action=show",
 		"tribesv"		=> "qtracker://{IP}:{S_PORT}?game=TribesVengeance&action=show",
@@ -532,6 +535,7 @@ if (!function_exists('lgsl_version')) { // START OF DOUBLE LOAD PROTECTION
 			case "stationeers"		: $c_to_q = -485;	$c_def = 27500;	$q_def = 27015;	$c_to_s = 0;	break;
 			case "squad"			: $c_to_q = 19378;	$c_def = 7787;	$q_def = 27165;	$c_to_s = 0;	break;
 			case "swat4"			: $c_to_q = 1;		$c_def = 10780;	$q_def = 10781;	$c_to_s = 0;	break;
+			case "theforest"		: $c_to_q = 1;		$c_def = 27015;	$q_def = 27016;	$c_to_s = 0;	break;
 			case "tribesv"			: $c_to_q = 1;		$c_def = 7777;	$q_def = 7778;	$c_to_s = 0;	break;
 			case "ut"				: $c_to_q = 1;		$c_def = 7777;	$q_def = 7778;	$c_to_s = 0;	break;
 			case "ut2003"			: $c_to_q = 1;		$c_def = 7757;	$q_def = 7758;	$c_to_s = 10;	break;