Beispiel #1
0
        public override void ReportScore(string _leaderboardID, long _score, Action <bool> _onCompletion)
        {
            base.ReportScore(_leaderboardID, _score, _onCompletion);

            if (string.IsNullOrEmpty(_leaderboardID))
            {
                return;
            }

            // Verify user authentication state before proceeding
            if (!VerifyUser())
            {
                if (_onCompletion != null)
                {
                    _onCompletion(false);
                }

                return;
            }

            // Report score
            AndroidScore _newScore = new AndroidScore(_leaderboardID, _score);

            _newScore.ReportScore(_onCompletion);
        }
Beispiel #2
0
        // Report score
        protected override Score CreateScoreForLocalUser(string _leaderboardGID, string _leaderboardID)
        {
            // Verify auth status
            if (!VerifyUser())
            {
                return(null);
            }

            // Verify id
            if (string.IsNullOrEmpty(_leaderboardID))
            {
                return(null);
            }

            // Create instance
            AndroidScore _instance = new AndroidScore(_leaderboardGID, _leaderboardID, LocalUser);

            return(_instance);
        }
		// Report score
		protected override Score CreateScoreForLocalUser (string _leaderboardGID, string _leaderboardID)
		{
			// Verify auth status
			if (!VerifyUser())
				return null ;
			
			// Verify id
			if (string.IsNullOrEmpty(_leaderboardID))
				return null;
			
			// Create instance
			AndroidScore		_instance		= new AndroidScore(_leaderboardGID, _leaderboardID, LocalUser);
			return _instance;
		}