[Easy One]what is the photon Function for:

whats the photon function for “OnPlayerConnected”?

im trying to send an RPC when a new player connects, its not working.

the command:

void OnPlayerConnected (PhotonPlayer netPlayer)
		//Add the player to the list. This is executed on the server.
		photonView.RPC("AddPlayerToList", PhotonTargets.AllBuffered, netPlayer);

the execution

	void AddPlayerToList (PhotonPlayer nPlayer)
		//Create a new entry in the PlayerList and supply the
		//player's network ID as the first entry.
		joinedlist = true;
		Playerdataclas capture = new Playerdataclas();
		capture.networkPlayer = int.Parse(nPlayer.ToString());

" void OnPhotonPlayerConnected (PhotonPlayer player) {" - OrangeLightning (comments)