Added basic card matching.

Added some more comments.