From 1ec6eb758f020dd7acf28e3236a9d83362af0bdb Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Mon, 23 Jan 2023 18:08:56 -0500 Subject: [PATCH 01/36] First incarnation of a function to install different wine versions for audio games that require a specific version of wine to work. --- audiogame-manager.sh | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index c40f698..3af3671 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -457,6 +457,31 @@ echo "Loading documentation, please wait..." exit 0 } +install_wine() { + # Requires wine version, e.g. 7.7 and architecture, 32|64 + if [[ $# -ne 2 ]]; then + exit 1 + fi + # Figure out wineInstallationPath + wineInstallationPath="${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/wine_$2/$1" + # If the path exists, wine should already be installed. + # Just make sure we didn't wind up with a empty directory for some reason + rmdir "${wineInstallationPath}" 2> /dev/null + if [[ -d "${wineInstallationPath}" ]]; then + return + fi + # This probably does not need to be cached, so download to tmp. + installationFile="$(mktemp)" + local v=$2 + v="${v/32/x86}" + v="${v/64/x64}" # Probably wrong, so just a place holder. + # If this goes wrong, bail out + set -e + curl -L --output "${installationFile}" "https://www.playonlinux.com/wine/binaries/phoenicis/upstream-linux-x86/PlayOnLinux-wine-${1}-upstream-linux-${v}.tar.gz" + tar xf "${installationFile}" -C "${wineInstallationPath}" + set +e +} + 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 From 56eb97c65900621d669e3d129ced5b8bdb6c7e6a Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Mon, 23 Jan 2023 20:18:36 -0500 Subject: [PATCH 02/36] First code using the new wine version code. All Aprone games now use Wine 7.7, this fixes problems with Swamp frequently disconnecting. If you find this doesn't work for you, please use the master branch to play Swamp until the bugs are fixed. I tested it here, and Swamp launched, but I also have wine 7.7 installed system wide currently. --- audiogame-manager.sh | 25 +++++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 3af3671..9dd5a0c 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -305,7 +305,9 @@ get_bottle() { "puzzle-divided"*) ;& "revelation"*) ;& "swamp"*) ;& - "triple -triad"*) export WINEPREFIX="${HOME}/.local/wine/aprone" ;; + "triple -triad"*) + version="7.7" + export WINEPREFIX="${HOME}/.local/wine/aprone" ;; "bg-"*) export WINEPREFIX="${HOME}/.local/wine/bg";; # ESP Pinball games "esp-pinball-classic"*) export WINEPREFIX="${HOME}/.local/wine/esp-pinball";; @@ -470,6 +472,7 @@ install_wine() { if [[ -d "${wineInstallationPath}" ]]; then return fi + mkdir -p "${wineInstallationPath}" 2> /dev/null # This probably does not need to be cached, so download to tmp. installationFile="$(mktemp)" local v=$2 @@ -747,7 +750,6 @@ game_launcher() { # kill any previous existing wineservers for this prefix in case they didn't shut down properly. wineserver -k # launch the game - # launch the game if command -v qjoypad &> /dev/null ; then mkdir -p ~/.qjoypad3 touch "${HOME}/.qjoypad3/${game%|*}.lyt" @@ -843,9 +845,23 @@ game_launcher() { fi if [[ -d "${WINEPREFIX}/drive_c/windows/syswow64" ]]; then pgrep -u "$USER" nvda2speechd &> /dev/null || ${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/nvda2speechd & - wine64 start /realtime /d "${winePath}" "$wineExec" + # Figure out which wine version to use + if [[ -n "${version}" ]]; then + install_wine "${version}" "64" + wine="${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/wine_64/${version}/bin/wine" + else + wine="$(command -v wine64)" + fi + $wine start /realtime /d "${winePath}" "$wineExec" else - wine start /d "${winePath}" "$wineExec" /realtime + # Figure out which wine version to use + if [[ -n "${version}" ]]; then + install_wine "${version}" "32" + wine="${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/wine_32/${version}/bin/wine" + else + wine="$(command -v wine)" + fi + $wine start /d "${winePath}" "$wineExec" /realtime fi fi exit 0 @@ -914,6 +930,7 @@ export BOX86_NOBANNER=1 unset noCache # Manual installation is not default, make sure it's unset unset manualInstall +unset version # The list of games available for installation. From db463525e90735e5338a882ba0bd3d65939c82a7 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Mon, 23 Jan 2023 23:33:00 -0500 Subject: [PATCH 03/36] Fixed clipboard_translator. It was refusing to run if or exiting if for some reason the clipboard was empty. --- speech/clipboard_translator.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/speech/clipboard_translator.sh b/speech/clipboard_translator.sh index b3df40f..7a267b2 100755 --- a/speech/clipboard_translator.sh +++ b/speech/clipboard_translator.sh @@ -3,7 +3,8 @@ # Modified from the script at: # https://gist.github.com/fdietze/6768a0970d7d732b7fbd7930ccceee2a -set -Eeuo pipefail # https://vaneyckt.io/posts/safer_bash_scripts_with_set_euxo_pipefail/#:~:text=set%20%2Du,is%20often%20highly%20desirable%20behavior. +# The next line has been commented because if there's nothing in clipboard the script breaks. +# set -Eeuo pipefail # https://vaneyckt.io/posts/safer_bash_scripts_with_set_euxo_pipefail/#:~:text=set%20%2Du,is%20often%20highly%20desirable%20behavior. shopt -s expand_aliases From 3cd9facf29042df0a6d61757d7e6dd8eed1f459d Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 24 Jan 2023 12:17:00 -0500 Subject: [PATCH 04/36] Finally fixed Shadow Line installer, I think. --- audiogame-manager.sh | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 9dd5a0c..45e0e2f 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -788,6 +788,7 @@ game_launcher() { if [[ "$game" =~ shadow-line ]]; then find "${WINEPREFIX}/drive_c/" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \; "${0%/*}/speech/clipboard_translator.sh" play_sr.exe shadow-line & + export version="7.7" fi if [[ "$game" =~ bokurano-daibouken-3 ]]; then dictPath="$(winepath "${winePath}")" @@ -1087,7 +1088,7 @@ gameList=( "Sequence Storm" #"Shades of Doom 1.2" "Shades of Doom" - #"Shadow Line" + "Shadow Line" "Shooter" "Silver Dollar" "Slender Lost Vision" @@ -2563,17 +2564,19 @@ EOF add_launcher "c:\Program Files\Shades of Doom 2.0\sod.exe" ;; "Shadow Line") - export winVer="win8" speechsdk + export version="7.7" + export winVer="win8" install_wine_bottle download "https://www.mm-galabo.com/sr/Download_files_srfv/shadowrine_fullvoice3.171.exe" - wine "${cache}/shadowrine_fullvoice3.171.exe" /sp- + wine "${cache}/shadowrine_fullvoice3.171.exe" /sp- & xdotool sleep 30 key --clearmodifiers --delay=500 Return xdotool key --clearmodifiers --delay=500 Return xdotool key --clearmodifiers --delay=500 Return xdotool key --clearmodifiers --delay=500 Return - xdotool sleep 300 key --clearmodifiers --delay=500 Down + echo "Running installer, this will take approximately 3 minutes..." + xdotool sleep 180 key --clearmodifiers --delay=500 Down xdotool key --clearmodifiers --delay=500 space - xdotool key --clearmodifiers --delay=500 alt+i + xdotool key --clearmodifiers --delay=500 alt+f wineserver -w add_launcher "c:\Program Files\GalaxyLaboratory\ShadowRine_FullVoice\play_sr.exe" ;; From 8bdba9d93e5c6581247efe626e3801ed4caa5d36 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 24 Jan 2023 16:04:58 -0500 Subject: [PATCH 05/36] More very experimental changes. Now games should install using the required version of wine if necessary. It works in all the tests I have done, but that doesn't mean there are no bugs. --- audiogame-manager.sh | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 45e0e2f..35598f4 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -466,6 +466,7 @@ install_wine() { fi # Figure out wineInstallationPath wineInstallationPath="${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/wine_$2/$1" + export wine="${wineInstallationPath}/bin/wine" # If the path exists, wine should already be installed. # Just make sure we didn't wind up with a empty directory for some reason rmdir "${wineInstallationPath}" 2> /dev/null @@ -538,6 +539,11 @@ install_rhvoice() { install_wine_bottle() { # 32 bit installations work best and are the default here, if you need to override it, do it in the game specific installation steps. export WINEARCH="${WINEARCH:-win32}" + # Figure out if we are using a specific version of wine + wine="${wine:-$(command -v wine)}" + # Set the WINE and WINESERVER environmental variables so winetricks will use the right installation. + WINE="${wine}" + WINESERVER="${wine}server" if [[ -z "$bottle" ]]; then local bottle="${game,,}" bottle="${bottle//[[:space:]]/-}" @@ -560,9 +566,9 @@ install_wine_bottle() { geckoPath="${cache}/wine_gecko-2.40-x86.msi" fi # This is in a brace list to pipe through dialog. - { DISPLAY="" wineboot -u - wine msiexec /i z:"$monoPath" /quiet - wine msiexec /i z:"$geckoPath" /quiet + { DISPLAY="" ${wine}boot -u + $wine msiexec /i z:"$monoPath" /quiet + $wine msiexec /i z:"$geckoPath" /quiet if [[ "${*}" =~ (speechsdk|sapi) ]]; then install_rhvoice fi @@ -2565,10 +2571,11 @@ EOF ;; "Shadow Line") export version="7.7" + install_wine "$version" "32" export winVer="win8" install_wine_bottle download "https://www.mm-galabo.com/sr/Download_files_srfv/shadowrine_fullvoice3.171.exe" - wine "${cache}/shadowrine_fullvoice3.171.exe" /sp- & + $wine "${cache}/shadowrine_fullvoice3.171.exe" /sp- & xdotool sleep 30 key --clearmodifiers --delay=500 Return xdotool key --clearmodifiers --delay=500 Return xdotool key --clearmodifiers --delay=500 Return @@ -2577,7 +2584,7 @@ EOF xdotool sleep 180 key --clearmodifiers --delay=500 Down xdotool key --clearmodifiers --delay=500 space xdotool key --clearmodifiers --delay=500 alt+f - wineserver -w + ${wine}server -w add_launcher "c:\Program Files\GalaxyLaboratory\ShadowRine_FullVoice\play_sr.exe" ;; "Silver Dollar") From ed82d449c64281e2fe470c1b93740a267a816242 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 24 Jan 2023 16:09:13 -0500 Subject: [PATCH 06/36] Updated installer for swamp. It now uses the new code to make sure everything happens in 7.7 --- audiogame-manager.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 35598f4..bc86ac1 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2673,6 +2673,7 @@ EOF add_launcher "c:\Program Files\Survive the Wild\stw.exe" ;; "Swamp") + install_wine "${version}" "32" export bottle="aprone" export winVer="win7" export winetricksSettings="vd=1024x768" @@ -2685,8 +2686,8 @@ EOF if curl -L --output "${cache}/SwampPatch.zip" "https://www.kaldobsky.com/audiogames/SwampPatch.zip" ; then unzip -o -d "$WINEPREFIX/drive_c/Program Files/swamp" "${cache}/SwampPatch.zip" fi - wine 'c:\Program Files\swamp\checkup.exe' /verysilent - #wine cmd.exe /c 'cd /d c:\Program Files\swamp && Windows32bit.bat' + $wine 'c:\Program Files\swamp\checkup.exe' /verysilent + #$wine cmd.exe /c 'cd /d c:\Program Files\swamp && Windows32bit.bat' # Delete music if requested. if [[ $deleteMusic -eq 0 ]]; then rm -frv "$WINEPREFIX/drive_c/Program Files/swamp/sounds/Music/" From 795eef018d09d9a3d1caa30adc2aadaa5066dfd6 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Wed, 25 Jan 2023 01:46:15 -0500 Subject: [PATCH 07/36] Updated the dependency installer script. --- wine/install-dependencies.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/wine/install-dependencies.sh b/wine/install-dependencies.sh index f1829f6..84996d5 100755 --- a/wine/install-dependencies.sh +++ b/wine/install-dependencies.sh @@ -13,12 +13,12 @@ is_function() { configure_arch() { packageList=( cabextract + curl dialog dos2unix gawk unzip w3m - wget wine winetricks wine_gecko @@ -34,6 +34,8 @@ configure_arch() { alsa-lib mesa openal + sox + sqlite3 translate-shell xz gst-plugins-bad @@ -72,6 +74,7 @@ configure_arch() { configure_debian() { packageList=( + curl dialog gawk gstreamer1.0-plugins-bad:i386 From 7e90f9586f21277546868d592c1ad17d6a71716a Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Thu, 26 Jan 2023 19:52:00 -0500 Subject: [PATCH 08/36] Entombed now uses wine 7.7, but there appears to be something wrong with part of the installation process, so not working currently. Added some statements to show what is happening, including which wine is being used or installed. --- audiogame-manager.sh | 41 ++++++++++++++++++++++++++++------------- 1 file changed, 28 insertions(+), 13 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index bc86ac1..c88ab55 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -481,8 +481,8 @@ install_wine() { v="${v/64/x64}" # Probably wrong, so just a place holder. # If this goes wrong, bail out set -e - curl -L --output "${installationFile}" "https://www.playonlinux.com/wine/binaries/phoenicis/upstream-linux-x86/PlayOnLinux-wine-${1}-upstream-linux-${v}.tar.gz" - tar xf "${installationFile}" -C "${wineInstallationPath}" + { curl -L --output "${installationFile}" "https://www.playonlinux.com/wine/binaries/phoenicis/upstream-linux-x86/PlayOnLinux-wine-${1}-upstream-linux-${v}.tar.gz" + tar xf "${installationFile}" -C "${wineInstallationPath}"; } | dialog --progressbox "Installing $2 bit Wine version $1." -1 -1 set +e } @@ -566,7 +566,9 @@ install_wine_bottle() { geckoPath="${cache}/wine_gecko-2.40-x86.msi" fi # This is in a brace list to pipe through dialog. - { DISPLAY="" ${wine}boot -u + { echo -n "Using " + ${wine} --version + DISPLAY="" ${wine}boot -u $wine msiexec /i z:"$monoPath" /quiet $wine msiexec /i z:"$geckoPath" /quiet if [[ "${*}" =~ (speechsdk|sapi) ]]; then @@ -791,11 +793,6 @@ game_launcher() { if [[ "$game" =~ ^bokurano-daibouken\| ]]; then "${0%/*}/speech/clipboard_translator.sh" play.exe bokurano-daibouken & fi - if [[ "$game" =~ shadow-line ]]; then - find "${WINEPREFIX}/drive_c/" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \; - "${0%/*}/speech/clipboard_translator.sh" play_sr.exe shadow-line & - export version="7.7" - fi if [[ "$game" =~ bokurano-daibouken-3 ]]; then dictPath="$(winepath "${winePath}")" if [[ -r "${cache}/bk3-dict.dat" ]] && [[ ! -d "${dictPath}/dict" ]]; then @@ -824,6 +821,14 @@ game_launcher() { if [[ "$game" =~ sequence-storm ]]; then "${0%/*}/speech/clipboard_reader.sh" SequenceStorm & fi + if [[ "$game" =~ shadow-line ]]; then + find "${WINEPREFIX}/drive_c/" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \; + "${0%/*}/speech/clipboard_translator.sh" play_sr.exe shadow-line & + export version="7.7" + fi + if [[ "$game" =~ swamp ]]; then + export version="7.7" + fi if [[ "$game" =~ audiodisc ]]; then wine "$winePath\\$wineExec" exit 0 @@ -832,6 +837,9 @@ game_launcher() { wine "$winePath\\$wineExec" exit 0 fi + if [[ "$game" =~ entombed ]]; then + export version="7.7" + fi if [[ "$game" =~ rs-games ]] || [[ "$game" =~ screaming-strike-2 ]]; then pushd "$(winepath "$winePath")" wine "$wineExec" @@ -859,6 +867,8 @@ game_launcher() { else wine="$(command -v wine64)" fi + echo -n "launching " + ${wine} --version $wine start /realtime /d "${winePath}" "$wineExec" else # Figure out which wine version to use @@ -868,6 +878,8 @@ game_launcher() { else wine="$(command -v wine)" fi + echo -n "launching " + ${wine} --version $wine start /d "${winePath}" "$wineExec" /realtime fi fi @@ -1960,23 +1972,25 @@ case "${game}" in add_launcher "c:\Program Files\Endless Runner\runner.exe" ;; "Entombed") + export version="7.7" + install_wine "$version" "32" export winVer="win7" install_wine_bottle speechsdk msvcrt40 gdiplus ie7 wmp11 mf # Ok, more dotnet. LC_ALL=C DISPLAY="" winetricks -q dotnet40 xna40 - wineserver -k # Sigh. + ${wine}server -k # Sigh. download "http://blind-games.com/newentombed/EntombedSetup.exe" "https://download.microsoft.com/download/E/C/1/EC1B2340-67A0-4B87-85F0-74D987A27160/SSCERuntime-ENU.exe" "https://stormgames.wolfe.casa/downloads/Entombed.exe.config" "https://stormgames.wolfe.casa/downloads/mfplat.dll" mkdir -p "${WINEPREFIX}/drive_c/temp" pushd "${WINEPREFIX}/drive_c/temp" 7z x "${cache}/SSCERuntime-ENU.exe" - wine msiexec /i "${WINEPREFIX}/drive_c/temp/SSCERuntime_x86-ENU.msi" /q + ${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 + ${wine} regsvr32 sqlceoledb35.dll + ${wine} regsvr32 sqlceca35.dll popd - wine "${cache}/EntombedSetup.exe" /silent + ${wine} "${cache}/EntombedSetup.exe" /silent pushd "${WINEPREFIX}/drive_c/Program Files/Entombed" cp ../Microsoft\ SQL\ Server\ Compact\ Edition/v3.5/Private/System.Data.SqlServerCe.Entity.dll ../Microsoft\ SQL\ Server\ Compact\ Edition/v3.5/Private/System.Data.SqlServerCe.dll . cp ../Microsoft\ SQL\ Server\ Compact\ Edition/v3.5/sql* . @@ -2673,6 +2687,7 @@ EOF add_launcher "c:\Program Files\Survive the Wild\stw.exe" ;; "Swamp") + export version="7.7" install_wine "${version}" "32" export bottle="aprone" export winVer="win7" From 2fdf75a47734301c7d7a900d62901e50273c97da Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Thu, 26 Jan 2023 21:56:20 -0500 Subject: [PATCH 09/36] Entombed working again, requires wine 7.0. --- audiogame-manager.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index c88ab55..453bb37 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -838,7 +838,7 @@ game_launcher() { exit 0 fi if [[ "$game" =~ entombed ]]; then - export version="7.7" + export version="7.0" fi if [[ "$game" =~ rs-games ]] || [[ "$game" =~ screaming-strike-2 ]]; then pushd "$(winepath "$winePath")" @@ -1972,7 +1972,7 @@ case "${game}" in add_launcher "c:\Program Files\Endless Runner\runner.exe" ;; "Entombed") - export version="7.7" + export version="7.0" install_wine "$version" "32" export winVer="win7" install_wine_bottle speechsdk msvcrt40 gdiplus ie7 wmp11 mf From eaafc19768fb27d6049277e9c048a3c20740b70a Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Fri, 27 Jan 2023 11:50:46 -0500 Subject: [PATCH 10/36] Fixed path for Sketchbook. --- audiogame-manager.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 453bb37..199173c 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2556,9 +2556,9 @@ EOF export winVer="win7" install_wine_bottle speechsdk download "http://games.ims-productions.com/SBYW/SBYW.zip" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" - unzip -d "$WINEPREFIX/drive_c/Program Files/scrolling battles" "${cache}/SBYW.zip" + unzip -d "$WINEPREFIX/drive_c/Program Files/sketchbook" "${cache}/SBYW.zip" find "${WINEPREFIX}" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \; - add_launcher "c:\Program Files\scrolling battles\SBYW.exe" + add_launcher "c:\Program Files\sketchbook\SBYW.exe" ;; "Sequence Storm") get_installer "sequence-storm-win64.zip" "https://special-magic-games-llc.itch.io/sequence-storm" From 5a9f715891b601e0aa1933166d8b580b6daf47b7 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Fri, 27 Jan 2023 12:27:17 -0500 Subject: [PATCH 11/36] Replace nvdaControllerClient at the launch of Sketchbook so that updates won't break it. Immediately after updating, relaunch the game to restore speech. --- audiogame-manager.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 199173c..69c87b8 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -826,6 +826,9 @@ game_launcher() { "${0%/*}/speech/clipboard_translator.sh" play_sr.exe shadow-line & export version="7.7" fi + if [[ "$game" =~ sketchbook ]]; then + find "${WINEPREFIX}" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \; + fi if [[ "$game" =~ swamp ]]; then export version="7.7" fi From a6c42a6bd12692984e6d7229afcbe5a9cd346493 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Fri, 27 Jan 2023 13:38:08 -0500 Subject: [PATCH 12/36] Sketchbook now working with sound. --- audiogame-manager.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 69c87b8..c5d30ae 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2558,8 +2558,10 @@ EOF "Sketchbook") export winVer="win7" install_wine_bottle speechsdk - download "http://games.ims-productions.com/SBYW/SBYW.zip" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" + download "http://sbyw.games/SBYW/SBYW.zip" "http://sbyw.games/SBYW/sounds.zip" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" + mv -v "${cache}/sounds.zip" "${cache}/SBYW-sounds.zip" unzip -d "$WINEPREFIX/drive_c/Program Files/sketchbook" "${cache}/SBYW.zip" + unzip -d "$WINEPREFIX/drive_c/Program Files/sketchbook" "${cache}/SBYW-sounds.zip" find "${WINEPREFIX}" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \; add_launcher "c:\Program Files\sketchbook\SBYW.exe" ;; From 947c5eacb95425176146f3caf11d90161b4f1948 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Mon, 30 Jan 2023 21:49:10 -0500 Subject: [PATCH 13/36] Added missing package xdg-utils to dependency installer script. --- wine/install-dependencies.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/wine/install-dependencies.sh b/wine/install-dependencies.sh index 84996d5..c0b434b 100755 --- a/wine/install-dependencies.sh +++ b/wine/install-dependencies.sh @@ -43,6 +43,7 @@ configure_arch() { gst-plugins-ugly gst-libav p7zip + xdg-utils ) if [[ "$(uname -m)" == "x86_64" ]]; then # Enable multilib From b434cc16dbb81e6e32be8e6c961ac59dd96156e2 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Mon, 30 Jan 2023 21:54:06 -0500 Subject: [PATCH 14/36] RS Games requires an older version of wine to actually speak. Trying 7.7. --- audiogame-manager.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index c5d30ae..4ce8957 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -844,6 +844,7 @@ game_launcher() { export version="7.0" fi if [[ "$game" =~ rs-games ]] || [[ "$game" =~ screaming-strike-2 ]]; then + export version="7.7" pushd "$(winepath "$winePath")" wine "$wineExec" popd @@ -2512,6 +2513,8 @@ EOF add_launcher "c:\Program Files\RTR Offline\rtr.exe" ;; "RS Games") + export version="7.7" + install_wine "$version" "32" export winVer="win7" install_wine_bottle speechsdk download "http://rsgames.org/rsdownloads/rsgclient/rsgames-client-setup-2.01.exe" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" From e5253d7757c772adbf0437fbebbba814a63af31c Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Mon, 30 Jan 2023 23:56:21 -0500 Subject: [PATCH 15/36] Finally, RS Games working. More fixes needed for some games. --- audiogame-manager.sh | 40 +++++++++++++++++++--------------------- 1 file changed, 19 insertions(+), 21 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 4ce8957..139b603 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -306,7 +306,7 @@ get_bottle() { "revelation"*) ;& "swamp"*) ;& "triple -triad"*) - version="7.7" + install_wine "7.7" "32" export WINEPREFIX="${HOME}/.local/wine/aprone" ;; "bg-"*) export WINEPREFIX="${HOME}/.local/wine/bg";; # ESP Pinball games @@ -348,6 +348,10 @@ get_bottle() { "challenge-of-the-horse"*) export WINEPREFIX="${HOME}/.local/wine/tunmi13";; *) export WINEPREFIX="${HOME}/.local/wine/${game%|*}";; esac + # Wine version for bottles + if [[ "$game" =~ rs-games ]]; then + install_wine "7.0" "32" + fi } get_installer() { @@ -531,19 +535,19 @@ install_rhvoice() { download "${RHVoice[${voiceName}]}" winetricks -q win8 echo "Installing RHVoice ${voiceName^}..." - wine "${cache}/${voiceFile}" & + ${wine} "${cache}/${voiceFile}" & sleep 20 - wineserver -k + ${wine}server -k } install_wine_bottle() { # 32 bit installations work best and are the default here, if you need to override it, do it in the game specific installation steps. export WINEARCH="${WINEARCH:-win32}" # Figure out if we are using a specific version of wine - wine="${wine:-$(command -v wine)}" + export wine="${wine:-$(command -v wine)}" # Set the WINE and WINESERVER environmental variables so winetricks will use the right installation. - WINE="${wine}" - WINESERVER="${wine}server" + export WINE="${wine}" + export WINESERVER="${wine}server" if [[ -z "$bottle" ]]; then local bottle="${game,,}" bottle="${bottle//[[:space:]]/-}" @@ -569,8 +573,8 @@ install_wine_bottle() { { echo -n "Using " ${wine} --version DISPLAY="" ${wine}boot -u - $wine msiexec /i z:"$monoPath" /quiet - $wine msiexec /i z:"$geckoPath" /quiet + ${wine} msiexec /i z:"$monoPath" /quiet + ${wine} msiexec /i z:"$geckoPath" /quiet if [[ "${*}" =~ (speechsdk|sapi) ]]; then install_rhvoice fi @@ -750,13 +754,15 @@ game_launcher() { exit 0 fi get_bottle "$game" + echo -n "launching " + ${wine} --version local winePath="${game#*|}" winePath="${winePath%\\*.exe}" local wineExec="${game#*|}" wineExec="${wineExec%|*}" wineExec="${wineExec##*\\}" # kill any previous existing wineservers for this prefix in case they didn't shut down properly. - wineserver -k + ${wine}server -k # launch the game if command -v qjoypad &> /dev/null ; then mkdir -p ~/.qjoypad3 @@ -829,9 +835,6 @@ game_launcher() { if [[ "$game" =~ sketchbook ]]; then find "${WINEPREFIX}" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \; fi - if [[ "$game" =~ swamp ]]; then - export version="7.7" - fi if [[ "$game" =~ audiodisc ]]; then wine "$winePath\\$wineExec" exit 0 @@ -843,10 +846,9 @@ game_launcher() { if [[ "$game" =~ entombed ]]; then export version="7.0" fi - if [[ "$game" =~ rs-games ]] || [[ "$game" =~ screaming-strike-2 ]]; then - export version="7.7" + if [[ "$game" =~ screaming-strike-2 ]]; then pushd "$(winepath "$winePath")" - wine "$wineExec" + ${wine} "$wineExec" popd exit 0 fi @@ -871,8 +873,6 @@ game_launcher() { else wine="$(command -v wine64)" fi - echo -n "launching " - ${wine} --version $wine start /realtime /d "${winePath}" "$wineExec" else # Figure out which wine version to use @@ -882,8 +882,6 @@ game_launcher() { else wine="$(command -v wine)" fi - echo -n "launching " - ${wine} --version $wine start /d "${winePath}" "$wineExec" /realtime fi fi @@ -2513,12 +2511,12 @@ EOF add_launcher "c:\Program Files\RTR Offline\rtr.exe" ;; "RS Games") - export version="7.7" + export version="7.0" install_wine "$version" "32" export winVer="win7" install_wine_bottle speechsdk download "http://rsgames.org/rsdownloads/rsgclient/rsgames-client-setup-2.01.exe" "https://stormgames.wolfe.casa/downloads/nvdaControllerClient32.dll" - wine "${cache}/rsgames-client-setup-2.01.exe" /silent + ${wine} "${cache}/rsgames-client-setup-2.01.exe" /silent find "${WINEPREFIX}" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \; add_launcher "c:\Program Files\RS Games Client\rsg.exe" ;; From 33800fc980e84ce7808521a2a0225618802bf83c Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 31 Jan 2023 17:37:10 -0500 Subject: [PATCH 16/36] Fixed major bug that would sometimes cause the wrong version of wine to be used. --- audiogame-manager.sh | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 139b603..8b9ef9b 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -866,24 +866,8 @@ game_launcher() { fi if [[ -d "${WINEPREFIX}/drive_c/windows/syswow64" ]]; then pgrep -u "$USER" nvda2speechd &> /dev/null || ${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/nvda2speechd & - # Figure out which wine version to use - if [[ -n "${version}" ]]; then - install_wine "${version}" "64" - wine="${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/wine_64/${version}/bin/wine" - else - wine="$(command -v wine64)" - fi - $wine start /realtime /d "${winePath}" "$wineExec" - else - # Figure out which wine version to use - if [[ -n "${version}" ]]; then - install_wine "${version}" "32" - wine="${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/wine_32/${version}/bin/wine" - else - wine="$(command -v wine)" - fi - $wine start /d "${winePath}" "$wineExec" /realtime fi + $wine start /d "${winePath}" "$wineExec" /realtime fi exit 0 } From 119f8ecfd4a30795949fab4c206c65abf9ba8d40 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Thu, 2 Feb 2023 04:11:54 -0500 Subject: [PATCH 17/36] Fixed Shadow Line launcher. --- audiogame-manager.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 8b9ef9b..4d3ca94 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -352,6 +352,9 @@ get_bottle() { if [[ "$game" =~ rs-games ]]; then install_wine "7.0" "32" fi + if [[ "$game" =~ shadow-line ]]; then + install_wine "7.7" "32" + fi } get_installer() { @@ -830,7 +833,6 @@ game_launcher() { if [[ "$game" =~ shadow-line ]]; then find "${WINEPREFIX}/drive_c/" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \; "${0%/*}/speech/clipboard_translator.sh" play_sr.exe shadow-line & - export version="7.7" fi if [[ "$game" =~ sketchbook ]]; then find "${WINEPREFIX}" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \; From a659b4e63edb0d32f8b90534e795c45ec9c7c9d7 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Thu, 2 Feb 2023 04:42:02 -0500 Subject: [PATCH 18/36] Make sure the wine variable gets set to something, if none of the conditions for setting it get called. --- audiogame-manager.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 4d3ca94..ef2eb7b 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -757,6 +757,8 @@ game_launcher() { exit 0 fi get_bottle "$game" + # make sure wine is actually set to something + export wine="${wine:-wine}" echo -n "launching " ${wine} --version local winePath="${game#*|}" @@ -868,8 +870,10 @@ game_launcher() { fi if [[ -d "${WINEPREFIX}/drive_c/windows/syswow64" ]]; then pgrep -u "$USER" nvda2speechd &> /dev/null || ${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/nvda2speechd & + # switch to wine64 for 64 bit prefix. + [[ "${wine}" == "wine" ]] && export wine="wine64" fi - $wine start /d "${winePath}" "$wineExec" /realtime + ${wine:-wine} start /d "${winePath}" "$wineExec" /realtime fi exit 0 } From 677e0211cc05da7e13ee2faf039b91d367dc8816 Mon Sep 17 00:00:00 2001 From: Michael Taboada Date: Fri, 3 Feb 2023 22:29:22 -0800 Subject: [PATCH 19/36] First pass at mist world. Seems to work ok. --- audiogame-manager.sh | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index ef2eb7b..e0a11d5 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -798,6 +798,10 @@ game_launcher() { if [[ "$game" =~ light-battles ]]; then pgrep -u "$USER" nvda2speechd &> /dev/null || ${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/nvda2speechd & fi + if [[ "$game" =~ mist-world ]]; then + "${0%/*}/speech/speak_window_title.sh" mw.exe & + pgrep -u "$USER" nvda2speechd &> /dev/null || ${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/nvda2speechd & + fi if [[ "$game" =~ ^bokurano-daibouken-2\| ]]; then "${0%/*}/speech/clipboard_translator.sh" play.exe bokurano-daibouken2 & fi @@ -1066,6 +1070,7 @@ gameList=( "Manamon 2" #"Marina Break" #"Minecraft" + "Mist World" "Monkey Business" "MudSplat French" "MudSplat English" @@ -2317,6 +2322,16 @@ EOF done # And of course, add the launcher. ;; + "Mist World") + export winVer="win7" + get_installer "Mist World_Setup.exe" "https://drive.google.com/file/d/12YeUqorkkMT46ZSR5pcfWxSY8DHOLxZ-/view?usp=share_link" + install_wine_bottle + download "https://github.com/RastislavKish/nvda2speechd/releases/download/v0.1/nvda2speechd32.dll" + 7z x -o"$WINEPREFIX/drive_c/Program Files/Mist World" "$cache/Mist World_Setup.exe" + sed -i 's/1024m/768m/g' "$WINEPREFIX/drive_c/Program Files/Mist World/mw.exe.vmoptions" + find "$WINEPREFIX/drive_c/Program Files/Mist World" -iname "nvdaControllerClient32.dll" -exec cp "$cache/nvda2speechd32.dll" "{}" \; + add_launcher 'c:\Program Files\Mist World\mw.exe' + ;; "Monkey Business") export winVer="win7" install_wine_bottle vb6run dx8vb speechsdk quartz From b76c55db6f534f5f2430d5fd2a6a9cf7d4a75577 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Sat, 4 Feb 2023 16:51:05 -0500 Subject: [PATCH 20/36] First pass at Mist World account creator script. --- game-scripts/mist_world_account_creator.sh | 61 ++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100755 game-scripts/mist_world_account_creator.sh diff --git a/game-scripts/mist_world_account_creator.sh b/game-scripts/mist_world_account_creator.sh new file mode 100755 index 0000000..3fb1f99 --- /dev/null +++ b/game-scripts/mist_world_account_creator.sh @@ -0,0 +1,61 @@ +#!/bin/bash + +export DISPLAY="${DISPLAY:-:0}" + +read -rp "Select create account from the menu, press enter to continue." continue +echo + +# Read email address +echo "Enter email address:" +read -r email + +# Validate email address format +if [[ "$email" =~ ^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}$ ]]; then + # Type email address + xdotool type --delay=75 "$email" + # Press tab + xdotool sleep 0.5 key --delay=75 Tab + # Press enter + xdotool sleep 0.5 key --delay=75 Return +else + echo "Invalid email format. Exiting." + exit 1 +fi + +# Press tab + +#xdotool sleep 0.5 key --delay=75 Tab +# Press enter +#xdotool sleep 0.5 key --delay=75 Return + +echo "Please check your email for the verification code." + +# Read verification code +echo "Enter verification code:" +read -r code + +# Type verification code +xdotool type --delay=1000 $code +# press tab +xdotool sleep 0.5 key --delay=75 Tab +# Press enter +xdotool sleep 0.5 key --delay=75 Return + +# Read password +echo "Enter password between 6 and 16 characters, 1 uppercase letter 1 number required:" +read -r password + +# Type password +xdotool type --delay=500 "$password" +# Press tab +xdotool sleep 0.5 key --delay=75 Tab +# Type password again +xdotool sleep 0.5 type --delay=500 "$password" +# Press tab +xdotool sleep 0.5 key --delay=75 Tab +# Press enter +xdotool sleep 0.5 key --delay=75 Return + +echo "Account created!" + +exit 0 From e9e2003dcbd0341770cb405363e602a4cf7fefa4 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Sat, 4 Feb 2023 16:58:55 -0500 Subject: [PATCH 21/36] Added instructions for using the Mist World account creation script to the end of installation. --- audiogame-manager.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index e0a11d5..f122564 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2331,6 +2331,12 @@ EOF sed -i 's/1024m/768m/g' "$WINEPREFIX/drive_c/Program Files/Mist World/mw.exe.vmoptions" find "$WINEPREFIX/drive_c/Program Files/Mist World" -iname "nvdaControllerClient32.dll" -exec cp "$cache/nvda2speechd32.dll" "{}" \; add_launcher 'c:\Program Files\Mist World\mw.exe' + echo + echo "If you do not have an account, There is a script in game-scripts to help." + echo "Launch the game, press enter on create account, then drop into a console so the game window does not lose focus." + echo "Change to the game-scripts directory and run" + echo "./mist_world_account_creator.sh and follow the prompts. + echo "To login, type your email address, press tab, and type your password. Press enter to confirm." ;; "Monkey Business") export winVer="win7" From 5113d99a9d81df8411e8d96121697973371307e2 Mon Sep 17 00:00:00 2001 From: Michael Taboada Date: Sat, 4 Feb 2023 22:36:23 -0800 Subject: [PATCH 22/36] Fix up update.exe for mist world on install --- audiogame-manager.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index f122564..05e2d5c 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2329,6 +2329,7 @@ EOF download "https://github.com/RastislavKish/nvda2speechd/releases/download/v0.1/nvda2speechd32.dll" 7z x -o"$WINEPREFIX/drive_c/Program Files/Mist World" "$cache/Mist World_Setup.exe" sed -i 's/1024m/768m/g' "$WINEPREFIX/drive_c/Program Files/Mist World/mw.exe.vmoptions" + cp "$WINEPREFIX/drive_c/Program Files/Mist World/"{mw.exe.vmoptions,update.exe.vmoptions} find "$WINEPREFIX/drive_c/Program Files/Mist World" -iname "nvdaControllerClient32.dll" -exec cp "$cache/nvda2speechd32.dll" "{}" \; add_launcher 'c:\Program Files\Mist World\mw.exe' echo From 6712a9a234acfa26722e67ec50f3e57478a74b2a Mon Sep 17 00:00:00 2001 From: Jeremiah Ticket Date: Sun, 5 Feb 2023 11:20:35 -0700 Subject: [PATCH 23/36] Fixed missing quote in mist world section. --- audiogame-manager.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 05e2d5c..780a75d 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2324,7 +2324,7 @@ EOF ;; "Mist World") export winVer="win7" - get_installer "Mist World_Setup.exe" "https://drive.google.com/file/d/12YeUqorkkMT46ZSR5pcfWxSY8DHOLxZ-/view?usp=share_link" + ' get_installer "Mist World_Setup.exe" "https://drive.google.com/file/d/12YeUqorkkMT46ZSR5pcfWxSY8DHOLxZ-/view?usp=share_link" install_wine_bottle download "https://github.com/RastislavKish/nvda2speechd/releases/download/v0.1/nvda2speechd32.dll" 7z x -o"$WINEPREFIX/drive_c/Program Files/Mist World" "$cache/Mist World_Setup.exe" @@ -2336,7 +2336,7 @@ EOF echo "If you do not have an account, There is a script in game-scripts to help." echo "Launch the game, press enter on create account, then drop into a console so the game window does not lose focus." echo "Change to the game-scripts directory and run" - echo "./mist_world_account_creator.sh and follow the prompts. + echo "./mist_world_account_creator.sh and follow the prompts." echo "To login, type your email address, press tab, and type your password. Press enter to confirm." ;; "Monkey Business") From 5e1ca7ce7fab5a3eba6f518c95e3d4131a773ee9 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Sun, 5 Feb 2023 15:37:57 -0500 Subject: [PATCH 24/36] Create a file, agm.conf, in new bottles that contains the path to wine and wineserver. This will make it possible for game helper scripts to work without breaking bottles that require different versions. --- audiogame-manager.sh | 3 +++ speech/set-voice.sh | 18 +++++++++++++----- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 780a75d..94ea230 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -589,6 +589,9 @@ install_wine_bottle() { chmod +x "${XDG_DATA_HOME:-$HOME/.local/share}/audiogame-manager/nvda2speechd" fi winetricks -q isolate_home $@ ${winVer:-winxp} ${winetricksSettings}; } | dialog --progressbox "Installing wine bottle, please wait..." -1 -1 + # make it easy for game scripts to know which version of wine to use. + echo "WINE=\"${WINE}\"" > "$HOME/.local/wine/${bottle}/agm.conf" + echo "WINESERVER=\"${WINESERVER}\"" >> "$HOME/.local/wine/${bottle}/agm.conf" } diff --git a/speech/set-voice.sh b/speech/set-voice.sh index 41d9fde..f76013a 100755 --- a/speech/set-voice.sh +++ b/speech/set-voice.sh @@ -77,6 +77,14 @@ if [[ -z "${WINEPREFIX}" ]]; then exit 0 fi +# Get wine version if available +if [[ -r "${WINEPREFIX}/agm.conf" ]]; then + source "${WINEPREFIX}/agm.conf" + export WINE + export WINESERVER +fi +wine="${WINE:-$(command -v wine)}" + msgbox() { # Returns: None # Shows the provided message on the screen with an ok button. @@ -124,7 +132,7 @@ menulist() { restore_voice() { if [[ $doRestore -eq 0 ]]; then - wineserver -k # If we don't do this it's likely wine will overwrite our reverted change or even clobber the registry key entirely + ${wine}server -k # If we don't do this it's likely wine will overwrite our reverted change or even clobber the registry key entirely $sed -i -E -e 's/"DefaultTokenId"="HKEY_LOCAL_MACHINE\\\\(SOFTWARE|Software)\\\\(Wow6432Node\\\\|)Microsoft\\\\Speech\\\\Voices\\\\Token(Enum|)s\\\\[^"]+"/"DefaultTokenId"="'"${oldVoice//\\/\\\\}"'"/g' "${WINEPREFIX}/user.reg" fi } @@ -142,7 +150,7 @@ set_voice() { RHVoiceName="${RHVoiceName##*/}" fullVoice="${voiceListFullName[$counter]}" fullVoice="${fullVoice/RHVoice/RHVoice\\\\${RHVoiceName}}" - wineserver -k # If we don't do this it's likely wine will overwrite our reverted change or even clobber the registry key entirely + ${wine}server -k # If we don't do this it's likely wine will overwrite our reverted change or even clobber the registry key entirely # Remove any existing rate change for voices $sed -i '/"DefaultTTSRate"=dword:/d' "${WINEPREFIX}/user.reg" $sed -i -E -e 's/"DefaultTokenId"="HKEY_LOCAL_MACHINE\\\\(SOFTWARE|Software)\\\\(Wow6432Node\\\\|)Microsoft\\\\Speech\\\\Voices\\\\Token(Enum|)s\\\\[^"]+"/"DefaultTokenId"="HKEY_LOCAL_MACHINE\\\\'"${fullVoice//\\/\\\\}"'"\n"DefaultTTSRate"=dword:0000000'${2:-7}'/g' "${WINEPREFIX}/user.reg" @@ -161,14 +169,14 @@ test_voice() { RHVoiceName="${RHVoiceName##*/}" fullVoice="${voiceListFullName[$counter]}" fullVoice="${fullVoice/RHVoice/RHVoice\\\\${RHVoiceName}}" - wineserver -k # If we don't do this it's likely wine will overwrite our reverted change or even clobber the registry key entirely + ${wine}server -k # If we don't do this it's likely wine will overwrite our reverted change or even clobber the registry key entirely $sed -i -E -e 's/"DefaultTokenId"="HKEY_LOCAL_MACHINE\\\\(SOFTWARE|Software)\\\\(Wow6432Node\\\\|)Microsoft\\\\Speech\\\\Voices\\\\Token(Enum|)s\\\\[^"]+"/"DefaultTokenId"="HKEY_LOCAL_MACHINE\\\\'"${fullVoice//\\/\\\\}"'"/g' "${WINEPREFIX}/user.reg" cat << "EOF" > "${bottle}/drive_c/windows/temp/speak.vbs" dim speechobject set speechobject=createobject("sapi.spvoice") speechobject.speak "This is a test of your chosen voice. It contains multiple sentences and punctuation, and is designed to give a full representation of this voices qualities." EOF - wine cscript "c:\windows\temp\speak.vbs" + ${wine} cscript "c:\windows\temp\speak.vbs" } # Handle voice restore, but only if voice changed @@ -181,7 +189,7 @@ dim speechobject set speechobject=createobject("sapi.spvoice") speechobject.speak "" EOF -wine cscript "c:\windows\temp\speak.vbs" +${wine} cscript "c:\windows\temp\speak.vbs" # Create an array of available voices. ifs="$IFS" From dd1007dce136416dbf8d02f29a7728d7f8bc6618 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Mon, 6 Feb 2023 05:04:26 -0500 Subject: [PATCH 25/36] Fixed a bug with Mist World installer. Apparently in ' sneaked it's way into the installer. Added an alert functioon in case there's something that needs to be read for an installer. --- audiogame-manager.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 94ea230..b658ba9 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -45,6 +45,13 @@ EOF export DIALOGOPTS='--no-lines --visit-items' +# Alerts, for when user needs to read something. +alert() { + play -qnV0 synth 3 pluck D3 pluck A3 pluck D4 pluck F4 pluck A4 delay 0 .1 .2 .3 .4 remix - chorus 0.9 0.9 38 0.75 0.3 0.5 -t + echo + read -rp "Press enter to continue." continue +} + # Check for latest news check_news() { trap return INT @@ -1268,6 +1275,7 @@ case "${game}" in add_launcher "c:\Program Files\AudioQuake\AudioQuake.exe" echo echo "After you launch the game, press tab then enter and it should begin speaking." + alert ;; "Battle of the Hunter") export bottle="tunmi13" @@ -2327,7 +2335,7 @@ EOF ;; "Mist World") export winVer="win7" - ' get_installer "Mist World_Setup.exe" "https://drive.google.com/file/d/12YeUqorkkMT46ZSR5pcfWxSY8DHOLxZ-/view?usp=share_link" + get_installer "Mist World_Setup.exe" "https://drive.google.com/file/d/12YeUqorkkMT46ZSR5pcfWxSY8DHOLxZ-/view?usp=share_link" install_wine_bottle download "https://github.com/RastislavKish/nvda2speechd/releases/download/v0.1/nvda2speechd32.dll" 7z x -o"$WINEPREFIX/drive_c/Program Files/Mist World" "$cache/Mist World_Setup.exe" @@ -2341,6 +2349,7 @@ EOF echo "Change to the game-scripts directory and run" echo "./mist_world_account_creator.sh and follow the prompts." echo "To login, type your email address, press tab, and type your password. Press enter to confirm." + alert ;; "Monkey Business") export winVer="win7" From ecec18417e69e54c0ef32cc3e55eb11a99a438b0 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 7 Feb 2023 03:46:15 -0500 Subject: [PATCH 26/36] Added game "Tactical Battle". --- audiogame-manager.sh | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index b658ba9..31c5a99 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -356,6 +356,9 @@ get_bottle() { *) export WINEPREFIX="${HOME}/.local/wine/${game%|*}";; esac # Wine version for bottles + if [[ "$game" =~ entombed ]]; then + install_wine "6.18" "32" + fi if [[ "$game" =~ rs-games ]]; then install_wine "7.0" "32" fi @@ -861,9 +864,6 @@ game_launcher() { wine "$winePath\\$wineExec" exit 0 fi - if [[ "$game" =~ entombed ]]; then - export version="7.0" - fi if [[ "$game" =~ screaming-strike-2 ]]; then pushd "$(winepath "$winePath")" ${wine} "$wineExec" @@ -1126,6 +1126,7 @@ gameList=( "Super Mario Bros" "Survive the Wild" "Swamp" + "Tactical Battle" "Technoshock" "Ten Pin Alley" "The Blind Swordsman" @@ -1980,7 +1981,7 @@ case "${game}" in add_launcher "c:\Program Files\Endless Runner\runner.exe" ;; "Entombed") - export version="7.0" + export version="6.18" install_wine "$version" "32" export winVer="win7" install_wine_bottle speechsdk msvcrt40 gdiplus ie7 wmp11 mf @@ -2739,6 +2740,14 @@ EOF fi add_launcher "c:\Program Files\swamp\Swamp.exe" ;; + "Tactical Battle") + install_wine_bottle speechsdk + LC_ALL=C DISPLAY="" winetricks -q dotnet462 + ${wine}server -k + download "https://blindgamers.com/downloads/Tactical%20Battle%20Dev.zip" + unzip -d "$WINEPREFIX/drive_c/Program Files/Tactical Battle" "${cache}/Tactical Battle Dev.zip" + add_launcher "c:\Program Files\Tactical Battle\Tactical Battle.exe" + ;; "Technoshock") install_wine_bottle download "http://tiflocomp.ru/download/games/technoshock_140b_en.zip" "http://tiflocomp.ru/download/games/technoshock140b_en_update.zip" From bc7cdcfd2550457337e8eb828b367e3c970bc547 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 7 Feb 2023 14:10:40 -0500 Subject: [PATCH 27/36] Adding Super Deekout, but have to save for later. Will finish it in a bit. --- audiogame-manager.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 31c5a99..11c4d4a 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1120,6 +1120,7 @@ gameList=( "Sonic the Hedgehog" "Sonic Zoom" #"Space Defender" + "Super Deekout" "Super Dogs Bone Hunt" "Super Egg Hunt" "Super Liam" @@ -2682,6 +2683,14 @@ EOF find "${WINEPREFIX}" -type f -name 'nvdaControllerClient64.dll' -exec cp -v "${cache}/nvdaControllerClient64.dll" "{}" \; add_launcher "c:\Program Files\space_defender\sdefender.exe" ;; + "Super Deekout") + install_wine_bottle vb6run dx8vb + download "http://www.danielzingaro.com/superdeekout_setup.exe" "http://www.danielzingaro.com/sd_full.exe" + ${wine} "${cache}/superdeekout_setup.exe" & + ${wine}server -k + 7z x -o"$WINEPREFIX/drive_c/Program Files/Super Deekout" "${cache}/sd_full.exe" + add_launcher "c:\Program Files\Super Deekout\super.exe" + ;; "Super Dogs Bone Hunt") install_wine_bottle vb6run dx8vb speechsdk download "http://www.pcs-games.net/SBH11.exe" From 9736e4c0001386e81c037ab83aa5a6b2698f986f Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 7 Feb 2023 15:40:25 -0500 Subject: [PATCH 28/36] More progress on Super Deekout. Unfortunately going to have to run the config.exe program. More xdotool to come. --- audiogame-manager.sh | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 11c4d4a..f425640 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2687,9 +2687,30 @@ EOF install_wine_bottle vb6run dx8vb download "http://www.danielzingaro.com/superdeekout_setup.exe" "http://www.danielzingaro.com/sd_full.exe" ${wine} "${cache}/superdeekout_setup.exe" & + xdotool sleep 15 key --delay 100 y 2> /dev/null + xdotool sleep 3 key --delay 250 alt+n 2> /dev/null + xdotool key --delay 250 alt+a 2> /dev/null + xdotool key --delay 250 space 2> /dev/null + xdotool key --delay 250 alt+n 2> /dev/null + xdotool key --delay 250 alt+n 2> /dev/null + xdotool key --delay 250 alt+n 2> /dev/null + xdotool key --delay 250 alt+i 2> /dev/null + xdotool sleep 15 key --delay 250 alt+f 2> /dev/null + xdotool sleep 3 key --delay 250 n 2> /dev/null ${wine}server -k - 7z x -o"$WINEPREFIX/drive_c/Program Files/Super Deekout" "${cache}/sd_full.exe" + #7z x -o"$WINEPREFIX/drive_c/Program Files/Super Deekout" "${cache}/sd_full.exe" add_launcher "c:\Program Files\Super Deekout\super.exe" + echo "Super Deekout needs some information before it will run:" + alert + read -erp "Please enter your first and last name separated by a space: " name + read -erp "Please enter your email address: " email + read -eri "US" -p "Please enter your 2 letter country code. If it is not US, be sure to backspace first: " country + country="${country:0:2}" + country="${country^^}" + echo "\"${name}\:" > "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" + echo "\"${email}\"" >> "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" + echo "\"${country}\"" >> "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" + unix2dos "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" ;; "Super Dogs Bone Hunt") install_wine_bottle vb6run dx8vb speechsdk From 68af5c87102566e8d0140aea6f2190be654ec48e Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 7 Feb 2023 18:35:20 -0500 Subject: [PATCH 29/36] Finished adding Super Deekout. Xdotool is very important dependency for this one. --- audiogame-manager.sh | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index f425640..fbd510f 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2699,18 +2699,24 @@ EOF xdotool sleep 3 key --delay 250 n 2> /dev/null ${wine}server -k #7z x -o"$WINEPREFIX/drive_c/Program Files/Super Deekout" "${cache}/sd_full.exe" - add_launcher "c:\Program Files\Super Deekout\super.exe" echo "Super Deekout needs some information before it will run:" alert - read -erp "Please enter your first and last name separated by a space: " name + read -erp "Please enter your first name: " fname + read -erp "Please enter your last name: " lname read -erp "Please enter your email address: " email - read -eri "US" -p "Please enter your 2 letter country code. If it is not US, be sure to backspace first: " country - country="${country:0:2}" - country="${country^^}" - echo "\"${name}\:" > "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" - echo "\"${email}\"" >> "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" - echo "\"${country}\"" >> "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" - unix2dos "$WINEPREFIX/drive_c/Program Files/Super Deekout/config.dat" + ${wine} "c:\Program Files\Super Deekout\config.exe" & + xdotool sleep 5 key --delay 100 Return 2> /dev/null + xdotool sleep 3 type --clearmodifiers --delay 100 "${fname}" + xdotool key --clearmodifiers --delay 100 Tab 2> /dev/null + xdotool sleep 1 type --clearmodifiers --delay 100 "${lname}" + xdotool key --clearmodifiers --delay 100 Tab 2> /dev/null + xdotool sleep 1 type --clearmodifiers --delay 100 "${email}" + xdotool key --clearmodifiers --delay 100 Tab 2> /dev/null + xdotool sleep 15 key --delay 100 u 2> /dev/null + xdotool key --clearmodifiers --delay 100 Tab 2> /dev/null + xdotool sleep 1 key --delay 250 Return 2> /dev/null + ${wine}server -k + add_launcher "c:\Program Files\Super Deekout\super.exe" ;; "Super Dogs Bone Hunt") install_wine_bottle vb6run dx8vb speechsdk From 57eac5b7f6be7f5b2ebb6199ac3c7a3c42dfa464 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 7 Feb 2023 22:28:46 -0500 Subject: [PATCH 30/36] Found a patch that turns Super Deekout into the full version. --- audiogame-manager.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index fbd510f..284ac3d 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2698,7 +2698,7 @@ EOF xdotool sleep 15 key --delay 250 alt+f 2> /dev/null xdotool sleep 3 key --delay 250 n 2> /dev/null ${wine}server -k - #7z x -o"$WINEPREFIX/drive_c/Program Files/Super Deekout" "${cache}/sd_full.exe" + 7z x -y -o"$WINEPREFIX/drive_c/Program Files/Super Deekout" "${cache}/sd_full.exe" echo "Super Deekout needs some information before it will run:" alert read -erp "Please enter your first name: " fname From 8dcdea5ed1c7e1c0399ca196186e557d3faa01b5 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Wed, 8 Feb 2023 09:51:21 -0500 Subject: [PATCH 31/36] Removed the "adding games" section from the README. It now has its own wiki page. --- README.md | 92 ------------------------------------------------------- 1 file changed, 92 deletions(-) diff --git a/README.md b/README.md index f09d9cf..88b8dce 100644 --- a/README.md +++ b/README.md @@ -17,95 +17,3 @@ Get usage instructions. Select from a list of games to install. With no arguments, the list of installed games will be displayed. In all the menus, both installer and launcher, use the up and down arrow keys to find the game you want. Press enter on the game to perform the action. For more detailed help, try the -h flag. - - -## Adding Games - -Because of the size of the audiogame-manager.sh file, adding new titles may seem like a daunting task. For most games, however, the process is not terribly difficult. The majority of them require two edits. - - -### The Menu Section - -You need to add the game title as it appears in the menu when you launch audiogame-manager.sh. Let's use the fictitious title "My Awesome Game" in the following example. - -First, find the list of games. This is easily done by searching for the comment: - - # The list of games available for installation. - -You will notice an array called gameList. Add the title, in quotes, to the array. Use the existing list as a guide to keep things formatted similarly. Games are approximately alphebatized, although I did add some of them prier to coffee, so that doesn't always hold true. So for our example, the entry here would be: - - "My Awesome Game" - -That's it for the menu. It's worth noting that to disable a game from showing up in the installation menu, just add a # to comment out the entry. - -### Installing the Game - -In most cases, the process to install a game is straight forward. If the game in question is self-voiced, it is very easy in deed. The only difficult part may be finding out what, if any wine packages are needed. Continuing with the example game, let's say for the time being that it is a self-voiced game that is 32 bit and will work on any version of wine, so we don't care about setting it. - -Once again, you can search for a string to get you to the top of the installation section. As before, the installers are approximately alphabetically ordered. So moving down to the "M" section, let's add the installer. find the string: - - # Install game based on the selection above. - -Then in the appropriate area, add the installer code. The example will have comments explaining what's going on. - - # Add the game title to the case statement - "My Awesome Game") - # Set up the wine prefix in ~/.local/wine/my-awesome-game - install_wine_bottle - # Get the game's installation file - download "http://.example.com/my_awesome_game_setup.exe" - # run the installer with the silent flag so that it installs without any prompts which are inaccessible to screen readers on Linux. - wine "${cache}/my_awesome_game_setup.exe" /silent - # Create the launcher entry so audiogame manager knows how to start the game. - add_launcher "c:\Program Files\My Awesome Game\mag.exe" - ;; - - -### Dealing with nvdaControllerClient.dll and SAPI - -Note that currently the 64 bit wine version of SAPI does not work. Games that include the nvdaControllerClient will work, but in order for wine to process the speech with SAPI, the dll file needs to be removed. Let's change the above example because the imaginary developer of My Awesome Game got tired of recording all of those voice clips and changed the game to use SAPI instead. Here is the updated code with comments. - - # Add the game title to the case statement - "My Awesome Game") - # Set up the wine prefix in ~/.local/wine/my-awesome-game and install speechsdk - install_wine_bottle speechsdk - # Get the game's installation file - download "http://.example.com/my_awesome_game_setup.exe" - # run the installer with the silent flag so that it installs without any prompts which are inaccessible to screen readers on Linux. - wine "${cache}/my_awesome_game_setup.exe" /silent - # Remove the nvdaControllerClient.dll file - # Note that it may just becalled nvdaControllerClient.dll or nvdaControllerClient32.dll - find "${WINEPREFIX}" -type f -name "nvdaControllerClient32.dll" -exec rm -fv "{}" \; - # Create the launcher entry so audiogame manager knows how to start the game. - add_launcher "c:\Program Files\My Awesome Game\mag.exe" - ;; - -In some cases, however, this will cause the game to not function at all. For these cases, we have a fake dll that can take the place of the original. You just need to make sure the fake dll is downloaded during game installation and then move it into place. For an example of how this works, please take a look at the "A Hero's Call" entry in audiogame-manager.sh. - -### Dealing with compressed files - -This is actually pretty easy. Just change the wine command to the command to extract the file to the proper location. If the "My Awesome Game" developer got tired of dealing with setup files and switched to zip, for instance, the new line would look like this. - - unzip -d "$WINEPREFIX/drive_c/Program Files" "${cache}/my_awesome_game.zip" - -Some games just extract to the current directory, which can make "Program Files" all cluttered. If you find this is the case, just add a directory name on to the end and it will be created, like so. - - unzip -d "$WINEPREFIX/drive_c/Program Files/My Awesome Game" "${cache}/my_awesome_game.zip" - - -### When Things Get Complicated - -If your game requires some extra setup before launching, there is a section to add code for it. As usual, there is a comment at the start of the section. Look for the string. - - # for games that require custom scripts before launch or custom launch parameters - -There are some tools available for getting games to speak that do not use any of the methods listed above. Look in the speech directory and you will find a clipboard translator and a script to read the current window title when it changes. - -If your game is 64 bit only, you will need to add a section here to launch it with the nvda2speechd setup. For a detailed example of this, check out the "Code Dungeon" installer. This is a good one too because it demonstrates an oddity required to get the keyboard working as well as setting the Windows version and architecture. It also shows how to prompt the user for a file that cannot be downloaded automatically, e.g. something from Itch. - -That covers most things. If the game happens to require .net, it can really get complicated indeed. For an example of this, take a look at the "Entombed" installer. - - -## Contributing - -If you would like to contribute, please try to keep the code formatted like it is currently. Please make sure that your additions work on your computer before doing a pull request. From 3085939e350e45d35a915c0ef3c58185a8f25e43 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Wed, 8 Feb 2023 16:03:14 -0500 Subject: [PATCH 32/36] Add some flags to make curl try harder to download files for those hosts that are less than reliable. --- audiogame-manager.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 284ac3d..2c7747f 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -291,7 +291,7 @@ download() { fi # Skip if the item is in cache. test -e "${cache}/${dest}" && continue - if ! curl -L4 --output "${cache}/${dest}" "${i}" ; then + if ! curl -L4 -C - --retry 10 --output "${cache}/${dest}" "${i}" ; then echo "Could not download \"$i\"..." exit 1 fi @@ -437,7 +437,7 @@ echo "Loading documentation, please wait..." local gameDoc="$(find "$gamePath" -type f -iname 'user_manual.html' -or -iname 'user_manual.htm' | head -1)" # Game name specific docs, add the name to the for loop. if [[ -z "$gameDoc" ]]; then - for i in "troopanum.txt" ; do + for i in "troopanum.txt" "superdeekout.txt" ; do gameDoc="$(find "$gamePath" -type f -iname "$i" -or -iname 'manual.htm' | head -1)" done fi From f10afe820a4602df4e42f7b8ee867b2e2374d27a Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Wed, 8 Feb 2023 20:26:51 -0500 Subject: [PATCH 33/36] Added an alert for the message about getting speech in vipMUD. --- audiogame-manager.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 2c7747f..e4dc034 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -2976,6 +2976,7 @@ export norh=false # Must install a voice, and rhvoice works easily with 64 bit. echo "To bypass these dialogs, press alt+o, then press enter until speech starts." echo "To be sure that each new dialog has had time to complete, wait a second between each press of enter." echo "In each subsequent launch, you will need to hit enter a couple times before it starts speaking." + alert ;; "Warsim") get_installer "Warsim Full Game.zip" "https://huw2k8.itch.io/warsim" From fbb389019d03448bb5465502b9fa6d8d9897c26d Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Thu, 9 Feb 2023 00:14:42 -0500 Subject: [PATCH 34/36] Experimental fix for systems in other languages. Export LANG to en_US.UTF-8 temporarily during installation of games. This needs testing, especially if your computer is normally in a different language. --- audiogame-manager.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index e4dc034..0c96e6c 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -607,6 +607,8 @@ install_wine_bottle() { # Install games game_installer() { + export LANG="en_US.UTF-8" + # Try to deal with systems in other languages mapfile -t installedGames < <(sed '/^$/d' "${configFile}" 2> /dev/null | cut -d '|' -f3) # Create the menu of installed games declare -a menuList From f1d21ae49fd19594d30825aaa3157d75ff2a31f9 Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Thu, 9 Feb 2023 17:13:34 -0500 Subject: [PATCH 35/36] Updated the README with information on switching keyboard layout if necessary. --- README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/README.md b/README.md index 88b8dce..b73871d 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,7 @@ Installer and launcher for Windows based audio games under wine for Linux. + ## Usage ./audiogame-manager.sh -c @@ -17,3 +18,18 @@ Get usage instructions. Select from a list of games to install. With no arguments, the list of installed games will be displayed. In all the menus, both installer and launcher, use the up and down arrow keys to find the game you want. Press enter on the game to perform the action. For more detailed help, try the -h flag. + + +## Language and Keyboard + +if you are using a language on your system other than English, you may need to temperarily change the keyboard layout while playing some games. To find out which keyboard layout you are currently using, run the following command: + + setxkbmap -print -verbose 10 | grep 'layout:' + +If the layout is not us, and if you are having some problems with keys not working, before you launch the game, run the following command to switch keyboard layout: + + setxkbmap us + +When you are done with the game, switch back to your original layout so things will work as expected. The following example will switch your keyboard back to the Czech layout. + + setxkbmap cz From 172f5482d009c765601ae93c5e2a540330c474dc Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Fri, 10 Feb 2023 09:44:45 -0500 Subject: [PATCH 36/36] Fixed up the grep statement to show only the first layout if there are multiples. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index b73871d..e7f1359 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ With no arguments, the list of installed games will be displayed. In all the men if you are using a language on your system other than English, you may need to temperarily change the keyboard layout while playing some games. To find out which keyboard layout you are currently using, run the following command: - setxkbmap -print -verbose 10 | grep 'layout:' + setxkbmap -print -verbose 10 | grep -m1 'layout:' If the layout is not us, and if you are having some problems with keys not working, before you launch the game, run the following command to switch keyboard layout: