The cribbage game in the latest bsd-games makes occasional, random errors in play. Specifically, the computer will play a card that makes the total exceed 31 and then declare it won that hand. An example game: Computer plays 6, I play 2, Computer plays K, I play 4 which gives a total of 22. Then, the Computer play T and reports that it gets 1 for last. That's a total of 32. I'm no expert, but I think a fundamental rule is that you can't exceed 31. This doesn't happen every time. Sometimes it says "go" properly. I haven't detected a pattern, but I haven't played that many games. My first guess- and it's just a guess- is that it seems to happen when the computer has to play something on a 22, versus 23 or more. Oh, this kind of error has happened a handful of times. Seems like that 22 sticks in my mind.
It's not just 22. I've played more games and seen the same kind of error again with other twenties.
Seems to be a bug from the upstream source. I suggest to 0) find out how often it happens / find a rule, when it happens 1) attach all logs as usual (perhaps we see interesting warnings) 2) look for patches in other distributions (https://repology.org/ may help here) 3) debug the game and provide a patch
This looks like Mike Sharov's fork of bsd-games, so I made a github account and posted my concern about this issue there. He responded very quickly and made some changes with cribbage. I also advised him about a strategy flaw in the computer's play. I haven't seen a response yet. Mr. Sharov said he didn't know anything about a Gentoo bsd-games version 3.1 package. So, I'm just assuming Gentoo is using his code. I haven't investigated that deeply.
(In reply to Don Wilburn from comment #3) > This looks like Mike Sharov's fork of bsd-games, so I made a github account > and posted my concern about this issue there. He responded very quickly and > made some changes with cribbage. > I also advised him about a strategy flaw in the computer's play. I haven't > seen a response yet. > Mr. Sharov said he didn't know anything about a Gentoo bsd-games version 3.1 > package. So, I'm just assuming Gentoo is using his code. I haven't > investigated that deeply. We started using it after his email to us a few months back. I only added it within the last 2 weeks.