AnimationLib
A nonlinear-animation lib for Java. It can be used in various graphic animations like Minecraft GUI , Software UI Animations.
Install / Use
/learn @itscola/AnimationLibREADME
AnimationLib
An animation lib for Java. It can be used in various graphic animations.
Demo:
protected Animation displayAnimation = new Animation();
protected Animation closeAnimation = new Animation();
displayAnimation.setMin(0).setMax(150).setFunction(new CubicOutFunction()).setTotalTime(260);
closeAnimation.setMin(150).setMax(0).setFunction(new CubicOutFunction()).setTotalTime(150);
if(!needClose){
// The update method will return the max value, after the total time.
Render2DUtils.drawRect(x , y , x1, displayAnimation.update());
}else{
Render2DUtils.drawRect(x , y , x1, closeAnimation.update());
}
if(displayAnimation.isFinish()){
// displayAnimation is finish.
}
displayAnimation.reset();
protected Animation displayAnimation = new Animation();
protected long time;
displayAnimation.setMin(0).setMax(150).setFunction(new CubicOutFunction()).setTotalTime(260);
//init
this.time = System.currentTimeMillis()
Render2DUtils.drawRect(x , y , x1, closeAnimation.update(System.currentTimeMillis() - this.time));
protected Animation displayAnimation = new Animation();
Render2DUtils.drawRect(x , y , x1,
displayAnimation.setMin(0).setMax(150).setFunction(new CubicOutFunction()).setTotalTime(260).setLock(true).update()
);
float value = enableAnimation.update();
if(!enableAnimation.isFinish()){
yPosition = 16 + value;
}
Related Skills
node-connect
336.9kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
83.0kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
336.9kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
83.0kCommit, push, and open a PR
