Multi-mouse woes on Pi 4
-
Pi Model or other hardware: Pi 4
Power Supply used: Smraza 3A
RetroPie Version Used: 4.7.1
Built From: Pre-made SD Image on RetroPie website
USB Devices connected: Two mice, wired 8BitDo controller (X-input)
Controller used: Wired 8BitDo SN30 Pro
Emulator: lr-genesis-plus-gx, lr-flycast, lr-snes9x, lr-fceumm, lr-pcsx-rearmed, lr-mame2003I am having issues when attempting to use multiple mice in certain libretro emulators. The PS1 and Arcade emulators listed above work fine. Separate mice control separate players for various lightgun and trackball games. However, I am having issues with the remaining emulators, even when the mouse indices are set appropriately. I will focus on lr-flycast here, but the issues with the remaining emulators are similar.
The issue: the emulator partially ignores the mouse index. Mouse buttons are separate (i.e., two mice can fire shots in lightgun games for players 1 and 2 separately), but all connected mice control the movement/crosshairs for player 1.
See below for a collection of relevant files.
Pastebin link to verbose log generated after running Confidential Mission in lr-flycast
Pastebin link to retroarch.cfg from the "all" folder
Dreamcast-specific retroarch.cfg:
# Settings made here will only override settings in the global retroarch.cfg if placed above the #include line input_remapping_directory = "/opt/retropie/configs/dreamcast/" #include "/opt/retropie/configs/all/retroarch.cfg"
Confidential Mission remap file showing players 1 and 2 set to "lightgun":
input_libretro_device_p1 = "4" input_libretro_device_p2 = "4" input_libretro_device_p3 = "1" input_libretro_device_p4 = "1" input_libretro_device_p5 = "1" input_libretro_device_p6 = "1" input_libretro_device_p7 = "1" input_libretro_device_p8 = "1" input_player1_analog_dpad_mode = "1" input_player2_analog_dpad_mode = "1" input_player3_analog_dpad_mode = "0" input_player4_analog_dpad_mode = "0" input_player5_analog_dpad_mode = "0" input_player6_analog_dpad_mode = "0" input_player7_analog_dpad_mode = "0" input_player8_analog_dpad_mode = "0"
Confidential Mission game.chd.cfg sitting in the ROM folder showing mouse and keyboard button mappings as well as change to mouse index for player 2:
input_overlay = "~/.config/retroarch/overlay/SindenBorderWhiteMedium.cfg" input_overlay_hide_in_menu = "false" input_player1_gun_trigger_mbtn = "1" input_player1_gun_aux_a_mbtn = "2" input_player1_gun_start_mbtn = "3" input_player1_gun_dpad_up = "up" input_player1_gun_dpad_down = "down" input_player1_gun_dpad_left = "left" input_player1_gun_dpad_right = "right" input_player2_gun_trigger_mbtn = "1" input_player2_gun_aux_a_mbtn = "2" input_player2_gun_start_mbtn = "3" input_player2_mouse_index = "2" input_player2_gun_dpad_up = "up" input_player2_gun_dpad_down = "down" input_player2_gun_dpad_left = "left" input_player2_gun_dpad_right = "right" aspect_ratio_index = "0" input_overlay_opacity = "1.000000"
I do have two Sinden lightguns (that's why the overlay is referenced), but the issue occurs even when I have the guns disconnected and try regular mice.
-
Just to add some more context, the issue appears to be concentrated around the core option lightgun type that most of these libretro emulators possess. When set to "lightgun," the issue arises. When set to "touch screen," the aiming issue goes away. However, auxiliary gun buttons don't work in this mode, and lr-flycast doesn't even have this core option.
I also downgraded from RetroArch 1.9.7 to 1.9.4 (which had working lightgun support on my pi3B) after I read that lightgun support was not working in 1.9.7. All of the above files reflect the 1.9.4 downgrade.
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.