Jump to content
(Public Beta) HyperSpin 2 is now available for everyone ×

HyperROM2XML EX Plus Alpha


Recommended Posts

Posted

** Updated to 1.5 [26NOV2011]**

1.5 New Features [26NOV2011];

* Fixed the CR/CRLF Problems found by DR9

HyperROM2XML should now accept either Carriage Return and/or Line Feed XML's.

* New commandline mode, suggested by bravo911

HyperROM2XML can now be run as a commandline program. Here's a the output from "HyperROM2XML.exe -help" when run from the commandline;

Command line Options

================================

-rom2xml = ROM2XML Functionality

-xml2rom = XML2ROM Functionality

WARNING: Make sure paths for directories do not include a trailing \ !

-rom2xml

===========================

(* Indicates required)

* -rompath="C:\path\to\roms"

(This is the path to your roms we will be using)

* -outxml="C:\mynew.xml"

(This is what the XML will be saved as)

-removetags

(if this is included it will remove the tags from the game names)

-ismame="C:\path\to\mame.exe"

(if this is included replicate the functionality of the Is Mame check

box from the UI, you need to supply a valid MAME executable)

-fileext="zip"

(if this is included it will filter the file types to include in the

XML, otherwise ALL files will included)

-xml2rom

===========================

(* Indicates required)

* -inxml="C:\Existing.xml"

(This is the HyperSpin XML to use)

* -fileext="zip"

(This what file extension to match)

* -sourcepath="C:\path\to\roms"

(This is the path to your roms from which we will copy)

* -targetpath="C:\path\to\roms"

(This is the path to the destination you want the roms copied to)

1.4 New Features [19FEB2011];

* Fixed the Tab/Indent problem

HyperROM2XML should now correctly accept an XML even with Indentation or Tabs.

1.3 New Features [03APR2010];

* Convert a Directory of Roms into a HyperSpin XML (Now with Added MAME Support!)

ROM2XML.png

The "Is MAME" option reads a MAME.EXE file and grabs the Description for each ROM. So instead of using the Rom Name for the Description and Name, it uses the Description MAME.EXE gives, ie./

Is MAME Checked (Remove Tags Checked)

_______________________________________________

rom name = sfa2

description = Street Fighter Alpha 2

_______________________________________________

Is MAME Checked (Remove Tags Unchecked)

_______________________________________________

rom name = sfa2

description = Street Fighter Alpha 2 (Euro XXXXXX)

_______________________________________________

Is MAME Unchecked (Remove Tags Checked)

_______________________________________________

rom name = Super Mario Kart (USA)

description = Super Mario Kart

_______________________________________________

Is MAME Unchecked (Remove Tags Unchecked)

_______________________________________________

rom name = Super Mario Kart (USA)

description = Super Mario Kart (USA)

_______________________________________________

Take a HyperSpin XML + a Directory of Roms and Copy the HyperSpin Compatible Roms to a new Directory.

(It will list how many were successful and create a MISSING.LOG to tell you which files it couldn't find)

XML2ROM.png

* Will also save your current settings to registry, saving you time when you reload the program. [Thanks shimoda]

* Added MAME Support using external MAME Executable.

* XML2ROM Will also work for Themes, Boxart and others based on a HyperSpin XML. [Thanks shimoda]

Downloads: (Requires .NET 2.0)

Binary (1.5)

Source Code (1.5)

Of all the things I've lost,

I miss my mind the least...

  • Replies 67
  • Created
  • Last Reply
Posted

Placed in the Gold Member Downloads/HyperSpin 3rd Party Apllications/Database-XML Utilities directory. Thanks! also for the code! ( at least it'll be there sometime in the next thirty minutes or whenever I can sneak in the ftp again :))

path=c:\HyperSpin;%path%

; clear the runway, HyperSpin is coming through!

for /f "tokens=not_enough delims=gameover" %%A in (HSKicksAss.txt)

do echo believe the hype > badassfrontend.txt[sIGPIC][/sIGPIC]

Posted

Works great. It's fast. The tag stripping was a surprise. I would prefer if this was optional (perhaps a check box). Not a big deal though. Thanks.

Posted
Works great. It's fast. The tag stripping was a surprise. I would prefer if this was optional (perhaps a check box). Not a big deal though. Thanks.

Nice Idea, 1.1 version is updated in 1st Post. Cheers :)

Of all the things I've lost,

I miss my mind the least...

  • 2 weeks later...
Posted

Works best for Consoles/HandHelds :)

(ie./ Systems that have Full Rom names like "Super Mario Bros (U).zip", not for systems like MAME with rom names like "3countb.zip")

This just gets the names of the files to make a database.

  • 3 weeks later...
Posted

Thanks for these adds. Regarding your first post, the thanks go to you for adding these requests. They'll make the workflow much easier. I'll be adding a short write up for this in the software menu as it is a siple, but useful utility especially for use with mame.

path=c:\HyperSpin;%path%

; clear the runway, HyperSpin is coming through!

for /f "tokens=not_enough delims=gameover" %%A in (HSKicksAss.txt)

do echo believe the hype > badassfrontend.txt[sIGPIC][/sIGPIC]

Posted
Thanks for these adds. Regarding your first post, the thanks go to you for adding these requests. They'll make the workflow much easier. I'll be adding a short write up for this in the software menu as it is a siple, but useful utility especially for use with mame.

No probs shim, really good additions thanks to your good ideas :D

** Let me know if you find any bugs! **

Of all the things I've lost,

I miss my mind the least...

  • 4 weeks later...
Posted

Having some trouble using the XML2ROM feature.

I create a HyperSpin XML of a custom ROM list using RomLister.

Load it into the XML2ROM tab, select the folder with my rom zip files and choose an output. First time I click go it doesn't copy any files, it says:

Files Copied: 0/1

Failed to Copy 1 Files

See "LasrRun_Missing.log"

The log file is empty

If I click go again I get an error message, this is what is says in the details section:

************** Exception Text **************

System.ArgumentOutOfRangeException: Value of '5' is not valid for 'Value'. 'Value' should be between 'minimum' and 'maximum'.

Parameter name: Value

at System.Windows.Forms.ProgressBar.set_Value(Int32 value)

at HyperROM2XML.frmMain.btnXML2ROM_Go_Click(Object sender, EventArgs e)

at System.Windows.Forms.Control.OnClick(EventArgs e)

at System.Windows.Forms.Button.OnClick(EventArgs e)

at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)

at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)

at System.Windows.Forms.Control.WndProc(Message& m)

at System.Windows.Forms.ButtonBase.WndProc(Message& m)

at System.Windows.Forms.Button.WndProc(Message& m)

at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)

at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)

at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

My XML FIle is basically set up like this (just more games, and I think this forum messes up the indentations of the lines):

<menu>

<game name="10yard">

<description>10-Yard Fight (World)</description>

<cloneof></cloneof>

<manufacturer>Irem</manufacturer>

<year>1983</year>

<genre>Sport / Football Americano</genre>

</game>

<game name="1941">

<description>1941 - Counter Attack (World)</description>

<cloneof></cloneof>

<manufacturer>Capcom</manufacturer>

<year>1990</year>

<genre>Sparatutto / Volo Verticale</genre>

</game>

<game name="1943">

<description>1943: The Battle of Midway (US)</description>

<cloneof></cloneof>

<manufacturer>Capcom</manufacturer>

<year>1987</year>

<genre>Sparatutto / Volo Verticale</genre>

</game>

</menu>

Any help is appreciated, so I dont have to manually move roms.

Thanks!

Posted

Where can i find rom2xml , i can not locate it at all , if i find it and sort your prob ill let you know , let me know where to get it, please

Posted

path=c:\HyperSpin;%path%

; clear the runway, HyperSpin is coming through!

for /f "tokens=not_enough delims=gameover" %%A in (HSKicksAss.txt)

do echo believe the hype > badassfrontend.txt[sIGPIC][/sIGPIC]

Posted
Having some trouble using the XML2ROM feature.

I create a HyperSpin XML of a custom ROM list using RomLister.

Load it into the XML2ROM tab, select the folder with my rom zip files and choose an output. First time I click go it doesn't copy any files, it says:

Files Copied: 0/1

Failed to Copy 1 Files

See "LasrRun_Missing.log"

The log file is empty

If I click go again I get an error message, this is what is says in the details section:

************** Exception Text **************

System.ArgumentOutOfRangeException: Value of '5' is not valid for 'Value'. 'Value' should be between 'minimum' and 'maximum'.

Parameter name: Value

at System.Windows.Forms.ProgressBar.set_Value(Int32 value)

at HyperROM2XML.frmMain.btnXML2ROM_Go_Click(Object sender, EventArgs e)

at System.Windows.Forms.Control.OnClick(EventArgs e)

at System.Windows.Forms.Button.OnClick(EventArgs e)

at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)

at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)

at System.Windows.Forms.Control.WndProc(Message& m)

at System.Windows.Forms.ButtonBase.WndProc(Message& m)

at System.Windows.Forms.Button.WndProc(Message& m)

at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)

at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)

at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

My XML FIle is basically set up like this (just more games, and I think this forum messes up the indentations of the lines):

<menu>

<game name="10yard">

<description>10-Yard Fight (World)</description>

<cloneof></cloneof>

<manufacturer>Irem</manufacturer>

<year>1983</year>

<genre>Sport / Football Americano</genre>

</game>

<game name="1941">

<description>1941 - Counter Attack (World)</description>

<cloneof></cloneof>

<manufacturer>Capcom</manufacturer>

<year>1990</year>

<genre>Sparatutto / Volo Verticale</genre>

</game>

<game name="1943">

<description>1943: The Battle of Midway (US)</description>

<cloneof></cloneof>

<manufacturer>Capcom</manufacturer>

<year>1987</year>

<genre>Sparatutto / Volo Verticale</genre>

</game>

</menu>

Any help is appreciated, so I dont have to manually move roms.

Thanks!

Is anyone else having this problem? I've tested it many times, but only with HyperSpin created lists or hand edited lists.

I'll take a look at it soon as I'm recovering from a series of HDD failures and currently running from an old 15gb drive :bawling:

Cheers.

EDIT: Hmm that XML looks wrong, I think thats the old HyperSpin XML format? Gimme a week or two and i'll sort it out.

Of all the things I've lost,

I miss my mind the least...

  • 1 month later...
  • 1 month later...
Posted

Fantastic tool! Thanks, already made some things easier.

I have a request, since for the life of me I can't find a tool for it, even unrelated to roms..

It's similar to how xml2rom works, except I guess you would call it, rom2wheel.

Being that your program gets a list of all your roms, then copies all matched wheels (or art of any sort, like snaps, or even .flv) to a specified folder.

What that would be handy for would be setting up Hyperspin to display only what you have snaps for, and keeping the full mame.xml.

(with recursive directorys?)

That feature in some cases might work better than creating an xml.

For eg, keeping the full mame genre xmls too. Probably the hyperspin feature of displaying only what you have art for is one of it's single most handy ideas ever.

Please and thank you kind sir!?

Posted

For anyone wanting to do the above, right this minute with a little effort, heres how.

Go in to your roms dir and open a cmd.exe (crtl+shift+right click)

type this in the command prompt:

dir /b *.zip >list.txt

Next create a batch file with this in it:

@echo off
REM -- Prepare the Command Processor --
SETLOCAL ENABLEEXTENSIONS
SETLOCAL DISABLEDELAYEDEXPANSION

::BatchSubstitude - parses a File line by line and replaces a substring"
::syntax: BatchSubstitude.bat OldStr NewStr File
::          OldStr [in] - string to be replaced
::          NewStr [in] - string to replace with
::          File   [in] - file to be parsed
:$changed 20100115
:$source http://www.dostips.com
if "%~1"=="" findstr "^::" "%~f0"&GOTO:EOF
for /f "tokens=1,* delims=]" %%A in ('"type %3|find /n /v """') do (
   set "line=%%B"
   if defined line (
       call set "line=echo.%%line:%~1=%~2%%"
       for /f "delims=" %%X in ('"echo."%%line%%""') do %%~X
   ) ELSE echo.
)

save it as findreplace.bat or something.

execute :

findreplace.bat .zip .png list.txt >png-list.txt

Now copy png-list.bat into your wheels/marguees/snaps folder.

Make a new batch file with this in it:

@echo off
pause
for /f %%a in (.\list-png.txt) do (
xcopy %%a C:\games\hyperspin-mame\Media\MAME\Images\Wheel
)
pause

name it find-png-copy.bat or something.

You should of course replace the directory with where you want the artwork to go.

This can also be used for video and screenshots, just change

findreplace.bat .zip .png list.txt >png-list.txt

to

findreplace.bat .zip .flv list.txt >flv-list.txt

and edit the last batch to the relevant folder.

The last two files are all you need to copy to each art folder, that is

find-png-copy.bat and png-list.txt.

Man does this make a huge time saver.

Also, if you are missing any art, it will come up in the command prompt when you run the last batch. You can also run

find-png-copy.bat >logfile.txt

To dump it in a txt file

  • 2 weeks later...
Guest Syhrus
Posted

Hello, why XML2ROM doesn't work ?? :( :( :(

I've the same problem as Aphexdash :( :( :( Have you a solution please ??!!!

Thanks.

Posted

I am having the same problem using a xml I created using HL. I found out it has to do with the xml having the games indented (tab).

***TAB***<game name="2020 Su.....

I removed the tab on the 1st 2 entries & XML2ROM worked, saying complete 2/2. I figured out what seems to be the problem, but it would be too much to edit every entry in all my xml's!

PS. Aphexdash - Great program. Hopefully this is an easy fix to straighten out. Thanks

[sIGPIC][/sIGPIC]

  • 2 weeks later...
Posted

Is the program taking away the year and developer from the titles? I remember having them at some point and when I used hyperROM the year and developer info were gone. Anyway i can keep that info in?

Posted
Is the program taking away the year and developer from the titles? I remember having them at some point and when I used hyperROM the year and developer info were gone. Anyway i can keep that info in?

The program doesn't take it away. It rebuilds the XML from scratch, but the only info it has is the ROM's file name. If you want to keep all the proper info, get a list of all your games and use that with HyperList (at the top menu).

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...