Collider:applyForce

Edit

Applies a force to the Collider.





Arguments

NameTypeDescription
xnumber The x component of the force to apply.
ynumber The y component of the force to apply.
znumber The z component of the force to apply.

Returns

Nothing

Arguments

NameTypeDescription
xnumber The x component of the force to apply.
ynumber The y component of the force to apply.
znumber The z component of the force to apply.
pxnumber The x position to apply the force at, in world coordinates.
pynumber The y position to apply the force at, in world coordinates.
pznumber The z position to apply the force at, in world coordinates.

Returns

Nothing

Arguments

NameTypeDescription
forceVec3 The force vector to apply.

Returns

Nothing

Arguments

NameTypeDescription
forceVec3 The force vector to apply.
positionVec3 The position to apply the force at, in world coordinates.

Returns

Nothing

Notes

If the Collider is asleep, it will need to be woken up with Collider:setAwake for this function to have any affect.

See also