In this tutorial I will show you how you can give a region to another faction as well as making an emergent playable in the same process. First make a backup of your startpos.esf in the data/campaigns/main/ folder
Next you will need to download ESF Editor from our file catalog and open up your startpos.esf with it.
I will start with making a emergent faction playable because it will in the end have the same process that is gone through as you would with adding a region to any faction whether it was already in the game.
The first section we will be editing is known as the CAMPAIGN_PREOPEN_MAP_INFO as the name suggests this is what the game reads in when you are at the grand campaign start area so it can populate the menu with who can be played and what regions they own.
We first want to edit CAMPAIGN_PLAYERS_SETUP. Find the emergent faction you wish to play.
Under its CAMPAIGN_PLAYER_SETUP section you will see the faction's name and then three booleans. By setting the second boolean to True you will allow that faction to be chosen at the menu.
Next find your faction in FACTION_INFOS and set the last integer to 1 or if you plan to give your faction multiple regions, then just put the number of regions you plan to give. This step may not be completely necessary because I notice for the faction I stole the regions from they automatically updated to reflect correctly in the start game screen.
Next we have REGION_OWNERSHIPS_BY_THEATRE. Each subsection is for a specific theatre, India, America, Europe. So find the theater for your region and then find the specific region entry and change the faction name to the name of the Emergent faction you want to play.
Now we are moving on to the CAMPAIGN_ENV section. This defines the bulk of the campaign state at the start of the first turn.
Under CAMPAIGN_PLAYERS_SETUP you will do the same process as in the prior section where the second boolean needs to be set to True.
Next we will move to CAMPAIGN_MODEL/WORLD.
Under this section you will see a FACTION_ARRAY and a REGION_MANAGER. These are the two final areas we will be editing.
Firstly go into the FACTION_ARRAY and find the Faction you want to be emergent or the faction you want to give a region to.
When you have found him you will see a lot of data variables for the faction at its FACTION section level. Here is what some of them do:
faction_id - int
faction_db_name - uft16
faction_display_name - utf16
unknown - Boolean
unknown - Boolean
Is Major Faction? - Boolean
unknown - Binary Data
Official Religion - utf16
unknown - Boolean
capitol_region_id - Int
capitol_region_id - Int
unknown - Boolean
Is Emergent? - Boolean
unknown -Uint
unknown - Binary Data
unknown - int
unknown - int
Main AI mode - utf16 (FULL or MAINTAINANCE)
AI Personality - utf16
protector faction_id - int
For Emergent factions to be playable you need to set Is Emergent? to False. (sorry forgot this step )
So I suggest to write down the Faction ID# for your faction.
Next we will go into the REGION_MANAGER and you will need to find the entry for your Region which may take some time as there are 205 regions to find it through.
At the REGION section level you will see a large set of data for each region here is explained some of what they are:
region_db_name - utf16
region_id - int
(skip past 13 unknowns)
owner faction_id - uint
owner theater_id - uint
theater_name - utf16
main_rebels - uft16 (Can be any Faction or just a rebels type)
base rebels type - utf16 (This can only be a rebels type of faction)
coastal climate? - utf16
So first we want to take the faction_id of our faction and set the owner faction_id to this value.
If you are using an emergent faction we will also need to go back to our faction section and change the capitol_region_ids to point to this region.
Next we must proceed further into the region and edit parts of the REGION_SLOT_MANAGER and the SETTLEMENT sections.
Proceed as far in as you can for each element in REGION_SLOT_MANAGER to if you can reach a BUILDING section which inside will have who owns the building and also the gov_type. You must edit each building to have your faction's name and government type.
Furthermore for each REGION_SLOT you need to edit SEIGABLE_GARRISON_RESIDENCE/GARRISON_RESIDENCE. In there is a single Uint that holds the ID to the owner faction of this region. (These same things also get done for the region_slots inside of the Road and Fort Slots.
Also do the same thing under SETTLEMENT for the SEIGABLE_GARRISON_RESIDENCE/GARRISON_RESIDENCE.
If you followed all the steps correctly this region should now be properly owned by the faction you chose.
If you were unlocking a emergent faction please note that you can only play as that emergent faction because the AI definitions for the emergent probably are not there so other factions crash on load.
Update: How to decouple an enemy army from the settlement of a region they no longer own
Deleted. How to move or pass armies, read other tutorial.
Also for emergent faction if you want to get all your government people to generate you will need to capture a region and then instantly the game will generate a Faction Leader and ministers for your faction. (It is hard with some factions who cannot build stuff like Scotland, but with USA I tested this).
(by Уран-235)
Добавлено (08.02.2011, 22:12)
---------------------------------------------
У кого какие затруднения с переводом - пишите, помогу.