extended client server communication

This commit is contained in:
logsol 2012-07-08 04:29:14 +02:00
parent 94f63fc7b2
commit 81d2aa4ddc
12 changed files with 156 additions and 86 deletions

View file

@ -18,6 +18,7 @@ define(["Server/User", "Server/Channel"], function(User, Channel) {
}
Coordinator.prototype.assignUserToChannel = function(user, channelName){
if(user.channel) {
user.channel.releaseUser(user);
}
@ -39,6 +40,12 @@ define(["Server/User", "Server/Channel"], function(User, Channel) {
delete this.lobbyUsers[user.id];
}
Coordinator.prototype.removeUser = function(user){
delete this.lobbyUsers[user.id];
if(user.channel) {
user.channel.releaseUser(user);
}
}
return Coordinator;