Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.
public static final class ActorAnimator.Clip
- Object
- ActorAnimator.Clip
A run of frames.
Constructors
public Clip(int[] frames, int ticksPerFrame, boolean loop) | Creates a clip. |
Methods
public int frameAt(int ticks) | The frame shown a number of ticks into the clip. |
Inherited methods
Constructor details
Clip
public Clip(int[] frames, int ticksPerFrame, boolean loop)Creates a clip.
Parameters
framesint[]- frame indices into the sheet, at least one
ticksPerFrameint- world ticks (1/60 s) each frame shows
loopboolean- whether it repeats; otherwise it holds the last frame
Method details
frameAt
public int frameAt(int ticks)The frame shown a number of ticks into the clip.
Parameters
ticksint- ticks since the clip started
Returns
a sheet frame index