public void SubmitScore(OKScoreSubmitComponent score) { if (score.displayString == null) { //Set the displayString to blank if it's null because you can't pass null strings to JNI functions score.displayString = ""; } OKAndroidPlugin.CallStatic("submitScore", score.scoreValue, score.OKLeaderboardID, score.metadata, score.displayString, score.GetCallbackGameObjectName()); }
public void SubmitScoreComponent(OKScoreSubmitComponent score) { if (string.IsNullOrEmpty(score.gameCenterLeaderboardCategory)) { Debug.Log("Submitting score to OpenKit"); OKBridgeSubmitScore(score.scoreValue, score.OKLeaderboardID, score.metadata, score.displayString, score.GetCallbackGameObjectName()); } else { Debug.Log("Submitting score to OpenKit & Gamecenter"); OKBridgeSubmitScoreWithGameCenter(score.scoreValue, score.OKLeaderboardID, score.metadata, score.displayString, score.GetCallbackGameObjectName(), score.gameCenterLeaderboardCategory); } }
public void SubmitScoreComponent(OKScoreSubmitComponent score) { if(string.IsNullOrEmpty(score.gameCenterLeaderboardCategory)) { Debug.Log("Submitting score to OpenKit"); OKBridgeSubmitScore(score.scoreValue, score.OKLeaderboardID, score.metadata, score.displayString, score.GetCallbackGameObjectName()); } else { Debug.Log("Submitting score to OpenKit & Gamecenter"); OKBridgeSubmitScoreWithGameCenter(score.scoreValue, score.OKLeaderboardID, score.metadata, score.displayString, score.GetCallbackGameObjectName(), score.gameCenterLeaderboardCategory); } }
public void SubmitScoreComponent(OKScoreSubmitComponent score) { score.scoreSubmissionFailed("Can't submit scores from Unity editor, native only"); }