Skip to main content

Rigidbody.AddRelativeForce(Vector3 force, ForceMode mode = ForceMode.Force)

Adds a force to the rigidbody relative to its coordinate system.

Parameters:

NameTypeDescription
forceVector3Force vector in local coordinates.
modeForceMode

Usage

---@type Rigidbody
local rigidbody;

---@type Vector3
local force;

---@type ForceMode
local mode;


rigidbody.AddRelativeForce(force, mode)