From c193d0a417ad7956b744876281704ed25418da5c Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Tue, 8 Mar 2022 03:05:32 -0500 Subject: [PATCH 01/17] Added the ability to use a settings file. See audiogame-manager -h for details. --- audiogame-manager.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index a109226..a164b9d 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -434,6 +434,14 @@ help() { for i in "${!command[@]}" ; do echo "-${i/:/ }: ${command[${i}]}" done | sort + echo + echo "Some settings that are often used can be stored in a settings.conf file." + echo "If wanted, place it at ${configFile%/*}/settings.conf." + echo "The syntax is variable=\"value\"" + echo + echo "noCache=\"true\" # Do not keep downloaded items in the cache." + echo "norh=\"true\" # Do not install RHVoice." + echo "redownload=\"true\" # Redownload sources, do not use the version stored in cache." exit 0 } @@ -1022,6 +1030,10 @@ for i in curl sox wget wine winetricks ; do done # Get latest news if available check_news +# Load any arguments from settings.conf file +if [[ -r "${configFile%/*}/settings.conf" ]]; then + source "${configFile%/*}/settings.conf" +fi # With no arguments, open the game launcher. if [[ $# -eq 0 ]]; then game_launcher From 1a826f5a7cf25e09082187146112ddbc7141ea00 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Tue, 8 Mar 2022 03:31:05 -0500 Subject: [PATCH 02/17] Improve the settings file a bit, added winedebug as an option. --- audiogame-manager.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index a164b9d..46cce1f 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -442,6 +442,7 @@ help() { echo "noCache=\"true\" # Do not keep downloaded items in the cache." echo "norh=\"true\" # Do not install RHVoice." echo "redownload=\"true\" # Redownload sources, do not use the version stored in cache." + echo "winedebug=\"flag(s)\" # Set wine debug flags, useful for development." exit 0 } @@ -829,6 +830,10 @@ cache="${XDG_CACHE_HOME:-$HOME/.cache}/audiogame-manager" configFile="${XDG_CONFIG_HOME:-$HOME/.config}/storm-games/audiogame-manager/games.conf" mkdir -p "${cache}" mkdir -p "${configFile%/*}" +# Load any arguments from settings.conf file +if [[ -r "${configFile%/*}/settings.conf" ]]; then + source "${configFile%/*}/settings.conf" +fi # Update the cache for older versions of audiogame-manager if [[ -d "${configFile%/*}/cache" ]]; then { mv -v "${configFile%/*}/cache/"* "${cache}" @@ -837,7 +842,7 @@ if [[ -d "${configFile%/*}/cache" ]]; then fi checkWinetricksUpdate="false" # Turn off debug messages -export WINEDEBUG="-all" +export WINEDEBUG="${winedebug:--all}" # Compatibility with box86 export BOX86_NOBANNER=1 # During installation, you can set winVer to the versions available. @@ -1030,10 +1035,6 @@ for i in curl sox wget wine winetricks ; do done # Get latest news if available check_news -# Load any arguments from settings.conf file -if [[ -r "${configFile%/*}/settings.conf" ]]; then - source "${configFile%/*}/settings.conf" -fi # With no arguments, open the game launcher. if [[ $# -eq 0 ]]; then game_launcher From 6dfb55a098858af317bd4b52845f132c7ff43a9a Mon Sep 17 00:00:00 2001 From: Michael Taboada Date: Tue, 8 Mar 2022 05:25:08 -0800 Subject: [PATCH 03/17] Add virtual desktop to a hero's call, it seems to work better that way --- audiogame-manager.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index a109226..aefe31e 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1078,6 +1078,7 @@ done case "${game}" in "A Hero's Call") export winVer="win7" + export winetricksSettings="vd=1024x768" install_wine_bottle speechsdk corefonts # Dotnet is evil. That is all. LC_ALL=C DISPLAY="" winetricks -q dotnet462 xna40 From d3a8ae6f4caf2ccc33f4100d24b3ca8ac6d85648 Mon Sep 17 00:00:00 2001 From: Michael Taboada Date: Wed, 9 Mar 2022 09:26:32 -0800 Subject: [PATCH 04/17] More work on entombed, still not working --- audiogame-manager.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 0e3d97f..92248fa 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1714,7 +1714,7 @@ case "${game}" in ;; "Entombed") export winVer="win7" - install_wine_bottle speechsdk msvcrt40 + install_wine_bottle speechsdk msvcrt40 gdiplus ie7 # Ok, more dotnet. LC_ALL=C DISPLAY="" winetricks -q dotnet462 wineserver -k # Sigh. @@ -1725,7 +1725,14 @@ case "${game}" in wine msiexec /i "${WINEPREFIX}/drive_c/temp/SSCERuntime_x86-ENU.msi" /q rm * popd + pushd "${WINEPREFIX}/drive_c/Program Files/Microsoft SQL Server Compact Edition/v3.5" + wine regsvr32 sqlceoledb35.dll + wine regsvr32 sqlceca35.dll + popd wine "${cache}/EntombedSetup.exe" /silent + pushd "${WINEPREFIX}/drive_c/Program Files/Entombed" + cp ../Microsoft\ SQL\ Server\ Compact\ Edition/v3.5/System.Data.SqlServerCe.Entity.dll ../Microsoft\ SQL\ Server\ Compact\ Edition/v3.5/Desktop/System.Data.SqlServerCe.dll . + popd add_launcher "c:\Program Files\Entombed\Entombed.exe" ;; "ESP Pinball Classic") From 2eba66ba5a52e70ac1d34f91bcc711ebc19061b5 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Wed, 9 Mar 2022 12:49:58 -0500 Subject: [PATCH 05/17] Updated the Scramble launcher to try to fix it not launching on the Pi and possibly Mac. --- audiogame-manager.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 92248fa..b455753 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -772,6 +772,12 @@ game_launcher() { wine "$winePath\\$wineExec" exit 0 fi + if [[ "$game" =~ scramble ]]; then + pushd "$(winepath "$winePath")" + wine "$wineExec" + popd + exit 0 + fi if [[ "$game" =~ screaming-strike-2 ]]; then pushd "$(winepath "$winePath")" wine "$wineExec" From 94324c92905dba52042ec9dee4c130ea80b040e8 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Wed, 9 Mar 2022 13:34:55 -0500 Subject: [PATCH 06/17] Revert "Updated the Scramble launcher to try to fix it not launching on the Pi and possibly Mac." because it did not work. This reverts commit 2eba66ba5a52e70ac1d34f91bcc711ebc19061b5. --- audiogame-manager.sh | 6 ------ 1 file changed, 6 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index b455753..92248fa 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -772,12 +772,6 @@ game_launcher() { wine "$winePath\\$wineExec" exit 0 fi - if [[ "$game" =~ scramble ]]; then - pushd "$(winepath "$winePath")" - wine "$wineExec" - popd - exit 0 - fi if [[ "$game" =~ screaming-strike-2 ]]; then pushd "$(winepath "$winePath")" wine "$wineExec" From 1d5a01d79c6c29a87176e7f1786ba6c84d157e94 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Fri, 11 Mar 2022 12:43:22 -0500 Subject: [PATCH 07/17] Use beautysh to format the code. --- audiogame-manager.sh | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 92248fa..c72ba5f 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash license() { -cat << EOF + cat << EOF ■The contents of this file are subject to the Common Public Attribution License Version 1.0 (the ■License■); you may not use this file except in compliance with the License. You may obtain a copy of the License at @@ -78,9 +78,9 @@ update() { local downloadFile="audiogame-manager.mac" else if [[ "$(uname -m)" == "armv7l" ]]; then - local downloadFile="audiogame-manager.arm" + local downloadFile="audiogame-manager.arm" else - local downloadFile="audiogame-manager" + local downloadFile="audiogame-manager" fi fi if [[ "$(wget --quiet -O - https://stormgames.wolfe.casa/downloads/${downloadFile} | sha256sum | cut -d ' ' -f1)" == "$(sha256sum "${filePath}" | cut -d ' ' -f1)" ]]; then @@ -106,7 +106,7 @@ open_url() { open "${*}" 2> /dev/null else xdg-open "${*}" 2> /dev/null -fi + fi } # Create desktop launcher file @@ -135,7 +135,7 @@ desktop_launcher() { 'StartupNotify=false' 'Keywords=game;' 'Categories=Game;' - 'Version=1.0') + 'Version=1.0') for i in "${dotDesktop[@]}" ; do echo "$i" >> "${desktopFile}" done @@ -147,18 +147,18 @@ desktop_launcher() { # Create the clipboard reading function for Sequence Storm write_sequence_storm_reader() { - if -e ~/.SequenceStormReader ]]; then +if -e ~/.SequenceStormReader ]]; then return fi # Here-document start cat << "EOF" > ~/.SequenceStormReader #!/usr/bin/env bash - + # Wait for the game to be launched while ! pgrep -u "$USER" ^SequenceStorm &> /dev/null ; do sleep 0.05 done - + export DISPLAY=:0 unset cliptext socketFile="$(find /tmp -maxdepth 1 -name "orca-*.sock")" @@ -195,7 +195,7 @@ while pgrep -u "$USER" ^SequenceStorm &> /dev/null ; do fi sleep 0.05 done - + exit 0 EOF # Here-document end @@ -351,7 +351,7 @@ download() { get_bottle() { # Handles games that use the same wine bottle - case "${game}" in + case "${game}" in # Aprone (Jeremy Kaldobsky) games. "castaways"*) ;& "castaways-2"*) ;& @@ -502,7 +502,7 @@ echo "Loading documentation, please wait..." fi exit 0 } - + winetricks() { # Report used packages to the winetricks maintainer so he knows they are being used. if ! [[ -e "${XDG_CACHE_HOME:-$HOME/.cache}/winetricks/track_usage" ]]; then @@ -1921,7 +1921,7 @@ case "${game}" in wine "${cache}/judgmentdayfullsetup.exe" /silent cat << EOF > /tmp/judgementday.reg Windows Registry Editor Version 5.00 - + [HKEY_CURRENT_USER\Software\VB and VBA Program Settings\judgmentday\config] "name"="$USER" EOF @@ -2310,7 +2310,7 @@ EOF ;; "Super Egg Hunt") export bottle="l-works" - install_wine_bottle + install_wine_bottle download "http://files.l-works.net/superegghuntsetup.exe" wine "${cache}/superegghuntsetup.exe" /silent add_launcher "c:\Program Files\Lworks\super egg hunt\superegghunt.exe" From 6d1230fcf9b94c314a7e59352406c367f52c5454 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Fri, 11 Mar 2022 13:08:45 -0500 Subject: [PATCH 08/17] the -d flag now launches the installer, which is more useful for debugging games. --- audiogame-manager.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index c72ba5f..e5852a7 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1045,7 +1045,7 @@ declare -A command=( [c]="Check your system for necessary components." [C]="Clear the cache. All game installers will be deleted." [D]="Create desktop shortcut. You can launch audiogame-manager from the desktop or applications menu." - [d]="Debug mode, wine will be much more verbose when games are launched with this flag." + [d]="Debug mode, wine will be much more verbose when games are installed with this flag." [h]="This help screen." [i]="Install games." [I:]="Noninteractive game installation." @@ -1069,7 +1069,7 @@ while getopts "${args}" i ; do D) desktop_launcher;; d) unset WINEDEBUG - game_launcher + game_installer ;; h) help;; i) game_installer;; From 8f807f93eb32c0380e9564d58857060c53add71a Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Mon, 14 Mar 2022 01:00:23 -0400 Subject: [PATCH 09/17] Removed the game "Fantasy Story II" because it is now natively accessible. It is now available in the new "Linux Game Manager" project: https://git.2mb.codes/~stormdragon2976/linux-game-manager --- audiogame-manager.sh | 8 -------- 1 file changed, 8 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index e5852a7..81d984f 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -942,7 +942,6 @@ gameList=( "ESP Pinball Party Pack" #"Eurofly" "Extant" - "Fantasy Story II" #"Fartman" "Finger Panic" "Fuck That Bird" @@ -1787,13 +1786,6 @@ case "${game}" in unzip -d "$WINEPREFIX/drive_c/Program Files/extant" "${cache}/extant.zip" add_launcher "c:\Program Files\extant\Extant.exe" ;; - "Fantasy Story II") - export winVer="win10" - install_wine_bottle speechsdk - download "https://stormgames.wolfe.casa/downloads/FS2_2.2_Windows_x86.zip" - unzip -d "$WINEPREFIX/drive_c/Program Files/" "${cache}/FS2_2.2_Windows_x86.zip" - add_launcher "c:\Program Files\FS2_2.2_Windows_x86\FantasyStory2.exe" - ;; "Fartman") install_wine_bottle dx8vb vb6run download "http://www.agarchive.net/games/bpc/fartman.exe" From 84cc04c62587bdbb3e7311afa039f610469c0b7c Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Wed, 23 Mar 2022 18:39:12 -0400 Subject: [PATCH 10/17] Set up Nyanchan Games bottle. Games themselves coming soon. --- audiogame-manager.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 81d984f..8656317 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -377,6 +377,13 @@ get_bottle() { "super-egg-hunt"*) ;& "super-liam"*) ;& "the-great-toy-robbery"*) export WINEPREFIX="${HOME}/.local/wine/l-works";; + # Nyanchan games group + "bokurano-daibouken-3"*) ;& + "laser-breakout"*) ;& + "marina-break"*) ;& + "mp5"*) ;& + "screaming-strike-2"*) ;& + "world-of-war"*) export WINEPREFIX="${HOME}/.local/wine/nyanchan";; # Oriol Gomez games group "bombercats"*) ;& "copter-mission"*) ;& @@ -2200,6 +2207,7 @@ EOF add_launcher "c:\Program Files\scramble_win32\scramble.exe" ;; "Screaming Strike 2") + export bottle="nyanchan" export winVer="win7" install_wine_bottle fakejapanese speechsdk download "https://www.nyanchangames.com/softs/screamingStrike2.exe" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" From d2c8694e8a0ce66a39f3a52db67e7e3a9586c95e Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Wed, 23 Mar 2022 21:17:28 -0400 Subject: [PATCH 11/17] Game "Marina Break" added, but disabled currently because it is not speaking. --- audiogame-manager.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 8656317..ed70748 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -968,6 +968,7 @@ gameList=( "Lunimals" "Manamon" "Manamon 2" + #"Marina Break" "Monkey Business" "MudSplat French" "MudSplat English" @@ -2008,6 +2009,17 @@ EOF wine "${cache}/manamon2_installer.exe" /silent add_launcher "c:\Program Files\VGStorm.com\Manamon 2\rpg.exe" ;; + "Marina Break") + export bottle="nyanchan" + export winVer="win7" + install_wine_bottle speechsdk + download "https://www.nyanchangames.com/softs/MbSetupE.exe" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" + wine "${cache}/MbSetupE.exe" & + xdotool sleep 10 key Return + wineserver -w + find "${WINEPREFIX}" -type f -name "nvdaControllerClient.dll" -exec rm -fv "{}" \; + add_launcher "c:\nyanchangame\MarinaBreak\marinabreak.exe" + ;; "Monkey Business") export winVer="win7" install_wine_bottle vb6run dx8vb speechsdk quartz From 9f6f6f7d91c02e2e9ca9dd16132d065441d8910b Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Thu, 24 Mar 2022 19:04:06 -0400 Subject: [PATCH 12/17] Added the game "Laser Breakout" but it is disabled for now because it does not speak. --- audiogame-manager.sh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index ed70748..d249c4c 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -961,6 +961,7 @@ gameList=( "Judgement Day" "Kitchensinc Games" "Kringle Crash" + #"Laser Breakout" #"Light Battles" "Light Cars" "Lockpick" @@ -1942,6 +1943,17 @@ EOF wine "${cache}/kringle crash setup.exe" /silent add_launcher "c:\Program Files\Kringle Crash\kringlecrash.exe" ;; + "Laser Breakout") + export bottle="nyanchan" + export winVer="win7" + install_wine_bottle speechsdk + download "http://www.nyanchangames.com/softs/lsSetup.exe" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" + wine "${cache}/lsSetup.exe" & + xdotool sleep 10 key Return + wineserver -w + find "${WINEPREFIX}" -type f -name "nvdaControllerClient.dll" -exec rm -fv "{}" \; + add_launcher "c:\nyanchangame\laser breakout\play.exe" + ;; "Light Battles") export winVer="win7" install_wine_bottle speechsdk @@ -2013,7 +2025,7 @@ EOF export bottle="nyanchan" export winVer="win7" install_wine_bottle speechsdk - download "https://www.nyanchangames.com/softs/MbSetupE.exe" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" + download "https://www.nyanchangames.com/softs/MbSetupE.exe" wine "${cache}/MbSetupE.exe" & xdotool sleep 10 key Return wineserver -w From bc5ac9f3d23cf06318a2ef0cbe49fbd437945945 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Sun, 27 Mar 2022 03:14:04 -0400 Subject: [PATCH 13/17] Added -t option to show number of games currently available. --- audiogame-manager.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index d249c4c..39fdfa9 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -990,7 +990,7 @@ gameList=( "Q9" "Revelation" "Rhythm Rage" - #"River raiders" + #"River Raiders" "RS Games" "Run For Your Life" #"Sammy Center" @@ -1065,6 +1065,7 @@ declare -A command=( [P]="Print a list of packages required by audiogame-manager." [R]="Redownload. Removes old versions of packages from cache before installing." [r]="Remove a game. This will delete all game data." + [t]="Total games. Show how many games are currently available." ) # Convert the keys of the associative array to a format usable by getopts @@ -1092,6 +1093,11 @@ while getopts "${args}" i ; do P) checklist quiet;; R) redownload="true";; r) game_removal;; + t) + dialog --backtitle "Linux Game Manager" \ + --infobox "There are currently ${#gameList[@]} games available." -1 -1 + exit 0 + ;; esac done @@ -2192,9 +2198,10 @@ EOF # Choppy sound under water. install_wine_bottle download "https://www.agarchive.net/games/XSight/River%20Raiders%201.3.5.exe" - wine "$cache/River Raiders 1.3.5.exe" /silent & + wine "$cache/River Raiders 1.3.5.exe" & xdotool sleep 5 type y 2> /dev/null xdotool sleep 1 key --clearmodifiers alt+n sleep 2 key alt+n sleep 2 key alt+n sleep 2 key alt+i sleep 5 key alt+f 2> /dev/null + wineserver -w add_launcher "c:\Program Files\River Raiders\raid.exe" ;; "RS Games") From 07054de7cb650be2c2aff9e37e661e385ca515ce Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Sun, 27 Mar 2022 13:39:52 -0400 Subject: [PATCH 14/17] Fixed a typo. --- audiogame-manager.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 39fdfa9..ff1e70c 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1094,7 +1094,7 @@ while getopts "${args}" i ; do R) redownload="true";; r) game_removal;; t) - dialog --backtitle "Linux Game Manager" \ + dialog --backtitle "Audiogame Manager" \ --infobox "There are currently ${#gameList[@]} games available." -1 -1 exit 0 ;; From eb0a19efa3435026e403af7c56dc2546baf63b09 Mon Sep 17 00:00:00 2001 From: Michael Taboada Date: Sun, 17 Apr 2022 09:32:13 -0700 Subject: [PATCH 15/17] Blind Drive added, but comment until sapi works in 64-bit wine --- audiogame-manager.sh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index ff1e70c..02f3916 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -921,6 +921,7 @@ gameList=( "BG Word Target" "BG Word Yahtzee" "BG Yahtzee" + #"Blind Drive" "Bloodshed" "Bombercats" #"Breed Memorial" @@ -969,7 +970,7 @@ gameList=( "Lunimals" "Manamon" "Manamon 2" - #"Marina Break" + "Marina Break" "Monkey Business" "MudSplat French" "MudSplat English" @@ -1540,6 +1541,17 @@ case "${game}" in wine "${cache}/${bgInstaller}" /silent add_launcher "c:\Program Files\Games\yahtzeeB\BGYahtzee.exe" ;; + "Blind Drive") + get_installer "Blind Drive 1.1.112.00i-win64.zip" "https://lofipeople.itch.io/blind-drive" + export WINEARCH=win64 + export winVer="win8" + install_wine_bottle sapi + unzip -d "$WINEPREFIX/drive_c/Program Files/blind-drive" "${cache}/Blind Drive 1.1.112.00i-win64.zip" + # Weird work around to get keyboard working. + winetricks -q usetakefocus=y + winetricks -q usetakefocus=n + add_launcher "c:\Program Files\blind-drive\Blind Drive.exe" + ;; "Bloodshed") export winVer="win7" install_wine_bottle speechsdk From 5cf7606f6e910fa761e9b2222e1caf61b278b369 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Thu, 5 May 2022 20:01:19 -0400 Subject: [PATCH 16/17] First pass at the new check for updates function. --- audiogame-manager.sh | 41 +++++++++++++---------------------------- 1 file changed, 13 insertions(+), 28 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index ff1e70c..0eb2593 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -68,36 +68,21 @@ check_news() { # Automatic update function update() { - local filePath="$(command -v ${0})" - if file "${filePath}" | grep -q 'Bourne-Again shell script' ; then + local url="$(git ls-remote --get-url)" + if [[ "$url" =~ ^ssh://|git@ ]] || [[ -z "$url" ]]; then return fi - # make sure the site can be reached - ping -c1 stormgames.wolfe.casa &> /dev/null || return - if [[ "$(uname)" == "Darwin" ]]; then - local downloadFile="audiogame-manager.mac" - else - if [[ "$(uname -m)" == "armv7l" ]]; then - local downloadFile="audiogame-manager.arm" - else - local downloadFile="audiogame-manager" - fi - fi - if [[ "$(wget --quiet -O - https://stormgames.wolfe.casa/downloads/${downloadFile} | sha256sum | cut -d ' ' -f1)" == "$(sha256sum "${filePath}" | cut -d ' ' -f1)" ]]; then - return - fi - dialog --backtitle "Audiogame Manager" --yesno "There is a new version of ${0##*/} available.\nDo you want to update now?" -1 -1 - if [[ ${?} -eq 0 ]]; then - if [[ -w "$0" ]]; then - wget --quiet -O "${filePath}" "https://stormgames.wolfe.casa/downloads/${downloadFile}" - chmod +x "$0" - else - sudo wget --quiet -O "${filePath}" "https://stormgames.wolfe.casa/downloads/${downloadFile}" - sudo chmod +x "$0" - fi - echo "${0##*/} has been updated. Please launch the program again to use the latest version." - exit 0 - fi + git remote update &> /dev/null + local upstream='@{u}' + local home="$(git rev-parse @)" + local remote="$(git rev-parse "$upstream")" +if [[ "$home" == "$remote" ]]; then + return +fi + dialog --backtitle "Audiogame Manager" \ + --yesno "Updates are available. Would you like to update now?" -1 -1 --stdout || return + git pull + exit $? } # Function to open urls across OS. From e1f8475b42b021189e7a2772cd8b4622eb6db246 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Fri, 13 May 2022 13:24:55 -0400 Subject: [PATCH 17/17] More work on Hearthstone, it's not working yet and appears to hang in the installer section. A little closer than before though. --- audiogame-manager.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 3dd0cd8..6d2deb9 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1859,8 +1859,8 @@ case "${game}" in add_launcher "c:\Program Files\hammer of glory\game.exe" ;; "Hearthstone") - export winVer="win7" - install_wine_bottle speechsdk + export winVer="win10" + install_wine_bottle ie8 vcrun2015 speechsdk # This download url breaks the download function, so grab it manually. wget -O "${cache}/Hearthstone.exe" "https://www.battle.net/download/getInstallerForGame?os=win&gameProgram=HEARTHSTONE&version=Live" wget -O "${cache}/Hearthstone_patch.zip" "https://github.com/HearthstoneAccess/HearthstoneAccess/releases/latest/download/patch.zip"