Przeglądaj źródła

Fixed legacy scripts unable to create tmpdir

Daniel Gibbs 8 lat temu
rodzic
commit
2834685a01
2 zmienionych plików z 11 dodań i 3 usunięć
  1. 3 3
      lgsm/functions/core_functions.sh
  2. 8 0
      lgsm/functions/core_legacy.sh

+ 3 - 3
lgsm/functions/core_functions.sh

@@ -566,14 +566,14 @@ functionfile="${FUNCNAME}"
 fn_fetch_function
 }
 
+# Calls code required for legacy servers
+core_legacy.sh
+
 # Creates tmp dir if missing
 if [ ! -d "${tmpdir}" ]; then
 	mkdir -p "${tmpdir}"
 fi
 
-# Calls code required for legacy servers
-core_legacy.sh
-
 # Calls on-screen messages (bootstrap)
 core_messages.sh
 

+ 8 - 0
lgsm/functions/core_legacy.sh

@@ -28,3 +28,11 @@ fi
 if [ -z "${steamcmddir}" ]; then
 	steamcmddir="${rootdir}/steamcmd"
 fi
+
+if [ -z "${lgsmdir}" ]; then
+	lgsmdir="${rootdir}/lgsm"
+fi
+
+if [ -z "${tmpdir}" ]; then
+	tmpdir="${lgsmdir}/tmp"
+fi