Thread: DirectX DirectInput problem

  1. #1
    Registered User
    Join Date
    Jul 2005
    Posts
    33

    Question DirectX DirectInput problem

    I'm making a game where you pilot a space ship through an asteroid field so it will act like a flight simulator. Up and Down for pitch, left and right for roll, and a and d for rudder controls.

    I needed to start using direct input over windows messages because of the key repeat rate messing the rotations up. So I got directinput all set up, and it is receiving commands

    Anyways, my problem is this:

    For every keyup event that controls the roll, pitch, or rudder, I tell the ship frame and camera frame to stop rotating. If you havn't guessed my problem here it is..... My ship and camera are always being told to stop rotating because even while one direction key is down, the other five are up and still telling the program to stop the rotations. And of course, now I can't rotate.

    So what I'm asking is how to tell direct input that I only want the ship and camera to stop rotating if the key has just gone up, not whenever its not down.

  2. #2
    Registered User
    Join Date
    Jul 2005
    Posts
    33
    ohhhhhh maybe I should have posted this in the game section I just registered for the forums and I didn't notice the category.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. searching problem
    By DaMenge in forum C Programming
    Replies: 9
    Last Post: 09-12-2005, 01:04 AM
  2. Bin packing problem....
    By 81N4RY_DR460N in forum C++ Programming
    Replies: 0
    Last Post: 08-01-2005, 05:20 AM
  3. Words and lines count problem
    By emo in forum C Programming
    Replies: 1
    Last Post: 07-12-2005, 03:36 PM
  4. half ADT (nested struct) problem...
    By CyC|OpS in forum C Programming
    Replies: 1
    Last Post: 10-26-2002, 08:37 AM
  5. binary tree problem - help needed
    By sanju in forum C Programming
    Replies: 4
    Last Post: 10-16-2002, 05:18 AM