Homepage › Forums › RetroPie Project › Ideas for Further Enhancements › Change button in emulator launch options (runcommand)
Tagged: launch options runcommand joypad
- This topic has 14 replies, 5 voices, and was last updated 9 years, 2 months ago by colinshare84.
-
AuthorPosts
-
09/04/2015 at 14:27 #105407colinshare84Participant
Hi
See my other post:
Basically, adding an option to customise which joypad button to bring up the emulator launch options would be useful and stop any accidental presses while starting games.
This message:
Press a key (or joypad button 0) to configure launch options for emulator/port ($emulator). Errors will be logged to /tmp/runcommand.log
Or even the ability to disable/hide this dialog completely for anyone who has their system set up to their liking.
Thanks!
09/23/2015 at 07:33 #106655MRKaneParticipantThere’s a joypad button for bringing up emulator launch options? I was thinking the other day that it’d be really awesome not to have to have a keyboard handy to always do this, and use the button “X” defined on setup on the controller instead :D
09/23/2015 at 09:30 #106659colinshare84ParticipantYeah if you pay attention to the quick message then you’ll see it but the problem is that if you press joypad button 0 (by accident or on purpose!) then it drops back to a menu which you can’t navigate with anything other than a keyboard! That’s why I think having the ability to change which joypad button it looks for would be a good addition.
It may be possible to change it by editing some code but I’m unsure as to which file I would need to edit.
09/24/2015 at 03:36 #106741MRKaneParticipantYou’re right on the money there – I think it’s also joypad 0 that can do that too – still, it’s only little stuff in the larger scheme of things.
I’m only getting to grips with the project and frankly I’m afraid to mess with things as the last few times I’ve done it things have fallen over :(
09/24/2015 at 03:43 #106742herbfargusMemberActually in 3.0 you can navigate the runcommand menu with your dpad. Just sayin…
But its OK to tinker- that’s what the pi is for. I’ve ruined my OS more times than I can count- just always make backups and you’ll be fine. You never learn if you don’t make mistakes :)
09/24/2015 at 10:28 #106767colinshare84ParticipantYou can navigate with the d-pad?! I’m going to double check on my setup but I don’t remember that!!
Either way, I’d still think adding an option to either disable the message or being able to change which buttons enter the runcommand menu would be a good addition. Don’t you agree? My 4 year old cousin can’t control his hands/excitement when starting a new game and I’ve had to tell him loads of times not to press buttons! Plus, I’ve got everything set up the way I want it so I don’t need to change which emulator runs a certain rom, etc.
09/24/2015 at 15:17 #106776petrockblogKeymasterthe joy2key feature currently uses the first axis on the joypad – so dpad on some, and on others it might be an analog stick. It works on my xbox and ibuffalo controllers at least.
09/24/2015 at 17:29 #106786herbfargusMemberIn theory though if one wishes to remove the joy2key aspect (to keep kids from messing it up) while still allowing for keyboard presses could they just remove these lines?:
09/25/2015 at 12:01 #106825colinshare84Participant@buzz, @herbfargus
Thanks guys, I’ve not had the chance to check if I can actually navigate using my controller. I think the reason I hadn’t noticed this before is that my player 1 controls are js1 and player 2 is js0 (long story!).
@herbfargus, that’s just what I was looking for! I’ll try this and let you know.Thanks!
09/25/2015 at 16:51 #106834petrockblogKeymasterjust to note the highlighted lines “stop” joy2key – you need to remove lines 655-661 to stop it from launching – but easier still you could just remove the joy2key.py program which would be simpler as it checks for it before trying to launch – /opt/retropie/supplementary/runcommand/joy2key.py
09/29/2015 at 00:02 #107039majerle9ParticipantI tried both methods listed. First I removed the lines from runcommand.sh, but nothing changed. Then I deleted joy2key.py and nothing happened then either. Now I’m not sure runcommand.sh is what runs this message. Has anyone actually tried this method and gotten it to work?
I’m desperately trying to childproof my retropie too and this is one of a few parts of the system that leave it open to damage from kids.
09/29/2015 at 09:50 #107047colinshare84ParticipantI’ve still not had the chance to try any of this myself, luckily I only subject my machine to kids occasionally! But it’s good to know I’m not the only one, majerle9!
Thanks for your help, buzz.
09/29/2015 at 22:36 #107081petrockblogKeymasterif you remove joy2key (did you remove it from the right place? Please giev more detail), there will be no joystick control to enter the launch menu nor navigate any retropie menus.
10/04/2015 at 18:02 #107261majerle9ParticipantIt’s working for me now. I used both methods just to be sure.
First I went to /opt/retropie/supplementary/runcommand/runcommand.sh and commented out all the lines that had anything to do with joy2key.
# if joy2key.py is installed run it with cursor keys for axis, and enter + tab f$ #__joy2key_dev=$(ls -1 /dev/input/js* 2>/dev/null | head -n1) #if [[ -f "$rootdir/supplementary/runcommand/joy2key.py" && -n "$__joy2key_dev" $ # __joy2key_dev=$(ls -1 /dev/input/js* | head -n1) # "$rootdir/supplementary/runcommand/joy2key.py" "$__joy2key_dev" 1b5b44 1b5b$ # __joy2key_pid=$! #fi # check for x/m key pressed to choose a screenmode (x included as it is useful o$ #clear #echo "Press a key (or joypad button 0) to configure launch options for emulator$ #IFS= read -s -t 1 -N 1 key </dev/tty #if [[ -n "$key" ]]; then # get_all_modes # main_menu # dont_launch=$? # clear #fi #if [[ -n $__joy2key_pid ]]; then # kill -INT $__joy2key_pid #fi #if [[ $dont_launch -eq 1 ]]; then # exit 0 #fi
Then I went to /opt/retropie/supplementary/runcommand/ and deleted the joy2key.py file.
Before I did that, when I started a game it said:
Press a key (or joypad button 0) to configure launch options for emulator/port ($emulator). Errors will be logged to /tmp/runcommand.log
Now it says:
========================================
Thanks for all the help.
10/05/2015 at 09:44 #107312colinshare84ParticipantI feel bad for not having the time to try any of this myself!
But thanks for all your help guys, I’ll try the steps (when life stops getting in the way!) which majerle9 took and see if I get the same result.
Thanks again!
-
AuthorPosts
- The forum ‘Ideas for Further Enhancements’ is closed to new topics and replies.