From 402a0f129dce2a71b70745be5ade1c4aa0267d99 Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Fri, 3 Feb 2023 08:50:41 +0300 Subject: [PATCH] engine: platform: sdl: use SDL joystick rumble for Platform_Vibrate --- engine/platform/sdl/in_sdl.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/engine/platform/sdl/in_sdl.c b/engine/platform/sdl/in_sdl.c index 65282890..3957b2e9 100644 --- a/engine/platform/sdl/in_sdl.c +++ b/engine/platform/sdl/in_sdl.c @@ -122,7 +122,8 @@ Platform_Vibrate */ void Platform_Vibrate( float time, char flags ) { - // stub + if( g_joy ) + SDL_JoystickRumble( g_joy, 0xFFFF, 0xFFFF, time * 1000.0f ); } /*