Merge branch 'cursorspeedmerge' into 'master'

Updated: Change cursor speed with settings.cfg (#6312)

Closes #6312

See merge request OpenMW/openmw!1255

(cherry picked from commit 1d342f80ed1af25d3cf1f70759be7fba1c9237b2)

b5af1928 gamepad cursor speed fix
This commit is contained in:
psi29a 2021-10-01 11:23:53 +00:00
parent 81748f8e3d
commit b81df8af9c
2 changed files with 3 additions and 2 deletions

View File

@ -222,6 +222,7 @@ Programmers
Yuri Krupenin Yuri Krupenin
zelurker zelurker
Noah Gooder Noah Gooder
Andrew Appuhamy (andrew-app)
Documentation Documentation
------------- -------------

View File

@ -98,8 +98,8 @@ namespace MWInput
// We keep track of our own mouse position, so that moving the mouse while in // We keep track of our own mouse position, so that moving the mouse while in
// game mode does not move the position of the GUI cursor // game mode does not move the position of the GUI cursor
float uiScale = MWBase::Environment::get().getWindowManager()->getScalingFactor(); float uiScale = MWBase::Environment::get().getWindowManager()->getScalingFactor();
float xMove = xAxis * dt * 1500.0f / uiScale; float xMove = xAxis * dt * 1500.0f / uiScale * mGamepadCursorSpeed;
float yMove = yAxis * dt * 1500.0f / uiScale; float yMove = yAxis * dt * 1500.0f / uiScale * mGamepadCursorSpeed;
float mouseWheelMove = -zAxis * dt * 1500.0f; float mouseWheelMove = -zAxis * dt * 1500.0f;
if (xMove != 0 || yMove != 0 || mouseWheelMove != 0) if (xMove != 0 || yMove != 0 || mouseWheelMove != 0)