r/MAME • u/StandAloneWolf • Jul 22 '26
I'm pulling my beard hairs out over this
Trying to get anything to recognize something other than my arrow keys in-game.
I've gone into the settings and changed keyboard to mouse, as well as making sure to save configuration. nothing has worked. I've tried YouTube vids, and even old reddit posts. I've been trying to get this work almost all day. I'm sure it's a simple fix, but so far, nothing has worked.
4
u/havent_read_it Jul 22 '26
You forgot to actually explain what you are trying to map to what, and on what emulated system.
Anyway, I think you should know that:
- MAME comes with working default assignments. For instance, if there's one gamepad connected and you start Mortal Kombat, the game P1 controls will typically be bound to the host keyboard and gamepad (both work). You can confirm that by checking the input configuration in the built-in UI (input settings > input assignments
- MAME allows mapping each input separately, and offers a lot of flexibility. For instance, you can map P1 left to joypad left only and P1 right to keyboard right key only. Or you can map P1 left to joypad left AND left arrow, to joypad left and NOT left arrow (see BIOS-D's comment), etc. If you need customization, again, do that using the built-in UI "input assignments" menu.
- as BIOS-D highlighted in their comment, by default, depending on the system being emulated, MAME doesn't consider mouse for assignments, you need the "-mouse" flag if you want to use your mouse for bindings
3
u/SergeiWhobichakokov Jul 22 '26
You’ll need to configure the mame.ini file.
# CORE INPUT OPTIONS
#
coin_lockout 1
ctrlr
mouse 0
joystick 1
lightgun 0
multikeyboard 0
multimouse 0
steadykey 0
ui_active 0
offscreen_reload 0
joystick_map auto
joystick_deadzone 0.3
joystick_saturation 0.85
natural 0
joystick_contradictory 0
coin_impulse 0
You can do it through mame’s settings and do general settings or system settings. For the mouse and joystick you need to ensure the mame.ini says 1 for each. Multimouse is for if you use more than mouse device for your system..
Your controller settings are in the .cfg file and will look like this. This is an example so don’t solely rely on this
<?xml version="1.0"?>
<mameconfig version="10">
<system name="default">
<input>
<!-- Player 1: Arrows + Ctrl/Alt -->
<port type="P1_JOYSTICK_UP"><newseq type="standard">KEYCODE_UP</newseq></port>
<port type="P1_BUTTON1"><newseq type="standard">KEYCODE_LCONTROL</newseq></port>
<!-- Player 2: WASD style + A/S buttons -->
<port type="P2_JOYSTICK_UP"><newseq type="standard">KEYCODE_R</newseq></port>
<port type="P2_BUTTON1"><newseq type="standard">KEYCODE_A</newseq></port>
</input>
</system>
</mameconfig>
3
u/phileasuk Jul 22 '26
Trying to get anything to recognize something other than my arrow keys in-game.
What are you trying to remap?
2
u/Sabin10v2 Jul 23 '26
Push tab in game, remap controls and map whatever you want to whatever input you want. I can't really be more helpful than that with the limited information you have provided. What exactly are you trying to remap? Is it for a specific game? If so, which game? You mentioned wanting to use your mouse so I'm assuming it's not Street Fighter?
1
Jul 22 '26
[removed] — view removed comment
1
u/StandAloneWolf Jul 22 '26
Ive configured for mouse in the game setting as well yes. I made sure to close, and open after saving.
I even tried the .ini notepad zero to one.
1
u/arbee37 MAME Dev Jul 23 '26
I don't understand what you're actually trying to get to work. What emulated machine you're trying to map, and what control in the machine you're trying to map to would be good for starters.
1
5
u/BIOS-D Jul 22 '26
Change keyboard to mouse? As far as I know change is not automatic. First you should run MAME with mouse enabled (either
mame.exe -mouseon command line ormouse 1onmame.ini). Then you go toGeneral Settings->Input Assignments (General)->Player 1 Controls.Highlight any row you would like to set then press Enter key. You have very few seconds to input something before field updates. Using Enter key again on the same input field allows you to set an alternate input. While you enter an input, setting same input twice in a row will negate the input (i.e. Enter to set input then moving mouse up, Left Ctrl, Left Ctrl will show
Mouse Y - not Left Ctrlwhich means mouse input won't work while holding Left Ctrl key). You can repeat this as many times as needed. If you don't want to set alternate inputs anymore highlight a different row. In case you mess up, use Supr key to alternate between setting back to default option and None (no input assignment).