Property | Type | Description | |
---|---|---|---|
DecayCurve | Curve | ||
ForceType | ForceTypes | ||
StrengthCurve | Curve |
Property | Type | Description | |
---|---|---|---|
Randomize | Random |
Method | Description | |
---|---|---|
AbstractForceController ( ) : System |
Constructor
|
|
AbstractForceController ( TimingModes mode ) : System |
Overloaded Contstructor with supplying Timing Mode
|
|
ApplyForce ( float dt, float strength ) : void |
Apply the force supplying strength (wich is modified in Update() according to the TimingMode
|
|
Trigger ( ) : void |
Triggers the trigger modes (Trigger and Curve)
|
|
Update ( float dt ) : void |
Inherited from Controller Depending on the TimingMode perform timing logic and call ApplyForce()
|
Method | Description | |
---|---|---|
GetDecayMultiplier ( Body body ) : float |
Calculate the Decay for a given body. Meant to ease force development and stick to the DRY principle and provide unified and predictable decay math.
|
public AbstractForceController ( TimingModes mode ) : System | ||
mode | TimingModes | |
return | System |
public abstract ApplyForce ( float dt, float strength ) : void | ||
dt | float | |
strength | float | The strength |
return | void |
protected GetDecayMultiplier ( Body body ) : float | ||
body | Body | The body to calculate decay for |
return | float |