Jump to content

All my products and services are free. All my costs are met by donations I receive from my users. If you enjoy using any of my products, please donate to support me. My bare hosting costs are currently not met so please consider donating by either clicking this text or the Patreon link on the right.

Patreon

[DEPRECATED - See GameEx/GameEx Arcade v14.78+] MAME XML Generator for PinballX


Recommended Posts

Posted

 

 

 

 

 

 

 

 

 

 

 

Well that first block of code I put in my example runs MAME.EXE and generates the xml file from the executable. I envisioned a spot in the UI where a user can point to MAME and the path gets passed in.

 

I can probably knock something up. The piece about orientation requires a helper block to do some math I didn't include here.

 

There's more to it for sure, but it really shouldn't be that difficult to produce a working POC. I can probably hand the code off after that so you guys can tweak it.

If you want it to only include roms the user has, I can pull a directory listing in as an array and parse against it in the select case. No big deal.

Posted

So you taking this one, Adultery? tbh, not really that interested in being a gui monkey as have lots of other projects on the go...

However, if you don't have time and there's some interest left in this for me, happy to prioritise over other stuff.

Posted

^this. Really it's more about not having a ton of time to work on it, but I can get it off the ground enough that it should be easy enough for you to run with it if I give you the keys. Maybe it'll be good enough. Depends on my availability. ;)

Posted

Cool - well put something together and it may be helpful. Your skills are waaaay over mine, A, although that code did make sense apart from some mysterious references. The problem is, I have no formal training at all, so when you say things like "The piece about orientation requires a helper block to do some math...." you may as well be talking to me about women's netball (read: leaves me baffled). It might be I end up doing my own approach anyways as I'm a coding thug and have no grace or manners at all + when I meet with good etiquette, I get confused and bang my keyboard. :P

Lets see how we go...

 

Posted

I will re-review what we have discussed and also take a look at the mame.xml file. I think we hit on quite a few things that would be great, but also lend a little complexity. The main goal is to keep the application simple to generate the intended output for use by PinballX. We could start by limiting the output to Vertical only and applying the * Mature *, language, and other filters.

Posted

Naw - it's best to factor in all the possible requirements at the start, Draco, rather than try and hack/re-code them in later. I've got a solid idea about how to make the app flexible and allow different users to get what they want out of it, whilst still keeping it simple to use. All I really need to see is the input we're working with - whether that's this mame.xml or the gamelist.txt. A post of what's produced from the mame.xml proceedure would be helpful.

 

Posted

Well I opened a command prompt and went to my Mame install folder. I run MAMEUI64 0.158 so my command line was Mameui64.exe -listxml > mame.xml .

It took a few minutes to generate the mame.xml file as it appears to be parsing through my collection.

Here is a good example of the first part for 1942:

<game name="1942" sourcefile="1942.c">
        <description>1942 (Revision B)</description>
        <year>1984</year>
        <manufacturer>Capcom</manufacturer>

As you can see, it follows the format for 1942 in the mame.xml file example I provided for <game name>, <description>, <manufacturer> and <year> tags:

 <game name="1942">
        <description>1942 (Capcom 1985)</description>
        <rom></rom>
        <manufacturer>Capcom</manufacturer>
        <year>1985</year>
        <type></type>
        <hidedmd>True</hidedmd>
        <hidebackglass>True</hidebackglass>
        <enabled>True</enabled>
        <rating>0</rating>
    </game>

Of course the example isn't the entirely the same as the mame.xml as there are going to be multiples of the same program due to the various revisions, hacks, clones, etc. and the .xml I provided for the Pinballx format does not account for these.

 I do not see the necessary tags in the mame.xml file (unless they are in the description field, they are no where else to be found) to differentiate between vertical, horizontal, *mature*, or the languages whereas within the gamelist.txt, they are in there. Maybe Audultery or someone else knows of an official source that could be used as a reference within the module to select these items as exclusions so we don't neccesarily have to lean on GameEx to generate such a list?

mame.zip

Posted

Of course, we could drum up some business for GameEx if we use the gamelist.txt file.. just a thought.

Posted

So mame.xml doesn't have genres + orientation...

Got me sailing into territories new here - looking into history and mameinfo.dat - both huge files with bonkers formatting. 

How does gameex parse mame games and get the genre and orientation etc?

got a feeling this is a path well known to some....

If it all proves too convoluted, maybe revert to plan A - parsing gamelist.xml.

Posted

I already have code that manages all the support files. I can parse those rather easily, no additional programming needed. I just need to import the class that I wrote. That would include catlist for genres and history.dat also.


Posted

For the orientation, you can use the values in the main file to determine whether or not the width and height makes it fit into one of those categories. That would take some additional code but it can be done easily also.

Posted

What about exclusions, such as the mature or adult titles, mahjong, quiz, puzzle, etc.? That is crucial in addition to the orientation.

Posted

 

It should be up to the user I think. I think we can get where you want kind of the same wayGameEx does (No casino, no porn please, only working, no clones, etc). All this is in the support files except only working and no clones, which are in the XML.

 

If I were gonna run with this, I'd probably want to hit the following goals right away:

 

• File picker for MAME.EXE, history.dat, and catlist.ini (possibly a download option and could host these files on my site, likely a drag and drop option for these as well so you don't have to browse to the files manually )

 

• A path option for your MAME romset

 

• Filter selections via checkboxes with a "filter" and "do not filter" textbox

 

• A place to add the path you want to drop the finished PBX file into

 

• An option to download complete XMLs from DracLabs without doing the grunt work yourself if you wanted to be lazy that is give one of you access to upload to

 

• Profit $$$

 

 

 

Posted

It's too bad I don't have a pincab. I have all kinds of ideas for plugins.

Gonna have to rely on the community for testing.

Posted

Should we move this topic to the PinballX forums or just leave it here for now and create an official project thread once ready for testing and release?

Posted

I think we should move it, might be other suggestions and could benefit from the visibility.

Posted

One thing I noticed is that the list.xml in my MAME directory is the same as the mame.xml I generated via command line.

Posted

For the file picker option - I believe these files version specific to the MAME version. If so, it might be a chore finding some of them other than the most recent, but again, having another repository for older versions isn't a bad thing.

I really think this is doable and that the PinballX community members running MAME on their pincabs and other setups via PinballX will be greatful for whatever we come up with and can be thrown together.

You know I don't mind documenting the schiznit out of this once we get up and running.

Posted

Support files are no big. Most recent ones will typically cover old ones too. The descriptions and categories can easily be referenced by parent roms. For example, if I have pacman.zip, the MAME.XML would tell me its a Puckman clone. I'd grab that description. Chances are the parent info won't change, even if the rom itself does.



I think the download option will help, I'm just not confident I'll keep up with the release schedule. I admittedly don't update my support files much (or really do anything on the cab these days). My machine is currently in a zombie state, half finished GameEx Arcade install on there.



Like I said before, my life is crazy lately working weekends and late nights, and what little time I have I spend with Quinn.



But I can knock this out in a few hours, so I'll take it on. I just can't promise to make it do everything you'll want right away (especially if Stigz doesn't seem to be down with picking up the torch on it, which I totally understand. I wouldn't want to take onHeadkaze's either because I'm sure it's above me).



You'll get the things on my list though for sure. And then you'll have to invite me over for a few games of The Adams Family and Street Fighter II Pinball. [emoji117] [emoji108]

Posted

I'll have to get Addams Family and Street Fighter pinball installed first. I am a version off in my PinballX installs having been tweaking GameEx Arcade Edition on my gaming setup, dealing with the real life responsibilities, yada yada yada... 

Gimme some ideas as to what we want to call this app officially and I'll see what I can do to knock up a logo for it.

Posted

For the path option for the location of the ROM set, I think it should be the same as GameEx and GameEx Arcade MAME path settings with multiple paths separated by ; as they are in the integrated support.

Being able to separate into vertical, horizontal or all games would be a good option.

Your list of items is fine. Presently, there is nothing other than the hard work of others doing it manually. While there may still be some manual tweaking of the xml file, it will go a long way.

 

Posted

Why the need to tweak the XML? It should be plug and play.


Also, I already have code in place that I use to handle multiple paths and extensions (since the advent of 7-zip support in MAME).


The real challenge will be finding the time to work on it over the next few weeks. Fortunately I have a lot of the code already scattered amidst my other plugins and projects, I just need to pull it all together and design the GUI.


As for the name, I'll let you guys sort that out and I'll give you banner dimensions after I lay out the form. I'll add the controls before I start working on the backend of it, like Stigz mentioned its best to lay out the requirements right away so I can carve out the real estate I need.


[emoji317]
Posted

Silly Rabbit! There's almost always some tweaking that has to occur, such as disabling the DMD, or disabling the ROM in the xml if it is one that does not work well with the user's setup, etc.

The user can either tweak the xml via Game Manager or directly via Notepad or Notepad++.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...