Class MachineFoundryOutletBlockEntity

java.lang.Object
net.minecraftforge.common.capabilities.CapabilityProvider<net.minecraft.world.level.block.entity.BlockEntity>
net.minecraft.world.level.block.entity.BlockEntity
com.hbm_m.block.entity.machines.MachineFoundryOutletBlockEntity
All Implemented Interfaces:
net.minecraftforge.common.capabilities.ICapabilityProvider, net.minecraftforge.common.capabilities.ICapabilityProviderImpl<net.minecraft.world.level.block.entity.BlockEntity>, net.minecraftforge.common.capabilities.ICapabilitySerializable<net.minecraft.nbt.CompoundTag>, net.minecraftforge.common.extensions.IForgeBlockEntity, net.minecraftforge.common.util.INBTSerializable<net.minecraft.nbt.CompoundTag>

public class MachineFoundryOutletBlockEntity extends net.minecraft.world.level.block.entity.BlockEntity
  • Nested Class Summary

    Nested classes/interfaces inherited from class net.minecraftforge.common.capabilities.CapabilityProvider

    net.minecraftforge.common.capabilities.CapabilityProvider.AsField<B extends net.minecraftforge.common.capabilities.ICapabilityProviderImpl<B>>
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    Only let this material through (null = all materials allowed).
    boolean
    When true: let everything EXCEPT the filter material through.
    boolean
    When true: outlet is closed by default and OPENS with redstone.

    Fields inherited from class net.minecraft.world.level.block.entity.BlockEntity

    level, remove, worldPosition

    Fields inherited from interface net.minecraftforge.common.extensions.IForgeBlockEntity

    INFINITE_EXTENT_AABB
  • Constructor Summary

    Constructors
    Constructor
    Description
    MachineFoundryOutletBlockEntity(net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.network.protocol.Packet<net.minecraft.network.protocol.game.ClientGamePacketListener>
     
    net.minecraft.nbt.CompoundTag
     
    boolean
    isClosed(net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos)
     
    void
    load(net.minecraft.nbt.CompoundTag tag)
     
    boolean
     
    int
    receiveMaterial(net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, net.minecraft.core.Direction incomingDir, MaterialType type, int amount)
    Called by an adjacent channel or crucible to offer material to this outlet.
    protected void
    saveAdditional(net.minecraft.nbt.CompoundTag tag)
     

    Methods inherited from class net.minecraft.world.level.block.entity.BlockEntity

    addEntityType, clearRemoved, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getPersistentData, getPosFromTag, getType, hasLevel, isRemoved, loadStatic, onChunkUnloaded, onlyOpCanSetNbt, saveToItem, saveWithFullMetadata, saveWithId, saveWithoutMetadata, setBlockState, setChanged, setChanged, setLevel, setRemoved, triggerEvent

    Methods inherited from class net.minecraftforge.common.capabilities.CapabilityProvider

    areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCaps

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface net.minecraftforge.common.capabilities.ICapabilityProvider

    getCapability, getCapability

    Methods inherited from interface net.minecraftforge.common.extensions.IForgeBlockEntity

    deserializeNBT, getModelData, getRenderBoundingBox, handleUpdateTag, hasCustomOutlineRendering, onDataPacket, onLoad, requestModelDataUpdate, serializeNBT
  • Field Details

    • filter

      @Nullable public MaterialType filter
      Only let this material through (null = all materials allowed).
    • invertFilter

      public boolean invertFilter
      When true: let everything EXCEPT the filter material through.
    • invertRedstone

      public boolean invertRedstone
      When true: outlet is closed by default and OPENS with redstone. When false (default): outlet is open by default and CLOSES with redstone.
  • Constructor Details

    • MachineFoundryOutletBlockEntity

      public MachineFoundryOutletBlockEntity(net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)
  • Method Details

    • isClosed

      public boolean isClosed(net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos)
    • passesFilter

      public boolean passesFilter(MaterialType type)
    • receiveMaterial

      public int receiveMaterial(net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, net.minecraft.core.Direction incomingDir, MaterialType type, int amount)
      Called by an adjacent channel or crucible to offer material to this outlet. The outlet tries to pour all offered material downward into the nearest basin. Returns how much was accepted (poured).
    • saveAdditional

      protected void saveAdditional(net.minecraft.nbt.CompoundTag tag)
      Overrides:
      saveAdditional in class net.minecraft.world.level.block.entity.BlockEntity
    • load

      public void load(net.minecraft.nbt.CompoundTag tag)
      Overrides:
      load in class net.minecraft.world.level.block.entity.BlockEntity
    • getUpdateTag

      public net.minecraft.nbt.CompoundTag getUpdateTag()
      Overrides:
      getUpdateTag in class net.minecraft.world.level.block.entity.BlockEntity
    • getUpdatePacket

      public net.minecraft.network.protocol.Packet<net.minecraft.network.protocol.game.ClientGamePacketListener> getUpdatePacket()
      Overrides:
      getUpdatePacket in class net.minecraft.world.level.block.entity.BlockEntity