Added state functions for cards.