refratoring clientInterface to allow updates to the gui