diff options
Diffstat (limited to 'source/gameengine/GameLogic/SCA_JoystickManager.cpp')
-rw-r--r-- | source/gameengine/GameLogic/SCA_JoystickManager.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/gameengine/GameLogic/SCA_JoystickManager.cpp b/source/gameengine/GameLogic/SCA_JoystickManager.cpp index c21db794e42..780e4e9ce88 100644 --- a/source/gameengine/GameLogic/SCA_JoystickManager.cpp +++ b/source/gameengine/GameLogic/SCA_JoystickManager.cpp @@ -60,14 +60,16 @@ SCA_JoystickManager::~SCA_JoystickManager() void SCA_JoystickManager::NextFrame(double curtime,double deltatime) { + // We should always handle events in case we want to grab them with Python +#ifdef WITH_SDL + SCA_Joystick::HandleEvents(); /* Handle all SDL Joystick events */ +#endif + if (m_sensors.Empty()) { return; } else { ; -#ifdef WITH_SDL - SCA_Joystick::HandleEvents(); /* Handle all SDL Joystick events */ -#endif SG_DList::iterator<SCA_JoystickSensor> it(m_sensors); for (it.begin();!it.end();++it) { |