Butter100fly (talk | contribs) No edit summary |
Butter100fly (talk | contribs) |
||
Line 23: | Line 23: | ||
<ol> | <ol> | ||
<li>so that we might launch it with another emulator! If we try and launch a game with no filepath in an emulator that's not a MAME emulator, it will never work, yet there are many cases where we might want to open a rom the MAME team has collected with some other emulator. For instance the RetroArch team did some great work on a standlone Sharp x6800 emulator that's much faster than MAME's emulator right now, so if you have that EFind-ed with QuickPlay, you can right click and launch that</li> | <li>so that we might launch it with another emulator! If we try and launch a game with no filepath in an emulator that's not a MAME emulator, it will never work, yet there are many cases where we might want to open a rom the MAME team has collected with some other emulator. For instance the RetroArch team did some great work on a standlone Sharp x6800 emulator that's much faster than MAME's emulator right now, so if you have that EFind-ed with QuickPlay, you can right click and launch that</li> | ||
<li>So that we can do something with the filepath: in particular in QuickPlay now (after release 4.7.0) we can ask QuickPlay's Synctool to fetch the file specified at the filepath from some remote location</li> | <li>So that we can do something with the filepath: in particular in QuickPlay now (after release 4.7.0) we can ask QuickPlay's [[Synctool_Guide | Synctool]] to fetch the file specified at the filepath from some remote location</li> | ||
</ol> | </ol> | ||
Like all other MAME functions in QuickPlay, the filePaths functionality doesn't ever inspect what romfiles you have on your disk, it just prints what the mame.xml says should be the paths. If you want to only print ROMS you have, then look at the MameFileManager option in the Arcade Roms menu. | Like all other MAME functions in QuickPlay, the filePaths functionality doesn't ever inspect what romfiles you have on your disk, it just prints what the mame.xml says should be the paths. If you want to only print ROMS you have, then look at the MameFileManager option in the Arcade Roms menu. | ||
== Understanding the MAME Printing Options settings == | == Understanding the MAME Printing Options settings == |
Revision as of 20:20, 13 October 2019
Understanding the MAME Path printing option
In Mame Options, there's a section 'Arcade and Softlist Printing Options'.
Before we start, it helps to understand how the MAME functionality in QuickPlay works - so i'll try and explain how everything gets printed one-time upfront at first, and then remains static:
How MAME in QuickPlay works
First you scan a MAME XML as a one-off thing into QuickPlay, creating a smaller file that QuickPlay uses to print things with. You then tell QuickPlay to print a set of Arcade Romdata files and/or a set of Software List Romdata files, and QuickPlay uses that file it made when it scanned the MAME XML. These romdatas are 'printed', once, in QuickPlays data folder as romdata.dat files and displayed in QuickPlay. If you want to change anything in them, its easiest to just delete them, change some option, and print them again.
So once these romdata files are printed, no more interaction with MAME happens until you actually play games.
Lanching a game
Now you understand how that works, let's think about what happens when you load a MAME game from QuickPlay
When QuickPlay calls MAME (or MAME-in-RetroArch), it doesn't 'need' filepaths: it calls 'mame.exe mamename' where mamename is a code the mame team made up to launch a particular game with ('bublbobl' for the game 'Bubble Bobble' for instance). This is the same for arcade or home computers/consoles. There's a mamename for everything. Of course we can use the (non-softlist) MAME Emulators we found during an EFind scan to try and run any Rom and any romdata in QuickPlay, so its entirely possible to pass MAME filepaths, but when we print off things from the MAME XML, every single game described by the MAME team is given a 'mamename', so we don't need this.
So, why might we want to also point to a filepath for these printed romdatas? There are two reasons:
- so that we might launch it with another emulator! If we try and launch a game with no filepath in an emulator that's not a MAME emulator, it will never work, yet there are many cases where we might want to open a rom the MAME team has collected with some other emulator. For instance the RetroArch team did some great work on a standlone Sharp x6800 emulator that's much faster than MAME's emulator right now, so if you have that EFind-ed with QuickPlay, you can right click and launch that
- So that we can do something with the filepath: in particular in QuickPlay now (after release 4.7.0) we can ask QuickPlay's Synctool to fetch the file specified at the filepath from some remote location
Like all other MAME functions in QuickPlay, the filePaths functionality doesn't ever inspect what romfiles you have on your disk, it just prints what the mame.xml says should be the paths. If you want to only print ROMS you have, then look at the MameFileManager option in the Arcade Roms menu.
Understanding the MAME Printing Options settings
Now you understand how that works, let's look at the new Arcade and Softlist Printing Options settings. Unusually the options apply the same to both Arcade and Softlist printing (usually they are two very different kinds of thing), that's why they are in the main Mame Options Menu
- Print MAME Filepaths - If you want gain the benefits described above, turn it on! However, there are reasons you might not want to have filepath's in your romdata: we require that you setup your MAME Rompaths in a certain way to print them (see below), RetroArch has complex MAME requirements so it might be difficult (never impossible!) to get ROM files in the right place and BIOS files in the right place to do what you want, or you might care about only having MAME emulators (entirely possible and awesome in QuickPlay) so you don't want or need any filePath's checked at any point. So the filepaths functionality is off by default, just enable it and save if you want to use it when printing romdata files
- Mame Roms Filetype - Usually mame roms are zipped. But its also possible to 7zip your romsets (this saves a bit of space). Altering this setting will literally print either '*.zip' or '*.7z' at the end of each filepath recorded against a MAME Romdata in QuickPlay, so set it to the same format as your roms
- Mame Roms Merge Type - You can read about this elsewhere: its a fundamental choice for MAME Roms of all kinds (including CHDs) and what type of Roms you have WILL affect what the filepaths are. If you have merged roms your filepaths will always be 'parent' names, if you don't you will first look to load 'child' names. You have to know which you have in order for filePath printing to work. (note 'fully-merged' is the same as 'merged' and any other option name probably means you do not have merged roms). Set this to match the Roms you have on disk
Using mame.ini's rompath variable
The last thing its important to understand, is that QuickPlay will need to find out from MAME what your rompaths are, in order to print them. Now MAME is pretty flexible in how you organise your rompaths, a bit too flexible really, so unless you follow a convention its impossible to know in advance the rompath to any particular rom, but you probably do follow the convention.
In order for filePath printing to work, you need to have the MAME paths read correctly from MAME's ini file. This currently works if you have a mame.ini/mess.ini in the same directory as the mame executable QuickPlay found in an EFind (or if the ini file is in system/mame/ or systems/mess realtive to the RetorArch executable, in the case of RetroArch)
There are 4 different kinds of ROMS in MAME: 'ROMS', 'CHDs', 'Software List ROMS', and 'Software List CHDs'. The folder names are usually called those. QuickPlay will look for folders named exactly as those four, in the rompath variable in your mame.ini, and use those to make the filepaths for those types of ROM when it prints MAME romdatas.
It is also possible to also have all your MAME roms in one folder (usually just called 'ROMS'). If there's only one folder in your rompath variable, QuickPlay will look there for all types of ROMS.
tips
- If your rompath situation doesn't match what I just described, and QuickPlay can't work out what a rompath is going to be, it will fallback to not really printing a rompath and instead print what it always used to './qp.exe' as the filepath (which effectively means we just don't know what your rompath is, you'll have to follow convention to get this working
- Whatever you do for naming your rompaths, be aware that some chd names, particularly Software List CHD names, can be very long. Minimise your path name length to allow for these (e.g.: prefer 'D:/Mame/Roms' over 'D:/OldGames/AllIndividualEmulators/MAME Assets/Content Files/MAME Gamefiles/MAME ROMS' or you will blow Window's MAX_PATH limit)
- Filepath printing is supported for RetroArch but there are a large number of factors and potential setups going on (in particular RetroArch require that the bios file for a non-arcade system always can be found in the parent folder of a softlist ROM), so unless you have all your ROMS and in a single folder, you might want to disable filepath printing for Mame-In-Retroarch, or design yourself some symlink mechanism that satisfies that rule. But as long as you follow the guide on how to setup RetroArch for MAME In QuickPlay you should have a mame.ini file that QuickPlay will read, so you might have luck!
Known limitations
What is all that extra console output when the romdatas are printing if I choose to print filepaths?
One point of printing filepaths is so we have named files to pass to QuickPlay's Synctool, but consider this: a romdata entry can contain only one filepath, and so Synctool only syncs one file, which isn't how MAME really works. With Mame there can also be:
- BIOS files / device files / parent files - needed for the rom to run
- Other disks to a CHD package - we only print disk 1
So when there's some helpful info about other files you could download in order for the romdata item we just printed to run or be fully played, at the moment the best we can do is print that to the console, so ifor now i've printed them out, so f you lare able you can open your mametool_logfile.txt and scrape that info out after doing a print and work out some way to copy the necessary files.
Generally if you have merged roms you just need to get your BIOS/device files onto your local pc somehow. Ultimately, file syncing is best for MAME CHDs because of this issue, you can try and fit your MAME and Softlist Roms on your local machine, and then sync the massively larger CHDs when needed.
I tried to run a MAME romdata game with 'parameters to run' in a non-MAME Emulator, but it didn't like the command-line args passed
There is a small conflict with the 'other-game-name' functionality: mame has a problem where the same 'mamename' has been used on, effectively, more than one game for the same system, so if we call a game by its softlist 'mamename' only, we might run the wrong rom (eg: the disk Famicom version of Super Mario 2 instead of the NES cart version). in order to fix this, I hardcoded further loading instrucitons (namely which device to load from) in the 'parameters to run' against only those items which conflict. However the 'parameters to run' in QuickPlay run irrespective of which emulator you choose to run a Romdata item with. Now if you want to run it with a different mame system, which is entirely valid, you might want this, but if you want to run it outside of MAME, you definitely dont.
So if you want to run a game that has mame calls in the 'parameters' in the romdata, change its emulator to the one you want, and clear the parameters (or to do this temporarily: right click the rom and clear the parameters before running, and set the MAME emulator back afterwards).
There are two potential fixes to this: either/or make these device calls at the emulator level (so we call the 'CART' version of the NES Softlist emulator in MAME) or make it so parameters don't carry over if you select a different emulator (there would probably have to be an exclusion for 'another mame emulator' though...)