PhysObj/CalculateForceOffset

From Garry's Mod
Jump to: navigation, search
 PhysObj:CalculateForceOffset( )

Contents

Description

Calculates the force and torque on the center of mass for an offset force impulse. The outputs can be directly passed to PhysObj:ApplyForceCenter and PhysObj:ApplyTorqueCenter, respectively.

Arguments

Vector force

The initial force

Arguments

Vector pos

The location of the force in world coordinates

Returns

Vector

The calculated force on the physics object's center of mass

Returns

Vector

The calculated torque on the physics object's center of mass
Personal tools
Navigation