Просмотр исходного кода

Merge branch 'master' into develop

Daniel Gibbs 4 лет назад
Родитель
Сommit
c83cb06949

+ 1 - 2
CONTRIBUTING.md

@@ -48,8 +48,7 @@ Before creating bug reports, please check [this list](https://github.com/GameSer
 #### Before Submitting A Bug Report
 
 * **Check the [documentation](https://docs.linuxgsm.com).** You might be able to find the cause of the problem and fix things yourself.
-* **Check that the problem is not related to** [**support page**](https://linuxgsm/com/support) for links to other support options.
-* **Check the** [**support page**](https://linuxgsm/com/support) for links to other support options.
+* **Check the** [**support page**](https://linuxgsm.com/support) for links to other support options.
 * **Perform a** [**cursory search**](https://github.com/search?q=org:GameServerManagers%20type:issues&type=Issues) to see if the problem has already been reported. If it has **and the issue is still open**, add a comment to the existing issue and give it a thumbs up instead of opening a new one.
 
 #### How Do I Submit A (Good) Bug Report?

+ 1 - 1
lgsm/functions/core_functions.sh

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

+ 5 - 2
lgsm/functions/update_minecraft_bedrock.sh

@@ -7,8 +7,11 @@
 
 functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
 
+#random number for userAgent
+randnum=$((1 + RANDOM % 5000))
+
 fn_update_minecraft_dl(){
-	latestmcbuildurl=$(curl -Ls "https://www.minecraft.net/en-us/download/server/bedrock/" | grep -o 'https://minecraft.azureedge.net/bin-linux/[^"]*zip')
+	latestmcbuildurl=$(curl -H "Accept-Encoding: identity" -H "Accept-Language: en" -Ls -A "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.${randnum}.212 Safari/537.36" "https://www.minecraft.net/en-us/download/server/bedrock/" | grep -o 'https://minecraft.azureedge.net/bin-linux/[^"]*zip')
 	fn_fetch_file "${latestmcbuildurl}" "" "" "" "${tmpdir}" "bedrock_server.${remotebuild}.zip"
 	echo -e "Extracting to ${serverfiles}...\c"
 	if [ "${firstcommandname}" == "INSTALL" ]; then
@@ -79,7 +82,7 @@ fn_update_minecraft_localbuild(){
 
 fn_update_minecraft_remotebuild(){
 	# Gets remote build info.
-	remotebuild=$(curl -Ls "https://www.minecraft.net/en-us/download/server/bedrock/" | grep -o 'https://minecraft.azureedge.net/bin-linux/[^"]*' | sed 's/.*\///' | grep -Eo "[.0-9]+[0-9]")
+	remotebuild=$(curl -H "Accept-Encoding: identity" -H "Accept-Language: en" -Ls -A "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.${randnum}.212 Safari/537.36" "https://www.minecraft.net/en-us/download/server/bedrock/" | grep -o 'https://minecraft.azureedge.net/bin-linux/[^"]*' | sed 's/.*\///' | grep -Eo "[.0-9]+[0-9]")
 	if [ "${firstcommandname}" != "INSTALL" ]; then
 		fn_print_dots "Checking remote build: ${remotelocation}"
 		# Checks if remotebuild variable has been set.

+ 1 - 1
linuxgsm.sh

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

+ 1 - 1
tests/tests_fctrserver.sh

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

+ 1 - 1
tests/tests_jc2server.sh

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

+ 1 - 1
tests/tests_mcserver.sh

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

+ 1 - 1
tests/tests_ts3server.sh

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