Update: CC - Demo New - Entity Loaded (tuby5lj4di.js) 131 bytes modified
parent
17068a817f
commit
1bb97179ab
|
@ -143,11 +143,9 @@ GameLib.CustomCode.prototype.buildInstancedGeometry = function(index) {
|
||||||
|
|
||||||
}.bind(this);
|
}.bind(this);
|
||||||
|
|
||||||
GameLib.CustomCode.prototype.startAnimation = function(attributeData) {
|
/**
|
||||||
this.generateAnimationVectors(attributeData);
|
* Builds update information holding our current position and scale, and our target position and scale
|
||||||
this.beforeRender.startAnimation = true;
|
*/
|
||||||
}.bind(this);
|
|
||||||
|
|
||||||
GameLib.CustomCode.prototype.generateAnimationVectors = function(attributeData) {
|
GameLib.CustomCode.prototype.generateAnimationVectors = function(attributeData) {
|
||||||
|
|
||||||
if (!attributeData) {
|
if (!attributeData) {
|
||||||
|
@ -192,6 +190,9 @@ GameLib.CustomCode.prototype.generateAnimationVectors = function(attributeData)
|
||||||
}
|
}
|
||||||
}.bind(this);
|
}.bind(this);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Performs the actual update to our instanced geometry
|
||||||
|
*/
|
||||||
GameLib.CustomCode.prototype.updateAttributeArrays = function(alpha) {
|
GameLib.CustomCode.prototype.updateAttributeArrays = function(alpha) {
|
||||||
console.log('animation : ' + alpha);
|
console.log('animation : ' + alpha);
|
||||||
}.bind(this);
|
}.bind(this);
|
||||||
|
@ -209,7 +210,13 @@ GameLib.CustomCode.prototype.loadNext = function() {
|
||||||
|
|
||||||
var attributeData = this.generateAttributeData(this.currentIndex, 128, 128);
|
var attributeData = this.generateAttributeData(this.currentIndex, 128, 128);
|
||||||
|
|
||||||
this.startAnimation(attributeData);
|
this.generateAnimationVectors(attributeData);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Notify our render component that we are ready to start animating
|
||||||
|
*/
|
||||||
|
this.beforeRender.startAnimation = true;
|
||||||
|
|
||||||
}.bind(this);
|
}.bind(this);
|
||||||
|
|
||||||
this.buildInstancedGeometry(0);
|
this.buildInstancedGeometry(0);
|
||||||
|
|
Loading…
Reference in New Issue