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

problems compiling directinput library

Started by skynethk Nov 10, 2004 at 3:38 PM 0 replies 400+ views
Original Post
skynethk
skynethk
Im having trouble compiling the header file for my directInput functions that i plan on including in my program. The error i keep getting is: error C2146: syntax error : missing ';' before identifier 'lpdi' fatal error C1004: unexpected end of file found The code for the header file is: #ifndef inputHasBeenIncluded #define inputHasBeenIncluded #include #include #include #include int inputInit(void); void inputShutdown(void); int inputInitMouse(void); int inputInitKeyboard(void); int inputReadMouse(void); int inputReadKeyboard(void); void inputReleaseMouse(void); void inputReleaseKeyboard(void); extern LPDIRECTINPUT8 lpdi; extern LPDIRECTINPUTDEVICE8 lpdikey; extern LPDIRECTINPUTDEVICE8 lpdimouse; extern UCHAR keyboard_state[256]; extern DIMOUSESTATE mouse_state; #endif Any help would be greatly appreciated.
circlesoft
circlesoft
Your LPDIRECTINPUT8 lpdi; declaration seems to be right, and you are including dinput.h.

Is the DX8 or DX9 SDK include directory in your list of include directories in Visual Studio? If it isn't, you could be including an older version that doesn't have the needed declarations.

Topic Locked

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

Sign in to reply to this topic.