HGHHConst.cs 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. namespace ET.Server
  2. {
  3. /// <summary>
  4. /// 晃晃静态常量
  5. /// </summary>
  6. public static class HGHHConst
  7. {
  8. /// <summary>
  9. /// 麻将对应数值
  10. /// 0x01-0x09 万
  11. /// 0x11-0x19 筒
  12. /// 0x21-0x29 条
  13. /// 0x31-0x37 东南西北中发白
  14. /// </summary>
  15. public static readonly int[] Values =
  16. {
  17. 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09,
  18. 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19,
  19. 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29,
  20. 0x35, 0x36, 0x37
  21. };
  22. public const int YI_WAN = 0x01;
  23. public const int DONG_FENG = 0x31;
  24. /** 默认不胡牌 **/
  25. public const int HU_DEFAULT = 0;
  26. /** 基本胡 x1 **/
  27. public const int HU_BASE = 1;
  28. /** 平胡 (无刻子,都是顺子) x2 **/
  29. public const int HU_PING = 2;
  30. /** 碰碰胡 x2 **/
  31. public const int HU_DUIDUI = 3;
  32. /** 七对 x4 **/
  33. public const int HU_7DUI = 4;
  34. /** 清一色 x8 **/
  35. public const int HU_QING = 5;
  36. /** 清一色碰碰胡 x16 **/
  37. public const int HU_QING_DUIDUI = 6;
  38. /** 清一色七对 x32 **/
  39. public const int HU_QING_QIDUI = 7;
  40. /// <summary>
  41. /// 牌型藩数 (下标对应上面牌型)
  42. /// </summary>
  43. public static int[] ScoreType = { 1, 1, 2, 2, 4, 8, 16, 32 };
  44. /// <summary>
  45. /// 刻子类型
  46. /// </summary>
  47. public enum KeziType
  48. {
  49. DEFAULT = 0,
  50. /** 明杠 */
  51. MING_GANG = 1,
  52. /** 回杠 */
  53. HUI_GANG = 2,
  54. /** 暗杠 */
  55. AN_GANG = 3,
  56. /** 碰 */
  57. PENG = 4,
  58. /** 吃 **/
  59. CHI = 5
  60. }
  61. public enum Result
  62. {
  63. /**平局*/
  64. PING = 0,
  65. /**点炮*/
  66. DIANPAO = 1,
  67. /**自摸*/
  68. ZIMO = 2,
  69. /**抢杠*/
  70. QIANGGANG = 3,
  71. /**留局*/
  72. LIUJU = 4,
  73. /**杠开*/
  74. GANGKAI = 5
  75. }
  76. }
  77. }