Added reference linking, finished client.