Skip to main content

write_building_slots

Function write_building_slots 

Source
pub fn write_building_slots(
    layout: &StartposLayout,
    plan: &CaiPlan,
    world: &WorldView,
    map_regions: &[MapRegion],
    layouts: &[SettlementLayout],
) -> Result<RecordNode>
Expand description

Writes the building slots list: each settlement’s slots in map order, then each horde army’s slots.

§Arguments

  • layout - Record layouts.
  • plan - Component ids.
  • world - The world’s objects.
  • map_regions - Regions of the map, in map order.
  • layouts - Settlement layouts of the map.

§Errors

Returns an error if the layout lacks the records.