ground work for different users on server and players on client

This commit is contained in:
Jeena Paradies 2012-07-13 21:10:08 +02:00
parent e37d1eeb2e
commit 2cb401bbd3
9 changed files with 122 additions and 54 deletions

View file

@ -1,14 +1,19 @@
define(["Chuck/Processors/ClientProcessor"], function(ClientProcessor) {
function ClientGame(networker){
function ClientGame(networker, id) {
this.networker = networker;
this.processor = new ClientProcessor();
this.processor.spawnMeWithId(id);
}
ClientGame.prototype.loadLevel = function(path) {
this.processor.loadLevel(path);
}
ClientGame.prototype.userJoined = function(userId) {
this.processor.spawnNewPlayerWithId(userId);
};
ClientGame.prototype.processGameCommand = function(command, options){
console.log('(not implemented) processGameCommand:', command, options);
}