Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Getting keyboard input

Author
Message
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 19th Oct 2003 13:31 Edited at: 19th Oct 2003 13:40
All my previous projects have been single player and as such I have used LEFTKEY(), RIGHTKEY() etc.

But with my current project I want the player to choose his own keys. That's the easy bit. What I'm having problems with is being able to read multiple key presses simultainiously.

With LEFTKEY(), RIGHTKEY() DBP automatically recognises simultanious key presses but if the player chooses to use W,A,S,D (for example) then I am stumped.

INKEY$ will only read one key press at a time as will SCANCODE and INPUT requires a carriage return and is therefore useless. Other than those I don't know of any other keyboard input commands.

There must be a way to achieve this, so what am I missing?

Thanks

EDIT - SORRY! My Bad! Please ignore this thread I had a brain failure or something the command I need is KEYSTATE(). It is a command I have used before. I just completely forgot about it

***IF ANY MODERATORS READ THIS PLEASE FEEL FREE TO CALL ME STUPID AND THEN DELETE THE THREAD - SORRY***

Login to post a reply

Server time is: 2024-11-25 12:47:35
Your offset time is: 2024-11-25 12:47:35