Minecraft version: 1.10.2
(It is also of note that the code presented has Forge patches applied)
PlayerChunkMap.updateMountedMovingPlayer() is not a special case for players riding other entities.
A debugger shows that it is called when ever a player moves, weather or not they are riding an entity!
PlayerCubeMap.updateMountedMovingPlayer() is called form
func_72358_d: PlayerList.serverUpdateMountedMovingPlayer() that is also misnamed.
PlayerList.serverUpdateMountedMovingPlayer() is called in 4 places
Entity entity = this.getSpectatingEntity();
if (entity != this)
{
if (entity.isEntityAlive())
{
this.setPositionAndRotation(entity.posX, entity.posY, entity.posZ, entity.rotationYaw, entity.rotationPitch);
this.mcServer.getPlayerList().serverUpdateMountedMovingPlayer(this);
if (this.isSneaking())
{
this.setSpectatingEntity(this);
}
}
else
{
this.setSpectatingEntity(this);
}
}
EntityPlayerMP.onUpdate() calls the method when they are spectating an another entity
In the other half of that if statement we findTHE SAME CALLmaking this not a special case!
In conclusion:
func_72685_d: PlayerChunkMap.updateMountedMovingPlayer()
should be changed to updateMovingPlayer() and the javadoc should read something like
"update chunks around a player that moved"
func_72358_d: PlayerList.serverUpdateMountedMovingPlayer()
should also be changed to serverUpdateMovingPlayer() and the javadoc should be something like
"using player's dimension, update the chunks around them"
Minecraft version: 1.10.2 (It is also of note that the code presented has Forge patches applied)
PlayerChunkMap.updateMountedMovingPlayer() is not a special case for players riding other entities. A debugger shows that it is called when ever a player moves, weather or not they are riding an entity!
PlayerCubeMap.updateMountedMovingPlayer() is called form func_72358_d: PlayerList.serverUpdateMountedMovingPlayer() that is also misnamed.
PlayerList.serverUpdateMountedMovingPlayer() is called in 4 places
EntityPlayerMP.onUpdate() calls the method when they are spectating an another entity
NetHendlerPlayServer.processPlayer() calls the method in a special case for riding an entity This may be where the mistake was made
In the other half of that if statement we find THE SAME CALL making this not a special case!
In conclusion:
func_72685_d: PlayerChunkMap.updateMountedMovingPlayer() should be changed to updateMovingPlayer() and the javadoc should read something like "update chunks around a player that moved"
func_72358_d: PlayerList.serverUpdateMountedMovingPlayer() should also be changed to serverUpdateMovingPlayer() and the javadoc should be something like "using player's dimension, update the chunks around them"