summaryrefslogtreecommitdiff
path: root/core/input
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2023-01-25 09:15:45 +0100
committerRémi Verschelde <rverschelde@gmail.com>2023-01-25 09:15:45 +0100
commit93c650c10dd544ab371582991d6f92e3cdb13b7b (patch)
treeb6d30a7148fa65a3ef0a1595ca5ef5148d4dfac1 /core/input
parent5df9a8412861797caa5949f916b76a4bc229e16a (diff)
parenta4e2978352e5cb92ff71ef1486e1a20d5cf1745d (diff)
Merge pull request #69028 from YeldhamDev/its_raw_you_donkey
Make `Input.get_vector()` check for plain `strength` instead of the raw one
Diffstat (limited to 'core/input')
-rw-r--r--core/input/input.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/input/input.cpp b/core/input/input.cpp
index 1ea9f00fee..3cf83fd64b 100644
--- a/core/input/input.cpp
+++ b/core/input/input.cpp
@@ -349,8 +349,8 @@ float Input::get_axis(const StringName &p_negative_action, const StringName &p_p
Vector2 Input::get_vector(const StringName &p_negative_x, const StringName &p_positive_x, const StringName &p_negative_y, const StringName &p_positive_y, float p_deadzone) const {
Vector2 vector = Vector2(
- get_action_raw_strength(p_positive_x) - get_action_raw_strength(p_negative_x),
- get_action_raw_strength(p_positive_y) - get_action_raw_strength(p_negative_y));
+ get_action_strength(p_positive_x) - get_action_strength(p_negative_x),
+ get_action_strength(p_positive_y) - get_action_strength(p_negative_y));
if (p_deadzone < 0.0f) {
// If the deadzone isn't specified, get it from the average of the actions.