PUN 2.9, have not run the OnJoinedRoom callback when I was the second one into the room
Options
I use the PUN 2.9 . I found when I was the first one into the room(which means I was the ClientMaster).Everything is OK. But when I was the second one into the room. The function "OnJoinedRoom" would not run. It just switch to the sync scene. But I did not write any code to load the scene. What I want is callback the OnjoinedRoom, And then load a loading scene. finally get into my sync scene. My sync scene is too big to direct load. There would be a lag.
I hope you know what I mean. My English is so poor. If there is any confuse. Please just ask me.
I hope you know what I mean. My English is so poor. If there is any confuse. Please just ask me.
0
Comments
-
Unless you turn this on, PUN should not load a scene, so something in your code must have that side-effect.
Enable the SupportLogger in the PhotonServerSettings. It will log OnJoinedRoom for you.
Maybe your script does not register for callbacks or is no longer existing when the other scene loads?!
This is related:
https://doc.photonengine.com/en-us/pun/v2/gameplay/instantiation/rpcsandraiseevent
Especially "Switching Scenes".
This contains info about automatic scene synchronization (in part 4 of the tutorial):
https://doc.photonengine.com/en-us/pun/v2/demos-and-tutorials/pun-basics-tutorial/intro0