Garry's Mod Wiki

Entity:SetFlexWeight

  Entity:SetFlexWeight( number flex, number weight )

Description

Sets the weight/value of given flex controller.

Setting flex weights spawns an internal networked entity (one per entity face posed) to accommodate networking to clients.

Only 96 flex controllers can be set! Flex controllers on models with higher amounts will not be accessible.

Arguments

1 number flex
The ID of the flex to modify weight of. The range is between 0 and Entity:GetFlexNum - 1.
2 number weight
The new weight to set. See Entity:GetFlexBounds for the model-defined input range.