-
Bug
-
Resolution: Duplicate
-
None
-
1.21.3
-
None
-
Unconfirmed
-
(Unassigned)
this is technically a duplicate of MC-142246, but that was closed as resolved, so I made this new one
when flying wit an elytra at higher speeds with fireworks, the player starts to flicker
this is caused by floating point inprecissions
inĀ
net.minecraft.client.renderer.entity.player.PlayerRenderer#extractFlightData
in this part
if (d > 0.0 && d2 > 0.0) { playerRenderState.shouldApplyFlyingYRot = true; double d3 = (vec32.x * vec3.x + vec32.z * vec3.z) / Math.sqrt(d * d2); double d4 = vec32.x * vec3.z - vec32.z * vec3.x; playerRenderState.flyingYRot = (float)(Math.signum(d4) * Math.acos(d3)); }
d3 can get sligthly above 1 (like 1.0000000000000002), which produces a NaN, because acos of >1 is NaN
- duplicates
-
MC-111516 Player flickers/turns invisible when flying at high speeds
- Resolved