Allow setting different profiles for different controllers, and automatically use the appropriate profile directory.
This commit is contained in:
1 parent
b8691df723
commit
e32b1526b3
6 files changed
+44
-23
No files matched your search
@@ -136,11 +136,6 @@ bool BootCore(const std::string& _rFilename)
|
||||
}
|
||||
}
|
||||
|
||||
if (game_ini.Exists("Core", "WiiProfile"))
|
||||
game_ini.Get("Core", "WiiProfile", &StartUp.strWiiControllerProfile);
|
||||
if (game_ini.Exists("Core", "GCProfile"))
|
||||
game_ini.Get("Core", "GCProfile", &StartUp.strGCControllerProfile);
|
||||
|
||||
// Run the game
|
||||
// Init the core
|
||||
if (!Core::Init())
|
||||
@@ -158,6 +153,7 @@ void Stop()
|
||||
|
||||
SCoreStartupParameter& StartUp = SConfig::GetInstance().m_LocalCoreStartupParameter;
|
||||
|
||||
StartUp.m_strUniqueID = "00000000";
|
||||
if (config_cache.valid)
|
||||
{
|
||||
config_cache.valid = false;
|
||||
@@ -173,8 +169,6 @@ void Stop()
|
||||
StartUp.bDSPHLE = config_cache.bDSPHLE;
|
||||
StartUp.bDisableWiimoteSpeaker = config_cache.bDisableWiimoteSpeaker;
|
||||
StartUp.m_strVideoBackend = config_cache.strBackend;
|
||||
StartUp.strGCControllerProfile = "";
|
||||
StartUp.strWiiControllerProfile = "";
|
||||
VideoBackend::ActivateBackend(StartUp.m_strVideoBackend);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -139,8 +139,6 @@ struct SCoreStartupParameter
|
||||
int iTheme;
|
||||
int iPosX, iPosY, iWidth, iHeight;
|
||||
|
||||
std::string strGCControllerProfile;
|
||||
std::string strWiiControllerProfile;
|
||||
enum EBootBS2
|
||||
{
|
||||
BOOT_DEFAULT,
|
||||
|
||||
@@ -56,7 +56,7 @@ void Initialize(void* const hwnd)
|
||||
g_controller_interface.Initialize();
|
||||
|
||||
// load the saved controller config
|
||||
g_plugin.LoadConfig(SConfig::GetInstance().m_LocalCoreStartupParameter.strGCControllerProfile);
|
||||
g_plugin.LoadConfig(true);
|
||||
}
|
||||
|
||||
void GetStatus(u8 _numPAD, SPADStatus* _pPADStatus)
|
||||
|
||||
@@ -45,7 +45,7 @@ void Initialize(void* const hwnd)
|
||||
g_controller_interface.SetHwnd(hwnd);
|
||||
g_controller_interface.Initialize();
|
||||
|
||||
g_plugin.LoadConfig(SConfig::GetInstance().m_LocalCoreStartupParameter.strWiiControllerProfile);
|
||||
g_plugin.LoadConfig(false);
|
||||
|
||||
WiimoteReal::Initialize();
|
||||
|
||||
|
||||
Reference in new issue
Block a user