[PhotonNetwork] Share strings

(The title may not be specific but I tried)


I have this game using Photon Network and want players to join maps and on server that players can create themselves. So what I mostly need is to make sure they join a level with some kind of string. So what I mostly need is to send a string over the network. If you know how to do this, please tell me!


Use an rpc

When you want to send the string use this function call:

photonView.RPC("SendString", PhotonTargets.All, "string you want to send")

define the function with an [RPC] tag:

    SendString(String doodookaka)
        String recieved_string = doodookaka;

I’m not a master at photon yet, so this might be wrong but let me know if it works.