...
코드 블럭 | ||
---|---|---|
| ||
using KakaoGame.API; KGTKakaoTalk.ShowSetting((result) => { if (result.IsSuccess) { // Successfully set the KakaoTalk game message reception settings } else if (result.code == KGTResultCode.NotKakaoTalkUser) { // The logged-in user is not a 'KakaoTalk' user. This occurs when the user is notonly aregistered KakaoTalkwith user,KakaoStory suchand as in the case of a user who is only registered for KakaoStorynot KakaoTalk. } else { // Failed to set the KakaoTalk game message reception settings } }); |
...
코드 블럭 | ||
---|---|---|
| ||
using KakaoGame.API; KGTKakaoTalk.TalkProfile((result) => { if (result.IsSuccess) { // Successfully retrieved KakaoTalk profile KGTKakaoTalkProfile talkProfile = result.Content; } else if (result.code == KGTResultCode.NotKakaoTalkUser) { // The logged-in user is not a 'KakaoTalk' user. This occurs when the user is notonly aregistered KakaoTalkwith user,KakaoStory suchand as in the case of a user who is only registered for KakaoStorynot KakaoTalk. } else { // Failed to retrieve KakaoTalk profile } }); |
...
코드 블럭 | ||
---|---|---|
| ||
using KakaoGame.API; KGTKakaoTalk.Friends((result) => { if (result.IsSuccess) { var players = result.Content; // Successfully retrieved KakaoTalk game friends list. foreach(var player in players) { var kakaoProfile = (KGTKakaoProfile)player.IdpProfile; // Used when sending game messages } } else if (result.code == KGTResultCode.NotKakaoTalkUser) { // The logged-in user is not a 'KakaoTalk' user. This occurs when the user is not a KakaoTalk user, such as in the case of a user who when the user is only registered forwith KakaoStory and not KakaoTalk. } else { // Failed to retrieve KakaoTalk game message reception settings } }); |
...
코드 블럭 | ||
---|---|---|
| ||
using KakaoGame.API; // Through the Friends API KGTKakaoFriendProfile kakaoProfile; // Kakao profile (KGTKakaoFriendProfile object) // [TODO] Set the template Id string templateId; // [TODO] Set the arguments for the message template Dictionary<string, object> argumentDic = new Dictionary<string, object>(); KGTKakaoTalk.SendGameMessage(kakaoProfile, templateId, argumentDic, (result) => { if (result.IsSuccess) { // Successfully sent a KakaoTalk chat message. } else if (result.code == KGTResultCode.MessageSettingDisabled) { // The recipient has set message reception to be disabled. } else if (result.code == KGTResultCode.ExceedDailyUsage) { // Occurs when the daily quota for sending messages to a specific app (regardless of the recipient) is exceeded. } else if (result.code == KGTResultCode.ExceedMonthlyUsage) { // Occurs when the monthly quota for sending messages to a specific person for a specific app is exceeded. } else if (result.code == KGTResultCode.NotKakaoTalkUser) { // The logged-in user is not a 'KakaoTalk' user. This occurs when the user is notonly aregistered KakaoTalkwith user,KakaoStory suchand as in the case of a user who is only registered for KakaoStorynot KakaoTalk. } else { // Failed to send KakaoTalk chat message. } }); |
...
코드 블럭 | ||
---|---|---|
| ||
using KakaoGame.API; // [TODO] Set the channel Id int channelId; KGTKakaoTalk.AddChannel(channelId, (result) => { if (result.IsSuccess) { // Successfully added friend } else if (result.code == KGTResultCode.NotKakaoTalkUser) { // The logged-in user is not a 'KakaoTalk' user. This occurs when the user is notonly aregistered KakaoTalkwith user,KakaoStory suchand as in the case of a user who is only registered for KakaoStorynot KakaoTalk. } else { // Failed to add friend } }); |
...