Update: CC - Before Render - Moorcow (orfy8cilgg.js) 45 bytes modified

beta.r3js.org
-=yb4f310 2017-11-27 11:27:47 +01:00
parent 5293a38fac
commit 77a24fdb5b
1 changed files with 9 additions and 9 deletions

View File

@ -797,6 +797,7 @@ if (this.mouseIsDown)
*/ */
if (GameLib.Utils.UndefinedOrNull(mesh.burnLife)) { if (GameLib.Utils.UndefinedOrNull(mesh.burnLife)) {
mesh.burnLife = 1; mesh.burnLife = 1;
mesh.burning = false;
} }
if (!mesh.burning) { if (!mesh.burning) {
@ -804,19 +805,18 @@ if (this.mouseIsDown)
mesh.burnLife -= data.delta * 2; mesh.burnLife -= data.delta * 2;
if (mesh.burnLife <= 0) { if (mesh.burnLife <= 0) {
mesh.burnLife = 0;
this.burnTree(mesh); this.burnTree(mesh);
}
if (mesh.instance.material.emissive) { if (mesh.instance.material.emissive) {
mesh.instance.material.emissive.setRGB( mesh.instance.material.emissive.setRGB(
1 - mesh.burnLife, 1 - mesh.burnLife,
0, 0,
0 0
); );
}
} }
} }
} }
} }
}.bind(this) }.bind(this)