Browse Source

Merge pull request #53251 from LATRio/53224

Rémi Verschelde 4 years ago
parent
commit
bc0f5d3dde
1 changed files with 2 additions and 0 deletions
  1. 2 0
      core/input/input_event.cpp

+ 2 - 0
core/input/input_event.cpp

@@ -864,6 +864,8 @@ void InputEventMouseMotion::_bind_methods() {
 ///////////////////////////////////
 
 void InputEventJoypadMotion::set_axis(JoyAxis p_axis) {
+	ERR_FAIL_INDEX(p_axis, JOY_AXIS_MAX);
+
 	axis = p_axis;
 	emit_changed();
 }