Mini-update January 2024: In current versions of RetroArch, the cores are placed under "Application Support" of your user. This path must also be set in "....", otherwise RetroArch does not start. Corrected below and marked in red.
- Configure the Attract Mode Intro Video
- Configure history.dat to display within Attract Mode
- Assign game-specific configurations for Attract Mode only
- Other Emulators (WIP)
- Including RetroArch Cores (WIP - huge!)
1. Configure Intro Video: The OSX package of Attract Mode does not contain the intro video, and the Configuration does not provide for the full path settings. Follow these easy steps: Download the attract mode intro video from their website. Within the .attract folder, move it to the intro subfolder. In the Configuration, the full path must be set (which is missing at least in the OSX version). This is: $HOME/.attract/intro/intro.mp4 Do not care about the different video formats and leave it easy.
2. Configure history.dat (assuming that history.dat runs already in your current MAME setup): First the history.dat plugin must be enabled under Configure/Plugins, exit Attract Mode and open attract.cfg in the .attract folder in your favorite text editor. Srcoll down to the plugin History.dat section. Change the parameter for dat_path to the actual path of your history.dat file in your MAME configuration (as always: open a Terminal window and drag your history.dat file into it -> you get the full path). In these settings you must once trigger "Generate Index", which goes sufficiently fast. From now on, you can activate the game's history with keystroke H, and you can scroll up and down with your joypad - very nice.
Asteroids history in Attract Mode - click to enlarge |
You may also assign a joypad button for toggling the history.dat display, but this can only be done manually in attract.cfg: Open it again in your text editor and look for the History.dat settings. Change param button from H to Joy0 Buttonxx (whereas xx is the key number -> which you should find out first via the Attract Mode Controls Menu on an empty entry (means: go for an empty entry and add an input, press the joypad button and you know what to insert).
My History Plugin section in attract.cfg:
plugin History.dat
enabled yes
param button H
param dat_path $HOME/Games/mame/history.dat
param generate_index
param index_clones No
param rows 30
My History Plugin section in attract.cfg:
plugin History.dat
enabled yes
param button H
param dat_path $HOME/Games/mame/history.dat
param generate_index
param index_clones No
param rows 30
3. Assign specific configurations to one game: Here Attract Mode really shines for MAME! Although it's again text editor time, the results are very convincing so far.
Example - Metal Slug 1-3 crash without warning when Cheats are enabled. As shown in my example in Part 1, I have Cheats enabled by default, thus these three games need specific configurations to run with Cheats disabled. This is what to do:
- Be sure to have a Hotkey enabled for Edit Game, as shown in Part 1 - in my case keystroke E
- Head for Metal Slug 1 and press E, browse down to Custom Arguments - now include the entire modified arguments, in my case the default arguments without Cheat enabled:[romfilename] -video bgfx -bgfx_backend opengl -bgfx_screen_chains hlsl -plugin hiscore -resolution 3000x1600 -artwork_crop
- That's it, from now on, Metal Slug 1 starts with these custom arguments and no longer crashes!
- The even nicer part: After setting them up for the first time, these specific configuration files are very easily editable and portable under [$HOME]/.attract/romlists/mame/mslug.cfg - so from now on, you can easily edit the game also from your Finder in your text editor. You can of course also copy/paste the running config to another rom where you need the same configuration by just renaming the rom file name, e.g. mslug2.cfg. That really rocks.
5. Running Retroarch Cores within Attract Mode: With the command line parameters of RetroArch explained here, you can launch any Libretro Core from within Attract Mode. For emulators other than MAME, the combination of Attract Mode and RetroArch is nearly unbeatable: Libretro cores within RetroArch are bleeding edge and e.g. Mednafen is much easier to handle than directly from the command line. Means: You configure your core from within RetroArch and run it then from Attract Mode as follows (example: Stella for the Atari 2600, stella.cfg, as located in .attract/emulators - you can also create this file from scratch here, and it will appear in Attract Mode, you only have to create a romset and configure the Display, and you are set):
Configuration file updated in January 2024 in order to reflect new Cores path
# Generated by Attract-Mode v2.2.0-3
#
executable
/Applications/RetroArch.app/Contents/MacOS/RetroArch
args
-L "$HOME/Library/Application Support/RetroArch/cores/stella_libretro.dylib" "[romfilename]"
rompath /PATH TO YOUR ROMS/atari2600/
romext
.A26
artwork flyer /PATH TO YOUR ROMS/atari2600/boxart
artwork marquee /PATH TO YOUR ROMS/atari2600/marquee
artwork snap /PATH TO YOUR ROMS/atari2600/snap
artwork wheel /PATH TO YOUR ROMS/atari2600/wheel
Brief explanation:
- The executable string must direct Attract Mode to the binary of the RetroArch.app folder.
- The args string contains the Retroarch Core under -L (January 2024: cores moved for quite a while into the "Application Support" folder of your user)
- The rompath string is self-explanatory (remember: open a Terminal window and drag the roms directory into it -> you have a pasteable rompath!)
Current limitation of RetroArch on Macs: For launching a game from the command line, RetroArch must start in Fullscreen Mode. Without Fullcreen Mode, the game only launches in the background. This sounds like a bug, not a feature.
Thoroughly enjoy your tutorials and posts. Keep it coming!
ReplyDeleteMany thanks, much appreciated!
DeleteHi, my retroarch cores are not there, but they are in: Library/application support/retroarch/cores. Anyway whatever i add as args strings won’t work. I’ve tried my location, and i’ve copied yours too, but none of them is working.
ReplyDeleteThe games run fine in retroarch, could you please help me?