[bb] Proper Key Names by dapsycho [ 1+ years ago ]

Started by BlitzBot, June 29, 2017, 00:28:41

Previous topic - Next topic

BlitzBot

Title : Proper Key Names
Author : dapsycho
Posted : 1+ years ago

Description : Didnt know exactly what title to call this but heres a good description.

What I wanted was a function that would return the proper keyname when a user pressed a key. This was for my game so that the user could map keys to the right functions and would be presented with a proper name instead of the scancode or be limited to A-Z or 0-9.

This little bit of code (about 60 lines) will do exactly that. If you run it and press the Right Alt key it will display the scancode plus the key name (Right Alt).

Hope anyone finds this useful.


Code :
Code (blitzbasic) Select
Please go here for a v.small 2k download:

http://www.blitzcoder.com/cgi-bin/showcase/showcase_showentry.pl?id=dapsycho05102002182739&comments=no


Comments : none...