refactored client to actually work with the network client stuff