Dynamic exhaust trail and optional afterburner geometry for AircraftController.

The trail owns a separate dynamic SceneModel. It creates translucent tube segments behind the aircraft and updates their transforms from controller state each frame. When afterburner configuration is present, it also creates three nested flame layers that appear above the configured speed threshold.

const exhaust = new AircraftExhaustTrail({
scene,
modelId: "aircraft",
coordinateSystem: aircraftSceneModel.coordinateSystem,
config: {
forwardAxis: "-Z",
exhaust: {
offset: [0, -0.8, 0],
trailLength: 42,
trailSegments: 24
},
afterburner: {
threshold: 0.7,
length: 10
}
}
});

Constructors

Properties

Resolved afterburner config, or null when disabled.

afterburnerObjectIds: string[] = []

Generated afterburner SceneObject IDs.

axis: string

Local aircraft axis used as the forward direction.

maxForwardSpeed: number

Speed used to normalize trail/afterburner intensity.

objectIds: string[] = []

All generated SceneObject IDs.

offset: Vec3

Aircraft-local exhaust emitter offset.

radius: number

Base trail radius.

sceneModel: SceneModel

Generated dynamic SceneModel containing trail and flame geometry.

segmentSpacing: number

Target spacing between generated trail samples.

trailAdvection: number

Fraction of emitter movement carried by existing samples.

trailExpansion: number

Radius growth along the trail.

trailObjectIds: string[] = []

Generated trail SceneObject IDs.

trailSegments: number

Number of trail segments.

trailTether: number

Tether strength pulling samples back toward the emitter path.

trailTransforms: SceneTransform[] = []

Mutable transforms for trail segments.

wander: number

Sideways trail curl amount.

Methods