mirror of
https://github.com/godotengine/godot.git
synced 2026-01-06 10:11:57 +03:00
add sign comparison for joystick axis events in InputMap::_find_event
fixes #4400
(cherry picked from commit 3b12f9ea82)
This commit is contained in:
committed by
Rémi Verschelde
parent
c523749662
commit
94b321822d
@@ -106,7 +106,7 @@ List<InputEvent>::Element *InputMap::_find_event(List<InputEvent> &p_list,const
|
||||
} break;
|
||||
case InputEvent::JOYSTICK_MOTION: {
|
||||
|
||||
same=(e.joy_motion.axis==p_event.joy_motion.axis);
|
||||
same=(e.joy_motion.axis==p_event.joy_motion.axis && (e.joy_motion.axis_value < 0) == (p_event.joy_motion.axis_value < 0));
|
||||
|
||||
} break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user