Three handed game with Button SB BB, first to act is Button Calls, SB folds, BB Checks. Now on the flop normally it's SB to act but it's folded, now who's to act next?
The reason I am asking is I am trying to write a poker software, and have trouble keeping track of involved players in the hand and decide who to act next.
To determine the next to act, I've mistakenly reduced the last round actions (flop turn river etc.) starting with all involved players and dropping those that either folded or went all-in, this calculation is wrong because I have to reduce all the rounds, this is inefficient and can be avoided.