Hello! I'm trying to implement a private chat. I have an inputField in which I enter the name of the required player. While sending a message, I need to check whether this player is online, how do I do this? Thank you all!
I use:
var playerList = from p in PhotonNetwork.playerList
select p;
foreach (var player in playerList)
{
if (player.NickName == name)
{
PhotonView.Get(NEED HELP).photonView.RPC("givePrivateMessage", PhotonTargets.All, text, PhotonNetwork.playerName, false);
}
}
I do not know how to call rpc from the player I need...
Sorry my english...