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 / key press trouble

Author
Message
JNice013
20
Years of Service
User Offline
Joined: 10th Jan 2004
Location:
Posted: 18th Jan 2004 20:58
I'm using DBC

I've been trying to use the scn code and keystate commands but I can't get them working. I've made a menu and i want it to be where if you press the 1 key it moves to a different menu.

Heres my code
SCANCODE()=1
IF KEYSTATE()=1
LOAD IMAGE "Garage.bmp",3
SHOW IMAGE 3

I keep getting errors and can't find a way around it
thanks to anybody who can help me with this.

"The Infamous J Nice"
CattleRustler
Retired Moderator
21
Years of Service
User Offline
Joined: 8th Aug 2003
Location: case modding at overclock.net
Posted: 18th Jan 2004 21:40 Edited at: 18th Jan 2004 21:43
IF KEYSTATE(scancode value) > 0 THEN...

there is a scancode keyboard chart floating around somewhere on these forums. If you can't locate it I'll post the image here.

a=30 I think, so to see if the user pressed a-key:

IF KEYSTATE(30) > 0
LOAD IMAGE "Garage.bmp",3
SHOW IMAGE 3
ENDIF

-RUST-

CattleRustler
Retired Moderator
21
Years of Service
User Offline
Joined: 8th Aug 2003
Location: case modding at overclock.net
Posted: 18th Jan 2004 21:46 Edited at: 18th Jan 2004 21:47


-RUST-

JNice013
20
Years of Service
User Offline
Joined: 10th Jan 2004
Location:
Posted: 20th Jan 2004 03:16
thanks for the scancode castlerustler

"The Infamous J Nice"
CattleRustler
Retired Moderator
21
Years of Service
User Offline
Joined: 8th Aug 2003
Location: case modding at overclock.net
Posted: 20th Jan 2004 05:45


-RUST-

Login to post a reply

Server time is: 2024-09-21 18:42:06
Your offset time is: 2024-09-21 18:42:06