Initialised all controller interfaces together on CFrame construction to fix the crash that would occur if the controller config were opened before a game was started.
This commit is contained in:
1 parent
5e645732f2
commit
b9fb6ad3e8
6 files changed
+35
-14
No files matched your search
@@ -35,8 +35,9 @@ void Shutdown()
|
||||
// if plugin isn't initialized, init and load config
|
||||
void Initialize(void* const hwnd)
|
||||
{
|
||||
for (unsigned int i=0; i<4; ++i)
|
||||
s_config.controllers.push_back(new GCKeyboard(i));
|
||||
if (s_config.controllers.empty())
|
||||
for (unsigned int i = 0; i < 4; ++i)
|
||||
s_config.controllers.push_back(new GCKeyboard(i));
|
||||
|
||||
g_controller_interface.Initialize(hwnd);
|
||||
|
||||
|
||||
Reference in new issue
Block a user