PUN keeps kicking me
Options
Since I implemented some RPCs, PUN keeps kicking me..
This seems kinda obvious why. I am calling RPCs in the Update()'s of two objects.
Further, these are both sending arrays.
I am guessing this is just too much data? What is the limit to how many RPCs I can send, or is this not actually the issue?
Sorry for such a noob question..
Thanks!
Edit: I assuming it is kicking me, all of the instantiated objects just disappear, or could this be due to a bug in my code?
This seems kinda obvious why. I am calling RPCs in the Update()'s of two objects.
Further, these are both sending arrays.
I am guessing this is just too much data? What is the limit to how many RPCs I can send, or is this not actually the issue?
Sorry for such a noob question..
Thanks!
Edit: I assuming it is kicking me, all of the instantiated objects just disappear, or could this be due to a bug in my code?
0
Comments
-
The problem was the number of RPCs. I optimised it to only send RPCs when there are changes in object states, instead of every frame, and seems to work well.
Still curious, what is the limit for RPCs?0 -
Hi @shadowsora,Still curious, what is the limit for RPCs?
I guess the disconnect hasn't been about the number of RPCs you send. Instead it has been about the size of the content you have sent. When you are sending messages which exceeds a certain limit, the server disconnects the sending client.1 -
Ah I see. Are you sure it isn't the combination of sending large objects, and at a high rate? It seems fine sending these arrays every couple of seconds instead of every frame.Christian_Simon said:Hi @shadowsora,
Still curious, what is the limit for RPCs?
I guess the disconnect hasn't been about the number of RPCs you send. Instead it has been about the size of the content you have sent. When you are sending messages which exceeds a certain limit, the server disconnects the sending client.0 -
Are you sure it isn't the combination of sending large objects, and at a high rate?
This can actually be the problem, because Photon doesn't send messages when they are 'created' on the client side, instead those messages are sent within a fixed interval. You can bypass this usingPhotonNetwork.SendOutgoingCommands();
. However if you already have the problem with such disconnects, I would recommend you taking a look at the options you have in order to reduce message size.1