Could you provide a repository that we could look at? This seems like an issue that could encompass many parts of the code, and providing the full scope could help. Also I want to say, your graphical style is really slick.
You have RigidBody of your character only on server side. The code may work even if you have bodies both on client and server side. I’d like not to tempt fate.
Position and rotation are Node attributes, while linear and angular velocities are RigidBody attributes. To cut down on the needed network bandwidth the physics components can be created as local on the server: in this case the client will not see them at all, and will only interpolate motion based on the node’s transform changes. Replicating the actual physics components allows the client to extrapolate using its own physics simulation, and to also perform collision detection, though always non-authoritatively.
By default the physics simulation also performs interpolation to enable smooth motion when the rendering framerate is higher than the physics FPS. This should be disabled on the server scene to ensure that the clients do not receive interpolated and therefore possibly non-physical positions and rotations. See SetInterpolation().
If you have character on the server side only, it should be fine.
Then, just turn off physics interpolation on the server side.
If it doen’t help… well, make a sample for ppl to try it. I’ve never seen such bugs with sample network app.
If someone want to see this in-game: https://puu.sh/zCy4x/f004273bf4.rar
(should run login server, after game server)(can type any login and pw, and dont need a character nick)(to walk let mouse button left pressing or double click with mouse button left)
void CMapHandler::CreateScene() - create scene to server and maps collision
CCharacter * CCharacterHandler::LoadCharacter( Connection * pConnection, String strCharacterName ) - instantie XML responsible for character node and create the logic component CCharacter
void CCharacter::FixedUpdate( float fTime ) - physics of each character at scene
I really dno what more can be, Im “newbie” on Urho3D, and until now this is the unique problem I dont solved.
I’m looking at your code and I’m not sure that the Client doesn’t have RigidBody component: in the file Server Data\Objects\Character.xml there is replicated RigidBody component that is probably replicated on the client side.