Commits

Alex Szpakowski committed cdf964b

Workaround for SDL_HAPTIC_INFINITY failing in Windows is no longer needed (patched in SDL as of 2 months ago)

  • Participants
  • Parent commits 7b1c06f

Comments (0)

Files changed (1)

File src/modules/joystick/sdl/Joystick.cpp

 		memset(&vibration.effect, 0, sizeof(SDL_HapticEffect));
 		vibration.effect.type = SDL_HAPTIC_LEFTRIGHT;
 
-		// SDL's Xinput code has an int. overflow bug with SDL_HAPTIC_INFINITY.
-		const Uint32 long_time = 1000 * 60 * 60 * 2;
-
-		vibration.effect.leftright.length = long_time;
+		vibration.effect.leftright.length = SDL_HAPTIC_INFINITY;
 		vibration.effect.leftright.large_magnitude = Uint16(left * LOVE_UINT16_MAX);
 		vibration.effect.leftright.small_magnitude = Uint16(right * LOVE_UINT16_MAX);