added max user and refactored coordinator/serveruser a bit fixes #105

This commit is contained in:
logsol 2015-03-03 23:43:15 +01:00
parent ccd146f01b
commit 6b472dc134
9 changed files with 156 additions and 66 deletions

View file

@ -53,6 +53,7 @@ function (ProtocolHelper, GameController, User, Nc, Settings, DomController) {
this.sendCommand('join', options);
DomController.setConnected(true);
} else {
alert("Error: no channel name");
window.location.href = "/";
}
}
@ -80,7 +81,7 @@ function (ProtocolHelper, GameController, User, Nc, Settings, DomController) {
}
Networker.prototype.onJoinError = function(options) {
// alert(options.message);
alert(options.message);
window.location.href = "/";
};

View file

@ -76,6 +76,7 @@ define(function() {
NETWORK_LOG_FILTER: ['ping', 'pong', 'worldUpdate', 'lookAt'],
// CHANNEL
CHANNEL_MAX_USERS: 20,
CHANNEL_DESTRUCTION_TIME: 5 * 60,
CHANNEL_END_ROUND_TIME: 4, //10,
CHANNEL_DEFAULT_MAX_USERS: 40,