Class · inherits BaseWrap
WrapDeformer
Allows for the real-time deformation of a MeshPart.
About WrapDeformer
The WrapDeformer object provides a low-resolution cage mesh that pairs
with a WrapTarget sibling to deform a parent MeshPart. The
MeshPart geometry is deformed according to the displacement between
pairs of WrapTarget cage mesh vertices and WrapDeformer cage
mesh vertices. Cage mesh vertices are paired based on UV equivalence.
WrapDeformer may be used with avatars or on distinct
MeshParts, as long as WrapTarget children are present
for the parent MeshParts. WrapDeformer is similar to
WrapLayer but doesn't require layered clothing and can directly deform
MeshParts for publishing.
Methods 3
CreateEditableMeshAsync
() → EditableMeshYieldsReturns anEditableMesh(currently unskinned) equivalent to the deformed parent mesh.Constructs and returns an
EditableMeshcorresponding to the deformed parent mesh geometry. This method respects all updates made to the deformation inputs prior to the request. It also sets the returned result'sFixedSizetotrue.GetDeformedCFrameAsync
(originalCFrame: CFrame) → CFrameYieldsReturns aCFramedeformed comparably to theMeshPart.Returns a
CFramedeformed by the same deformation field used for the geometry of the parentMeshPart. This method is useful for the placement of accessories.The input and output
CFrameare both in the space of the parentMeshPart; only position (not rotation) will be deformed. This method respects all updates made to the deformation inputs prior to the request.SetCageMeshContent
(content: Content, cageOrigin: CFrame?) → ()Sets the cage mesh used to deform against a siblingWrapTargetcage mesh.Sets the cage mesh used to deform the parent
MeshPartin conjunction with a siblingWrapTargetcage mesh. Thecontentparameter should represent a Roblox mesh asset ID or anEditableMeshreference in yourDataModel.
WrapDeformer also has every member of BaseWrap. Deprecated and Roblox-only members are hidden.
Reference text from the Roblox Creator Documentation, licensed CC BY 4.0, reorganized by rbxtoolshub.com · Studio 0.743.0.7431133.