Duke3D: Allow reordering of gamefunc menu entries via DEF command
This merge request is a usability improvement to the existing keybind menus.
Currently, in order to define new keys in a mod, one has to rename one of the existing gamefuncs, disable its behavior, and hook up CON code to that key. One big drawback of this is that the key ends up being placed at the same place in the menu where the original key used to be, which may be far away from more related keys. Currently, it is not possible to reorder these game functions, making it a requirement for the user to search through the keybind menu for any important keys they might have missed.
Additionally, some existing keys, such as "Strafe Left" and "Strafe Right", or the "Steroids" powerup key are placed far away from related keys. Hence the possibility to reorder keybinds would be desired even without redefining a game function.
This merge request includes a series of related commits that enable the reordering of keys for both the keyboard config and mouse/controller config, which is controlled through a DEF command.
DEF command usage:
List the gamefunc names (or corresponding indices) separated by whitespace. This will define the order of gamefuncs on the keyboard configuration menu. Any omitted gamefuncs will not be listed in the menu.
keyconfig
{
gamefunc_Move_Forward
gamefunc_Move_Backward
gamefunc_Strafe_Left
gamefunc_Strafe_Right
...
}