Restructure organization, add docs, rooms.

Restructure the organization of the source code taking advantage of
module exports for more structured code. Add docs using docco. Implement
the ability for sockets to join rooms.