From 5240e75be20791d5226e7ac589a09a102755edf2 Mon Sep 17 00:00:00 2001 From: skidau Date: Mon, 7 Jan 2013 12:25:18 +1100 Subject: Fixed the infinite rumble problem caused by r4d6056f14625. --- .../InputCommon/Src/ControllerInterface/DInput/DInputJoystick.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'Source/Core/InputCommon/Src/ControllerInterface') diff --git a/Source/Core/InputCommon/Src/ControllerInterface/DInput/DInputJoystick.cpp b/Source/Core/InputCommon/Src/ControllerInterface/DInput/DInputJoystick.cpp index b7ac3bf82e..af6ee7e77c 100644 --- a/Source/Core/InputCommon/Src/ControllerInterface/DInput/DInputJoystick.cpp +++ b/Source/Core/InputCommon/Src/ControllerInterface/DInput/DInputJoystick.cpp @@ -535,11 +535,7 @@ ControlState Joystick::Hat::GetState() const void Joystick::ForceConstant::SetState(const ControlState state) { - float force = abs(state - 0.5) * 2; - if (state < 0.5) - force = -force; - - const LONG new_val = LONG(10000 * force); + const LONG new_val = LONG(10000 * state); LONG &val = params.lMagnitude; if (val != new_val) -- cgit v1.2.3