public class ControlledAnimation
extends java.lang.Object
| Constructor and Description |
|---|
ControlledAnimation(int d) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canDecreaseTimer()
Checks if the timer can be decreased
|
boolean |
canIncreaseTimer()
Checks if the timer can be increased
|
void |
decreaseTimer()
Decreases the timer by 1.
|
void |
decreaseTimer(int time)
Decreases the timer by a specific value.
|
float |
getAnimationFraction()
Returns a float that represents a fraction of the animation, a value between 0.0F and 1.0F.
|
float |
getAnimationProgressArcTan()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressPoly2()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressPoly3()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressPolyN(int n)
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressSin()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressSinPowerOf(int i)
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressSinSqrt()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressSinToTen()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressSinToTenWithoutReturn() |
float |
getAnimationProgressSmooth()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressSteep()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressTemporary()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressTemporaryFS()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
float |
getAnimationProgressTemporaryInvesed()
Returns a value between 0.0F and 1.0F depending on the timer and duration of the animation.
|
int |
getTimer()
Returns the timer of this animation.
|
void |
increaseTimer()
Increases the timer by 1.
|
void |
increaseTimer(int time)
Increases the timer by a specific value.
|
void |
resetTimer()
Sets the timer to 0.
|
void |
setDuration(int d)
Sets the duration of the animation in ticks.
|
void |
setTimer(int time)
Sets the timer to a specific value.
|
public void setDuration(int d)
d - is the maximum number of ticks that the timer can reach.public int getTimer()
public void setTimer(int time)
time - is the number of ticks to be set.public void resetTimer()
public void increaseTimer()
public boolean canIncreaseTimer()
public void increaseTimer(int time)
time - is the number of ticks to be increased in the timerpublic void decreaseTimer()
public boolean canDecreaseTimer()
public void decreaseTimer(int time)
time - is the number of ticks to be decreased in the timerpublic float getAnimationFraction()
public float getAnimationProgressSmooth()
public float getAnimationProgressSteep()
public float getAnimationProgressSin()
public float getAnimationProgressSinSqrt()
public float getAnimationProgressSinToTen()
public float getAnimationProgressSinToTenWithoutReturn()
public float getAnimationProgressSinPowerOf(int i)
i - is the power of the sine function.public float getAnimationProgressPoly2()
public float getAnimationProgressPoly3()
public float getAnimationProgressPolyN(int n)
n - is the power of the polynomial function.public float getAnimationProgressArcTan()
public float getAnimationProgressTemporary()
public float getAnimationProgressTemporaryFS()
public float getAnimationProgressTemporaryInvesed()