mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-02 04:56:50 +01:00
Set world on fixed tile entity to avoid NPE. Addresses BUKKIT-3949
This commit is contained in:
parent
311f0c86a4
commit
c33908509a
1 changed files with 1 additions and 0 deletions
|
@ -139,6 +139,7 @@ public class WorldServer extends World implements org.bukkit.BlockChangeDelegate
|
||||||
|
|
||||||
if (Block.byId[type] instanceof BlockContainer) {
|
if (Block.byId[type] instanceof BlockContainer) {
|
||||||
TileEntity replacement = ((BlockContainer) Block.byId[type]).b(this);
|
TileEntity replacement = ((BlockContainer) Block.byId[type]).b(this);
|
||||||
|
replacement.world = this;
|
||||||
this.setTileEntity(x, y, z, replacement);
|
this.setTileEntity(x, y, z, replacement);
|
||||||
return replacement;
|
return replacement;
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue