Ron/Tsumo/Riichi calls (V2) #9

Open
opened 2026-09-10 21:02:26 +00:00 by Baplar · 1 comment
Owner

Computing shanten is expensive, and counting yaku somewhat as well.

  • External service through websocket or REST API ?
  • Algorithm could be implemented in flux or protograph, but costly and lots of effort
Computing shanten is expensive, and counting yaku somewhat as well. - External service through websocket or REST API ? - Algorithm *could* be implemented in flux or protograph, but costly and lots of effort
Baplar changed title from Ron/Tsumo (V3?) to Ron/Tsumo (V2) 2026-09-21 09:13:15 +00:00
Baplar changed title from Ron/Tsumo (V2) to Ron/Tsumo/Riichi calls (V2) 2026-09-21 09:13:29 +00:00
Author
Owner

Inspiration: https://github.com/MahjongRepository/mahjong/blob/master/mahjong/shanten.py
Need to adapt it so that when the hand is tenpai, we also return the isolated tiles to discard with a 3n+2 hand, and the winning tiles with a 3n+1 hand (isolated + pairs if there are 2 pairs + both sides of tatsu first + middle of tatsu second)
Once that is done, we can run https://github.com/MahjongRepository/mahjong/blob/master/mahjong/hand_calculating/hand.py for each possible winning tile to check for invalid hands eg no yaku.

Inspiration: https://github.com/MahjongRepository/mahjong/blob/master/mahjong/shanten.py Need to adapt it so that when the hand is tenpai, we also return the isolated tiles to discard with a 3n+2 hand, and the winning tiles with a 3n+1 hand (isolated + pairs if there are 2 pairs + both sides of tatsu first + middle of tatsu second) Once that is done, we can run https://github.com/MahjongRepository/mahjong/blob/master/mahjong/hand_calculating/hand.py for each possible winning tile to check for invalid hands eg no yaku.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Baplar/ResoniteMahjong#9
No description provided.