Detect Star Citizen installs on any drive and in custom library folders - #7
Merged
Conversation
get_default_paths() previously scanned only drives C-F for the fixed "Roberts Space Industries\StarCitizen" layout, so an install on another drive or in a custom library folder (e.g. G:\Games\StarCitizen) was never found and the app reported "No installations found". - Scan every fixed drive, not just C-F. - Cover common custom roots (Games\StarCitizen, bare StarCitizen, etc.). - Read the authoritative install path from the RSI Launcher log (%APPDATA%\rsilauncher\logs\log.log), which records the real library folder the user picked in the launcher. All candidates are still verified against logbackups on disk before being offered.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
get_default_paths()only scanned drives C-F for the fixed layout…\Roberts Space Industries\StarCitizen. An install on another drive, or in a custom library folder, was never found — the app showed "No installations found" and the user had to browse manually.Example that failed:
G:\Games\StarCitizen\LIVE(drive G isn''t scanned, andGames\StarCitizenisn''t the expected folder name).Changes
Games\Roberts Space Industries\StarCitizen,Games\StarCitizen, bareStarCitizen, in addition to the existing two.%APPDATA%\rsilauncher\logs\log.log), which records the real library folder the user chose, e.g.… Installing Star Citizen LIVE … at G:\Games\StarCitizen. This is the only reliable way to find a fully custom library folder. (The launcher''s own settings store is encrypted, and the path is not in the registry, so the log is the practical source.)…\<ENV>\logbackupson disk before being offered, so stale log entries (old/moved installs) are dropped automatically.Verification
On a machine with the game at
G:\Games\StarCitizen\LIVE(drives C/F/G),get_default_paths()now returns:The stale
C:\Program Files\…entry parsed from the log is correctly discarded (folder no longer exists).ruff checkandpyrightboth pass.Notes