X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Flibgame%2Fjoystick.c;h=d5a78a290465dfa71730ab29d00de1fe7ef23e92;hb=61c3da024802ecc0268bab42d7499fc0346e4fd3;hp=af30a82067eb8812399b6c5eb26f5ca3fdf100e7;hpb=909a0a4d74f274b5c05c16cf595b235aa092fc9a;p=rocksndiamonds.git diff --git a/src/libgame/joystick.c b/src/libgame/joystick.c index af30a820..d5a78a29 100644 --- a/src/libgame/joystick.c +++ b/src/libgame/joystick.c @@ -1,7 +1,7 @@ /*********************************************************** * Artsoft Retro-Game Library * *----------------------------------------------------------* -* (c) 1995-2002 Artsoft Entertainment * +* (c) 1995-2006 Artsoft Entertainment * * Holger Schemel * * Detmolder Strasse 189 * * 33604 Bielefeld * @@ -20,15 +20,17 @@ /* ========================================================================= */ -/* platform dependant joystick functions */ +/* platform dependent joystick functions */ /* ========================================================================= */ #if defined(PLATFORM_UNIX) && !defined(TARGET_SDL) void UnixInitJoysticks() { + static boolean unix_joystick_subsystem_initialized = FALSE; + boolean print_warning = !unix_joystick_subsystem_initialized; int i; - for (i=0; i center) @@ -224,7 +232,7 @@ void CheckJoystickData() int i; int distance = 100; - for(i=0; i= setup.input[i].joy.xmiddle) setup.input[i].joy.xleft = setup.input[i].joy.xmiddle - distance; @@ -317,7 +325,7 @@ int AnyJoystick() int i; int result = 0; - for (i=0; i