TrueSync
|
Represents a physical 3D rigid body. More...
Public Types | |
enum | InterpolateMode { None, Interpolate, Extrapolate } |
Public Member Functions | |
void | AddForce (TSVector force) |
Applies the provided force in the body. More... | |
void | AddForce (TSVector force, ForceMode mode) |
Applies the provided force in the body. More... | |
void | AddForce (TSVector force, TSVector position) |
Applies the provided force in the body. More... | |
void | AddForce (TSVector force, TSVector position, ForceMode mode) |
Applies the provided force in the body. More... | |
void | AddTorque (TSVector torque) |
Simulates the provided tourque in the body. More... | |
void | LookAt (TSVector target) |
Changes orientation to look at target position. More... | |
void | MovePosition (TSVector position) |
Moves the body to a new position. | |
void | MoveRotation (TSQuaternion rot) |
Rotates the body to a provided rotation. | |
Public Attributes | |
InterpolateMode | interpolation |
Interpolation mode that should be used. | |
bool | freezeZAxis |
If true it freezes Z rotation of the RigidBody (it only appears when in 2D Physics). | |
Properties | |
FP | mass [get, set] |
Mass of the body. | |
bool | useGravity [get, set] |
If true it uses gravity force. | |
bool | isKinematic [get, set] |
If true it doesn't get influences from external forces. | |
TSCollider | tsCollider [get] |
Returns the TSCollider attached. | |
TSTransform | tsTransform [get] |
Returns the TSTransform attached. | |
TSVector | position [get, set] |
Position of the body. | |
TSQuaternion | rotation [get, set] |
Orientation of the body. | |
TSVector | velocity [get, set] |
LinearVelocity of the body. | |
TSVector | angularVelocity [get, set] |
AngularVelocity of the body. | |
Represents a physical 3D rigid body.
Definition at line 11 of file TSRigidBody.cs.
void TrueSync.TSRigidBody.AddForce | ( | TSVector | force | ) |
Applies the provided force in the body.
force | A TSVector representing the force to be applied. |
Definition at line 134 of file TSRigidBody.cs.
void TrueSync.TSRigidBody.AddForce | ( | TSVector | force, |
ForceMode | mode | ||
) |
Applies the provided force in the body.
force | A TSVector representing the force to be applied. |
mode | Indicates how the force should be applied. |
Definition at line 144 of file TSRigidBody.cs.
Applies the provided force in the body.
force | A TSVector representing the force to be applied. |
position | Indicates the location where the force should hit. |
Definition at line 158 of file TSRigidBody.cs.
Applies the provided force in the body.
force | A TSVector representing the force to be applied. |
position | Indicates the location where the force should hit. |
Definition at line 168 of file TSRigidBody.cs.
void TrueSync.TSRigidBody.AddTorque | ( | TSVector | torque | ) |
Simulates the provided tourque in the body.
torque | A TSVector representing the torque to be applied. |
Definition at line 181 of file TSRigidBody.cs.
void TrueSync.TSRigidBody.LookAt | ( | TSVector | target | ) |
Changes orientation to look at target position.
target | A TSVector representing the position to look at. |
Definition at line 191 of file TSRigidBody.cs.