MCPcopy
hub / github.com/KilledByAPixel/LittleJS / restart

Method restart

plugins/tweenSystem.js:161–167  ·  view source on GitHub ↗

Reset this tween to the start: life back to duration, pause cleared, * re-added to the active list if previously stopped, and the callback * re-fired with the start value. * @memberof TweenSystem

()

Source from the content-addressed store, hash-verified

159 * re-fired with the start value.
160 * @memberof TweenSystem */
161 restart()
162 {
163 this.life = this.duration;
164 this.paused = false;
165 if (tweenActive.indexOf(this) < 0) tweenActive.push(this);
166 this.callback(this.interp(this.duration));
167 }
168
169 /** True if this tween is in the active list and not paused.
170 * @returns {boolean}

Callers 1

tween.test.mjsFile · 0.80

Calls 1

interpMethod · 0.95

Tested by

no test coverage detected