diff --git a/lgsm/functions/info_config.sh b/lgsm/functions/info_config.sh index e092c127b..547eb7c47 100644 --- a/lgsm/functions/info_config.sh +++ b/lgsm/functions/info_config.sh @@ -605,6 +605,7 @@ fn_info_config_sdtd(){ fn_info_config_mta(){ if [ ! -f "${servercfgfullpath}" ]; then + ip="${zero}" port="${unavailable}" httpport="${unavailable}" ase="${unavailable}" @@ -612,6 +613,7 @@ fn_info_config_mta(){ serverpassword="${unavailable}" maxplayers="${zero}" else + ip=$(grep -m 1 "serverip" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's///g' | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//' | cut -f1 -d "<" | tr -cd '[:digit:]') port=$(grep -m 1 "serverport" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's///g' | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//' | cut -f1 -d "<" | tr -cd '[:digit:]') httpport=$(grep -m 1 "httpport" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's///g' | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//' | cut -f1 -d "<" | tr -cd '[:digit:]') ase=$(grep -m 1 "ase" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^\//d' -e 's///g' | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//' | cut -f1 -d "<" | tr -cd '[:digit:]')