Skip to content

Commit

Permalink
Win32|Fixed: Initialize DirectInput before joystick init
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed Mar 20, 2012
1 parent f31069f commit dd241bd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions doomsday/engine/win32/src/joystick.c
Expand Up @@ -364,6 +364,8 @@ static boolean directInputInit(void)
Con_Message(" DirectInput init failed.\n");
return false;
}

return true;
}

static void directInputShutdown(void)
Expand Down Expand Up @@ -399,6 +401,8 @@ boolean Joystick_Init(void)
return false;
}

if(!directInputInit()) return false;

// ddi will contain info for the joystick device.
memset(&firstJoystick, 0, sizeof(firstJoystick));
memset(&ddi, 0, sizeof(ddi));
Expand Down

0 comments on commit dd241bd

Please sign in to comment.