use of network.rs485.logisticspipes.property.PropertyHolder in project LogisticsPipes by RS485.
the class PipePropertiesUpdate method processPacket.
@Override
public void processPacket(EntityPlayer player) {
LogisticsTileGenericPipe tile = this.getPipe(player.getEntityWorld(), LTGPCompletionCheck.PIPE);
if (!(tile.pipe instanceof PropertyHolder)) {
return;
}
// sync updated properties
tile.pipe.readFromNBT(tag);
MainProxy.runOnServer(player.world, () -> () -> {
// resync client; always
MainProxy.sendPacketToPlayer(fromPropertyHolder((PropertyHolder) tile.pipe).setPacketPos(this), player);
});
}
Aggregations