Documentation ¶
Index ¶
- Constants
- func CheckTile(tile []int) int
- func IsM(v int) bool
- func IsP(v int) bool
- func IsS(v int) bool
- func IsSameType(a, b int) bool
- func IsZ(v int) bool
- func LeftTiles34(tile34 []int) []int
- func NumToTile(v int) []byte
- func NumToTileStr(v int) string
- func StrToTile(s *string) []int
- func Tile34IsHu(tiles34 []int) bool
- func TileToStr(tile []int) string
- type MahjongResult
- type TileLine
Constants ¶
View Source
const TileMax = 34
Variables ¶
This section is empty.
Functions ¶
func IsSameType ¶
func LeftTiles34 ¶
func NumToTileStr ¶
func Tile34IsHu ¶
Types ¶
type MahjongResult ¶
type MahjongResult struct { NumKe int // 刻子数量 NumShun int // 顺子数量 Jiang int // 将牌值(0-8{1-9万},9-17{1-9筒},18-26{1-9条}) ArrayKe []int // 刻子数组 ArrayShun []int // 顺子数组 IsQiDui bool // 七对,包含龙七对(此时将牌值存了4张龙头牌) IsChurchmenPout bool // 九莲宝灯 IsTongTan bool // 通天(注意: 未考虑副露) IsRyanPeiKou bool // 两杯口(IsRyanPeiKou == true 时 IsIiPeiKou == false) IsIiPeiKou bool // 一杯口 }
func Tiles34Backtrack ¶
func Tiles34Backtrack(tiles34 []int) (res []*MahjongResult)
func Tiles34Result ¶
func Tiles34Result(tiles34 []int) (res []*MahjongResult)
func (*MahjongResult) String ¶
func (mr *MahjongResult) String() string
Click to show internal directories.
Click to hide internal directories.