Preparing the Data Files

Run the "PAK" decryption tool, which you can download here.

Press the "Open PAK file" button.  Navigate to the DATA folder in your Praetorians directory, the default path is "c:\program files\eidos interactive\pyro studios\praetorians\dat"

Select the name of the PAK file you wish to decrypt.  All files are encrypted except the sound*.pak and music.pak file, if you select a file that is already decrypted it will ask if you wish to re-encrypt it.  I would recommend doing all the encrypted files, even though you will normally only need the varios.pak file.  Backups will be made with the .BACKUP extension.

You can now access files inside of the PAKs, which are standard ZIP files.  I recommend using WinRAR, available here, since it allows you to drag and drop folders into subfolders without extracting all the files.

 

Making a Multiplayer Map

For this example, we will be converting the "Tutorial III" campaign map into a multiplayer map.

First, we will need a copy of the original settings file for this mission.  Extract the "SP_TUTORIAL_3.MIS" file from the Misiones folder of the varios.pak file.  The main purpose of this file is to set up the map graphics, cameras, unit and building locations, and link to other data files such as scripts.  You will notice the multiplayer maps are also in this folder, named MP_x_y.mss, and the single player campaign maps ZZZ_name.mis.  If you wish to convert a campaign map in the future and are unable to decipher the Spanish filename the DefTextoNombreMisiones.dat in the textos folder of the textos.pak file is a good reference.  You can also use Google to do translations.

The first step is to make a copy of the newly extracted file and change it's name so it will appear as a new map.  I use the format similar to that of the other multiplayer maps, my initials, the number of players, and the number of the map, ie JN_2_1.mss

Now you can open up this new file in any standard text editor, such as notepad.  Let's look at the first section.  Comments and translations appear in green, and just notes, they do not appear in the file.  Lines that are in gray are deleting in the modifications.  If there is an arrow icon "" followed by an indented red line that means a new line is being inserted, usually replacing the line above it.  A "section" in the game is the *name, a { starts it, and a } closes it.  You must remove all of it to remove a section.

*ESCENARIO Scenario
{  
     *VISUAL "Mapas\SP_TUTORIAL_3.PVE" "Line of Vision" file
     *LOGICO "Mapas\SP_TUTORIAL_3.MLG" "Logic" file
     *OBJETOS "Mapas\SP_TUTORIAL_3.MOB" "Objects" file
     *AGUA "Mapas\SP_TUTORIAL_3.H2O" "Water" file
     *MINIMAPA "Mapas\Descripcion\SP_TUTORIAL_3.TGA" Mini-map graphic
     *MURALLAS "Mapas\SP_TUTORIAL_3.MUR" "Walls" file
     *ZONAS_ACC "Mapas\SP_TUTORIAL_3.ZAC" "Zones" file
     *DATOS_IA "Mapas\SP_TUTORIAL_3.pia" "Data" file
     *SCRIPT "Scripts\SP_TUTORIAL_3.TRG" Script file
     *CONFIG_TERRENO "Tutorial_3" Terrain type
     *MALLA 125 100 "Mesh"
}  

The only thing that needs to be changed in this section is the *SCRIPT line should be be removed, since it won't be used.  Scripts have more advanced settings, as well as all the logic to make a mission work, such as doing the mission briefing to all the special events and triggers.

*MAPEADOR ?
{  
     *CAMARA 32.124 57.4 61.2631 50 0 88 200 0.1 "Camera"
     *FLAGS 0x52a2ca Flags
     *FLAGS 0x1042a688  
}  
 

I am unsure of the the "camera" settings are for, so they are left as they are.  The flags setting is a series of hex values that toggle certain characteristics on and off.  What values do what is unknown, I had problems with the Centurions and the barracks in the fortress, so I copied the line from one of the original multi-player maps.  Here is what I replaced the existing line with: "*FLAGS 0x1042a688"

 

*COLORES_MAPEADOR "Colors" ?
{  
     *FONDO 0x7f000000 "Bottom"
     *MALLA_IMPAR 0xff408080 "Mesh Uneven"
     *MALLA_PAR 0xff808080 "Mesh Even"
     *MALLA_BORDE 0x7fc0c0c0 "Mesh Edge"
     *TEXTURE_BORDE 0x7f00ff00 "Texture Edge"
     *CASILLA_NOSEL 0x7fffffff "Square" ?
     *VERT_DIAG 0xffc0c0c0 ?
     *VERT_POND 0xff00ff00 ?
     *SPLINE_NOSEL 0xff400000 ?
     *STR_ENTRADA 0xff000000 "Entered" ?
}  

The purpose of this section is unclear, it appears to be hex RGB color codes for certain aspects of the map.  I left them the same.
 

*NOMBRE_MISION "LTEXT_MISION_SP_TUTORIAL_3" "Mission Name"
*NOMBRE_MISION "Fortress Siege (2)" "Mission Name"
*DESCRIPCION "LTEXT_TUTORIAL3_DESCRIPCION" Description

Here are the next three lines.  The first line is the name of the mission as it appears in the mission selector.  It points to a variable mentioned earlier in the DefTextoNombreMisiones.dat in the textos folder of the textos.pak file, the text there is inserted as the title.  However, we do not want to change that file since it is a shared files, and it would be overwritten by other custom maps.  You can enter your new name directly between the quotes, such as "Fortress Siege (2)".  The 2 is the number of players this map will be, and is only cosmetic to make the format of existing map names.  The next line is the description, and isn't used in multiplayer maps, so it is removed.

 

*EFECTO_ATMOSFERICO Effect Atmosphere
*SONIDO "Sound"
{  
     *TIPO "ARIO" ?
     *POSICION 29.8364 0 -1.2356 "Position"
     *POSICION 32.2671 0 2.32173 "Position"
     *POSICION 41.2274 0 3.05127 "Position"
      ...etc  
}  
*MUSICA "Music"
{  
     *TIPO "SA01" "Type"
}  
*MUSICA_BATALLA "Music Battle"
{  
     *TIPO "SB01" "Type"
}  

This is a large section with many "Sound" sub-sections and appears to be ambient sound affects, triggered at specific locations?  It also contains the background music and battle music.  I left them in place, untouched.

 

*MAX_PLAYERS 2 Maximum Players
*POS_INICIAL 101.0 20.0 Initial Starting Point
*POS_INICIAL 25.0 77.0 Initial Starting Point
   
*CIVILIZACION "Civilization"
{  
     *NOMBRE "NEUTRAL" "Name Neutral"
     *RAZA "BARBAROS" "Race Barbarian"
     *COLOR 7 Team Color
     *NEUTRAL Allegiance; team
}  
*CIVILIZACION  
{  
*NOMBRE "Romanos"  
*NOMBRE_LEGIBLE "LTEXT_TUTORIAL3_CIV1_TXT"  
*RAZA "ROMANOS"  
...etc  
*CRITTER  
{  
     *TIPO "CONEJO"  
     *POSICION 48.1718 -0.0162716 85.5148  
     *ORIENTACION 0  
}  

The first three lines are new, the first one sets the maximum number of players, both CPU and human.  The second two lines set up starting locations for those players, you will need one POS_INICIAL line for each possible player.  The parameters for the line are POS_INICIAL y ? x.  I'm unsure of the middle setting, but here is a quick and dirty sketch of how the x/y coordinate system works.  The 0,0 location starts in the upper left corner, and x is east/west, and y north/south.  The scale depends on the size of the map, this map x roughly 0-100, y is 0-120.  The neutral civilization section is left in since it appears in the multiplayer maps as well, but does not appear in the game.  Everything after through the last "critter" is removed.  These contain all the troop and creature locations, and aren't used in multiplayer.

 

 

*ESTRUCTURA Structure
{  
     *NOMBRE "Matisco" "Name"
     *NOMBRE_LEGIBLE "LTEXT_TUTORIAL3_PUE1_TXT" "Name"
     *DEFINICION "PESE_1" "Definition"
     *POSICION 101.5 -0.0162735 25.5 "Position"
     *POSICION 103 -0.0074501 8 "Position"
     *ORIENTACION 0 "Orientation"
     *VISUAL "PESE_1" "Visual"
     *HABITANTES 200 "Inhabitants"
     *HABITANTES 350 "Inhabitants"
     *MAX_HABITANTES 200 "Maximum Inhabitants"
     *MAX_HABITANTES 350 "Maximum Inhabitants"
     *VEL_REGENERACION 5 "Regeneration"
}  

This section now follows neutral civilization section.  The first structure is the village in the lower right.  The first first two lines set up the name of the village, I removed them so it shows the default "Village" name.    The definition line defines the name of the village to the game.  After the "PE" are compass directions that rotate the village, showing which direction the exit is drawn as pointing.  The next line uses the same format as noted above, POSICION y ? x.  I changed the location slightly to move it so it couldn't be attacked from across the river.  I am unsure of the ORIENTACION line, it appears to usually be 0.  The VISUAL line is how the object appears on the screen.  HABITANTES is how many people are currently in the village, and MAX_HABITANTES is the maximum possible people in the village.  VEL_REGENERACION is how many seconds it takes for a village to be re-added to the village.  I raised the population of the village from 200 to 350 to counteract the other player's fortress.

 

*ESTRUCTURA Structure
{  
     *DEFINICION "PUERTAFORTALEZA" "Definition" "Fortress Door"?
     *POSICION 25.5 -0.0109406 69.5 "Position"
     *ORIENTACION 4.71239 "Orientation"
}  
*ESTRUCTURA Structure
{  
     *NOMBRE "Barracks" "Name"
     *DEFINICION "BARRACON_ROMANO" "Definition" "Roman Barracks"
     *POSICION 25.5 -0.0162754 86.5 "Position"
     *ORIENTACION 0 "Orientation"
     *GENERADOR "BARRACON_ROMANO" "Generate" "Roman Barracks"
     *HABITANTES 0 "Inhabitants"
     *HABITANTES 200 "Inhabitants"
     *MAX_HABITANTES 0 "Maximum Inhabitants"
     *MAX_HABITANTES 200 "Maximum Inhabitants"
     *VEL_REGENERACION 0 "Regeneration"
     *VEL_REGENERACION 6 "Regeneration"
     *PUNTO_ENTRADA 0 0 0 "Entrance Point"
     *PUNTO_SALIDA 0 0 0 "Exit Point"
}  

The first structure is the fortress door, it is left alone.  The second structure is the barracks in fortress.  The first two lines of it set up it's name and type, "Roman Barracks".  The position line is the same as before, POSICION y ? x, same with ORIENTACION.  The GENERADOR function seems to be required, where it isn't to make a normal village.  The HABITANTES and MAX_HABITANTES lines are changed to 200, in the tutorial you can't use the village so they're set to 0.  The VEL_REGENERACION line is set to 6 so it people will repopulate it, slightly slower then in the village outside.  The last two lines would set up entrance and exit points to the barracks, removing them lets the game set them up.

 

*ESTRUCTURA Structure
{  
*NOMBRE "PUENTE" "Name" "Bridge"
*DEFINICION "PUENTE_TOSCO" "Definition" "Course Bridge"
*POSICION 46.5 -0.0162735 14.5 "Position"
*ORIENTACION 0 "Orientation"
}  

This final structure is the bridge in the map.  None of the settings need to be changed.  Everything else after this structure can be removed, just need to leave the final un-indented "}" at the end to close the "{" at the start of the file.  The sections deal with zones and camera angles and don't apply.

There is one other possible modification, you can replace the barracks structure above with this one:
 

*ESTRUCTURA Structure
{  
     *DEFINICION "PESW_1" "Definition"
     *POSICION 27.5 -0.0162754 83.5 "Position"
     *ORIENTACION 0 "Orientation"
     *VISUAL "PESW_1" "Visual"
     *HABITANTES 200 "Inhabitants"
     *MAX_HABITANTES 200 "Maximum Inhabitants"
     *VEL_REGENERACION 6 "Regeneration"
}  

This replaces the barracks with a village.  It doesn't look as nice but has some advantages.  First, playing against the CPU in skirmish if the computer starts in the fortress they will actually play, they don't understand it and will rush to the other village otherwise, never using it to create any units.  It also helps the game decide when you've one where it doesn't when the barracks is destroyed. 

 

Playing Your Map

So now you have a completed map, you need to put it into a PAK file.  It must be in a "Misiones" folder.  So create one on your hard drive and copy the new map into it.  Then step back out of the folder and right click on it, and assuming you have WinZip installed select the "Add to ZIP" option.  When it asks for the filename, enter in any name that isn't currently a standard PAK file, I use the same name as the mission file, ie jn_2_1.pak.  Note is must have a .PAK extension, not .ZIP.  If you're modifying your file with new changes you can also open it with WinRAR and drag and drop the file into the appropriate subfolder.  Now simply copy the file into your DATA folder you found the PAKs in at the start of this tutorial, start the game, and it should now appear under the multiplayer and skirmish level load screens.  Start it like any other map.

Have fun :)