Ejemplo n.º 1
0
 //玩家胡牌进行分数计算
 public static void PlayerResultCalculateGrade(this FiveStarRoom fiveStarRoom, int winCard, int huPaiIndex, int operateType)
 {
     fiveStarRoom.FiveStarPlayerDic[huPaiIndex].HuPaiCount++;                                                                                             //胡牌次数加1
     fiveStarRoom.SmallPlayerResults[huPaiIndex].WinCard    = winCard;                                                                                    //记录赢的哪张牌
     fiveStarRoom.SmallPlayerResults[huPaiIndex].HuPaiTypes = fiveStarRoom.FiveStarPlayerDic[huPaiIndex].GetHuPaiType(winCard, ref fiveStarRoom.intData); //记录胡牌类型 获得赢牌的倍数
     fiveStarRoom.intData2 = fiveStarRoom.PlayerMaiMa(huPaiIndex, operateType);                                                                           //判断能不能买码 能就广播买码消息 并返回买码的倍数
     if (FiveStarOperateType.ZiMo == operateType)
     {
         fiveStarRoom.ZiMoCalculateScore(huPaiIndex);//自摸分数计算
     }
     else if (FiveStarOperateType.FangChongHu == operateType)
     {
         fiveStarRoom.FangChongHuCalculateScore(huPaiIndex); //放冲胡分数计算
     }
 }