PUN 2, Remote clients position right after joining.
Options
Photonview is set to send "Unreliable On Change" and I also check our byte array for changes before sending. (added code below) I'm using CullArea and CullHandler with almost no modifications.
When a player joins a room with remote clients already available, and those remote clients prefab doesn't move or update it's values, the remote clients prefabs position remains in the Instantiated position.
I think this happens because that remote client doesn't send anything with OnPhotonSerializeView after player entered. When the player moves or rotates or does anything to send a stream again, it fixes the issue.
However I couldn't find a good way of fixing this. Do you think it may be caused by myself checking if byte array is the same in the OnPhotonSerializeView function? Should I make this check elsewhere?
Thank you.
Mehmet
When a player joins a room with remote clients already available, and those remote clients prefab doesn't move or update it's values, the remote clients prefabs position remains in the Instantiated position.
I think this happens because that remote client doesn't send anything with OnPhotonSerializeView after player entered. When the player moves or rotates or does anything to send a stream again, it fixes the issue.
However I couldn't find a good way of fixing this. Do you think it may be caused by myself checking if byte array is the same in the OnPhotonSerializeView function? Should I make this check elsewhere?
if (lastSent == null || byteArry.Length != lastSent.Length || !byteArry.SequenceEqual(lastSent))
{
stream.SendNext(byteArry);
lastSent = new byte[byteArry.Length];
System.Array.Copy(byteArry, lastSent, byteArry.Length);
}
Thank you.
Mehmet
0