Example #1
0
    /// <summary>
    /// 服务器广播结算
    /// </summary>
    /// <param name="obj"></param>
    private void OnServerBroadcastSettle(byte[] obj)
    {
        AppDebug.Log("服务器广播结算");
        PAIGOW_ROOM_OPENPOKERRESULT proto = PAIGOW_ROOM_OPENPOKERRESULT.decode(obj);

        RoomPaiJiuProxy.Instance.OnServerResult(proto);

        //是否是最后一局
        //if (RoomPaiJiuProxy.Instance.CurrentRoom.currentLoop >= RoomPaiJiuProxy.Instance.CurrentRoom.maxLoop)
        //{
        //    m_Result = proto.paigow_room;
        //}
        if (PaiJiuSceneCtrl.Instance != null)
        {
            PaiJiuSceneCtrl.Instance.Settle(proto.paigow_room.loopEnd);
        }
    }
Example #2
0
    /// <summary>
    ///  结算
    /// </summary>
    /// <param name="proto"></param>
    public void OnServerResult(PAIGOW_ROOM_OPENPOKERRESULT proto)
    {
        PAIGOW_ROOM room = proto.paigow_room;

        CurrentRoom.isCutPan = false;
        CurrentRoom.SetRoom(room);
        CurrentRoom.roomStatus = ROOM_STATUS.SETTLE;

        for (int i = 0; i < CurrentRoom.SeatList.Count; i++)
        {
            Debug.Log(string.Format("服务器发送{0}总收益{1}", CurrentRoom.SeatList[i].Pos, CurrentRoom.SeatList[i].TotalEarnings));
        }

        //设置倒计时
        if (room.hasUnixtime())
        {
            SetCountDown(room.unixtime);
        }
        //刷新房间 座位信息
        SendRoomInfoChangeNotify();
    }