It's exactly the same as posted already.
GetAsyncKeyState('A') & 0x01
Help keyboard reconizing 2 players
Thanks :) wasnt sure if that was legal to do on all letters (eg. another letter could have 0x002) thanks for clearing it up :D
The GetAsyncKeyState call returns the current state of the key in question. Every key has the same potential return values. 0x80 corresponds to the 'currently pressed' bit, and 0x01 corresponds to the 'was pressed since last time' bit.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement