|
|
359e43ce23
|
docs: 全面更新 README + DSL规范
README.md:
- 测试数: 45→58, 玩法: 4→5 (新增南昌)
- 番型: 16→39 种完整清单
- 新增: 精牌类型(fixed/random), 计分倍数, 5种玩法覆盖表
- 新增: 压测结果表, 引擎代码规模
dsl-specification.md:
- scoring 段新增 self_draw/discard_win/dealer 倍数字段
- 已知限制更新: 花牌(完全支持), wildcard type(fixed+random)
- 快速清单新增 wildcard.type + scoring倍数 检查项
|
2026-07-04 22:02:47 +08:00 |
|
|
|
ae9c4c4142
|
feat: EndConditions映射 + 骰子翻牌定精(random wildcard)
EndConditions:
- BuildPhases 现在映射 PhaseConfig.Endconditions (之前 DslLoader 解析但 BuildPhases 忽略)
- 4处 _rules.Phases.Any(p => p.ParallelElimination) → _playPhase.ParallelElimination
- 新增 _playPhase 字段, 游戏不再依赖原始 DSL 做运行时判断
Random wildcard (骰子翻牌定精):
- WildcardRegistry.ComputeNextTiles(): 翻到 X → 正精=X+1, 副精=X+2 (9→1 循环, 字牌序循环)
- WildcardRegistry.RevealedTile 记录翻到的牌
- Deal() 发牌后翻一张牌确定精, 支持 random_count 控制精数量
- WildcardConfig 新增 RandomCount 字段 (默认2=正精+副精)
- ValidateRuleCompliance 接受 random 类型
南昌麻将 DSL:
- 新增 dsl-examples/nanchang.yaml (136张, random精, 无吃)
- 引擎加载 7/7, 1000局 0错误, 胡牌率 61%
58 tests pass, 5 种玩法全部 0 错误验证通过
|
2026-07-04 21:06:16 +08:00 |
|