Spawn on moving object

Hi there!

I have one very simple question: How could i spawn the player onto a moving object? I try to instantiate it on a spawnpoint moving with the cube, but the player allways falls off...

thanx!

one answer is:

void OnCollisionEnter (Collision collision) {
    foreach (ContactPoint contact in collision.contacts) {  
                rigidbody.isKinematic = true;
               transform.parent = contact.otherCollider.transform; 
            }
}