Skip to content

What exactly is bending? #141

@tknappra

Description

@tknappra

I feel that I've read everything on lance-gg.github.io that I can about bending, ie localObjBending and remoteObjBending, and I don't think I quite understand it. So, I'm hoping to get some clarification on it.

I'm a pretty decent front-end developer (I created my own front-end framework, https://duckjs.org, not trying to self-advertise, just trying to show where I'm coming from and my level of understanding), but I hardly know anything about "netcode" as they call it. From what I've researched, it's generally good to have an "authoritative server". And, according to https://forum.unity.com/threads/authoritative-server-definition.209320, I think an authoritative server system means that the server owns all data and has the "final say" in all actions, meanwhile, clients focus on rendering the server state in the best possible way and transmitting user input data to the server.

My questions regarding bending:

  1. Does remoteObjBending mean that clients have some authority over server state? Ie, is the server adjusting itself slightly to the state of clients?

  2. Does localObjBending mean that the client is bending its local state back to a previous version of its own state? If so, what is the purpose of that?

  3. Does bending only happen when using syncMode=extrapolate?

  4. Does syncMode=interpolate perform bending?

  5. Is extrapolation better than interpolation? In what contexts would you use one vs the other? It seems like you have to choose one or the other in Lance, ie you can't use both. So, I'd just like to inform myself.

  6. Also, I know this is obviously unrelated to Lance, but I found another framework called Colyseus that seems to have become popular. Is there a reason why people might choose Colyseus over Lance other than the fact that Colyseus looks like it's more client-ignostic (ie works with Unity, Cocos, Construct, etc)? I'm personally trying to make a simple browser-based multiplayer physics game similar to https://github.com/lance-gg/sprocketleague, so the built-in integrations with Cannon/P2 in Lance just make so much sense to me. I went through the Lance pong example, and I'm very impressed with how everything in Lance is architected. So, I'm really just asking this because Lance seems ideal to me, and I see no reason to use Colyseus assuming that Colyseus would perform the same stuff (ie "netcode") as Lance and with the same level of performance, right? Also, I didn't find anything on Colyseus about bending.

PS
Sorry this is a lot of questions, but I'm hoping to get some answers so that I can start building my game in Lance!

PPS
I also wanted to say thanks to all the developers for this awesome project!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions