diff --git a/src/input_core/input_core.cpp b/src/input_core/input_core.cpp index 99447c0bd..71524a7c4 100644 --- a/src/input_core/input_core.cpp +++ b/src/input_core/input_core.cpp @@ -4,6 +4,7 @@ #include #include +#include #include #include "core/core_timing.h" @@ -177,7 +178,7 @@ void InputCore::BuildKeyMapping() { for (size_t i = 0; i < Settings::values.input_mappings.size(); i++) { auto val = KeyMap::mapping_targets[i]; auto key = Settings::values.input_mappings[i]; - key_mappings.try_emplace(key, std::vector()); + key_mappings.emplace(key, std::vector()); key_mappings[key].push_back(val); } } @@ -219,7 +220,7 @@ void InputCore::ParseSettings() { } std::tuple InputCore::ApplyDeadzone(float x, float y, float dead_zone) { - float magnitude = sqrt((x * x) + (y * y)); + float magnitude = std::sqrt((x * x) + (y * y)); if (magnitude < dead_zone) { x = 0; y = 0;