0
votes

I have a multiplayer game that synchronizes the movement of the character via photon transform view, applying a Lerp Interpolation for a smooth movement, the shots are synchronized in each client using Photon RPC calls.

I have the following problem, when you move and shoot with a player the other clients observe that the projectiles start in a position in which the player is not yet (this uses Lerp in the synchronization of the movement).

I need to see the projectiles, so I can't make them invisible and only show a shooting animation.

what is the best way to do this?

1

1 Answers

1
votes

What you should do is take into account the player position when you start animating the projectile, so that indeed it starts shooting from where the player is and not from where the rpc, which means you also need to adjust the trajectory so that it correct itself to match the projectile real position and direction.

have you tried to minimize the lerp so that it doesn't lag? are you already at the limit of it