From 1121e5419d6249112ec1011e204930660dc39160 Mon Sep 17 00:00:00 2001 From: the-sane <3657071+the-sane@users.noreply.github.com> Date: Wed, 6 Nov 2024 16:12:33 -0500 Subject: [PATCH] Redirect output to a log file to remove RSI Launcher's need for a terminal --- lib/sc-launch.sh | 13 ++++++++----- lug-helper.sh | 4 ---- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/lib/sc-launch.sh b/lib/sc-launch.sh index 78f0660..8a034ff 100755 --- a/lib/sc-launch.sh +++ b/lib/sc-launch.sh @@ -17,7 +17,7 @@ # If you do not wish to use the above .desktop files, simply run this script # from your terminal. # -# version: 1.3 +# version: 1.4 ################################################################################ ################################################################ @@ -25,6 +25,8 @@ # Add additional environment variables here as needed ################################################################ export WINEPREFIX="$HOME/Games/star-citizen" +launch_log="$WINEPREFIX/sc-launch.log" + export WINEDLLOVERRIDES=winemenubuilder.exe=d # Prevent updates from overwriting our .desktop entries export WINEDEBUG=-all # Cut down on console debug messages export EOS_USE_ANTICHEATCLIENTNULL=1 @@ -33,9 +35,10 @@ export __GL_SHADER_DISK_CACHE=1 export __GL_SHADER_DISK_CACHE_SIZE=10737418240 export __GL_SHADER_DISK_CACHE_PATH="$WINEPREFIX" export __GL_SHADER_DISK_CACHE_SKIP_CLEANUP=1 -# Mesa (AMD/Intel) Shader Cache Options +# Mesa (AMD/Intel) shader cache options export MESA_SHADER_CACHE_DIR="$WINEPREFIX" export MESA_SHADER_CACHE_MAX_SIZE="10G" +# Optional HUDs #export DXVK_HUD=fps,compiler #export MANGOHUD=1 @@ -86,10 +89,10 @@ trap "update_check; \"$wine_path\"/wineserver -k" EXIT # Launch the game ############################################# # To enable feral gamemode, replace the launch line below with: -# gamemoderun "$wine_path"/wine "C:\Program Files\Roberts Space Industries\RSI Launcher\RSI Launcher.exe" +# gamemoderun "$wine_path"/wine "C:\Program Files\Roberts Space Industries\RSI Launcher\RSI Launcher.exe" > "$launch_log" 2>&1 # # To enable gamescope and feral gamemode, replace the launch line below with the # desired gamescope arguments. For example: -# gamescope --hdr-enabled -W 2560 -H 1440 --force-grab-cursor gamemoderun "$wine_path"/wine "C:\Program Files\Roberts Space Industries\RSI Launcher\RSI Launcher.exe" +# gamescope --hdr-enabled -W 2560 -H 1440 --force-grab-cursor gamemoderun "$wine_path"/wine "C:\Program Files\Roberts Space Industries\RSI Launcher\RSI Launcher.exe" > "$launch_log" 2>&1 -"$wine_path"/wine "C:\Program Files\Roberts Space Industries\RSI Launcher\RSI Launcher.exe" +"$wine_path"/wine "C:\Program Files\Roberts Space Industries\RSI Launcher\RSI Launcher.exe" > "$launch_log" 2>&1 diff --git a/lug-helper.sh b/lug-helper.sh index 15636de..5075e80 100755 --- a/lug-helper.sh +++ b/lug-helper.sh @@ -2926,8 +2926,6 @@ install_game_wine() { sed -i '/^Path=/s/ /\\\s/g' "$home_desktop_file" # Replace icon sed -i "s|^Icon=.*|Icon=$rsi_icon_name|" "$home_desktop_file" - # Make it start in a terminal - echo "Terminal=true" >> "$home_desktop_file" debug_print continue "Updated $home_desktop_file" else debug_print continue "Unable to find $home_desktop_file" @@ -2945,8 +2943,6 @@ install_game_wine() { sed -i '/^Path=/s/ /\\\s/g' "$localshare_desktop_file" # Replace icon sed -i "s|^Icon=.*|Icon=$rsi_icon_name|" "$localshare_desktop_file" - # Make it start in a terminal - echo "Terminal=true" >> "$localshare_desktop_file" debug_print continue "Updated $localshare_desktop_file" else debug_print continue "Unable to find $localshare_desktop_file"