示例#1
0
        public FriendCollection GetFriends()
        {
            if (IsSignedInToLive)
            {
                if (friendCollection == null)
                {
                    friendCollection = new FriendCollection();
                }

                lp.LoadFriends(delegate(string[] FriendsList, NSError error)
                {
                    foreach (string Friend in FriendsList)
                    {
                        friendCollection.Add(new FriendGamer()
                        {
                            Gamertag = Friend
                        });
                    }
                });
            }

            return(friendCollection);
        }
示例#2
0
 /// <summary>
 /// Loads the friends of this player.
 /// </summary>
 /// <param name="completionCallback">Completion callback.</param>
 public void LoadFriends(Action <Player[]> completionCallback)
 {
     gkLocalPlayer.LoadFriends(_CreateLoadFriendsCallback(completionCallback));
 }