Photon Networking – Player Movement Sync Issue with 3+ Players

I’m working on a multiplayer third-person controller using PlayCanvas for the client and Photon Realtime for networking.
Each player controls their own character, and movement data is sent through Photon events to update positions across clients.

Everything works correctly when there are only 2 players in the room — movement and updates are fully synchronized between both players.

However, when a third player joins, the synchronization breaks in a strange way:

  1. When the first joined player moves, the second and third players don’t see the movement.

  2. When the second player moves, the first player doesn’t see it, but the third player does.

  3. When the third player moves, the movement is visible to both the first and second players.

It seems like a desync starts happening once more than 2 players are connected.
I suspect it could be related to actor numbers, entity mapping, or the way I’m handling onEvent() callbacks for syncing player positions.

Here’s the test project link for reference:
:link: PlayCanvas 3D HTML5 Game Engine

If anyone has ideas or has faced a similar issue, I’d really appreciate your input! Thank you!

1 Like

Hi @rvndudz and welcome!

When working with a forked project of another user, it’s important to check the original project and the manual page. Forked versions might have problems or missing parts. Using a fork of the original project as a stable base gives you a more reliable start and makes it easier for others to help.

1 Like

Thank you @Albertos, I’ll start it again using this original project.

1 Like

Try forking this project: Multiplayer FPS Template | VisionsKlips and remove the features you don’t want.

MAKE SURE TO CHANGE THE APP ID IN THE ATTRIBUTES OF THE ROOT ENTITY IN THE PHOTON LOADBALANCING! This is because I’m using the free version of Photon and your project might blow up and I have to pay for it.

For more information about Photon App ID’s, read this article: Real-time Multiplayer with Photon | PlayCanvas Developer Site