Class AnimatedProperty<T>
java.lang.Object
dev.prozilla.pine.common.property.animated.AnimatedProperty<T>
- All Implemented Interfaces:
Updatable,AnimatedPropertyBase<T>,Property<T>,Functor<T>
- Direct Known Subclasses:
AnimatedFloatProperty,AnimatedIntProperty,AnimatedObjectProperty
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetCurve()floatbooleanvoidrestart()voidsetDuration(float duration) voidupdate(float deltaTime) Progresses the animation.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface dev.prozilla.pine.common.property.animated.AnimatedPropertyBase
getRestartedValue, getUpdatedValueMethods inherited from interface dev.prozilla.pine.common.property.Property
getValue, getValueOr, hasValue, hasValueProperty, isNotNull, isNotNullProperty, isNull, map, replaceNull, requireValue, snapshot, toStringProperty
-
Field Details
-
curve
-
time
protected float time
-
-
Constructor Details
-
AnimatedProperty
-
-
Method Details
-
restart
public void restart()- Specified by:
restartin interfaceAnimatedPropertyBase<T>
-
update
public void update(float deltaTime) Progresses the animation.- Specified by:
updatein interfaceAnimatedPropertyBase<T>- Specified by:
updatein interfaceUpdatable- Parameters:
deltaTime- How far to progress the animation, in seconds
-
getFactor
public float getFactor()- Specified by:
getFactorin interfaceAnimatedPropertyBase<T>
-
hasFinished
public boolean hasFinished()- Specified by:
hasFinishedin interfaceAnimatedPropertyBase<T>
-
setDuration
public void setDuration(float duration) - Specified by:
setDurationin interfaceAnimatedPropertyBase<T>
-
getCurve
- Specified by:
getCurvein interfaceAnimatedPropertyBase<T>
-