* Fixed compiling on Mac/Linux

* Fixed "return to NK2O" not working with neek.
This commit is contained in:
cyan06 2015-07-07 19:34:32 +00:00
parent f49b732a3b
commit be6092e1e9
4 changed files with 161 additions and 157 deletions

View File

@ -2,8 +2,8 @@
<app version="1">
<name> USB Loader GX</name>
<coder>USB Loader GX Team</coder>
<version>3.0 r1250</version>
<release_date>20150705141019</release_date>
<version>3.0 r1251</version>
<release_date>20150707190220</release_date>
<!-- // remove this line to enable arguments
<arguments>
<arg>--ios=250</arg>

View File

@ -1547,6 +1547,7 @@ int GameBooter::BootNeek(struct discHdr *gameHdr)
u64 returnToChoice = game_cfg->returnTo;
const char *NandEmuPath = game_cfg->NandEmuPath.size() == 0 ? Settings.NandEmuChanPath : game_cfg->NandEmuPath.c_str();
bool autoboot = true;
bool NK2O_isInstalled = false;
char tempPath[100] = "";
int ret = -1;
@ -1655,6 +1656,12 @@ int GameBooter::BootNeek(struct discHdr *gameHdr)
if(CheckFile(tempPath))
RemoveFile(tempPath);
}
else
{
snprintf(tempPath, sizeof(tempPath), "%s/title/00010001/4e4b324f/content/title.tmd", NandEmuPath);
if(CheckFile(tempPath))
NK2O_isInstalled = true;
}
// Every checks passed successfully. Continue execution.
@ -1684,19 +1691,16 @@ int GameBooter::BootNeek(struct discHdr *gameHdr)
if(autoboot && returnToChoice)
{
// Todo : allow user to select the channel to return to.
// check if NK2O is installed
snprintf(tempPath, sizeof(tempPath), "%s/title/00010001/4e4b324f/content/title.tmd", NandEmuPath);
if(CheckFile(tempPath))
if(NK2O_isInstalled)
{
neek_config->returnto = TITLE_ID(0x00010001, 'NK2O'); // Currently forced to NK2O user channel
neek_config->config |= NCON_EXT_RETURN_TO; // enable "return to" patch
neek_config->config |= NCON_EXT_RETURN_TO; // enable "return to" patch
}
if(isWiiU())
{
neek_config->returnto = TITLE_ID(0x00010002, 'HCVA');// Currently forced to "Return to WiiU" system channel
neek_config->config |= NCON_EXT_RETURN_TO; // enable "return to" patch
neek_config->returnto = TITLE_ID(0x00010002, 'HCVA'); // Currently forced to "Return to WiiU" system channel
neek_config->config |= NCON_EXT_RETURN_TO; // enable "return to" patch
}
}