User Tools

Site Tools


migration

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
migration [2020/05/22 14:10] maximemigration [2021/06/08 14:51] maxime
Line 5: Line 5:
 ==== BUILDING and MONUMENT asset types ==== ==== BUILDING and MONUMENT asset types ====
  
-Monuments have been reworked, and the ''MONUMENT'' type has been merged into ''[[preview:api:building|BUILDING]]''. This means there are a few changes to the way buildings and monuments are created.+Monuments have been reworked, and the ''MONUMENT'' type has been merged into ''[[api:building|BUILDING]]''. This means there are a few changes to the way buildings and monuments are created.
  
 === Buildings === === Buildings ===
  
-A building's only building part should be specified with the property ''[[preview:api:building#assetcorebuildingpart|AssetCoreBuildingPart]]'' instead of ''BuildingPartSetList''. For the game to not mistake a building for a monument, the property ''[[preview:api:building#buildingpartsetlist|BuildingPartSetList]]'' shoud be left empty.+A building's only building part should be specified with the property ''[[api:building#assetcorebuildingpart|AssetCoreBuildingPart]]'' instead of ''BuildingPartSetList''. For the game to not mistake a building for a monument, the property ''[[api:building#buildingpartsetlist|BuildingPartSetList]]'' shoud be left empty.
  
 <file lua> <file lua>
Line 34: Line 34:
 === Monuments === === 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 ''[[preview:api:building#assetcorebuildingpart|AssetCoreBuildingPart]]''. All other parts still are in ''[[preview:api:building#buildingpartsetlist|BuildingPartSetList]]''.+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 ''[[api:building#assetcorebuildingpart|AssetCoreBuildingPart]]''. All other parts still are in ''[[api:building#buildingpartsetlist|BuildingPartSetList]]''.
  
-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 ''[[preview:api:building_part#isvisiblewhenbuild|BUILDING_PART.IsVisibleWhenBuilt]]'' to ''false''.+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 ''[[api:building_part#isvisiblewhenbuild|BUILDING_PART.IsVisibleWhenBuilt]]'' to ''false''.
  
 <file lua> <file lua>
Line 44: Line 44:
  
 if (foundation.getGameVersion == nil or version.cmp(foundation.getGameVersion(), "1.6") < 0) then if (foundation.getGameVersion == nil or version.cmp(foundation.getGameVersion(), "1.6") < 0) then
-    myMonument.DataType = "BUILDING",+    myMonument.DataType = "BUILDING"
     myMonument.BuildingPartSetList = {     myMonument.BuildingPartSetList = {
     {     {
Line 51: Line 51:
     }     }
 else else
-    myMonument.DataType = "BUILDING", +    myMonument.DataType = "BUILDING" 
-    myMonument.AssetCoreBuildingPart = "CORE_BUILDING_PART",+    myMonument.AssetCoreBuildingPart = "CORE_BUILDING_PART"
     myMonument.BuildingPartSetList = {     myMonument.BuildingPartSetList = {
     {     {
Line 70: Line 70:
  
 Before: Before:
-  * CorePart - ''[[preview:api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]'' +  * CorePart - ''[[api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]'' 
-    * StartPart - ''[[preview:api:building_part_mover|BUILDING_PART_MOVER]]'' +    * StartPart - ''[[api:building_part_mover|BUILDING_PART_MOVER]]'' 
-    * EndPart - ''[[preview:api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]''+    * EndPart - ''[[api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]''
  
 Now: Now:
-  * CorePart - ''[[preview:api:building_part_mover|BUILDING_PART_MOVER]]'' +  * CorePart - ''[[api:building_part_mover|BUILDING_PART_MOVER]]'' 
-    * StartPart - ''[[preview:api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]'' +    * StartPart - ''[[api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]'' 
-    * EndPart - ''[[preview:api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]''+    * EndPart - ''[[api:building_part_mover_bridge|BUILDING_PART_MOVER_BRIDGE]]''
  
 ==== Slope constructor ==== ==== Slope constructor ====
  
-Improvements have been made to the bridge, and you now have to setup bridge end parts (''StartPart'' and ''EndPart'') with a ''[[preview:api:building_constructor_slope|BUILDING_CONSTRUCTOR_SLOPE]]''.+Improvements have been made to the bridge, and you now have to setup bridge end parts (''StartPart'' and ''EndPart'') with a ''[[api:building_constructor_slope|BUILDING_CONSTRUCTOR_SLOPE]]''.
  
 ==== Building zone and basement ==== ==== Building zone and basement ====
  
-To improve the number of basement spawned, scalable building parts (with constructor ''[[preview:api:building_constructor_scaler|BUILDING_CONSTRUCTOR_SCALER]]'' or ''[[preview:api:building_constructor_basement|BUILDING_CONSTRUCTOR_BASEMENT]]'') now need a non-empty building zone that fits the size of your basement filler. If no building zone is set, basements will not be placed.+To improve the number of basement spawned, scalable building parts (with constructor ''[[api:building_constructor_scaler|BUILDING_CONSTRUCTOR_SCALER]]'' or ''[[api:building_constructor_basement|BUILDING_CONSTRUCTOR_BASEMENT]]'') now need a non-empty building zone that fits the size of your basement filler. If no building zone is set, basements will not be placed
 + 
 +The [[api:building_zone|BUILDING_ZONE]] type has also been reworked to allow zone polygons per building part.
  
 ===== Foundation 1.4.5.1009 ===== ===== Foundation 1.4.5.1009 =====
migration.txt · Last modified: 2023/09/05 11:21 by mathieu

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki