Merge server and client - closes #5, closes #3