migration
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
migration [2019/08/01 15:37] – maxime | migration [2019/10/02 18:35] – maxime | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Migration Notes ====== | ====== Migration Notes ====== | ||
- | ===== Foundation | + | ===== Foundation |
+ | |||
+ | ==== 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 130: | ||
</ | </ | ||
- | ==== 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 88: | Line 158: | ||
{ | { | ||
ShortName = " | ShortName = " | ||
- | | + | |
{ DataType = " | { DataType = " | ||
{ DataType = " | { DataType = " | ||
Line 95: | Line 165: | ||
{ | { | ||
ShortName = " | ShortName = " | ||
- | | + | |
{ DataType = " | { DataType = " | ||
} | } | ||
Line 110: | Line 180: | ||
==== 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 200: | ||
==== createMod() function is simplified ==== | ==== createMod() function is simplified ==== | ||
+ | |||
Since the new '' | Since the new '' | ||
Line 136: | Line 208: | ||
==== 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