mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-28 19:58:53 +00:00
Merge pull request #5419 from leoetlino/import-code-reuse
Reuse the IOS code for WAD installation
This commit is contained in:
commit
ed5e98c3cc
18 changed files with 531 additions and 401 deletions
|
@ -983,13 +983,10 @@ bool SConfig::AutoSetup(EBootBS2 _BootBS2)
|
|||
DiscIO::CNANDContentManager::Access().GetNANDLoader(m_strFilename);
|
||||
const IOS::ES::TMDReader& tmd = content_loader.GetTMD();
|
||||
|
||||
if (content_loader.GetContentByIndex(tmd.GetBootIndex()) == nullptr)
|
||||
if (!IOS::ES::IsChannel(tmd.GetTitleId()))
|
||||
{
|
||||
// WAD is valid yet cannot be booted. Install instead.
|
||||
u64 installed = DiscIO::CNANDContentManager::Access().Install_WiiWAD(m_strFilename);
|
||||
if (installed)
|
||||
SuccessAlertT("The WAD has been installed successfully");
|
||||
return false; // do not boot
|
||||
PanicAlertT("This WAD is not bootable.");
|
||||
return false;
|
||||
}
|
||||
|
||||
SetRegion(tmd.GetRegion(), &set_region_dir);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue