Class VerticalSnakeAnimation
java.lang.Object
xyz.xenondevs.invui.animation.impl.AbstractAnimation
xyz.xenondevs.invui.animation.impl.AbstractSoundAnimation
xyz.xenondevs.invui.animation.impl.VerticalSnakeAnimation
- All Implemented Interfaces:
Animation
An animation that moves like a snake in vertical direction,
starting from (0,0) then moving all the way down, one to the side,
all the way up and repeat.
-
Constructor Summary
ConstructorDescriptionVerticalSnakeAnimation
(int tickDelay, boolean sound) Creates a newVerticalSnakeAnimation
. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
handleFrame
(int frame) Handles the next frame of theAnimation
.Methods inherited from class xyz.xenondevs.invui.animation.impl.AbstractAnimation
addFinishHandler, addShowHandler, cancel, convToIndex, finish, getCurrentViewers, getHeight, getSlots, getWidth, setGui, setSlots, setWindows, show, start
-
Constructor Details
-
VerticalSnakeAnimation
public VerticalSnakeAnimation(int tickDelay, boolean sound) Creates a newVerticalSnakeAnimation
.- Parameters:
tickDelay
- The delay between each slot being shown.sound
- Whether a sound should be played when the slot is shown.
-
-
Method Details
-
handleFrame
protected void handleFrame(int frame) Description copied from class:AbstractAnimation
Handles the next frame of theAnimation
.- Specified by:
handleFrame
in classAbstractAnimation
- Parameters:
frame
- The current frame
-