I have a progress bar that will increase as my program completes but it jumps from increment a to b rather than smoothly easing in or out. Is there a way I can tween the progress bar rather than having it jerk? The progress bar currently is just a PIXI.graphic object in a container that changes positions.
let progressBarContainer = new PIXI.Container();
let progressBar = new PIXI.Graphics();
progressBarContainer.addChild(progressBar);
//after progress is made
progressBar.position = (x + progress, y)
I was thinking of having a timer function that increases the progress bar by some x value until it reaches the desired percentage (maybe use a cubic function to imitate easing animations) but I was wondering if maybe there is a more effective way that I have not come across yet.
Thanks!