I\'m using NodeJS+Socket.IO for simple web game. It works. Why?
Here\'s my server.js
server.js
var app = require(\'express\').createServer(); var
Server side
socket.on('updatePlayer', function(updatePlayer){ console.log("Someone just moved on the map!") updatePlayer() // will trigger the client side function });
Client side
socket.emit('updatePlayer', function(){ console.log('testing'); })