buildings
This is an old revision of the document!
Table of Contents
Buildings
Here is an exemple of how to declare a new fountain building.
Buildings are ensemble of building parts. Simple buildings have only one part.
Scripts
Declare the building:
myMod:register({ DataType = "BUILDING", Id = "FOUNTAIN", Name = "MY_MOD_FOUNTAIN", Description = "MY_MOD_FOUNTAIN", BuildingType = "DECORATION", BuildingPartList = { "FOUNTAIN_PART" }, --VillagerRequired = { Status = "NEWCOMER", Quantity = 9 } })
Declare the building part:
myMod:register({ DataType = "BUILDING_PART", Id = "FOUNTAIN_PART", Description = "", ConstructorData = { DataType = "DEFAULT_BUILDING_CONSTRUCTOR", CoreObjectPrefab = "PREFAB_FOUNTAIN" }, BuildingZone = { 5, 5 }, ConstructionVisual = "PREFAB_FOUNTAIN_CONSTRUCTION", Cost = { UpkeepCost = { { Resource = "GOLD", Quantity = 5 } }, RessourcesNeeded = { { Resource = "WOOD", Quantity = 5 }, { Resource = "STONE", Quantity = 10 } } } })
Data
TODO
Link Data to Script
TODO
myMod:registerAssetId("models/fountain.fbx/Prefab/Fountain", "PREFAB_FOUNTAIN") myMod:registerAssetId("models/fountain.fbx/Prefab/Fountain_Construction_Steps", "PREFAB_FOUNTAIN_CONSTRUCTION")
Text and Localization
TODO
Construction Steps
TODO
buildings.1534514457.txt.gz ยท Last modified: 2018/08/17 10:00 by polymorphgames