KeyDown event not found in VB.NET 2010?

jaywash

Baseband Member
Messages
69
Location
Canada
Hai everyone, I've been trying to look at how games and other such applications are made in VB.NET 2010 and they all, of course, use the keydown and keyup events, but when I take a look at VB.NET on my computer I dont seem to have those events, is there something additional i need to install? Thanks to anyone who can give me a hand.
 
There are probably much better ways of doing what you're doing than using raw input.

I mean your window will have focus whilst the person is playing the game, and there would be no other reason that your "games" should want to deal with raw input and capture keystrokes when the game should be in the back ground. or be... I don't know, windowless so that a user doesn't know that the "game" is running...


anyway, the INPUT and KEYDOWN functions are not in standard libraries at all which is why yu don't have those events, they are messages from a raw input buffer. the raw input buffer captures the events, and tells your program that it has these events

you should tailor your google searches toward capturing raw data, you need to tell your program to register it's interest in raw data using RID flags, then use getrawinputdata functions. these are functions of the standard windows library.


As you may have guessed from my initial paragraph, there is little use for capturing raw input inside making games, it's far more likely that this is the sort of thing that you'd be interested in if you were making a key logger.

for that reason, it's pretty unlikely that there are going to be floods of people wanting to help.
but that does give you another avenue of searching, if you can find and understand the source code for a key logger, then you'll be a big step forward to using raw keystroke data in your game.
 
Back
Top Bottom