Jump to content
  • Advertisement
Sign in to follow this  

Problem with DirectInput8Create while debugging

This topic is 4615 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

Hi, i am a newbie...here is my code.....
BOOL cInput::Init(HWND hWnd, HINSTANCE hInst)
  // Free a prior Init
  // Record parent Window handle
  m_hWnd = hWnd;
  // Create a DirectInput interface  \\m_pDI =    NULL;
  if(FAILED(DirectInput8Create( hInst, DIRECTINPUT_VERSION, IID_IDirectInput8, (void**)&m_pDI, NULL)))
  return FALSE;
  // Return a success
  return TRUE;
i use VC++ 6.0 and directx 9 sdk can anybody tell me whats wrong with this code ,it compiles n runs fine but while debugging at line "DirectInput8Create" it exits to the assembly gives dialog "userbreakpoint called at .....".here the hInst is valid...n even rest seems fine for me.any kind of help is welcomed. thanks in advance... [Edited by - Muhammad Haggag on November 28, 2005 4:36:09 AM]

Share this post

Link to post
Share on other sites
Thanks a lot for replying...
i call this from another class
m_Input.Init(GethWnd(), GethInst());
GethWnd(),GethInst() returns the handler(m_hWnd) and the instace of the window( m_hInst) respectively....
m_hWnd = CreateWindow(m_Class, m_Caption,WS_OVERLAPPEDWINDOW,
m_XPos, m_YPos,
m_Width, m_Height,
NULL, NULL, m_hInst, NULL);

the debugging escapes to disassembly as it leaves the line DirectInput8Create so i dont get to know what it returns...

hope so this will do

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • 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!