Jump to content

  • Log In with Google      Sign In   
  • Create Account

Banner advertising on our site currently available from just $5!


1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!


mrsaq

Member Since 03 Oct 2012
Offline Last Active Oct 05 2012 03:09 PM

Topics I've Started

client side prediction

03 October 2012 - 03:06 PM

Hey guys, I'm trying to do client-side prediction using a client / server UDP networking model. I'm using the design found here https://developer.valvesoftware.com/wiki/Latency_Compensating_Methods_in_Client/Server_In-game_Protocol_Design_and_Optimization as the basis of my implementation. If you run two instances of the program and use the arrow keys to move the server sends out full state updates many times a second and there is simulated lag of about half a second. If I move on the server, my input is displayed correctly and the client gets the updated state and is correct. When I move on the client, my input is correctly displayed using mypredictedinput() and is updated correctly to the server. When I receive the input acknowledged packet back from the server and I know I have a state with a stateid past my prediction is where I am lost, not sure what I'm doing right / wrong at that point.

PARTNERS