Skip to content

Commit

Permalink
Fix automatic mod directory detection broken by the last commit.
Browse files Browse the repository at this point in the history
  • Loading branch information
DreamyCecil committed Jul 27, 2024
1 parent 057aef0 commit 4bffce9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Source/CommandLine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -455,7 +455,9 @@ static size_t DetermineRootDir(const CString &strFile, const CString &strDefault
std::cout << "Assumed game directory " << strGameType << ": " << _strRoot << '\n';

// If path to the file is under a mod directory right after the root
if (strFile.AsLower().StartsWith("mods/")) {
const CString strModDir = strFile.AsLower().substr(iDir);

if (strModDir.StartsWith("mods/")) {
size_t iModNameEnd = strFile.find('/', iDir + 5);

// Get mod directory
Expand Down

0 comments on commit 4bffce9

Please sign in to comment.