Skip to content

@modoki/engine / index / buildRig2D

Function: buildRig2D()

buildRig2D(opts): Rig2DFile

Build a rig: auto-tessellate the sprite → grid mesh, then auto-weight each vertex to the bones. Returns a Rig2DFile ready to JSON.stringify / feed to setRig2D / normalizeRig2D.

Parameters

opts

BuildRig2DOptions

Returns

Rig2DFile

Built with Modoki.