Understanding multiplayer local prediction...

Not favoritedFavorited Favorited 0 favourites
  • 1 posts
From the Asset Store
"Easy Local Notifications" enhances games with customizable local notifications.
  • In the MULTIPLAYER: REAL-TIME GAME example, I see that local prediction is enabled for the Peer sprite. When I play the game, I see that the sprite moves immediately on the peer and if I disable local prediction, then there’s a noticeable delay.

    So, what’s happening? I see that “on client update”, “inputs” is updated to reflect the peer’s button press states. Then every tick the peer also uses this value to move the sprite locally.

    With prediction disabled, it feels to me that “inputs” is updated once and should be sent to the host and actioned on the peer at the same time – but there’s a delay and I don’t understand why or how it's different to when prediction is enabled.

    I’m also not sure I understand WHEN “on client update” triggers!

    Any guidance would be hugely appreciated.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 0 visitors browsing this topic (0 users and 0 guests)