Merge pull request #97068 from Mickeon/allow_joy_axis_invalid

Allow `JOY_AXIS_INVALID` in InputEventJoypadMotion's `axis`
This commit is contained in:
Rémi Verschelde 2024-09-18 17:41:08 +02:00
commit d8a82a8945
No known key found for this signature in database
GPG Key ID: C3336907360768E1

View File

@ -1088,7 +1088,7 @@ void InputEventMouseMotion::_bind_methods() {
///////////////////////////////////
void InputEventJoypadMotion::set_axis(JoyAxis p_axis) {
ERR_FAIL_COND(p_axis < JoyAxis::LEFT_X || p_axis > JoyAxis::MAX);
ERR_FAIL_COND(p_axis < JoyAxis::INVALID || p_axis > JoyAxis::MAX);
axis = p_axis;
emit_changed();