Adaptive map guide (updated 2021)

This guide will take you through the steps to turn a standard skirmish map in to an adaptive map, or how to set one up from the start, the method is the same for both apart from the first step, where renaming won't be necessary because you will name it correctly to begin with, your map name must start with Adaptive , For ease of identifying in the vault and to honour the author of the script, failure to do this will lead to your map being hidden by the vault mods.

Change your map name

In my example my map is called Test Map, this will need to be changed to Adaptive Test Map here,

alt text
First make a normal save this can be used as a back up, Then you will need to save your map using save as, Then right click in the files box and create a new folder and name it;
Adaptive test map
Then select the folder you have just created and click select folder

alt text

when the editor saves, it will add the correct file path so it will look like this -- Adaptive_Test_Map.v0001 --

Creating the lua files needed

Now switch to the markers tab and then to the adaptive tab,

alt text

And click create table file, A pop up will appear asking to replace the script.lua click yes to this, if you check your map folder you should have all these files

Image

Setting up your options

Assigning mex and hydro to player spawn

By doing this when a player in not in that slot their resources wont spawn on the map,
First make sure your army spawn id's are set up correctly (odds vs evens),

alt text

Then select the adaptive tab and select all the resource markers you want to add to that player, Then click the corresponding Army and repeat for all players,

alt text

Lines will appear showing you have done it correctly, If this is the only thing you want your adaptive map to do you can stop here, Read on if you want to explore the other options available.

Assigning extra core mex

In this example I want to be able to choose between 4 or 6 core mex, so I will add 2 extra mex markers per player and select them, then assign them to a player and tag them as core mexes,

alt text

The untagged ones will always spawn with the player, But the tagged ones will need to be selected from the options in the game lobby, to make them appear in the options when you host a game you need to edit the options.lua, I prefer to use notepad++ (but regular notepad works to), find this section of code and move it above the comment line that states
-- it should be above this line to use them --

{
    default = 1,
    label = "<LOC adaptive_core_mex_label> Core Mexes",
    help = "<LOC adaptive_core_mex_2_help> Spawn 4 or 5 core mexes.",
    key = 'core_mexes',
    pref = 'core_mexes',
    values = {
      -- there are no additional translations for this option
        { text = "4", help = "<LOC adaptive_core_mex_key_4> Spawn 4 core mexes.", key = 1, },
        { text = "5", help = "<LOC adaptive_core_mex_key_5> Spawn 5 core mexes.", key = 2, },
    },
},

In my example I would now need to change a couple of numbers and remove some text for it to show in the options with the right number of mex, Green box's change from 5 to 6, And yellow boxes need to be deleted or the game will default to the text that it's referencing there,

alt text

These should be changed to match your map if necessary, And can be changed on any of the options

alt text
Label and help,

alt text
Text and help in the values,

This process is the same for all options that are either on or off (Extra hydros, Extra mexes, Extra base mexes) although you don't have to have them linked to player, if you don't want them to be dependent on a player

To change which option is the default option you will need to change the number after
-- Default = X -- to match the key number -- key = X -- then you need to open script.lua and find this line (Line 23)

local core_mexes = ScenarioInfo.Options.core_mexes or 1

and change the number to match the default number you chose in the options.lua,
It is the same process for setting all defaults so remember this process.

Assigning expansion mexes

In this example we will add expansion mexes so you will be able to choose between 4 options;
option key=1 : removes a+b+c
option key=2 : spawn a, removes b+c
option key=3 : spawn a+b, removes c
option key=4 : spawn a+b+c

Add the mexes you want to be your expansion mexes,then open the adaptive tab and tag them like this,

alt text

Red is 1, Green is 2, Yellow is 3, And tag them all to a player if you want them player dependent, Repeat for all players and mex you want assigned, Now back to the options.lua and find this, and move it above the line

7e3f6488-e838-4a24-b9e6-2ab4fe65369c-image.png

In this instance all the text, help and labels are correct for what I am doing but if I needed to change anything it would be the same as above, this process will work for all options that have 4 choices (Middle mexes, Side mexes and so on)

Optional civilian defences

In this example we will create some defences between our players that you can choose if there are no defences, T1, T2, T3 or wreckage of any of the tech levels, for this one we'll start by moving the options above the line in options.lua look for this

alt text

Now go back to editor and switch to the unit tab and groups tab, Then create 3 groups in ARMY_17 named;
Optional_Civilian_Defenses_2
Optional_Civilian_Defenses_3
Optional_Civilian_Defenses_4

alt text

Then with Optional_Civilian_Defenses_2 group selected switch to the units tab then click on find unit which will open the unit browser then pick your T1 defences and place them, Then select the next group Optional_Civilian_Defenses_3, And repeat the last step but this time with T2 defences, And then repeat with next group for T3, You will also need to place a radar and power for some defences to work, You can place mobile units down but they will be Dumb though they won't move at all, And only attack if you get in range, The process is similar if you just want civilian bases, But you need to use the option labelled
-- Civilian Base -- and you only need one group named;
Optional_Civilian_Base_2
Make sure you change the text and help lines in the options.lua to match your map

Crazy rush

This option will add a crazy rush mex to your players spawn (for the uninitiated crazy rush is where you place a mex down and the 4 spots around it turn into new mexes), This one is easy, Open adaptive tab and select one of the start mex assigned to a player and tag it as Crazyrush One Mexes that's it, The option for this should already be above the line in the options.lua

Expanding map

This will allow you to define a start area, And then have it expand after either, A set time has elapsed or 80%/90% of mex have been built or if a player spawns in the expanded area, In this example we will add 2 players and place them in the expansion area, First we need to set up our areas, Switch to the map and areas tab and and create a new area, Name it AREA_4

alt text

Choose the size you want your start area to be here (boxes match the arrows)

alt text

In my example i will be adding players you can skip this part if its not relevant*, To add players place a blank marker and rename it to the next numerical army then switch to the armies tab and add armies, Then i will move the markers into the expansion area and add their start mex and tag them in the adaptive tab as before,

*Now we need to open options.lua and move the expansion options above the line and edit the help line so its relevant

alt text

If you want to change the default you need to change it here in the script.lua for this option

alt text

Next we need to open script.lua and find this and remove the -- from the highlighted line

alt text

Then scroll down to the expansion part and change these from AREA_1 to AREA_4

alt text

so that the options for 80% or 90% mex built are only looking at the start area not the whole expanded map area, The next part is for players added in the expansion you are done if this doesn't apply to your map, Now find this part and delete the red squares and change the blue square to the army numbers that are in the expansion and you are done.

alt text

Seraphim jamming crystal

this will add a jamming crystal to your map which will create false radar signals, To do this open the groups tab and create a new group in ARMY_17 and name it;
Jamming

alt text

then switch to the units tab and place a seraphim jamming crystal,

alt text

Then open options.lua and move the jamming part above the line and adjust the default if you want to (don't forget to change the default in script.lua to match)

Here's a link to Cookienoobs video tutorial https://www.youtube.com/watch?v=VVxEhCuc53g&

Vault Admin / Creative Team / Map Guru

Shouldn't the spawns 4 and 6 be swapped in your example to be proper odd vs even?

I suppose to maintain rotational symmetry yes but seeing as it's my personal version and I preferred diagonal symmetry I did it that way, probably not the best example tho
--- edit I have updated the guide

Vault Admin / Creative Team / Map Guru

Madmax, in an attempt to reach out to you to discuss something privately, I did a search and stumbled upon this map guide......I just want say its very helpful and informative. I have learned alot of good tips reading thru this......so thank you. Do you have any more guides that go into more details about importing and exporting stratums in the layer section and what benefits they offer?

Also do have any guides that go a bit more into texturing tips and masking?

Madmax, in an attempt to reach out to you to discuss something privately, I did a search and stumbled upon this map guide......I just want say its very helpful and informative. I have learned alot of good tips reading thru this......so thank you. Do you have any more guides that go into more details about importing and exporting stratums in the layer section and what benefits they offer?

Also do have any guides that go a bit more into texturing tips and masking?

@oncehandsome I've mentioned this a few times already I believe, but if you join the FAF discord mapping channels, you'll find a specific channel that has a list of a lot of guides and material for mapping.

Additionally, a lot of mappers hang out there and are happy to help you with questions. Good luck.

"Design is an iterative process. The required number of iterations is one more than the number you have currently done. This is true at any point in time."

See all my projects:

Index thanks i appreciate the response........Isnt Discord a chat program. Sorry not too familar with it but i hear it mentioned all the time. I was hoping to minimize the number of additional apps running in my system tray (too many already between steam, epic, razer, logitech, etc etc) I was just hoping to read thru some more advanced guides here if possible....thnx

@oncehandsome

Discord is a chatprogram, yes. You can use it to chat and (video) call with other people individually, or you can join servers hosted by specific communities. I use it to videocall with IRL friends, as well as with people from my FAF clan when we play together. FAF itself has a dedicated server where a lot of people that play FAF hang out, and it also serves as a general information hub.

Don't worry about minimizing apps running in the background. Unless your PC is more than 15 years old or really, really, shitty, you will not notice the difference. For reference, my PC is coming up on its 10 year anniversary, and while I am certainly starting to notice it being not up to par for some of the mapping work that I do, discord has never been an issue.

Alternatively, you can close the program when you're done chatting or looking through the mapping documentation, of course. No system drain if you don't keep the software running.

"Design is an iterative process. The required number of iterations is one more than the number you have currently done. This is true at any point in time."

See all my projects: