first working client network layer
cleaned up code
small adjustments