Rafael Nadal soaked up the emotion of a memorable but bittersweet evening in Malaga as his professional career came to an end.