1
0
mirror of https://github.com/godotengine/godot.git synced 2025-12-06 17:25:19 +00:00

Replace default deadzone magic number with named constant

This commit is contained in:
Malcolm Anderson
2024-11-12 09:43:29 -08:00
parent 0f5f3bc954
commit 829dade53b
5 changed files with 9 additions and 6 deletions

View File

@@ -1097,7 +1097,7 @@ JoyAxis InputEventJoypadMotion::get_axis() const {
void InputEventJoypadMotion::set_axis_value(float p_value) {
axis_value = p_value;
pressed = Math::abs(axis_value) >= 0.5f;
pressed = Math::abs(axis_value) >= InputMap::DEFAULT_DEADZONE;
emit_changed();
}