Socket
Socket
Sign inDemoInstall

p5.tween

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

p5.tween - npm Package Compare versions

Comparing version 1.1.0 to 1.2.0

20

dist/p5.tween.js

@@ -125,5 +125,9 @@ var p5;

this.currentMotionIndex = 0;
if (this.onLoopListener)
this.onLoopListener(this);
}
else {
this.active = false;
if (this.onEndListener)
this.onEndListener(this);
}

@@ -142,2 +146,18 @@ }

}
onEnd(listener) {
if (typeof listener !== 'function') {
console.error("The given event listener for 'onEnd' is not a function. Use .onEnd(function(tween) { /* your code */})");
return;
}
this.onEndListener = listener;
return this;
}
onLoop(listener) {
if (typeof listener !== 'function') {
console.error("The given event listener for 'onLoop' is not a function. Use .onLoop(function(tween) { /* your code */})");
return;
}
this.onLoopListener = listener;
return this;
}
}

@@ -144,0 +164,0 @@ tween.Tween = Tween;

2

dist/p5.tween.min.js

@@ -1,1 +0,1 @@

var p5;!function(t){!function(t){t.EASINGS={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>t*(2-t),easeInOutQuad:t=>t<.5?2*t*t:(4-2*t)*t-1,easeInCubic:t=>t*t*t,easeOutCubic:t=>--t*t*t+1,easeInOutCubic:t=>t<.5?4*t*t*t:(t-1)*(2*t-2)*(2*t-2)+1,easeInQuart:t=>t*t*t*t,easeOutQuart:t=>1- --t*t*t*t,easeInOutQuart:t=>t<.5?8*t*t*t*t:1-8*--t*t*t*t,easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>1+--t*t*t*t*t,easeInOutQuint:t=>t<.5?16*t*t*t*t*t:1+16*--t*t*t*t*t,easeInElastic:t=>(.04-.04/t)*Math.sin(25*t)+1,easeOutElastic:t=>.04*t/--t*Math.sin(25*t),easeInOutElastic:t=>(t-=.5)<0?(.02+.01/t)*Math.sin(50*t):(.02-.01/t)*Math.sin(50*t)+1,easeInSin:t=>1+Math.sin(Math.PI/2*t-Math.PI/2),easeOutSin:t=>Math.sin(Math.PI/2*t),easeInOutSin:t=>(1+Math.sin(Math.PI*t-Math.PI/2))/2}}(t.tween||(t.tween={}))}(p5||(p5={})),function(t){!function(t){t.Tween=class{constructor(t){this.motions=[],this.keyChanges=[],this.active=!1,this.isLoop=!1,this.isPaused=!1,this.currentMotionIndex=0,this.obj=t}resetToStart(){for(let t in this.start)this.obj[t]=this.start[t];this.motionStart=this.createStartObject(this.start)}createStartObject(t){const e={};return this.keyChanges.forEach(i=>e[i]=t[i]),e}addToKeyChangeList(t){this.keyChanges.includes(t)||this.keyChanges.push(t)}interpolation(e,i,s,n="linear"){return(n in t.EASINGS?t.EASINGS[n]:t.EASINGS.linear)(s)*(i-e)+e}addMotion(t,e,i,s="linear"){return this.addToKeyChangeList(t),this.motions.push({actions:[{key:t,target:e}],duration:i,leftTime:0,easing:s}),this}addMotions(t,e,i="linear"){return t.flatMap(t=>t.key).forEach(t=>this.addToKeyChangeList(t)),this.motions.push({actions:t,duration:e,leftTime:0,easing:i}),this}resetMotions(){this.motions=[]}startLoop(){return this.isLoop=!0,this.startTween(),this}startTween(){return this.start=this.createStartObject(this.obj),this.motionStart=this.createStartObject(this.obj),this.currentMotionIndex=0,this.active=!0,this}pause(){return this.isPaused=!0,this}resume(){return this.isPaused=!1,this}restart(){return this.pause(),this.currentMotionIndex=0,this.motions.forEach(t=>t.leftTime=0),this.resetToStart(),this.resume(),this}update(t){if(!this.active||this.isPaused)return;const e=this.motions[this.currentMotionIndex];if(e.leftTime>=e.duration&&(e.leftTime=0,this.motionStart=this.createStartObject(this.obj),this.currentMotionIndex+=1,this.currentMotionIndex>=this.motions.length&&(this.isLoop?(this.resetToStart(),this.currentMotionIndex=0):this.active=!1)),e.leftTime+=t,e.actions)for(let t of e.actions)if(t.key&&!isNaN(t.target)){const i=Math.min(e.leftTime/e.duration,1);this.obj[t.key]=this.interpolation(this.motionStart[t.key],t.target,i,e.easing)}}}}(t.tween||(t.tween={}))}(p5||(p5={})),function(t){!function(t){t.GeometricObjectTween=class extends t.Tween{addMotionTo(t,e,i="linear"){let s=[];t.x&&s.push({key:"x",target:t.x}),t.y&&s.push({key:"y",target:t.y}),t.width&&s.push({key:"width",target:t.width}),t.height&&s.push({key:"height",target:t.height}),t.w&&s.push({key:"w",target:t.w}),t.h&&s.push({key:"h",target:t.h}),t.angle&&s.push({key:"angle",target:t.angle}),t.rotation&&s.push({key:"rotation",target:t.rotation}),super.addMotions(s,e,i)}}}(t.tween||(t.tween={}))}(p5||(p5={})),function(t){!function(e){e.manager=new class{constructor(){this.tweens=[]}getTween(t){return this.tweens.find(e=>e.name===t).tween}addTween(t,i){const s=i||"tween"+this.tweens.length,n=new e.Tween(t);return this.tweens.push({name:s,tween:n}),n}update(t){for(let e of this.tweens)e.tween.update(t)}},t.prototype.registerMethod("pre",()=>e.manager.update(window.deltaTime))}(t.tween||(t.tween={}))}(p5||(p5={}));
var p5;!function(t){!function(t){t.EASINGS={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>t*(2-t),easeInOutQuad:t=>t<.5?2*t*t:(4-2*t)*t-1,easeInCubic:t=>t*t*t,easeOutCubic:t=>--t*t*t+1,easeInOutCubic:t=>t<.5?4*t*t*t:(t-1)*(2*t-2)*(2*t-2)+1,easeInQuart:t=>t*t*t*t,easeOutQuart:t=>1- --t*t*t*t,easeInOutQuart:t=>t<.5?8*t*t*t*t:1-8*--t*t*t*t,easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>1+--t*t*t*t*t,easeInOutQuint:t=>t<.5?16*t*t*t*t*t:1+16*--t*t*t*t*t,easeInElastic:t=>(.04-.04/t)*Math.sin(25*t)+1,easeOutElastic:t=>.04*t/--t*Math.sin(25*t),easeInOutElastic:t=>(t-=.5)<0?(.02+.01/t)*Math.sin(50*t):(.02-.01/t)*Math.sin(50*t)+1,easeInSin:t=>1+Math.sin(Math.PI/2*t-Math.PI/2),easeOutSin:t=>Math.sin(Math.PI/2*t),easeInOutSin:t=>(1+Math.sin(Math.PI*t-Math.PI/2))/2}}(t.tween||(t.tween={}))}(p5||(p5={})),function(t){!function(t){t.Tween=class{constructor(t){this.motions=[],this.keyChanges=[],this.active=!1,this.isLoop=!1,this.isPaused=!1,this.currentMotionIndex=0,this.obj=t}resetToStart(){for(let t in this.start)this.obj[t]=this.start[t];this.motionStart=this.createStartObject(this.start)}createStartObject(t){const e={};return this.keyChanges.forEach(n=>e[n]=t[n]),e}addToKeyChangeList(t){this.keyChanges.includes(t)||this.keyChanges.push(t)}interpolation(e,n,i,s="linear"){return(s in t.EASINGS?t.EASINGS[s]:t.EASINGS.linear)(i)*(n-e)+e}addMotion(t,e,n,i="linear"){return this.addToKeyChangeList(t),this.motions.push({actions:[{key:t,target:e}],duration:n,leftTime:0,easing:i}),this}addMotions(t,e,n="linear"){return t.flatMap(t=>t.key).forEach(t=>this.addToKeyChangeList(t)),this.motions.push({actions:t,duration:e,leftTime:0,easing:n}),this}resetMotions(){this.motions=[]}startLoop(){return this.isLoop=!0,this.startTween(),this}startTween(){return this.start=this.createStartObject(this.obj),this.motionStart=this.createStartObject(this.obj),this.currentMotionIndex=0,this.active=!0,this}pause(){return this.isPaused=!0,this}resume(){return this.isPaused=!1,this}restart(){return this.pause(),this.currentMotionIndex=0,this.motions.forEach(t=>t.leftTime=0),this.resetToStart(),this.resume(),this}update(t){if(!this.active||this.isPaused)return;const e=this.motions[this.currentMotionIndex];if(e.leftTime>=e.duration&&(e.leftTime=0,this.motionStart=this.createStartObject(this.obj),this.currentMotionIndex+=1,this.currentMotionIndex>=this.motions.length&&(this.isLoop?(this.resetToStart(),this.currentMotionIndex=0,this.onLoopListener&&this.onLoopListener(this)):(this.active=!1,this.onEndListener&&this.onEndListener(this)))),e.leftTime+=t,e.actions)for(let t of e.actions)if(t.key&&!isNaN(t.target)){const n=Math.min(e.leftTime/e.duration,1);this.obj[t.key]=this.interpolation(this.motionStart[t.key],t.target,n,e.easing)}}onEnd(t){if("function"==typeof t)return this.onEndListener=t,this;console.error("The given event listener for 'onEnd' is not a function. Use .onEnd(function(tween) { /* your code */})")}onLoop(t){if("function"==typeof t)return this.onLoopListener=t,this;console.error("The given event listener for 'onLoop' is not a function. Use .onLoop(function(tween) { /* your code */})")}}}(t.tween||(t.tween={}))}(p5||(p5={})),function(t){!function(t){t.GeometricObjectTween=class extends t.Tween{addMotionTo(t,e,n="linear"){let i=[];t.x&&i.push({key:"x",target:t.x}),t.y&&i.push({key:"y",target:t.y}),t.width&&i.push({key:"width",target:t.width}),t.height&&i.push({key:"height",target:t.height}),t.w&&i.push({key:"w",target:t.w}),t.h&&i.push({key:"h",target:t.h}),t.angle&&i.push({key:"angle",target:t.angle}),t.rotation&&i.push({key:"rotation",target:t.rotation}),super.addMotions(i,e,n)}}}(t.tween||(t.tween={}))}(p5||(p5={})),function(t){!function(e){e.manager=new class{constructor(){this.tweens=[]}getTween(t){return this.tweens.find(e=>e.name===t).tween}addTween(t,n){const i=n||"tween"+this.tweens.length,s=new e.Tween(t);return this.tweens.push({name:i,tween:s}),s}update(t){for(let e of this.tweens)e.tween.update(t)}},t.prototype.registerMethod("pre",()=>e.manager.update(window.deltaTime))}(t.tween||(t.tween={}))}(p5||(p5={}));

@@ -1,1 +0,1 @@

{"kinds":{"1":"Module","2":"Namespace","32":"Variable","64":"Function","128":"Class","512":"Constructor","1024":"Property","2048":"Method","2097152":"Object literal"},"rows":[{"id":0,"kind":1,"name":"\"Easings\"","url":"modules/_easings_.html","classes":"tsd-kind-module"},{"id":1,"kind":2,"name":"p5","url":"modules/_easings_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"Easings\""},{"id":2,"kind":2,"name":"tween","url":"modules/_easings_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"Easings\".p5"},{"id":3,"kind":2097152,"name":"EASINGS","url":"modules/_easings_.p5.tween.html#easings","classes":"tsd-kind-object-literal tsd-parent-kind-namespace","parent":"\"Easings\".p5.tween"},{"id":4,"kind":64,"name":"linear","url":"modules/_easings_.p5.tween.html#easings.linear","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":5,"kind":64,"name":"easeInQuad","url":"modules/_easings_.p5.tween.html#easings.easeinquad","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":6,"kind":64,"name":"easeOutQuad","url":"modules/_easings_.p5.tween.html#easings.easeoutquad","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":7,"kind":64,"name":"easeInOutQuad","url":"modules/_easings_.p5.tween.html#easings.easeinoutquad","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":8,"kind":64,"name":"easeInCubic","url":"modules/_easings_.p5.tween.html#easings.easeincubic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":9,"kind":64,"name":"easeOutCubic","url":"modules/_easings_.p5.tween.html#easings.easeoutcubic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":10,"kind":64,"name":"easeInOutCubic","url":"modules/_easings_.p5.tween.html#easings.easeinoutcubic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":11,"kind":64,"name":"easeInQuart","url":"modules/_easings_.p5.tween.html#easings.easeinquart","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":12,"kind":64,"name":"easeOutQuart","url":"modules/_easings_.p5.tween.html#easings.easeoutquart","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":13,"kind":64,"name":"easeInOutQuart","url":"modules/_easings_.p5.tween.html#easings.easeinoutquart","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":14,"kind":64,"name":"easeInQuint","url":"modules/_easings_.p5.tween.html#easings.easeinquint","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":15,"kind":64,"name":"easeOutQuint","url":"modules/_easings_.p5.tween.html#easings.easeoutquint","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":16,"kind":64,"name":"easeInOutQuint","url":"modules/_easings_.p5.tween.html#easings.easeinoutquint","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":17,"kind":64,"name":"easeInElastic","url":"modules/_easings_.p5.tween.html#easings.easeinelastic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":18,"kind":64,"name":"easeOutElastic","url":"modules/_easings_.p5.tween.html#easings.easeoutelastic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":19,"kind":64,"name":"easeInOutElastic","url":"modules/_easings_.p5.tween.html#easings.easeinoutelastic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":20,"kind":64,"name":"easeInSin","url":"modules/_easings_.p5.tween.html#easings.easeinsin","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":21,"kind":64,"name":"easeOutSin","url":"modules/_easings_.p5.tween.html#easings.easeoutsin","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":22,"kind":64,"name":"easeInOutSin","url":"modules/_easings_.p5.tween.html#easings.easeinoutsin","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":23,"kind":1,"name":"\"GeometricObjectTween\"","url":"modules/_geometricobjecttween_.html","classes":"tsd-kind-module"},{"id":24,"kind":2,"name":"p5","url":"modules/_geometricobjecttween_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"GeometricObjectTween\""},{"id":25,"kind":2,"name":"tween","url":"modules/_geometricobjecttween_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"GeometricObjectTween\".p5"},{"id":26,"kind":128,"name":"GeometricObjectTween","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html","classes":"tsd-kind-class tsd-parent-kind-namespace","parent":"\"GeometricObjectTween\".p5.tween"},{"id":27,"kind":2048,"name":"addMotionTo","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#addmotionto","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":28,"kind":512,"name":"constructor","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":29,"kind":2048,"name":"addMotion","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#addmotion","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":30,"kind":2048,"name":"addMotions","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#addmotions","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":31,"kind":2048,"name":"resetMotions","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#resetmotions","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":32,"kind":2048,"name":"startLoop","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#startloop","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":33,"kind":2048,"name":"startTween","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#starttween","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":34,"kind":2048,"name":"pause","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#pause","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":35,"kind":2048,"name":"resume","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#resume","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":36,"kind":2048,"name":"restart","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#restart","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":37,"kind":2048,"name":"update","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#update","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":38,"kind":1,"name":"\"Tween\"","url":"modules/_tween_.html","classes":"tsd-kind-module"},{"id":39,"kind":2,"name":"p5","url":"modules/_tween_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"Tween\""},{"id":40,"kind":2,"name":"tween","url":"modules/_tween_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"Tween\".p5"},{"id":41,"kind":128,"name":"Tween","url":"classes/_tween_.p5.tween.tween.html","classes":"tsd-kind-class tsd-parent-kind-namespace","parent":"\"Tween\".p5.tween"},{"id":42,"kind":1024,"name":"obj","url":"classes/_tween_.p5.tween.tween.html#obj","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":43,"kind":1024,"name":"start","url":"classes/_tween_.p5.tween.tween.html#start","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":44,"kind":1024,"name":"motionStart","url":"classes/_tween_.p5.tween.tween.html#motionstart","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":45,"kind":1024,"name":"motions","url":"classes/_tween_.p5.tween.tween.html#motions","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":46,"kind":1024,"name":"keyChanges","url":"classes/_tween_.p5.tween.tween.html#keychanges","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":47,"kind":1024,"name":"active","url":"classes/_tween_.p5.tween.tween.html#active","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":48,"kind":1024,"name":"isLoop","url":"classes/_tween_.p5.tween.tween.html#isloop","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":49,"kind":1024,"name":"isPaused","url":"classes/_tween_.p5.tween.tween.html#ispaused","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":50,"kind":1024,"name":"currentMotionIndex","url":"classes/_tween_.p5.tween.tween.html#currentmotionindex","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":51,"kind":512,"name":"constructor","url":"classes/_tween_.p5.tween.tween.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":52,"kind":2048,"name":"resetToStart","url":"classes/_tween_.p5.tween.tween.html#resettostart","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":53,"kind":2048,"name":"createStartObject","url":"classes/_tween_.p5.tween.tween.html#createstartobject","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":54,"kind":2048,"name":"addToKeyChangeList","url":"classes/_tween_.p5.tween.tween.html#addtokeychangelist","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":55,"kind":2048,"name":"interpolation","url":"classes/_tween_.p5.tween.tween.html#interpolation","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":56,"kind":2048,"name":"addMotion","url":"classes/_tween_.p5.tween.tween.html#addmotion","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":57,"kind":2048,"name":"addMotions","url":"classes/_tween_.p5.tween.tween.html#addmotions","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":58,"kind":2048,"name":"resetMotions","url":"classes/_tween_.p5.tween.tween.html#resetmotions","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":59,"kind":2048,"name":"startLoop","url":"classes/_tween_.p5.tween.tween.html#startloop","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":60,"kind":2048,"name":"startTween","url":"classes/_tween_.p5.tween.tween.html#starttween","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":61,"kind":2048,"name":"pause","url":"classes/_tween_.p5.tween.tween.html#pause","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":62,"kind":2048,"name":"resume","url":"classes/_tween_.p5.tween.tween.html#resume","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":63,"kind":2048,"name":"restart","url":"classes/_tween_.p5.tween.tween.html#restart","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":64,"kind":2048,"name":"update","url":"classes/_tween_.p5.tween.tween.html#update","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":65,"kind":1,"name":"\"TweenManager\"","url":"modules/_tweenmanager_.html","classes":"tsd-kind-module"},{"id":66,"kind":2,"name":"p5","url":"modules/_tweenmanager_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"TweenManager\""},{"id":67,"kind":2,"name":"tween","url":"modules/_tweenmanager_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"TweenManager\".p5"},{"id":68,"kind":128,"name":"TweenManager","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html","classes":"tsd-kind-class tsd-parent-kind-namespace tsd-is-not-exported","parent":"\"TweenManager\".p5.tween"},{"id":69,"kind":1024,"name":"tweens","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#tweens","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":70,"kind":2048,"name":"getTween","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#gettween","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":71,"kind":2048,"name":"addTween","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#addtween","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":72,"kind":2048,"name":"update","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#update","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":73,"kind":32,"name":"manager","url":"modules/_tweenmanager_.p5.tween.html#manager","classes":"tsd-kind-variable tsd-parent-kind-namespace","parent":"\"TweenManager\".p5.tween"}],"index":{"version":"2.3.9","fields":["name","parent"],"fieldVectors":[["name/0",[0,30.647]],["parent/0",[]],["name/1",[1,28.134]],["parent/1",[0,2.995]],["name/2",[2,23.026]],["parent/2",[3,3.823]],["name/3",[0,30.647]],["parent/3",[4,3.823]],["name/4",[5,39.12]],["parent/4",[6,1.316]],["name/5",[7,39.12]],["parent/5",[6,1.316]],["name/6",[8,39.12]],["parent/6",[6,1.316]],["name/7",[9,39.12]],["parent/7",[6,1.316]],["name/8",[10,39.12]],["parent/8",[6,1.316]],["name/9",[11,39.12]],["parent/9",[6,1.316]],["name/10",[12,39.12]],["parent/10",[6,1.316]],["name/11",[13,39.12]],["parent/11",[6,1.316]],["name/12",[14,39.12]],["parent/12",[6,1.316]],["name/13",[15,39.12]],["parent/13",[6,1.316]],["name/14",[16,39.12]],["parent/14",[6,1.316]],["name/15",[17,39.12]],["parent/15",[6,1.316]],["name/16",[18,39.12]],["parent/16",[6,1.316]],["name/17",[19,39.12]],["parent/17",[6,1.316]],["name/18",[20,39.12]],["parent/18",[6,1.316]],["name/19",[21,39.12]],["parent/19",[6,1.316]],["name/20",[22,39.12]],["parent/20",[6,1.316]],["name/21",[23,39.12]],["parent/21",[6,1.316]],["name/22",[24,39.12]],["parent/22",[6,1.316]],["name/23",[25,30.647]],["parent/23",[]],["name/24",[1,28.134]],["parent/24",[25,2.995]],["name/25",[2,23.026]],["parent/25",[26,3.823]],["name/26",[25,30.647]],["parent/26",[27,3.823]],["name/27",[28,39.12]],["parent/27",[29,1.832]],["name/28",[30,34.012]],["parent/28",[29,1.832]],["name/29",[31,34.012]],["parent/29",[29,1.832]],["name/30",[32,34.012]],["parent/30",[29,1.832]],["name/31",[33,34.012]],["parent/31",[29,1.832]],["name/32",[34,34.012]],["parent/32",[29,1.832]],["name/33",[35,34.012]],["parent/33",[29,1.832]],["name/34",[36,34.012]],["parent/34",[29,1.832]],["name/35",[37,34.012]],["parent/35",[29,1.832]],["name/36",[38,34.012]],["parent/36",[29,1.832]],["name/37",[39,30.647]],["parent/37",[29,1.832]],["name/38",[2,23.026]],["parent/38",[]],["name/39",[1,28.134]],["parent/39",[2,2.25]],["name/40",[2,23.026]],["parent/40",[40,3.823]],["name/41",[2,23.026]],["parent/41",[41,3.823]],["name/42",[42,39.12]],["parent/42",[43,1.134]],["name/43",[44,39.12]],["parent/43",[43,1.134]],["name/44",[45,39.12]],["parent/44",[43,1.134]],["name/45",[46,39.12]],["parent/45",[43,1.134]],["name/46",[47,39.12]],["parent/46",[43,1.134]],["name/47",[48,39.12]],["parent/47",[43,1.134]],["name/48",[49,39.12]],["parent/48",[43,1.134]],["name/49",[50,39.12]],["parent/49",[43,1.134]],["name/50",[51,39.12]],["parent/50",[43,1.134]],["name/51",[30,34.012]],["parent/51",[43,1.134]],["name/52",[52,39.12]],["parent/52",[43,1.134]],["name/53",[53,39.12]],["parent/53",[43,1.134]],["name/54",[54,39.12]],["parent/54",[43,1.134]],["name/55",[55,39.12]],["parent/55",[43,1.134]],["name/56",[31,34.012]],["parent/56",[43,1.134]],["name/57",[32,34.012]],["parent/57",[43,1.134]],["name/58",[33,34.012]],["parent/58",[43,1.134]],["name/59",[34,34.012]],["parent/59",[43,1.134]],["name/60",[35,34.012]],["parent/60",[43,1.134]],["name/61",[36,34.012]],["parent/61",[43,1.134]],["name/62",[37,34.012]],["parent/62",[43,1.134]],["name/63",[38,34.012]],["parent/63",[43,1.134]],["name/64",[39,30.647]],["parent/64",[43,1.134]],["name/65",[56,30.647]],["parent/65",[]],["name/66",[1,28.134]],["parent/66",[56,2.995]],["name/67",[2,23.026]],["parent/67",[57,3.823]],["name/68",[56,30.647]],["parent/68",[58,3.324]],["name/69",[59,39.12]],["parent/69",[60,2.749]],["name/70",[61,39.12]],["parent/70",[60,2.749]],["name/71",[62,39.12]],["parent/71",[60,2.749]],["name/72",[39,30.647]],["parent/72",[60,2.749]],["name/73",[63,39.12]],["parent/73",[58,3.324]]],"invertedIndex":[["active",{"_index":48,"name":{"47":{}},"parent":{}}],["addmotion",{"_index":31,"name":{"29":{},"56":{}},"parent":{}}],["addmotions",{"_index":32,"name":{"30":{},"57":{}},"parent":{}}],["addmotionto",{"_index":28,"name":{"27":{}},"parent":{}}],["addtokeychangelist",{"_index":54,"name":{"54":{}},"parent":{}}],["addtween",{"_index":62,"name":{"71":{}},"parent":{}}],["constructor",{"_index":30,"name":{"28":{},"51":{}},"parent":{}}],["createstartobject",{"_index":53,"name":{"53":{}},"parent":{}}],["currentmotionindex",{"_index":51,"name":{"50":{}},"parent":{}}],["easeincubic",{"_index":10,"name":{"8":{}},"parent":{}}],["easeinelastic",{"_index":19,"name":{"17":{}},"parent":{}}],["easeinoutcubic",{"_index":12,"name":{"10":{}},"parent":{}}],["easeinoutelastic",{"_index":21,"name":{"19":{}},"parent":{}}],["easeinoutquad",{"_index":9,"name":{"7":{}},"parent":{}}],["easeinoutquart",{"_index":15,"name":{"13":{}},"parent":{}}],["easeinoutquint",{"_index":18,"name":{"16":{}},"parent":{}}],["easeinoutsin",{"_index":24,"name":{"22":{}},"parent":{}}],["easeinquad",{"_index":7,"name":{"5":{}},"parent":{}}],["easeinquart",{"_index":13,"name":{"11":{}},"parent":{}}],["easeinquint",{"_index":16,"name":{"14":{}},"parent":{}}],["easeinsin",{"_index":22,"name":{"20":{}},"parent":{}}],["easeoutcubic",{"_index":11,"name":{"9":{}},"parent":{}}],["easeoutelastic",{"_index":20,"name":{"18":{}},"parent":{}}],["easeoutquad",{"_index":8,"name":{"6":{}},"parent":{}}],["easeoutquart",{"_index":14,"name":{"12":{}},"parent":{}}],["easeoutquint",{"_index":17,"name":{"15":{}},"parent":{}}],["easeoutsin",{"_index":23,"name":{"21":{}},"parent":{}}],["easings",{"_index":0,"name":{"0":{},"3":{}},"parent":{"1":{}}}],["easings\".p5",{"_index":3,"name":{},"parent":{"2":{}}}],["easings\".p5.tween",{"_index":4,"name":{},"parent":{"3":{}}}],["easings\".p5.tween.easings",{"_index":6,"name":{},"parent":{"4":{},"5":{},"6":{},"7":{},"8":{},"9":{},"10":{},"11":{},"12":{},"13":{},"14":{},"15":{},"16":{},"17":{},"18":{},"19":{},"20":{},"21":{},"22":{}}}],["geometricobjecttween",{"_index":25,"name":{"23":{},"26":{}},"parent":{"24":{}}}],["geometricobjecttween\".p5",{"_index":26,"name":{},"parent":{"25":{}}}],["geometricobjecttween\".p5.tween",{"_index":27,"name":{},"parent":{"26":{}}}],["geometricobjecttween\".p5.tween.geometricobjecttween",{"_index":29,"name":{},"parent":{"27":{},"28":{},"29":{},"30":{},"31":{},"32":{},"33":{},"34":{},"35":{},"36":{},"37":{}}}],["gettween",{"_index":61,"name":{"70":{}},"parent":{}}],["interpolation",{"_index":55,"name":{"55":{}},"parent":{}}],["isloop",{"_index":49,"name":{"48":{}},"parent":{}}],["ispaused",{"_index":50,"name":{"49":{}},"parent":{}}],["keychanges",{"_index":47,"name":{"46":{}},"parent":{}}],["linear",{"_index":5,"name":{"4":{}},"parent":{}}],["manager",{"_index":63,"name":{"73":{}},"parent":{}}],["motions",{"_index":46,"name":{"45":{}},"parent":{}}],["motionstart",{"_index":45,"name":{"44":{}},"parent":{}}],["obj",{"_index":42,"name":{"42":{}},"parent":{}}],["p5",{"_index":1,"name":{"1":{},"24":{},"39":{},"66":{}},"parent":{}}],["pause",{"_index":36,"name":{"34":{},"61":{}},"parent":{}}],["resetmotions",{"_index":33,"name":{"31":{},"58":{}},"parent":{}}],["resettostart",{"_index":52,"name":{"52":{}},"parent":{}}],["restart",{"_index":38,"name":{"36":{},"63":{}},"parent":{}}],["resume",{"_index":37,"name":{"35":{},"62":{}},"parent":{}}],["start",{"_index":44,"name":{"43":{}},"parent":{}}],["startloop",{"_index":34,"name":{"32":{},"59":{}},"parent":{}}],["starttween",{"_index":35,"name":{"33":{},"60":{}},"parent":{}}],["tween",{"_index":2,"name":{"2":{},"25":{},"38":{},"40":{},"41":{},"67":{}},"parent":{"39":{}}}],["tween\".p5",{"_index":40,"name":{},"parent":{"40":{}}}],["tween\".p5.tween",{"_index":41,"name":{},"parent":{"41":{}}}],["tween\".p5.tween.tween",{"_index":43,"name":{},"parent":{"42":{},"43":{},"44":{},"45":{},"46":{},"47":{},"48":{},"49":{},"50":{},"51":{},"52":{},"53":{},"54":{},"55":{},"56":{},"57":{},"58":{},"59":{},"60":{},"61":{},"62":{},"63":{},"64":{}}}],["tweenmanager",{"_index":56,"name":{"65":{},"68":{}},"parent":{"66":{}}}],["tweenmanager\".p5",{"_index":57,"name":{},"parent":{"67":{}}}],["tweenmanager\".p5.tween",{"_index":58,"name":{},"parent":{"68":{},"73":{}}}],["tweenmanager\".p5.tween.tweenmanager",{"_index":60,"name":{},"parent":{"69":{},"70":{},"71":{},"72":{}}}],["tweens",{"_index":59,"name":{"69":{}},"parent":{}}],["update",{"_index":39,"name":{"37":{},"64":{},"72":{}},"parent":{}}]],"pipeline":[]}}
{"kinds":{"1":"Module","2":"Namespace","32":"Variable","64":"Function","128":"Class","512":"Constructor","1024":"Property","2048":"Method","2097152":"Object literal"},"rows":[{"id":0,"kind":1,"name":"\"Easings\"","url":"modules/_easings_.html","classes":"tsd-kind-module"},{"id":1,"kind":2,"name":"p5","url":"modules/_easings_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"Easings\""},{"id":2,"kind":2,"name":"tween","url":"modules/_easings_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"Easings\".p5"},{"id":3,"kind":2097152,"name":"EASINGS","url":"modules/_easings_.p5.tween.html#easings","classes":"tsd-kind-object-literal tsd-parent-kind-namespace","parent":"\"Easings\".p5.tween"},{"id":4,"kind":64,"name":"linear","url":"modules/_easings_.p5.tween.html#easings.linear","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":5,"kind":64,"name":"easeInQuad","url":"modules/_easings_.p5.tween.html#easings.easeinquad","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":6,"kind":64,"name":"easeOutQuad","url":"modules/_easings_.p5.tween.html#easings.easeoutquad","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":7,"kind":64,"name":"easeInOutQuad","url":"modules/_easings_.p5.tween.html#easings.easeinoutquad","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":8,"kind":64,"name":"easeInCubic","url":"modules/_easings_.p5.tween.html#easings.easeincubic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":9,"kind":64,"name":"easeOutCubic","url":"modules/_easings_.p5.tween.html#easings.easeoutcubic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":10,"kind":64,"name":"easeInOutCubic","url":"modules/_easings_.p5.tween.html#easings.easeinoutcubic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":11,"kind":64,"name":"easeInQuart","url":"modules/_easings_.p5.tween.html#easings.easeinquart","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":12,"kind":64,"name":"easeOutQuart","url":"modules/_easings_.p5.tween.html#easings.easeoutquart","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":13,"kind":64,"name":"easeInOutQuart","url":"modules/_easings_.p5.tween.html#easings.easeinoutquart","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":14,"kind":64,"name":"easeInQuint","url":"modules/_easings_.p5.tween.html#easings.easeinquint","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":15,"kind":64,"name":"easeOutQuint","url":"modules/_easings_.p5.tween.html#easings.easeoutquint","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":16,"kind":64,"name":"easeInOutQuint","url":"modules/_easings_.p5.tween.html#easings.easeinoutquint","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":17,"kind":64,"name":"easeInElastic","url":"modules/_easings_.p5.tween.html#easings.easeinelastic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":18,"kind":64,"name":"easeOutElastic","url":"modules/_easings_.p5.tween.html#easings.easeoutelastic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":19,"kind":64,"name":"easeInOutElastic","url":"modules/_easings_.p5.tween.html#easings.easeinoutelastic","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":20,"kind":64,"name":"easeInSin","url":"modules/_easings_.p5.tween.html#easings.easeinsin","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":21,"kind":64,"name":"easeOutSin","url":"modules/_easings_.p5.tween.html#easings.easeoutsin","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":22,"kind":64,"name":"easeInOutSin","url":"modules/_easings_.p5.tween.html#easings.easeinoutsin","classes":"tsd-kind-function tsd-parent-kind-object-literal","parent":"\"Easings\".p5.tween.EASINGS"},{"id":23,"kind":1,"name":"\"GeometricObjectTween\"","url":"modules/_geometricobjecttween_.html","classes":"tsd-kind-module"},{"id":24,"kind":2,"name":"p5","url":"modules/_geometricobjecttween_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"GeometricObjectTween\""},{"id":25,"kind":2,"name":"tween","url":"modules/_geometricobjecttween_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"GeometricObjectTween\".p5"},{"id":26,"kind":128,"name":"GeometricObjectTween","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html","classes":"tsd-kind-class tsd-parent-kind-namespace","parent":"\"GeometricObjectTween\".p5.tween"},{"id":27,"kind":2048,"name":"addMotionTo","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#addmotionto","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":28,"kind":512,"name":"constructor","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":29,"kind":2048,"name":"addMotion","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#addmotion","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":30,"kind":2048,"name":"addMotions","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#addmotions","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":31,"kind":2048,"name":"resetMotions","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#resetmotions","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":32,"kind":2048,"name":"startLoop","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#startloop","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":33,"kind":2048,"name":"startTween","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#starttween","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":34,"kind":2048,"name":"pause","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#pause","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":35,"kind":2048,"name":"resume","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#resume","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":36,"kind":2048,"name":"restart","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#restart","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":37,"kind":2048,"name":"update","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#update","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":38,"kind":2048,"name":"onEnd","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#onend","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":39,"kind":2048,"name":"onLoop","url":"classes/_geometricobjecttween_.p5.tween.geometricobjecttween.html#onloop","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-inherited","parent":"\"GeometricObjectTween\".p5.tween.GeometricObjectTween"},{"id":40,"kind":1,"name":"\"Tween\"","url":"modules/_tween_.html","classes":"tsd-kind-module"},{"id":41,"kind":2,"name":"p5","url":"modules/_tween_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"Tween\""},{"id":42,"kind":2,"name":"tween","url":"modules/_tween_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"Tween\".p5"},{"id":43,"kind":128,"name":"Tween","url":"classes/_tween_.p5.tween.tween.html","classes":"tsd-kind-class tsd-parent-kind-namespace","parent":"\"Tween\".p5.tween"},{"id":44,"kind":1024,"name":"obj","url":"classes/_tween_.p5.tween.tween.html#obj","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":45,"kind":1024,"name":"start","url":"classes/_tween_.p5.tween.tween.html#start","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":46,"kind":1024,"name":"motionStart","url":"classes/_tween_.p5.tween.tween.html#motionstart","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":47,"kind":1024,"name":"motions","url":"classes/_tween_.p5.tween.tween.html#motions","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":48,"kind":1024,"name":"keyChanges","url":"classes/_tween_.p5.tween.tween.html#keychanges","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":49,"kind":1024,"name":"active","url":"classes/_tween_.p5.tween.tween.html#active","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":50,"kind":1024,"name":"isLoop","url":"classes/_tween_.p5.tween.tween.html#isloop","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":51,"kind":1024,"name":"isPaused","url":"classes/_tween_.p5.tween.tween.html#ispaused","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":52,"kind":1024,"name":"currentMotionIndex","url":"classes/_tween_.p5.tween.tween.html#currentmotionindex","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":53,"kind":1024,"name":"onEndListener","url":"classes/_tween_.p5.tween.tween.html#onendlistener","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":54,"kind":1024,"name":"onLoopListener","url":"classes/_tween_.p5.tween.tween.html#onlooplistener","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":55,"kind":512,"name":"constructor","url":"classes/_tween_.p5.tween.tween.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":56,"kind":2048,"name":"resetToStart","url":"classes/_tween_.p5.tween.tween.html#resettostart","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":57,"kind":2048,"name":"createStartObject","url":"classes/_tween_.p5.tween.tween.html#createstartobject","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":58,"kind":2048,"name":"addToKeyChangeList","url":"classes/_tween_.p5.tween.tween.html#addtokeychangelist","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":59,"kind":2048,"name":"interpolation","url":"classes/_tween_.p5.tween.tween.html#interpolation","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"\"Tween\".p5.tween.Tween"},{"id":60,"kind":2048,"name":"addMotion","url":"classes/_tween_.p5.tween.tween.html#addmotion","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":61,"kind":2048,"name":"addMotions","url":"classes/_tween_.p5.tween.tween.html#addmotions","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":62,"kind":2048,"name":"resetMotions","url":"classes/_tween_.p5.tween.tween.html#resetmotions","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":63,"kind":2048,"name":"startLoop","url":"classes/_tween_.p5.tween.tween.html#startloop","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":64,"kind":2048,"name":"startTween","url":"classes/_tween_.p5.tween.tween.html#starttween","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":65,"kind":2048,"name":"pause","url":"classes/_tween_.p5.tween.tween.html#pause","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":66,"kind":2048,"name":"resume","url":"classes/_tween_.p5.tween.tween.html#resume","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":67,"kind":2048,"name":"restart","url":"classes/_tween_.p5.tween.tween.html#restart","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":68,"kind":2048,"name":"update","url":"classes/_tween_.p5.tween.tween.html#update","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":69,"kind":2048,"name":"onEnd","url":"classes/_tween_.p5.tween.tween.html#onend","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":70,"kind":2048,"name":"onLoop","url":"classes/_tween_.p5.tween.tween.html#onloop","classes":"tsd-kind-method tsd-parent-kind-class","parent":"\"Tween\".p5.tween.Tween"},{"id":71,"kind":1,"name":"\"TweenManager\"","url":"modules/_tweenmanager_.html","classes":"tsd-kind-module"},{"id":72,"kind":2,"name":"p5","url":"modules/_tweenmanager_.p5.html","classes":"tsd-kind-namespace tsd-parent-kind-module","parent":"\"TweenManager\""},{"id":73,"kind":2,"name":"tween","url":"modules/_tweenmanager_.p5.tween.html","classes":"tsd-kind-namespace tsd-parent-kind-namespace","parent":"\"TweenManager\".p5"},{"id":74,"kind":128,"name":"TweenManager","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html","classes":"tsd-kind-class tsd-parent-kind-namespace tsd-is-not-exported","parent":"\"TweenManager\".p5.tween"},{"id":75,"kind":1024,"name":"tweens","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#tweens","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":76,"kind":2048,"name":"getTween","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#gettween","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":77,"kind":2048,"name":"addTween","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#addtween","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":78,"kind":2048,"name":"update","url":"classes/_tweenmanager_.p5.tween.tweenmanager.html#update","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-not-exported","parent":"\"TweenManager\".p5.tween.TweenManager"},{"id":79,"kind":32,"name":"manager","url":"modules/_tweenmanager_.p5.tween.html#manager","classes":"tsd-kind-variable tsd-parent-kind-namespace","parent":"\"TweenManager\".p5.tween"}],"index":{"version":"2.3.9","fields":["name","parent"],"fieldVectors":[["name/0",[0,31.417]],["parent/0",[]],["name/1",[1,28.904]],["parent/1",[0,3.075]],["name/2",[2,23.795]],["parent/2",[3,3.905]],["name/3",[0,31.417]],["parent/3",[4,3.905]],["name/4",[5,39.89]],["parent/4",[6,1.394]],["name/5",[7,39.89]],["parent/5",[6,1.394]],["name/6",[8,39.89]],["parent/6",[6,1.394]],["name/7",[9,39.89]],["parent/7",[6,1.394]],["name/8",[10,39.89]],["parent/8",[6,1.394]],["name/9",[11,39.89]],["parent/9",[6,1.394]],["name/10",[12,39.89]],["parent/10",[6,1.394]],["name/11",[13,39.89]],["parent/11",[6,1.394]],["name/12",[14,39.89]],["parent/12",[6,1.394]],["name/13",[15,39.89]],["parent/13",[6,1.394]],["name/14",[16,39.89]],["parent/14",[6,1.394]],["name/15",[17,39.89]],["parent/15",[6,1.394]],["name/16",[18,39.89]],["parent/16",[6,1.394]],["name/17",[19,39.89]],["parent/17",[6,1.394]],["name/18",[20,39.89]],["parent/18",[6,1.394]],["name/19",[21,39.89]],["parent/19",[6,1.394]],["name/20",[22,39.89]],["parent/20",[6,1.394]],["name/21",[23,39.89]],["parent/21",[6,1.394]],["name/22",[24,39.89]],["parent/22",[6,1.394]],["name/23",[25,31.417]],["parent/23",[]],["name/24",[1,28.904]],["parent/24",[25,3.075]],["name/25",[2,23.795]],["parent/25",[26,3.905]],["name/26",[25,31.417]],["parent/26",[27,3.905]],["name/27",[28,39.89]],["parent/27",[29,1.754]],["name/28",[30,34.782]],["parent/28",[29,1.754]],["name/29",[31,34.782]],["parent/29",[29,1.754]],["name/30",[32,34.782]],["parent/30",[29,1.754]],["name/31",[33,34.782]],["parent/31",[29,1.754]],["name/32",[34,34.782]],["parent/32",[29,1.754]],["name/33",[35,34.782]],["parent/33",[29,1.754]],["name/34",[36,34.782]],["parent/34",[29,1.754]],["name/35",[37,34.782]],["parent/35",[29,1.754]],["name/36",[38,34.782]],["parent/36",[29,1.754]],["name/37",[39,31.417]],["parent/37",[29,1.754]],["name/38",[40,34.782]],["parent/38",[29,1.754]],["name/39",[41,34.782]],["parent/39",[29,1.754]],["name/40",[2,23.795]],["parent/40",[]],["name/41",[1,28.904]],["parent/41",[2,2.329]],["name/42",[2,23.795]],["parent/42",[42,3.905]],["name/43",[2,23.795]],["parent/43",[43,3.905]],["name/44",[44,39.89]],["parent/44",[45,1.057]],["name/45",[46,39.89]],["parent/45",[45,1.057]],["name/46",[47,39.89]],["parent/46",[45,1.057]],["name/47",[48,39.89]],["parent/47",[45,1.057]],["name/48",[49,39.89]],["parent/48",[45,1.057]],["name/49",[50,39.89]],["parent/49",[45,1.057]],["name/50",[51,39.89]],["parent/50",[45,1.057]],["name/51",[52,39.89]],["parent/51",[45,1.057]],["name/52",[53,39.89]],["parent/52",[45,1.057]],["name/53",[54,39.89]],["parent/53",[45,1.057]],["name/54",[55,39.89]],["parent/54",[45,1.057]],["name/55",[30,34.782]],["parent/55",[45,1.057]],["name/56",[56,39.89]],["parent/56",[45,1.057]],["name/57",[57,39.89]],["parent/57",[45,1.057]],["name/58",[58,39.89]],["parent/58",[45,1.057]],["name/59",[59,39.89]],["parent/59",[45,1.057]],["name/60",[31,34.782]],["parent/60",[45,1.057]],["name/61",[32,34.782]],["parent/61",[45,1.057]],["name/62",[33,34.782]],["parent/62",[45,1.057]],["name/63",[34,34.782]],["parent/63",[45,1.057]],["name/64",[35,34.782]],["parent/64",[45,1.057]],["name/65",[36,34.782]],["parent/65",[45,1.057]],["name/66",[37,34.782]],["parent/66",[45,1.057]],["name/67",[38,34.782]],["parent/67",[45,1.057]],["name/68",[39,31.417]],["parent/68",[45,1.057]],["name/69",[40,34.782]],["parent/69",[45,1.057]],["name/70",[41,34.782]],["parent/70",[45,1.057]],["name/71",[60,31.417]],["parent/71",[]],["name/72",[1,28.904]],["parent/72",[60,3.075]],["name/73",[2,23.795]],["parent/73",[61,3.905]],["name/74",[60,31.417]],["parent/74",[62,3.405]],["name/75",[63,39.89]],["parent/75",[64,2.829]],["name/76",[65,39.89]],["parent/76",[64,2.829]],["name/77",[66,39.89]],["parent/77",[64,2.829]],["name/78",[39,31.417]],["parent/78",[64,2.829]],["name/79",[67,39.89]],["parent/79",[62,3.405]]],"invertedIndex":[["active",{"_index":50,"name":{"49":{}},"parent":{}}],["addmotion",{"_index":31,"name":{"29":{},"60":{}},"parent":{}}],["addmotions",{"_index":32,"name":{"30":{},"61":{}},"parent":{}}],["addmotionto",{"_index":28,"name":{"27":{}},"parent":{}}],["addtokeychangelist",{"_index":58,"name":{"58":{}},"parent":{}}],["addtween",{"_index":66,"name":{"77":{}},"parent":{}}],["constructor",{"_index":30,"name":{"28":{},"55":{}},"parent":{}}],["createstartobject",{"_index":57,"name":{"57":{}},"parent":{}}],["currentmotionindex",{"_index":53,"name":{"52":{}},"parent":{}}],["easeincubic",{"_index":10,"name":{"8":{}},"parent":{}}],["easeinelastic",{"_index":19,"name":{"17":{}},"parent":{}}],["easeinoutcubic",{"_index":12,"name":{"10":{}},"parent":{}}],["easeinoutelastic",{"_index":21,"name":{"19":{}},"parent":{}}],["easeinoutquad",{"_index":9,"name":{"7":{}},"parent":{}}],["easeinoutquart",{"_index":15,"name":{"13":{}},"parent":{}}],["easeinoutquint",{"_index":18,"name":{"16":{}},"parent":{}}],["easeinoutsin",{"_index":24,"name":{"22":{}},"parent":{}}],["easeinquad",{"_index":7,"name":{"5":{}},"parent":{}}],["easeinquart",{"_index":13,"name":{"11":{}},"parent":{}}],["easeinquint",{"_index":16,"name":{"14":{}},"parent":{}}],["easeinsin",{"_index":22,"name":{"20":{}},"parent":{}}],["easeoutcubic",{"_index":11,"name":{"9":{}},"parent":{}}],["easeoutelastic",{"_index":20,"name":{"18":{}},"parent":{}}],["easeoutquad",{"_index":8,"name":{"6":{}},"parent":{}}],["easeoutquart",{"_index":14,"name":{"12":{}},"parent":{}}],["easeoutquint",{"_index":17,"name":{"15":{}},"parent":{}}],["easeoutsin",{"_index":23,"name":{"21":{}},"parent":{}}],["easings",{"_index":0,"name":{"0":{},"3":{}},"parent":{"1":{}}}],["easings\".p5",{"_index":3,"name":{},"parent":{"2":{}}}],["easings\".p5.tween",{"_index":4,"name":{},"parent":{"3":{}}}],["easings\".p5.tween.easings",{"_index":6,"name":{},"parent":{"4":{},"5":{},"6":{},"7":{},"8":{},"9":{},"10":{},"11":{},"12":{},"13":{},"14":{},"15":{},"16":{},"17":{},"18":{},"19":{},"20":{},"21":{},"22":{}}}],["geometricobjecttween",{"_index":25,"name":{"23":{},"26":{}},"parent":{"24":{}}}],["geometricobjecttween\".p5",{"_index":26,"name":{},"parent":{"25":{}}}],["geometricobjecttween\".p5.tween",{"_index":27,"name":{},"parent":{"26":{}}}],["geometricobjecttween\".p5.tween.geometricobjecttween",{"_index":29,"name":{},"parent":{"27":{},"28":{},"29":{},"30":{},"31":{},"32":{},"33":{},"34":{},"35":{},"36":{},"37":{},"38":{},"39":{}}}],["gettween",{"_index":65,"name":{"76":{}},"parent":{}}],["interpolation",{"_index":59,"name":{"59":{}},"parent":{}}],["isloop",{"_index":51,"name":{"50":{}},"parent":{}}],["ispaused",{"_index":52,"name":{"51":{}},"parent":{}}],["keychanges",{"_index":49,"name":{"48":{}},"parent":{}}],["linear",{"_index":5,"name":{"4":{}},"parent":{}}],["manager",{"_index":67,"name":{"79":{}},"parent":{}}],["motions",{"_index":48,"name":{"47":{}},"parent":{}}],["motionstart",{"_index":47,"name":{"46":{}},"parent":{}}],["obj",{"_index":44,"name":{"44":{}},"parent":{}}],["onend",{"_index":40,"name":{"38":{},"69":{}},"parent":{}}],["onendlistener",{"_index":54,"name":{"53":{}},"parent":{}}],["onloop",{"_index":41,"name":{"39":{},"70":{}},"parent":{}}],["onlooplistener",{"_index":55,"name":{"54":{}},"parent":{}}],["p5",{"_index":1,"name":{"1":{},"24":{},"41":{},"72":{}},"parent":{}}],["pause",{"_index":36,"name":{"34":{},"65":{}},"parent":{}}],["resetmotions",{"_index":33,"name":{"31":{},"62":{}},"parent":{}}],["resettostart",{"_index":56,"name":{"56":{}},"parent":{}}],["restart",{"_index":38,"name":{"36":{},"67":{}},"parent":{}}],["resume",{"_index":37,"name":{"35":{},"66":{}},"parent":{}}],["start",{"_index":46,"name":{"45":{}},"parent":{}}],["startloop",{"_index":34,"name":{"32":{},"63":{}},"parent":{}}],["starttween",{"_index":35,"name":{"33":{},"64":{}},"parent":{}}],["tween",{"_index":2,"name":{"2":{},"25":{},"40":{},"42":{},"43":{},"73":{}},"parent":{"41":{}}}],["tween\".p5",{"_index":42,"name":{},"parent":{"42":{}}}],["tween\".p5.tween",{"_index":43,"name":{},"parent":{"43":{}}}],["tween\".p5.tween.tween",{"_index":45,"name":{},"parent":{"44":{},"45":{},"46":{},"47":{},"48":{},"49":{},"50":{},"51":{},"52":{},"53":{},"54":{},"55":{},"56":{},"57":{},"58":{},"59":{},"60":{},"61":{},"62":{},"63":{},"64":{},"65":{},"66":{},"67":{},"68":{},"69":{},"70":{}}}],["tweenmanager",{"_index":60,"name":{"71":{},"74":{}},"parent":{"72":{}}}],["tweenmanager\".p5",{"_index":61,"name":{},"parent":{"73":{}}}],["tweenmanager\".p5.tween",{"_index":62,"name":{},"parent":{"74":{},"79":{}}}],["tweenmanager\".p5.tween.tweenmanager",{"_index":64,"name":{},"parent":{"75":{},"76":{},"77":{},"78":{}}}],["tweens",{"_index":63,"name":{"75":{}},"parent":{}}],["update",{"_index":39,"name":{"37":{},"68":{},"78":{}},"parent":{}}]],"pipeline":[]}}
{
"name": "p5.tween",
"version": "1.1.0",
"version": "1.2.0",
"description": "A simple library to use tweens in p5.js",

@@ -5,0 +5,0 @@ "main": "dist/p5.tween.js",

@@ -17,3 +17,3 @@ # p5.tween

<script src="p5.min.js"></script>
<script src="https://unpkg.com/p5.tween@1.0.0/dist/p5.tween.min.js"></script>
<script src="https://unpkg.com/p5.tween/dist/p5.tween.min.js"></script>
```

@@ -76,2 +76,17 @@ 2. Add a tween to your sketch

### Using an event on loop
```js
p5.tween.manager.addTween(myShape, 'tween1')
.onLoop((tween) => myShape.c = random(0, 255))
.addMotions([
{ key: 'y', target: height },
{ key: 'w', target: 30 },
{ key: 'h', target: 80 },
], 600, 'easeInQuad')
// ...
.startLoop()
```
- [Demo](https://editor.p5js.org/Milchreis/present/7lIxFsbWM)
- [Code](https://editor.p5js.org/Milchreis/sketches/7lIxFsbWM)
## πŸ“– API

@@ -106,2 +121,6 @@ * [API-Doc](https://milchreis.github.io/p5.tween/docs)

tween.startTween()
// Events
tween.onLoop((thisTween) => console.log(thisTween))
tween.onEnd((thisTween) => console.log(thisTween))
```

@@ -108,0 +127,0 @@

@@ -14,2 +14,5 @@ namespace p5.tween {

private onEndListener: Function
private onLoopListener: Function
constructor(objStart) {

@@ -72,3 +75,3 @@ this.obj = objStart

*/
addMotions(actions: { key: string, target: number}[], duration: number, easing: string = 'linear'): Tween {
addMotions(actions: { key: string, target: number }[], duration: number, easing: string = 'linear'): Tween {
actions.flatMap(a => a.key).forEach((key: string) => this.addToKeyChangeList(key))

@@ -100,3 +103,3 @@

}
/**

@@ -155,4 +158,10 @@ * Starts the tween and plays it one time

this.currentMotionIndex = 0
if (this.onLoopListener)
this.onLoopListener(this)
} else {
this.active = false
if (this.onEndListener)
this.onEndListener(this)
}

@@ -178,3 +187,31 @@ }

}
/**
* Sets a function which is called when the tween is over.
* @param listener expects a function or lambda which should be executed. The function has one argument which represents the tween it self.
*/
onEnd(listener: Function): Tween {
if (typeof listener !== 'function') {
console.error("The given event listener for 'onEnd' is not a function. Use .onEnd(function(tween) { /* your code */})")
return
}
this.onEndListener = listener
return this
}
/**
* Sets a function which is called every time the tween has played a complete loop.
* @param listener expects a function or lambda which should be executed. The function has one argument which represents the tween it self.
*/
onLoop(listener: Function): Tween {
if (typeof listener !== 'function') {
console.error("The given event listener for 'onLoop' is not a function. Use .onLoop(function(tween) { /* your code */})")
return
}
this.onLoopListener = listener
return this
}
}
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚑️ by Socket Inc