mojira.dev
MC-101700

Missing server-side check in enderman teleport

The bug

The client tries to teleport endermen as well. This can cause particles and teleportation sounds to appear at the wrong position or the enderman might be away for a short moment before its position is re-synchronized.

How to reproduce

  1. Summon an enderman

  2. Punch it in Creative mode
    → It will disappear for a short moment

Code analysis

Partwise by @unknown

Based on 1.12 decompiled using MCP 9.40 PRE 1

The method net.minecraft.entity.monster.EntityEnderman.teleportRandomly() is called client-side as well which can result in different results since the random number generators are not synchronized. Additionally this method is called when the hurt animation is displayed client-side by dealing 0 unblockable damage to the enderman.

This could be solved by either adding an "is server" check in the method EntityEnderman.teleportRandomly() or maybe even better in the method net.minecraft.entity.monster.EntityEnderman.attackEntityFrom(DamageSource, float).

Linked issues

Attachments

Comments 8

Tan Chin Cheern

Isn't this like a feature or request for addition?

user-f2760

So the client teleports the enderman too and not only the server.
This cause problems if the server cancel the teleport.

This is clearly an issue, and a fix is already provided.

Franz Reiter

Any chance for a fix?

bob

Is this still an issue in the latest snapshot 16w44a? If so please update the affected versions.

This is an automated comment on any open or reopened issue with out-of-date affected versions.

marcono1234

Maybe the check should already happen in EntityEnderman.attackEntityFrom(DamageSource, float).

Sonicwave

Confirmed 1.12.1

Jon1337

Confirmed for 18w30b

Jon1337

Still in 18w50a

Franz Reiter

slicedlime

Confirmed

(Unassigned)

client-side, enderman, server-side, teleport

Minecraft 1.9.2, Minecraft 1.12, Minecraft 1.12.1, Minecraft 1.13, Minecraft 18w30b, Minecraft 1.13.2, Minecraft 18w50a

19w35a

Retrieved