diff --git a/automation_tools/automation_task_list.cfg b/automation_tools/automation_task_list.cfg
index 2c28ed28..cd5908d4 100644
--- a/automation_tools/automation_task_list.cfg
+++ b/automation_tools/automation_task_list.cfg
@@ -3,5 +3,6 @@
hash^DOOMSHAPLACEHOLDER^https://buildbot.libretro.com/assets/cores/DOOM/Doom%20%28Shareware%29.zip
hash^VITASHAPLACEHOLDER^https://github.com/Vita3K/Vita3K/releases/download/continuous/ubuntu-latest.zip
hash^DUCKSTATIONSHAPLACEHOLDER^https://github.com/stenzek/duckstation/releases/download/preview/DuckStation-x64.AppImage
+hash^SAMEDUCKSHAPLACEHOLDER^https://buildbot.libretro.com/nightly/linux/x86_64/latest/sameduck_libretro.so.zip
latestcommit^UNIVERSALDYNAMICINPUTCOMMITPLACEHOLDER^https://github.com/Venomalia/UniversalDynamicInput^main
outside_info^VERSIONPLACEHOLDER^${GITHUB_WORKSPACE}/buildid
diff --git a/es-configs/es_settings.xml b/es-configs/es_settings.xml
index 0b8ab539..9364318d 100644
--- a/es-configs/es_settings.xml
+++ b/es-configs/es_settings.xml
@@ -106,7 +106,7 @@
-
+
@@ -142,3 +142,4 @@
+
diff --git a/functions.sh b/functions.sh
index 9af45dcf..7edf9da7 100644
--- a/functions.sh
+++ b/functions.sh
@@ -290,48 +290,6 @@ cli_compress_all_games() {
done < <(printf '%s\n' "$compressable_systems_list")
}
-desktop_mode_warning() {
- # This function is a generic warning for issues that happen when running in desktop mode.
- # Running in desktop mode can be verified with the following command: if [[ ! $XDG_CURRENT_DESKTOP == "gamescope" ]]; then
- # This function will check if desktop mode is currently being used and if the warning has not been disabled, and show it if needed.
- # USAGE: desktop_mode_warning
-
- if [[ ! $XDG_CURRENT_DESKTOP == "gamescope" ]]; then
- if [[ $desktop_mode_warning == "true" ]]; then
- choice=$(zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap --ok-label="Yes" --extra-button="No" --extra-button="Never show this again" \
- --window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
- --title "RetroDECK Desktop Mode Warning" \
- --text="You appear to be running RetroDECK in the Steam Deck's Desktop mode!\n\nSome functions of RetroDECK may not work properly in Desktop mode, such as the Steam Deck's normal controls.\n\nRetroDECK is best enjoyed in Game mode!\n\nDo you still want to proceed?")
- rc=$? # Capture return code, as "Yes" button has no text value
- if [[ $rc == "1" ]]; then # If any button other than "Yes" was clicked
- if [[ $choice == "No" ]]; then
- exit 1
- elif [[ $choice == "Never show this again" ]]; then
- set_setting_value $rd_conf "desktop_mode_warning" "false" retrodeck "options" # Store desktop mode warning variable for future checks
- fi
- fi
- fi
- fi
-}
-
-low_space_warning() {
- # This function will verify that the drive with the $HOME path on it has at least 10% space free, so the user can be warned before it fills up
- # USAGE: low_space_warning
-
- if [[ $low_space_warning == "true" ]]; then
- local used_percent=$(df --output=pcent "$HOME" | tail -1 | tr -d " " | tr -d "%")
- if [[ "$used_percent" -ge 90 && -d "$HOME/retrodeck" ]]; then # If there is any RetroDECK data on the main drive to move
- choice=$(zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap --ok-label="OK" --extra-button="Never show this again" \
- --window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
- --title "RetroDECK Low Space Warning" \
- --text="Your main drive is over 90% full!\n\nIf your drive fills completely this can lead to data loss or system crash.\n\nPlease consider moving some RetroDECK folders to other storage locations using the Configurator.")
- if [[ $choice == "Never show this again" ]]; then
- set_setting_value $rd_conf "low_space_warning" "false" retrodeck "options" # Store low space warning variable for future checks
- fi
- fi
- fi
-}
-
set_setting_value() {
# Function for editing settings
# USAGE: set_setting_value $setting_file "$setting_name" "$new_setting_value" $system $section_name(optional)
@@ -348,7 +306,7 @@ set_setting_value() {
else
sed -i '\^\['"$current_section_name"'\]^,\^\^'"$setting_name_to_change"'=^s^\^'"$setting_name_to_change"'=.*^'"$setting_name_to_change"'='"$setting_value_to_change"'^' $1
fi
- if [[ "$4" == "retrodeck" ]]; then # If a RetroDECK setting is being changed, also write it to memory for immediate use
+ if [[ "$4" == "retrodeck" && ("$current_section_name" == "" || "$current_section_name" == "paths" || "$current_section_name" == "options") ]]; then # If a RetroDECK setting is being changed, also write it to memory for immediate use
eval "$setting_name_to_change=$setting_value_to_change"
fi
;;
@@ -663,7 +621,7 @@ build_preset_config(){
;;
esac
- done < <(eval cat "$presets_dir/$read_system_name"_presets.cfg)
+ done < <(cat "$presets_dir/$read_system_name"_presets.cfg)
fi
done < <(printf '%s\n' "$preset_section")
done
@@ -793,15 +751,15 @@ do
;;
"add_setting_line" )
- eval add_setting_line $3 "$setting_name" $system_name $current_section
+ add_setting_line $3 "$setting_name" $system_name $current_section
;;
"disable_setting" )
- eval disable_setting $3 "$setting_name" $system_name $current_section
+ disable_setting $3 "$setting_name" $system_name $current_section
;;
"enable_setting" )
- eval enable_setting $3 "$setting_name" $system_name $current_section
+ enable_setting $3 "$setting_name" $system_name $current_section
;;
"change" )
@@ -835,23 +793,38 @@ do
case $action in
"disable_file" )
- eval disable_file "$config_file"
+ if [[ "$config_file" = \$* ]]; then # If patch setting value is a reference to an internal variable name
+ eval config_file="$config_file"
+ fi
+ disable_file "$config_file"
;;
"enable_file" )
- eval enable_file "$config_file"
+ if [[ "$config_file" = \$* ]]; then # If patch setting value is a reference to an internal variable name
+ eval config_file="$config_file"
+ fi
+ enable_file "$config_file"
;;
"add_setting_line" )
- eval add_setting_line "$config_file" "$setting_name" $system_name $current_section
+ if [[ "$config_file" = \$* ]]; then # If patch setting value is a reference to an internal variable name
+ eval config_file="$config_file"
+ fi
+ add_setting_line "$config_file" "$setting_name" $system_name $current_section
;;
"disable_setting" )
- eval disable_setting "$config_file" "$setting_name" $system_name $current_section
+ if [[ "$config_file" = \$* ]]; then # If patch setting value is a reference to an internal variable name
+ eval config_file="$config_file"
+ fi
+ disable_setting "$config_file" "$setting_name" $system_name $current_section
;;
"enable_setting" )
- eval enable_setting "$config_file" "$setting_name" $system_name $current_section
+ if [[ "$config_file" = \$* ]]; then # If patch setting value is a reference to an internal variable name
+ eval config_file="$config_file"
+ fi
+ enable_setting "$config_file" "$setting_name" $system_name $current_section
;;
"change" )
@@ -886,6 +859,17 @@ check_network_connectivity() {
fi
}
+check_desktop_mode() {
+ # This function will do a basic check of if we are running in Steam Deck game mode or not, and return "true" if we are outside of game mode
+ # USAGE: if [[ $(check_desktop_mode) == "true" ]]; then
+
+ if [[ ! $XDG_CURRENT_DESKTOP == "gamescope" ]]; then
+ echo "true"
+ else
+ echo "false"
+ fi
+}
+
check_for_version_update() {
# This function will perform a basic online version check and alert the user if there is a new version available.
@@ -1408,15 +1392,15 @@ prepare_emulator() {
update_splashscreens
dir_prep "$roms_folder" "/var/config/emulationstation/ROMs"
dir_prep "$media_folder" "/var/config/emulationstation/.emulationstation/downloaded_media"
- dir_prep "$themes_folder" "/var/config/emulationstation/.emulationstation/themes"
dir_prep "$rdhome/gamelists" "/var/config/emulationstation/.emulationstation/gamelists"
cp -f /app/retrodeck/es_settings.xml /var/config/emulationstation/.emulationstation/es_settings.xml
+ set_setting_value "es_settings.xml" "UserThemeDirectory" "$themes_folder" "es_settings"
fi
if [[ "$action" == "postmove" ]]; then
dir_prep "$roms_folder" "/var/config/emulationstation/ROMs"
dir_prep "$media_folder" "/var/config/emulationstation/.emulationstation/downloaded_media"
- dir_prep "$themes_folder" "/var/config/emulationstation/.emulationstation/themes"
dir_prep "$rdhome/gamelists" "/var/config/emulationstation/.emulationstation/gamelists"
+ set_setting_value "es_settings.xml" "UserThemeDirectory" "$themes_folder" "es_settings"
fi
fi
@@ -1747,9 +1731,14 @@ prepare_emulator() {
cp -fv "$emuconfigs/ppssppsdl/"* /var/config/ppsspp/PSP/SYSTEM/
set_setting_value "$ppssppconf" "CurrentDirectory" "$roms_folder/psp" "ppsspp" "General"
fi
+ # Shared actions
+ dir_prep "$saves_folder/PSP/PPSSPP-SA" "/var/config/ppsspp/PSP/SAVEDATA"
+ dir_prep "$states_folder/PSP/PPSSPP-SA" "/var/config/ppsspp/PSP/PPSSPP_STATE"
fi
if [[ "$action" == "postmove" ]]; then # Run only post-move commands
set_setting_value "$ppssppconf" "CurrentDirectory" "$roms_folder/psp" "ppsspp" "General"
+ dir_prep "$saves_folder/PSP/PPSSPP-SA" "/var/config/ppsspp/PSP/SAVEDATA"
+ dir_prep "$states_folder/PSP/PPSSPP-SA" "/var/config/ppsspp/PSP/PPSSPP_STATE"
fi
fi
@@ -2658,3 +2647,43 @@ change_preset_dialog() {
echo "No choices made"
fi
}
+
+desktop_mode_warning() {
+ # This function is a generic warning for issues that happen when running in desktop mode.
+ # Running in desktop mode can be verified with the following command: if [[ ! $XDG_CURRENT_DESKTOP == "gamescope" ]]; then
+ # This function will check if desktop mode is currently being used and if the warning has not been disabled, and show it if needed.
+ # USAGE: desktop_mode_warning
+
+ if [[ $(check_desktop_mode) == "true" && $desktop_mode_warning == "true" ]]; then
+ choice=$(zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap --ok-label="Yes" --extra-button="No" --extra-button="Never show this again" \
+ --window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
+ --title "RetroDECK Desktop Mode Warning" \
+ --text="You appear to be running RetroDECK in the Steam Deck's Desktop mode!\n\nSome functions of RetroDECK may not work properly in Desktop mode, such as the Steam Deck's normal controls.\n\nRetroDECK is best enjoyed in Game mode!\n\nDo you still want to proceed?")
+ rc=$? # Capture return code, as "Yes" button has no text value
+ if [[ $rc == "1" ]]; then # If any button other than "Yes" was clicked
+ if [[ $choice == "No" ]]; then
+ exit 1
+ elif [[ $choice == "Never show this again" ]]; then
+ set_setting_value $rd_conf "desktop_mode_warning" "false" retrodeck "options" # Store desktop mode warning variable for future checks
+ fi
+ fi
+ fi
+}
+
+low_space_warning() {
+ # This function will verify that the drive with the $HOME path on it has at least 10% space free, so the user can be warned before it fills up
+ # USAGE: low_space_warning
+
+ if [[ $low_space_warning == "true" ]]; then
+ local used_percent=$(df --output=pcent "$HOME" | tail -1 | tr -d " " | tr -d "%")
+ if [[ "$used_percent" -ge 90 && -d "$HOME/retrodeck" ]]; then # If there is any RetroDECK data on the main drive to move
+ choice=$(zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap --ok-label="OK" --extra-button="Never show this again" \
+ --window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
+ --title "RetroDECK Low Space Warning" \
+ --text="Your main drive is over 90% full!\n\nIf your drive fills completely this can lead to data loss or system crash.\n\nPlease consider moving some RetroDECK folders to other storage locations using the Configurator.")
+ if [[ $choice == "Never show this again" ]]; then
+ set_setting_value $rd_conf "low_space_warning" "false" retrodeck "options" # Store low space warning variable for future checks
+ fi
+ fi
+ fi
+}
diff --git a/net.retrodeck.retrodeck.Configurator.desktop b/net.retrodeck.retrodeck.Configurator.desktop
index ce38bb89..89c01fff 100644
--- a/net.retrodeck.retrodeck.Configurator.desktop
+++ b/net.retrodeck.retrodeck.Configurator.desktop
@@ -4,7 +4,7 @@ GenericName=RetroDECK Configuration Utility
Type=Application
Comment=A handy tool to change common RetroDECK settings
Icon=net.retrodeck.retrodeck
-Exec=--configurator
+Exec=/app/tools/configurator.sh
Terminal=false
StartupNotify=false
Keywords=multi;engine;emulator;standalone;steam;deck
diff --git a/net.retrodeck.retrodeck.yml b/net.retrodeck.retrodeck.yml
index cd350d36..e1f3751c 100644
--- a/net.retrodeck.retrodeck.yml
+++ b/net.retrodeck.retrodeck.yml
@@ -425,6 +425,15 @@ modules:
- type: archive
url: https://buildbot.libretro.com/stable/1.15.0/linux/x86_64/RetroArch_cores.7z
sha256: 2230bc38eaf87406efd0c2b7bdd1cf9e813ba113505600f14a7ef9eb06f8c7c0
+
+ - name: retroarch-sameduck-core
+ buildsystem: simple
+ build-commands:
+ - mv sameduck_libretro.so /app/share/libretro/cores/sameduck_libretro.so
+ sources:
+ - type: archive
+ url: https://buildbot.libretro.com/nightly/linux/x86_64/latest/sameduck_libretro.so.zip
+ sha256: SAMEDUCKSHAPLACEHOLDER
- name: doom-shareware
buildsystem: simple
diff --git a/post_update.sh b/post_update.sh
index dc038419..357f531b 100644
--- a/post_update.sh
+++ b/post_update.sh
@@ -78,6 +78,8 @@ post_update() {
# - Move Duckstation saves and states to new locations
# - Clean up legacy tools files (Configurator is now accessible through the main ES-DE menu)
# - Move Dolphin and Primehack save folder names
+ # - Move PPSSPP saves/states to appropriate folders
+ # - Set ESDE user themes folder directly
update_rd_conf # Expand retrodeck.cfg to latest template
set_setting_value $rd_conf "screenshots_folder" "$rdhome/screenshots"
@@ -163,6 +165,12 @@ post_update() {
dir_prep "$saves_folder/gc/primehack/EU" "/var/data/primehack/GC/EUR"
dir_prep "$saves_folder/gc/primehack/US" "/var/data/primehack/GC/USA"
dir_prep "$saves_folder/gc/primehack/JP" "/var/data/primehack/GC/JAP"
+
+ dir_prep "$saves_folder/PSP/PPSSPP-SA" "/var/config/ppsspp/PSP/SAVEDATA"
+ dir_prep "$states_folder/PSP/PPSSPP-SA" "/var/config/ppsspp/PSP/PPSSPP_STATE"
+
+ set_setting_value "es_settings.xml" "UserThemeDirectory" "$themes_folder" "es_settings"
+ unlink "/var/config/emulationstation/.emulationstation/themes"
fi
# The following commands are run every time.
diff --git a/tools/configurator.sh b/tools/configurator.sh
index 1ea88c00..a97238c7 100644
--- a/tools/configurator.sh
+++ b/tools/configurator.sh
@@ -457,6 +457,8 @@ configurator_open_emulator_dialog() {
;;
esac
+
+ configurator_open_emulator_dialog
}
configurator_retrodeck_tools_dialog() {
@@ -1010,6 +1012,7 @@ configurator_about_retrodeck_dialog() {
--window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
--title "RetroDECK Credits" \
--filename="$emuconfigs/defaults/retrodeck/reference_lists/retrodeck_credits.txt"
+ configurator_about_retrodeck_dialog
;;
"" ) # No selection made or Back button clicked