diff --git a/minecraft/start.sh b/minecraft/start.sh index 18137b7..2b401e7 100644 --- a/minecraft/start.sh +++ b/minecraft/start.sh @@ -11,7 +11,7 @@ get_paper_server() { MC_VERSION="1.20.4" fi majorVersion=$MC_VERSION - PAPER_BUILD_JSON=$(curl -X GET -s "https://api.papermc.io/v2/projects/paper/versions/1.20.4/builds") + PAPER_BUILD_JSON=$(curl -X GET -s "https://api.papermc.io/v2/projects/paper/versions/${MC_VERSION}/builds") PAPER_BUILD_FILENAME=$(jq -n "$PAPER_BUILD_JSON" | jq -jc '.builds[-1].downloads.application.name') PAPER_BUILD_NUMBER=$(jq -n "$PAPER_BUILD_JSON" | jq '.builds[-1].build') PAPER_BUILD_DOWNLOAD_URL="https://api.papermc.io/v2/projects/paper/versions/${MC_VERSION}/builds/${PAPER_BUILD_NUMBER}/downloads/${PAPER_BUILD_FILENAME}" @@ -116,4 +116,4 @@ fi java -Xms$RAM -Xmx$RAM -XX:+AlwaysPreTouch -XX:+DisableExplicitGC -XX:+ParallelRefProcEnabled -XX:+PerfDisableSharedMem -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1HeapRegionSize=8M -XX:G1HeapWastePercent=5 -XX:G1MaxNewSizePercent=40 -XX:G1MixedGCCountTarget=4 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1NewSizePercent=30 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:G1ReservePercent=20 -XX:InitiatingHeapOccupancyPercent=15 -XX:MaxGCPauseMillis=200 -XX:MaxTenuringThreshold=1 -XX:SurvivorRatio=32 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true -jar server.jar nogui -sleep 10 \ No newline at end of file +sleep 10