Overview
I will write about the process of making your own AI Faction what I know myself, mostly from personal experience and experiments.
Basic mod structure
The first thing you will need is your Faction’s ships and buildings designs. It would be better if you will plan how they will be divided into tiers beforehand.
To make a mod you create a folder in your user’s AirshipsGame directory mod subdirectory (for me it is D:Users*username*AppDataRoamingAirshipsGamemods). Name it whatever you want, it is better if it will represent your mod’s ID and content.
In that folder of your mod there should be…
1) “info.json” file with descriptions, for example:
2) “logo.png” – that will be your mod’s logo, recomended resolution is 512*512px.
3) Directories for your designs, you can find them in your user’s AirshipsGame directory: “buildings“, “landships“, “ships“. You include only the ones used in your Faction and it may be better to rename them to easily organize and type in your .json structure.
4) “ConstructionStrategy” directory, containing “strategies.json” files with your Faction’s Construction Strategies, the file(s) itself may be named any way, “h_strategies.json“, for example.
You probably already have your designs. If not, just create them ingame. I recommend, if you will make multiple ships for every tier, making them all (or almost all, with some requiring more tech) available with one tech simultaneously. That will help your Faction to build more than one design at a time (with the way the game works now, it is not so easy to prevent that).
Maybe that Tech Tree will help you:
[link]
Construction Strategy
When you have your designs in the corresponding subfolders, you can start making your Faction’s Construction Strategies, “strategies.json” containing the list of factons, you can find the default ones in “…SteamsteamappscommonAirships Conquer the SkiesdataConstructionStrategy” folder.
Here is an example of some “NewFactionName” Faction:
“name” – just name your Faction whatever you want.
“charges” – charges (icon/heraldry) to be used by your Faction, I am just leaving it blank (no ‘“charges”: [ ],‘ at all). You can find the list of charges at “…Airships Conquer the SkiesdataChargecharges.json“.
“shipTiers” – that is your ship building priority. The higher the better. AI will prioritize building ships from the first line, then from the second, then it will build ships from the last list if it will be unable (no required Tech) to build more advanced ones. What I find very tricky is that AI seems to be checking the designs themselves, so it will consider two ships with different names being one ship if their designs are the same. So it is difficult to build ship from the tier below together with the next tier ships. For AI to use multiple designs at the same time they should be unique for every tier. And you can not repeat one design on multiple tiers, because AI will see it as high-tier ship and skip the first tier at all, building only one ship from the second. That is strange and seems pointless to me that the game sees it like that, but that is the case anyway. AI tends to prioritize only one ship above all others, if you are not careful enough. You should prevent the scenario when on a tier one ship is available before all others.
“shipUpgradeSequences” – AI can upgrade ships in that sequence. As far as I get it, it tries to Upgrade before building something from scratch.
Same with landships and buildings.
Designs are typed without “.json” file extension, so “ShipOneLvl2” will refer to “ShipOneLvl2.json” file in “ships” folder of your mod.
“techs” – the order in which AI will do researching. Some first technologies will be available for it from the beginning. You can find the list of techs at “…Airships Conquer the SkiesdataTechtech.json“:
It seems that AI does not care about the Tech Tree itself, it can research any Tech, skipping required for that Techs. Maybe it can even research both Techs from one group, I did not test it.
You can add multiple Factions in one “strategies.json” file, but do not forget to separate them with comma (after “}”).
You can make a simple Faction with one tier (all ships on one tier) or one ship Upgrade Sequence designs (one ship at a tier), if it is problematic to organize working tiers.
Use examples
The easiest thing may be to download some Faction mod as example and do the things similarly. You can use my Faction mod for that:
[link]
You can find the default Factions in “…SteamsteamappscommonAirships Conquer the SkiesdataConstructionStrategy” folder. By the way, you may want to move “strategies.json” from there when you will test your Faction, because in other case you will have to deal with the low probability of your Faction appearing.
Best regards.