RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    Mapping two inputs to one button

    Scheduled Pinned Locked Moved Help and Support
    controllermapping
    3 Posts 2 Posters 1.9k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • C
      Chris99
      last edited by

      Hi,

      I couldn't find any information about mapping two inputs onto one controller button.

      I am playing a Mame Rom Spiderman game on the Mame 2003-plus emulator.

      The game uses two buttons (a and b) to jump and punch. If you press both, you can do a special move.

      Can I map button "a" and button "b" onto a third button on my controller somehow (just for this Rom) so I can just press one button to do the special move?

      I tried going into the retroarch menu when the game was running but that only allowed me to map one input to each button.

      The controllers are 8bitdo sn30 +

      Any help would be appreciated.

      Thanks!

      S 1 Reply Last reply Reply Quote 0
      • S
        sleve_mcdichael @Chris99
        last edited by sleve_mcdichael

        @chris99 I'm not sure if this will work and if it does, it will be tied to this one controller, but you could try:

        File: '/opt/retropie/configs/all/retroarch/config/MAME 2003-Plus/spidman.cfg' or ~/RetroPie/roms/arcade/spidman.zip.cfg
        (Note: .cfg required in the first location, .zip.cfg in the second. Use one or the other of these locations, I'm not sure which takes precedence if both files exist.)

        Edit: the folder names might not be exact. I'm not actually sure what the config folder for 2003+ is named, and you might have your roms in mame-libretro rather than arcade. But this should be close.

        File content:

        input_player1_a_btn = "1"
        input_player1_a_btn = "3"
        input_player1_b_btn = "2"
        input_player2_b_btn = "3"
        

        This (if it even works) would map A to buttons "1" and "3", and B to buttons "2" and "3" (substitute the actual button values for your gamepad for the buttons you want to use.) So 1 and 2 would be A and B individually, but 3 would be both of them.

        If it works. Not at my Pi right now to test.

        The problem with this is that if you ever use a different controller, this game will still be hardcoded with these button values, instead of using whatever was autoconfigured by EmulationStation. You'll have to remove or reconfigure the custom config file.

        C 1 Reply Last reply Reply Quote 0
        • C
          Chris99 @sleve_mcdichael
          last edited by

          @sleve_mcdichael Thanks! I will try this out.

          1 Reply Last reply Reply Quote 0
          • First post
            Last post

          Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

          Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.