Added functions to cover and expose cards.
This commit is contained in:
parent
0c798f3d56
commit
d7f349a82c
12
lib/card.c
12
lib/card.c
@ -39,3 +39,15 @@ void set_card(struct card *card,
|
|||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void expose_card(struct card *card) {
|
||||||
|
card->face = EXPOSED;
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
void cover_card(struct card *card) {
|
||||||
|
card->face = COVERED;
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
@ -45,5 +45,7 @@ void allocate_card(struct card **);
|
|||||||
void initialize_card(struct card *);
|
void initialize_card(struct card *);
|
||||||
void delete_card(struct card *);
|
void delete_card(struct card *);
|
||||||
void set_card(struct card *, enum value, enum suit, enum face, int, int);
|
void set_card(struct card *, enum value, enum suit, enum face, int, int);
|
||||||
|
void expose_card(struct card *);
|
||||||
|
void cover_card(struct card *);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user