Original Post
Howdy: I'm working on a user interface and I am at the point where I have the interface rendering as I want, with limited controls. I can have windows, labels, buttons and not much else at the moment. What I am having a hard time figuring out is how would I let user input be customizable for the application? The GUI is skinnable through an XML skin file. I want to allow users the ability to have their button perform their chosen action. So, playerA might have a SHOOT button on the left of their screen and playerB might have the SHOOT button on the right. This is done through the XML skin. Now, input, I want players to be able to customize their keyboard shortcuts and this is where I have hit a wall. PlayerA might SHOOT with the Z key, PlayerB might shoot with the G key, etc. How would one design this? Also, the shortcut keys should affect the GUI so, if I press Z to SHOOT, the graphics engine should update with my shot, other logic should happen AND the GUI needs to disable the SHOOT button until the timeout elapses and I can SHOOT again. I've found lots of tutorials on how to render the GUI and that is not at all an issue. My problem is how would I translate the input into game functions that would be called when I Press a button on the GUI or press a key on the keyboard. TIA, Webby