- // Transmit chats and moves to current room
- // TODO: WebRTC instead in this case (most demanding?)
+ case "askclients":
+ socket.send(JSON.stringify({code:"clients", sockIds:Object.keys(clients).filter(k => k != sid)}));
+ break;
+ case "askidentity":
+ clients[obj.target].send(JSON.stringify({code:"identify",from:sid}));
+ break;
+ case "identity":
+ clients[obj.target].send(JSON.stringify({code:"identity",user:obj.user}));
+ break;
+ case "askchallenges":
+ // TODO: ask directly to people (webRTC)
+ // TODO... + clarify socket system
+ break;
+ case "newchallenge":
+ clients[obj.target].send(JSON.stringify({code:"newchallenge",chall:obj.chall}));
+ case "askgames":
+ // TODO: ask directly to people (webRTC)
+ break;