Integrated Dynamics

Integrated Dynamics

63M Downloads

Bug in a TE writeToNBT() method

maruohon opened this issue ยท 1 comments

commented

There seems to be either a failed copy & paste, or some left-over debug remnant here:
https://github.com/CyclopsMC/IntegratedDynamics/blob/master-1.12/src/main/java/org/cyclops/integrateddynamics/core/tileentity/TileMultipartTicking.java#L108

This is potentially quite bad, because if that markDirty() is or calls the vanilla TileEntity#markDirty(), then it can cause block updates (via World#updateComparatorOutputLevel()) and even new adjacent chunks to get loaded while the chunk this tile is in is being saved. And of course it also always marks the chunk as dirty while it's being written... which shouldn't really do anything but still.

We are currently investigating several TileEntity NBT reset related issues on the ATC server, and this is one possible cause for at least some of the issues we are seeing.

commented

That should not be there indeed.

Looks like it has been there for a long time though...

Will look into removing it for the next update.