mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-26 08:48:34 +01:00
to be safe3
This commit is contained in:
parent
4b835f8df8
commit
924e7da95f
1 changed files with 5 additions and 4 deletions
|
@ -67,12 +67,13 @@ public class PacketUpdateTileEntity implements IMessage{
|
||||||
public IMessage onMessage(PacketUpdateTileEntity message, MessageContext ctx){
|
public IMessage onMessage(PacketUpdateTileEntity message, MessageContext ctx){
|
||||||
if(message.pos != null && message.compound != null){
|
if(message.pos != null && message.compound != null){
|
||||||
World world = Minecraft.getMinecraft().theWorld;
|
World world = Minecraft.getMinecraft().theWorld;
|
||||||
|
if(world != null){
|
||||||
TileEntity tile = world.getTileEntity(message.pos);
|
TileEntity tile = world.getTileEntity(message.pos);
|
||||||
if(tile != null && tile instanceof TileEntityBase){
|
if(tile != null && tile instanceof TileEntityBase){
|
||||||
((TileEntityBase)tile).receiveSyncCompound(message.compound);
|
((TileEntityBase)tile).receiveSyncCompound(message.compound);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue