Hi,
As the title says, I'm unable to sync values on Clients Joining later i.e I send the RPC already and when a client joins it doesn't get buffered on its app.
Please note:
1. I am using RpcTarget.AllBuffered
2. The RPC gets sent on Click.
Here's my code:
Important: The user (not master) gets the rpc when both have joined but RPC is not sent yet. But when the user joins later (after RPC is sent) it get the string send by rpc for a mili second before the original text appears again.
What am I doing wrong here any clues? I have just began with the RPC on Photon.
Any help would be appreciated.
Thanks in advance.
As the title says, I'm unable to sync values on Clients Joining later i.e I send the RPC already and when a client joins it doesn't get buffered on its app.
Please note:
1. I am using RpcTarget.AllBuffered
2. The RPC gets sent on Click.
Here's my code:
void Start() { testIF = GetComponent<TMP_InputField>(); textTMP = GetComponent<TextMeshProUGUI>(); } [PunRPC] public void testFunction( string testString) { textTMP.text = testString; } public void spawnBookmark() { PhotonView pv = GetComponent<PhotonView>(); if (pv.IsMine) { pv.RPC("testFunction", RpcTarget.AllBuffered, testIF.text); } }I am getting input from user on runtime and a assigned this function to button via inspector.
Important: The user (not master) gets the rpc when both have joined but RPC is not sent yet. But when the user joins later (after RPC is sent) it get the string send by rpc for a mili second before the original text appears again.
What am I doing wrong here any clues? I have just began with the RPC on Photon.
Any help would be appreciated.
Thanks in advance.