Record Class AnimationProgress.EmptyProgress
java.lang.Object
java.lang.Record
kr.toxicity.model.api.animation.AnimationProgress.EmptyProgress
- Record Components:
time- the time of the keyframe
- All Implemented Interfaces:
Comparable<Timed>, AnimationProgress, Timed
- Enclosing interface:
AnimationProgress
public static record AnimationProgress.EmptyProgress(float time)
extends Record
implements AnimationProgress
An implementation of
AnimationProgress that represents an empty keyframe.- Since:
- 2.0.0
-
Nested Class Summary
Nested classes/interfaces inherited from interface AnimationProgress
AnimationProgress.EmptyProgress -
Field Summary
Fields inherited from interface AnimationProgress
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionEmptyProgress(float time) Creates an instance of aEmptyProgressrecord class. -
Method Summary
Modifier and TypeMethodDescription@NotNull BoneMovementanimate(@NotNull BoneMovement movement, @NotNull BoneMovement dest) Applies this keyframe's animation to a bone's movement.final booleanIndicates whether some other object is "equal to" this one.booleanChecks if the rotation in this keyframe should be applied globally.final inthashCode()Returns a hash code value for this object.booleanChecks if interpolation should be skipped after this keyframe.floattime()Returns the value of thetimerecord component.@NotNull AnimationProgresstoEmpty()Converts this progress to empty progress at the same time.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
EmptyProgress
public EmptyProgress(float time) Creates an instance of aEmptyProgressrecord class.- Parameters:
time- the value for thetimerecord component
-
-
Method Details
-
animate
@NotNull public @NotNull BoneMovement animate(@NotNull @NotNull BoneMovement movement, @NotNull @NotNull BoneMovement dest) Description copied from interface:AnimationProgressApplies this keyframe's animation to a bone's movement.- Specified by:
animatein interfaceAnimationProgress- Parameters:
movement- the current bone movementdest- the destination object to store the result- Returns:
- the resulting bone movement
-
toEmpty
Description copied from interface:AnimationProgressConverts this progress to empty progress at the same time.- Specified by:
toEmptyin interfaceAnimationProgress- Returns:
- an empty progress
-
skipInterpolation
public boolean skipInterpolation()Description copied from interface:AnimationProgressChecks if interpolation should be skipped after this keyframe.- Specified by:
skipInterpolationin interfaceAnimationProgress- Returns:
- true to skip interpolation, false otherwise
-
globalRotation
public boolean globalRotation()Description copied from interface:AnimationProgressChecks if the rotation in this keyframe should be applied globally.- Specified by:
globalRotationin interfaceAnimationProgress- Returns:
- true for global rotation, false for local
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
time
-