I will take here the example of the 'Oric-1' computer
1. Preparing elements
1. Choose a name for the new system. This name will be used throughout the whole process. Here we choose "Oric-1".
2. Create an icon for the new system. The icon should be a 200x150 pixels .png file. Its name should be "icon.png".
3. Go to "mGalaxy\Data\BaseSystems" and create a new folder called that name: "Oric-1"
4. Place the icon inside the "mGalaxy\Data\BaseSystems\Oric-1" folder
2. Editing
1. Open "mGalaxy\Data\BaseSystems\BaseSystems.xml" with a text editor.
2. At the end of the document, just before the "</Emulators>" ending tag, paste this block of code:
Code: Select all
<System type="[1]">
<Name ss="[2]" em="[3]" tgdb="[4]" gb="[5]">[6]</Name>
<Emu selected="[7]">
<Cmd hidden="false" name="[8]" value="[9]"/>
</Emu>
<Extensions>[10]</Extensions>
</System>
Code: Select all
<System type="[1]">
The Oric is a computer, so we edit this way: <System type="Computer">
Line 2: ID's on web databases and system name
Code: Select all
<Name ss="[2]" em="[3]" tgdb="[4]" gb="[5]">[6]</Name>
Replace [3] with the ID for that system on EmuMovies (optional)
Replace [4] with the ID for that system on TheGamesDB (optional)
Replace [5] with the ID|ShortName for that system on GiantBomb (optional)
Replace [6] with the system name we have chosen for the folder: Oric-1
If you don't know the exact ID for that system , leave it empty ("")
<Name ss="" em="" tgdb="" gb="">Oric-1</Name>
I do know some ID's for that system. So the line will finally look like this:
<Name ss="131" em="143" tgdb="" gb="">Oric-1</Name>
Line 3: Selected emu index
Code: Select all
<Emu selected="[7]">
Line 4: Emulator index, command window visibility, emulator name, command line
Code: Select all
<Cmd hidden="false" name="[8]" value="[9]"/>
hidden="false": indicates whether or not the command window will be hidden when launching game (visible (default) is "false", hidden is "true")
Replace [8] with the name you've chosen for the emulator (the name chosen for [7]).
Replace [9] with the full command line to launch a rom.
Composing the command line
Well...This is the hardest step of this tutorial!
The goal is to give the full command line structure to the emulator!
If we were to launch a game from a command window (or .bat file) we would have something like this:
Code: Select all
"C:\Program Files (x86)\Oricutron_win32_v12\oricutron.exe" "D:\ROMS\Oric\Hunchback (UK) (19xx).tap" --fullscreen
mGalaxy will know about the application path and folder path made in mGalaxy_Runway! So, we do not want here to hard code those paths but just give mGalaxy the structure for the rom path (the reason being that some emus for instance won't request the extension info..while some other do!) and command option!
The way to achieve this is to use text symbols (also called 'variables').
The path to the rom folder is symbolized by: %path
The name of the file is symbolized by: %file
The extension for the file is symbolized by: %ext
The whole thing has to be surrounded by double quotes. A double quote is symbolized by: "
Finally you can give the command line options if needed.
So, the line will look like this:
<Cmd hidden="false" name="Oricutron" value=""%path\%file%ext" --fullscreen"/>
NOTE:
Sometimes the emulator is missing an essential function like going to full screen or exiting with the 'Escape' key (which is requested by mGalaxy)!
In that case (and this is the case for our Oric-1 example!) this is not the emulator that will be launched but a script that will behave as an intermediary between mGalaxy and the emulator.
If this occurs, you don't have to change a thing in the path/file/extension/command info that you've previously given!! The only thing is to add "[Script]" to the emulator name: name="Oricutron [Script]"
This being done, mGalaxy knows that he will have to search for a script (with the same name: Oricutron [Script]) in "mGalaxy\Data\Scripts\"
Writing a script should be part of another tutorial so we won't go further on the topic here!
Line 5
Code: Select all
</Emu>
Line 6: Allowed file extensions
Code: Select all
<Extensions>[10]</Extensions>
Here we will have:
<Extensions>.dsk,.tap</Extensions>
Line 7
Code: Select all
</System>
RESULT
The final block of code should now look like this
Code: Select all
<System type="Computer">
<Name ss="131" em="143" tgdb="" gb="">Oric-1</Name>
<Emu selected="Oricutron [Script]">
<Cmd hidden="false" name="Oricutron [Script]" value=""%path\%file%ext" --fullscreen"/>
</Emu>
<Extensions>.dsk,.tap</Extensions>
</System>
Come here on the forum, and share your new system info so that we can include it to mGalaxy!