mainloop: Fix up controller sticks and axes also on SDL builds for GNU/Linux

This commit is contained in:
Sebastian Krzyszkowiak 2022-07-19 05:04:47 +02:00
parent 7094ce5b95
commit e27ebd4618
No known key found for this signature in database
GPG key ID: E8F235CF3BDBC3FF

View file

@ -114,7 +114,9 @@ static inline bool HandleEvent(struct Game* game, ALLEGRO_EVENT* ev) {
al_reconfigure_joysticks(); al_reconfigure_joysticks();
break; break;
case ALLEGRO_EVENT_JOYSTICK_AXIS: case ALLEGRO_EVENT_JOYSTICK_AXIS:
#if (ALLEGRO_VERSION_INT >= ((5 << 24) | (2 << 16) | (5 << 8))) #if (defined(ALLEGRO_SDL) && !defined(__SWITCH__) && !defined(__vita__))
if (true) {
#elif (ALLEGRO_VERSION_INT >= ((5 << 24) | (2 << 16) | (5 << 8)))
if ((al_get_system_id() == ALLEGRO_SYSTEM_ID_XGLX) || (al_get_system_id() == ALLEGRO_SYSTEM_ID_RASPBERRYPI)) { if ((al_get_system_id() == ALLEGRO_SYSTEM_ID_XGLX) || (al_get_system_id() == ALLEGRO_SYSTEM_ID_RASPBERRYPI)) {
#elif defined(ALLEGRO_WITH_XWINDOWS) #elif defined(ALLEGRO_WITH_XWINDOWS)
if (true) { if (true) {