Mojira Archive
MC-268535

The distances some entities travel are miscalculated

The distances some entities travel seem to be wrongly calculated. The affected entities (that I found) include Primed TNTs, Falling Blocks, Minecarts, Players, Items and most mobs. Unaffected entities include Snowballs, Arrows and Boats. Instead of following the equation s=vt (where s is the distance the entity travels in one game tick, v is the velocity of the entity in that tick, t=0.05 seconds which is 1 tick), it seems like s=kvt, where k is a constant that depends on the type of the entity.

Steps to reproduce

  1. Teleport yourself to a high place: /tp @s ~ 300 ~
  2. Summon a primed TNT entity with a very long fuse (so it doesn't explode): /summon tnt ~ ~ ~ {fuse:30000}
  3. Freeze the game: /tick freeze
  4. Get the y-coordinate of the TNT in millimeters: /data get entity @e[type=tnt,limit=1,sort=nearest] Pos[1] 1000
  5. Step 1 tick: /tick step 1t
  6. Get the velocity of the TNT in millimeters per second: /data get entity @e[type=tnt,limit=1,sort=nearest] Motion[1] -20000
  7. Repeat step 4
  8. (x)When you multiply the velocity in step 6 by 0.05 seconds, you don't get the difference of the two y-coordinates in steps 4&7

In the video, I summoned a TNT with an initial velocity of 39.2m/s (downward). This is its terminal velocity, which is the velocity that makes its gravity and air friction entirely cancel out, so its velocity is always 39.2m/s. It should move 39.2m/s*0.05s=1.96m in one tick, but it moved 2.00m. Ignore the scoreboard in the video.