From 1007d5505ca18e806c1ff42634ead55c0a9ed82f Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:19:42 +0000 Subject: [PATCH 01/18] removed x86 for x64 hurtworld exec --- functions/command_details.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions/command_details.sh b/functions/command_details.sh index 30437b933..6cf79674d 100644 --- a/functions/command_details.sh +++ b/functions/command_details.sh @@ -499,7 +499,7 @@ echo -e "Change ports by editing the parameters in" echo -e "hwserver script" echo -e "" echo -e "Useful port diagnostic command:" -echo -e "netstat -atunp | grep Hurtworld.x86" +echo -e "netstat -atunp | grep Hurtworld" echo -e "" { echo -e "DESCRIPTION\tDIRECTION\tPORT\tPROTOCOL" From accd81186921a994dcdc550b4ee73bc9a6e10324 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:20:18 +0000 Subject: [PATCH 02/18] Added comments on the fixes --- functions/install_fix_steam.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/functions/install_fix_steam.sh b/functions/install_fix_steam.sh index 2a2d5d656..d3e329a80 100644 --- a/functions/install_fix_steam.sh +++ b/functions/install_fix_steam.sh @@ -9,6 +9,7 @@ echo "" echo "Applying steamclient.so fix" echo "=================================" sleep 1 +# Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam,or a local steamclient.so. mkdir -pv "${HOME}/.steam/sdk32" cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" sleep 1 @@ -21,12 +22,15 @@ echo "Applying libsteam.so and steamclient.so fixes" echo "=================================" sleep 1 if [ "${gamename}" == "Garry's Mod" ]; then + # Fixes: .steam/sdk32/libsteam.so: cannot open shared object file: No such file or directory mkdir -pv "${HOME}/.steam/sdk32" cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then + # Fixes: .steam/bin32/libsteam.so: cannot open shared object file: No such file or directory mkdir -pv "${HOME}/.steam/bin32" cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" elif [ "${gamename}" == "Hurtworld" ]; then + # Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so. cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" fi From 8d3cc1112d84022243acd39335aa805bf39504cd Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:36:54 +0000 Subject: [PATCH 03/18] intergrating fix.sh --- functions/command_debug.sh | 9 +----- functions/command_start.sh | 11 +------ functions/command_validate.sh | 5 +-- functions/core_functions.sh | 10 ++++++ functions/fix.sh | 21 ++++++++++++ functions/fix_csgo.sh | 4 +-- functions/fix_steamcmd.sh | 60 +++++++++++++++++++++++++++++++++++ functions/update_dl.sh | 5 +-- 8 files changed, 97 insertions(+), 28 deletions(-) create mode 100644 functions/fix.sh create mode 100644 functions/fix_steamcmd.sh diff --git a/functions/command_debug.sh b/functions/command_debug.sh index bec1f7ade..91f91dd66 100644 --- a/functions/command_debug.sh +++ b/functions/command_debug.sh @@ -52,15 +52,8 @@ fn_scriptlog "Started debug" sleep 1 echo -en "\n" cd "${executabledir}" +fix.sh if [ "${engine}" == "source" ]||[ "${engine}" == "goldsource" ]; then - if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then - startfix=1 - fix_csgo.sh - elif [ "${gamename}" == "Insurgency" ]; then - fix_ins.sh - elif [ "${gamename}" == "ARMA 3" ]; then - fix_arma3.sh - fi ${executable} ${parms} -debug else ${executable} ${parms} diff --git a/functions/command_start.sh b/functions/command_start.sh index 2a4c9b74c..a79302698 100644 --- a/functions/command_start.sh +++ b/functions/command_start.sh @@ -73,16 +73,7 @@ echo -en "\n" fn_start_tmux(){ check.sh - -if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then - startfix=1 - fix_csgo.sh -elif [ "${gamename}" == "Insurgency" ]; then - fix_ins.sh -elif [ "${gamename}" == "ARMA 3" ]; then - fix_arma3.sh -fi - +fix.sh info_config.sh fn_parms logs.sh diff --git a/functions/command_validate.sh b/functions/command_validate.sh index 1d3774276..b6dc36819 100644 --- a/functions/command_validate.sh +++ b/functions/command_validate.sh @@ -34,10 +34,7 @@ else ${unbuffer} ./steamcmd.sh +login "${steamuser}" "${steampass}" +force_install_dir "${filesdir}" +app_update "${appid}" validate +quit|tee -a "${scriptlog}" fi -if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then - echo -e '\n' - fix_csgo.sh -fi +fix.sh fn_scriptlog "Checking complete" } diff --git a/functions/core_functions.sh b/functions/core_functions.sh index 2aa1648c0..41e86824d 100644 --- a/functions/core_functions.sh +++ b/functions/core_functions.sh @@ -165,6 +165,11 @@ fn_runfunction # Fix +fix.sh(){ +functionfile="${FUNCNAME}" +fn_runfunction +} + fix_arma3.sh(){ functionfile="${FUNCNAME}" fn_runfunction @@ -180,6 +185,11 @@ functionfile="${FUNCNAME}" fn_runfunction } +fix_steamcmd.sh(){ +functionfile="${FUNCNAME}" +fn_runfunction +} + # Info diff --git a/functions/fix.sh b/functions/fix.sh new file mode 100644 index 000000000..4659831e6 --- /dev/null +++ b/functions/fix.sh @@ -0,0 +1,21 @@ +#!/bin/bash +# LGSM fix.sh function +# Author: Daniel Gibbs +# Website: http://gameservermanagers.com +lgsm_version="291215" + +# Description: Overall function for managing fixes. +# Runs functions that will fix an issue. + +if [ ! -z "${appid}" ]; then + fix_steamcmd.sh +fi + +if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then + startfix=1 + fix_csgo.sh +elif [ "${gamename}" == "Insurgency" ]; then + fix_ins.sh +elif [ "${gamename}" == "ARMA 3" ]; then + fix_arma3.sh +fi \ No newline at end of file diff --git a/functions/fix_csgo.sh b/functions/fix_csgo.sh index 488149b0f..c6243d5c6 100644 --- a/functions/fix_csgo.sh +++ b/functions/fix_csgo.sh @@ -19,7 +19,7 @@ if [ ! -f "${filesdir}/steam_appid.txt" ]; then fi } -fn_csgofixes(){ +fn_install_fix_csgo(){ # Fixes the following error: # Error parsing BotProfile.db - unknown attribute 'Rank". if ! grep -q "//Rank" "${systemdir}/botprofile.db" > /dev/null 2>&1; then @@ -84,5 +84,5 @@ fi if [ ! -z "${startfix}" ]; then fn_csgoappfix else - fn_csgofixes + fn_install_fix_csgo fi \ No newline at end of file diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh new file mode 100644 index 000000000..e373e03ab --- /dev/null +++ b/functions/fix_steamcmd.sh @@ -0,0 +1,60 @@ +#!/bin/bash +# LGSM fix_steamcmd.sh function +# Author: Daniel Gibbs +# Website: http://gameservermanagers.com +lgsm_version="301215" + +# Description: fixes various issues related to steamCMD + +fn_fix_steamcmd_msg_start(){ + fn_printdots "Applying steamclient.so fix: ${gamename}" + sleep 2 + fn_printinfo "Applying steamclient.so fix: ${gamename}" +} + +fn_fix_steamcmd_msg_end(){ + if [ $? -ne 0 ]; then + fn_printfail "Applying steamclient.so fix: ${gamename}" + else + fn_printok "Applying steamclient.so fix: ${gamename}" + fi +} + + +# Fixes: [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 + fn_fix_steamcmd_msg_start + mkdir -pv "${HOME}/.steam/sdk32" + cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" + fn_fix_steamcmd_msg_end +fi + +if [ "${gamename}" == "Garry's Mod" ]; then + # Fixes: .steam/sdk32/libsteam.so: cannot open shared object file: No such file or directory + if [ ! -f "${HOME}/.steam/sdk32/libsteam.so" ]; then + fn_fix_steamcmd_msg_start + mkdir -pv "${HOME}/.steam/sdk32" + cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" + fn_fix_steamcmd_msg_end + fi +elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then + # Fixes: .steam/bin32/libsteam.so: cannot open shared object file: No such file or directory + if [ ! -f "${HOME}/.steam/bin32/libsteam.so" ]; then + fn_fix_steamcmd_msg_start + mkdir -pv "${HOME}/.steam/bin32" + cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" + fn_fix_steamcmd_msg_end + fi +elif [ "${gamename}" == "Hurtworld" ]; then + # Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so. + if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" ]; then + fn_fix_steamcmd_msg_start + cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" + fn_fix_steamcmd_msg_end + fi + if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" ]; then + fn_fix_steamcmd_msg_start + cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" + fn_fix_steamcmd_msg_end + fi +fi diff --git a/functions/update_dl.sh b/functions/update_dl.sh index 21fa13154..09bd3ebe9 100644 --- a/functions/update_dl.sh +++ b/functions/update_dl.sh @@ -24,10 +24,7 @@ else ${unbuffer} ./steamcmd.sh +login "${steamuser}" "${steampass}" +force_install_dir "${filesdir}" +app_update "${appid}" +quit|tee -a "${scriptlog}" fi -if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then - echo -e '\n' - fix_csgo.sh -fi +fix.sh } fn_teamspeak3_dl(){ From 21af90524c7a50d1f2979fb2234adb9a2ff8f91b Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:46:16 +0000 Subject: [PATCH 04/18] improving messages --- functions/fix_steamcmd.sh | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh index e373e03ab..b2196c28c 100644 --- a/functions/fix_steamcmd.sh +++ b/functions/fix_steamcmd.sh @@ -7,22 +7,23 @@ lgsm_version="301215" # Description: fixes various issues related to steamCMD fn_fix_steamcmd_msg_start(){ - fn_printdots "Applying steamclient.so fix: ${gamename}" + fn_printdots "Applying ${fixname} fix: ${gamename}" sleep 2 - fn_printinfo "Applying steamclient.so fix: ${gamename}" + fn_printinfonl "Applying ${fixname} fix: ${gamename}" } fn_fix_steamcmd_msg_end(){ if [ $? -ne 0 ]; then - fn_printfail "Applying steamclient.so fix: ${gamename}" + fn_printfailnl "Applying ${fixname} fix: ${gamename}" else - fn_printok "Applying steamclient.so fix: ${gamename}" + fn_printoknl "Applying ${fixname} fix: ${gamename}" fi } # Fixes: [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 + local fixname="steamclient.so general" fn_fix_steamcmd_msg_start mkdir -pv "${HOME}/.steam/sdk32" cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" @@ -32,6 +33,7 @@ fi if [ "${gamename}" == "Garry's Mod" ]; then # Fixes: .steam/sdk32/libsteam.so: cannot open shared object file: No such file or directory if [ ! -f "${HOME}/.steam/sdk32/libsteam.so" ]; then + local fixname="libsteam.so" fn_fix_steamcmd_msg_start mkdir -pv "${HOME}/.steam/sdk32" cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" @@ -40,6 +42,7 @@ if [ "${gamename}" == "Garry's Mod" ]; then elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then # Fixes: .steam/bin32/libsteam.so: cannot open shared object file: No such file or directory if [ ! -f "${HOME}/.steam/bin32/libsteam.so" ]; then + local fixname="libsteam.so" fn_fix_steamcmd_msg_start mkdir -pv "${HOME}/.steam/bin32" cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" @@ -47,12 +50,15 @@ elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then fi elif [ "${gamename}" == "Hurtworld" ]; then # Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so. + if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" ]; then + local fixname="steamclient.so x86" fn_fix_steamcmd_msg_start cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" fn_fix_steamcmd_msg_end fi if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" ]; then + local fixname="steamclient.so x86_64" fn_fix_steamcmd_msg_start cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" fn_fix_steamcmd_msg_end From 6b35557cb176d3eb8c9f493407ec039d4522cece Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:48:53 +0000 Subject: [PATCH 05/18] Added script log messages --- functions/fix_steamcmd.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh index b2196c28c..0dcbd3c3b 100644 --- a/functions/fix_steamcmd.sh +++ b/functions/fix_steamcmd.sh @@ -15,8 +15,10 @@ fn_fix_steamcmd_msg_start(){ fn_fix_steamcmd_msg_end(){ if [ $? -ne 0 ]; then fn_printfailnl "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Failure! Applying ${fixname} fix: ${gamename}" else fn_printoknl "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Complete! Applying ${fixname} fix: ${gamename}" fi } From a79c4bf1fb9512673036dc421ee87a5784061989 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:52:32 +0000 Subject: [PATCH 06/18] outputs copy to logs instead of screen --- functions/fix_steamcmd.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh index 0dcbd3c3b..abb3888e9 100644 --- a/functions/fix_steamcmd.sh +++ b/functions/fix_steamcmd.sh @@ -28,7 +28,7 @@ if [ ! -f "${HOME}/.steam/sdk32/steamclient.so" ]; then local fixname="steamclient.so general" fn_fix_steamcmd_msg_start mkdir -pv "${HOME}/.steam/sdk32" - cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" + cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi @@ -38,7 +38,7 @@ if [ "${gamename}" == "Garry's Mod" ]; then local fixname="libsteam.so" fn_fix_steamcmd_msg_start mkdir -pv "${HOME}/.steam/sdk32" - cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" + cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then @@ -47,7 +47,7 @@ elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then local fixname="libsteam.so" fn_fix_steamcmd_msg_start mkdir -pv "${HOME}/.steam/bin32" - cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" + cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi elif [ "${gamename}" == "Hurtworld" ]; then @@ -56,13 +56,13 @@ elif [ "${gamename}" == "Hurtworld" ]; then if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" ]; then local fixname="steamclient.so x86" fn_fix_steamcmd_msg_start - cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" + cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" ]; then local fixname="steamclient.so x86_64" fn_fix_steamcmd_msg_start - cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" + cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi fi From eb6c4cbe0fb7f3c421c364f38fe873bd8b7ac3d3 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:55:36 +0000 Subject: [PATCH 07/18] Added another message to scriptlog --- functions/fix_steamcmd.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh index abb3888e9..32c5722f2 100644 --- a/functions/fix_steamcmd.sh +++ b/functions/fix_steamcmd.sh @@ -10,6 +10,7 @@ fn_fix_steamcmd_msg_start(){ fn_printdots "Applying ${fixname} fix: ${gamename}" sleep 2 fn_printinfonl "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Applying ${fixname} fix: ${gamename}" } fn_fix_steamcmd_msg_end(){ From 8cccdfdccdef5fec4f36e1ba705a4c8ed1c636b5 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 00:56:39 +0000 Subject: [PATCH 08/18] removed newline --- functions/fix_steamcmd.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh index 32c5722f2..f6f460fd7 100644 --- a/functions/fix_steamcmd.sh +++ b/functions/fix_steamcmd.sh @@ -9,7 +9,7 @@ lgsm_version="301215" fn_fix_steamcmd_msg_start(){ fn_printdots "Applying ${fixname} fix: ${gamename}" sleep 2 - fn_printinfonl "Applying ${fixname} fix: ${gamename}" + fn_printinfo "Applying ${fixname} fix: ${gamename}" fn_scriptlog "Applying ${fixname} fix: ${gamename}" } From 7b31105b668ed211f07af4c14fd05b3233a630bc Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 01:03:05 +0000 Subject: [PATCH 09/18] improved messages --- functions/fix_steamcmd.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh index f6f460fd7..070ce7165 100644 --- a/functions/fix_steamcmd.sh +++ b/functions/fix_steamcmd.sh @@ -4,13 +4,14 @@ # Website: http://gameservermanagers.com lgsm_version="301215" -# Description: fixes various issues related to steamCMD +# Description: fixes various issues related to steamCMD. fn_fix_steamcmd_msg_start(){ fn_printdots "Applying ${fixname} fix: ${gamename}" - sleep 2 + sleep 1 fn_printinfo "Applying ${fixname} fix: ${gamename}" fn_scriptlog "Applying ${fixname} fix: ${gamename}" + sleep 1 } fn_fix_steamcmd_msg_end(){ @@ -28,7 +29,7 @@ fn_fix_steamcmd_msg_end(){ if [ ! -f "${HOME}/.steam/sdk32/steamclient.so" ]; then local fixname="steamclient.so general" fn_fix_steamcmd_msg_start - mkdir -pv "${HOME}/.steam/sdk32" + mkdir -pv "${HOME}/.steam/sdk32" >> "${scriptlog}" cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi @@ -38,7 +39,7 @@ if [ "${gamename}" == "Garry's Mod" ]; then if [ ! -f "${HOME}/.steam/sdk32/libsteam.so" ]; then local fixname="libsteam.so" fn_fix_steamcmd_msg_start - mkdir -pv "${HOME}/.steam/sdk32" + mkdir -pv "${HOME}/.steam/sdk32" >> "${scriptlog}" cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi @@ -47,7 +48,7 @@ elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then if [ ! -f "${HOME}/.steam/bin32/libsteam.so" ]; then local fixname="libsteam.so" fn_fix_steamcmd_msg_start - mkdir -pv "${HOME}/.steam/bin32" + mkdir -pv "${HOME}/.steam/bin32" >> "${scriptlog}" cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" >> "${scriptlog}" fn_fix_steamcmd_msg_end fi From adba7743f57caa4cd5ec823195ad8b24dd450008 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 19:18:00 +0000 Subject: [PATCH 10/18] reworked csgofixes --- functions/command_install.sh | 2 +- functions/fix_csgo.sh | 95 +++++++++++++----------------------- 2 files changed, 35 insertions(+), 62 deletions(-) diff --git a/functions/command_install.sh b/functions/command_install.sh index 2ddb3a785..0ebea8caa 100644 --- a/functions/command_install.sh +++ b/functions/command_install.sh @@ -23,7 +23,7 @@ elif [ "${gamename}" == "Teamspeak 3" ]; then elif [ ! -z "${appid}" ]; then install_steamcmd.sh install_serverfiles.sh - install_fix_steam.sh + fix.sh fi # Configuration diff --git a/functions/fix_csgo.sh b/functions/fix_csgo.sh index c6243d5c6..084fd70d3 100644 --- a/functions/fix_csgo.sh +++ b/functions/fix_csgo.sh @@ -2,87 +2,60 @@ # LGSM fix_csgo.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com -lgsm_version="271215" +lgsm_version="301215" # Description: Resolves various issues with csgo. -# Fixed server not always creating steam_appid.txt file. -fn_csgoappfix(){ -if [ ! -f "${filesdir}/steam_appid.txt" ]; then - fn_printdots "Applying 730 steam_appid.txt Fix." +fn_fix_steamcmd_msg_start(){ + fn_printdots "Applying ${fixname} fix: ${gamename}" sleep 1 - fn_printinfo "Applying 730 steam_appid.txt Fix." - fn_scriptlog "Applying 730 steam_appid.txt Fix" + fn_printinfo "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Applying ${fixname} fix: ${gamename}" sleep 1 - echo -en "\n" +} + +fn_fix_steamcmd_msg_end(){ + if [ $? -ne 0 ]; then + fn_printfailnl "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Failure! Applying ${fixname} fix: ${gamename}" + else + fn_printoknl "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Complete! Applying ${fixname} fix: ${gamename}" + fi +} + +# Fixes: server not always creating steam_appid.txt file. +if [ ! -f "${filesdir}/steam_appid.txt" ]; then + local fixname="730 steam_appid.txt" + fn_fix_steamcmd_msg_start echo -n "730" >> "${filesdir}/steam_appid.txt" + fn_fix_steamcmd_msg_end fi -} -fn_install_fix_csgo(){ -# Fixes the following error: -# Error parsing BotProfile.db - unknown attribute 'Rank". +# Fixes: Error parsing BotProfile.db - unknown attribute 'Rank'". if ! grep -q "//Rank" "${systemdir}/botprofile.db" > /dev/null 2>&1; then - echo "Applying botprofile.db fix." - sleep 1 - echo "" - echo "botprofile.db fix removes the following error from appearing on the console:" - echo " Error parsing BotProfile.db - unknown attribute 'Rank" - sleep 1 + local fixname="botprofile.db" + fn_fix_steamcmd_msg_start sed -i 's/\tRank/\t\/\/Rank/g' "${systemdir}/botprofile.db" > /dev/null 2>&1 - if [ $? -ne 0 ]; then - fn_printfailure "Applying botprofile.db fix." - else - fn_printcomplete "Applying botprofile.db fix." - fi - echo -en "\n" - echo "" + fn_fix_steamcmd_msg_end fi -# Fixes errors simular to the following: -# Unknown command "cl_bobamt_vert". +# Fixes: Unknown command "cl_bobamt_vert". if ! grep -q "//exec default" "${servercfgdir}/valve.rc" > /dev/null 2>&1 || ! grep -q "//exec joystick" "${servercfgdir}/valve.rc" > /dev/null 2>&1; then - echo "Applying valve.rc fix." - sleep 1 - echo "" - echo "valve.rc fix removes the following error from appearing on the console:" - echo " Unknown command \"cl_bobamt_vert\"" - sleep 1 + local fixname="valve.rc" + fn_fix_steamcmd_msg_start sed -i 's/exec default.cfg/\/\/exec default.cfg/g' "${servercfgdir}/valve.rc" > /dev/null 2>&1 sed -i 's/exec joystick.cfg/\/\/exec joystick.cfg/g' "${servercfgdir}/valve.rc" > /dev/null 2>&1 - if [ $? -ne 0 ]; then - fn_printfailure "Applying valve.rc fix." - else - fn_printcomplete "Applying valve.rc fix." - fi - echo -en "\n" - echo "" + fn_fix_steamcmd_msg_end fi -# Fixes errors simular to the following: +# Fixes: workshop map issue. # http://forums.steampowered.com/forums/showthread.php?t=3170366. if [ -f "${systemdir}/subscribed_collection_ids.txt" ]||[ -f "${systemdir}/subscribed_file_ids.txt" ]||[ -f "${systemdir}/ugc_collection_cache.txt" ]; then - echo "workshopmapfix fixes the following error:" - echo " http://forums.steampowered.com/forums/showthread.php?t=3170366" - sleep 1 - echo "" - echo "Applying workshopmap fix." - sleep 1 + local fixname="workshop map" + fn_fix_steamcmd_msg_start rm -f "${systemdir}/subscribed_collection_ids.txt" rm -f "${systemdir}/subscribed_file_ids.txt" rm -f "${systemdir}/ugc_collection_cache.txt" - if [ $? -ne 0 ]; then - fn_printfailure "Applying workshopmap fix." - else - fn_printcomplete "Applying workshopmap fix." - fi - echo -en "\n" - echo "" -fi -} - -if [ ! -z "${startfix}" ]; then - fn_csgoappfix -else - fn_install_fix_csgo + fn_fix_steamcmd_msg_end fi \ No newline at end of file From 819615eff1c4199aa51432c6b7a218636a2d85a2 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 19:24:33 +0000 Subject: [PATCH 11/18] updated arma3 fix --- functions/fix_arma3.sh | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/functions/fix_arma3.sh b/functions/fix_arma3.sh index 2240b0fb7..c6b6ece0c 100644 --- a/functions/fix_arma3.sh +++ b/functions/fix_arma3.sh @@ -2,10 +2,32 @@ # LGSM fix_arma3.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com -lgsm_version="271215" +lgsm_version="301215" # Fixes line 63: 20150 Segmentation fault (core dumped) #488 +fn_fix_steamcmd_msg_start(){ + fn_printdots "Applying ${fixname} fix: ${gamename}" + sleep 1 + fn_printinfo "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Applying ${fixname} fix: ${gamename}" + sleep 1 +} + +fn_fix_steamcmd_msg_end(){ + if [ $? -ne 0 ]; then + fn_printfailnl "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Failure! Applying ${fixname} fix: ${gamename}" + else + fn_printoknl "Applying ${fixname} fix: ${gamename}" + fn_scriptlog "Complete! Applying ${fixname} fix: ${gamename}" + fi +} + +# Fixes: server not always creating steam_appid.txt file. if [ -d "${rootdir}/.local/share/Arma\ 3" ]; then + local fixname="20150 Segmentation fault (core dumped)" + fn_fix_steamcmd_msg_start mkdir -p "${rootdir}/.local/share/Arma\ 3" -fi + fn_fix_steamcmd_msg_end +fi \ No newline at end of file From 3da6d7eb602eb0dbb420ef569e9c577d4673e06d Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 20:10:53 +0000 Subject: [PATCH 12/18] merged install fixes to fix.sh --- functions/command_install.sh | 12 +---- functions/core_functions.sh | 47 +++++++++---------- functions/fix.sh | 17 ++++++- functions/{install_fix_kf.sh => fix_kf.sh} | 2 +- functions/{install_fix_ro.sh => fix_ro.sh} | 2 +- .../{install_fix_ut2k4.sh => fix_ut2k4.sh} | 2 +- .../{install_fix_ut99.sh => fix_ut99.sh} | 2 +- functions/install_fix_steam.sh | 43 ----------------- 8 files changed, 41 insertions(+), 86 deletions(-) rename functions/{install_fix_kf.sh => fix_kf.sh} (94%) rename functions/{install_fix_ro.sh => fix_ro.sh} (94%) rename functions/{install_fix_ut2k4.sh => fix_ut2k4.sh} (94%) rename functions/{install_fix_ut99.sh => fix_ut99.sh} (95%) delete mode 100644 functions/install_fix_steam.sh diff --git a/functions/command_install.sh b/functions/command_install.sh index 0ebea8caa..75e6c0060 100644 --- a/functions/command_install.sh +++ b/functions/command_install.sh @@ -23,28 +23,18 @@ elif [ "${gamename}" == "Teamspeak 3" ]; then elif [ ! -z "${appid}" ]; then install_steamcmd.sh install_serverfiles.sh - fix.sh fi # Configuration -fix_glibc.sh +fix.sh install_logs.sh install_gsquery.sh install_config.sh if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then install_gslt.sh - fix_csgo.sh elif [ "${gamename}" == "Teamspeak 3" ]; then install_ts3db.sh elif [ "${gamename}" == "Team Fortress 2" ]; then install_gslt.sh -elif [ "${gamename}" == "Killing Floor" ]; then - install_fix_kf.sh -elif [ "${gamename}" == "Red Orchestra: Ostfront 41-45" ]; then - install_fix_ro.sh -elif [ "${gamename}" == "Unreal Tournament 2004" ]; then - install_fix_ut2k4.sh -elif [ "${gamename}" == "Unreal Tournament 99" ]; then - install_fix_ut99.sh fi install_complete.sh diff --git a/functions/core_functions.sh b/functions/core_functions.sh index 41e86824d..66a99d52a 100644 --- a/functions/core_functions.sh +++ b/functions/core_functions.sh @@ -190,6 +190,26 @@ functionfile="${FUNCNAME}" fn_runfunction } +fix_glibc.sh(){ +functionfile="${FUNCNAME}" +fn_runfunction +} + +fix_ro.sh(){ +functionfile="${FUNCNAME}" +fn_runfunction +} + +fix_kf.sh(){ +functionfile="${FUNCNAME}" +fn_runfunction +} + +fix_ut2k4.sh(){ +functionfile="${FUNCNAME}" +fn_runfunction +} + # Info @@ -279,11 +299,6 @@ functionfile="${FUNCNAME}" fn_runfunction } -fix_glibc.sh(){ -functionfile="${FUNCNAME}" -fn_runfunction -} - install_gsquery.sh(){ functionfile="${FUNCNAME}" fn_runfunction @@ -299,11 +314,6 @@ functionfile="${FUNCNAME}" fn_runfunction } -install_fix_kf.sh(){ -functionfile="${FUNCNAME}" -fn_runfunction -} - install_logs.sh(){ functionfile="${FUNCNAME}" fn_runfunction @@ -314,11 +324,6 @@ functionfile="${FUNCNAME}" fn_runfunction } -install_fix_ro.sh(){ -functionfile="${FUNCNAME}" -fn_runfunction -} - install_serverdir.sh(){ functionfile="${FUNCNAME}" fn_runfunction @@ -333,11 +338,6 @@ functionfile="${FUNCNAME}" fn_runfunction } -install_fix_steam.sh(){ -functionfile="${FUNCNAME}" -fn_runfunction -} - install_ts3.sh(){ functionfile="${FUNCNAME}" fn_runfunction @@ -353,11 +353,6 @@ functionfile="${FUNCNAME}" fn_runfunction } -install_fix_ut2k4.sh(){ -functionfile="${FUNCNAME}" -fn_runfunction -} - install_ut2k4_key.sh(){ functionfile="${FUNCNAME}" fn_runfunction @@ -373,7 +368,7 @@ functionfile="${FUNCNAME}" fn_runfunction } -install_fix_ut99.sh(){ +fix_ut99.sh(){ functionfile="${FUNCNAME}" fn_runfunction } diff --git a/functions/fix.sh b/functions/fix.sh index 4659831e6..44472ea71 100644 --- a/functions/fix.sh +++ b/functions/fix.sh @@ -2,7 +2,7 @@ # LGSM fix.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com -lgsm_version="291215" +lgsm_version="301215" # Description: Overall function for managing fixes. # Runs functions that will fix an issue. @@ -18,4 +18,17 @@ elif [ "${gamename}" == "Insurgency" ]; then fix_ins.sh elif [ "${gamename}" == "ARMA 3" ]; then fix_arma3.sh -fi \ No newline at end of file +fi + +if [ "${function_selfname}" == "command_install.sh" ]; then + fix_glibc.sh + if [ "${gamename}" == "Killing Floor" ]; then + fix_kf.sh + elif [ "${gamename}" == "Red Orchestra: Ostfront 41-45" ]; then + fix_ro.sh + elif [ "${gamename}" == "Unreal Tournament 2004" ]; then + fix_ut2k4.sh + elif [ "${gamename}" == "Unreal Tournament 99" ]; then + fix_ut99.sh + fi +fi diff --git a/functions/install_fix_kf.sh b/functions/fix_kf.sh similarity index 94% rename from functions/install_fix_kf.sh rename to functions/fix_kf.sh index 324602ff5..23529d78c 100644 --- a/functions/install_fix_kf.sh +++ b/functions/fix_kf.sh @@ -1,5 +1,5 @@ #!/bin/bash -# LGSM install_fix_kf.sh function +# LGSM fix_kf.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com lgsm_version="271215" diff --git a/functions/install_fix_ro.sh b/functions/fix_ro.sh similarity index 94% rename from functions/install_fix_ro.sh rename to functions/fix_ro.sh index 2fe53cb4f..4ff8c8b64 100644 --- a/functions/install_fix_ro.sh +++ b/functions/fix_ro.sh @@ -1,5 +1,5 @@ #!/bin/bash -# LGSM install_fix_ro.sh function +# LGSM fix_ro.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com lgsm_version="271215" diff --git a/functions/install_fix_ut2k4.sh b/functions/fix_ut2k4.sh similarity index 94% rename from functions/install_fix_ut2k4.sh rename to functions/fix_ut2k4.sh index e6b321463..486d38ce6 100644 --- a/functions/install_fix_ut2k4.sh +++ b/functions/fix_ut2k4.sh @@ -1,5 +1,5 @@ #!/bin/bash -# LGSM install_fix_ut2k4.sh function +# LGSM fix_ut2k4.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com lgsm_version="271215" diff --git a/functions/install_fix_ut99.sh b/functions/fix_ut99.sh similarity index 95% rename from functions/install_fix_ut99.sh rename to functions/fix_ut99.sh index dd16f921b..d6d0c7806 100644 --- a/functions/install_fix_ut99.sh +++ b/functions/fix_ut99.sh @@ -1,5 +1,5 @@ #!/bin/bash -# LGSM install_fix_ut99.sh function +# LGSM fix_ut99.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com lgsm_version="271215" diff --git a/functions/install_fix_steam.sh b/functions/install_fix_steam.sh deleted file mode 100644 index d3e329a80..000000000 --- a/functions/install_fix_steam.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/bash -# LGSM install_fix_steam.sh function -# Author: Daniel Gibbs -# Website: http://gameservermanagers.com -lgsm_version="271215" - -fn_steamclientfix(){ -echo "" -echo "Applying steamclient.so fix" -echo "=================================" -sleep 1 -# Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam,or a local steamclient.so. -mkdir -pv "${HOME}/.steam/sdk32" -cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" -sleep 1 -} - -# Server specific -fn_libsteamfix(){ -echo "" -echo "Applying libsteam.so and steamclient.so fixes" -echo "=================================" -sleep 1 -if [ "${gamename}" == "Garry's Mod" ]; then - # Fixes: .steam/sdk32/libsteam.so: cannot open shared object file: No such file or directory - mkdir -pv "${HOME}/.steam/sdk32" - cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" -elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then - # Fixes: .steam/bin32/libsteam.so: cannot open shared object file: No such file or directory - mkdir -pv "${HOME}/.steam/bin32" - cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" -elif [ "${gamename}" == "Hurtworld" ]; then - # Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so. - cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" - cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" -fi -sleep 1 -} - -fn_steamclientfix -if [ "${gamename}" == "Garry's Mod" ]||[ "${gamename}" == "Serious Sam 3: BFE" ]||[ "${gamename}" == "Hurtworld" ]; then - fn_libsteamfix -fi From beb21dd117901e42cca61d347cfa1d57668cafd3 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 20:15:41 +0000 Subject: [PATCH 13/18] Added installer menu --- functions/fix.sh | 2 ++ functions/fix_ro.sh | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/functions/fix.sh b/functions/fix.sh index 44472ea71..668ce425e 100644 --- a/functions/fix.sh +++ b/functions/fix.sh @@ -22,6 +22,8 @@ fi if [ "${function_selfname}" == "command_install.sh" ]; then fix_glibc.sh + echo "Applying ${gamename} Server Fixes" + echo "=================================" if [ "${gamename}" == "Killing Floor" ]; then fix_kf.sh elif [ "${gamename}" == "Red Orchestra: Ostfront 41-45" ]; then diff --git a/functions/fix_ro.sh b/functions/fix_ro.sh index 4ff8c8b64..37893176a 100644 --- a/functions/fix_ro.sh +++ b/functions/fix_ro.sh @@ -6,12 +6,12 @@ lgsm_version="271215" echo "Applying ${gamename} Server Fixes" echo "=================================" -echo "Applying WebAdmin ROOst.css fix!" +echo "Applying WebAdmin ROOst.css fix." echo "http://forums.tripwireinteractive.com/showpost.php?p=585435&postcount=13" sed -i 's/none}/none;/g' "${filesdir}/Web/ServerAdmin/ROOst.css" sed -i 's/underline}/underline;/g' "${filesdir}/Web/ServerAdmin/ROOst.css" sleep 1 -echo "Applying WebAdmin CharSet fix!" +echo "Applying WebAdmin CharSet fix." echo "http://forums.tripwireinteractive.com/showpost.php?p=442340&postcount=1" sed -i 's/CharSet="iso-8859-1"/CharSet="utf-8"/g' "${systemdir}/uweb.int" sleep 1 From 0bb4cd77ada8f6abf6fba03d5b3a903ead9ebfdf Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 20:31:47 +0000 Subject: [PATCH 14/18] Adjusted install menu for fixes --- functions/command_install.sh | 4 ++++ functions/fix.sh | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/functions/command_install.sh b/functions/command_install.sh index 75e6c0060..0a241d4fc 100644 --- a/functions/command_install.sh +++ b/functions/command_install.sh @@ -26,7 +26,11 @@ elif [ ! -z "${appid}" ]; then fi # Configuration +echo "" +echo "Applying ${gamename} Server Fixes" +echo "=================================" fix.sh +echo "" install_logs.sh install_gsquery.sh install_config.sh diff --git a/functions/fix.sh b/functions/fix.sh index 668ce425e..44472ea71 100644 --- a/functions/fix.sh +++ b/functions/fix.sh @@ -22,8 +22,6 @@ fi if [ "${function_selfname}" == "command_install.sh" ]; then fix_glibc.sh - echo "Applying ${gamename} Server Fixes" - echo "=================================" if [ "${gamename}" == "Killing Floor" ]; then fix_kf.sh elif [ "${gamename}" == "Red Orchestra: Ostfront 41-45" ]; then From 8f851c5ed36303f4593b122450f8b04265231c2f Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 20:43:58 +0000 Subject: [PATCH 15/18] start fixes and install fixes kept apart. --- functions/command_debug.sh | 1 + functions/fix.sh | 27 +++++++++++++++++---------- functions/fix_kf.sh | 2 -- functions/fix_ro.sh | 2 -- functions/fix_ut2k4.sh | 2 -- functions/fix_ut99.sh | 2 -- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/functions/command_debug.sh b/functions/command_debug.sh index 91f91dd66..097ddf289 100644 --- a/functions/command_debug.sh +++ b/functions/command_debug.sh @@ -10,6 +10,7 @@ local modulename="Debug" function_selfname="$(basename $(readlink -f "${BASH_SOURCE[0]}"))" check.sh +fix.sh info_distro.sh fn_parms echo "" diff --git a/functions/fix.sh b/functions/fix.sh index 44472ea71..6c7ef34c4 100644 --- a/functions/fix.sh +++ b/functions/fix.sh @@ -7,21 +7,28 @@ lgsm_version="301215" # Description: Overall function for managing fixes. # Runs functions that will fix an issue. -if [ ! -z "${appid}" ]; then - fix_steamcmd.sh -fi +# Fixes that are run on start +if [ "${function_selfname}" != "command_install.sh" ]; then + if [ ! -z "${appid}" ]; then + fix_steamcmd.sh + fi -if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then - startfix=1 - fix_csgo.sh -elif [ "${gamename}" == "Insurgency" ]; then - fix_ins.sh -elif [ "${gamename}" == "ARMA 3" ]; then - fix_arma3.sh + if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then + startfix=1 + fix_csgo.sh + elif [ "${gamename}" == "Insurgency" ]; then + fix_ins.sh + elif [ "${gamename}" == "ARMA 3" ]; then + fix_arma3.sh + fi fi +# Fixes that are run on install only. if [ "${function_selfname}" == "command_install.sh" ]; then fix_glibc.sh + echo "" + echo "Applying ${gamename} Server Fixes" + echo "=================================" if [ "${gamename}" == "Killing Floor" ]; then fix_kf.sh elif [ "${gamename}" == "Red Orchestra: Ostfront 41-45" ]; then diff --git a/functions/fix_kf.sh b/functions/fix_kf.sh index 23529d78c..7e77ca8e6 100644 --- a/functions/fix_kf.sh +++ b/functions/fix_kf.sh @@ -4,8 +4,6 @@ # Website: http://gameservermanagers.com lgsm_version="271215" -echo "Applying ${gamename} Server Fixes" -echo "=================================" echo "Applying WebAdmin ROOst.css fix." echo "http://forums.tripwireinteractive.com/showpost.php?p=585435&postcount=13" sed -i 's/none}/none;/g' "${filesdir}/Web/ServerAdmin/ROOst.css" diff --git a/functions/fix_ro.sh b/functions/fix_ro.sh index 37893176a..d3d0ac0e2 100644 --- a/functions/fix_ro.sh +++ b/functions/fix_ro.sh @@ -4,8 +4,6 @@ # Website: http://gameservermanagers.com lgsm_version="271215" -echo "Applying ${gamename} Server Fixes" -echo "=================================" echo "Applying WebAdmin ROOst.css fix." echo "http://forums.tripwireinteractive.com/showpost.php?p=585435&postcount=13" sed -i 's/none}/none;/g' "${filesdir}/Web/ServerAdmin/ROOst.css" diff --git a/functions/fix_ut2k4.sh b/functions/fix_ut2k4.sh index 486d38ce6..b9ec4ad8a 100644 --- a/functions/fix_ut2k4.sh +++ b/functions/fix_ut2k4.sh @@ -4,8 +4,6 @@ # Website: http://gameservermanagers.com lgsm_version="271215" -echo "Applying ${gamename} Server Fixes" -echo "=================================" echo "applying WebAdmin ut2003.css fix." echo "http://forums.tripwireinteractive.com/showpost.php?p=585435&postcount=13" sed -i 's/none}/none;/g' "${filesdir}/Web/ServerAdmin/ut2003.css" diff --git a/functions/fix_ut99.sh b/functions/fix_ut99.sh index d6d0c7806..d4ceca37f 100644 --- a/functions/fix_ut99.sh +++ b/functions/fix_ut99.sh @@ -4,8 +4,6 @@ # Website: http://gameservermanagers.com lgsm_version="271215" -echo "Applying ${gamename} Server Fixes" -echo "=================================" echo "enabling UdpServerUplink." { echo "[IpServer.UdpServerUplink]" From f74be89e1c03a926133d429c3252b479dd7f6bd8 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 20:47:38 +0000 Subject: [PATCH 16/18] removed server fixes menu --- functions/command_install.sh | 4 ---- 1 file changed, 4 deletions(-) diff --git a/functions/command_install.sh b/functions/command_install.sh index 0a241d4fc..75e6c0060 100644 --- a/functions/command_install.sh +++ b/functions/command_install.sh @@ -26,11 +26,7 @@ elif [ ! -z "${appid}" ]; then fi # Configuration -echo "" -echo "Applying ${gamename} Server Fixes" -echo "=================================" fix.sh -echo "" install_logs.sh install_gsquery.sh install_config.sh From d0b4d226c4b6bcb961659b593a3456904183fba4 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 20:52:44 +0000 Subject: [PATCH 17/18] Made titles more consistant --- functions/fix.sh | 1 + functions/install_dl_ut2k4.sh | 2 ++ functions/install_dl_ut99.sh | 2 ++ functions/install_serverdir.sh | 1 + functions/install_steamcmd.sh | 1 + functions/install_ts3db.sh | 1 + functions/install_ut2k4.sh | 1 + functions/install_ut2k4_key.sh | 1 + functions/install_ut99.sh | 1 + 9 files changed, 11 insertions(+) diff --git a/functions/fix.sh b/functions/fix.sh index 6c7ef34c4..0e2ac763b 100644 --- a/functions/fix.sh +++ b/functions/fix.sh @@ -29,6 +29,7 @@ if [ "${function_selfname}" == "command_install.sh" ]; then echo "" echo "Applying ${gamename} Server Fixes" echo "=================================" + sleep 1 if [ "${gamename}" == "Killing Floor" ]; then fix_kf.sh elif [ "${gamename}" == "Red Orchestra: Ostfront 41-45" ]; then diff --git a/functions/install_dl_ut2k4.sh b/functions/install_dl_ut2k4.sh index d8c930fa6..687867e74 100644 --- a/functions/install_dl_ut2k4.sh +++ b/functions/install_dl_ut2k4.sh @@ -4,8 +4,10 @@ # Website: http://gameservermanagers.com lgsm_version="271215" +echo "" echo "Downloading Server Files" echo "=================================" +sleep 1 cd "${filesdir}" if [ ! -f dedicatedserver3339-bonuspack.zip ]; then wget http://gameservermanagers.com/files/ut2004/dedicatedserver3339-bonuspack.zip diff --git a/functions/install_dl_ut99.sh b/functions/install_dl_ut99.sh index d77598d07..c053ca18e 100644 --- a/functions/install_dl_ut99.sh +++ b/functions/install_dl_ut99.sh @@ -4,8 +4,10 @@ # Website: http://gameservermanagers.com lgsm_version="271215" +echo "" echo "Downloading Server Files" echo "=================================" +sleep 1 cd "${filesdir}" if [ ! -f ut-server-436.tar.gz ]; then wget http://gameservermanagers.com/files/ut99/ut-server-436.tar.gz diff --git a/functions/install_serverdir.sh b/functions/install_serverdir.sh index fb9f713b6..2c664e8e3 100644 --- a/functions/install_serverdir.sh +++ b/functions/install_serverdir.sh @@ -7,6 +7,7 @@ lgsm_version="271215" echo "" echo "Server Directory" echo "=================================" +sleep 1 echo "" pwd echo "" diff --git a/functions/install_steamcmd.sh b/functions/install_steamcmd.sh index 094310191..fe944a253 100644 --- a/functions/install_steamcmd.sh +++ b/functions/install_steamcmd.sh @@ -9,6 +9,7 @@ lgsm_version="271215" echo "" echo "Installing SteamCMD" echo "=================================" +sleep 1 steamcmddir="${rootdir}/steamcmd" if [ ! -f "${steamcmddir}/steamcmd.sh" ]; then if [ ! -d "${steamcmddir}" ]; then diff --git a/functions/install_ts3db.sh b/functions/install_ts3db.sh index f7654ce07..57c87b97d 100644 --- a/functions/install_ts3db.sh +++ b/functions/install_ts3db.sh @@ -9,6 +9,7 @@ fn_install_ts3db_mariadb(){ echo "" echo "checking if libmariadb2 is installed" echo "=================================" + sleep 1 ldd ${filesdir}/libts3db_mariadb.so | grep "libmariadb.so.2 => not found" if [ $? -eq 0 ]; then echo "libmariadb2 not installed. Please install it first." diff --git a/functions/install_ut2k4.sh b/functions/install_ut2k4.sh index fe4e428e4..44d78b885 100644 --- a/functions/install_ut2k4.sh +++ b/functions/install_ut2k4.sh @@ -4,6 +4,7 @@ # Website: http://gameservermanagers.com lgsm_version="271215" +echo "" echo "Installing ${gamename} Server" echo "=================================" sleep 1 diff --git a/functions/install_ut2k4_key.sh b/functions/install_ut2k4_key.sh index 10143a736..35a9599f6 100644 --- a/functions/install_ut2k4_key.sh +++ b/functions/install_ut2k4_key.sh @@ -4,6 +4,7 @@ # Website: http://gameservermanagers.com lgsm_version="271215" +echo "" echo "Enter ${gamename} CD Key" echo "=================================" sleep 1 diff --git a/functions/install_ut99.sh b/functions/install_ut99.sh index c1b5a91a5..32b49f7a1 100644 --- a/functions/install_ut99.sh +++ b/functions/install_ut99.sh @@ -4,6 +4,7 @@ # Website: http://gameservermanagers.com lgsm_version="271215" +echo "" echo "Installing ${gamename} Server" echo "=================================" sleep 1 From dbc0832894141c030cd0e9fe929591412a289d8e Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 30 Dec 2015 20:57:27 +0000 Subject: [PATCH 18/18] renamed function --- functions/fix_arma3.sh | 8 ++++---- functions/fix_csgo.sh | 20 ++++++++++---------- functions/fix_steamcmd.sh | 24 ++++++++++++------------ 3 files changed, 26 insertions(+), 26 deletions(-) diff --git a/functions/fix_arma3.sh b/functions/fix_arma3.sh index c6b6ece0c..75db601a9 100644 --- a/functions/fix_arma3.sh +++ b/functions/fix_arma3.sh @@ -6,7 +6,7 @@ lgsm_version="301215" # Fixes line 63: 20150 Segmentation fault (core dumped) #488 -fn_fix_steamcmd_msg_start(){ +fn_msg_start(){ fn_printdots "Applying ${fixname} fix: ${gamename}" sleep 1 fn_printinfo "Applying ${fixname} fix: ${gamename}" @@ -14,7 +14,7 @@ fn_fix_steamcmd_msg_start(){ sleep 1 } -fn_fix_steamcmd_msg_end(){ +fn_msg_end(){ if [ $? -ne 0 ]; then fn_printfailnl "Applying ${fixname} fix: ${gamename}" fn_scriptlog "Failure! Applying ${fixname} fix: ${gamename}" @@ -27,7 +27,7 @@ fn_fix_steamcmd_msg_end(){ # Fixes: server not always creating steam_appid.txt file. if [ -d "${rootdir}/.local/share/Arma\ 3" ]; then local fixname="20150 Segmentation fault (core dumped)" - fn_fix_steamcmd_msg_start + fn_msg_start mkdir -p "${rootdir}/.local/share/Arma\ 3" - fn_fix_steamcmd_msg_end + fn_msg_end fi \ No newline at end of file diff --git a/functions/fix_csgo.sh b/functions/fix_csgo.sh index 084fd70d3..4227d36eb 100644 --- a/functions/fix_csgo.sh +++ b/functions/fix_csgo.sh @@ -6,7 +6,7 @@ lgsm_version="301215" # Description: Resolves various issues with csgo. -fn_fix_steamcmd_msg_start(){ +fn_msg_start(){ fn_printdots "Applying ${fixname} fix: ${gamename}" sleep 1 fn_printinfo "Applying ${fixname} fix: ${gamename}" @@ -14,7 +14,7 @@ fn_fix_steamcmd_msg_start(){ sleep 1 } -fn_fix_steamcmd_msg_end(){ +fn_msg_end(){ if [ $? -ne 0 ]; then fn_printfailnl "Applying ${fixname} fix: ${gamename}" fn_scriptlog "Failure! Applying ${fixname} fix: ${gamename}" @@ -27,35 +27,35 @@ fn_fix_steamcmd_msg_end(){ # Fixes: server not always creating steam_appid.txt file. if [ ! -f "${filesdir}/steam_appid.txt" ]; then local fixname="730 steam_appid.txt" - fn_fix_steamcmd_msg_start + fn_msg_start echo -n "730" >> "${filesdir}/steam_appid.txt" - fn_fix_steamcmd_msg_end + fn_msg_end fi # Fixes: Error parsing BotProfile.db - unknown attribute 'Rank'". if ! grep -q "//Rank" "${systemdir}/botprofile.db" > /dev/null 2>&1; then local fixname="botprofile.db" - fn_fix_steamcmd_msg_start + fn_msg_start sed -i 's/\tRank/\t\/\/Rank/g' "${systemdir}/botprofile.db" > /dev/null 2>&1 - fn_fix_steamcmd_msg_end + fn_msg_end fi # Fixes: Unknown command "cl_bobamt_vert". if ! grep -q "//exec default" "${servercfgdir}/valve.rc" > /dev/null 2>&1 || ! grep -q "//exec joystick" "${servercfgdir}/valve.rc" > /dev/null 2>&1; then local fixname="valve.rc" - fn_fix_steamcmd_msg_start + fn_msg_start sed -i 's/exec default.cfg/\/\/exec default.cfg/g' "${servercfgdir}/valve.rc" > /dev/null 2>&1 sed -i 's/exec joystick.cfg/\/\/exec joystick.cfg/g' "${servercfgdir}/valve.rc" > /dev/null 2>&1 - fn_fix_steamcmd_msg_end + fn_msg_end fi # Fixes: workshop map issue. # http://forums.steampowered.com/forums/showthread.php?t=3170366. if [ -f "${systemdir}/subscribed_collection_ids.txt" ]||[ -f "${systemdir}/subscribed_file_ids.txt" ]||[ -f "${systemdir}/ugc_collection_cache.txt" ]; then local fixname="workshop map" - fn_fix_steamcmd_msg_start + fn_msg_start rm -f "${systemdir}/subscribed_collection_ids.txt" rm -f "${systemdir}/subscribed_file_ids.txt" rm -f "${systemdir}/ugc_collection_cache.txt" - fn_fix_steamcmd_msg_end + fn_msg_end fi \ No newline at end of file diff --git a/functions/fix_steamcmd.sh b/functions/fix_steamcmd.sh index 070ce7165..410574263 100644 --- a/functions/fix_steamcmd.sh +++ b/functions/fix_steamcmd.sh @@ -6,7 +6,7 @@ lgsm_version="301215" # Description: fixes various issues related to steamCMD. -fn_fix_steamcmd_msg_start(){ +fn_msg_start(){ fn_printdots "Applying ${fixname} fix: ${gamename}" sleep 1 fn_printinfo "Applying ${fixname} fix: ${gamename}" @@ -14,7 +14,7 @@ fn_fix_steamcmd_msg_start(){ sleep 1 } -fn_fix_steamcmd_msg_end(){ +fn_msg_end(){ if [ $? -ne 0 ]; then fn_printfailnl "Applying ${fixname} fix: ${gamename}" fn_scriptlog "Failure! Applying ${fixname} fix: ${gamename}" @@ -28,43 +28,43 @@ fn_fix_steamcmd_msg_end(){ # Fixes: [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 local fixname="steamclient.so general" - fn_fix_steamcmd_msg_start + fn_msg_start mkdir -pv "${HOME}/.steam/sdk32" >> "${scriptlog}" cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" >> "${scriptlog}" - fn_fix_steamcmd_msg_end + fn_msg_end fi if [ "${gamename}" == "Garry's Mod" ]; then # Fixes: .steam/sdk32/libsteam.so: cannot open shared object file: No such file or directory if [ ! -f "${HOME}/.steam/sdk32/libsteam.so" ]; then local fixname="libsteam.so" - fn_fix_steamcmd_msg_start + fn_msg_start mkdir -pv "${HOME}/.steam/sdk32" >> "${scriptlog}" cp -v "${filesdir}/bin/libsteam.so" "${HOME}/.steam/sdk32/libsteam.so" >> "${scriptlog}" - fn_fix_steamcmd_msg_end + fn_msg_end fi elif [ "${gamename}" == "Serious Sam 3: BFE" ]; then # Fixes: .steam/bin32/libsteam.so: cannot open shared object file: No such file or directory if [ ! -f "${HOME}/.steam/bin32/libsteam.so" ]; then local fixname="libsteam.so" - fn_fix_steamcmd_msg_start + fn_msg_start mkdir -pv "${HOME}/.steam/bin32" >> "${scriptlog}" cp -v "${filesdir}/Bin/libsteam.so" "${HOME}/.steam/bin32/libsteam.so" >> "${scriptlog}" - fn_fix_steamcmd_msg_end + fn_msg_end fi elif [ "${gamename}" == "Hurtworld" ]; then # Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so. if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" ]; then local fixname="steamclient.so x86" - fn_fix_steamcmd_msg_start + fn_msg_start cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86/steamclient.so" >> "${scriptlog}" - fn_fix_steamcmd_msg_end + fn_msg_end fi if [ ! -f "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" ]; then local fixname="steamclient.so x86_64" - fn_fix_steamcmd_msg_start + fn_msg_start cp -v "${rootdir}/steamcmd/linux32/steamclient.so" "${filesdir}/Hurtworld_Data/Plugins/x86_64/steamclient.so" >> "${scriptlog}" - fn_fix_steamcmd_msg_end + fn_msg_end fi fi