WrapDeformer

Show Deprecated

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.

Summary

Properties

Properties inherited from BaseWrap
  • Hidden
    Plugin Security
    Read Parallel
  • CageMeshId:ContentId
    Plugin Security
    Read Parallel

    Asset ID for cage mesh.

  • Plugin Security
    Read Parallel

    Cage mesh offset relative to parent MeshPart.

  • Read Only
    Not Replicated
    Read Parallel

    Cage mesh offset in world space.

  • HSRAssetId:ContentId
    Not Scriptable
    Roblox Security
    Read Parallel
  • Plugin Security
    Read Parallel

    Describes where a global zero was while authoring the cage mesh in an asset creation tool.

  • Read Only
    Not Replicated
    Read Parallel

    Describes where the origin (in world space) was while authoring the cage mesh in an asset creation tool.

Methods

Properties

Methods

SetCageMeshContent

void

Sets the cage mesh used to deform the parent MeshPart in conjunction with a sibling WrapTarget cage mesh. The content parameter should represent a Roblox mesh asset ID or an EditableMesh reference in your DataModel.

Parameters

content: Content

Returns

void

CreateEditableMeshAsync

Yields

Constructs and returns an EditableMesh corresponding 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's FixedSize to true.


Returns

GetDeformedCFrameAsync

Yields

Returns a CFrame deformed by the same deformation field used for the geometry of the parent MeshPart. This method is useful for the placement of accessories.

The input and output CFrame are both in the space of the parent MeshPart; only position (not rotation) will be deformed. This method respects all updates made to the deformation inputs prior to the request.

Parameters

originalCFrame: CFrame

Returns

Events