• Content count

  • Joined

  • Last visited

Community Reputation

100 Neutral

About himynameisnick

  • Rank
  1. moving in a 3d space: movement delay when pressing keys

    [quote name='karwosts' timestamp='1301176955' post='4790793'] Sounds like it might have something to do with how you're capturing key events. I get the feeling your half second delay is the time between when you hold down a key and when the OS starts sending character repeats (like when you hold down 'a' in a text editor, it sends it once, than after a 1/2 to 1 second it starts spamming 'aaaaaaaaa' until you release. I'm not that familiar with linux input events, but that sounds like a culprit to me. Are you capturing keyup/keydown messages and setting a state off of that, or are you just moving anytime you get a keydown message? [/quote] I'm capturing keyup/keydown messages. I think you might be right, I noticed when I hit the key it actually moves just a little bit, pauses half a second, and then starts moving again.
  2. Hi, sorry if this has been answered somewhere, I checked google and searched the forums here and found nothing. If it has already been answered I would appreciate any links! This is a project for a computer graphics class I'm in, we are to make an animation or game or do a research paper, and I chose to make a game (duh). Anyway, I created a 3d world that you can fly around in using opengl on a linux machine. The problem is that when I push a key to move, there's a slight delay before you actually start moving, maybe half a second at the most. It's especially annoying when I'm moving forward and then push one of the keys to turn, it works but as soon as I hit the second key it stops moving for half a second and then starts moving again. Does anyone know what's causing the delay? ps. I think the NeHe tutorial 10 is about moving in a 3d space but I'm having trouble getting it to run on my computer. It runs on the machines at my school but I'm not going back there until monday