Custom Maps

MCT mapping, whether your're planning a flight or managing Intel / Logistics, uses 'map tiles' - a popular and common approach to draw the map you see. As you move and zoom around, multiple tile images are seamlessly loaded and unloaded. These tile images come from a Tile Source - typically a Tile Server or a local collection such as MBTiles and can have a range of different styles / themes.

MCT allows you to customise and add your own Tile Sources - either by adding a Json configuration file for a Tile Server or by adding your own .mbtiles files. These tile sources can then be selected from any map view using the layer selection button in the upper right corner.



Adding Tile Servers
You can add your own Tile Servers to MCT by creating a Json configuration file in your Saved Games\MCT\CustomMapTiles folder. There are a few properties you need to include which are stated below. Start by inspecting one of the existing Tile Server configuration files and use this as a reference for building your own.
  • Name (Required) - Provide a suitable name; this will appear in the layer selection menu at the top right of the map
  • URL (Required) - The URL of the tile server; this will usually end with "/{z}/{y}/{x}" and provides the requested tile images
  • Params (Optional) - A list of Name & Value pairs to be passed to the map

Finding Tile Servers
MCT includes a small selection of popular Tile Servers and there are plenty more available by other providers. Many of these will require the use of an API key - these will usually be free for individual use and worth checking out.

To get started with finding and adding your own tiles sources, take a look at https://leafletjs.com/plugins.html#basemap-providers and https://leaflet-extras.github.io/leaflet-providers/preview/. While not all providers will be compatible, most will provide the required URL along with any additional map parameters / options it needs. Additionally, check out providers such as MapBox who offer free personal use services allowing you to build your own custom tile styles and host them with a Tile Server.


Tile Params
There are a number of options you can provide to customise / modify how the map tiles are displayed / loaded. When utilising a third-party service such as those mentioned abobe, you will usually be given the options required to utilise your tile source. A full list of supported options can be found at https://leafletjs.com/reference.html#tilelayer.

Note: When setting maximum Zoom values below 20, consider setting maxZoom to '20' and setting maxNativeZoom to your tile's maximum zoom value



Using MBTiles
Much like Tile Servers, MBTiles are a collection of tile images only these are wrapped into a single .mbtiles file and can be consumed 'offline'. You can add your own .mbtiles files for MCT to consume - to do this, MCT starts its own Tile Server, providing tiles from your .mbtiles file. By default, this is started automatically on port 3111 and you can both disable auto-start and change the port used in MCT Settings. These tiles can then be consumed by any other application by using the appropriate URL.

You will need to add your .mbtiles sources to the Saved Games\MCT\TileServer folder - once added, these will automatically appear in the map source list in the upper right corner.
Metadata
MCT will inspect the metadata table of your mbtiles file to determine the most appropriate map parameters such as minimum and maximum zoom levels, attribution etc. For a full list of possible metadata entries, take a look at the MBTiles specification.


Map Settings
You can manage your custom map additions by opening MCT Settings and selecting the "Map Tiles" tab. From here you can see the status of the Tile Server along with all additional tiles sources available to MCT.
Note that you cannot change the attributes for mbtiles sources as these are derrived from the metadata - you can see details about your mbtiles source, including the available metadata on the right.



Need Further Help
If you need any further help, join the discussion or open a ticket in the MCT Discord.