Skip to content

Commit f1a80d4

Browse files
committed
mods path and assets fix pcsx2 [skip ci]
1 parent 35db559 commit f1a80d4

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

pcsx2/component_prepare.sh

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,15 @@ if [[ "$action" == "reset" ]]; then # Run reset-only commands
1818
set_setting_value "$pcsx2_config" "MemoryCards" "$saves_path/ps2/pcsx2/memcards" "pcsx2" "Folders"
1919
set_setting_value "$pcsx2_config" "RecursivePaths" "$roms_path/ps2" "pcsx2" "GameList"
2020
set_setting_value "$pcsx2_config" "Cheats" "$cheats_path/PCSX2" "Folders"
21+
22+
## Backups Old Cheats
2123
if [[ -d "$cheats_path/PCSX2" && "$(ls -A "$cheats_path/PCSX2")" ]]; then
2224
backup_file="$backups_path/cheats/PCSX2-$(date +%y%m%d).tar.gz"
2325
create_dir "$(dirname "$backup_file")"
2426
tar -czf "$backup_file" -C "$cheats_path" PCSX2
2527
log i "PCSX2 cheats backed up to $backup_file"
2628
fi
29+
2730
create_dir -d "$cheats_path/PCSX2"
2831
tar -xzf "$component_extras/pcsx2-cheats.tar.gz" -C "$cheats_path/PCSX2" --overwrite
2932
create_dir "$saves_path/ps2/pcsx2/memcards"
@@ -34,6 +37,14 @@ if [[ "$action" == "reset" ]]; then # Run reset-only commands
3437
dir_prep "$cheats_path/PCSX2/" "$pcsx2_cheats_path"
3538
dir_prep "$videos_path/PCSX2/" "$pcsx2_vidoes_path"
3639

40+
## Backups Mods / Patches
41+
if [[ -d "$mods_path/PCSX2" && "$(ls -A "$mods_path/PCSX2")" ]]; then
42+
backup_file="$backups_path/mods/PCSX2-$(date +%y%m%d).tar.gz"
43+
create_dir "$(dirname "$backup_file")"
44+
tar -czf "$backup_file" -C "$mods_path" PCSX2
45+
log i "PCSX2 patches backed up to $backup_file"
46+
fi
47+
tar -xzf "$component_extras/pcsx2-patches.tar.gz" -C "$mods_path/PCSX2/patches" --overwrite
3748

3849
fi
3950

pcsx2/component_recipe.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,19 @@
8080
"dest": "rd_extras/pcsx2-cheats"
8181
}
8282
]
83+
},
84+
{
85+
"source_url": "https://github.com/PCSX2/pcsx2_patches",
86+
"source_type": "git",
87+
"version": "latest",
88+
"extraction_type": "local",
89+
"assets": [
90+
{
91+
"type": "tar.gz",
92+
"source": "patches/.",
93+
"dest": "rd_extras/pcsx2-patches"
94+
}
95+
]
8396
}
8497
]
8598
}

0 commit comments

Comments
 (0)