Topic: what kind of objects are interpolated?
Reading through the source code, I think characters and flags are interpolated. But are there any other objects that are interpolated? Are things like bullets and hooks interpolated at all?
You are not logged in. Please login or register.
Teeworlds Forum → Development → what kind of objects are interpolated?
Reading through the source code, I think characters and flags are interpolated. But are there any other objects that are interpolated? Are things like bullets and hooks interpolated at all?
As far as hooks are concerned all the data you need is the 2 end points, the player and the wall/other player. So no need to calculate anything.
As for bullets, they might not be interpolated, but that might create problems, or might work work perfectly well, depending on implementation. So you'd really have to check.
As far as I know interpolated objects in vanilla are :
-yourself (your tee), this includes collision and any sort of hook forces; other players are NOT interpolated in vanilla
-bullets
Flags are not interpolated but afaik "attached" to their carrier, if they have no carrier they are not interpolated.
Regards
Essentially everything is (linearly) interpolated. One exception is the own player, which is even extrapolated, i.e. predicted even further than what the server sent you.
Essentially everything is (linearly) interpolated. One exception is the own player, which is even extrapolated, i.e. predicted even further than what the server sent you.
Thank you for the response
Let's say I was at (20, 10) according to server and a bullet hits me at that position. But my client displayed rendered myself at predicted position (23, 10), which leads to a discrepancy - I got hit by the bullet even though it looked like I wasn't hit. Theoretically this could happen right?
Although this can happen, this shouldn't because your client should predict the gun the right way (tunings are sent to the client) so if the server isn't moving your tee, you won't collide with the bullet if your client doesn't show you colliding with the bullet (and the bullet is there, of course).
Maybe I am completely wrong and that's antiping approach but I think this is vanilla
Let's say I was at (20, 10) according to server and a bullet hits me at that position. But my client displayed rendered myself at predicted position (23, 10), which leads to a discrepancy - I got hit by the bullet even though it looked like I wasn't hit. Theoretically this could happen right?
If I understand you and the game correctly, I think that this could happen. For example: Bullet heading for (20, 10), your current position. As you want to dodge, you press right, your client predicts that you move right, moving you on the screen. Network problems: The server doesn't receive your request to move right. Bullet hits you at (20, 10), the server informs you that you're still in that position. The client will reset your position to (20, 10), because the server said you didn't move.
Teeworlds Forum → Development → what kind of objects are interpolated?
Powered by PunBB, supported by Informer Technologies, Inc.
Currently installed 3 official extensions. Copyright © 2003–2009 PunBB.