From 42835dc2a970d11698200a9fabf052f223645469 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Sat, 15 Jan 2022 05:17:38 -0500 Subject: [PATCH] Updated Swamp installer and update script. --- audiogame-manager.sh | 5 ++--- game-scripts/swamp-update.sh | 9 +++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 8876730..ec1b833 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2183,9 +2183,8 @@ EOF export winVer="win7" export winetricksSettings="vd=1024x768" install_wine_bottle dx8vb quartz corefonts vb6run speechsdk - download "https://kaldobsky.com/audiogames/SwampPart1.zip" "https://kaldobsky.com/audiogames/SwampPart2.zip" - unzip -d "$WINEPREFIX/drive_c/Program Files/swamp" "${cache}/SwampPart1.zip" - unzip -d "$WINEPREFIX/drive_c/Program Files/swamp" "${cache}/SwampPart2.zip" + download "https://www.kaldobsky.com/audiogames/Swamp.zip" + unzip -d "$WINEPREFIX/drive_c/Program Files/swamp" "${cache}/Swamp.zip" # make sure the latest version is installed. if wget -O "${cache}/SwampPatch.zip" "https://www.kaldobsky.com/audiogames/SwampPatch.zip" ; then unzip -o -d "$WINEPREFIX/drive_c/Program Files/swamp" "${cache}/SwampPatch.zip" diff --git a/game-scripts/swamp-update.sh b/game-scripts/swamp-update.sh index cd8bfa8..b8c9128 100755 --- a/game-scripts/swamp-update.sh +++ b/game-scripts/swamp-update.sh @@ -37,10 +37,11 @@ # Works which are defined in the CPAL as a work which combines Covered Code # or portions thereof with code not governed by the terms of the CPAL. -updateURL="https://www.kaldobsky.com/audiogames/SwampPatch.zip" +cache="${XDG_CONFIG_HOME:-$HOME/.config}/storm-games/audiogame-manager/cache" +updateURL="https://www.kaldobsky.com/audiogames/Swamp.zip" extract_error() { - echo "There was an error extracting the patch." + echo "There was an error extracting the zip file." exit 1 } @@ -53,7 +54,7 @@ trap popd EXIT echo "Checking for Swamp updates..." -# Check for and download new patches. +# Check for and download new versions. update="$(wget -N "${updateURL}" 2>&1 | grep "not modified on server")" if [ -n "${update}" ]; then @@ -64,7 +65,7 @@ fi echo "Updating Swamp..." # Unzip the new patch -unzip -o SwampPatch.zip || extract_error +unzip -o Swamp.zip || extract_error echo "Swamp has been updated."