self:apply_central_impulse
Client
Applies an instantaneous impulse to the rigid body's center of mass
Syntax
local status = self:apply_central_impulse(
impulse
)Parameters
| Type | Name | Description |
|---|---|---|
vector3 | impulse | Impulse vector to apply as {x, y, z} |
Returns
| Type | Name | Description |
|---|---|---|
bool | status | true on successful execution, false otherwise |
Examples
local entity = physics.rigid.create()
entity:apply_central_impulse({0, 5, 0})