mirror of
https://github.com/logsol/chuck.js.git
synced 2026-05-11 18:47:35 +00:00
join success roundtrip added
This commit is contained in:
parent
e93dbf2f2a
commit
2183e70bd8
5 changed files with 48 additions and 53 deletions
|
|
@ -19,11 +19,12 @@ function (ProtocolHelper, GameController) {
|
|||
this.socketLink.on('connect', function () {
|
||||
self.onConnect();
|
||||
});
|
||||
/*
|
||||
|
||||
this.socketLink.on('message', function (message) {
|
||||
self.onMessage(message);
|
||||
//self.onMessage(message);
|
||||
console.log('Message from server: ', message);
|
||||
});
|
||||
*/
|
||||
|
||||
this.socketLink.on('disconnect', function () {
|
||||
self.onDisconnect();
|
||||
});
|
||||
|
|
@ -48,7 +49,7 @@ function (ProtocolHelper, GameController) {
|
|||
|
||||
|
||||
Networker.prototype.onJoinSuccess = function (options) {
|
||||
this.gameController = new GameController(options.id);
|
||||
this.gameController = new GameController();
|
||||
this.gameController.loadLevel("default.json");
|
||||
/*
|
||||
console.log("Joined " + options.channelName);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue