Browse Source

Merge branch 'release/21.5.0'

pull/3752/head v21.5.0
Daniel Gibbs 3 years ago
parent
commit
3456c92a1e
  1. 2
      lgsm/config-default/config-lgsm/arkserver/_default.cfg
  2. 180
      lgsm/config-default/config-lgsm/cdserver/_default.cfg
  3. 2
      lgsm/config-default/config-lgsm/colserver/_default.cfg
  4. 202
      lgsm/config-default/config-lgsm/dayzserver/_default.cfg
  5. 2
      lgsm/config-default/config-lgsm/dodrserver/_default.cfg
  6. 2
      lgsm/config-default/config-lgsm/pstbsserver/_default.cfg
  7. 2
      lgsm/config-default/config-lgsm/pzserver/_default.cfg
  8. 2
      lgsm/config-default/config-lgsm/sfserver/_default.cfg
  9. 2
      lgsm/config-default/config-lgsm/squadserver/_default.cfg
  10. 2
      lgsm/config-default/config-lgsm/stnserver/_default.cfg
  11. 187
      lgsm/config-default/config-lgsm/tiserver/_default.cfg
  12. 2
      lgsm/config-default/config-lgsm/vhserver/_default.cfg
  13. 3
      lgsm/data/almalinux-8.csv
  14. 3
      lgsm/data/centos-7.csv
  15. 3
      lgsm/data/centos-8.csv
  16. 5
      lgsm/data/debian-10.csv
  17. 11
      lgsm/data/debian-11.csv
  18. 5
      lgsm/data/debian-9.csv
  19. 3
      lgsm/data/rhel-7.csv
  20. 3
      lgsm/data/rhel-8.csv
  21. 3
      lgsm/data/rocky-8.csv
  22. 3
      lgsm/data/serverlist.csv
  23. 5
      lgsm/data/ubuntu-16.04.csv
  24. 5
      lgsm/data/ubuntu-18.04.csv
  25. 11
      lgsm/data/ubuntu-20.04.csv
  26. 11
      lgsm/data/ubuntu-21.04.csv
  27. 124
      lgsm/data/ubuntu-21.10.csv
  28. 124
      lgsm/data/ubuntu-22.04.csv
  29. 16
      lgsm/functions/check_deps.sh
  30. 18
      lgsm/functions/core_dl.sh
  31. 2
      lgsm/functions/core_functions.sh
  32. 61
      lgsm/functions/fix_steamcmd.sh
  33. 2
      lgsm/functions/fix_vh.sh
  34. 21
      lgsm/functions/info_distro.sh
  35. 66
      lgsm/functions/info_game.sh
  36. 37
      lgsm/functions/info_messages.sh
  37. 22
      lgsm/functions/install_config.sh
  38. 2
      lgsm/functions/install_server_files.sh
  39. 44
      lgsm/functions/mods_core.sh
  40. 2
      linuxgsm.sh
  41. 2
      tests/tests_fctrserver.sh
  42. 2
      tests/tests_jc2server.sh
  43. 2
      tests/tests_mcserver.sh
  44. 2
      tests/tests_ts3server.sh

2
lgsm/config-default/config-lgsm/arkserver/_default.cfg

@ -13,7 +13,7 @@ ip="0.0.0.0"
port="7777"
queryport="27015"
rconport="27020"
# Default Map: TheIsland, Ragnarok, CrystalIsles, Aberration_P, ScorchedEarth_P, TheCenter, Extinction, Valguero_P, Genesis
# Default Map: TheIsland, Ragnarok, CrystalIsles, Aberration_P, ScorchedEarth_P, TheCenter, Extinction, Valguero_P, Genesis, Gen2
defaultmap="TheIsland"
altsavedirectoryname="${defaultmap}"
maxplayers="70"

180
lgsm/config-default/config-lgsm/cdserver/_default.cfg

@ -0,0 +1,180 @@
##################################
######## Default Settings ########
##################################
# DO NOT EDIT, ANY CHANGES WILL BE OVERWRITTEN!
# Copy settings from here and use them in either:
# common.cfg - applies settings to every instance.
# [instance].cfg - applies settings to a specific instance.
#### Game Server Settings ####
## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
startparameters="-batchmode -nographics"
#### LinuxGSM Settings ####
## LinuxGSM Stats
# Send useful stats to LinuxGSM developers.
# https://docs.linuxgsm.com/configuration/linuxgsm-stats
# (on|off)
stats="off"
## Notification Alerts
# (on|off)
# Display IP | https://docs.linuxgsm.com/alerts#display-ip
displayip=""
# More info | https://docs.linuxgsm.com/alerts#more-info
postalert="off"
# Discord Alerts | https://docs.linuxgsm.com/alerts/discord
discordalert="off"
discordwebhook="webhook"
# Email Alerts | https://docs.linuxgsm.com/alerts/email
emailalert="off"
email="[email protected]"
emailfrom=""
# Gotify Alerts | https://docs.linuxgsm.com/alerts/gotify
gotifyalert="off"
gotifytoken="token"
gotifywebhook="webhook"
# IFTTT Alerts | https://docs.linuxgsm.com/alerts/ifttt
iftttalert="off"
ifttttoken="accesstoken"
iftttevent="linuxgsm_alert"
# Mailgun Email Alerts | https://docs.linuxgsm.com/alerts/mailgun
mailgunalert="off"
mailgunapiregion="us"
mailguntoken="accesstoken"
mailgundomain="example.com"
mailgunemailfrom="[email protected]"
mailgunemail="[email protected]"
# Pushbullet Alerts | https://docs.linuxgsm.com/alerts/pushbullet
pushbulletalert="off"
pushbullettoken="accesstoken"
channeltag=""
# Pushover Alerts | https://docs.linuxgsm.com/alerts/pushover
pushoveralert="off"
pushovertoken="accesstoken"
pushoveruserkey="userkey"
# Rocket.Chat Alerts | https://docs.linuxgsm.com/alerts/rocket.chat
rocketchatalert="off"
rocketchatwebhook="webhook"
rocketchattoken=""
# Slack Alerts | https://docs.linuxgsm.com/alerts/slack
slackalert="off"
slackwebhook="webhook"
# Telegram Alerts | https://docs.linuxgsm.com/alerts/telegram
# You can add a custom cURL string eg proxy (useful in Russia) in "curlcustomstring".
# For example "--socks5 ipaddr:port" for socks5 proxy see more in "curl --help".
telegramapi="api.telegram.org"
telegramalert="off"
telegramtoken="accesstoken"
telegramchatid=""
curlcustomstring=""
## Updating | https://docs.linuxgsm.com/commands/update
updateonstart="off"
## Backup | https://docs.linuxgsm.com/commands/backup
maxbackups="4"
maxbackupdays="30"
stoponbackup="on"
## Logging | https://docs.linuxgsm.com/features/logging
consolelogging="on"
logdays="7"
## Monitor | https://docs.linuxgsm.com/commands/monitor
# Query delay time
querydelay="1"
## ANSI Colors | https://docs.linuxgsm.com/features/ansi-colors
ansi="on"
#### Advanced Settings ####
## Message Display Time | https://docs.linuxgsm.com/features/message-display-time
sleeptime="0.5"
## SteamCMD Settings | https://docs.linuxgsm.com/steamcmd
# Server appid
appid="685100"
steamcmdforcewindows="no"
# SteamCMD Branch | https://docs.linuxgsm.com/steamcmd/branch
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill
# 2: CTRL+c
# 3: quit
# 4: quit 120s
# 5: stop
# 6: q
# 7: exit
# 8: 7 Days to Die
# 9: GoldSrc
# 10: Avorion
# 11: end
stopmode="2"
## Query mode
# 1: session only
# 2: gamedig (gsquery fallback)
# 3: gamedig
# 4: gsquery
# 5: tcp
querymode="1"
querytype=""
## Console type
consoleverbose="yes"
consoleinteract="no"
## Game Server Details
# Do not edit
gamename="Crafting Dead"
engine="unity3d"
glibc="2.15"
#### Directories ####
# Edit with care
## Game Server Directories
systemdir="${serverfiles}"
executabledir="${serverfiles}"
executable="./crafting_dead.x86_64"
servercfgdir="${systemdir}"
servercfg="properties.json"
servercfgdefault="properties.json"
servercfgfullpath="${servercfgdir}/${servercfg}"
## Backup Directory
backupdir="${lgsmdir}/backup"
## Logging Directories
logdir="${rootdir}/log"
gamelogdir="${systemdir}/logs"
lgsmlogdir="${logdir}/script"
consolelogdir="${logdir}/console"
lgsmlog="${lgsmlogdir}/${selfname}-script.log"
consolelog="${consolelogdir}/${selfname}-console.log"
alertlog="${lgsmlogdir}/${selfname}-alert.log"
postdetailslog="${lgsmlogdir}/${selfname}-postdetails.log"
## Logs Naming
lgsmlogdate="${lgsmlogdir}/${selfname}-script-$(date '+%Y-%m-%d-%H:%M:%S').log"
consolelogdate="${consolelogdir}/${selfname}-console-$(date '+%Y-%m-%d-%H:%M:%S').log"

2
lgsm/config-default/config-lgsm/colserver/_default.cfg

@ -116,7 +116,7 @@ steamcmdforcewindows="no"
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
steammaster="true"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill

202
lgsm/config-default/config-lgsm/dayzserver/_default.cfg

@ -0,0 +1,202 @@
##################################
######## Default Settings ########
##################################
# DO NOT EDIT, ANY CHANGES WILL BE OVERWRITTEN!
# Copy settings from here and use them in either:
# common.cfg - applies settings to every instance.
# [instance].cfg - applies settings to a specific instance.
#### Game Server Settings ####
## SteamCMD Login | https://docs.linuxgsm.com/steamcmd#steamcmd-login
# steamuser="username"
# steampass='password'
## Predefined Parameters | https://docs.linuxgsm.com/configuration/start-parameters
ip="0.0.0.0"
port="2302"
## DayZ Modules
# Add mods with relative paths:
# mods/@cf
# To load the "Community framework for DayZ SA" module found in the
# directory serverfiles/mods/@cf. Load several mods as:
# mods="mods/@cf\;mods/@dayz-expansion\;mods/@deerisle"
mods=""
## Server-side Mods
servermods=""
## Path to BattlEye
# Leave empty for default
bepath=""
## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
startparameters="-ip=${ip} -port=${port} -config=${servercfgfullpath} -mod=${mods} -servermod=${servermods} -bepath=${bepath} -limitFPS=60 -dologs -adminlog -freezeCheck"
#### LinuxGSM Settings ####
## LinuxGSM Stats
# Send useful stats to LinuxGSM developers.
# https://docs.linuxgsm.com/configuration/linuxgsm-stats
# (on|off)
stats="off"
## Notification Alerts
# (on|off)
# Display IP | https://docs.linuxgsm.com/alerts#display-ip
displayip=""
# More info | https://docs.linuxgsm.com/alerts#more-info
postalert="off"
# Discord Alerts | https://docs.linuxgsm.com/alerts/discord
discordalert="off"
discordwebhook="webhook"
# Email Alerts | https://docs.linuxgsm.com/alerts/email
emailalert="off"
email="[email protected]"
emailfrom=""
# Gotify Alerts | https://docs.linuxgsm.com/alerts/gotify
gotifyalert="off"
gotifytoken="token"
gotifywebhook="webhook"
# IFTTT Alerts | https://docs.linuxgsm.com/alerts/ifttt
iftttalert="off"
ifttttoken="accesstoken"
iftttevent="linuxgsm_alert"
# Mailgun Email Alerts | https://docs.linuxgsm.com/alerts/mailgun
mailgunalert="off"
mailgunapiregion="us"
mailguntoken="accesstoken"
mailgundomain="example.com"
mailgunemailfrom="[email protected]"
mailgunemail="[email protected]"
# Pushbullet Alerts | https://docs.linuxgsm.com/alerts/pushbullet
pushbulletalert="off"
pushbullettoken="accesstoken"
channeltag=""
# Pushover Alerts | https://docs.linuxgsm.com/alerts/pushover
pushoveralert="off"
pushovertoken="accesstoken"
pushoveruserkey="userkey"
# Rocket.Chat Alerts | https://docs.linuxgsm.com/alerts/rocket.chat
rocketchatalert="off"
rocketchatwebhook="webhook"
rocketchattoken=""
# Slack Alerts | https://docs.linuxgsm.com/alerts/slack
slackalert="off"
slackwebhook="webhook"
# Telegram Alerts | https://docs.linuxgsm.com/alerts/telegram
# You can add a custom cURL string eg proxy (useful in Russia) in "curlcustomstring".
# For example "--socks5 ipaddr:port" for socks5 proxy see more in "curl --help".
telegramapi="api.telegram.org"
telegramalert="off"
telegramtoken="accesstoken"
telegramchatid=""
curlcustomstring=""
## Updating | https://docs.linuxgsm.com/commands/update
updateonstart="off"
## Backup | https://docs.linuxgsm.com/commands/backup
maxbackups="4"
maxbackupdays="30"
stoponbackup="on"
## Logging | https://docs.linuxgsm.com/features/logging
consolelogging="on"
logdays="7"
## Monitor | https://docs.linuxgsm.com/commands/monitor
# Query delay time
querydelay="5"
## ANSI Colors | https://docs.linuxgsm.com/features/ansi-colors
ansi="on"
#### Advanced Settings ####
## Message Display Time | https://docs.linuxgsm.com/features/message-display-time
sleeptime="0.5"
## SteamCMD Settings | https://docs.linuxgsm.com/steamcmd
# Server appid
appid="1042420"
steamcmdforcewindows="no"
# SteamCMD Branch | https://docs.linuxgsm.com/steamcmd/branch
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill
# 2: CTRL+c
# 3: quit
# 4: quit 120s
# 5: stop
# 6: q
# 7: exit
# 8: 7 Days to Die
# 9: GoldSrc
# 10: Avorion
# 11: end
stopmode="2"
## Query mode
# 1: session only
# 2: gamedig (gsquery fallback)
# 3: gamedig
# 4: gsquery
# 5: tcp
querymode="2"
querytype="protocol-valve"
## Console type
consoleverbose="yes"
consoleinteract="no"
## Game Server Details
# Do not edit
gamename="DayZ"
engine="enfusion"
glibc="2.27"
#### Directories ####
# Edit with care
## Game Server Directories
systemdir="${serverfiles}"
executabledir="${serverfiles}"
executable="./DayZServer"
servercfgdir="${systemdir}/cfg"
servercfg="${selfname}.server.cfg"
servercfgdefault="server.cfg"
servercfgfullpath="${servercfgdir}/${servercfg}"
## Backup Directory
backupdir="${lgsmdir}/backup"
## Logging Directories
logdir="${rootdir}/log"
lgsmlogdir="${logdir}/script"
consolelogdir="${logdir}/console"
lgsmlog="${lgsmlogdir}/${selfname}-script.log"
consolelog="${consolelogdir}/${selfname}-console.log"
alertlog="${lgsmlogdir}/${selfname}-alert.log"
postdetailslog="${lgsmlogdir}/${selfname}-postdetails.log"
## Logs Naming
lgsmlogdate="${lgsmlogdir}/${selfname}-script-$(date '+%Y-%m-%d-%H:%M:%S').log"
consolelogdate="${consolelogdir}/${selfname}-console-$(date '+%Y-%m-%d-%H:%M:%S').log"

2
lgsm/config-default/config-lgsm/dodrserver/_default.cfg

@ -121,7 +121,7 @@ steamcmdforcewindows="no"
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
steammaster="true"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill

2
lgsm/config-default/config-lgsm/pstbsserver/_default.cfg

@ -124,7 +124,7 @@ steamcmdforcewindows="no"
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
steammaster="true"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill

2
lgsm/config-default/config-lgsm/pzserver/_default.cfg

@ -13,7 +13,7 @@ ip="0.0.0.0"
adminpassword="CHANGE_ME"
## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
startparameters="-ip ${ip} -adminpassword \"${adminpassword}\" -servername ${selfname}"
startparameters="--ip ${ip} -adminpassword \"${adminpassword}\" -servername ${selfname}"
#### LinuxGSM Settings ####

2
lgsm/config-default/config-lgsm/sfserver/_default.cfg

@ -15,7 +15,7 @@ beaconport="15000"
port="7777"
## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
startparameters="FactoryGame -ServerQueryPort=${queryport} -BeaconPort=${beaconport} -Port=${port} -log -unattended"
startparameters="FactoryGame -multihome=${ip} -ServerQueryPort=${queryport} -BeaconPort=${beaconport} -Port=${port} -log -unattended"
#### LinuxGSM Settings ####

2
lgsm/config-default/config-lgsm/squadserver/_default.cfg

@ -120,7 +120,7 @@ steamcmdforcewindows="no"
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
steammaster="true"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill

2
lgsm/config-default/config-lgsm/stnserver/_default.cfg

@ -119,7 +119,7 @@ steamcmdforcewindows="no"
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
steammaster="true"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill

187
lgsm/config-default/config-lgsm/tiserver/_default.cfg

@ -0,0 +1,187 @@
##################################
######## Default Settings ########
##################################
# DO NOT EDIT, ANY CHANGES WILL BE OVERWRITTEN!
# Copy settings from here and use them in either:
# common.cfg - applies settings to every instance.
# [instance].cfg - applies settings to a specific instance.
#### Game Server Settings ####
## Predefined Parameters | https://docs.linuxgsm.com/configuration/start-parameters
ip="0.0.0.0"
port="7777"
queryport="27015"
# Possible maps, see: https://isle.fandom.com/wiki/The_Isle_Server_Settings_and_Configuration#Optional_Maps
map=""
## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
startparameters="${map} -MultiHome=${ip} -Port=${port} -QueryPort=${queryport} -log"
#### LinuxGSM Settings ####
## LinuxGSM Stats
# Send useful stats to LinuxGSM developers.
# https://docs.linuxgsm.com/configuration/linuxgsm-stats
# (on|off)
stats="off"
## Notification Alerts
# (on|off)
# Display IP | https://docs.linuxgsm.com/alerts#display-ip
displayip=""
# More info | https://docs.linuxgsm.com/alerts#more-info
postalert="off"
# Discord Alerts | https://docs.linuxgsm.com/alerts/discord
discordalert="off"
discordwebhook="webhook"
# Email Alerts | https://docs.linuxgsm.com/alerts/email
emailalert="off"
email="[email protected]"
emailfrom=""
# Gotify Alerts | https://docs.linuxgsm.com/alerts/gotify
gotifyalert="off"
gotifytoken="token"
gotifywebhook="webhook"
# IFTTT Alerts | https://docs.linuxgsm.com/alerts/ifttt
iftttalert="off"
ifttttoken="accesstoken"
iftttevent="linuxgsm_alert"
# Mailgun Email Alerts | https://docs.linuxgsm.com/alerts/mailgun
mailgunalert="off"
mailgunapiregion="us"
mailguntoken="accesstoken"
mailgundomain="example.com"
mailgunemailfrom="[email protected]"
mailgunemail="[email protected]"
# Pushbullet Alerts | https://docs.linuxgsm.com/alerts/pushbullet
pushbulletalert="off"
pushbullettoken="accesstoken"
channeltag=""
# Pushover Alerts | https://docs.linuxgsm.com/alerts/pushover
pushoveralert="off"
pushovertoken="accesstoken"
pushoveruserkey="userkey"
# Rocket.Chat Alerts | https://docs.linuxgsm.com/alerts/rocket.chat
rocketchatalert="off"
rocketchatwebhook="webhook"
rocketchattoken=""
# Slack Alerts | https://docs.linuxgsm.com/alerts/slack
slackalert="off"
slackwebhook="webhook"
# Telegram Alerts | https://docs.linuxgsm.com/alerts/telegram
# You can add a custom cURL string eg proxy (useful in Russia) in "curlcustomstring".
# For example "--socks5 ipaddr:port" for socks5 proxy see more in "curl --help".
telegramapi="api.telegram.org"
telegramalert="off"
telegramtoken="accesstoken"
telegramchatid=""
curlcustomstring=""
## Updating | https://docs.linuxgsm.com/commands/update
updateonstart="off"
## Backup | https://docs.linuxgsm.com/commands/backup
maxbackups="4"
maxbackupdays="30"
stoponbackup="on"
## Logging | https://docs.linuxgsm.com/features/logging
consolelogging="on"
logdays="7"
## Monitor | https://docs.linuxgsm.com/commands/monitor
# Query delay time
querydelay="1"
## ANSI Colors | https://docs.linuxgsm.com/features/ansi-colors
ansi="on"
#### Advanced Settings ####
## Message Display Time | https://docs.linuxgsm.com/features/message-display-time
sleeptime="0.5"
## SteamCMD Settings | https://docs.linuxgsm.com/steamcmd
# Server appid
appid="412680"
steamcmdforcewindows="no"
# SteamCMD Branch | https://docs.linuxgsm.com/steamcmd/branch
branch="evrima"
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="true"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill
# 2: CTRL+c
# 3: quit
# 4: quit 120s
# 5: stop
# 6: q
# 7: exit
# 8: 7 Days to Die
# 9: GoldSrc
# 10: Avorion
# 11: end
stopmode="2"
## Query mode
# 1: session only
# 2: gamedig (gsquery fallback)
# 3: gamedig
# 4: gsquery
# 5: tcp
querymode="2"
querytype="protocol-valve"
## Console type
consoleverbose="yes"
consoleinteract="no"
## Game Server Details
# Do not edit
gamename="The Isle"
engine="unreal4"
glibc="2.17"
#### Directories ####
# Edit with care
## Game Server Directories
systemdir="${serverfiles}/TheIsle"
executabledir="${systemdir}/Binaries/Linux"
executable="./TheIsleServer-Linux-Shipping"
servercfgdir="${systemdir}/Saved/Config/LinuxServer"
servercfg="Game.ini"
servercfgdefault="Game.ini"
servercfgfullpath="${servercfgdir}/${servercfg}"
## Backup Directory
backupdir="${lgsmdir}/backup"
## Logging Directories
logdir="${rootdir}/log"
gamelogdir="${systemdir}/Saved/Logs"
lgsmlogdir="${logdir}/script"
consolelogdir="${logdir}/console"
lgsmlog="${lgsmlogdir}/${selfname}-script.log"
consolelog="${consolelogdir}/${selfname}-console.log"
alertlog="${lgsmlogdir}/${selfname}-alert.log"
postdetailslog="${lgsmlogdir}/${selfname}-postdetails.log"
## Logs Naming
lgsmlogdate="${lgsmlogdir}/${selfname}-script-$(date '+%Y-%m-%d-%H:%M:%S').log"
consolelogdate="${consolelogdir}/${selfname}-console-$(date '+%Y-%m-%d-%H:%M:%S').log"

2
lgsm/config-default/config-lgsm/vhserver/_default.cfg

@ -124,7 +124,7 @@ steamcmdforcewindows="no"
branch=""
betapassword=""
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
steammaster="false"
steammaster="true"
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
# 1: tmux kill

3
lgsm/data/almalinux-8.csv

@ -17,6 +17,7 @@ bs
bt,libicu
bt1944
cc
cd
cmw
cod,compat-libstdc++-33.i686
cod2,compat-libstdc++-33.i686
@ -29,6 +30,7 @@ cscz
csgo
css,ncurses-libs.i686
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven
terraria
tf2,libcurl.i686
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

3
lgsm/data/centos-7.csv

@ -17,6 +17,7 @@ bs
bt,libicu
bt1944
cc
cd
cmw
cod,compat-libstdc++-33.i686
cod2,compat-libstdc++-33.i686
@ -29,6 +30,7 @@ cscz
csgo
css,ncurses-libs.i686
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven
terraria
tf2,libcurl.i686
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

3
lgsm/data/centos-8.csv

@ -17,6 +17,7 @@ bs
bt,libicu
bt1944
cc
cd
cmw
cod,compat-libstdc++-33.i686
cod2,compat-libstdc++-33.i686
@ -29,6 +30,7 @@ cscz
csgo
css,ncurses-libs.i686
dab
dayz
dmc
dod
dodr
@ -102,6 +104,7 @@ sven
terraria
tf2,libcurl.i686
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

5
lgsm/data/debian-10.csv

@ -1,4 +1,4 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
@ -17,6 +17,7 @@ bs
bt,libicu-dev
bt1944
cc
cd
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
@ -29,6 +30,7 @@ cscz
csgo
css,libtinfo5:i386
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven,libssl1.1:i386,zlib1g:i386
terraria
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

11
lgsm/data/debian-11.csv

@ -1,4 +1,4 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc-s1,lib32stdc++6,netcat,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc-s1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc-s1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
@ -17,6 +17,7 @@ bs
bt,libicu-dev
bt1944
cc
cd
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
@ -29,6 +30,7 @@ cscz
csgo
css,libtinfo5:i386
dab
dayz
dmc
dod
dodr
@ -57,7 +59,7 @@ kf2
lo
l4d
l4d2
mc,openjdk-16-jre
mc,openjdk-17-jre
mcb
mh
mohaa,libstdc++5:i386
@ -72,7 +74,7 @@ ns2c,speex:i386,libtbb2
onset,libmariadbclient-dev
opfor
pc
pmc,openjdk-16-jre
pmc,openjdk-17-jre
pstbs,libgconf-2-4
pvkii
pvr,libc++1
@ -103,6 +105,7 @@ sven,libssl1.1:i386,zlib1g:i386
terraria
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu
@ -117,7 +120,7 @@ vs
vints,mono-complete
wet
wf
wmc,openjdk-16-jre
wmc,openjdk-17-jre
wurm,xvfb
zmr,libtinfo5:i386
zps,libtinfo5:i386

Can't render this file because it has a wrong number of fields in line 2.

5
lgsm/data/debian-9.csv

@ -1,4 +1,4 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
@ -17,6 +17,7 @@ bs
bt,libicu-dev
bt1944
cc
cd
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
@ -29,6 +30,7 @@ cscz
csgo
css,libtinfo5:i386
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven,libssl1.1:i386,zlib1g:i386
terraria
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

3
lgsm/data/rhel-7.csv

@ -17,6 +17,7 @@ bs
bt,libicu
bt1944
cc
cd
cmw
cod,compat-libstdc++-33.i686
cod2,compat-libstdc++-33.i686
@ -29,6 +30,7 @@ cscz
csgo
css,ncurses-libs.i686
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven
terraria
tf2,libcurl.i686
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

3
lgsm/data/rhel-8.csv

@ -17,6 +17,7 @@ bs
bt,libicu
bt1944
cc
cd
cmw
cod,compat-libstdc++-33.i686
cod2,compat-libstdc++-33.i686
@ -29,6 +30,7 @@ cscz
csgo
css,ncurses-libs.i686
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven
terraria
tf2,libcurl.i686
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

3
lgsm/data/rocky-8.csv

@ -17,6 +17,7 @@ bs
bt,libicu
bt1944
cc
cd
cmw
cod,compat-libstdc++-33.i686
cod2,compat-libstdc++-33.i686
@ -29,6 +30,7 @@ cscz
csgo
css,ncurses-libs.i686
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven
terraria
tf2,libcurl.i686
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

3
lgsm/data/serverlist.csv

@ -15,6 +15,7 @@ bs,bsserver,Blade Symphony
bt,btserver,Barotrauma
bt1944,bt1944server,Battalion 1944
cc,ccserver,Codename CURE
cd,cdserver,Crafting Dead
cmw,cmwserver,Chivalry: Medieval Warfare
cod,codserver,Call of Duty
cod2,cod2server,Call of Duty 2
@ -27,6 +28,7 @@ cscz,csczserver,Counter-Strike: Condition Zero
csgo,csgoserver,Counter-Strike: Global Offensive
css,cssserver,Counter-Strike: Source
dab,dabserver,Double Action: Boogaloo
dayz,dayzserver,DayZ
dmc,dmcserver,Deathmatch Classic
dod,dodserver,Day of Defeat
dodr,dodrserver,Day of Dragons
@ -101,6 +103,7 @@ sven,svenserver,Sven Co-op
terraria,terrariaserver,Terraria
tf2,tf2server,Team Fortress 2
tfc,tfcserver,Team Fortress Classic
ti,tiserver,The Isle
ts,tsserver,The Specialists
ts3,ts3server,Teamspeak 3
tu,tuserver,Tower Unite

1 ac acserver Assetto Corsa
15 bt btserver Barotrauma
16 bt1944 bt1944server Battalion 1944
17 cc ccserver Codename CURE
18 cd cdserver Crafting Dead
19 cmw cmwserver Chivalry: Medieval Warfare
20 cod codserver Call of Duty
21 cod2 cod2server Call of Duty 2
28 csgo csgoserver Counter-Strike: Global Offensive
29 css cssserver Counter-Strike: Source
30 dab dabserver Double Action: Boogaloo
31 dayz dayzserver DayZ
32 dmc dmcserver Deathmatch Classic
33 dod dodserver Day of Defeat
34 dodr dodrserver Day of Dragons

5
lgsm/data/ubuntu-16.04.csv

@ -1,4 +1,4 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
@ -17,6 +17,7 @@ bs
bt,libicu-dev
bt1944
cc
cd
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
@ -29,6 +30,7 @@ cscz
csgo
css,libtinfo5:i386
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven,libssl1.1:i386,zlib1g:i386
terraria
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

5
lgsm/data/ubuntu-18.04.csv

@ -1,4 +1,4 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
@ -17,6 +17,7 @@ bs
bt,libicu-dev
bt1944
cc
cd
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
@ -29,6 +30,7 @@ cscz
csgo
css,libtinfo5:i386
dab
dayz
dmc
dod
dodr
@ -103,6 +105,7 @@ sven,libssl1.1:i386,zlib1g:i386
terraria
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu

Can't render this file because it has a wrong number of fields in line 2.

11
lgsm/data/ubuntu-20.04.csv

@ -1,4 +1,4 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
@ -17,6 +17,7 @@ bs
bt,libicu-dev
bt1944
cc
cd
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
@ -29,6 +30,7 @@ cscz
csgo
css,libtinfo5:i386
dab
dayz
dmc
dod
dodr
@ -57,7 +59,7 @@ kf2
lo
l4d
l4d2
mc,openjdk-16-jre
mc,openjdk-17-jre
mcb
mh
mohaa,libstdc++5:i386
@ -72,7 +74,7 @@ ns2c,speex:i386,libtbb2
onset,libmariadbclient-dev
opfor
pc
pmc,openjdk-16-jre
pmc,openjdk-17-jre
pstbs,libgconf-2-4
pvkii
pvr,libc++1
@ -103,6 +105,7 @@ sven,libssl1.1:i386,zlib1g:i386
terraria
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu
@ -117,7 +120,7 @@ vs
vints,mono-complete
wet
wf
wmc,openjdk-16-jre
wmc,openjdk-17-jre
wurm,xvfb
zmr,libtinfo5:i386
zps,libtinfo5:i386

Can't render this file because it has a wrong number of fields in line 2.

11
lgsm/data/ubuntu-21.04.csv

@ -1,4 +1,4 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc-s1,lib32stdc++6,netcat,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc-s1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc-s1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
@ -17,6 +17,7 @@ bs
bt,libicu-dev
bt1944
cc
cd
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
@ -29,6 +30,7 @@ cscz
csgo
css,libtinfo5:i386
dab
dayz
dmc
dod
dodr
@ -57,7 +59,7 @@ kf2
lo
l4d
l4d2
mc,openjdk-16-jre
mc,openjdk-17-jre
mcb
mh
mohaa,libstdc++5:i386
@ -72,7 +74,7 @@ ns2c,speex:i386,libtbb2
onset,libmariadbclient-dev
opfor
pc
pmc,openjdk-16-jre
pmc,openjdk-17-jre
pstbs,libgconf-2-4
pvkii
pvr,libc++1
@ -103,6 +105,7 @@ sven,libssl1.1:i386,zlib1g:i386
terraria,libsdl
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu
@ -117,7 +120,7 @@ vs
vints,mono-complete
wet
wf
wmc,openjdk-16-jre
wmc,openjdk-17-jre
wurm,xvfb
zmr,libtinfo5:i386
zps,libtinfo5:i386

Can't render this file because it has a wrong number of fields in line 2.

124
lgsm/data/ubuntu-21.10.csv

@ -0,0 +1,124 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc-s1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc-s1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
ahl2
ark
arma3
av
bb
bb2,libcurl4-gnutls-dev:i386
bd
bf1942,libncurses5:i386,libtinfo5:i386
bfv,libncurses5:i386,libstdc++5:i386
bmdm,libncurses5:i386
bo
bs
bt,libicu-dev
bt1944
cc
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
cod4
coduo,libstdc++5:i386
codwaw
col
cs
cscz
csgo
css,libtinfo5:i386
dab
dmc
dod
dodr
dods
doi
dst,libcurl4-gnutls-dev:i386
dys
eco,libgdiplus
em
etl
fctr
fof
gmod,libtinfo5:i386
hl2dm
hldm
hldms
hw,lib32z1
ins
inss
ios
jc2
jc3
jk2
kf
kf2
lo
l4d
l4d2
mc,openjdk-17-jre
mcb
mh
mohaa,libstdc++5:i386
mom
mta,libncursesw5
mumble
nd
nmrih,libtinfo5:i386
ns
ns2,speex,libtbb2
ns2c,speex:i386,libtbb2
onset,libmariadbclient-dev
opfor
pc
pmc,openjdk-17-jre
pstbs,libgconf-2-4
pvkii
pvr,libc++1
pz,openjdk-16-jre,rng-tools
q2
q3
ql
qw
ricochet
ro
rtcw
rust,lib32z1
rw,openjdk-16-jre
samp
sb
sbots
scpsl,mono-complete
scpslsm,mono-complete
sdtd,telnet,expect
sfc,libtinfo5:i386
sf
sof2
sol
squad
st
stn
sven,libssl1.1:i386,zlib1g:i386
terraria,libsdl
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu
tw
unt
ut
ut2k4
ut3
ut99
vh,libc6-dev
vs
vints,mono-complete
wet
wf
wmc,openjdk-17-jre
wurm,xvfb
zmr,libtinfo5:i386
zps,libtinfo5:i386
Can't render this file because it has a wrong number of fields in line 2.

124
lgsm/data/ubuntu-22.04.csv

@ -0,0 +1,124 @@
all,bc,binutils,bsdmainutils,bzip2,ca-certificates,cpio,curl,file,gzip,hostname,jq,lib32gcc-s1,lib32stdc++6,netcat,python3,tar,tmux,unzip,util-linux,wget,xz-utils
steamcmd,lib32gcc-s1,lib32stdc++6,libsdl2-2.0-0:i386,steamcmd
ac
ahl
ahl2
ark
arma3
av
bb
bb2,libcurl4-gnutls-dev:i386
bd
bf1942,libncurses5:i386,libtinfo5:i386
bfv,libncurses5:i386,libstdc++5:i386
bmdm,libncurses5:i386
bo
bs
bt,libicu-dev
bt1944
cc
cmw
cod,libstdc++5:i386
cod2,libstdc++5:i386
cod4
coduo,libstdc++5:i386
codwaw
col
cs
cscz
csgo
css,libtinfo5:i386
dab
dmc
dod
dodr
dods
doi
dst,libcurl4-gnutls-dev:i386
dys
eco,libgdiplus
em
etl
fctr
fof
gmod,libtinfo5:i386
hl2dm
hldm
hldms
hw,lib32z1
ins
inss
ios
jc2
jc3
jk2
kf
kf2
lo
l4d
l4d2
mc,openjdk-17-jre
mcb
mh
mohaa,libstdc++5:i386
mom
mta,libncursesw5
mumble
nd
nmrih,libtinfo5:i386
ns
ns2,speex,libtbb2
ns2c,speex:i386,libtbb2
onset,libmariadbclient-dev
opfor
pc
pmc,openjdk-17-jre
pstbs,libgconf-2-4
pvkii
pvr,libc++1
pz,openjdk-16-jre,rng-tools
q2
q3
ql
qw
ricochet
ro
rtcw
rust,lib32z1
rw,openjdk-16-jre
samp
sb
sbots
scpsl,mono-complete
scpslsm,mono-complete
sdtd,telnet,expect
sfc,libtinfo5:i386
sf
sof2
sol
squad
st
stn
sven,libssl1.1:i386,zlib1g:i386
terraria,libsdl
tf2,libcurl4-gnutls-dev:i386
tfc
ti
ts
ts3
tu
tw
unt
ut
ut2k4
ut3
ut99
vh,libc6-dev
vs
vints,mono-complete
wet
wf
wmc,openjdk-17-jre
wurm,xvfb
zmr,libtinfo5:i386
zps,libtinfo5:i386
Can't render this file because it has a wrong number of fields in line 2.

16
lgsm/functions/check_deps.sh

@ -225,7 +225,13 @@ fn_deps_detector(){
## Check.
# SteamCMD: Will be removed from required array if no appid is present or non-free repo is not available.
# This will cause SteamCMD to be installed using tar.
if [ "${deptocheck}" == "steamcmd" ]&&[ -z "${appid}" ]||[ "${deptocheck}" == "steamcmd" ]&&[ "${distroid}" == "debian" ]&& ! grep -qE "^deb .*non-free" /etc/apt/sources.list; then
if [ "${deptocheck}" == "libsdl2-2.0-0:i386" ]&&[ -z "${appid}" ]; then
array_deps_required=( "${array_deps_required[@]/libsdl2-2.0-0:i386}" )
steamcmdstatus=1
elif [ "${deptocheck}" == "steamcmd" ]&&[ -z "${appid}" ]; then
array_deps_required=( "${array_deps_required[@]/steamcmd}" )
steamcmdstatus=1
elif [ "${deptocheck}" == "steamcmd" ]&&[ "${distroid}" == "debian" ]&& ! grep -qE "^deb .*non-free" /etc/apt/sources.list; then
array_deps_required=( "${array_deps_required[@]/steamcmd}" )
steamcmdstatus=1
# Java: Added for users using Oracle JRE to bypass check.
@ -310,6 +316,14 @@ if [ "${commandname}" == "INSTALL" ]; then
fi
fi
# Will warn user if their distro is no longer supported by the vendor.
if [ -n "${distrosupport}" ]; then
if [ "${distrosupport}" == "unsupported" ]; then
fn_print_warning_nl "${distroname} is no longer supported by the vendor. Upgrading is recommended."
fn_script_log_warn "${distroname} is no longer supported by the vendor. Upgrading is recommended."
fi
fi
info_distro.sh
if [ ! -f "${tmpdir}/dependency-no-check.tmp" ]&&[ ! -f "${datadir}/${distroid}-${distroversioncsv}.csv" ]; then

18
lgsm/functions/core_dl.sh

@ -60,29 +60,29 @@ fn_dl_steamcmd(){
if [ "${appid}" == "90" ]; then
# If using a specific branch.
if [ -n "${branch}" ]&&[ -n "${betapassword}" ]; then
${unbuffer} ${steamcmdcommand} +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_set_config 90 mod "${appidmod}" +app_update "${appid}" -beta "${branch}" -betapassword "${betapassword}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_set_config 90 mod "${appidmod}" +app_update "${appid}" -beta "${branch}" -betapassword "${betapassword}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
elif [ -n "${branch}" ]; then
${unbuffer} ${steamcmdcommand} +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_set_config 90 mod "${appidmod}" +app_update "${appid}" -beta "${branch}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_set_config 90 mod "${appidmod}" +app_update "${appid}" -beta "${branch}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
else
${unbuffer} ${steamcmdcommand} +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_set_config 90 mod "${appidmod}" +app_update "${appid}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_set_config 90 mod "${appidmod}" +app_update "${appid}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
fi
# Force Windows Platform type.
elif [ "${steamcmdforcewindows}" == "yes" ]; then
if [ -n "${branch}" ]&&[ -n "${betapassword}" ]; then
${unbuffer} ${steamcmdcommand} +@sSteamCmdForcePlatformType windows +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_update "${appid}" -beta "${branch}" -betapassword "${betapassword}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +@sSteamCmdForcePlatformType windows +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_update "${appid}" -beta "${branch}" -betapassword "${betapassword}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
elif [ -n "${branch}" ]; then
${unbuffer} ${steamcmdcommand} +@sSteamCmdForcePlatformType windows +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_update "${appid}" -beta "${branch}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +@sSteamCmdForcePlatformType windows +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_update "${appid}" -beta "${branch}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
else
${unbuffer} ${steamcmdcommand} +@sSteamCmdForcePlatformType windows +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_update "${appid}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +@sSteamCmdForcePlatformType windows +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_update "${appid}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
fi
# All other servers.
else
if [ -n "${branch}" ]&&[ -n "${betapassword}" ]; then
${unbuffer} ${steamcmdcommand} +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_update "${appid}" -beta "${branch}" -betapassword "${betapassword}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_update "${appid}" -beta "${branch}" -betapassword "${betapassword}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
elif [ -n "${branch}" ]; then
${unbuffer} ${steamcmdcommand} +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_update "${appid}" -beta "${branch}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_update "${appid}" -beta "${branch}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
else
${unbuffer} ${steamcmdcommand} +login "${steamuser}" "${steampass}" +force_install_dir "${serverfiles}" +app_update "${appid}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
${unbuffer} ${steamcmdcommand} +force_install_dir "${serverfiles}" +login "${steamuser}" "${steampass}" +app_update "${appid}" ${validate} +quit | uniq | tee -a "${lgsmlog}" "${steamcmdlog}"
fi
fi

2
lgsm/functions/core_functions.sh

@ -8,7 +8,7 @@
functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
modulesversion="v21.4.1"
modulesversion="v21.5.0"
# Core

61
lgsm/functions/fix_steamcmd.sh

@ -25,6 +25,8 @@ fn_fix_steamclient_so(){
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${2}/steamclient.so"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${2}/steamclient.so"
elif [ -f "${HOME}/.local/share/Steam/steamcmd/linux32/steamclient.so" ]; then
cp "${HOME}/.local/share/Steam/steamcmd/linux32/steamclient.so" "${2}/steamclient.so"
fi
fn_fix_msg_end
fi
@ -40,6 +42,8 @@ fn_fix_steamclient_so(){
cp "${HOME}/.steam/steamcmd/linux64/steamclient.so" "${2}/steamclient.so"
elif [ -f "${steamcmddir}/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${2}/steamclient.so"
elif [ -f "${HOME}/.local/share/Steam/steamcmd/linux64/steamclient.so" ]; then
cp "${HOME}/.local/share/Steam/steamcmd/linux64/steamclient.so" "${2}/steamclient.so"
fi
fn_fix_msg_end
fi
@ -47,27 +51,64 @@ fn_fix_steamclient_so(){
}
# Helps fix: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam,or a local steamclient.so.
if [ ! -f "${HOME}/.steam/sdk64/steamclient.so" ]; then
fixname="steamclient.so sdk64"
steamsdk64="${HOME}/.steam/sdk64"
steamclientsdk64="${steamsdk64}/steamclient.so"
# remove any old unlinked versions of steamclient.so
if [ -f "${steamclientsdk64}" ]; then
if [ "$(stat -c '%h' "${steamclientsdk64}")" -eq 1 ]; then
fixname="steamclient.so sdk64 -- remove old file"
fn_fix_msg_start
rm -f "${steamclientsdk64}"
fn_fix_msg_end
fi
fi
# place new hardlink for the file to the disk
if [ ! -f "${steamclientsdk64}" ]; then
fixname="steamclient.so sdk64 hardlink"
fn_fix_msg_start
mkdir -p "${HOME}/.steam/sdk64"
if [ ! -d "${steamsdk64}" ]; then
mkdir -p "${steamsdk64}"
fi
if [ -f "${HOME}/.steam/steamcmd/linux64/steamclient.so" ]; then
cp "${HOME}/.steam/steamcmd/linux64/steamclient.so" "${HOME}/.steam/sdk64/steamclient.so"
ln "${HOME}/.steam/steamcmd/linux64/steamclient.so" "${steamclientsdk64}"
elif [ -f "${steamcmddir}/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${HOME}/.steam/sdk64/steamclient.so"
ln "${steamcmddir}/linux64/steamclient.so" "${steamclientsdk64}"
elif [ -f "${HOME}/.local/share/Steam/steamcmd/linux64/steamclient.so" ]; then
ln "${HOME}/.local/share/Steam/steamcmd/linux64/steamclient.so" "${steamclientsdk64}"
else
fn_print_fail_nl "Could not copy any steamclient.so 64bit for the gameserver"
fi
fn_fix_msg_end
fi
# Helps fix: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam,or a local steamclient.so.
if [ ! -f "${HOME}/.steam/sdk32/steamclient.so" ]; then
fixname="steamclient.so sdk32"
steamsdk32="${HOME}/.steam/sdk32"
steamclientsdk32="${HOME}/.steam/sdk32/steamclient.so"
if [ -f "${steamclientsdk32}" ]; then
if [ " $(stat -c '%h' "${steamclientsdk32}")" -eq 1 ]; then
fixname="steamclient.so sdk32 -- remove old file"
fn_fix_msg_start
rm -f "${steamclientsdk32}"
fn_fix_msg_end
fi
fi
# place new hardlink for the file to the disk
if [ ! -f "${steamclientsdk32}" ]; then
fixname="steamclient.so sdk32 link"
fn_fix_msg_start
mkdir -p "${HOME}/.steam/sdk32"
if [ ! -d "${steamsdk32}" ]; then
mkdir -p "${steamsdk32}"
fi
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so"
ln "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${steamclientsdk32}"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so"
ln "${steamcmddir}/linux32/steamclient.so" "${steamclientsdk32}"
elif [ -f "${HOME}/.local/share/Steam/steamcmd/linux32/steamclient.so" ]; then
ln "${HOME}/.local/share/Steam/steamcmd/linux32/steamclient.so" "${steamclientsdk32}"
else
fn_print_fail_nl "Could not copy any steamclient.so 32bit for the gameserver"
fi
fn_fix_msg_end
fi

2
lgsm/functions/fix_vh.sh

@ -17,7 +17,7 @@ if [ -f "${modsinstalledlistfullpath}" ]; then
if ! grep -qE "^executable=\"./start_server_bepinex.sh\"" "${configdirserver}/${selfname}.cfg"
then
echo 'executable="./start_server_bepinex.sh"' >> "${configdirserver}/${selfname}.cfg"
executeable="./start_server_bepinex.sh"
executable="./start_server_bepinex.sh"
fi
fi
fi

21
lgsm/functions/info_distro.sh

@ -80,6 +80,23 @@ else
distroversioncsv="${distroversion}"
fi
# Check if distro supported by distro vendor.
if [ "$(command -v distro-info 2>/dev/null)" ]; then
distrosunsupported="$(distro-info --unsupported)"
distrosunsupported_array=( "${distrosunsupported}" )
for distrounsupported in "${distrosunsupported_array[@]}"; do
if [ "${distrounsupported}" == "${distrocodename}" ]; then
distrosupport=unsupported
break
else
distrosupport=supported
fi
done
else
distrosupport=unknown
fi
echo "${distrosupport}"
## Glibc version
# e.g: 1.17
glibcversion="$(ldd --version | sed -n '1s/.* //p')"
@ -291,11 +308,11 @@ if [ -z "${displaymasterserver}" ]; then
if [ "${steammaster}" == "true" ]||[ "${commandname}" == "DEV-QUERY-RAW" ]; then
# Will query server IP addresses first.
for queryip in "${queryips[@]}"; do
masterserver="$(curl --connect-timeout 10 -m 3 -s 'https://api.steampowered.com/ISteamApps/GetServersAtAddress/v0001?addr='${queryip}':'${port}'&format=json' | jq '.response.servers[]|.addr' | wc -l 2>/dev/null)"
masterserver="$(curl --connect-timeout 10 -m 3 -s "https://api.steampowered.com/ISteamApps/GetServersAtAddress/v0001?addr=${queryip}&format=json" | jq --arg port "${port}" --arg queryport "${queryport}" '.response.servers[] | select((.gameport == ($port|tonumber) or (.gameport == ($queryport|tonumber)))) | .addr' | wc -l 2>/dev/null)"
done
# Should that not work it will try the external IP.
if [ "${masterserver}" == "0" ]; then
masterserver="$(curl --connect-timeout 10 -m 3 -s 'https://api.steampowered.com/ISteamApps/GetServersAtAddress/v0001?addr='${extip}':'${port}'&format=json' | jq '.response.servers[]|.addr' | wc -l 2>/dev/null)"
masterserver="$(curl --connect-timeout 10 -m 3 -s "https://api.steampowered.com/ISteamApps/GetServersAtAddress/v0001?addr=${extip}&format=json" | jq --arg port "${port}" --arg queryport "${queryport}" '.response.servers[] | select((.gameport == ($port|tonumber) or (.gameport == ($queryport|tonumber)))) | .addr' | wc -l 2>/dev/null)"
fi
if [ "${masterserver}" == "0" ]; then
displaymasterserver="false"

66
lgsm/functions/info_game.sh

@ -258,6 +258,26 @@ fn_info_game_bt1944(){
rconport=$((port+2))
}
fn_info_game_cd(){
if [ ! -f "${servercfgfullpath}" ]; then
servername="${unavailable}"
port="${zero}"
rconenabled="false"
rconport="${zero}"
rconpassword="${unavailable}"
steamport="${zero}"
maxplayers="${zero}"
else
servername=$(jq -r '.game_title' "${servercfgfullpath}")
port=$(jq -r '.game_port' "${servercfgfullpath}")
steamport=$(jq -r '.steam_port_messages' "${servercfgfullpath}")
rconenabled=$(jq -r '.rcon' "${servercfgfullpath}")
rconport=$(jq -r '.rcon_port' "${servercfgfullpath}")
rconpassword=$(jq -r '.rcon_password' "${servercfgfullpath}")
maxplayers=$(jq -r '.player_count' "${servercfgfullpath}")
fi
}
fn_info_game_cmw(){
# Config
if [ ! -f "${servercfgfullpath}" ]; then
@ -442,6 +462,34 @@ fn_info_game_dodr(){
queryport=${queryport:-"27015"}
}
fn_info_game_dayz(){
# Config
if [ ! -f "${servercfgfullpath}" ]; then
servername="${unavailable}"
adminpassword="${unavailable}"
serverpassword="${unavailable}"
maxplayers="${zero}"
else
servername=$(sed -nr 's/^hostname\s*=\s*"(.*)"\s*;/\1/p' "${servercfgfullpath}")
adminpassword=$(sed -nr 's/^passwordAdmin\s*=\s*"(.*)"\s*;/\1/p' "${servercfgfullpath}")
serverpassword=$(sed -nr 's/^password\s*=\s*"(.*)"\s*;/\1/p' "${servercfgfullpath}")
maxplayers=$(sed -nr 's/^maxPlayers\s*=\s*([0-9]+)\s*;/\1/p' "${servercfgfullpath}")
queryport=$(sed -nr 's/^steamQueryPort\s*=\s*([0-9]+)\s*;/\1/p' "${servercfgfullpath}")
# Not Set
servername=${servername:-"NOT SET"}
adminpassword=${adminpassword:-"NOT SET"}
serverpassword=${serverpassword:-"NOT SET"}
maxplayers=${maxplayers:-"0"}
queryport=${queryport:-"27016"}
fi
# Parameters
port=${port:-"2302"}
steammasterport=$((port+2))
battleeyeport=$((port+4))
}
fn_info_game_dst(){
# Config
if [ ! -f "${clustercfgfullpath}" ]; then
@ -1771,6 +1819,16 @@ fn_info_game_stn(){
fi
}
fn_info_game_ti(){
if [ -f "${servercfgfullpath}" ]; then
servername=$(sed -nr 's/^ServerName="(.*)"/\1/p' "${servercfgfullpath}")
maxplayers=$(sed -nr 's/^MaxPlayerCount=([0-9]+)/\1/' "${servercfgfullpath}")
else
servername="${unavailable}"
maxplayers="${zero}"
fi
}
fn_info_game_ts3(){
# Config
if [ ! -f "${servercfgfullpath}" ]; then
@ -2209,6 +2267,8 @@ elif [ "${shortname}" == "bt" ]; then
fn_info_game_bt
elif [ "${shortname}" == "bt1944" ]; then
fn_info_game_bt1944
elif [ "${shortname}" == "cd" ]; then
fn_info_game_cd
elif [ "${shortname}" == "cmw" ]; then
fn_info_game_cmw
elif [ "${shortname}" == "cod" ]; then
@ -2223,6 +2283,8 @@ elif [ "${shortname}" == "codwaw" ]; then
fn_info_game_codwaw
elif [ "${shortname}" == "col" ]; then
fn_info_game_col
elif [ "${shortname}" == "dayz" ]; then
fn_info_game_dayz
elif [ "${shortname}" == "dodr" ]; then
fn_info_game_dodr
elif [ "${shortname}" == "dst" ]; then
@ -2315,6 +2377,10 @@ elif [ "${shortname}" == "stn" ]; then
fn_info_game_stn
elif [ "${shortname}" == "terraria" ]; then
fn_info_game_terraria
elif [ "${shortname}" == "ti" ]; then
fn_info_game_ti
elif [ "${shortname}" == "ts3" ]; then
fn_info_game_ts3
elif [ "${shortname}" == "tu" ]; then
fn_info_game_tu
elif [ "${shortname}" == "tw" ]; then

37
lgsm/functions/info_messages.sh

@ -658,7 +658,7 @@ fn_info_message_ports_edit(){
startparameterslocation="${red}UNKNOWN${default}"
# engines/games that require editing in the config file.
local ports_edit_array=( "ac" "arma3" "bo" "bt" "dst" "eco" "idtech2" "idtech3" "idtech3_ql" "jc2" "jc3" "lwjgl2" "mcb" "mumble" "pc" "pz" "qw" "refractor" "renderware" "rw" "sb" "sdtd" "st" "stn" "ts3" "tw" "terraria" "unreal" "unreal2" "unreal3" "vints" "wurm")
local ports_edit_array=( "ac" "arma3" "bo" "bt" "cd" "dst" "eco" "idtech2" "idtech3" "idtech3_ql" "jc2" "jc3" "lwjgl2" "mcb" "mumble" "pc" "pz" "qw" "refractor" "renderware" "rw" "sb" "sdtd" "st" "stn" "ts3" "tw" "terraria" "unreal" "unreal2" "unreal3" "vints" "wurm")
for port_edit in "${ports_edit_array[@]}"; do
if [ "${shortname}" == "ut3" ]; then
startparameterslocation="${servercfgdir}/UTWeb.ini"
@ -669,7 +669,7 @@ fn_info_message_ports_edit(){
fi
done
# engines/games that require editing the start parameters.
local ports_edit_array=( "av" "col" "fctr" "goldsrc" "hw" "iw3.0" "ioquake3" "qfusion" "rust" "scpsl" "scpslsm" "sol" "spark" "source" "unreal4" "arma3" "unt" "vh" )
local ports_edit_array=( "av" "col" "fctr" "goldsrc" "hw" "iw3.0" "ioquake3" "qfusion" "rust" "scpsl" "scpslsm" "sol" "spark" "source" "unreal4" "arma3" "dayz" "unt" "vh" )
for port_edit in "${ports_edit_array[@]}"; do
if [ "${engine}" == "${port_edit}" ]||[ "${gamename}" == "${port_edit}" ]||[ "${shortname}" == "${port_edit}" ]; then
startparameterslocation="${configdirserver}"
@ -859,6 +859,15 @@ fn_info_message_bt1944(){
} | column -s $'\t' -t
}
fn_info_messages_cd(){
{
fn_port "header"
fn_port "Game" port udp
fn_port "Steam" steamport udp
fn_port "RCON" rconport tcp
} | column -s $'\t' -t
}
fn_info_message_cmw(){
fn_info_message_password_strip
{
@ -929,6 +938,16 @@ fn_info_message_csgo(){
} | column -s $'\t' -t
}
fn_info_message_dayz(){
{
fn_port "header"
fn_port "Game" port udp
fn_port "Query Steam" queryport udp
fn_port "Steam Master" steammasterport udp
fn_port "BattleEye" battleeyeport udp
} | column -s $'\t' -t
}
fn_info_message_dodr(){
{
fn_port "header"
@ -1414,6 +1433,14 @@ fn_info_message_st(){
} | column -s $'\t' -t
}
fn_info_message_ti(){
{
fn_port "header"
fn_port "Game" port udp
fn_port "Query" queryport udp
} | column -s $'\t' -t
}
fn_info_message_ts3(){
{
fn_port "header"
@ -1615,6 +1642,8 @@ fn_info_message_select_engine(){
fn_info_message_bt
elif [ "${shortname}" == "bt1944" ]; then
fn_info_message_bt1944
elif [ "${shortname}" == "cd" ]; then
fn_info_messages_cd
elif [ "${shortname}" == "csgo" ]; then
fn_info_message_csgo
elif [ "${shortname}" == "cmw" ]; then
@ -1631,6 +1660,8 @@ fn_info_message_select_engine(){
fn_info_message_codwaw
elif [ "${shortname}" == "col" ]; then
fn_info_message_col
elif [ "${shortname}" == "dayz" ]; then
fn_info_message_dayz
elif [ "${shortname}" == "dodr" ]; then
fn_info_message_dodr
elif [ "${shortname}" == "dst" ]; then
@ -1719,6 +1750,8 @@ fn_info_message_select_engine(){
fn_info_message_stn
elif [ "${shortname}" == "terraria" ]; then
fn_info_message_terraria
elif [ "${shortname}" == "ti" ]; then
fn_info_message_ti
elif [ "${shortname}" == "ts3" ]; then
fn_info_message_ts3
elif [ "${shortname}" == "tu" ]; then

22
lgsm/functions/install_config.sh

@ -274,6 +274,13 @@ elif [ "${shortname}" == "bmdm" ]; then
fn_default_config_remote
fn_set_config_vars
fn_list_config_locations
elif [ "${shortname}" == "cd" ]; then
gamedirname="CraftingDead"
array_configs+=( properties.json )
fn_fetch_default_config
fn_default_config_remote
fn_set_config_vars
fn_list_config_locations
elif [ "${shortname}" == "cod" ]; then
gamedirname="CallOfDuty"
array_configs+=( server.cfg )
@ -351,6 +358,14 @@ elif [ "${shortname}" == "css" ]; then
fn_default_config_remote
fn_set_config_vars
fn_list_config_locations
elif [ "${shortname}" == "dayz" ]; then
gamedirname="DayZ"
fn_check_cfgdir
array_configs+=( server.cfg )
fn_fetch_default_config
fn_default_config_remote
fn_set_config_vars
fn_list_config_locations
elif [ "${shortname}" == "dod" ]; then
gamedirname="DayOfDefeat"
array_configs+=( server.cfg )
@ -757,6 +772,13 @@ elif [ "${shortname}" == "tfc" ]; then
fn_default_config_remote
fn_set_config_vars
fn_list_config_locations
elif [ "${shortname}" == "ti" ]; then
gamedirname="TheIsle"
array_configs+=( Game.ini )
fn_fetch_default_config
fn_default_config_remote
fn_set_config_vars
fn_list_config_locations
elif [ "${shortname}" == "ts" ]; then
gamedirname="TheSpecialists"
array_configs+=( server.cfg )

2
lgsm/functions/install_server_files.sh

@ -27,7 +27,7 @@ fn_install_server_files(){
elif [ "${shortname}" == "codwaw" ]; then
remote_fileurl="http://linuxgsm.download/CallOfDutyWorldAtWar/codwaw-lnxded-1.7-full.tar.xz"; local_filedir="${tmpdir}"; local_filename="codwaw-lnxded-1.7-full.tar.xz"; chmodx="nochmodx" run="norun"; force="noforce"; md5="2c6be1bb66ea631b9b2e7ae6216c6680"
elif [ "${shortname}" == "etl" ]; then
remote_fileurl="http://linuxgsm.download/WolfensteinEnemyTerritory/etlegacy-v2.78-i386-et-260b.tar.xz"; local_filedir="${tmpdir}"; local_filename="etlegacy-v2.78-i386-et-260b.tar.xz"; chmodx="nochmodx" run="norun"; force="noforce"; md5="501e442fdac2eeab5e7f51e5b5c27280"
remote_fileurl="http://linuxgsm.download/WolfensteinEnemyTerritory/etlegacy-v2.78.1-i386-et-260b.tar.xz"; local_filedir="${tmpdir}"; local_filename="etlegacy-v2.78.1-i386-et-260b.tar.xz"; chmodx="nochmodx" run="norun"; force="noforce"; md5="7c08b52cb09b30eadb98ea05ef780fc7"
elif [ "${shortname}" == "mohaa" ]; then
remote_fileurl="http://linuxgsm.download/MedalofHonorAlliedAssault/moh_revival_v1.12_RC3.5.1.tar.xz"; local_filedir="${tmpdir}"; local_filename="moh_revival_v1.12_RC3.5.1.tar.xz"; chmodx="nochmodx" run="norun"; force="noforce"; md5="7c664538999252eeaf2b6d9949416480"
elif [ "${shortname}" == "ns" ]; then

44
lgsm/functions/mods_core.sh

@ -33,33 +33,39 @@ fn_mod_install_files(){
# Convert mod files to lowercase if needed.
fn_mod_lowercase(){
# Checking lowercase settings from mods array definition
if [ "${modlowercase}" == "LowercaseOn" ]; then
echo -en "converting ${modprettyname} files to lowercase..."
fn_sleep_time
fn_script_log_info "Converting ${modprettyname} files to lowercase"
fileswc=$(find "${extractdir}" -depth | wc -l)
echo -en "\r"
# Total files and directories for the mod, to output to the user
fileswc=$(find "${extractdir}" | wc -l)
# Total uppercase files and directories for the mod, to output to the user
filesupperwc=$(find "${extractdir}" -name '*[[:upper:]]*' | wc -l)
fn_script_log_info "Found ${filesupperwc} uppercase files out of ${fileswc}, converting"
echo -en "Found ${filesupperwc} uppercase files out of ${fileswc}, converting..."
# Convert files and directories starting from the deepest to prevent issues (-depth argument)
while read -r src; do
dst=$(dirname "${src}$(/)basename" "${src}" | tr '[:upper:]' '[:lower:]')
if [ "${src}" != "${dst}" ]
then
[ ! -e "${dst}" ] && mv -T "${src}" "${dst}" || echo -e "${src} was not renamed"
# We have to convert only the last file from the path, otherwise we will fail to convert anything if a parent dir has any uppercase
# therefore, we have to separate the end of the filename to only lowercase it rather than the whole line
# Gather parent dir, filename lowercase filename, and set lowercase destination name
latestparentdir=$(dirname "${src}")
latestfilelc=$(basename "${src}" | tr '[:upper:]' '[:lower:]')
dst="${latestparentdir}/${latestfilelc}"
# Only convert if destination does not already exist for some reason
if [ ! -e "${dst}" ]; then
# Finally we can rename the file
mv "${src}" "${dst}"
# Exit if it fails for any reason
local exitcode=$?
((renamedwc++))
if [ "${exitcode}" != 0 ]; then
fn_print_fail_eol_nl
core_exit.sh
fi
fi
echo -en "${renamedwc} / ${totalfileswc} / ${fileswc} converting ${modprettyname} files to lowercase..." $'\r'
((totalfileswc++))
done < <(find "${extractdir}" -depth)
echo -en "${renamedwc} / ${totalfileswc} / ${fileswc} converting ${modprettyname} files to lowercase..."
if [ "${exitcode}" != 0 ]; then
fn_print_fail_eol_nl
core_exit.sh
else
done < <(find "${extractdir}" -depth -name '*[[:upper:]]*')
fn_print_ok_eol_nl
fi
fi
fi
}
# Create ${modcommand}-files.txt containing the full extracted file/directory list.

2
linuxgsm.sh

@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then
set -x
fi
version="v21.4.1"
version="v21.5.0"
shortname="core"
gameservername="core"
commandname="CORE"

2
tests/tests_fctrserver.sh

@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then
set -x
fi
version="v21.4.1"
version="v21.5.0"
shortname="fctr"
gameservername="fctrserver"
commandname="CORE"

2
tests/tests_jc2server.sh

@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then
set -x
fi
version="v21.4.1"
version="v21.5.0"
shortname="jc2"
gameservername="jc2server"
commandname="CORE"

2
tests/tests_mcserver.sh

@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then
set -x
fi
version="v21.4.1"
version="v21.5.0"
shortname="mc"
gameservername="mcserver"
commandname="CORE"

2
tests/tests_ts3server.sh

@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then
set -x
fi
version="v21.4.1"
version="v21.5.0"
shortname="ts3"
gameservername="ts3server"
commandname="CORE"

Loading…
Cancel
Save