Plugin Problem...

I am trying to implement game center leaderboards into my game using the Prime31 Game Center plugin. I have looked through the Prime31 docs and asked around on unity answers, but I still don’t fully understand it. I was told that I need to use something called a long instead of an int to store the score I want to submit to the leaderboard…I have no idea what that means. “Titania” is the id of the leaderboard I made in iTunes connect…am I using it correctly?

I get this error

NewBehaviourScript.js(10,34): BCE0023: No appropriate version of ‘GameCenterBinding.reportScore’ forthe argument list ‘(String, long)’ was found.

var longValue : long = 10;

function Start(){
    GameCenterBinding.isGameCenterAvailable();
    GameCenterBinding.authenticateLocalPlayer();
    GameCenterBinding.reportScore("Titania", longValue);
}

function OnGUI (){
    if (GUI.Button (Rect (10,10,150,100), "Test")) {
        GameCenterBinding.showLeaderboardWithTimeScope(GameCenterLeaderboardTimeScope.AllTime);             

}

1 Answer

1

try switching the values:

GameCenterBinding.reportScore(longValue,“Titania”);

http://prime31.com/unity/docs/#gameCenterDoc