Alright, I wanted to document here a little on how this will work (basically reminding me what I need to put in the readme file).
First, I took a lazy way out. I don't have guis to manage the ini files, I have menu options to open the ini files. They hardly ever change so it wasn't worth the effort.
On ini file that will probably not change unless Randy adds more mode is DRSModes.ini
[DRSModes]
Raw49=1
Progressive49=2
8-Way=3
4-Way=4
Diagonals=5
2-Way Horizontal=6
2-Way Vertical=7
16-Way=8
Pretty self explainatory. In theory if a new mode is added just add it hear and start using the name in the other files.
I will need controls.dat to generate a controls_dat_moses.ini file when a new version is added. However, since I don't have a gpwiz49 yet I am going to have to guess at what modes are best for what controls.
This file is basically all the control names in FEDEV_descriptions_to_controls.txt from the FEDEV package for controls.dat.
To give you an idea, this file looks like
[CONTROLS]
Just Buttons=8-Way
2-way Joystick (Horizontal)=2-Way Horizontal
2-way Joystick (Vertical)=2-Way Vertical
4-way Joystick=4-Way
Diagonal 4-way Joystick=Diagonals
...
49-way Joystick=Raw49
...
Flightstick (Analog)=Progressive49
Lightgun=8-Way
Analog Gun=Progressive49
...
As you see, you assign the control the key name form DRSModes.ini. yeah, very database like, I know. But I know people aren't going to memorize the number so this will make it easy to figure out what's going on.
Simularly mame_modes.ini takes all the mame control constants (at least the ones I found in listxml) and assigns a DRSMode. Again, since I don't have a gpwiz49 yet the default modes is not final. But since it is an ini file, the purpose of it being an ini file, you can change it to your liking. Yes, before you even ask, there is no joy2way in mame. They default the games to joy8way (hence on of the reasons controls.dat exists). It serves two purposes for them to do it that way, it saves two bits which is why I think they did that in the first place, ran out of bits for something. But also it covers for horizontal and vertical games.
[CONTROLS]
joy4way=4-Way
joy8way=8-Way
trackball=8-Way
doublejoy8way=8-Way
dial=8-Way
paddle=Raw49
stick=Progressive49
lightgun=Raw49
doublejoy4way=4-Way
The final ini file you will want to edit is the override.ini file. This lists games you want to force to a certain mode. Example:
[CONTROLS]
puckman=8-Way
Ulitmately then the setup programs generates a gamemodes.ini file that looks like
[MODES]
puckman=3
puckmana=4
puckmanf=4
puckmanh=4
pacman=4
pacmanf=4
puckmod=4
pacmod=4
newpuc2=4
As you see, the override.ini works.
The program is working and pretty much ready for public. I'm having a couple of issues with fe.donkeyfly.com. I will upload files when I get a chance.
Note: Being that this is driven off of ini files you should be able to adapt it to any emulator. Though how many emus have different control layouts? mame is the only one that comes to mind. Zinc is all 8way games. Neogeo, except for 2 games, is all 8way. same with CPS1 and CPS2, so that covers neoragex, nebula, and kawaks.
console emus should be 8ways.
Anyhow, if the situation occurs it shouldn't be too hard to manually edit the files to make them work for other emulators.
I attached a new pic of the setup GUI.
Note: Everytime you click on generate or setup the settings ini files are reloaded. Especially since now I just tell the computer to open the default app for the ini file. You could have moved or changed some setting using notepad or what have you outside of the program. So these two events need the latest setting info. Don't worry, it takes no time to do this. It basically just refreshes the paths to the ini files.