From 56bf1ecc131fa7f0cd152dfaee7fe9c5917d4b40 Mon Sep 17 00:00:00 2001 From: "Anthony J. Bentley" Date: Mon, 9 Oct 2017 03:42:50 -0600 Subject: [PATCH] Treat failed haptics initialization as a warning, not a fatal error. --- src/libui_sdl/main.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/libui_sdl/main.cpp b/src/libui_sdl/main.cpp index dceef640..7c6508c6 100644 --- a/src/libui_sdl/main.cpp +++ b/src/libui_sdl/main.cpp @@ -567,7 +567,11 @@ int main(int argc, char** argv) // http://stackoverflow.com/questions/14543333/joystick-wont-work-using-sdl SDL_SetHint(SDL_HINT_JOYSTICK_ALLOW_BACKGROUND_EVENTS, "1"); - if (SDL_Init(SDL_INIT_EVERYTHING) < 0) + if (SDL_Init(SDL_INIT_HAPTIC) < 0) + { + printf("SDL couldn't init rumble\n"); + } + if (SDL_Init(SDL_INIT_VIDEO | SDL_INIT_AUDIO | SDL_INIT_JOYSTICK) < 0) { printf("SDL shat itself :(\n"); return 1;