Make picking up the pile a Player object function

This also fixes an issue where the human player's hand was not
sorted by rank after picking up the pile.