migration
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
migration [2019/08/02 13:07] – maxime | migration [2023/04/18 15:26] – polymorphgames | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Migration Notes ====== | ====== Migration Notes ====== | ||
- | ===== Foundation | + | ===== Foundation |
+ | |||
+ | * [[changelog: | ||
+ | |||
+ | ==== Gendered fields ==== | ||
+ | |||
+ | In 1.9.3, we merged the Nun and Monk profiles and statuses together to avoid duplication. This brought in the notion of " | ||
+ | |||
+ | **Note: '' | ||
+ | |||
+ | ==== Text fields ==== | ||
+ | |||
+ | * If empty in gender, will take '' | ||
+ | * If we want the '' | ||
+ | * If empty, will LOG and ERROR and take the '' | ||
+ | * To convert: | ||
+ | <file lua> | ||
+ | -- OLD WAY | ||
+ | AgentProfile = { | ||
+ | DataType = " | ||
+ | ProfileName = " | ||
+ | } | ||
+ | |||
+ | -- NEW WAY | ||
+ | AgentProfile = { | ||
+ | DataType = " | ||
+ | ProfileNameGendered = { | ||
+ | -- MASCULINE | ||
+ | " | ||
+ | -- FEMININE | ||
+ | " | ||
+ | -- GENERIC | ||
+ | " | ||
+ | } | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | ==== Character Setup ==== | ||
+ | |||
+ | * '' | ||
+ | * Animations: If NONE in gender, will take the one from '' | ||
+ | * Left/Right Hand: If '' | ||
+ | * Clothing: If '' | ||
+ | * Lists: | ||
+ | * What is in '' | ||
+ | * No more need to duplicate stuff in both genders | ||
+ | * To convert: | ||
+ | <file lua> | ||
+ | -- OLD WAY | ||
+ | CharacterSetup = { | ||
+ | DataType = " | ||
+ | WalkAnimation = " | ||
+ | IdleAnimation = " | ||
+ | FemaleHatList = { | ||
+ | " | ||
+ | }, | ||
+ | MaleHatList = { | ||
+ | " | ||
+ | } | ||
+ | } | ||
+ | |||
+ | -- NEW WAY | ||
+ | CharacterSetup = { | ||
+ | DataType = " | ||
+ | CharacterSetupDataGendered = { | ||
+ | -- MALE | ||
+ | { | ||
+ | DataType = " | ||
+ | HatList = { | ||
+ | " | ||
+ | } | ||
+ | }, | ||
+ | -- FEMALE | ||
+ | { | ||
+ | DataType = " | ||
+ | HatList = { | ||
+ | " | ||
+ | } | ||
+ | }, | ||
+ | -- ALL | ||
+ | { | ||
+ | DataType = " | ||
+ | WalkAnimation = " | ||
+ | IdleAnimation = " | ||
+ | -- Things put in lists here will be used by all genders | ||
+ | } | ||
+ | } | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | ==== Assets ==== | ||
+ | '' | ||
+ | * Gendered Fields: | ||
+ | * '' | ||
+ | * Need to do conversion manually | ||
+ | * '' | ||
+ | * Will automatically bring the value in '' | ||
+ | * You can set it up manually if you want | ||
+ | * '' | ||
+ | * Will automatically bring the value in '' | ||
+ | * You can set it up manually if you want | ||
+ | * '' | ||
+ | * Will automatically bring the value in '' | ||
+ | * You can set it up manually if you want | ||
+ | |||
+ | '' | ||
+ | * Gendered Fields: | ||
+ | * '' | ||
+ | * Need to do conversion manually | ||
+ | * '' | ||
+ | * Will automatically bring the value in '' | ||
+ | * You can set it up manually if you want | ||
+ | * '' | ||
+ | * Will automatically bring the value in '' | ||
+ | * You can set it up manually if you want | ||
+ | * '' | ||
+ | * Will automatically bring the value in '' | ||
+ | * You can set it up manually if you want | ||
+ | |||
+ | ==== Data ==== | ||
+ | '' | ||
+ | * Gendered Fields: | ||
+ | * '' | ||
+ | * If '' | ||
+ | * Can use same quota for each gender, it will only evaluate villagers of that gender for the quota. | ||
+ | * If quota from '' | ||
+ | |||
+ | ===== Foundation 1.9.0.7 ===== | ||
+ | |||
+ | * [[changelog: | ||
+ | |||
+ | ==== Sub-buildings and building functions ==== | ||
+ | |||
+ | Buildings can now have sub-buildings, | ||
+ | |||
+ | Sub-buildings are available as soon as their parent building is available by feeding the list above. But like building parts, they can be unlocked later on using the game action '' | ||
+ | |||
+ | An example of sub-buildings is given in the '' | ||
+ | |||
+ | ==== Building part list ==== | ||
+ | |||
+ | The building part set list ('' | ||
+ | |||
+ | ==== Unlockables ==== | ||
+ | |||
+ | With the whole rework of the progression system for 1.9, unlockables have been reworked to improve the way content is unlocked throughout the game. | ||
+ | |||
+ | Unlockable types ('' | ||
+ | |||
+ | Examples are given in the '' | ||
+ | |||
+ | <file lua> | ||
+ | -- OLD UNLOCKABLE | ||
+ | mod: | ||
+ | DataType = " | ||
+ | Id = " | ||
+ | Name = " | ||
+ | Description = " | ||
+ | EstateInfluenceCostList = { | ||
+ | { Estate = " | ||
+ | }, | ||
+ | RelatedProp = " | ||
+ | }) | ||
+ | |||
+ | -- NEW UNLOCKABLE | ||
+ | mod: | ||
+ | DataType = " | ||
+ | Id = " | ||
+ | Name = " | ||
+ | Description = " | ||
+ | DataCost = { | ||
+ | ResourceCollection = { | ||
+ | { Resource = " | ||
+ | } | ||
+ | }, | ||
+ | ActionList = { | ||
+ | { | ||
+ | DataType = " | ||
+ | BuildingProgressData = { | ||
+ | AssetBuildingList = { | ||
+ | " | ||
+ | }, | ||
+ | }, | ||
+ | }, | ||
+ | }, | ||
+ | }) | ||
+ | </ | ||
+ | |||
+ | ==== Estates and progression ==== | ||
+ | |||
+ | Progression, | ||
+ | |||
+ | Unlockables are now added directly to progress tiers ('' | ||
+ | |||
+ | <file lua> | ||
+ | -- OLD PROGRESSION | ||
+ | mithrilFactoryMod: | ||
+ | Id = " | ||
+ | EstateProgressList = { -- Add a new estate progress tier | ||
+ | Action = " | ||
+ | { | ||
+ | DataType = " | ||
+ | SplendorRequired = 5, | ||
+ | VillagerStatusRequired = { Status = " | ||
+ | UpgradeList = { | ||
+ | " | ||
+ | " | ||
+ | } | ||
+ | } | ||
+ | } | ||
+ | }) | ||
+ | |||
+ | -- NEW PROGRESS TIER | ||
+ | mithrilFactoryMod: | ||
+ | Id = " | ||
+ | UnlockableList = { | ||
+ | Action = " | ||
+ | " | ||
+ | " | ||
+ | }, | ||
+ | }) | ||
+ | </ | ||
+ | |||
+ | ==== Quests ==== | ||
+ | |||
+ | Quests have been greatly reworked, where instead of having a single '' | ||
+ | |||
+ | All of those are in the form of game conditions ('' | ||
+ | |||
+ | An example of quest is given in the '' | ||
+ | |||
+ | <file lua> | ||
+ | -- OLD QUEST | ||
+ | myMod: | ||
+ | DataType = " | ||
+ | Id = " | ||
+ | Name = " | ||
+ | Description = " | ||
+ | QuestFunction = { | ||
+ | DataType = " | ||
+ | Estate = " | ||
+ | ResourceListToDeliver = {{ Resource = " | ||
+ | DaysCount = 60 | ||
+ | }, | ||
+ | QuestRewardList = { | ||
+ | QuestRewardResources({{ Resource = " | ||
+ | } | ||
+ | }) | ||
+ | |||
+ | -- NEW QUEST | ||
+ | myMod: | ||
+ | DataType = " | ||
+ | Id = " | ||
+ | Name = " | ||
+ | Description = " | ||
+ | ObjectiveList = { | ||
+ | { | ||
+ | DataType = " | ||
+ | ResourceListToAccumulate = { | ||
+ | { Resource = " | ||
+ | }, | ||
+ | }, | ||
+ | { | ||
+ | DataType = " | ||
+ | IsNeedExecution = true, | ||
+ | ActionList = { | ||
+ | { | ||
+ | DataType = " | ||
+ | AmountToPay = { | ||
+ | { Resource = " | ||
+ | }, | ||
+ | IsDeliveryAction = true, | ||
+ | }, | ||
+ | }, | ||
+ | }, | ||
+ | }, | ||
+ | FailureConditionList = { | ||
+ | { | ||
+ | DataType = " | ||
+ | DaysToComplete = 30, | ||
+ | }, | ||
+ | }, | ||
+ | QuestSuccessActionList = { | ||
+ | { | ||
+ | DataType = " | ||
+ | BudgetCategory = " | ||
+ | ResourceCollection = { | ||
+ | { Resource = " | ||
+ | }, | ||
+ | }, | ||
+ | }, | ||
+ | QuestFailActionList = {}, | ||
+ | }) | ||
+ | </ | ||
+ | |||
+ | ==== Events ==== | ||
+ | |||
+ | Similarly to quests, events have been reworked to trigger a list of actions ('' | ||
+ | |||
+ | An example of event is given in the '' | ||
+ | |||
+ | ===== Foundation 1.8.0.0 ===== | ||
+ | |||
+ | * [[changelog: | ||
+ | |||
+ | ==== Resource bundles ==== | ||
+ | |||
+ | Building part costs have been changed to allow for building in steps, with the builder bringing a bundle of resources for each step. | ||
+ | |||
+ | To allow this, '' | ||
+ | |||
+ | The number of construction steps built for each bundle is proportional to a bundle' | ||
+ | |||
+ | ===== Foundation 1.7.1 ===== | ||
+ | |||
+ | * [[changelog: | ||
+ | |||
+ | ==== Texture loading ==== | ||
+ | |||
+ | Some '' | ||
+ | |||
+ | Therefore, we added a way to explicitly choose the type of an asset to load, when calling '' | ||
+ | |||
+ | This third parameter is currently only used for image assets. | ||
+ | |||
+ | <file lua> | ||
+ | mod: | ||
+ | mod: | ||
+ | mod: | ||
+ | </ | ||
+ | |||
+ | **Technical Info: | ||
+ | |||
+ | ===== Foundation 1.6.0.0522 ===== | ||
+ | |||
+ | ==== BUILDING and MONUMENT asset types ==== | ||
+ | |||
+ | Monuments have been reworked, and the '' | ||
+ | |||
+ | === Buildings === | ||
+ | |||
+ | A building' | ||
+ | |||
+ | <file lua> | ||
+ | local myBuilding = | ||
+ | { | ||
+ | DataType = " | ||
+ | ... | ||
+ | } | ||
+ | |||
+ | if (foundation.getGameVersion == nil or version.cmp(foundation.getGameVersion(), | ||
+ | myBuilding.BuildingPartSetList = { | ||
+ | { | ||
+ | Name = " | ||
+ | BuildingPartList = { " | ||
+ | } | ||
+ | } | ||
+ | else | ||
+ | myBuilding.AssetCoreBuildingPart = " | ||
+ | end | ||
+ | |||
+ | mod: | ||
+ | </ | ||
+ | |||
+ | === Monuments === | ||
+ | |||
+ | Monuments are now created around a single building part, placed before all the others. This part is the one selected just after selecting the monument in the building selection menu. This part has to be specified in the property '' | ||
+ | |||
+ | The core building part, if removed, will remove the whole monument. Like for the market, the core building part can be used for preview only, and be invisible once built by setting '' | ||
+ | |||
+ | <file lua> | ||
+ | local myMonument = { | ||
+ | ... | ||
+ | } | ||
+ | |||
+ | if (foundation.getGameVersion == nil or version.cmp(foundation.getGameVersion(), | ||
+ | myMonument.DataType = " | ||
+ | myMonument.BuildingPartSetList = { | ||
+ | { | ||
+ | Name = " | ||
+ | BuildingPartList = { " | ||
+ | } | ||
+ | else | ||
+ | myMonument.DataType = " | ||
+ | myMonument.AssetCoreBuildingPart = " | ||
+ | myMonument.BuildingPartSetList = { | ||
+ | { | ||
+ | Name = " | ||
+ | BuildingPartList = { " | ||
+ | } | ||
+ | end | ||
+ | |||
+ | mod: | ||
+ | </ | ||
+ | |||
+ | ==== Bridge mover ==== | ||
+ | |||
+ | The way bridges are placed has been modified, and requires a small mover change. A bridge mover ('' | ||
+ | |||
+ | Now, to have a functional bridge, you need instead to place a bridge mover on the start part and end part, and remove the mover of the core part. | ||
+ | |||
+ | Before: | ||
+ | * CorePart - '' | ||
+ | * StartPart - '' | ||
+ | * EndPart - '' | ||
+ | |||
+ | Now: | ||
+ | * CorePart - '' | ||
+ | * StartPart - '' | ||
+ | * EndPart - '' | ||
+ | |||
+ | ==== Slope constructor ==== | ||
+ | |||
+ | Improvements have been made to the bridge, and you now have to setup bridge end parts ('' | ||
+ | |||
+ | ==== Building zone and basement ==== | ||
+ | |||
+ | To improve the number of basement spawned, scalable building parts (with constructor '' | ||
+ | |||
+ | The [[api: | ||
+ | |||
+ | ===== Foundation 1.4.5.1009 ===== | ||
+ | |||
+ | ==== Building Part Function ==== | ||
+ | |||
+ | For assets from type '' | ||
+ | |||
+ | Migration example for the //Example 02// mod: | ||
+ | <file lua building_parts.lua> | ||
+ | mod: | ||
+ | DataType = " | ||
+ | ... | ||
+ | |||
+ | -- OLD | ||
+ | -- BuildingFunction = { | ||
+ | -- DataType = " | ||
+ | -- WorkerCapacity = 4, | ||
+ | -- RelatedJob = { Job = " | ||
+ | -- ResourceProduced = { | ||
+ | -- { Resource = " | ||
+ | -- } | ||
+ | -- }, | ||
+ | |||
+ | -- NEW | ||
+ | BuildingFunction = " | ||
+ | |||
+ | ... | ||
+ | }) | ||
+ | |||
+ | -- ALSO NEW | ||
+ | mod: | ||
+ | DataType = " | ||
+ | Id = " | ||
+ | WorkerCapacity = 4, | ||
+ | RelatedJob = { Job = " | ||
+ | ResourceProduced = { | ||
+ | { Resource = " | ||
+ | } | ||
+ | }) | ||
+ | </ | ||
+ | |||
+ | ==== Resource Type List ==== | ||
+ | The enumeration '' | ||
+ | |||
+ | Another change is that resource, markets, granaries and warehouses can now have multiple resource types. This, combined with new customizable resource types, will be useful to customize where resources can be stocked and sold. This means that the property '' | ||
+ | |||
+ | For example, before this change, the wine was a resource of type '' | ||
+ | |||
+ | The complete list of core resource types can be found: [[api: | ||
+ | |||
+ | Migration example: | ||
+ | <file lua> | ||
+ | mod: | ||
+ | DataType = " | ||
+ | ... | ||
+ | |||
+ | -- OLD | ||
+ | -- ResourceType = " | ||
+ | |||
+ | -- NEW | ||
+ | ResourceTypeList = { | ||
+ | " | ||
+ | " | ||
+ | } | ||
+ | |||
+ | ... | ||
+ | }) | ||
+ | </ | ||
+ | |||
+ | ===== Foundation 1.3.1.0802 ===== | ||
+ | |||
+ | ==== Building Part Sets ==== | ||
- | ==== Building part sets ==== | ||
In order to categorize the different parts of a building in the construction window, buildings and monuments now have building part sets. | In order to categorize the different parts of a building in the construction window, buildings and monuments now have building part sets. | ||
Line 61: | Line 551: | ||
</ | </ | ||
- | ==== Event choices | + | ==== Event Choices |
The event assets have been reworked to give the possiblity to have multiple actions triggered when a choice is made. The class '' | The event assets have been reworked to give the possiblity to have multiple actions triggered when a choice is made. The class '' | ||
Line 110: | Line 601: | ||
==== New mod.json ==== | ==== New mod.json ==== | ||
+ | |||
In order to only load mods when enabled, Foundation will now need a new description file for each mod. It will declare all the things Foundation would need to know about the mod without parsing the lua file. | In order to only load mods when enabled, Foundation will now need a new description file for each mod. It will declare all the things Foundation would need to know about the mod without parsing the lua file. | ||
Line 129: | Line 621: | ||
==== createMod() function is simplified ==== | ==== createMod() function is simplified ==== | ||
+ | |||
Since the new '' | Since the new '' | ||
Line 136: | Line 629: | ||
==== GENERAL_DATA asset type has been removed ==== | ==== GENERAL_DATA asset type has been removed ==== | ||
+ | |||
'' | '' | ||
However, modders can now partially override Foundation main balancing ('' | However, modders can now partially override Foundation main balancing ('' |
migration.txt · Last modified: 2023/09/05 11:21 by mathieu