Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Compile error /dinput)

This topic is 5489 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Okay, I know this is kinda stupid but I get a "missing ; before *" error when I run this code. I´m linking dinput8.lib and the header dinput.h (as you can see below). I´m really tired so plz don´t hit me for asking what I´ve missed.
//This class sets up a camera and uses DirectInput 

//to rotate, and move the camera


#define DXERRORCHK(function,type) if(FAILED(function)){MessageBox(NULL,type,"Error",MB_OK); return false;}

class CCamera
	bool Initialize(HINSTANCE hInstance);

	IDirectInput8 *p_iDInput8; //Create a pointer to an instance of a dinput object

	IDirectInputDevice8 *p_iDInputDevice8;

bool CCamera::Initialize(HINSTANCE hInstance)
	//Create the dinput object

	DirectInput8Create(hInstance, DIRECTINPUT_VERSION, IID_DirectInput8,
	//Create our keyboard device

		"Failed to create keyboard device");
	//Set data format

		"Failed to set keyboard format");


Bad Monkey Productions

Share this post

Link to post
Share on other sites
Just a thought, but if you''re providing the paths to the DirectX SDK by using the Tools->Options->Directories tab (in vc6 at least), make sure the SDK entries are above the visual studio directories.

If you don''t, the compiler includes the DirectX files that came with VC6, which will be DirectX v3, which won''t have any DInput8 stuff.

Of course, if you''re not using visual studio, this is all guff...

Share this post

Link to post
Share on other sites
Heh got it working, forgot that I reinstalled the sdk Thanks for the help anyhow

[edited by - shakazed on July 8, 2003 4:41:11 PM]

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!