FANDOM


Automaps are what we call those nice minimaps that overlay onto the radar or the rest of the screen. To create one, follow these steps.

The image itself

  • Open up the .map in GtkRadiant and zoom is as far as you can while still being able to see the whole map.
  • Draw a 'square' brush around the map as close to the map as possible and write down the coordinates of the top-left corner. (Q in 1.4, J in 1.5)
  • Make a new brush at the bottom right corner to see the coordinates of that corner (GtkRadiant only shows the coords of the top-left corner of a brush), write them down, then delete that second brush.
  • Take a screenshot of the map and open it in your favorite graphics editor. Any editor works fine as long as it supports PNG and Transparency.
  • Crop the image to the size of the first, square brush you made then delete that brush in the map as it's no longer needed.

These are the important steps to get the image itself, now you can make that image nicer in the graphics editor if you want. If you decide to do so, here are the Standards the Team & CMP uses:

  • The color to be used is light blue (#009cff)
  • Major walls are 5px thick, things like stairs are made with thinner lines
  • The base opacity is 40% for the full map, 20% for the radar map
  • Areas lower than the base have a lower opacity, higher areas have a higher opacity

If you want to make a multilevel automap, create one image for each level, also write down the height of that level in map units from the center of the map (0,0,0). Save the file as a PNG.

The Shader

The official shader looks like this. Change the paths and names to fit your map.

The radar map:

gfx/automap/mb2_mygeeto1
    {
	nopicmip
	nomipmaps
    {
	clampmap gfx/automap/mb2_mygeeto1
	depthfunc equal
	blendfunc blend
	rgbGen identity
	alphaGen const 0.85
    }
}

The full map:

gfx/automap/mb2_mygeeto1full
    {
	nopicmip
	nomipmaps
    {
	map gfx/automap/mb2_mygeeto1full
	blendfunc blend
	rgbGen identity
	alphaGen const 0.85
    }
}

The .siege

Now to make the map actually show up you need to edit the .siege file of the map.

These lines are to be added below the missionname line.

radartopleft "x1, y1"
radarbottomright "x2, y2"
AutoMap
{
   AutoMap0
   {
       radargraphic "gfx/automap/mb2_dotf"
       radargraphicfull "gfx/automap/mb2_dotffull"
       height "0"
   }

   AutoMap1
   {
       radargraphic "gfx/automap/mb2_dotf_upper"
       radargraphicfull "gfx/automap/mb2_dotffull2"
       height "100"
   }
}

Explanation

 radartopleft "x1, y1"
 radarbottomright "x2, y2"
  • Here you replace x1, y1, x2, and y2 with the coordinates of the top-left respectively bottom-right corners. Example:
radartopleft "-2048, 3072"
radarbottomright "7168, -6144"
  • Note the space after the commas as well as the citation marks.
AutoMap
{
    AutoMap0
    {
        radargraphic "gfx/automap/mb2_dotf"
        radargraphicfull "gfx/automap/mb2_dotffull"
        height "0"
    }
  • This defines the first level in a multilevel automap or the only level in a one level automap.
  • radargraphic is the graphic displayed in the radar, this is the one with 20% base opacity.
  • radargraphicfull is the big graphic displayed on the screen, this is the one with 40% base opacity.
  • height is the height of this level, this is not needed for single-level automaps.
   AutoMap1
   {
       radargraphic "gfx/automap/mb2_dotf_upper"
       radargraphicfull "gfx/automap/mb2_dotffull2"
       height "100"
   }
  • Of you want a multilevel automap you can add more stages like this one.
  • Remember that you need to define the height value of these stages for them to work.
  • If you want you can add up to ten stages named AutoMap0 to AutoMap9.
}
  • Don't forget the closing bracket.