Update: CC - Snake FS - Entity Loaded (21g30t1e75.js) 227 bytes modified
parent
dbd977ad92
commit
23121376d9
|
@ -1895,6 +1895,14 @@ GameLib.Event.Subscribe(
|
||||||
this.explodeTime = 0;
|
this.explodeTime = 0;
|
||||||
this.speedTimer = 0;
|
this.speedTimer = 0;
|
||||||
|
|
||||||
|
GameLib.Event.Emit(
|
||||||
|
GameLib.Event.GAME_DATA,
|
||||||
|
{
|
||||||
|
type : 'game_start',
|
||||||
|
state : this.state
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Re-initialize our other custom code components
|
* Re-initialize our other custom code components
|
||||||
*/
|
*/
|
||||||
|
@ -1942,7 +1950,15 @@ GameLib.Event.Subscribe(
|
||||||
this.touchStart.initialized = false;
|
this.touchStart.initialized = false;
|
||||||
this.touchStart.entityLoaded = null;
|
this.touchStart.entityLoaded = null;
|
||||||
|
|
||||||
console.log('starting game snake');
|
GameLib.Event.Emit(
|
||||||
|
GameLib.Event.GAME_DATA,
|
||||||
|
{
|
||||||
|
type : 'game_over',
|
||||||
|
state : this.state
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
console.log('game over');
|
||||||
}.bind(this)
|
}.bind(this)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue