Implemented support for multiple clients.

Changed output messages to only write to each client.