Esempio n. 1
0
        public void ShowLeaderboardUI(string leaderboardId, GooglePlayGames.BasicApi.LeaderboardTimeSpan span, Action <GooglePlayGames.BasicApi.UIStatus> cb)
        {
            if (!this.IsAuthenticated())
            {
                return;
            }
            Action <CommonErrorStatus.UIStatus> callback1 = Callbacks.NoopUICallback;

            if (cb != null)
            {
                callback1 = (Action <CommonErrorStatus.UIStatus>)(result => cb((GooglePlayGames.BasicApi.UIStatus)result));
            }
            Action <CommonErrorStatus.UIStatus> callback2 = NativeClient.AsOnGameThreadCallback <CommonErrorStatus.UIStatus>(callback1);

            if (leaderboardId == null)
            {
                this.GameServices().LeaderboardManager().ShowAllUI(callback2);
            }
            else
            {
                this.GameServices().LeaderboardManager().ShowUI(leaderboardId, span, callback2);
            }
        }
Esempio n. 2
0
        public void LoadLeaderboardData(string leaderboardId, GooglePlayGames.BasicApi.LeaderboardStart start, int rowCount, GooglePlayGames.BasicApi.LeaderboardCollection collection, GooglePlayGames.BasicApi.LeaderboardTimeSpan timeSpan, string playerId, Action <LeaderboardScoreData> callback)
        {
            // ISSUE: object of a compiler-generated type is created
            // ISSUE: variable of a compiler-generated type
            LeaderboardManager.\u003CLoadLeaderboardData\u003Ec__AnonStorey164 dataCAnonStorey164 = new LeaderboardManager.\u003CLoadLeaderboardData\u003Ec__AnonStorey164();
            // ISSUE: reference to a compiler-generated field
            dataCAnonStorey164.playerId = playerId;
            // ISSUE: reference to a compiler-generated field
            dataCAnonStorey164.rowCount = rowCount;
            // ISSUE: reference to a compiler-generated field
            dataCAnonStorey164.callback = callback;
            // ISSUE: reference to a compiler-generated field
            dataCAnonStorey164.\u003C\u003Ef__this = this;
            NativeScorePageToken nativeScorePageToken = new NativeScorePageToken(GooglePlayGames.Native.Cwrapper.LeaderboardManager.LeaderboardManager_ScorePageToken(this.mServices.AsHandle(), leaderboardId, (Types.LeaderboardStart)start, (Types.LeaderboardTimeSpan)timeSpan, (Types.LeaderboardCollection)collection));

            // ISSUE: reference to a compiler-generated field
            dataCAnonStorey164.token = new ScorePageToken((object)nativeScorePageToken, leaderboardId, collection, timeSpan);
            // ISSUE: reference to a compiler-generated method
            GooglePlayGames.Native.Cwrapper.LeaderboardManager.LeaderboardManager_Fetch(this.mServices.AsHandle(), Types.DataSource.CACHE_OR_NETWORK, leaderboardId, new GooglePlayGames.Native.Cwrapper.LeaderboardManager.FetchCallback(LeaderboardManager.InternalFetchCallback), Callbacks.ToIntPtr <FetchResponse>(new Action <FetchResponse>(dataCAnonStorey164.\u003C\u003Em__A1), new Func <IntPtr, FetchResponse>(FetchResponse.FromPointer)));
        }
Esempio n. 3
0
 internal void ShowUI(string leaderboardId, GooglePlayGames.BasicApi.LeaderboardTimeSpan span, Action <CommonErrorStatus.UIStatus> callback)
 {
     Misc.CheckNotNull <Action <CommonErrorStatus.UIStatus> >(callback);
     GooglePlayGames.Native.Cwrapper.LeaderboardManager.LeaderboardManager_ShowUI(this.mServices.AsHandle(), leaderboardId, (Types.LeaderboardTimeSpan)span, new GooglePlayGames.Native.Cwrapper.LeaderboardManager.ShowUICallback(Callbacks.InternalShowUICallback), Callbacks.ToIntPtr((Delegate)callback));
 }
Esempio n. 4
0
 public void LoadScores(string leaderboardId, GooglePlayGames.BasicApi.LeaderboardStart start, int rowCount, GooglePlayGames.BasicApi.LeaderboardCollection collection, GooglePlayGames.BasicApi.LeaderboardTimeSpan timeSpan, Action <LeaderboardScoreData> callback)
 {
     this.GameServices().LeaderboardManager().LoadLeaderboardData(leaderboardId, start, rowCount, collection, timeSpan, this.mUser.id, callback);
 }