regresar



Badc Templates









1. Template files overview

Templates in badc is not a single file, they are many, and they are build in diferent way.

geo_obj.data : Holds most important data. It has 4 main group data:
1) The airfields localization, their damage, the park places, army owner, code name, etc
2) Sector coordinates, type (atackable or not), TTL, army owner, etc
3) City name, coordinates, damage, suply radius, spot Zones, army owner, etc...
4) A list of relation on city and sectors, to know wich sectors has a city and will be not attacable till city has 50% damage

city.mis : this is a mission file created using FMB (Full Mission Builder). It is the more time consuming file. Here you determine wich cityes are part of the campaign, and make the spot Zones. Each of this spot zone is an atacable place. This file indicates what types of objects will be place, and where they will be placed. It NOT has the objects. The indicators are a combination of aircrafts way points of differen altitudes to represent different objects. (I will explain later). Later generator will put objects "under" those WP lines.

tanks_wp.mis : This is the tank placement template. Each serctor of 10x10 km needs to have 2 or more "points". Later the genator will use 2 of those "points" to place champs and initial 9-tank-group. As you see 2 points at least are needed. More is better, so generator will have more combination of 2 points to pick from, making more umpredictable where champs /moving tanks are placed. Those "points" are static tanks, really do not matter what type the object is, the generator will look objects coordinates (the points). On sectors where is impossible to place 2 tank places, the sector will be un-attacable.

red_obj.mis : A mission that holds one LI-2 per airfield. Nothing more.

blue_obj.mis : Same, but with JU-52, and objects numbers starts with 10000.

frontline.mis: This file holds the frontline status. It has one flag per square, exept for the unattacable sectors.

aircraft.data: This file has the information of plane aviables, type, tasks, airclass, etc etc.

imap.data : This file is a HTML image image to aid target selection at mission creation time. It holds the setors names (and aditionally fields and city names) to be displayed as a popup when placing mouse over front image.

To create templates for a map, all files described above has to be written, each file has particular conditions to meet. The templates files at firt impresion looks very complex, but they are not.






2. Places templates description

I provide in this guide a explanation file by file and some tools to semi-automate template creation. But before start looking onto each file I better explain the difference between "static objects templates" and "places template".

Static objects templates are files created with FMB, they have all the objects of the map. Usually it holds thouthands of cars, planes, AAA, trains, etc. all spread on a particular map. Later, when you attack a place, mission generator looks for a set of objects close to that place you attack, "copy" them and "paste" into the mission it is created.

This system has advantages and disdvantages. They are easy to build, can take several hours to build them, but later are easy to use for generator program with "copy and paste". The disadvantage is that you cant change object types, you need a red template and a blue template, the objects are all at the same place and after several attacks to same place people can know where is the AAA and where are the jackpots (best place to bomb).

Badc uses 2 static objects templates files: red_obj.mis and blue_obj.mis. They only hold static planes to place on airbases, 1 per base, and used only to make bases display correct color on maps. (no white bases).

Places templates: This templates do not have objects that later will be on mission. They have the "places" where we like to have objects placed. Later the generator will insert the objects in correct place into the mission we are generating. Thats all.

The paces templates are not hard to make, it only needs some convetion (rules) on how those places are marked, to later the generator understand where and how the objects has to be inserted. Badc uses "place" templates for airbases, tank waypoints and city targets. Lets see a general example, later we will see each template details rules.

Lets say we are creating a static template for an airfield, we place several planes, and can look like this:


After those planes are selected (type) and placed, we have to rotate them one by one and later align them. Now, lets use the same airfiled, and use the "place template" idea. We want to have some planes aligned in 2 lines, like is showed in next image:

So later the generator will insert planes like whow next image (they are correct lined up and rotated, maybe not visible because image size):

So, how do we make those lines to later the generator place the objects? We use an aircraft (any flyable) and we set waypoints, this way we "draw" lines. Maybe You can not undestand this the first time you read, but is very easy. When you place a flight, FMB writes the coordinates of the way points. Placing the waypoints and "drawing" a line with a plane will make 2 things: tell us where the coordinates are and show us where the objects will be placed.

Lets see a working example, next image shows several waypoints where I like to place some planes. I use B-17 aircraft to "draw" those waypoints:

Next image shows how aircrafts are placed:

Compare last 2 images, look the direction of waypoints and how planes are placed. You will notice that planes always are placed with nose pointing to the right of the lines. When I say "right" I mean: imagine you stand up on WP0 and look on direction to WP1, the planes will be looking to the "right" of that direction.

For easy understand I combine those 2 images into a single one and drawed a big red arrow of the "right" direction. When you make templates you will not see the planes, and you have to create this image in your mind:

This way place templates works. You just use a mission to place flights, you never place the objects. Trust that later the generator will use that file with flight waypoints to read the coordinates and place the objects as you wish. You can use any plane to "draw" places, it does not matters the army or the type of the plane. Generator will place red static planes if later that base is soviet, or place blue static planes if the base is on german side. Be sure to understand all to this point before read next tips.

To avoid using many flyiable planes and to speed up template creation, we use same flight to make several places. How? well, generator will look into pairs of waypoints because we know a line is defined by 2 points. So, when you create you places you can keep adding points using same flight like show next image:

Those waypoints indicates 3 places: place planes from WP0 to WP1, place planes from WP2 to WP3, place planes from WP4 to WP5. When you "draw" those waypoints you have to keep pairs of waypoints. I say to myself when I make those templates:

placing WP0 I think: planes from here
placing WP1 I think: to here
placing WP2 I think: planes from here
placing WP3 I think: to here
placing WP4 I think: planes from here
placing WP5 I think: to here

As you can see, you are free to select srating point between places. In this example, the lines between WP1 and WP2 will not define a place, its just a relocating line and you have to ignore it. Same goes for line btween WP3 and WP4.

Really is is very simple after you try several times. Next image shows how planes are located using the places showed in previous image:

And next image is the combination of both of them, showing what you have to "imagine" at the moment you "darw" your templates. Remember, it is VERY important you use pairs or waypoints, because they define the lines. Just remember to use "from here" - "to here" nemotechnic.






3. Creating templates

To create a template for a map mean you have to create several files. You can make by hand each of them, but this will usually introduce several mistakes, because lots of corrdinates has to be written and a mistake on one coordinate will produce incorrect missions. So, I provide some tools to create templates in a semi-automatic way.

We create templates in several stages (or steps), because some stages needs data from previous stages. For example, the Geo_obj.data contains four (4) main gruopg of data. One of those gropus are the sector definitions, and to write the sectors definition you need to have the tank waypoints. And tank waypoints will be made using a template created after finishing "stage 1", where we define airfields and park places. Dont worry now about this, the only important thing now is to know that there are several "stages".

This semi-automatic template creation uses perl scripts. So you need to have perl installed. If you dont have perl, it will not be possible to make templates as I describe in this manual.

The process of template creation need you to work with FMB, and time to time run some scripts, so to make things easy, create a folder under FB/missions. I usually name the forlder with the name of the map templates im building, do for example to make normandie1 templates I have a folder: "D:\Ubi Soft\IL-2 Sturmovik Forgotten Battles\Missions\normandie1" where I place all the perl scrips and where I will hold template files. Once thy are finished I rename them, adding a 2 or 3 letter code before each file to easy recgnition.

copy all the scrips provided with this manual into a folder you like.



3.1 First Stage

Lets start building templates for Normandie1 map. As described before I place all scripts into a new folder called normandie. Then I start IL2FB, and load map "normandie1". The first thing to do is to place a object "airfield champfire" on the most right-top corner, better just a bit outside last sector number/letter (if you can, if not place as far you can on top-right of map). This will be used by scripts to determine the limits of map. Save this file as "initial.mis". This file now will provide important data: the limits of the map and the map name.

Abobe image shows the "airfield champfire" localization for normandie1 map. This map has at top-right coordinates named O-10, so the "airfield champfire" is located at P-11 sector. Of course, P-11 cordinates are not displayed on FMB. This top right square will have different coordinates on different maps.

This new file initial.mis will hold the data of airfields, besides other information I told. For each airfield on map we like to use for campaign, we need to colect several information: The coordinates of the location, the 2 headings for take off and landing, the orientation of runway, the "places" where we will like to put parked planes and the place for a static plane to be used a airfield army identification.

All this data is colected by adding 3 objects to each airfiels:

  1. The first object will be a static JU-52, place it somewhere you like.
  2. The second object is a flight (any plane, I use B-17) with 2 way points: way point 0 is a takeoff and waypoint 1 is a landing. This flight will provide information on coordinates for taking off and landing places, and allso will provide "center location" of an airfield, and runway headings.
  3. The last object is a flight, a different one (any plane, but I use B17 again) that will hold the parking places for aircrafts, as described in section "Places templates". You can add up to 9 places, that is up to 18 waypoints. Remember the orientation to the "right" and the nemothecnic "from_here to here".

When you have all this 3 object placed, you select other airfield and repeat process adding a new JU-52, a B17 with 2 waypoints (one take-off other landing), and other B17 to "draw" the parking places. Next image shows a screen shot with those 3 objects for an airfield.

Time to time you will like to check how planes are placed, if the orientation is correct, if you have correct pairs of WP for the park places, and so on. To see a preview of your work, run the script "view_bases.pl". This script will read your "initial.mis" file and create a new file called "preview_bases.mis". Load this file into FMB and check how planes are placed. This script will print an error if you have even (not pairs) amount of waypoints. The preview will only display german planes, like if the base is under german control, later the generator will place greman or soviet planes.

Remember to keep working on "initial.mis". It is a common mistake to load the preview, and then keep adding Ju-52, park places and toff/land WP to the preview mission. The preview mission is just that, a mission to look how yor waypoints will be read by generator. The important file is "initial.mis". After you inspect the preview mission remmenber to load back "initial.mis" to keep working on.

Next picture is how you see a base in preview_base.mis. Notice that the static JU-52 will not be showed. The preview mission only display the "aircrafts park places".

This is how looks an error message when you try to make a preview and the waypoints amount are not pairs. When this happens you have to load "initial.mis" on FMB and search where is located the problem. A recomendation is to do a preview every time you finish a base. So if there is a problem with pairs WP, the problem will be always in the last base you was working. Aditionally, error will display what line number is the one making even waypoints, so if you like you can manual delete that line, by editing "initial.mis" in a text editor. (not recomended, better look the WP in FMB).

This is all we need to finish first stage, a "initial.mis" with a champfire, and each base with 3 objects. Once you are used to make this bases, each base will not take more than a couple of minutes. The way I work in doing first adding the filedchamp, the I add all JU-52 to all bases I like to use, so they are a visual aid to find bases. Later I add all take-off and landing waypoints using a B-17 for each base. This way, when I look all the map, I have to see "something blue" (the ju-52) and "something red" (the b17 waypoints). Finally I add the parking places to each base, doing some previews time to time.

If you look into the initial.mis I provide as example you will see frontline markers. You do not need them yet. Is something we will add in next stages, explained later.

Now we are ready to run 1_stage.pl script. (run in a cmd window: perl -w 1_stage.pl). This will create 5 files:

  1. blue_obj.mis: One JU-52 per base, on places indicated by the JU-52. This file is ready to use.
  2. red_obj.mis: One Li-2 per base, on places indicated by the JU-52. This file is ready to use.
  3. tank_wp.mis: A initial template for tanks, we have to work on this on next stage.
  4. city.mis: A empty template where we will add cityes to attack and targets on next stage.
  5. geo_obj.data: is a partial content of this file, where now hold all airfields descriptions, park places, headings, damage, etc etc.

If you are curious, you can look into geo_obj.data just created, there you can see several lines with the onformation of each airfield. For example this are the lines representing the airfiled is showded on above example images . That information is: airfield general information (first line), Heading coordinates (AF06:Hx), followed by several lines with parking places coordinates and angle for plane placements (AF06:Px)

             AF06,aerodromo--D03,38788.61,29109.76,2,-D,03,2,0:2
             AF06:H1,38048.61,28764.76,
             AF06:H2,39530.43,29455.75,
             AF06:P1,38451.23,29622.01,38526.13,29846.98,378,
             AF06:P2,38509.59,29613.09,38578.11,29816.26,378,
             AF06:P3,39102.59,29655.61,39159.29,29544.57,152,
             AF06:P4,39185.28,29124.04,38982.10,29024.82,243,
             AF06:P5,38386.74,29213.82,38443.44,29383.92,378,
             AF06:P6,38625.36,29535.12,38665.52,29639.07,381,
             #--- End AF06 (aerodromo--D03)

Don worry if you dont understand this information, you dont need to understand it to keep woring on templates.



3.2 Second Stage

This stage is the one it takes more time, because we have to work on the tanks waypoints template and the city template. I will divide into 2 parts "A and B" for each one of them.

A- Tank wp template

The tank template holds "points" where generator will later place a defense champ (some static objects, AAA, and static tanks) or a group of moving tanks (the attacking group). Each sector needs at least 2 "points" so it will be possible to place both goups, one in each point. More points places are welcome, so generator later can pick diferent combinations of them, making missions less repetitive. The amount of "points" recomended for each sector is up to 5, and no less than 3 to make some variations on selection.

There are some sectors where tanks can not move. For example sea, lagoons, sectors covered by forest, etc. On this sectors we will place 0 points, that is, there will be no starting points, and sectors become un-attacable.

Go to FMB and load the mission "tank_wp.mis" created on first stage. You will see something like this (showed only a small part):

You can see on all sectors 5 tanks, one on each corner and one more in sector center. This file is created in this way for speed edit. Is more easy to delete and move objects alrready lpaced on mission. Each of those static tanks you see are the "points". Like on paking places we use flight for later place objects, here we use a static tank to indicate the coordinates of where a camp, or a group of moving tanks will be placed. In that image I named sectors with numbers 1 to 4, just for easy reference on this manual.

Previous image shows 4 sectors. The very first thing to do is delete all 5 points from unattacable sectors(sea, lagoons and only forest sectors). Later, you have to relocate points based on simple rules. The points (actually tanks on this template) needs to be not very close. All of them has to be inside the sector, no river, lagoon, city or forest has to intercept their path. If you cant place all 5 of them, try deleting some of them for easy find correct places. Next image shows how edited those points. Sector named 1 is un-attacable (sea) and deleted all 5 points. Sector named 2 has 4 points, sector named 3 has 5 points and sector named 4 has only 3 points:

As you can see, all points meet requeriments. Now I will show a mage with incorrect point placement. I will add some lines to conect them, and place a red dot over green lines to show a problem. Those lines have to be done in your mind when you are moving points.

Sector named as 1 has one point in other side of river. Sector named 2 has poins incorrect placed because the run into a city. Sector named 3 are correct, but two points are too close, so is recomended to move one of them a bit away, like the red line show. Sector named 4 has two paths runing into forest. On next image I show how this points are corrected:

You have to check sector by sector point placement. Make sure that sectors has at least 2 waypoints, but a minimum of 3 is recomended. Also be sure to not place points outside sector. For work more confortable, zoom in and out so the grid lines only display 10x10 squares. It is also recomndable for areas with hils and mountains to look exacltly the place you are placing a point, so you avoid to place them on hill precipices.

This template takes some time, when you are used to work with it, you can make several sectors in a minute. The more important thing is to make unatacable the sectors that cant hold tanks points. The other sectors can be edited or corrected later (problem with hills, or a point on other side of river, etc..)


B- City template

Now we start with city template. This template will hold the cityes that will like to include as targets. Only one city per sector. City cant be closer to 10km each other. Load city.mis into FMB. The first thing to do is to place a "observation ballon 90m" object over each city we like to include. This way we easy check that we dont place 2 city too close. Next image shows how the template looks after adding several cityes. The lines are drawed only to show the distance you have check

After you finish, you have to zoom close to each city and add several "champfires" objects. Each champfire will be an "attacable zone", add at least one and up to 9 zones for each city. All places marked with a fire (zones) has to be close to the city, never place them in a distance bigger than 5 km. Also, each target place zone needs to be 1 km or more seperated from any other zone. So, you leave room to place objects and not overlap them. Next image shows a city with 3 zones (3 fires), all of them inside 5km limit, and all of them seperated at least 1km from other fires.

Place more zones on more important cityes (5 or 6 is ok) and less zones on small towns (2 or 3 is ok). Once you finish placing fire zone markers, you have to place objects on each of them. Next images shows one zone with objects and remaining others still empty.

The way to place objects is very simmilar to the method described as "place templates". In fact, is the same with a few more options. You have to draw pair of waypoints. Those pair of waypoints indicates the line where objects will be placed. But now we have a extra fearture. Using the altitude of the wp we can indicate different objects types. Think like the waypoints is a pencil, and the altitude is the pencil type. So, with different altitudes we can "draw" diferent objects.