unneeded 'loaded'
parent
e2c307ec78
commit
e87f06104e
|
@ -481,7 +481,7 @@ GameLib.D3.Mesh.prototype.createInstance = function() {
|
|||
|
||||
this.instance.name = this.name;
|
||||
|
||||
if (this.parentMesh && this.parentMesh.loaded) {
|
||||
if (this.parentMesh && this.parentMesh.instance) {
|
||||
this.parentMesh.add(this.instance, this);
|
||||
}
|
||||
|
||||
|
@ -550,7 +550,7 @@ GameLib.D3.Mesh.prototype.updateInstance = function() {
|
|||
this.instance.rotation.z = this.rotation.z;
|
||||
}
|
||||
|
||||
if (this.parentMesh && this.parentMesh.loaded) {
|
||||
if (this.parentMesh && this.parentMesh.instance) {
|
||||
if (this.instance.parent !== this.parentMesh.instance) {
|
||||
this.instance.parent = this.parentMesh.instance;
|
||||
}
|
||||
|
|
|
@ -77,7 +77,7 @@ GameLib.D3.RenderTarget.prototype.updateInstance = function() {
|
|||
if (this.instance) {
|
||||
this.instance.setSize(this.width, this.height);
|
||||
this.instance.stencilBuffer = this.stencilBuffer;
|
||||
if (this.texture && this.texture.loaded) {
|
||||
if (this.texture && this.texture.instance) {
|
||||
this.instance.texture = this.texture.instance;
|
||||
this.instance.texture.needsUpdate = true;
|
||||
} else {
|
||||
|
@ -86,7 +86,6 @@ GameLib.D3.RenderTarget.prototype.updateInstance = function() {
|
|||
} else {
|
||||
try {
|
||||
this.createInstance();
|
||||
this.loaded = true;
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue