top trim

Eine Animation zurücksetzen

Once an animation completes, the timeline remains in its finished state. If you want to reuse the animation, you must reset the animation to its start state before you can play it again. To accomplish this in JavaScript, we must remove the animation's attribute using a JavaScript function like the one shown below:

function onExit()
{
  var box = scene.getBoxById("opacityDemoBox");
  box.removeAttribute("boxAnimate","false");
}
bottom trim