-
-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Implement proper support for MAME CHDs #158
Comments
Going to tackle this next, need to get my hands on a MAME game with a HD or LD file. |
@lemonadecbc Almost done with this one, although I just realized that the MAME CHD DATs store the SHA1 of the compressed data, not the uncompressed data. This is the complete opposite of everything else out there which is quite unfortunate as I'll need to handle this special case. Also they don't provide size information at all, which is another bummer... Edit: Correction, it's not even the SHA1 of the compressed CHD, it's the SHA1 of the uncompressed data + CHD header + CHD metadata, which is different from the compressed, and uncompressed data. It's going to be fun :) |
Importing MAME CHDs should now work with d1858b7 They come with limited support for now, commands like Another option would be to use a dir2dat DAT instead (like the ones from Pleasuredome), but then I would need to make an exception and compute the CHD hash without extracting it first. In any case I would advise using separate DATs for ROMs and CHDs for now as I'm not sure how |
Just released 0.20.0, leaving this open for now as there are still a couple things I need to take care of. |
I was going to try this new feature (thanks for awesome job!), but not sure which and how the CHD dat should be imported as all the MAME v0.272 DAT's from ProgrettoSnaps seem to give error: "Error: SimpleError { err: "Failed to deserialize DAT file, duplicate field For example MAME_CHD_272.dat is in Logigx format, but is giving this error. Is there something wrong with this MAME version or is this a bug introduced with 0.20.0 upgrade? |
Thanks for the heads up, I see the Progetto DATs mix rom and disk tags, which is causing the issue. All my testing was done using pleasuredome's DATs, where the CHD DAT only has disk tags: https://pleasuredome.github.io/pleasuredome/mame/ I'll adapt the logic to try and support both. |
Fixed in 04501c8. Separated rom and disk parsing, as a quick hack I still merged them afterwards. Still a first step towards a working |
Sorry if I'm rushing here, but did you try to fix already parsing Progetto DATs? I see the DATs are now being processed further, but there's another error this time: Rom "os12.rom" not found in game "torchh" parent/bios, please fix your DAT file CHD dat for Progetto also seems to get a lot of "please fix your DAT file" warnings before this final fatal error. Pleasuredome DATs seem to work well, thanks for hint. |
By the way, I also noticed that Pleasuredome's CHD DAT for 0.272 (merged) does crash when trying to run sort-roms -w: Wanted: That line of code seems to reference to rom.crc, but the DAT file only has sha1 and no CRC. If I manually edit DAT to contain crc="00000000" for all disks, error goes away. |
Did not try with As for progetto I'll have a look. These warnings happen when there are references to non-existent files in parent roms, these need to be fixed by the DAT provider. I'll see where the error comes from though, I probably expect CRC to be non-empty like with the |
The develop branch can now import the progetto DATs, and |
Just released 0.20.1. I switched to Progetto's DATs as they seem to be the most popular. I'll probably work on a self-healing feature for |
MAME CHDs are expected to be stored in this directory structure:
<machine name>/<rom>.chd
Currently there's no way to tell oxyromon to sort files like this, but chd-files are stored in root and/or 1G1R-folder. The idea is to allow using oxyromon sort-roms with parameter that would allow use of machine-tag from dat-file and store disk-tagged CHD's when sorting the rom files and exporting them.
The text was updated successfully, but these errors were encountered: