Update: CC - Before Render - Moorcow (72d6a2a3kc.js) 395 bytes modified
parent
7901982977
commit
e1aec1ec91
|
@ -11,6 +11,7 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) {
|
|||
this.burger = this.entityLoaded.burger;
|
||||
this.parcel = this.entityLoaded.parcel;
|
||||
this.santa = this.entityLoaded.santa;
|
||||
this.renderer = this.entityLoaded.renderer;
|
||||
|
||||
this.bull.instance.visible = false;
|
||||
this.star.instance.visible = false;
|
||||
|
@ -162,6 +163,20 @@ if (GameLib.Utils.UndefinedOrNull(this.initialized)) {
|
|||
this.totalTime += data.delta;
|
||||
this.spawnTime += data.delta;
|
||||
|
||||
if (this.mouseDown) {
|
||||
this.renderer.clearColor.r += 0.01;
|
||||
if (this.renderer.clearColor.r > 1) {
|
||||
this.renderer.clearColor.r = 1;
|
||||
}
|
||||
this.renderer.updateInstance('clearColor');
|
||||
} else {
|
||||
this.renderer.clearColor.r -= 0.01;
|
||||
if (this.renderer.clearColor.r < 0) {
|
||||
this.renderer.clearColor.r = 0;
|
||||
}
|
||||
this.renderer.updateInstance('clearColor');
|
||||
}
|
||||
|
||||
if (this.spawnTime > this.nextSpawnTime) {
|
||||
this.nextSpawnTime = this.getNextSpawnTime();
|
||||
this.spawnTime = 0;
|
||||
|
|
Loading…
Reference in New Issue