Animation · interface

SpringLink

One link of a chain: a spring, plus where it sits relative to the link above it at rest.

Explained in Animation.

interface SpringLink extends SpringSettings
import type { SpringLink } from '@driftengine/animation';

In depth

The offset is what makes a chain hang rather than collapse. Without it every link would be pulled to the same point and a braid would be a single mass with extra arithmetic.

Properties

NameTypeDescription
restOffsetMreadonlyreadonly [number, number, number]Where this link rests relative to the one above it, in metres.