Technical notes for Empire Builder. The project page shows the finished piece; this one is about how it works.
Empire Builder is a seven by seven kilometre stretch of the Columbia River with a train running through it. Almost every part of it is generated: the ground from survey data, the rail line from a script, the forest from PCG graphs. That only works if the pieces agree, so they share data: one heightmap and one set of masks feed both the landscape and the plants, and one spline carries the track, the train and the clearing in the forest.
Survey data to Landscape
The ground starts as USGS 3DEP elevation: 1 m lidar along the river, with 10 m data filling the far bank. Houdini merges the two, carves the river bed and exports a heightmap plus a set of masks (water, shore, steep slope, erosion flow, the island and the rail bed) that the landscape material and PCG both read.

The export also writes a small ue_import.json with the world size, Z scale and the area each mask covers, so PCG can line every mask up with the Landscape.
The rail line is data, not a hand-drawn spline
A Houdini script, rail_route.py, lays out the route: it follows the river, caps the height above the water and keeps clear of the inland pond. It writes a JSON file that Unreal reads, so a change to the brief is a parameter change and a re-run, not points dragged in the editor.

In Unreal the JSON becomes a spline, and BP_RailTrack builds the track on it: two rails as spline meshes at standard gauge, sleepers as instances with a little random offset, and a trapezoid ballast bed under both.




One spline, three systems
The same spline drives the track, the train and the vegetation, so moving the route moves all three:
- BP_Train exposes one
Distancevalue to Sequencer. Each car samples the spline at its front and rear bogie and takes its position and heading from those two points, so long cars stay on the rails through curves. - PCG finds the spline by the tag
PCG_Railand keeps the embankment clear: a 2.75 m shoulder and a 1.5 : 1 slope give the toe of the bank, and nothing grows inside it.


The forest in layers
The forest is three groups of PCG volumes, each with its own graph, and all of them read the same terrain masks and the rail spline. Built up one group at a time, seen from the same camera:





Plants that respect the camera
Each side of the line is dressed for the camera. The island side, where the shots look from, gets grass and low shrubs; the tall forest wall goes behind the train, and the embankment itself stays bare. Which side faces the island comes from the island's direction and the spline's right vector. For the close shots, plants also keep clear of the sight line from each camera to the train: 7 m for canopy, 3.5 m for shrubs.


Megaplants
The hero trees are Megaplants: Nanite skinned meshes with built-in wind, enabled with r.Nanite.Foliage=1. Colour variants are material instances that a palette actor applies after PCG generates, so the heavy meshes are never duplicated. Wind is computed around each instance's own pivot, for a sway of 35–80 cm.
What I'd keep
- Prove each feature on a tiny sample through the whole chain (one plant variant, export, 54 trees, colour, wind) before scaling it to thousands.
- Keep parameters at the top of re-runnable scripts and change them there, not by hand in the editor.