Compare commits

..

2 commits

Author SHA1 Message Date
Ell
5909820693
Merge pull request #134 from Quarris/main
Open the gates pwease
2022-05-26 12:46:39 +02:00
Quarris
00df052755 Added a constructor for PipeBlockEntity which accepts a BlockEntityType parameter 2022-05-23 21:19:24 +01:00

View file

@ -30,6 +30,7 @@ import net.minecraft.world.item.ItemStack;
import net.minecraft.world.level.Level; import net.minecraft.world.level.Level;
import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.entity.BlockEntity;
import net.minecraft.world.level.block.entity.BlockEntityType;
import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.phys.AABB; import net.minecraft.world.phys.AABB;
import net.minecraftforge.api.distmarker.Dist; import net.minecraftforge.api.distmarker.Dist;
@ -81,6 +82,10 @@ public class PipeBlockEntity extends BlockEntity implements MenuProvider, IPipeC
super(Registry.pipeBlockEntity, pos, state); super(Registry.pipeBlockEntity, pos, state);
} }
public PipeBlockEntity(BlockEntityType<?> type, BlockPos pos, BlockState state) {
super(type, pos, state);
}
@Override @Override
public void onChunkUnloaded() { public void onChunkUnloaded() {
PipeNetwork.get(this.level).uncachePipe(this.worldPosition); PipeNetwork.get(this.level).uncachePipe(this.worldPosition);