0
페이스 북에 연결하는 Android 게임을 개발 중입니다. 사용자가 연결되어 있으면 Facebook 벽에 응용 프로그램을 게시 할 수 있습니다.Facebook SDK Unity Publish
스크립트의 문제점 InteractiveConsole.cs
사용자가 게시 버튼을 클릭 한 다음 취소 버튼을 클릭하면 "게시되지 않았습니다."라는 메시지가 표시됩니다. 게시 버튼 만 클릭하고 게시 할 때 "게시"메시지를 표시하려고합니다.
문제는 두 경우 모두 게시 또는 취소하기로 결정할 때 GUI에 "게시"메시지가 표시된다는 것입니다.
페이스 북 공유하기 취소public GUIText guiFeed;
#region FB.Feed() example
public string FeedToId = "";
public string FeedLink = "http://www.google.com";
public string FeedLinkName = "Test";
public string FeedLinkCaption = "Test Caption ";
public string FeedLinkDescription = "Test Deszcription";
public string FeedPicture = "http://www.selfspark.com/wp-content/uploads/Smiley-Face-Button.jpg";
public string FeedMediaSource = "";
public string FeedActionName = "";
public string FeedActionLink = "";
public string FeedReference = "";
public bool IncludeFeedProperties = false;
private Dictionary<string, string[]> FeedProperties = new Dictionary<string, string[]>();
public void CallFBFeed()
{
Dictionary<string, string[]> feedProperties = null;
if (IncludeFeedProperties)
{
feedProperties = FeedProperties;
}
FB.Feed(
toId: FeedToId,
link: FeedLink,
linkName: FeedLinkName,
linkCaption: FeedLinkCaption,
linkDescription: FeedLinkDescription,
picture: FeedPicture,
mediaSource: FeedMediaSource,
actionName: FeedActionName,
actionLink: FeedActionLink,
reference: FeedReference,
properties: feedProperties,
callback: LogCallback
);
}
void LogCallback(FBResult response)
{
Debug.Log(response.Text);
guiFeed.text = "response Feed:"+response.Text;
if (response.Text == null)
{
feedd.text = "not publish";
}
else
{
feedd.text = " publish";
}
}
#endregion
답변 주셔서 감사 많은,이 :) 꽤 잘 작동 – user3655933