Skip to main content

Module component

Module component 

Source
Expand description

The spine of a design: its stages and the body components stacked inside them.

A .ork design is a tree. Its trunk is the spine: the stages, and inside each of them the nose cones, body tubes and transitions that stack end to end along the axis. Everything else hangs off that trunk and is read by super::attached: the tubes and rings inside the body, the fins and lugs on it, the recovery gear.

What this module does is turn the spine into hpr_design types: a Rocket of Stages of Components, each of them carrying whatever super::attached read inside and on it. It resolves nothing itself. Where OpenRocket wrote auto, the component carries an AutoDimension and Rocket::layout works the radius out from the neighbours, which is the one place that rule lives. The one exception is a radius that rule cannot reach (a chain of automatic radii with no fixed radius anywhere along it), which takes OpenRocket’s default, OPENROCKET_DEFAULT_RADIUS_M, because the design holds no other number for it.

Constants§

OPENROCKET_DEFAULT_RADIUS_M
The radius OpenRocket gives an automatic body radius that has no fixed radius anywhere along its chain to take, in meters: its default radius, 25 mm.

Functions§

rocket
Reads a design document into a Rocket: its stages, the body components stacked in them, and the parts on and inside each of those.