Reply To: LR-MAME. How to set custom controls?

Home Forums RetroPie Project Controller Configuration in RetroPie LR-MAME. How to set custom controls? Reply To: LR-MAME. How to set custom controls?

#116608
Profile photo of helpman
helpman
Participant

In my case I just needed to remap joystick buttons, so just as example… may give you a hint about what you need…

in home/opt/retropie/configs/neogeo (as example) I have to swap button 0 and button 1, but just in case I set all buttons needed. You must edit the file retroarch.cfg

# Settings made here will only override settings in the global retroarch.cfg if placed above the #include line

input_player1_joypad_index = 0
input_player1_b_btn = 0
input_player1_a_btn = 1
input_player1_y_btn = 2
input_player1_x_btn = 3
input_player1_start_btn = 7
input_player1_select_btn = 13
input_player2_joypad_index = 1
input_player2_b_btn = 0
input_player2_a_btn = 1
input_player2_y_btn = 2
input_player2_x_btn = 3
input_player2_start_btn = 7
input_player2_select_btn = 13
input_enable_hotkey_btn = 9
input_shader_next_btn = 6
input_shader_prev_btn = 5

input_remapping_directory = /opt/retropie/configs/neogeo/

#include “/opt/retropie/configs/all/retroarch.cfg”

as you can see if you compare it to yours, I added the input_blabhlahblah

apart from remapping the buttons to others (in neogeo select insert coins so I set it to my button 13, which emulates the coin slot. even with the button changed, as the base retroarch hotkeys are still by default select+start, which are defined as button 9 and button 8, the hotkey still works and pressing both will exit the game back to emulation station.

you can do this for every libretro based emulator.

if you need to change buttons for a specific game, just make a copy of the retroarch.cfg file for that emulator, and place it on home/pi/retropie/roms/mame-mame4all (or the rom folder you need) and edit away.

# Settings made here will only override settings in the global retroarch.cfg if placed above the #include line
# configuracion mame juegos 6 botones
input_player1_start_btn = “7”
input_player1_select_btn = “13”
input_player1_b_btn = “1”
input_player1_a_btn = “2”
input_player1_y_btn = “3”
input_player1_x_btn = “4”
input_player1_l_btn = “5”
input_player1_r_btn = “6”
input_player1_l2_btn = “nul”
input_player1_r2_btn = “nul”
input_player1_l3_btn = “nul”
input_player1_r3_btn = “nul”
input_player2_start_btn = “7”
input_player2_select_btn = “13”
input_player2_b_btn = “1”
input_player2_a_btn = “2”
input_player2_y_btn = “3”
input_player2_x_btn = “4”
input_player2_l_btn = “5”
input_player2_r_btn = “6”
input_player2_l2_btn = “nul”
input_player2_r2_btn = “nul”
input_player2_l3_btn = “nul”
input_player2_r3_btn = “nul”
input_enable_hotkey_btn = “9”
input_shader_next_btn = “6”
input_shader_prev_btn = “5”

input_remapping_directory = /opt/retropie/configs/mame-mame4all/

#include “/opt/retropie/configs/all/retroarch.cfg”

this is a mapping for street fighter 2 championship edition.
(I just moved all the buttons, as the button 0 is not used, but 1,2,3,4,5,6 instead.)
so as the rom zip file is named sf2ce.zip, you must name this file “sf2ce.zip.cfg” and it will be loaded when this game runs.

not sure if this helped you 😀

Skip to toolbar