Question

I'm currently trying to get score posting onto a facebook wall, through Unity. I'm using a simple test case seen below, however it does not currently post anything. The FBResult in the callback function returns with no error, and "true" as the result text. Additionally the login process is being completed correctly, and the permissions have been given by the user account. The only thing I can think of, is that I need to submit a review to get access to the full publisher_access permission. However I was under the impression that this would not be necessary for testing the application on my developer account(?)

Either way any help in this matter would be much appreciated! Thanks!

if(!FB.IsLoggedIn)
    FacebookManager.Instance.Logon();

Dictionary<string, string> scoreData = new Dictionary<string, string> {{"score", 10.ToString()}};

FB.API ("/me/scores", Facebook.HttpMethod.POST, OnPost, scoreData);
Was it helpful?

Solution

Calling FB.API( "/me/scores", ... ) doesn't post anything to the wall. It's a not custom, story call, which is published on facebook under Recent activity. You can find it on the left, at the very bottom of your profile page.

Scores information in Recent Activity

The more tricky part is that it is up to facebook, whether anything will be posted there anyway. Facebook itself chooses whether or when to show anything, taking into consideration the amount of app overall users, amount of submitted scores, application popularity. For my application, it has taken some time to these activities to start appearing.

The only thing you can do to make sure that you're posting it correct and that it will start working when Facebook want it to start working, is to checking manually whether the scores are actually submitted. You can do this by calling:

FB.API ("/YOUR_APP_ID/scores/",Facebook.HttpMethod.GET, ScoresCallback );

When the result contains your posted scores it means that everything is working correct and you cannot do anything more - you can only wait for the app popularity to increase.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top