View Single Post
Old 01-08-2007, 10:52 AM   #5 (permalink)
redhead
Newbie
 
redhead's Avatar
 
Join Date: Jun 2002
Location: Denmark
Posts: 1,693
redhead is on a distinguished road
Write a wrapper, through which you run your game.
Have the wrapper say
  • Any key press, send unchanged to child process.
  • if no key-press within N seconds from last key press, send X-key to child process.
  • Anything returned from child, send unchanged to parent stdout/error
If it's controled stricktly through keyboard bindings, then it's not that difficult, but if it's controled through mouse-movements aswell, then it will introduce some difficulties, which you can overcome, but not without alot of trouble.
__________________
Don't worry Ma'am, We're university students, We know what We're doing.
-----
If you pull the pin, Mr.Grenade would no longer be your friend.
-----
01000111 01101111 00100000 01000011 00100000 00100001
redhead is offline   Reply With Quote