[verified] fix: wildcard count correction in CheckWin tile count check
根因: CheckWin 开头 tiles.Count != 14 检查未计入 wildcardCount, 导致 12 tiles + 2 wildcards = 14 被误判为手牌不足。 修复: tiles.Count + wildcardCount != 14 同步修正鬼牌_1wildcard补刻子测试用13 tiles + 1 wildcard = 14 测试: 33/33 全部通过
This commit is contained in:
@ -28,7 +28,7 @@ public class MeldsSolver
|
||||
{
|
||||
var tiles = new List<int>(hand);
|
||||
if (newTile.HasValue) tiles.Add(newTile.Value);
|
||||
if (tiles.Count != 14) return new MeldsResult { IsWin = false };
|
||||
if (tiles.Count + wildcardCount != 14) return new MeldsResult { IsWin = false };
|
||||
|
||||
tiles.Sort();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user