From 5609609fb74558f6670fa36f9a552a96edc7c704 Mon Sep 17 00:00:00 2001 From: Edouard Durand Date: Sun, 16 Aug 2026 11:31:40 +0800 Subject: [PATCH] rpcs3-sa: keep the wiki config database fresh RPCS3 applies per-game settings from a wiki-curated config database (GuiConfigs/config_database.dat) at boot, including headless boots, but only the desktop GUI ever downloads that file, and on these builds the GUI never runs, so games launch without the curated fixups. Fetch the database at launch when the cached copy is missing or older than a week. Offline launches fail fast on the connect timeout, and the download is validated before it replaces the cached file. --- .../standalone/rpcs3-sa/scripts/start_rpcs3.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/projects/ROCKNIX/packages/emulators/standalone/rpcs3-sa/scripts/start_rpcs3.sh b/projects/ROCKNIX/packages/emulators/standalone/rpcs3-sa/scripts/start_rpcs3.sh index 6e98185d6fc..f6b16acc1a2 100755 --- a/projects/ROCKNIX/packages/emulators/standalone/rpcs3-sa/scripts/start_rpcs3.sh +++ b/projects/ROCKNIX/packages/emulators/standalone/rpcs3-sa/scripts/start_rpcs3.sh @@ -28,6 +28,19 @@ for FOLDER_LINK in "${FOLDER_LINKS[@]}"; do ln -sf "$TARGET_FOLDER" "$SOURCE_FOLDER" done +# Refresh the wiki config database when online and older than a week; RPCS3 +# applies it per game at boot. The desktop GUI can force a refresh anytime. +CONFIG_DB="/storage/.config/rpcs3/GuiConfigs/config_database.dat" +if [ -z "$(find "${CONFIG_DB}" -mtime -7 2>/dev/null)" ]; then + mkdir -p "$(dirname "${CONFIG_DB}")" + if curl -sf --connect-timeout 3 --max-time 15 "https://api.rpcs3.net/config/?api=v1" -o "${CONFIG_DB}.tmp" \ + && grep -q '"games"' "${CONFIG_DB}.tmp"; then + mv "${CONFIG_DB}.tmp" "${CONFIG_DB}" + else + rm -f "${CONFIG_DB}.tmp" + fi +fi + #Emulation Station Features GAME=$(echo "${1}"| sed "s#^/.*/##") PLATFORM=$(echo "${2}"| sed "s#^/.*/##")