From bf30cc8a7229aa16ad019085b011ba37426eb6ad Mon Sep 17 00:00:00 2001 From: "fires.gc" Date: Fri, 13 Mar 2009 21:45:27 +0000 Subject: [PATCH] added pal/ntsc detection for WADs git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2654 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/Core/Src/CoreParameter.cpp | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/Source/Core/Core/Src/CoreParameter.cpp b/Source/Core/Core/Src/CoreParameter.cpp index 643bfffcfa..192d972740 100644 --- a/Source/Core/Core/Src/CoreParameter.cpp +++ b/Source/Core/Core/Src/CoreParameter.cpp @@ -142,10 +142,23 @@ bool SCoreStartupParameter::AutoSetup(EBootBios _BootBios) } else if (DiscIO::CNANDContentManager::Access().GetNANDLoader(m_strFilename).IsValid()) { + const DiscIO::INANDContentLoader& ContentLoader = DiscIO::CNANDContentManager::Access().GetNANDLoader(m_strFilename); + u64 TitleID = ContentLoader.GetTitleID(); + char* pTitleID = (char*)&TitleID; + + // NTSC or PAL + if ((pTitleID[0] == 'E') || (pTitleID[0] == 'J')) + { + bNTSC = true; + } + else + { + bNTSC = false; + } + bWii = true; Region = EUR_DIR; m_BootType = BOOT_WII_NAND; - bNTSC = false; } else {