Home › For server admins

Making a theme

A theme is made in the game: Freehold sets out one of its buildings in front of you, you rebuild it with ordinary blocks, and one command reads it back into a datapack. Nothing has to be installed and no file has to be written by hand. This page walks through it a building at a time.

Before you start

1. Set out the template

Stand on open ground and type /freehold theme template <theme> <building> [version], for example /freehold theme template nordic freehold:house_t1. Without a version it is default.

2. Rebuild it

Inside the frame everything is yours, and so is its height: walls, wall height, roof form and pitch, windows, façade, furnishing, material. A building may rise above the frame or stay lower than it — see A taller or lower building. Four things are fixed, and the export refuses if one of them is off — so a rebuilt building stands on the ground wherever Freehold's own one does:

Invisible blocks

Where Freehold's building leaves the ground as it is, the template sets structure void (minecraft:structure_void), an invisible vanilla block. What you do with it decides that cell:

Material that follows the biome

Use Freehold's own blocks, and your building takes the wood and stone of its biome — spruce in the taiga, sandstone in the desert, as Freehold's buildings do. The export writes these blocks back as their material:

BlockBecomes
Oak planks, stairs, slab, log, stripped log, stripped log slab, trapdoor, door, fencelight wood
Spruce planks, stairs, slab, log, stripped log, stripped log slab, trapdoor, door, fence; mangrove trapdoor (the window)dark wood
Cobblestone, cobblestone stairs, slab and wallstone
Stone bricks, stone brick stairs and slab; polished andesitemasonry
Coarse dirtground

The exact list is the default line of each file under data/freehold/material_class/ — see material_class/. If your theme has class files of its own, their default blocks count instead. Every other block stays the same in every biome — glass, lanterns, birch planks — which is what you want where a building should look alike everywhere. To keep every block as it is, add blocks to the end of the export command.

3. Export it

Click the command in the chat and send it: /freehold theme export <theme> <building> <version> <x> <y> <z> [height] [blocks].

4. Load it and look at it

Run /reload. Then /freehold blueprint preview <theme>:<building> sets the result out where you stand, and a settlement builds it once it is in that theme: choose it at the founding, or set it with /freehold theme set <freehold> <theme> — see Themes.

A taller or lower building

A theme may draw a building taller or lower than Freehold's. Build on above the template, or leave its top layers empty, and give the export the height you want as the number of layers it reads back, counted up from the corner in the command — at least 2: /freehold theme export nordic freehold:house_t1 default <x> <y> <z> 12.

In the game a building is as tall as its theme draws it. The outline when placing it, the levelling of its site, its protection and its demolition reach up to that height, and a windmill beside it sees that height when it checks its open stand. What happens to standing buildings when a settlement changes to a theme of another height is on Themes.

Versions

Export the version default of a building first — without it, the export refuses every other. A building placed in a version your theme does not draw is built in your theme's default. All versions of a building in your theme share one height — see A taller or lower building.

Handing it on

Zip the folder <world>/datapacks/<theme>/. Next to the game's files it holds the drawings as text under blueprint_source/, so whoever works on the theme next sets out your drawing with template and builds on. Freehold's licence allows datapacks of your own.

Common pitfalls

Recolouring only

One material class file recolours every building without a single one rebuilt. data/<theme>/material_class/wood.json replaces Freehold's wood as a whole — nothing of Freehold's file is mixed in. The same goes for stone, masonry and ground. Its shape:

{
  "schema_version": 1,
  "ranks": {
    "light": {
      "default": {"planks": "minecraft:birch_planks", "stairs": "minecraft:birch_stairs", "...": "..."},
      "biomes": {"minecraft:taiga": {"planks": "minecraft:spruce_planks", "...": "..."}}
    },
    "dark": {"default": {"...": "..."}}
  }
}

For the advanced

The export also writes the drawing as text, to data/<theme>/blueprint_source/<building>/<version>.fhb, and it can be edited by hand. The next export of that version writes it anew from what stands in the game.

See also: Themes, The datapack.