Setup

Setup should be pretty easy…

.5) Install a recent java jdk or jre (SE). -> http://java.sun.com/javase/downloads/?intcmp=1281 (jre 6 update 11 will be fine)

1) Download the WebMAME zip file and extract it into a directory… Boy that was easy.

2) Either download WebMAME_libs zip file and extract it into the same directory, or download each package seperately and then copy the jar file into the lib directory.

you will need:
commons-beanutils.jar -> http://commons.apache.org/downloads/download_beanutils.cgi
commons-collections-3.2.1.jar -> http://commons.apache.org/downloads/download_collections.cgi
commons-digester-1.8.jar -> http://commons.apache.org/downloads/download_digester.cgi
commons-logging-1.1.1.jar -> http://commons.apache.org/downloads/download_logging.cgi
jetty-6.1.0.jar -> http://dist.codehaus.org/jetty/jetty-6.1.x/jetty-6.1.1.zip
jetty-util-6.1.0.jar -> with jetty jar
servlet-api-2.5.jar -> with jetty jar

These are all contained in the WebMAME_libs zip file, but in case my bandwidth drops, you might want to just grab them from their source. (its safer there also)

2.5) Download CURL (http://curl.haxx.se/download.html) and place the executable either in the WebMAME directory (not the lib directory) or place it in your path somewhere.

you should now have all the files you need.

3) copy mame.xml into your resources directory. What file? This is the mames -listxml as a file. From a command line, go into your mame directory and type "mame -listxml > c:\webmame\resources\mame.xml" and press enter. Modify the directory based on where you put the webmame files.

4) edit your emulator.xml in the resources directory.

should look like

<?xml version="1.0" encoding="UTF-8"?>
<emulators>
<emulator name="mame" directory="c:\emul\mame\" executable="mame.exe"/>
</emulators>

it only looks at the name of the emulator (call it as you want), the directory and the executable file. In the future, I will add additional attributes to this.

Modify it to point to your mame directory and mame executable file.

Modify Server Settings
Look in the resources/settings.properties file
You can modify the location of your snapshot/marquee/ect directories
You can also change the port of the server. Dont change it unless you know what it is.
You can also modify the root. This will allow you to change ALL the urls from http://localhost/emul/XXXXX to http://localhost/myawesumesetup/XXXX (note: must check for availability of www.myawesumesetup.com with godaddy)

Modify the webpages look / feel
Default is ok, but if you want it to look like 'your own' you can
1) Modify the web_files/header.htm…. This is pasted in the top of EVERY page I generate.
2) Modify the web_files/footer.htm…. This is pasted INSIDE a list… (ie, add <li>XXX</li>)
3) Modify the webmame.css file…. NOTE: This appears to be broken at the moment… sorry.

Webpage Configure

5) goto [http://localhost/emul/pages cat

add categories you want (enter in field)
goto all emulators
select mame
select alpha for game to add
select game
check all categories this game is associated with

to allow you to run from a command line
copy categories.bat file to name of category… ("copy category.bat fighter.bat")
test ("fighter sf2")
done

Configure by hand
NOTE: I'm not going to modify this section, since I don't know if anyone will use it… The urls have been updated in the main page.

5) modify your Categories.xml

I sent a copy so you can see what it should look like. You can actually delete this file and create it all from inside the app.

<?xml version="1.0" encoding="UTF-8"?>
<categories>
<category name="fighter">
<game name="puckman" emulator="mame"/>
</category>
</categories>

this is saying that the game "puckman" will be run in the emulator "mame" for the category "fighter". There can be multiple categories and multiple games per category.

type some by hand if you want, or just delete the puckman game. It's really there to get an initial working game running for testing.

6) run "startServer" batch file. You should be in the WebMAME directory when you run this. The classpaths are relative since I don't have an install program to update them to the real libs directory. But should be fine. If you want to create a shortcut to this batch file make sure to set the 'starts in' to the WebMAME directory.

The server should now be started. You should now have the app server running. To test this, load IE (or whatever)

NOTE: When entering these in a web browser, you do not need the "%20", you can use spaces. IE will replace them for you. But since these could be clickable, and I could test them here to make sure they work, I added the %20.

Lets create a category. Type "http://localhost/config/testcat%20create". Nothing will come back (but no errors should be shown). Yes, I need to add better feedback, wait for version .2.

Next, lets add puckman to the new 'testcat' category. type "http://localhost/config/testcat%20add%20puckman%20emul%20mame".

Now, lets see if the listxml has been updated. Type "http://localhost/mame/testcat%20-listxml". You should see a custom listxml with only the puckman game in it. If not… somethings not working, go back and see ifyou can spot whats wrong (look at the startServer window for errors).

Next, lets try and launch it. type "http://localhost/mame/testcat%20puckman". Its should run launch pacman.

You should now have the basics done. Edit the categories.xml and see how it was changed.

Too remove a game, just type "http://localhost/mame/testcat%20puckman".

Now its time to get command line working.

7) copy categoryName.bat to testcat.bat (note that its called the same thing as the category name above. I DO use this name in the batch file. This allows for no modifications to the batch file for each category).

8) in a command prompt type "testcat -listxml" and enter. You should see the listxml
9) type "testcat -listfull". Another test
10) type "testcat puckman". this should launch pacman.

note. while this is running, you can launch another game from either a browser (even from another machine, just change the 'localhost' to the computers ip address or update your hosts file if the ip address is known to change often.

The basics are done

HyperSpin Setup

NOTE: We copy and move Themes around. I've been using it on my system for weeks without loss, but I don't guarantee there aren't bugs. You might want to backup the themes.

To start off with, update your settings.properties to point to your HyperSpin

hyperspinthemes=true
true/false depending on if you want HyperSpin enabled

hyperspinthemedir=D:/emul/hyperspin 1.2/HyperSpin/media/mame/themes
Directory that the repository themes are stored. This is used on pages to tell you if one exists only.

hyperspinmamedirectory=d:/emul/HyperSpin 1.2/HyperSpin/Databases/
Database Directory.

hyperspindir=D:/emul/hyperspin 1.2/HyperSpin/
Main Hyperspin directory

hyperspinthemeextension=zip
The extension of all themes (not sure if HyperSpin handles .rar's ect)

hyperspinthemerepository=MAME
Name of the repository. I keep a 'all games' under MAME… But if you want to truely hide them, you could name this anything.

hyperspinthemerepositorykeepcopy=true
This is if you keep a copy of the themes in the repository. IE, copy the first time, or move them around.

hyperspinwheelimageextension=png
This is the extensions to the wheel images copied with each theme.

hyperspindescriptioncleanup=true
This is if we try and remove the extra stuff from the description "Game (made from xxx)" -> "Game"

hyperspingenreini=Genre
Just keep it to this, I don't remember now what it was…

You need to do some manual editing to HyperSpin files / directories for each Category.. (Example below is for a Starwars control panel)

1st. Copy the batch file in webmame directory (as always). ("copy category.bat Starwars.bat")
2nd. Copy the MAME.ini file to the category name .ini in the HyperSpin Setting directory (IE, "copy MAME.ini Starwars.ini")
3rd. Modify the new .ini file to point to the new batch file ("edit Starwars.ini", change to look like this
[exe info]
path=c:\emul\webmame rompath=c:\emul\roms userompath = false
exe=Starwars.bat
winstate = HIDDEN
hyperlaunch=false
4th. Create a blank Media directory for the new category. I copy the basics of Images (minus wheel), Sound and Video… Then I create blank directories for wheel and Themes)

HyperSpin
Media
Starwars <- new
Images <- copies
Backgrounds
BetaBrite Classic
BetaBrite Prism
Other
Special
Wheel <- blank
Sound <- copy
Wheel Sounds <- copy
Video <- blank
Themes <- blank

I create a blank template directory and copy it in for each category when I create them.

5th. Create empty Database directory for each Category (ie "cd c:\HyperSpin\Databases", "md Starwars")

I think that is it. Next go to a webpage, add the category in WebMAME, add a few games, and you will start seeing the wheel / themes and other stuff added automatically.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License