Skip to content

mlctrez/factbp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

factbp

About

This library allows reading and writing factorio blueprint data. It supports reading and writing both the compressed format and just the json format.

This library will handle the differences in json format between reading and writing a single blueprint or a blueprint book containing nested blueprints or books.

Top level json element is either a single blueprint:

{
  "blueprint": {
    "item": "blueprint",
    "entities": []
  }
}

Or a book, where blueprints array is blueprints or nested books.

{
  "blueprint_book": {
    "item": "blueprint-book",
    "blueprints": [
      {
        "blueprint_book": {
          "item": "blueprint-book",
          "blueprints": [
          ]
        }
      },
      {
        "blueprint": {
          "item": "blueprint",
          "entities": []
        }
      }
    ]
  }
}

The Container struct handles reading and writing the top level object and the elements in the blueprints array.

About

Library for manipulating Factorio blueprints

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages