Use different path for patched executable. (#70)

* Use different path for patched executable.

* Use error code variant on std::filesystem::create_directories.
This commit is contained in:
Darío
2025-01-10 08:57:34 -03:00
committed by GitHub
parent b9cffba14d
commit 0737ff771d
3 changed files with 29 additions and 33 deletions

View File

@@ -19,8 +19,6 @@
#include <ui/installer_wizard.h>
#include <mod/mod_loader.h>
#define GAME_XEX_PATH "game:\\default.xex"
const size_t XMAIOBegin = 0x7FEA0000;
const size_t XMAIOEnd = XMAIOBegin + 0x0000FFFF;
@@ -171,7 +169,8 @@ int main(int argc, char *argv[])
HostStartup();
bool isGameInstalled = Installer::checkGameInstall(GAME_INSTALL_DIRECTORY);
std::filesystem::path modulePath;
bool isGameInstalled = Installer::checkGameInstall(GAME_INSTALL_DIRECTORY, modulePath);
bool runInstallerWizard = forceInstaller || forceDLCInstaller || !isGameInstalled;
if (runInstallerWizard)
{
@@ -189,7 +188,6 @@ int main(int argc, char *argv[])
KiSystemStartup();
auto modulePath = FileSystem::ResolvePath(GAME_XEX_PATH, false);
uint32_t entry = LdrLoadModule(modulePath);
if (!runInstallerWizard)