source-sdk-2013
source-sdk-2013 copied to clipboard
Fixed server physics when server has custom tickrate
Shouldn't the client tickrate also be adjusted? Otherwise it would desync?
https://github.com/ValveSoftware/source-sdk-2013/blob/master/mp/src/game/client/physics.cpp#L180
-physenv->SetSimulationTimestep( IsXbox() ? DEFAULT_XBOX_CLIENT_VPHYSICS_TICK : DEFAULT_TICK_INTERVAL );
+physenv->SetSimulationTimestep( IsXbox() ? DEFAULT_XBOX_CLIENT_VPHYSICS_TICK : gpGlobals->interval_per_tick );
Shouldn't the client tickrate also be adjusted? Otherwise it would desync?
https://github.com/ValveSoftware/source-sdk-2013/blob/master/mp/src/game/client/physics.cpp#L180
-physenv->SetSimulationTimestep( IsXbox() ? DEFAULT_XBOX_CLIENT_VPHYSICS_TICK : DEFAULT_TICK_INTERVAL ); +physenv->SetSimulationTimestep( IsXbox() ? DEFAULT_XBOX_CLIENT_VPHYSICS_TICK : gpGlobals->interval_per_tick );
I've ran hl2dm server at 44 tickrate with this like for a year, and i didn't noticed any strange behavior on client.