Empires Modding
Modding Guide
Getting Started
Empires saves user files in your Documents\My Games\FieldOfGloryEmpires folder, which will be referred to as your 'user' folder. In addition to saved games, logs, and options files, this is where user created mods are located. Editing files directly in the game install folder (ex C:\Program Files (x86)\Slitherine\Field of Glory Empires) is NOT recommended, doing so may prevent multiplayer games from working correctly and interfere with game updates.
Before you begin modding, you may wish to open the USER.TXT file in your user folder and the following line to enable additional debugging tools:
DEBUGMODE 1
Create a Scenario
Empires currently only support mods by the creation of a new, modified scenario. The quickest way to create a new scenario and get started modding is to copy an existing scenario. For example, to start with the grand campaign, browse to the Scenarios folder in your game install folder (ex. C:\Program Files (x86)\Slitherine\Field of Glory Empires\Scenarios). Copy the d310BCGrandCampaign folder into the SCENARIOS folder of your user folder (ex Documents\My Games\FieldOfGloryEmpires\SCENARIOS). Rename the pasted folder to something new (it is recommended the new folder name not contain spaces). You should also make sure this new folder and its contents are not Read-Only. Inside this folder, you should see a number of files:
MYSCENARIO │ SCENARIO.BSF │ TEXT1.TXT │ TEXT1_FRE.TXT │ TEXT1_GER.TXT | TEXT1_SPA.TXT │ SCENARIO.TXT │ ├───DATA │ │ SETUP.csv │ │ SETUP_FACTIONS.csv │ │ REGIONS.csv │ │ SETUP_GROUPS.csv │ └───SCRIPTS │ Events_Plugin.BSF
A good place to start would be to open TEXT1.TXT in a text editor. Here you can give your mod a unique name, description, and starting message. See Modding#Custom_Text for details on modifying string files in the Archon engine. TEXT1_FRE.TXT, TEXT1_GER.TXT, and TEXT1_SPA.TXT contain the translations of the strings in TEXT1.TXT. If you do not plan to translate your mod into other languages, you should just remove these three files and the strings entered in TEXT1.TXT will be used for all languages.
SCENARIO.BSF is another place you can make some quick edits to you scenario. Refer to Scripting for a description of the Archon scripting language. The InitScenario function near the beginning of this file sets up a number of parameters for your scenario, try changing gTurnInfos.dateFirstTurn to adjust the starting date for your mod.
If you start the game and select Scenarios, your modified scenario should now appear near the bottom of the list and be selectable for play.