Binding a keyboard shortcut to a player action
It is relatively easy to reassign an existing action to a different keystroke in the files UDKInput.INI or DefaultInput.INI. It is somewhat harder to create a unique action. In this recipe we will be making the O key toggle a burst of light which lasts as long as you hold the key, then fades back out. I've chosen the letter O just because this key isn't defined by default in the UDK configuration. What this could be used for is triggering a flash light or lantern carried by the player, or illuminating the scene when casting spells.
Getting ready
The scene we'll use has a dark ambiance, Packt_06_KeyChange_Start.UDK.
The next screenshot is the result (when we've reached our goal) of flashing a bright light in the room:
How to do it...
The configuration part
Open the scene if you like and look around, but eventually you should close it, and close UDK, as we need to set configuration with UDK closed.
Open ConTEXT and choose File | Open and browse for...