AngularVelocity
Calculate the angular velocity necessary to rotate the current rotation and the specified rotation over a give time.
Read time 1 minuteLast updated 9 days ago
Definition
- Type: Method
- Namespace: UnityEngine.LowLevelPhysics2D
- Assembly: UnityEngine.Physics2DModule
AngularVelocity(PhysicsRotate, float)
Calculate the angular velocity necessary to rotate the current rotation and the specified rotation over a give time.
public readonly float AngularVelocity(PhysicsRotate rotation, float deltaTime)
Parameters
The rotation used as a calculation to rotate to.
The delta time over which the rotation would take place.
Returns
Type | Description |
|---|---|
| float | The angular velocity required to rotate to the specified rotation. |
AngularVelocity(PhysicsRotate, PhysicsRotate, float)
Calculate the angular velocity necessary to rotate between two rotations over a give time.
public static float AngularVelocity(PhysicsRotate rotationA, PhysicsRotate rotationB, float deltaTime)
Parameters
The rotation to rotate from.
The rotation to rotate to.
The delta time over which the rotation would take place.
Returns
Type | Description |
|---|---|
| float | The angular velocity required to rotate between the specified rotations. |