Lost Lily/Grid ToolkitDocs 1.0
Table of Contents

Extend Grid Toolkit with a cubic topology

What this teaches

This scene demonstrates a supported extension boundary rather than a built-in topology. A project-owned IGridTopology, orientation system, authoring adapter, layout, hit resolver, and renderer cooperate to build tetracubes in three dimensions.

Open and run

Menu path: Tools > Lost Lily > Grid Toolkit > Samples > Open > Cubic Grid Construction.

Read Custom topology, orientation, and layout before treating the implementation as an architectural reference.

Enter Play Mode. Press 1–5 to select a piece, X/Y/Z to rotate on each axis, and left-click to place. Right-drag orbits, the mouse wheel zooms, and R resets the construction.

Cubic Grid Construction in Play Mode showing an empty three-dimensional voxel board, five tetracube choices, orientation controls, and status text.
The cubic extension supplies logical 3D coordinates, multi-axis orientation, spatial layout, hits, and retained visuals without changing Grid Toolkit core.

Try it

  1. Place a foundation slab on the lower layer.
  2. Select another piece and rotate it around two different axes.
  3. Attach it above ground so at least one face touches the existing construction.
  4. Build around a volumetric corner and inspect the preview from several camera angles.
  5. Try a detached or invalid placement, then press R.

Checkpoint

Valid pieces occupy three-dimensional cells and remain attached according to the example's project policy. Invalid previews report a reason without mutation. Camera orbit changes presentation only. Reset clears the construction and restores the starting cubic board.

How it works

Extension part Public contract Responsibility
Cubic coordinates/topology IGridTopology Defines identity, neighbors, distance, and 3D footprint transforms.
Orientation system IGridOrientationSystem Normalizes rotations around all supported axes.
Layout IGridLayout Projects logical cubic cells into world positions and resolves hits.
Layout provider IGridLayoutProvider Creates a compatible layout for the board binding.
Renderer modules Visualization contracts Build cell, structure, intent, and hit surfaces for the custom layout.

Try another variation

In a duplicated scene, change a tetracube footprint or placement rule. Implement and test any derived topology in your own assemblies through the public contracts.

Troubleshooting

Symptom Fix
A piece rotates differently than expected. Check the current X/Y/Z orientation and view the preview from another camera angle.
Custom hits disagree with visuals. Test the layout's pose and hit conversion as one contract.

Next sample

Return to the Samples & Demos catalog, or continue with Extending Grid Toolkit.