|
@@ -22,8 +22,8 @@ fn_info_config_avalanche(){
|
|
|
port="${zero}"
|
|
port="${zero}"
|
|
|
else
|
|
else
|
|
|
|
|
|
|
|
- servername=$(grep "Name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^--/d' -e 's/Name//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "Password" "${servercfgfullpath}" | sed -e 's/^ *//g' -e '/^--/d' -e 's/Password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "Name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^--/d' -e 's/Name//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "Password" "${servercfgfullpath}" | sed -e 's/^ *//g' -e '/^--/d' -e 's/Password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
slots=$(grep "MaxPlayers" "${servercfgfullpath}" | grep -v "\--" | tr -cd '[:digit:]')
|
|
slots=$(grep "MaxPlayers" "${servercfgfullpath}" | grep -v "\--" | tr -cd '[:digit:]')
|
|
|
port=$(grep "BindPort" "${servercfgfullpath}" | grep -v "\--" | tr -cd '[:digit:]')
|
|
port=$(grep "BindPort" "${servercfgfullpath}" | grep -v "\--" | tr -cd '[:digit:]')
|
|
|
|
|
|
|
@@ -34,7 +34,7 @@ fn_info_config_avalanche(){
|
|
|
port=${port:-"0"}
|
|
port=${port:-"0"}
|
|
|
|
|
|
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
|
- ipconfigcheck=$(grep "BindIP" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^--/d' -e 's/BindIP//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ ipconfigcheck=$(grep "BindIP" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^--/d' -e 's/BindIP//g' | tr -d '=\";,:' | xargs -0)
|
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
|
ip="${ipconfigcheck}"
|
|
ip="${ipconfigcheck}"
|
|
|
fi
|
|
fi
|
|
@@ -80,10 +80,10 @@ fn_info_config_dontstarve(){
|
|
|
tickrate="${zero}"
|
|
tickrate="${zero}"
|
|
|
port="${zero}"
|
|
port="${zero}"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "default_server_name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/default_server_name//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "server_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/server_password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "default_server_name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/default_server_name//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "server_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/server_password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
slots=$(grep "max_players" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "max_players" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
- gamemode=$(grep "game_mode" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/game_mode//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ gamemode=$(grep "game_mode" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/game_mode//g' | tr -d '=\";,:' | xargs -0)
|
|
|
tickrate=$(grep "tick_rate" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
tickrate=$(grep "tick_rate" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
port=$(grep "server_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
port=$(grep "server_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
|
|
|
|
@@ -108,13 +108,13 @@ fn_info_config_minecraft(){
|
|
|
gameworld="${unavailable}"
|
|
gameworld="${unavailable}"
|
|
|
else
|
|
else
|
|
|
|
|
|
|
|
- servername=$(grep "motd" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/motd//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- rconpassword=$(grep "rcon.password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/rcon.password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "motd" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/motd//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ rconpassword=$(grep "rcon.password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/rcon.password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
rconport=$(grep "rcon.port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
rconport=$(grep "rcon.port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
slots=$(grep "max-players" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "max-players" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
port=$(grep "server-port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
port=$(grep "server-port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
gamemode=$(grep "gamemode" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
gamemode=$(grep "gamemode" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
- gameworld=$(grep "level-name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/level-name//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ gameworld=$(grep "level-name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/level-name//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
|
|
|
# Not Set
|
|
# Not Set
|
|
|
servername=${servername:-"NOT SET"}
|
|
servername=${servername:-"NOT SET"}
|
|
@@ -126,7 +126,7 @@ fn_info_config_minecraft(){
|
|
|
gameworld=${gameworld:-"NOT SET"}
|
|
gameworld=${gameworld:-"NOT SET"}
|
|
|
|
|
|
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
|
- ipconfigcheck=$(grep "server-ip" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^--/d' -e 's/server-ip//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ ipconfigcheck=$(grep "server-ip" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^--/d' -e 's/server-ip//g' | tr -d '=\";,:' | xargs -0)
|
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
|
ip="${ipconfigcheck}"
|
|
ip="${ipconfigcheck}"
|
|
|
fi
|
|
fi
|
|
@@ -142,12 +142,12 @@ fn_info_config_projectzomboid(){
|
|
|
port="${zero}"
|
|
port="${zero}"
|
|
|
gameworld="${unavailable}"
|
|
gameworld="${unavailable}"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "PublicName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/PublicName//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "Password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^Password" | sed -e '/^#/d' -e 's/Password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- rconpassword=$(grep "RCONPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/RCONPassword//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "PublicName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/PublicName//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "Password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^Password" | sed -e '/^#/d' -e 's/Password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ rconpassword=$(grep "RCONPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/RCONPassword//g' | tr -d '=\";,:' | xargs -0)
|
|
|
slots=$(grep "MaxPlayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "MaxPlayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
port=$(grep "DefaultPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
port=$(grep "DefaultPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
|
- gameworld=$(grep "Map" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^Map" | sed -e '/^#/d' -e 's/Map//g' | tr -d '=\";' | xargs)
|
|
|
|
|
|
|
+ gameworld=$(grep "Map" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^Map" | sed -e '/^#/d' -e 's/Map//g' | tr -d '=\";' | xargs -0)
|
|
|
|
|
|
|
|
# Not Set
|
|
# Not Set
|
|
|
servername=${servername:-"NOT SET"}
|
|
servername=${servername:-"NOT SET"}
|
|
@@ -167,9 +167,9 @@ fn_info_config_idtech3(){
|
|
|
|
|
|
|
|
slots="${zero}"
|
|
slots="${zero}"
|
|
|
else
|
|
else
|
|
|
- rconpassword=$(grep "zmq_rcon_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/set zmq_rcon_password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- servername=$(grep "sv_hostname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/set sv_hostname//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "g_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/set g_password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ rconpassword=$(grep "zmq_rcon_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/set zmq_rcon_password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ servername=$(grep "sv_hostname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/set sv_hostname//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "g_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/set g_password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
slots=$(grep "sv_maxClients" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "sv_maxClients" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
|
|
|
|
|
# Not Set
|
|
# Not Set
|
|
@@ -187,9 +187,9 @@ fn_info_config_realvirtuality(){
|
|
|
serverpassword="${unavailable}"
|
|
serverpassword="${unavailable}"
|
|
|
slots="${zero}"
|
|
slots="${zero}"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "hostname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/hostname//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- adminpassword=$(grep "passwordAdmin" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/passwordAdmin//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "hostname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/hostname//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ adminpassword=$(grep "passwordAdmin" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/passwordAdmin//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
slots=$(grep "maxPlayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "maxPlayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
|
|
|
|
|
# Not Set
|
|
# Not Set
|
|
@@ -208,9 +208,9 @@ fn_info_config_seriousengine35(){
|
|
|
slots="${zero}"
|
|
slots="${zero}"
|
|
|
port="${zero}"
|
|
port="${zero}"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "prj_strMultiplayerSessionName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/prj_strMultiplayerSessionName//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- rconpassword=$(grep "rcts_strAdminPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/rcts_strAdminPassword//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- gamemode=$(grep "gam_idGameMode" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/gam_idGameMode//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "prj_strMultiplayerSessionName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/prj_strMultiplayerSessionName//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ rconpassword=$(grep "rcts_strAdminPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/rcts_strAdminPassword//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ gamemode=$(grep "gam_idGameMode" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/gam_idGameMode//g' | tr -d '=\";,:' | xargs -0)
|
|
|
slots=$(grep "gam_ctMaxPlayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "gam_ctMaxPlayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
port=$(grep "prj_uwPort" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
port=$(grep "prj_uwPort" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
|
|
|
|
@@ -229,9 +229,9 @@ fn_info_config_source(){
|
|
|
serverpassword="${unavailable}"
|
|
serverpassword="${unavailable}"
|
|
|
rconpassword="${unavailable}"
|
|
rconpassword="${unavailable}"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "hostname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/hostname//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "sv_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/sv_password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- rconpassword=$(grep "rcon_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/rcon_password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "hostname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/hostname//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "sv_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/sv_password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ rconpassword=$(grep "rcon_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's/rcon_password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
|
|
|
# Not Set
|
|
# Not Set
|
|
|
servername=${servername:-"NOT SET"}
|
|
servername=${servername:-"NOT SET"}
|
|
@@ -249,8 +249,8 @@ fn_info_config_starbound(){
|
|
|
rconport="21026"
|
|
rconport="21026"
|
|
|
slots="8"
|
|
slots="8"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "serverName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e 's/serverName//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- rconpassword=$(grep "rconServerPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e 's/rconServerPassword//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "serverName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e 's/serverName//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ rconpassword=$(grep "rconServerPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e 's/rconServerPassword//g' | tr -d '=\";,:' | xargs -0)
|
|
|
port=$(grep "gameServerPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
port=$(grep "gameServerPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
|
queryport=$(grep "queryServerPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
queryport=$(grep "queryServerPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
|
rconport=$(grep "rconServerPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
rconport=$(grep "rconServerPort" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
@@ -273,7 +273,7 @@ fn_info_config_teamspeak3(){
|
|
|
queryport="10011"
|
|
queryport="10011"
|
|
|
fileport="30033"
|
|
fileport="30033"
|
|
|
else
|
|
else
|
|
|
- dbplugin=$(grep "dbplugin=" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/dbplugin=//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ dbplugin=$(grep "dbplugin=" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/dbplugin=//g' | tr -d '=\";,:' | xargs -0)
|
|
|
port=$(grep "default_voice_port" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
port=$(grep "default_voice_port" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
|
queryport=$(grep "query_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
queryport=$(grep "query_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
fileport=$(grep "filetransfer_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
fileport=$(grep "filetransfer_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
@@ -284,7 +284,7 @@ fn_info_config_teamspeak3(){
|
|
|
fileport=${fileport:-"30033"}
|
|
fileport=${fileport:-"30033"}
|
|
|
|
|
|
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
|
- ipconfigcheck=$(grep "voice_ip" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/voice_ip//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ ipconfigcheck=$(grep "voice_ip" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/voice_ip//g' | tr -d '=\";,:' | xargs -0)
|
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
|
ip="${ipconfigcheck}"
|
|
ip="${ipconfigcheck}"
|
|
|
fi
|
|
fi
|
|
@@ -297,7 +297,7 @@ fn_info_config_mumble(){
|
|
|
queryport="${port}"
|
|
queryport="${port}"
|
|
|
servername="Mumble"
|
|
servername="Mumble"
|
|
|
else
|
|
else
|
|
|
- port=$(grep "port" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^;/d' -e 's/port//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ port=$(grep "port" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^;/d' -e 's/port//g' | tr -d '=\";,:' | xargs -0)
|
|
|
queryport="${port}"
|
|
queryport="${port}"
|
|
|
|
|
|
|
|
# Not Set
|
|
# Not Set
|
|
@@ -306,7 +306,7 @@ fn_info_config_mumble(){
|
|
|
servername="Mumble Port ${port}"
|
|
servername="Mumble Port ${port}"
|
|
|
|
|
|
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
# check if the ip exists in the config file. Failing this will fall back to the default.
|
|
|
- ipconfigcheck=$(cat "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^;/d' -e 's/voice_ip//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ ipconfigcheck=$(cat "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^;/d' -e 's/voice_ip//g' | tr -d '=\";,:' | xargs -0)
|
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
if [ -n "${ipconfigcheck}" ]; then
|
|
|
ip="${ipconfigcheck}"
|
|
ip="${ipconfigcheck}"
|
|
|
fi
|
|
fi
|
|
@@ -321,9 +321,9 @@ fn_info_config_teeworlds(){
|
|
|
port="8303"
|
|
port="8303"
|
|
|
slots="12"
|
|
slots="12"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "sv_name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/^sv_name//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^password" | sed -e '/^#/d' -e 's/^password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- rconpassword=$(grep "sv_rcon_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/^sv_rcon_password//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "sv_name" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/^sv_name//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^password" | sed -e '/^#/d' -e 's/^password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ rconpassword=$(grep "sv_rcon_password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/^sv_rcon_password//g' | tr -d '=\";,:' | xargs -0)
|
|
|
port=$(grep "sv_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
port=$(grep "sv_port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
slots=$(grep "sv_max_clients" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "sv_max_clients" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
|
|
|
|
@@ -343,9 +343,9 @@ fn_info_config_terraria(){
|
|
|
gameworld="${unavailable}"
|
|
gameworld="${unavailable}"
|
|
|
slots="${zero}"
|
|
slots="${zero}"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "worldname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/worldname//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "worldname" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/worldname//g' | tr -d '=\";,:' | xargs -0)
|
|
|
port=$(grep "port" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
port=$(grep "port" "${servercfgfullpath}" | tr -cd '[:digit:]')
|
|
|
- gameworld=$(grep "world=" "${servercfgfullpath}" | grep -v "#" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/world=//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ gameworld=$(grep "world=" "${servercfgfullpath}" | grep -v "#" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/world=//g' | tr -d '=\";,:' | xargs -0)
|
|
|
slots=$(grep "maxplayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
slots=$(grep "maxplayers" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
|
|
|
|
|
# Not Set
|
|
# Not Set
|
|
@@ -368,18 +368,18 @@ fn_info_config_unreal(){
|
|
|
webadminuser="${unavailable}"
|
|
webadminuser="${unavailable}"
|
|
|
webadminpass="${unavailable}"
|
|
webadminpass="${unavailable}"
|
|
|
else
|
|
else
|
|
|
- servername=$(grep "ServerName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/ServerName//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- serverpassword=$(grep "GamePassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/GamePassword//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- adminpassword=$(grep "AdminPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminPassword//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ servername=$(grep "ServerName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/ServerName//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ serverpassword=$(grep "GamePassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/GamePassword//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ adminpassword=$(grep "AdminPassword" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminPassword//g' | tr -d '=\";,:' | xargs -0)
|
|
|
port=$(grep "Port" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^Port" | grep -v "#" | tr -cd '[:digit:]')
|
|
port=$(grep "Port" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' | grep "^Port" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
gsqueryport=$(grep "OldQueryPortNumber" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
gsqueryport=$(grep "OldQueryPortNumber" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
- webadminenabled=$(grep "bEnabled" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/bEnabled//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ webadminenabled=$(grep "bEnabled" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/bEnabled//g' | tr -d '=\";,:' | xargs -0)
|
|
|
webadminport=$(grep "ListenPort" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
webadminport=$(grep "ListenPort" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]')
|
|
|
if [ "${engine}" == "unreal" ]; then
|
|
if [ "${engine}" == "unreal" ]; then
|
|
|
- webadminuser=$(grep "AdminUsername" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminUsername//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
- webadminpass=$(grep "UTServerAdmin.UTServerAdmin" "${servercfgfullpath}" -A 4 | grep "AdminPassword" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminPassword//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ webadminuser=$(grep "AdminUsername" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminUsername//g' | tr -d '=\";,:' | xargs -0)
|
|
|
|
|
+ webadminpass=$(grep "UTServerAdmin.UTServerAdmin" "${servercfgfullpath}" -A 4 | grep "AdminPassword" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminPassword//g' | tr -d '=\";,:' | xargs -0)
|
|
|
else
|
|
else
|
|
|
- webadminuser=$(grep "AdminName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminName//g' | tr -d '=\";,:' | xargs)
|
|
|
|
|
|
|
+ webadminuser=$(grep "AdminName" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/AdminName//g' | tr -d '=\";,:' | xargs -0)
|
|
|
webadminpass="${adminpassword}"
|
|
webadminpass="${adminpassword}"
|
|
|
fi
|
|
fi
|
|
|
|
|
|