Example #1
0
        private void CancelFindGame(ulong gameRequestId)
        {
            CancelGameEntryRequest cancelGameEntryRequest = new CancelGameEntryRequest();

            cancelGameEntryRequest.RequestId = gameRequestId;
            Player   player   = new Player();
            Identity identity = new Identity();

            identity.SetGameAccountId(this.m_battleNet.GameAccountId);
            player.SetIdentity(identity);
            cancelGameEntryRequest.AddPlayer(player);
            GamesAPI.CancelGameContext @object = new GamesAPI.CancelGameContext(gameRequestId);
            this.m_rpcConnection.QueueRequest(this.m_gameMasterService.Id, 4u, cancelGameEntryRequest, new RPCContextDelegate(@object.CancelGameCallback), 0u);
        }
    private void CancelFindGame(ulong gameRequestId)
    {
        BnetGameType findingBnetGameType = Network.Get().GetFindingBnetGameType();

        if (!this.IsNoAccountTutorialGame(findingBnetGameType))
        {
            CancelGameEntryRequest message = new CancelGameEntryRequest {
                RequestId = gameRequestId
            };
            bnet.protocol.game_master.Player val = new bnet.protocol.game_master.Player();
            Identity identity = new Identity();
            identity.SetGameAccountId(base.m_battleNet.GameAccountId);
            val.SetIdentity(identity);
            message.AddPlayer(val);
            CancelGameContext context = new CancelGameContext(gameRequestId);
            base.m_rpcConnection.QueueRequest(this.m_gameMasterService.Id, 4, message, new RPCContextDelegate(context.CancelGameCallback), 0);
        }
    }