diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/WSprite.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/WSprite.java index 97a1ab83..28394309 100644 --- a/src/main/java/io/github/cottonmc/cotton/gui/widget/WSprite.java +++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/WSprite.java @@ -202,7 +202,7 @@ public void paint(DrawContext context, int x, int y, int mouseX, int mouseY) { if (currentFrameTime >= frameTime) { currentFrame++; //if we've hit the end of the animation, go back to the beginning - if (currentFrame >= frames.length - 1) { + if (currentFrame >= frames.length) { currentFrame = 0; } currentFrameTime = 0;