Get rid of `DummyGameInserted` event
In the dikdikdik application, there are two important concepts: The table (where the games are announced and played), and the score sheet (where the scores are written down). The idea is:
- games are played at a table. The table should not be aware of the score sheet, because playing without a score sheet is theoretically possible.
- a thing called
ScoreSheetProcessManager
looks at what happens at the table, and sends out commands to the score sheet, so that the score is written down correctly.
Sadly enough, I made the mistake assuming that every game would correspond to a single score line. In most cases this is true, but I overlooked one.
There is a case in which the score can change although no game has been played: when more than 4 players are on the table, and everybody passes, the dealer wins a franc from each player that got cards, see #62 (closed).
To work around this, when we need a score line without a corresponding game, we send a command to the table to insert a dummy game. Which is an ugly solution, because now what happens at the table sometimes depends on what happens in the score sheet, which is something I wanted to avoid.
So I will rewrite the score events so that it will be possible to have multiple
score lines for one single game. This way the DummyGameInserted
event can be
left out.
I also used the dummy game for correction lines (#93 (closed)). But once more score lines per game are possible, this use of dummy games can be eliminated as well.