diff --git a/lib/card.c b/lib/card.c index 9c7b456..43ffb82 100644 --- a/lib/card.c +++ b/lib/card.c @@ -12,7 +12,7 @@ struct card *initialize_card() { card->frame = initialize_frame(); card->value = NONE; card->suit = NONE; - card->exposed = FALSE; + card->face = COVERED; return(card); } @@ -27,13 +27,13 @@ void delete_card(struct card *card) { void set_card(struct card *card, enum value value, enum suit suit, - char exposed, + enum face face, int start_y, int start_x) { set_frame(card->frame, start_y, start_x); card->value = value; card->suit = suit; - card->exposed = exposed; + card->face = face; return; } diff --git a/lib/card.h b/lib/card.h index 325e036..049bd84 100644 --- a/lib/card.h +++ b/lib/card.h @@ -26,16 +26,18 @@ enum value { ACE = 14 }; +enum face { COVERED, EXPOSED }; + struct card { struct frame *frame; enum value value; enum suit suit; - char exposed; + char face; }; struct card *initialize_card(); void delete_card(struct card *); -void set_card(struct card *, enum value, enum suit, char, int, int); +void set_card(struct card *, enum value, enum suit, enum face, int, int); void refresh_card(struct card *); #endif