We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 49bfcb6 commit db8cbafCopy full SHA for db8cbaf
1 file changed
viz/3dviewer.html
@@ -165,6 +165,13 @@
165
166
function restartAnimationTimer() {
167
clearInterval(animationTimer);
168
+
169
+ // If trying to play from the very end of a non-looping animation, reset to the beginning first.
170
+ if (frames.length > 0 && frameIndex === frames.length - 1 && !loop) {
171
+ frameIndex = 0;
172
+ updateFrame(); // Immediately update visuals to show frame 0
173
+ }
174
175
animationTimer = setInterval(() => {
176
if (!playing || !frames.length) return;
177
if (frameIndex < frames.length - 1) {
0 commit comments