Un jeu de cartes à piper les une dans les autres - retour accueil
git clone git://bebou.netlib.re/pipe-game
Log | Files | Refs | README |
commit 03457c0cac1d4230ce0cf19e54da36ba7459cf51 parent d449248b5e7f851f1ffdc46460468b107e84598f Auteurice: Arthur Pons <arthur.pons@unistra.fr> Date: Tue, 21 Jan 2025 11:42:20 +0100 Ajout d'hr dans l'interface pour la lisibilité Diffstat:
M | interface.c | | | 6 | ++++++ |
1 file changed, 6 insertions(+), 0 deletions(-)
diff --git a/interface.c b/interface.c @@ -24,6 +24,10 @@ int nblines(char *str) { return l; } +void hr(int i) { + tb_printf(0, i, TB_DEFAULT, TB_BLACK, "-------"); +} + void addcardtopile(char* cardname, pile* p) { p->cards[p->cardCount] = malloc(CARD_NAME_SIZE); strcpy(p->cards[p->cardCount], cardname); @@ -130,7 +134,9 @@ void display(pile* h, pile* p, int handcurline, int playedcurline, char* curmenu int l=0; l=nblines(res); tb_printf(0, biggestpile+1, TB_DEFAULT, TB_BLACK, cmd); + hr(biggestpile+1+p->cardCount); tb_printf(0, biggestpile+1+p->cardCount+1, TB_DEFAULT, TB_BLACK, res); + hr(biggestpile+1+p->cardCount+1+l); tb_printf(0, biggestpile+1+p->cardCount+2+l, TB_DEFAULT, TB_BLACK, intern); tb_present(); }