Add backwards compatibility check for the user dir

This commit is contained in:
the Sane. 2024-08-14 16:19:55 -04:00 committed by GitHub
parent 8fa64ca1ed
commit d8b8b47262
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -682,7 +682,12 @@ getdirs() {
# $game_version is set in the version_menu() function
############################################################################
# The game's user directory
user_dir="$game_path/$game_version/user/client/0"
if [ -d "$game_path/$game_version/USER/Client" ]; then
# Backwards compatibility for older installs
user_dir="$game_path/$game_version/USER/Client/0"
else
user_dir="$game_path/$game_version/user/client/0"
fi
# The location within the USER directory to which the game exports keybinds
keybinds_dir="$user_dir/Controls/Mappings"
# game data mask