Crazy house in PUN room.

Options
Volk
Volk
Hi!

Sometimes I go into an existing room (where players are already playing) and there is some horror happening. This horror lasts for a while (usually from 30 seconds to a minute), and then everything normalizes. Not enough time to record the video, but I'll try next time. Although it's easy to imagine this situation (example in this video, only very quickly: https://radikal.ru/video/bWm0pCBilsq ).

In general, all the objects (PhotonView) begin to move around the location furiously and jerkily as "Figaro here, Figaro there"... They flash at different coordinates, do something quickly and then disappear again, appear in different places, and so on. After a while, this circus ends and the game goes on as usual.

May be (IMHO) RPC commands accumulate on the PUN server (in a bufer) while MasterClient is playing, and then all these commands are quickly sent to those who join this room.

BUT! I use in the project only:

RpcTarget.Others
Sends the RPC to everyone else. This client does not execute the RPC. Player who join later will not execute this RPC.

NOT: RpcTarget.AllBuffered or RpcTarget.OthersBuffered.

Please tell me what the problem may be and how can I get rid of this in my game?

Thanks!

Comments

  • Tobias
    Options
    We can not really look this up for you. If you don't use the *Buffered variants of RPCs, then this should not be the cause, right.
    You may want to debug this some more and figure out if this is triggered by event from the server or what else causes the objects to move. You could Debug.Log() in the OnPhotonSerializeView callbacks and RPCs of a specific item, to see how many updates it gets.
  • Volk
    Volk
    edited March 2021
    Options
    Tobias wrote: »
    We can not really look this up for you. If you don't use the *Buffered variants of RPCs, then this should not be the cause, right.
    You may want to debug this some more and figure out if this is triggered by event from the server or what else causes the objects to move. You could Debug.Log() in the OnPhotonSerializeView callbacks and RPCs of a specific item, to see how many updates it gets.

    Thanks for the answer! This situation is quite rare. I thought that maybe someone faced this problem. Ok! I'll try to check my code. :) The thing is that my code does not control the NOT-MASTER-CLIENT-OBJECT transform - so I reasonably decided that the problem is on the PUN side. On the MASTER-CLIENT side, everything was correct at that moment. o:)