mirror of
https://github.com/logsol/chuck.js.git
synced 2026-05-11 10:37:34 +00:00
working towards usable new structure
This commit is contained in:
parent
3afc2fa66e
commit
815c63009f
15 changed files with 223 additions and 84 deletions
|
|
@ -4,7 +4,7 @@ define([
|
|||
"Game/Config/Settings",
|
||||
"Game/Core/Control/InputController",
|
||||
"Lib/Utilities/RequestAnimFrame",
|
||||
"Game/Server/NotificationCenter"
|
||||
"Game/Core/NotificationCenter"
|
||||
],
|
||||
|
||||
function(Parent, PhysicsEngine, Settings, InputController, requestAnimFrame, NotificationCenter) {
|
||||
|
|
@ -14,15 +14,15 @@ function(Parent, PhysicsEngine, Settings, InputController, requestAnimFrame, Not
|
|||
|
||||
this.inputControllers = {};
|
||||
|
||||
this.update();
|
||||
this.updateWorld();
|
||||
//this.update();
|
||||
//this.updateWorld();
|
||||
|
||||
NotificationCenter.on('user/joined', this.userJoined, this);
|
||||
NotificationCenter.on('user/left', this.userLeft, this);
|
||||
//NotificationCenter.on('user/joined', this.userJoined, this);
|
||||
//NotificationCenter.on('user/left', this.userLeft, this);
|
||||
}
|
||||
|
||||
GameController.prototype = Object.create(Parent.prototype);
|
||||
|
||||
/*
|
||||
GameController.prototype.update = function() {
|
||||
|
||||
requestAnimFrame(this.update.bind(this));
|
||||
|
|
@ -79,6 +79,6 @@ function(Parent, PhysicsEngine, Settings, InputController, requestAnimFrame, Not
|
|||
|
||||
setTimeout(this.updateWorld.bind(this), Settings.WORLD_UPDATE_BROADCAST_INTERVAL);
|
||||
}
|
||||
|
||||
*/
|
||||
return GameController;
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue