Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reaper: Respect reaper toggle and kill reaper process #815

Closed
wants to merge 8 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions lang/chinese.txt
Original file line number Diff line number Diff line change
Expand Up @@ -723,7 +723,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="启用FSR(OpenVR)"
DESC_USEOPENVRFSR="启用FidelityFX超级分辨率(FSR)兼容OpenVR"
GUI_USEREAP="使用reaper命令"
DESC_USEREAP="如果可用,使用 reaper 命令"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="修复符号链接"
DESC_FIXSYMLINKS="修复指向与当前版本不同的 Proton 版本的符号链接"
GUI_UNSYMLINK="取消符号链接"
Expand Down Expand Up @@ -811,8 +811,6 @@ DESC_SPEKVERS="Special K下载版本。"
NOTY_MISSDLL="'XXX'需要'YYY',这在目前运行的'ZZZ'的WINEPREFIX中是不存在的"
GUI_FORCESLR="强制使用Steam Linux Runtime"
DESC_FORCESLR="强制使用Steam Linux Runtime 如果无法使用"
GUI_FORCEREAP="强制执行reaper命令"
DESC_FORCEREAP="强制执行reaper命令,如果不可用"
GUI_CUPROTOCOMPAT="在 compatibilitytools.d 中提取自定义Proton"
DESC_CUPROTOCOMPAT="在 compatibilitytools.d 中提取自定义Proton"
GUI_RUN_VORTEX_WINETRICKS="在 Vortex 模式下启用 Winetricks"
Expand Down
4 changes: 1 addition & 3 deletions lang/dutch.txt
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="Enable FSR (OpenVR)"
DESC_USEOPENVRFSR="Enable FidelityFX Super Resolution (FSR) compatible OpenVR"
GUI_USEREAP="Use reaper command"
DESC_USEREAP="Use reaper command if available"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Fix symlinks"
DESC_FIXSYMLINKS="Fix symlinks pointing to a Proton version unlike the current one"
GUI_UNSYMLINK="Unsymlink"
Expand Down Expand Up @@ -807,8 +807,6 @@ DESC_SPEKVERS="Special K download version"
NOTY_MISSDLL="'XXX' requires 'YYY', which is not available in the WINEPREFIX currently running with 'ZZZ'"
GUI_FORCESLR="Force Steam Linux Runtime"
DESC_FORCESLR="Force Steam Linux Runtime if not available"
GUI_FORCEREAP="Force reaper command"
DESC_FORCEREAP="Force reaper command if not available"
GUI_CUPROTOCOMPAT="Uitpakken aangepaste Proton archieven in compatibilitytools.d"
DESC_CUPROTOCOMPAT="Uitpakken aangepaste Proton archieven in compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Enable Winetricks in Vortex Mode"
Expand Down
4 changes: 1 addition & 3 deletions lang/english.txt
Original file line number Diff line number Diff line change
Expand Up @@ -723,7 +723,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="Enable FSR (OpenVR)"
DESC_USEOPENVRFSR="Enable FidelityFX Super Resolution (FSR) compatible OpenVR"
GUI_USEREAP="Use reaper command"
DESC_USEREAP="Use reaper command if available"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Fix symlinks"
DESC_FIXSYMLINKS="Fix symlinks pointing to a Proton version unlike the current one"
GUI_UNSYMLINK="Unsymlink"
Expand Down Expand Up @@ -811,8 +811,6 @@ DESC_SPEKVERS="Special K download version"
NOTY_MISSDLL="'XXX' requires 'YYY', which is not available in the WINEPREFIX currently running with 'ZZZ'"
GUI_FORCESLR="Force Steam Linux Runtime"
DESC_FORCESLR="Force Steam Linux Runtime if not available"
GUI_FORCEREAP="Force reaper command"
DESC_FORCEREAP="Force reaper command if not available"
GUI_CUPROTOCOMPAT="Extract custom Proton in compatibilitytools.d"
DESC_CUPROTOCOMPAT="Extract custom Proton in compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Enable Winetricks in Vortex Mode"
Expand Down
4 changes: 1 addition & 3 deletions lang/englishUK.txt
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="Enable FSR (OpenVR)"
DESC_USEOPENVRFSR="Enable FidelityFX Super Resolution (FSR) compatible OpenVR"
GUI_USEREAP="Use reaper command"
DESC_USEREAP="Use reaper command if available"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Fix symlinks"
DESC_FIXSYMLINKS="Fix symlinks pointing to a Proton version unlike the current one"
GUI_UNSYMLINK="Unsymlink"
Expand Down Expand Up @@ -807,8 +807,6 @@ DESC_SPEKVERS="Special K download version"
NOTY_MISSDLL="'XXX' requires 'YYY', which is not available in the WINEPREFIX currently running with 'ZZZ'"
GUI_FORCESLR="Force Steam Linux Runtime"
DESC_FORCESLR="Force Steam Linux Runtime if not available"
GUI_FORCEREAP="Force reaper command"
DESC_FORCEREAP="Force reaper command if not available"
GUI_CUPROTOCOMPAT="Extract custom Proton in compatibilitytools.d"
DESC_CUPROTOCOMPAT="Extract custom Proton in compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Enable Winetricks in Vortex Mode"
Expand Down
4 changes: 1 addition & 3 deletions lang/french.txt
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="Activer FSR (OpenVR)"
DESC_USEOPENVRFSR="Activer la FidelityFX Super Resolution (FSR) compatible OpenVR"
GUI_USEREAP="Utiliser la commande reaper"
DESC_USEREAP="Utiliser la commande reaper si disponible"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Corriger les liens symboliques"
DESC_FIXSYMLINKS="Corriger les liens symboliques pointant vers une version de Proton différente de la version actuelle"
GUI_UNSYMLINK="Supprimer le lien symbolique"
Expand Down Expand Up @@ -807,8 +807,6 @@ DESC_SPEKVERS="Version de téléchargement de Special K"
NOTY_MISSDLL="'XXX' nécessite 'YYY', qui n'est pas disponible dans le WINEPREFIX actuellement utilisé avec 'ZZZ'"
GUI_FORCESLR="Forcer Steam Linux Runtime"
DESC_FORCESLR="Forcer Steam Linux Runtime si non disponible"
GUI_FORCEREAP="Forcer la commande reaper"
DESC_FORCEREAP="Force la commande reaper si non disponible"
GUI_CUPROTOCOMPAT="Extraire Proton custom dans compatibilitytools.d"
DESC_CUPROTOCOMPAT="Extraire Proton custom dans compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Activer Winetricks dans le Vortex mode"
Expand Down
4 changes: 1 addition & 3 deletions lang/german.txt
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="Verwende FSR (OpenVR)"
DESC_USEOPENVRFSR="Verwende FidelityFX Super Resolution (FSR) kompatibles OpenVR"
GUI_USEREAP="Verwende reaper Befehl"
DESC_USEREAP="Verwende reaper Befehl falls verfügbar"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Repariere symlinks"
DESC_FIXSYMLINKS="Repariere symlinks die auf eine andere Proton Version als die gerade verwendete zeigen"
GUI_UNSYMLINK="Unsymlink"
Expand Down Expand Up @@ -807,8 +807,6 @@ DESC_SPEKVERS="Special K download Version"
NOTY_MISSDLL="'XXX' benötigt 'YYY', welches im WINEPREFIX der gerade verwendeten Proton Version 'ZZZ' nicht verfügbar ist"
GUI_FORCESLR="Erzwinge Steam Linux Runtime"
DESC_FORCESLR="Erzwinge Steam Linux Runtime falls nicht verfügbar"
GUI_FORCEREAP="Erzwinge reaper Befehl"
DESC_FORCEREAP="Erzwinge reaper Befehl falls nicht verfügbar"
GUI_CUPROTOCOMPAT="Entpacke custom Proton nach compatibilitytools.d"
DESC_CUPROTOCOMPAT="Entpacke custom Proton nach compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Starte Winetricks vor Vortex"
Expand Down
4 changes: 1 addition & 3 deletions lang/italian.txt
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="Abilita FSR (OpenVR)"
DESC_USEOPENVRFSR="Abilita FidelityFX Super Resolution (FSR) compatibile OpenVR"
GUI_USEREAP="Usa il comando reaper"
DESC_USEREAP="Usa il comando reaper se è disponibile"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Ripara symlinks"
DESC_FIXSYMLINKS="Ripara i symlinks che puntano a una versione di proton diversa da quella attuale"
GUI_UNSYMLINK="Unsymlink"
Expand Down Expand Up @@ -807,8 +807,6 @@ DESC_SPEKVERS="Scarica versione Special K"
NOTY_MISSDLL="'XXX' richiede 'YYY', che non è disponibile in WINEPREFIX dove è in esecuzione con 'ZZZ'"
GUI_FORCESLR="Forza Steam Linux Runtime"
DESC_FORCESLR="Forza Steam Linux Runtime se non disponibile"
GUI_FORCEREAP="Forza il comando reaper"
DESC_FORCEREAP="Forza il comando reaper se è non disponibile"
GUI_CUPROTOCOMPAT="Estrazione di archivi personalizzati di Proton in compatibilitytools.d"
DESC_CUPROTOCOMPAT="Estrazione di archivi personalizzati di Proton in compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Enable Winetricks in Vortex Mode"
Expand Down
4 changes: 1 addition & 3 deletions lang/polish.txt
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Własna rozdzielczość do FST, z której
GUI_USEOPENVRFSR="Włącz FSR (OpenVR)"
DESC_USEOPENVRFSR="Włącz OpenVR kompatybilny z FidelityFX Super Resolution (FSR)"
GUI_USEREAP="Użyj polecenia reaper"
DESC_USEREAP="Użyj polecenia reaper jeśli dostępne"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Napraw linki symboliczne"
DESC_FIXSYMLINKS="Napraw linki symboliczne wskazując na wersję Protona inną niż obecna"
GUI_UNSYMLINK="Usuń link symboliczny"
Expand Down Expand Up @@ -807,8 +807,6 @@ DESC_SPEKVERS="Wersja pobrana Special K"
NOTY_MISSDLL="'XXX' wymaga 'YYY', które nie jest dostępne w WINEPREFIX obecnie uruchamianym z 'ZZZ'"
GUI_FORCESLR="Wymuś Steam Linux Runtime"
DESC_FORCESLR="Wymuś Steam Linux Runtime, jeśli nie dostępne"
GUI_FORCEREAP="Wymuś polecenia reaper"
DESC_FORCEREAP="Wymuś polecenia reaper, jeśli nie dostępne"
GUI_CUPROTOCOMPAT="Wypakowanie własnych archiwów Protona do compatibilitytools.d"
DESC_CUPROTOCOMPAT="Wypakowanie własnych archiwów Protona do compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Włącz Winetricks w trybie Vortex"
Expand Down
4 changes: 1 addition & 3 deletions lang/russian.txt
Original file line number Diff line number Diff line change
Expand Up @@ -719,7 +719,7 @@ DESC_WINE_FULLSCREEN_FSR_CUSTOM_MODE="Custom resolution for FSR to upscale from.
GUI_USEOPENVRFSR="Enable FSR (OpenVR)"
DESC_USEOPENVRFSR="Enable FidelityFX Super Resolution (FSR) compatible OpenVR"
GUI_USEREAP="Use reaper command"
DESC_USEREAP="Use reaper command if available"
DESC_USEREAP="Allow Steam to run the Reaper process at startup (default behaviour with regular Steam launch) - disabling this may allow forked processes to stay open after game close, but disable this option with caution"
GUI_FIXSYMLINKS="Fix symlinks"
DESC_FIXSYMLINKS="Fix symlinks pointing to a proton version unlike the current one"
GUI_UNSYMLINK="Unsymlink"
Expand Down Expand Up @@ -807,8 +807,6 @@ DESC_SPEKVERS="Special K download version"
NOTY_MISSDLL="'XXX' requires 'YYY', which is not available in the WINEPREFIX currently running with 'ZZZ'"
GUI_FORCESLR="Заставить Steam Linux Runtime"
DESC_FORCESLR="Заставить Steam Linux Runtime если опция не доступна"
GUI_FORCEREAP="Заставить reaper command"
DESC_FORCEREAP="Заставить reaper command если опция не доступна"
GUI_CUPROTOCOMPAT="Распаковка архивов альтернативных сборок Proton в compatibilitytools.d"
DESC_CUPROTOCOMPAT="Распаковка архивов альтернативных сборок Proton в compatibilitytools.d"
GUI_RUN_VORTEX_WINETRICKS="Enable Winetricks in Vortex Mode"
Expand Down
77 changes: 16 additions & 61 deletions steamtinkerlaunch
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
PREFIX="/usr"
PROGNAME="SteamTinkerLaunch"
NICEPROGNAME="Steam Tinker Launch"
PROGVERS="v14.0.20230528-3"
PROGVERS="v14.0.20230529-10 (reaper-kill)"
PROGCMD="${0##*/}"
SHOSTL="stl"
GHURL="https://github.com"
Expand Down Expand Up @@ -1923,14 +1923,6 @@ function setGameVars {
# this should cover it though as well already
APPMAFE="$(listAppManifests | grep -m1 "${1}.acf")"
fi

REAPSESTR="reaper SteamLaunch"

if grep -q "$REAPSESTR" <<< "$@"; then
HAVEREAP=1
else
HAVEREAP=0
fi

if grep -q "$SLR" <<< "$@"; then
HAVESLR=1
Expand All @@ -1950,31 +1942,13 @@ function setGameVars {
mapfile -t -O "${#INGCMD[@]}" INGCMD <<< "$INGARG"
done <<< "$(printf "%s\n" "$@")"

# then put the reaper command into an array, as it is the first command in the line
if [ "$HAVEREAP" -eq 1 ]; then
FOUNDREAP=0
while read -r INGARG; do
if [ "$FOUNDREAP" -eq 0 ]; then
mapfile -t -O "${#REAPCMD[@]}" REAPCMD <<< "$INGARG"
if [ "$INGARG" == "--" ]; then
FOUNDREAP=1
fi
else
mapfile -t -O "${#WIPAGCMD[@]}" WIPAGCMD <<< "$INGARG"
fi
done <<< "$(printf "%s\n" "${INGCMD[@]}")"
else
while read -r INGARG; do
mapfile -t -O "${#WIPAGCMD[@]}" WIPAGCMD <<< "$INGARG"
done <<< "$(printf "%s\n" "${INGCMD[@]}")"
fi
THISREAP="${REAPCMD[*]}"
THISREAP="${THISREAP% SteamLaunch*}"
if [ -z "$LASTREAP" ] || { [ -n "$LASTREAP" ] && [ "$LASTREAP" != "$THISREAP" ];}; then
updateConfigEntry "LASTREAP" "$THISREAP" "$STLDEFGLOBALCFG"
fi
# This was part of reaper code, may not be needed anymore
while read -r INGARG; do
mapfile -t -O "${#WIPAGCMD[@]}" WIPAGCMD <<< "$INGARG"
done <<< "$(printf "%s\n" "${INGCMD[@]}")"

# if the SLR is called from command line put it into an array as well
## NOTE 28/05/23 - May not be needed anymore?
if [ "$HAVESLR" -eq 1 ]; then
FOUNDSLR=0
while read -r ORGARG; do
Expand Down Expand Up @@ -2700,7 +2674,6 @@ function setDefaultCfgValues {
if [ -z "$USESLR" ] ; then USESLR="1"; fi
if [ -z "$FORCESLR" ] ; then FORCESLR="0"; fi
if [ -z "$USEREAP" ] ; then USEREAP="1"; fi
if [ -z "$FORCEREAP" ] ; then FORCEREAP="0"; fi
if [ -z "$USEPROTON" ] ; then USEPROTON="$(getDefaultProton)"; fi
if [ -z "$REDIRCOMPDATA" ] ; then REDIRCOMPDATA="disabled"; fi
if [ -z "$REDIRSTEAMUSER" ] ; then REDIRSTEAMUSER="disabled"; fi
Expand Down Expand Up @@ -3208,8 +3181,6 @@ function saveCfg {
echo "FORCESLR=\"$FORCESLR\""
echo "## $DESC_USEREAP"
echo "USEREAP=\"$USEREAP\""
echo "## $DESC_FORCEREAP"
echo "FORCEREAP=\"$FORCEREAP\""
echo "## $DESC_USEPROTON"
echo "USEPROTON=\"$USEPROTON\""
echo "## $DESC_REDIRCOMPDATA"
Expand Down Expand Up @@ -5127,7 +5098,6 @@ function AllSettingsEntriesDummyFunction {
--field=" $GUI_USESLR!$DESC_USESLR ('USESLR')":CHK "${USESLR/#-/ -}" `#CAT_Proton` `#SUB_Checkbox` `#MENU_GAME` \
--field=" $GUI_FORCESLR!$DESC_FORCESLR ('FORCESLR')":CHK "${FORCESLR/#-/ -}" `#CAT_Proton` `#SUB_Checkbox` `#MENU_GAME` \
--field=" $GUI_USEREAP!$DESC_USEREAP ('USEREAP')":CHK "${USEREAP/#-/ -}" `#CAT_Proton` `#SUB_Checkbox` `#MENU_GAME` \
--field=" $GUI_FORCEREAP!$DESC_FORCEREAP ('FORCEREAP')":CHK "${FORCEREAP/#-/ -}" `#CAT_Proton` `#SUB_Checkbox` `#MENU_GAME` \
--field=" $GUI_AUTOLASTPROTON!$DESC_AUTOLASTPROTON ('AUTOLASTPROTON')":CHK "${AUTOLASTPROTON/#-/ -}" `#CAT_Proton` `#SUB_Checkbox` `#MENU_GLOBAL` \
--field=" $GUI_REDIRCOMPDATA!$DESC_REDIRCOMPDATA ('REDIRCOMPDATA')":CB "$(cleanDropDown "${REDIRCOMPDATA/#-/ -}" "disabled!single-proton!global-proton")" `#CAT_Proton` `#MENU_GAME` \
--field=" $GUI_REDIRSTEAMUSER!$DESC_REDIRSTEAMUSER ('REDIRSTEAMUSER')":CB "$(cleanDropDown "${REDIRSTEAMUSER/#-/ -}" "disabled!symlink!restore-backup")" `#CAT_Proton` `#MENU_GAME` \
Expand Down Expand Up @@ -18089,11 +18059,6 @@ function startGame {
writelog "INFO" "${FUNCNAME[0]} - Rebuilding STEAM_COMPAT_TOOL_PATHS variable:"
writelog "INFO" "${FUNCNAME[0]} - Adding RUNPROTON '${RUNPROTON%/*}'"
STEAM_COMPAT_TOOL_PATHS="${RUNPROTON%/*}"
if [ "$HAVESCTP" -eq 1 ] && [ "$USESLR" -eq 1 ]; then
RUNSLA="${RUNSLR[0]}"
writelog "INFO" "${FUNCNAME[0]} - Adding '${RUNSLA%/*}' because USESLR is enabled"
STEAM_COMPAT_TOOL_PATHS="$STEAM_COMPAT_TOOL_PATHS:${RUNSLA%/*}"
fi
writelog "INFO" "${FUNCNAME[0]} - Result: Set STEAM_COMPAT_TOOL_PATHS from '$ORG_STEAM_COMPAT_TOOL_PATHS' to '$STEAM_COMPAT_TOOL_PATHS'"
elif [ "$RUNFORCESLR" -eq 1 ]; then
writelog "INFO" "${FUNCNAME[0]} - Rebuilding STEAM_COMPAT_TOOL_PATHS variable, because SLR was forced"
Expand Down Expand Up @@ -18322,7 +18287,6 @@ function fixCustomMeta {
function initPlay {
HAVESLR=0
HAVESLRCT=0
HAVEREAP=0
HAVESCTP=0
INCOPATH=0
STLPLAY=1
Expand Down Expand Up @@ -19377,19 +19341,19 @@ function setSLRReap {
fi
fi
fi
# ---------------




# Set Reaper command (currently no way to toggle this if we call setSLRReap for non-game launches, doesn't seem to have any negative impact though?)
# ---------------
if [ "$HAVEREAP" -eq 1 ] && [ "$USEREAP" -eq 1 ]; then
writelog "INFO" "${FUNCNAME[0]} - ## reaper command is enabled via USEREAP=$USEREAP - prepending to the current launch command"
SLRCMD=("${REAPCMD[@]}" "${SLRCMD[@]}")
elif [ "$HAVEREAP" -eq 0 ] && [ "$USEREAP" -eq 1 ] && [ -n "$LASTREAP" ] && [ -f "$LASTREAP" ] && [ "$FORCEREAP" -eq 1 ]; then
writelog "INFO" "${FUNCNAME[0]} - ## No reaper command provided from command line, but FORCEREAP is $FORCEREAP, so prepending LASTREAP '$LASTREAP' to the current launch command"
SLRCMD=("$LASTREAP" "SteamLaunch" "AppId=$AID" "--" "${SLRCMD[@]}")
fi
# Reaper is started *by Steam now* after a game launch (i.e. after %command% but *not* before)
# so if reaper is disabled we have to check for and kill it
if [ "$USEREAP" -eq 0 ]; then
if "$PGREP" -x "reaper"; then
writelog "INFO" "${FUNCNAME[0]} - USEREAP is '$USEREAP' and found reaper process, killing it!"
"$PKILL" -9 "reaper"
fi
fi
# ---------------


Expand Down Expand Up @@ -19747,18 +19711,9 @@ function launchSteamGame {
echo "I '${INGCMD[*]}'"
echo "X '${FINALSTARTCMD[*]}'"
echo "$(date) - $GN ($AID) - ======================"
if [ "$HAVESCTP" -eq 0 ] && [ "$HAVEREAP" -eq 0 ]; then
echo "$(date) - $GN ($AID) - HAVESCTP='$HAVESCTP', and HAVEREAP='$HAVEREAP' - assuming ${PROGNAME,,} is used as compat tool - using regular base game command to continue"
elif [ "$HAVESCTP" -eq 0 ] && [ "$HAVEREAP" -eq 1 ]; then
echo "$(date) - $GN ($AID) - HAVESCTP='$HAVESCTP', but also HAVEREAP='$HAVEREAP' - assuming ${PROGNAME,,} is set to both command and compat tool (or compat tool is empty) - steam doesn't provide STEAM_COMPAT_TOOL_PATHS, so have to cut out the reaper line to continue; HAVESLR='$HAVESLR'"
elif [ "$HAVESCTP" -eq 1 ] && [ "$HAVEREAP" -eq 1 ]; then
echo "$(date) - $GN ($AID) - HAVESCTP='$HAVESCTP', and HAVEREAP='$HAVEREAP' - assuming $PROGCMD is used as command line tool - switching proton version is disabled"
elif [ "$HAVESCTP" -eq 1 ] && [ "$HAVEREAP" -eq 0 ]; then
echo "$(date) - $GN ($AID) - HAVESCTP='$HAVESCTP', but also HAVEREAP='$HAVEREAP' - something went wrong - never seen this in the wild"
fi
echo "$(date) - $GN ($AID) - ======================"
echo "$(date) - $GN ($AID) - INITIAL LAUNCH COMAND '${INGCMD[*]}'"
echo "$(date) - $GN ($AID) - HAVESCTP='$HAVESCTP';HAVEREAP='$HAVEREAP';HAVESLR='$HAVESLR';HAVESLRCT='$HAVESLRCT';HAVEINPROTON='$HAVEINPROTON'"
echo "$(date) - $GN ($AID) - HAVESCTP='$HAVESCTP';HAVESLR='$HAVESLR';HAVESLRCT='$HAVESLRCT';HAVEINPROTON='$HAVEINPROTON'"
echo "$(date) - $GN ($AID) - REAPCMD '${REAPCMD[*]}'"
echo "$(date) - $GN ($AID) - RUNSLR '${RUNSLR[*]}'"
echo "$(date) - $GN ($AID) - RUNSLRCT '${RUNSLRCT[*]}'"
Expand Down