Facebook登录失败,并安装应用程序FB并安装、应用程序、Facebook、FB

2023-09-07 02:10:01 作者:良辰美景奈何天i

使用Unity 4.3和Facebook SDK 5.0.3 / 5.0.4的测试版我似乎无法使用FB.Login(publish_actions,LoginCallback)登录到Facebook在Android上。我的游戏节目游戏想后给你的朋友对你代表-message。攻确定后,我得到一个Ajax微调约2-3秒后,我带回我的比赛而不能发表FB.Feed。

Using Unity 4.3 and Facebook SDK 5.0.3 / 5.0.4 beta I seem to be unable to log in to Facebook on Android using FB.Login("publish_actions", LoginCallback). My game shows the "Game would like to post to your friends on your behalf"-message. After tapping OK, I get an ajax-spinner for about 2-3 seconds after which I'm brought back to my game without being able to post a FB.Feed.

我得到的信息是:

V / FBUnitySDK(8892):在发送到Unity OnLoginComplete({取消:真的,key_hash:XXXXXXXXXXXXXXXXXXX})

当我删除Facebook的应用程序,一切似乎正常工作和我收到询问我publish_actions权限的弹出窗口。

As soon as I remove the Facebook app, everything seems to work fine and I'm getting a popup that asks for my publish_actions permissions.

我也看了成关键哈希问题,并能够通过获取FB.Android.KeyHash找到正确的key_hash。

I also looked into the key hash problem and was able to find the correct key_hash by getting FB.Android.KeyHash.

有没有办法解决?

推荐答案

好吧,我终于想通了。

在Mac上,在终端中输入以下内容:

keytool -list -keystore pathtokeystorefile.keystore | openssl sha1 -binary | openssl base64

您会被提示输入密码。这样做,你会得到您的有效KeyHash。

You'll be prompted to enter the password. Do so and you will get your valid KeyHash.