Slag-O-Matic Posted June 26, 2022 Share Posted June 26, 2022 (edited) First, thanks to those who responded to my earlier inquiries. You've helped me gain a greater understanding of how this whole system comes together which has made things a LOT easier for me. I'm generally the type of person who would prefer to know how and why something works, rather than just going through the motions and hoping that it works. So, thanks for all that. Now, on to greater things. I've got LB/BB set up with Arcade and so far about a dozen platforms (via MAME and RetroArch) and it's working well, albeit with keyboard and mouse which isn't exactly a fun console experience. So I went out and bought an 8BitDo Arcade Stick in hopes that it'll improve the sofa gaming experience. Largely through trial and error I managed to get the joystick and buttons mapped with BigBox and (mostly) LaunchBox; I'm not terribly concerned about LaunchBox since I'm going to be the only one using that and I'll be on keyboard/mouse for that. But with BigBox it's working well enough. My question is about how to set up the mappings for emulation, and specifically about MAME. With console emulation it's one-size-fits-all, which is to say one mapping profile will work with all games on that console since the controller is the same on every game on that console. But with MAME it's generally unique to each game. It could be as simple as Pac-Man (four-way joystick and nothing else) or something more complicated like Street Fighter II (eight-way joystick and six buttons). And there's the matter of the COIN and P1 START buttons, which largely IS universal across MAME. So my questions are, (a) how does one go about mapping controls on MAME and the various consoles, and (b) within MAME do I really have to map every button to every game? It FEELS like I should be able to make a "universal mapping" of sorts, with games that don't use all of the buttons just ignoring those inputs. (So if I mapped the six buttons intending to play Street Fighter II, and then loaded up Super Mario Brothers which only uses two buttons, SMB should theoretically just ignore those four other buttons, right?) BONUS QUESTION #1: Am I correct in assuming that if I were to buy a second 8BitDo Arcade Stick, I would be able to map the buttons on the second one as the "player two" controller in the same way that I've mapped the solo controller (which defaults to "player one")? And if so, does that follow the same process as the previous (a) and (b) questions, only with specifying the "player two" controller? BONUS QUESTION #2: Assuming I'm right about the "universal mapping" thing, is there a way to do an exception to "universal mapping"? Specifically I'm thinking of games that require two joysticks, such as Battlezone. If I were to buy a second 8BitDo Arcade Stick, could I have it operate as the "player two" controller in all applicable games, but when Battlezone is loaded up (which is exclusively a one-player game) then the mappings change so that I can use the two joysticks on the two controllers to play the game? Edited June 26, 2022 by Slag-O-Matic Quote Link to comment Share on other sites More sharing options...
Lordmonkus Posted June 26, 2022 Share Posted June 26, 2022 In Mame you can set a "global" control scheme which function for just about every game outside of maybe driving games or some other games with odd controllers. This is set in the menu you get when you press Tab on the keyboard under Input (general). These control settings will be defaulted for every game, if you need to do a game specific control scheme you will need to go into the Input (this Machine) section and setup the controls there. This will set the controls for that specific game / rom. If you use Mame for consoles and other systems you will need to do the controls on a machine basis. 18 minutes ago, Slag-O-Matic said: BONUS QUESTION #1: Am I correct in assuming that if I were to buy a second 8BitDo Arcade Stick, I would be able to map the buttons on the second one as the "player two" controller in the same way that I've mapped the solo controller (which defaults to "player one")? And if so, does that follow the same process as the previous (a) and (b) questions, only with specifying the "player two" controller? This should work fine but I do not know for certain, I have no experience with those specific controllers or wireless. 19 minutes ago, Slag-O-Matic said: BONUS QUESTION #2: Assuming I'm right about the "universal mapping" thing, is there a way to do an exception to "universal mapping"? Specifically I'm thinking of games that require two joysticks, such as Battlezone. If I were to buy a second 8BitDo Arcade Stick, could I have it operate as the "player two" controller in all applicable games, but when Battlezone is loaded up (which is exclusively a one-player game) then the mappings change so that I can use the two joysticks on the two controllers to play the game? In this example you gave you should be able to setup the 2 controllers to play that specific game using the {this Machine) controller settings. Mame is extremely flexible with its controller stuff. Quote Link to comment Share on other sites More sharing options...
Slag-O-Matic Posted June 26, 2022 Author Share Posted June 26, 2022 (edited) I again thank you for your help. 🙂 2 hours ago, Lordmonkus said: This is set in the menu you get when you press Tab on the keyboard under Input (general). These control settings will be defaulted for every game, if you need to do a game specific control scheme you will need to go into the Input (this Machine) section and setup the controls there. This will set the controls for that specific game / rom. If you use Mame for consoles and other systems you will need to do the controls on a machine basis. I found the function and was experimenting with it a bit. While I'm able to get it "somewhat" working, it's not 100%. I was experimenting with Street Fighter II Championship Edition as my test case, and use this image for reference on the controller. SF2 has six buttons. Using the arcade machine as the template, buttons X, Y, and RB would be light/medium/heavy punch respectively, while A, B, and RT would be light/medium/heavy kick respectively. I also decided to use the SELECT button as the P1 COIN button, and the START button as the P1 START button. For the moment I'm ignoring the two macro buttons on the controller (the two black buttons in the upper-right corner). I went into Input (general) then Player 1 Controls. In addition to the keyboard and mouse controls, MAME saw all of the buttons on my controller but they were not in the correct order. MAME lists the default buttons thusly: Button 1 (A), Button 2 (B), Button 3 (X), Button 4 (Y), Button 5 (LB), Button 6 (RB), Button 7 (START), Button 8 (BACK). (Note that BACK is how MAME sees the SELECT button on the controller.) I want the buttons to be defined as: Button 1 (X), Button 2 (Y), Button 3 (RB), Button 4 (A), Button 5 (B), Button 6 (RT), Button 7 (LB), Button 8 (LT). (Also note that SF2 doesn't use buttons 7 and 8 but I wanted to define them universally anyway.) Also, by default P1 SELECT (aka P1 COIN) is defined as 5 and P1 START is defined as 1. I want to change them to BACK and START respectively. I was able to remap things as I wanted, but not all of the controls work. The joystick, three kick buttons (A, B, RT), and light punch (X) work, but that's it. Medium and heavy punch (Y and RB) doesn't work, nor does P1 COIN (BACK) or P1 START (START). One thing I did notice: As I was adjusting the mappings, most of the changes I made showed up dimmed out. All of the default settings are in bright white, but when I make an adjustment it's like 50% white. There is no correlation between the color of the mapping and its functionality; some of the dim ones work, some don't. If you have any insight there I'd love to hear it. On a similar note, please check my understanding of how MAME uses config files. As I understand it, MAME stores its configuration files inside of a "cfg" folder within the MAME folder. On a perfectly clean/never used installation of MAME there will be a single file in there called __empty.cfg which is basically a default template that MAME uses. Upon MAME's first launch it will copy that __empty.cfg file as default.cfg. When you go into Input (General) those are the settings you are modifying. When you launch a ROM, MAME looks for a config file that matches the ROM name (e.g., sf2ceusa.cfg). If it finds one then it uses those settings; if you go under Input (This Machine) those are the settings you're modifying. If it doesn't find one then it makes a copy of default.cfg and names it after the ROM (e.g., sf2ceusa.cfg). Now, here's where I get a little uncertain. Let's say I launch SF2CE and (based on my understanding above) MAME copies default.cfg into sf2ceusa.cfg. I make no changes to either the General or This Machine inputs. Then at some point in the future I'm playing Berzerk and I change the General settings. When I go back into SF2CE, are my new adjustments to General going to be reflected there? In other words, does MAME "know" that I didn't tweak any settings in SF2CE and therefore always want SF2CE to use the General settings, or does the mere act of launching SF2CE effectively "lock in" whatever the General settings were at the time I first launched it? If I'm understanding it right, it sounds like the Input (General) settings is NOT "use these settings everywhere UNLESS there's a custom configuration for a specific machine" but rather "use these settings going forward as the default values for any new ROM that's opened". The latter seems very limited and poorly worded (I would have called it "Input (Default Template)" instead) but does seem to be what's happening; the former is what I was expecting. Which is accurate? Thanks yet again. EDIT/UPDATE: So, I kind of answered my own question. I deleted everything inside of my MAME/cfg folder except for __empty.cfg. Through BigBox I launched MAME and SF2CE. The General and This Machine inputs were largely the same. I modified the General settings, quit out of everything, then deleted the sf2ceusa.cfg file from within MAME/cfg. When I relaunched MAME and SF2CE the inputs were copies of all the General settings that I made before. So it seems that it functions as "Default Template" rather than "General" after all. And, oddly enough, after doing all this ALMOST all of the buttons work. The only buttons that aren't working are BACK (SELECT, aka P1 COIN) and START (P1 START). I still have to use the keyboard 5 and 1 for those, respectively. Any ideas why? Edited June 27, 2022 by Slag-O-Matic New information. Quote Link to comment Share on other sites More sharing options...
jrallen81 Posted September 2, 2022 Share Posted September 2, 2022 On 6/26/2022 at 7:18 PM, Slag-O-Matic said: I again thank you for your help. 🙂 I found the function and was experimenting with it a bit. While I'm able to get it "somewhat" working, it's not 100%. I was experimenting with Street Fighter II Championship Edition as my test case, and use this image for reference on the controller. SF2 has six buttons. Using the arcade machine as the template, buttons X, Y, and RB would be light/medium/heavy punch respectively, while A, B, and RT would be light/medium/heavy kick respectively. I also decided to use the SELECT button as the P1 COIN button, and the START button as the P1 START button. For the moment I'm ignoring the two macro buttons on the controller (the two black buttons in the upper-right corner). I went into Input (general) then Player 1 Controls. In addition to the keyboard and mouse controls, MAME saw all of the buttons on my controller but they were not in the correct order. MAME lists the default buttons thusly: Button 1 (A), Button 2 (B), Button 3 (X), Button 4 (Y), Button 5 (LB), Button 6 (RB), Button 7 (START), Button 8 (BACK). (Note that BACK is how MAME sees the SELECT button on the controller.) I want the buttons to be defined as: Button 1 (X), Button 2 (Y), Button 3 (RB), Button 4 (A), Button 5 (B), Button 6 (RT), Button 7 (LB), Button 8 (LT). (Also note that SF2 doesn't use buttons 7 and 8 but I wanted to define them universally anyway.) Also, by default P1 SELECT (aka P1 COIN) is defined as 5 and P1 START is defined as 1. I want to change them to BACK and START respectively. I was able to remap things as I wanted, but not all of the controls work. The joystick, three kick buttons (A, B, RT), and light punch (X) work, but that's it. Medium and heavy punch (Y and RB) doesn't work, nor does P1 COIN (BACK) or P1 START (START). One thing I did notice: As I was adjusting the mappings, most of the changes I made showed up dimmed out. All of the default settings are in bright white, but when I make an adjustment it's like 50% white. There is no correlation between the color of the mapping and its functionality; some of the dim ones work, some don't. If you have any insight there I'd love to hear it. On a similar note, please check my understanding of how MAME uses config files. As I understand it, MAME stores its configuration files inside of a "cfg" folder within the MAME folder. On a perfectly clean/never used installation of MAME there will be a single file in there called __empty.cfg which is basically a default template that MAME uses. Upon MAME's first launch it will copy that __empty.cfg file as default.cfg. When you go into Input (General) those are the settings you are modifying. When you launch a ROM, MAME looks for a config file that matches the ROM name (e.g., sf2ceusa.cfg). If it finds one then it uses those settings; if you go under Input (This Machine) those are the settings you're modifying. If it doesn't find one then it makes a copy of default.cfg and names it after the ROM (e.g., sf2ceusa.cfg). Now, here's where I get a little uncertain. Let's say I launch SF2CE and (based on my understanding above) MAME copies default.cfg into sf2ceusa.cfg. I make no changes to either the General or This Machine inputs. Then at some point in the future I'm playing Berzerk and I change the General settings. When I go back into SF2CE, are my new adjustments to General going to be reflected there? In other words, does MAME "know" that I didn't tweak any settings in SF2CE and therefore always want SF2CE to use the General settings, or does the mere act of launching SF2CE effectively "lock in" whatever the General settings were at the time I first launched it? If I'm understanding it right, it sounds like the Input (General) settings is NOT "use these settings everywhere UNLESS there's a custom configuration for a specific machine" but rather "use these settings going forward as the default values for any new ROM that's opened". The latter seems very limited and poorly worded (I would have called it "Input (Default Template)" instead) but does seem to be what's happening; the former is what I was expecting. Which is accurate? Thanks yet again. EDIT/UPDATE: So, I kind of answered my own question. I deleted everything inside of my MAME/cfg folder except for __empty.cfg. Through BigBox I launched MAME and SF2CE. The General and This Machine inputs were largely the same. I modified the General settings, quit out of everything, then deleted the sf2ceusa.cfg file from within MAME/cfg. When I relaunched MAME and SF2CE the inputs were copies of all the General settings that I made before. So it seems that it functions as "Default Template" rather than "General" after all. And, oddly enough, after doing all this ALMOST all of the buttons work. The only buttons that aren't working are BACK (SELECT, aka P1 COIN) and START (P1 START). I still have to use the keyboard 5 and 1 for those, respectively. Any ideas why? Did you ever get an answer for this? I’m about to try to map for joysticks and had some unrecognized last time. thx!!! Quote Link to comment Share on other sites More sharing options...
Slag-O-Matic Posted September 3, 2022 Author Share Posted September 3, 2022 Yes. The folks at 8BitDo helped me out. Download and install 8BitDo Ultimate Software: https://support.8bitdo.com/ultimate-software.html Using that software, map the SELECT and START buttons to P1 and P2, respectively: Once they're mapped, click the "sync to device" button to send the new mapping to the controller. Quit the software, launch MAME, and go to Input (general) -> Other Controls. Once there, map "Coin 1" to P1 and "1 Player Start" to P2. From that point the SELECT button on the Arcade Stick will function as COIN 1 and the START button will function as PLAYER 1 START. (I went a step further and remapped the "quit game" function as P1+P2, so when I want to quit a MAME title I press both SELECT and START together. This works.) If you have multiple controllers you can repeat the process with the second (third, etc) controller, changing to "Coin 2" and "2 Player Start" and such. There's a bit of weirdness happening though, something I don't fully understand. After I mapped the buttons on my controllers P1 and P2 also functioned as SELECT/COIN1 and START/1 PLAYER START — which I fully expected to happen. Nothing weird there. But after I got it to work, just for giggles I went back into Ultimate Software, unmapped the P1 and P2 buttons from SELECT and START, and synced it to the controller. I fully expected this to break the new mappings I made in MAME — but they didn't. SELECT and START still function as expected, and P1 and P2 do nothing. I don't know why but... (shrug) Quote Link to comment Share on other sites More sharing options...
jrallen81 Posted September 3, 2022 Share Posted September 3, 2022 thanks, very helpful. I have another question about MAME cocktail mode disappearing from the menu if you know anything about that!~ Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.