self:set_gravity_scale

Client

Sets the gravity scale multiplier of the rigid body


Syntax

local status = self:set_gravity_scale(
    scale
)

Parameters

TypeNameDescription
floatscaleGravity scale multiplier to apply

Returns

TypeNameDescription
boolstatustrue on successful execution, false otherwise

Examples

Set the gravity scale of a rigid body
local entity = physics.rigid.create()

entity:set_gravity_scale(1.5)

On this page