Improving UI Capabilities
Author: Patrick Kelly
The problem I ran into recently was changing a user interface element from a hard-coded single-use blueprint widget into a multiple-use blueprint widget. This was due to my observation of other games struggling to provide simple instructions or tool tips to the user to guide them through the game. We had a widget that prompted the user to press a key to do an action, but in order to re-use this element, we would have had to duplicate and re-code this widget for other actions.
The solution to this problem was creating a data table that stored the action name and prompts for each widget prompt. With this, I could use this data table to initialize the prompt widget that would only last from its instantiation to the keypress that would remove it. From this, the widget prompt could now be changed in one widget blueprint and changed for each prompt that was creating differing instances. E to interact would be called differently that R to reload, but they would both run off the same blue print widget.
Comments
Post a Comment