Open menehune23 opened 2 weeks ago
I was able to work around the issue by altering the command that ES uses for the system. I'm not sure what the default command is, but I added a <command>
tag to the /userdata/system/configs/emulationstation/es_systems_pico8.cfg
and now there are no issues with Splore search:
<?xml version="1.0" encoding="UTF-8"?>
<systemList>
<system>
<name>pico8</name>
<command>/bin/bash -c 'if [[ "$(basename %ROM%)" == "Splore.png" ]]; then /userdata/bios/pico-8/pico8 -splore; else /userdata/bios/pico-8/pico8 -run "%ROM%"; fi'</command>
<emulators>
<emulator name="lexaloffle">
<cores>
<core default="true">pico8_official</core>
</cores>
</emulator>
<emulator name="libretro">
<cores>
<core>fake08</core>
</cores>
</emulator>
</emulators>
</system>
</systemList>
BONUS: You can leverage this to add -pixel_perfect 1
to the command to get integer scaling. I want to look into how I can leverage the command to render a bezel as well -- something in the style of the Perfect Overlays 😁
Even though a workaround is possible, it would be good to get to the bottom of it so that the custom command is not necessary.
I found the default command in the /etc/emulationstation/es_systems.cfg
:
<command>emulatorlauncher %CONTROLLERSCONFIG% -system %SYSTEM% -rom %ROM% -gameinfoxml %GAMEINFOXML% -systemname %SYSTEMNAME%</command>
It turns out that the workaround has the drawback of external controllers not working (bluetooth or wired).
It gets even stranger though. If I remove the workaround and start Splore while a controller is connected, the original double-input issue also goes away.
I haven't tested with multiple controllers and multi-player games, to see which scenarios they work in. But for now I'll stick with the workaround since I personally won't be playing with external controllers.
Another clue, the default command expands to:
emulatorlauncher -p1index 0 -p1guid 19000000010000000100000000010000 -p1name Deeplay-keys -p1nbbuttons 17 -p1nbhats 1 -p1nbaxes 4 -p1devicepath /dev/input/event1 -system pico8 -rom /userdata/roms/pico8/Splore.png -gameinfoxml /tmp/game.xml -systemname Pico-8
I found that the Splore search also works correctly if I override the -p1devicepath
to event0
instead of event1
:
<command>emulatorlauncher %CONTROLLERSCONFIG% -system %SYSTEM% -rom %ROM% -gameinfoxml %GAMEINFOXML% -systemname %SYSTEMNAME% -p1devicepath /dev/input/event0</command>
This will still cause issues if using an external controller though as the built-in game pad might not be p1. To get around this I tried setting the p1 controller in the ES settings, but that didn't seem to help. The external controller didn't work in Splore at all.
Optimally, it would be nice to understand where ES is getting the devicepath from, and change it at the root so I don't have to override it. Anyone know?
I would like to add my confirmation that this is happening to me, too. I also confirmed that the config fix above worked for me.
KNULLI V41-dev-a1102db1e2 2024/11/07 19:52
RG Cube XX
Knulli build version
40-dev-d3b520f949 2024/07/21 02:18
Your architecture
RG35XX H
Issue description
When running PICO-8's Splore via Emulation Station, the search function using the D-pad is not working correctly. It seems to be taking each input twice. Pressing up/down skips a letter (sequence is B->D->F, etc) and pressing right adds an extra whitespace. I suspect the issue is either:
I'm leaning towards option 2, because I can ssh into my device and run
/userdata/bios/pico-8/pico8 -splore
and it works correctly (aside from fighting Emulation Station for the screen, which is expected since it's running in parallel to it, but the inputs work correctly).Detailed reproduction steps
Install the official PICO-8 binaries according to the Knulli instructions, including adding a
Splore.png
file.Start Splore from the Emulation Station frontend
Navigate to the search function
Use d-pad buttons to attempt to enter a search string, and observe the described skipping
Details of any attempts to fix this yourself
No response
Details of any modifications you have made to Knulli.
None
Logs and data
No response