Example #1
0
    /// <summary>
    /// 服务器广播切锅
    /// </summary>
    /// <param name="obj"></param>
    private void OnServerCutGuo(byte[] obj)
    {
        Debug.Log("服务器广播切锅:");
        PAIGOW_ROOM_CUTPAN proto = PAIGOW_ROOM_CUTPAN.decode(obj);

        RoomPaiJiuProxy.Instance.OnServerCutGuo(proto);
    }
Example #2
0
    /// <summary>
    /// 客户端发送切锅
    /// </summary>
    public void ClientSendQieGuo(bool isCutGuo)
    {
        PAIGOW_ROOM_CUTPAN proto = new PAIGOW_ROOM_CUTPAN();

        proto.isCutGuo = isCutGuo;
        NetWorkSocket.Instance.Send(proto.encode(), PAIGOW_ROOM_CUTPAN.CODE, GameCtrl.Instance.SocketHandle);
    }
Example #3
0
 public void OnServerCutGuo(PAIGOW_ROOM_CUTPAN proto)
 {
     if (proto.hasPos())
     {
         Seat seat = GetSeatBySeatId(proto.pos);
         if (seat == null)
         {
             return;
         }
         if (proto.hasIsCutGuo())
         {
             seat.isCutGuo = proto.isCutGuo ? 1 : 2;
         }
         else
         {
             //通知切锅
             seat.isCutGuo = 3;
         }
         SendSeatInfoChangeNotify(seat);
     }
 }