Author Topic: [Tool] Convert emulationstation xml gamelist to Attract Mode romlist  (Read 17726 times)

IceLancer

  • Full Member
  • ***
  • Posts: 44
    • View Profile
Hey there.
Previously i released
[Tool] Convert emulationstation/launchbox xml database "DESC" to Overview Attract
http://forum.attractmode.org/index.php?topic=1990.0
to convert description to overview in AM use

Today i release tool for converting  xml info to AM romlist.
Reason for this is because scraper
https://github.com/sselph/scraper/releases
really scrapes a lot of info when combined with fast scraper
https://forum.recalbox.com/topic/2594/batch-scrape-your-roms-on-your-pc-fastscraper

Anyway output example:
Code: [Select]
#Name;Title;Emulator;CloneOf;Year;Manufacturer;Category;Players;Rotation;Control;Status;DisplayCount;DisplayType;AltRomname;AltTitle;Extra;Buttons
ddonpach;DoDonPachi (International, Master Ver. 97/02/05);Cave;;1997;Cave (Atlus license);;;;;;;;;;;;;;;;;;;;

Before u use my tool make sure ur xml is in proper format and not broken!
Broken format example:
Code: [Select]
    <desc>
   </desc>
    <releasedate>
   </releasedate>
Or even Worse
Code: [Select]
   </desc>

   </releasedate>

Proper format:
Code: [Select]
    <desc></desc>
    <releasedate></releasedate>

scraper mentioned above will NEVER make such errors but Universal_XML_Scraper64 Absolutely WILL.
Do not use that to make ur xml's use above mentioned instead ,it can rip from more then just one place compared to XML64!


Anyway here is the script:

https://mega.nz/#!08Qx0YgQ!vRAEGTjVCSR0dCPavN7Z9n4siKq-xidNWKKDqEvPpqQ


python 2.7

Usage:
Copy gamelist.xml to folder where script is, run the script,preferably in dos box to see if any error pops up.

----------
After converting is done , open newly created my_text_file.txt with ur editor of choice, notepad++ will do just fine

and search replace all:
Code: [Select]
EMULATOR-REPLACE
with your emulator name , example:
Code: [Select]
MAME (Libretro)
(make sure u dont have regex enabled,just normal search and replace)

Last thing, depending on ur ROM PATH, u might get something like this:
Code: [Select]
./ddonpach;DoDonPachi (International, Master Ver.
u will need to get rid of that at start ./ and replace with nothing. empty nothing.NOT SPACE, just nothing.
or if ur path is different , get rid of it all before game rom name
example:
again and search replace all:
Code: [Select]
./
with nothing , example:
Code: [Select]

So end result will be:
Code: [Select]
ddonpach;DoDonPachi (International, Master Ver.

At the end rename my_text_file.txt to match ur emulator name, example: MAME (Libretro).txt
Copy that txt to your AM romlist and enjoy!

Have fun!


qqplayer

  • Sr. Member
  • ****
  • Posts: 301
    • View Profile
Re: [Tool] Convert emulationstation xml gamelist to Attract Mode romlist
« Reply #2 on: December 09, 2017, 05:34:16 PM »
Awesome , thanks!!!

cosmo

  • Full Member
  • ***
  • Posts: 54
    • View Profile
Re: [Tool] Convert emulationstation xml gamelist to Attract Mode romlist
« Reply #3 on: December 10, 2017, 06:34:59 AM »
This is great. thanks!!!

roostaar

  • Newbie
  • *
  • Posts: 8
    • View Profile
Re: [Tool] Convert emulationstation xml gamelist to Attract Mode romlist
« Reply #4 on: October 03, 2018, 02:51:55 PM »
This is really useful, thank you very much.  ;D

Is there any way I can sort the resulting .txt file by the Game Title rather than romfilename?
Space Invaders for example appears in the 'I's (invaders.zip).
I'm sure Excel can probably do it, but I'm not sure how...

Lastly, is it possible to add the Rotation;Control;Status;DisplayCount;DisplayType;AltRomname;AltTitle;Extra;Buttons info easily to this .txt file?

Would make for some interesting filters.  8)

Thanks again dude. :)

manzarek

  • Sr. Member
  • ****
  • Posts: 156
    • View Profile
    • YouTube
Re: [Tool] Convert emulationstation xml gamelist to Attract Mode romlist
« Reply #5 on: December 16, 2019, 12:21:33 AM »
thank you very much.  ;)
Mame Fighting