preview
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
preview [2019/10/02 16:01] – polymorphgames | preview [2020/04/22 12:46] – removed vjraymon | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Preview Modding Documentation for Foundation 1.4 ====== | ||
- | :!: Please do not upload mods for Foundation 1.4 to mod.io before the official release of those modding features, since it would make your mod visible to all players, and they won't be able to play it :!: | ||
- | |||
- | ===== How to Access 1.4 Preview ? ===== | ||
- | Contact developer on our [[https:// | ||
- | |||
- | ===== Generated Documentation ===== | ||
- | * [[preview: | ||
- | * [[preview: | ||
- | * [[api: | ||
- | |||
- | ===== New Features ===== | ||
- | * [[#Building part function|Building part functions are now assets, declared individually.]] | ||
- | * [[preview: | ||
- | * [[#Resource type list|A resource can now have multiple resource types]] | ||
- | * [[preview: | ||
- | |||
- | ===== Migration Notes ===== | ||
- | ==== 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 '' | ||
- | |||
- | Migration example: | ||
- | <file lua> | ||
- | mod: | ||
- | DataType = " | ||
- | ... | ||
- | |||
- | -- OLD | ||
- | -- ResourceType = " | ||
- | |||
- | -- NEW | ||
- | ResourceTypeList = { | ||
- | " | ||
- | " | ||
- | } | ||
- | |||
- | ... | ||
- | }) | ||
- | </ |