I put a behavior called "Keyboard Input" on StencylForge to detect keyboard events of any key pressed released.
Unlike usual I wasn't lazy with comments and fully commented it as well
so I hope it will be easy to use.
In short: Add the behavior to a scene, then write in any scene behavior custom events called "KeyUp" and "KeyDown", and use the custom block "last pressed key" to check which key has been pressed or released. The custom block "last input character" will return the character generated by the last key-up event. It takes into account modifier keys and should work with any keyboard layout.