Team Cereustooling wiki

Edit a cliff's far objects (block maps)

Partly checkedagainst the code on 2026-11-12 11:36

The castle, the cliffs and the distant terrain of Limveld are not in the tiles. They are in the 2x2 and 4x4 block maps. This page says what the mcp-bridge branch does with them today, and how to edit them today. Direct editing is being built, see the last section.

Status: the behaviour below was read against the code. The editing route in "Edit a block map today" was not tried in the running tool, and nothing here was tested in game.

Map names

Kind Id Example
Tile m60_XX_ZZ_L0 m60_42_38_00
2x2 block map m60_BX_BZ_L1, with BX = XX / 2 and BZ = ZZ / 2 m60_21_19_01
4x4 block map m60_BX_BZ_L2, with BX = XX / 4 and BZ = ZZ / 4 m60_10_09_02

L is the layer. The same scheme applies to m61 and to Elden Ring projects.

What exists today

Block maps load around tiles as context

With Show surrounding block maps as context on, loading an m60 or m61 tile also loads its 2x2 and 4x4 block maps. The toggle is in the Map List: right-click any map. It is shown for Nightreign and Elden Ring projects and is on by default (setting MapEditor_Show_Block_Map_Context).

  • A tile of layer L uses the block map of layer L where the project has one, else the layer 0 one. When tiles of several layers want both versions of a block, the layered one wins.
  • The Map List marks these maps [context, read-only].
  • Their objects cannot be selected. The map is never marked as changed and never saved. Save Map on one does nothing.
  • They are loaded with the Havok (collision) load skipped.
  • They unload with the last tile that needs them.
  • They are left out of the reopened session (project-setup.md) and are not closed by "Loading a map replaces the open ones" (poi-variations.md).

Each block map has its own low-detail copy of every tile's map pieces. The copy's model name is m, two digits, then the tile's XX, ZZ and the piece number NN (for example m26423800 for m423800 of tile 42_38). To stop them fighting the tile's own pieces for depth:

  • a block map's copy is hidden when its tile is loaded;
  • the 4x4 copy is also hidden when a loaded 2x2 block map has one.

So only the most detailed loaded copy of each piece draws.

Tiles and blocks sit at their world offset

Nightreign m60 and m61 maps are placed at a fixed offset whatever order they load in, so neighbours line up:

  • A tile's origin is at X = tileX * 256, Z = tileZ * 256 (its centre).
  • A 2x2 block's origin is at index * 512 + 128. A 4x4 block's is at index * 1024 + 384.
  • Every layer uses the same offsets.
  • Small-base POI maps keep their own origin, worked out from WorldMapLegacyConvParam as before.

Positions in the MSB, in the property editor and in the bridge stay map-local.

Layered tile copies are lit

Irradiance volumes are looked up by map id. A tile copied under a new layer (for example m60_42_38_60) that has no envmap or ivinfo files of its own is lit with the layer 0 tile's bake (m60_42_38_00). If the copy has no EnvMapEffectBox regions it borrows the base tile's boxes. A copy that carries its own renamed bakes keeps using them.

Storm effects in block maps

The far copies of the storm effects in block maps follow the Hide Storm Effects toggle, see rendering.md.

Edit a block map today

Context objects cannot be edited in place. To change one, open its block map as an ordinary map:

  1. Find the block map in the Map List. It is the entry marked [context, read-only] near your tile, or work its id out from the table above.
  2. Open it on purpose:
    • Double-click the entry. This needs the preference Enable Load on Double-click (Map Editor, Map List), which is off by default in the code. With it off, a double-click does nothing.
    • Or, through the MCP bridge, call load_map with its id. It answers "loaded (was read-only context, now editable)".
  3. The map is now an ordinary map: selectable, editable and saved like any other. Edit it and save it.

Things to know about a block map opened this way:

  • All of its map pieces are shown again, including the low-detail copies of tiles you have loaded. They overlap the tiles' own pieces until you unload the block map.
  • It was loaded as context without collision. To get its collision, unload it and load it again as an ordinary map (right-click > Load Map). This follows from the code and was not tried.
  • It stays loaded until you unload it yourself.
  • A context map shows Save Map and Unload Map in its right-click menu, not Load Map, because it is already loaded.

To avoid the context load altogether, turn Show surrounding block maps as context off and load the block map like any other map.

How to tell it worked

  • After step 2 the [context, read-only] mark is gone and clicking the map's objects selects them.
  • After saving, the block map's MSB is in the project folder, not the game install.

What goes wrong

  • Clicking a cliff selects nothing. It belongs to a context map. Open the block map on purpose.
  • Two copies of the terrain flicker. A block map is open as an ordinary map together with its tiles.
  • A layered tile is dark. It has no bake of its own and no layer 0 tile to borrow from. Not seen here; it follows from the lighting rule above.

Being built: direct editing

Direct editing of block-map objects is being built on another branch and is not on mcp-bridge yet. It will make far objects editable without the steps above. See area-editing.md. When it lands, the "Edit a block map today" section must be rewritten.

Source files this page documents (5)
  • smithbox:src/Smithbox.Program/Editors/Map Editor/Framework/BlockMapContext.cs
  • smithbox:src/Smithbox.Program/Editors/Map Editor/Framework/Connections/MapConnections_NR.cs
  • smithbox:src/Smithbox.Program/Editors/Map Editor/Data/IrradianceVolumeBank.cs
  • smithbox:src/Smithbox.Program/Editors/Map Editor/GUI/MapListView.cs
  • smithbox:src/Smithbox.Program/Editors/Map Editor/MapUniverse.cs

Changed one of these? Update this page: smithbox/block-maps-and-far-objects.md (how).