Skip to main content
GameDev.net gamedev.net
🔒 Locked

XInput help.

Started by Shadeirou Sep 17, 2010 at 2:16 AM 3 replies 2.2k views
Original Post
Shadeirou
Shadeirou
Hey guys,

I'm trying to add support for Xbox 360 controllers into some of my games and am having trouble getting the API to work with Code::Blocks. I have downloaded the latest version of the DirectX SDK and have attempted to you the XInput.h, XInput.lib, and XInput9_1_0.dll files included in the SDK, but I get errors in the form of "error: `__in' was not declared in this scope" in the XInput.h file.

Anyway, can anyone help me to get the Xbox 360 controller API working? If so, I can take it from there. I will absolutely not use Visual Studio and would like to include the API files along with program so that it is easily portable to many different computers without having to install the SDK.

Thanks.
Shadeirou
Shadeirou
Anybody? I know how to link libraries myself, maybe someone just has the XInput library that is separate from the DirectX SDK?
darkelf2k5
darkelf2k5
__in? Maybe you need windows.h
Every time you implement a singleton, God kills a kitten. Please, think of the kittens!
darkelf2k5
darkelf2k5
Try just adding a
#define __in
before including the XInput headers. AFAIK __in is a macro hint only, it does nothing.
Every time you implement a singleton, God kills a kitten. Please, think of the kittens!
Shadeirou
Shadeirou
Thanks! That worked. <3

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.