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.

This commit is contained in:
stormdragon2976 2023-01-23 20:18:36 -05:00
parent 1ec6eb758f
commit 56eb97c659

View File

@ -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.