Hi how can I get the my friends nickname?

 for (int i = 0; i < friendList.Count; i++)


            FriendInfo friend = friendList[i];

            if ( friend.IsOnline)


                friendNickname.text = "" + <-----------???? how if its a nickname?

                friendID.text = ""+friend.UserId;






                friendNickname.text = "NO FRIENDS!";

                friendID.text = "NO IDS!";



Im using photon 2

I see this on google but not working

foreach (PhotonPlayer p in PhotonNetwork.playerList)
    string nickName = p.NickName;

any help will be appreciated



  • Hi @tataygames,

    FriendInfo contains the UserId of the friend and not the Nickname.

    You should have a way of mapping UserId with Nickname.

    Usually a friend system works best with an external service that saves the friends list + friend info. Photon just needs a unique identifier of the friend to be able to locate it and identify it. We use the UserId for this.