Mapping
GUIDE

File Structure & Prerequisites [1]

What are all the components of a map-file for BAR

MAPPING QUICK LINKS

Commands used in this guide

No items found.

Here you will find the complete list of things you will need to design a map and make it functional.

Intro & Structure

How is a BAR map made?

Well, for starters, a BAR-certified map is what we want, and to get to that level, a new map consists of many different parts that need to work well together. There is quite some tweaking involved to get all of them working. Generally there are 4 different things needed to start:

1. A Photo-editor like Photoshop or Gimp
2. Mapping Software: World Machine
3. A text editor to do some code editing
4. A set of additional tools to compile and edit/finetune your map

List of tools and useful links

Structure

A typical map consists of 3 components that are combined in your final mapname.sd7 file.

  1. A compiled set of 2 mapfiles, the mapname.smf and mapname.smt
  2. A custom set of additional map textures like normalmap, specularmap, splatmap, and more.
  3. The mapname.sd7, which is a zipped folder that contains all kinds of extra's and the important mapinfo.lua

1. Basic map assets

To compile the basics of a map you need a minimum of 3 maps. The all have unique and specific formats.
Some of these maps can/will be made manually with a photo-editor.
Though you can also generate/make these within World Machine.

1.1 Height

The heightmap is a 16 bit PNG file

The dimensions are linked to your final map size.
A 20x10 map has a 1281 x 641 px heightmap.
Calculate: 64 x [yourmap size] + 1

1.2 Metal

The metalmap is a 8-bit RGB BMP

Full RED (255,0,0) is max metal. Preferably use a sharp pixel pen with the exact color-value you want with a 4px radius dots (no anti-aliasing/smoothing). Simply paint where you want your metal to be.
A 20x10 map has a 640 x 320 px (1/4 or 25% of the heightmap).
Calculate: 16 x [yourmap size]

1.3 Texture (or Diffuse)

The texture is 8-bit RGB BMP

With the heightmap alone you can already render the map texture from World Machine.
A 20x10 map has a 10240 x 5120 px texture.
Calculate: 512 x [yourmap size]

1.4 Type

The optional typemap is a 8-bit RGB BMP

This map is optional, but often nice to have. Shades of grey/white are used to link these to specific types of terrain. Usually a typemap contains at least 2 types for basic terrain types like: flat ground, hard/rock/cliffs. But you can add things like sand, snow, muddy, ice, etc.
A 20x10 map has a 640 x 320 px (1/4 or 25% of the heightmap). Values are linked/defined in mapinfo.lua.
Calculate: 16 x [yourmap size]

1.5 Minimap

The minimap can be auto-generated during compiling, but you can also set a manual one.
The minimap is a 8-bit RGB BMP, though in yourmap.sd7 (the final file) you use .PNG and .DDS
The minimap always is 1024x1024 px

2. Additional Assets

2.1 Normalmap

The normalmap is in 8-bit RGB as DDS

Important for extra details & quality. You want to use the highest possible resolution, preferably always 8K.
A 20x10 map has a 10240 x 5120 px normalmap (1:1 with the texture). For smaller maps below 12x12 you could even go double resolution (2:1) for the normalmap.
Calculate: 512 x [yourmap size]

2.2 Specularmap

The Specularmap is half size in 8-bit RGBA as DDS

This map is also important to give the map extra toning in both color and how much lighting it reflects.
This map can be half res, like 4K, but 8K is also fine.
A 20x10 map has at least a 5120 x 2560 px specularmap
Calculate: 256 x [yourmap size]

2.3 Grass

The Grassmap is a 8-bit RGB BMP or TGA

Shades of grey/white are used to set the density of the grass.
You can also paint grass live in the game, and export from there.
A 20x10 map has a 320 x 160 px (1/8or 12.5% of the heightmap).
Calculate: 16 x [yourmap size]

2.4 DNTS Splatmap

The Splatmap is usually 2048 px wide as RGBA in PNG or TGA

The most important map for high res/quality detail textures. It uses a 4 channel RGBA format. This can be PNG or TGA.
Always use width/height with the ^2, ideally at least 2048 px.
A 20x10 map has a 2048 x 1024 px splatmap

2.5 Four separate DNTS textures

These 4 custom DNTS textures are painted with the DNTS splatmap. There are lots of textures to be found in other maps, and the size/intensity can be tweaked in-game and in the mapinfo.lua.
Most DTNS textures are 512 x 512 or 1024 x 1024 px and in DDS, PNG or TGA format

2.6 Skybox

DDS Cubemap preferably with 2K resolution per side

This one is also important to get high quality toning/colors/reflections. There are various skyboxes available.
Skyboxes are special cubemaps in the DDS format.

2.7 Reflect map

This is optional, and rarely used, but on icy or (very) reflective materials this can work very well. You will need a very good/fitting skybox to get the most out of a Reflectmap. For most normal terrains you don't need this, the Specular map (2.2) will suffice.
Ask Beherith what dimensions/format is best

3. SD7 Map file

The last part is combining all the above maps into one big .SD7 file.

This is in fact just a zipped folder, which generally consists of these parts:

  • /Features (for map objects and their stats)
  • /mapconfig (for placement of all map objects)
  • /maphelper (needed to make it run)
  • /maps (contains all maps from part 1 & 2)
  • /objects3d (contains all models for all map objects)
  • /unittextures (contains all textures for all map objects)
  • mapinfo.lua (contains the full config/setting of the map)
  • mapoptions.lua (optional for custom preset-setting - not all used in current lobby)

Work in Progress

Part #2 Heightmaps & Basics on Rendering

We will explain as much as possible about heightmaps, World Machine, textures and how to get all that ready to compile.

Part #3 Additional Maps & Details Painting

We will explain how get the additional maps (normal maps, specular maps) in shape, what formats to use, and how the DNTS splatmap works, including DNTS painting in Springboard.

Part #4 Objects & Grass

We will explain how to place objects (features) and Grass in a map. This involves Springboard and the in-game Grass Editor. You also learn how to export/convert it to be ready to use in your .SD7 map file.

Part #5 Your Map Config file

wWe will explain how to config your mapinfo.lua and also how to test and do final tweaks and polish

Part #6 Ready?

We will explain how to make your map ready for release.

For our current most advanced/complete mapping tutorial, use ''Beheriths Mapping Guide''

Good Luck Commander!
(you will need it)

Units related to this guide

No items found.
No items found.