Joining the two logics together slowly.

This commit is contained in:
2021-07-28 09:22:58 -07:00
parent 54559e761c
commit 9b4589dfe8
35 changed files with 405 additions and 51 deletions

32
temp/round/flop.c Normal file
View File

@ -0,0 +1,32 @@
/**
* Copyright (c) 2021 Dominic Masters
*
* This software is released under the MIT License.
* https://opensource.org/licenses/MIT
*/
#include "flop.h"
void pokerFlopInit(poker_t *poker) {
uint8_t count;
if(poker->round == POKER_ROUND_BET0) {
printf("Poker Flop Start\n");
poker->round = POKER_ROUND_FLOP;
count = POKER_FLOP_CARD_COUNT;
} else if(poker->round == POKER_ROUND_BET1) {
printf("Poker Turn\n");
poker->round = POKER_ROUND_TURN;
count = POKER_TURN_CARD_COUNT;
} else if(poker->round == POKER_ROUND_BET2) {
printf("Poker River\n");
poker->round = POKER_ROUND_RIVER;
count = POKER_RIVER_CARD_COUNT;
}
// Burn and flop.
pokerDealerBurn(&poker->dealer, 1);
pokerDealerTurn(&poker->dealer, count);
pokerRoundBetInit(poker);
}