Fix jittering once a tick during rendering pre-1.16 (fixes #264)
The fetching of the ticks variable was accidentally moved to before the timer update while updating to 1.16, this caused the interpolation to be off by one tick each frame in which the timer advances to the next tick.
This commit is contained in:
@@ -236,14 +236,15 @@ public class VideoRenderer implements RenderInfo {
|
|||||||
RenderTickCounter timer = ((MinecraftAccessor) mc).getTimer();
|
RenderTickCounter timer = ((MinecraftAccessor) mc).getTimer();
|
||||||
//#if MC>=11600
|
//#if MC>=11600
|
||||||
//$$ int elapsedTicks =
|
//$$ int elapsedTicks =
|
||||||
//#else
|
|
||||||
int elapsedTicks = timer.ticksThisFrame;
|
|
||||||
//#endif
|
//#endif
|
||||||
timer.beginRenderTick(
|
timer.beginRenderTick(
|
||||||
//#if MC>=11400
|
//#if MC>=11400
|
||||||
MCVer.milliTime()
|
MCVer.milliTime()
|
||||||
//#endif
|
//#endif
|
||||||
);
|
);
|
||||||
|
//#if MC<11600
|
||||||
|
int elapsedTicks = timer.ticksThisFrame;
|
||||||
|
//#endif
|
||||||
|
|
||||||
executeTaskQueue();
|
executeTaskQueue();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user