فهرست منبع

feat(pw): port & steamport setting for palworld (#4479)

* fix: servername variable assignment for sf and unt

The servername variable was incorrectly assigned using the selfname variable instead of the correct servername variable. This has been fixed to ensure accurate information is displayed for each game type.

* add: port & steamport setting for palworld

---------

Co-authored-by: Daniel Gibbs <me@danielgibbs.co.uk>
Armin 2 سال پیش
والد
کامیت
64e9e82462
2فایلهای تغییر یافته به همراه6 افزوده شده و 5 حذف شده
  1. 3 2
      lgsm/config-default/config-lgsm/pwserver/_default.cfg
  2. 3 3
      lgsm/modules/info_game.sh

+ 3 - 2
lgsm/config-default/config-lgsm/pwserver/_default.cfg

@@ -11,12 +11,13 @@
 ## Predefined Parameters | https://docs.linuxgsm.com/configuration/start-parameters
 servername="LinuxGSM"
 
-# Use game server config file to edit, used for port check script (workaround)
+# For community servers (serverlist) you need to change these settings (publicip & publicport) in the gameserver config file aswell
 port="8211"
+steamport="27015"
 
 ## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
 ## Game Server Docs | https://tech.palworldgame.com/dedicated-server-guide#linux
-startparameters="EpicApp=PalServer -useperfthreads -NoAsyncLoadingThread -UseMultithreadForDS -servername='${servername}'"
+startparameters="EpicApp=PalServer -useperfthreads -NoAsyncLoadingThread -UseMultithreadForDS -servername='${servername}' -port='${port}' -queryport='${steamport}'"
 
 #### LinuxGSM Settings ####
 

+ 3 - 3
lgsm/modules/info_game.sh

@@ -621,7 +621,7 @@ fn_info_game_pvr() {
 fn_info_game_pw() {
 	servername="${servername:-"NOT SET"}"
 	port="${port:-"0"}"
-	steamport="27015"
+	steamport="${steamport:-"0"}"
 	unknownport="1985"
 }
 
@@ -1978,7 +1978,7 @@ fn_info_game_sdtd() {
 # Config Type: Parameters (with an ini)
 fn_info_game_sf() {
 	# Parameters
-	servername="${selfname:-"NOT SET"}"
+	servername="${servername:-"NOT SET"}"
 	port="${port:-"0"}"
 	queryport="${queryport:-"0"}"
 	beaconport="${beaconport:-"0"}"
@@ -2131,7 +2131,7 @@ fn_info_game_tw() {
 
 # Config Type: Parameters
 fn_info_game_unt() {
-	servername="${selfname:-"NOT SET"}"
+	servername="${servername:-"NOT SET"}"
 	port="${port:-"0"}"
 	queryport="${port}"
 	steamport="$((port + 1))"