ModelDeformerclass

Deforms an ancestor model using an ordered stack of masked operations before bone skinning. Bones, collision, hitboxes and attachments are unaffected.

object→VolumeComponent→ModelDeformer
Namespace
Sandbox
Assembly
Sandbox.Engine
Declaration
public sealed class Sandbox.ModelDeformer : Sandbox.Volumes.VolumeComponent

Constructors1

Showing 1 constructors

public ModelDeformer()PUBLICCONSTRUCTOR

Creates a sphere volume with a broad, smooth falloff.

Properties19

Showing 19 properties

public bool Sandbox.ModelDeformer.ApplyToBoneMergedChildren { get; set; }PUBLICGETSET

Apply this effect to bone-merged clothing and accessories attached to the same model.

Returns:bool—

public float Sandbox.ModelDeformer.Falloff { get; set; }PUBLICGETSET

Width of the smooth edge fade, relative to the shape's radius or smallest half-extent. Zero applies full strength inside the shape; one fades across the entire interior. Infinite shapes always apply full strength and do not use falloff.

Returns:float—

public float Sandbox.ModelDeformer.Inflation { get; set; }PUBLICGETSET

Signed inflation: negative values contract, zero leaves the model unchanged, and positive values expand. The shape boundary limits displacement; capsules expand or contract around their axis.

Returns:float—

public float Sandbox.ModelDeformer.InflationSoftness { get; set; }PUBLICGETSET

How gradually inflation fades near the shape's edge. Zero keeps inflation broad; one softens it across the whole shape, concentrating the effect toward the center.

Returns:float—

public Sandbox.ModelDeformer.NormalModeType Sandbox.ModelDeformer.NormalMode { get; set; }PUBLICGETSET

Accurate follows the local deformation; Smooth softens its shading over a neighbourhood. Preserve moves vertices without correcting their shading. No mode changes the displacement itself.

Returns:NormalModeType—

public float Sandbox.ModelDeformer.NormalSmoothingRadius { get; set; }PUBLICGETSET

Distance over which surface shading is smoothed, in local units. Larger values soften more detail without changing the shape of the mesh.

Returns:float—

public int Sandbox.ModelDeformer.Priority { get; set; }PUBLICGETSET

Lower priorities deform the model first; higher priorities operate on their result. Use distinct priorities when the order of effects matters.

Returns:int—

public float Sandbox.ModelDeformer.PullFocus { get; set; }PUBLICGETSET

How strongly the pull is concentrated near the center. Zero pulls the entire interior equally; one gradually weakens the pull from the center toward the edge, leaving the rim in place.

Returns:float—

public Angles Sandbox.ModelDeformer.RotationOffset { get; set; }PUBLICGETSET

Rotation around the shape center, applied after scale and before translation.

Returns:Angles—

public Vector3 Sandbox.ModelDeformer.ScaleFactor { get; set; }PUBLICGETSET

Scale on each local axis around the shape center.

Returns:Vector3—

public virtual Sandbox.Volumes.SceneVolume Sandbox.ModelDeformer.SceneVolume { get; set; }PUBLICVIRTUALGETSET

Choose the affected area, then move or resize it in the scene. Infinite affects the whole model. Vertices affected by a finite shape stay inside its boundary.

Returns:SceneVolume—

public float Sandbox.ModelDeformer.StretchRatio { get; set; }PUBLICGETSET

Local Z scale. One is unchanged; below one squashes and above one stretches. X/Y compensate to preserve volume before Value and the shape's falloff are applied. At zero the height is flat; width compensation is capped at ten near zero to stay finite.

Returns:float—

public float Sandbox.ModelDeformer.StretchTransition { get; set; }PUBLICGETSET

Width of the transition between the squashed or stretched area and the surrounding mesh. Zero gives an abrupt boundary; one spreads the transition across the whole shape.

Returns:float—

public float Sandbox.ModelDeformer.TransformBlend { get; set; }PUBLICGETSET

How much of the shape blends the transform into the surrounding mesh. Zero transforms the entire interior equally; one blends from the center to the edge.

Returns:float—

public float Sandbox.ModelDeformer.Weight { get; set; }PUBLICGETSET

Blend from the original shape at zero to the full effect at one. Negative values reverse the displacement; values above one amplify it.

Returns:float—

On this page