Page 1 of 1

When to calculate an average stat?

Posted: 09 June 2020, 16:20
by MikeIsHere
I want to have a stat points per hand
I was thinking that I would keep track of the numerator and denominator separately and then have a step before endGame that would calculate the averages. But then I though of games that do not end by end conditions (disconnect or quitting). In these scenarios

1) do I need to still record stats?
2) does this mean I have to calculate the average every round because I don't know when the game will end. If so what is the compute cost of two get stats and one set stat every play?