math docs
    Preparing search index...

    Function forward

    • The forward pass: snaps the end effector onto target and drags the rest of the chain after it.

      A non-finite target leaves the chain untouched rather than poisoning it.

      The base is not pinned, so the whole chain moves. Run alone once per frame this is a follower rather than a solver - a rope or tentacle whose head leads. Pair it with backward, or use solve, to keep the base put.

      Parameters

      • chain: Chain2

        the chain to move, mutated in place

      • target: readonly [number, number]

        where the end effector should go

      Returns Chain2

      the chain