Thread: DirectInput woes again....

  1. #1
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,607

    DirectInput woes again....

    Aaaaaaaaaaaaaaaaaaaaaarghhhhhhhhhhhhhhh!!!


    I had to reinstall my OS and my MSDEV and now my code doesn't work. I have defined dinput.lib and dinput8.lib in the link section and I have included <dinput.h> in my code.

    Also I have set the include directory as well to include the DX90SDK/include and yet it still does not recognize IDirectInput8?????

    Why did they make DirectInput compile so assinine? All other files compile fine with no errors except for this stupid DirectInput.

    Please help me get this going. I keep getting missing storage class specifier before '*' with this line.

    IDirectInput8 *pDID;

    And thus this line:

    pDID-><Some_func>;

    Unknown identifier 'pDID' in function <blah blah blah>


    This is stupid....the include path is there, the lib path is there, #define DIRECTINPUT_VERSION 0x0800 is there prior to including dinput.h.

    I'm lost.


    Hint to Microsoft: Try writing some compiler error messages in the friggin English language for once.

  2. #2
    The Defective GRAPE Lurker's Avatar
    Join Date
    Feb 2003
    Posts
    949
    Are you sure you named it pDID? Are you sure there is only one thing with that name? Just checking .
    Do not make direct eye contact with me.

  3. #3
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,607
    Yes, yes and yes. I'm totally lost again as to why this is happening.

  4. #4
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,607
    I figured it out. You are not going to believe this garbage.

    My code was fine.


    Please someone sticky this thread so we don't have to fret with this.


    When you set your global include and library paths to the DirectX SDK They must be at the top of the list

    If they are at the bottom of the list....they will not work - or some of them won't like DirectInput.

    Good now I can set out to do what I wanted to in the first place.....the sound engine.

    ::walks off muttering expletives::

  5. #5
    Registered User
    Join Date
    Apr 2002
    Posts
    1,571
    That's because it searches from top to bottom. You had some other header that had higher priority getting in the way of the one you really wanted.
    "...the results are undefined, and we all know what "undefined" means: it means it works during development, it works during testing, and it blows up in your most important customers' faces." --Scott Meyers

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. DirectInput
    By Lionmane in forum Windows Programming
    Replies: 4
    Last Post: 11-12-2005, 11:43 PM
  2. DirectInput and Dev-C++
    By Niara in forum Game Programming
    Replies: 2
    Last Post: 03-11-2005, 10:20 AM
  3. DirectInput or WM_KEYDOWN question
    By Mecnels in forum Game Programming
    Replies: 4
    Last Post: 03-18-2003, 06:45 AM
  4. My DirectInput tutorial....
    By jdinger in forum A Brief History of Cprogramming.com
    Replies: 1
    Last Post: 06-18-2002, 11:32 PM
  5. DirectInput lost with Alt-Tab
    By jdinger in forum Game Programming
    Replies: 2
    Last Post: 05-11-2002, 11:23 PM