Commit d58d231
authored
Fix Human movement by restoring the body rotation tick (#4301)
The 25w02a update (ac2bbe5) adapted HumanEntity to Mojang's new
tickHeadTurn(float) signature but dropped the super call in the process.
Mob.tickHeadTurn is solely bodyRotationControl.clientTick(), which is the
only thing that ever writes yBodyRot, so the Human's yBodyRot was frozen
at its spawn value.
Since LookControl clamps yHeadRot to within getMaxHeadYRot() of yBodyRot
while navigating, and this override copies yHeadRot onto yRot (the vector
moveRelative steers by), the movement direction was pinned to a cone
around that stale angle and MoveControl's steering was overwritten every
tick. Humans walked into walls, moved sideways, and oscillated between
two blocks.1 parent d3d52c9 commit d58d231
1 file changed
Lines changed: 2 additions & 0 deletions
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
304 | 304 | | |
305 | 305 | | |
306 | 306 | | |
| 307 | + | |
| 308 | + | |
307 | 309 | | |
308 | 310 | | |
309 | 311 | | |
| |||
0 commit comments