本帖最后由 Seekladoom 于 2021-8-13 17:23 编辑
这是有刻意考虑日本麻将打法(国士无双、岭上开花这些等)才写了这么多数组的吗?
补上楼主用到的麻将图案字体:
GL-MahjongTile.rar
(26.15 KB, 下载次数: 1925)
这些数组对应的就是麻将图案字体中相应的图案(一~九萬、一~九筒这些等等)了:- zi =['1','2','3','4','7','6','5']
- man =['q','w','e','r','t','y','u','i','o']
- so =['a','s','d','f','g','h','j','k','l']
- pin =['z','x','c','v','b','n','m',',','.']
- mj =zi+man+so+pin
- zon =mj[randint(0,32)]
- zi0 =['7','6','5','8','1','2','3','4']
- zi4 =['1','1','1','2','2','2','8','3','3','3','4','4','4']
- zi6 =['q','o','a','l','z','.','8','1','2','3','4']
- zi8 =['z','z','z','x','c','v','8','b','n','m',',','.','.','.']
- zi9 =['s','s','s','d','d','d','f','f','f','6','6','6']
- zi11=['q','q','q','a','a','a','z','l','l','l','.','.','.']
- zi13=['e','e','e','e','t','y','u','i','g','m']
- zi16=['x','x','x','x','c','c','c','c','8','v','v','v','v']
- zi17=['7','7','7','7','b','b','b','o','i','u','y','t']
- zi18=['g','h','j','8','y','u','i','1']
- zi19=['z','x','c','v','b','n','m',',','.','.','.']
- zi20=['1','1','1','1','2','2','2','2','3','3','3','3','4','4','4','4','7','7']
复制代码 |