Class Momentum
Applies acceleration/velocity/friction to simulate momentum for an object being moved by other solvers/components
Assembly: cs.temp.dll.dll
public class Momentum : Solver, MonoBehaviour
Properties
Accelerate to goal position at this rate
Declaration
public float AccelerationRate { get; set; }
Property Value
Accelerate to goal position at this rate
Declaration
public float AccelerationRate { get; set; }
Property Value
Friction to slow down the current velocity
Declaration
public float Resistance { get; set; }
Property Value
Friction to slow down the current velocity
Declaration
public float Resistance { get; set; }
Property Value
Apply more resistance when going faster- applied resistance is resistance * (velocity ^ resistanceVelocityPower)
Declaration
public float ResistanceVelocityPower { get; set; }
Property Value
Apply more resistance when going faster- applied resistance is resistance * (velocity ^ resistanceVelocityPower)
Declaration
public float ResistanceVelocityPower { get; set; }
Property Value
Instantly maintain a constant depth from the view point instead of simulating Z-velocity
Declaration
public bool SnapZ { get; set; }
Property Value
Instantly maintain a constant depth from the view point instead of simulating Z-velocity
Declaration
public bool SnapZ { get; set; }
Property Value
Apply more acceleration if farther from target- applied acceleration is accelerationRate + springiness * distance
Declaration
public float Springiness { get; set; }
Property Value
Apply more acceleration if farther from target- applied acceleration is accelerationRate + springiness * distance
Declaration
public float Springiness { get; set; }
Property Value
Methods
Declaration
protected override void OnEnable()
Overrides
Declaration
protected override void OnEnable()
Overrides
Declaration
public override void SnapTo(Vector3 position, Quaternion rotation, Vector3 scale)
Parameters
Type |
Name |
Description |
Vector3 |
position |
|
Quaternion |
rotation |
|
Vector3 |
scale |
|
Overrides
Declaration
public override void SnapTo(Vector3 position, Quaternion rotation, Vector3 scale)
Parameters
Type |
Name |
Description |
Vector3 |
position |
|
Quaternion |
rotation |
|
Vector3 |
scale |
|
Overrides
Declaration
public override void SolverUpdate()
Overrides
Declaration
public override void SolverUpdate()
Overrides
Implements
MonoBehaviour