Class AbstractBaseNetworkNodeContainerBlockEntity<T extends com.refinedmods.refinedstorage.api.network.impl.node.AbstractNetworkNode>

java.lang.Object
net.minecraft.world.level.block.entity.BlockEntity
com.refinedmods.refinedstorage.common.api.support.network.AbstractNetworkNodeContainerBlockEntity<T>
com.refinedmods.refinedstorage.common.support.network.AbstractBaseNetworkNodeContainerBlockEntity<T>
All Implemented Interfaces:
ConfigurationCardTarget, NetworkItemTargetBlockEntity, PlayerAwareBlockEntity, net.minecraft.world.Nameable
Direct Known Subclasses:
AbstractCableLikeBlockEntity, AbstractDiskContainerBlockEntity, AbstractGridBlockEntity, AutocrafterBlockEntity, AutocrafterManagerBlockEntity, AutocraftingMonitorBlockEntity, ControllerBlockEntity, DetectorBlockEntity, InterfaceBlockEntity, NetworkReceiverBlockEntity, NetworkTransmitterBlockEntity, RelayBlockEntity, SecurityManagerBlockEntity, StorageBlockBlockEntity, StorageMonitorBlockEntity, WirelessTransmitterBlockEntity

public abstract class AbstractBaseNetworkNodeContainerBlockEntity<T extends com.refinedmods.refinedstorage.api.network.impl.node.AbstractNetworkNode> extends AbstractNetworkNodeContainerBlockEntity<T> implements NetworkItemTargetBlockEntity, ConfigurationCardTarget, PlayerAwareBlockEntity, net.minecraft.world.Nameable
  • Nested Class Summary

    Nested classes/interfaces inherited from class net.minecraft.world.level.block.entity.BlockEntity

    net.minecraft.world.level.block.entity.BlockEntity.DataComponentInput
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
     

    Fields inherited from class com.refinedmods.refinedstorage.common.api.support.network.AbstractNetworkNodeContainerBlockEntity

    containers, mainNetworkNode

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

    level, remove, worldPosition
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    AbstractBaseNetworkNodeContainerBlockEntity(net.minecraft.world.level.block.entity.BlockEntityType<?> type, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, T networkNode)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    activenessChanged(boolean newActive)
     
    protected void
    applyImplicitComponents(net.minecraft.world.level.block.entity.BlockEntity.DataComponentInput componentInput)
     
    protected boolean
     
    protected void
    collectImplicitComponents(net.minecraft.core.component.DataComponentMap.Builder components)
     
    createMainContainer(T networkNode)
     
    protected boolean
    doesBlockStateChangeWarrantNetworkNodeUpdate(net.minecraft.world.level.block.state.BlockState oldBlockState, net.minecraft.world.level.block.state.BlockState newBlockState)
     
    void
     
    final net.minecraft.network.chat.Component
     
    final net.minecraft.network.chat.Component
     
    protected final net.minecraft.world.entity.player.Player
    getFakePlayer(net.minecraft.server.level.ServerLevel serverLevel)
     
     
     
    protected boolean
     
    protected final void
    initialize(net.minecraft.server.level.ServerLevel level)
     
    protected void
    initialize(net.minecraft.server.level.ServerLevel level, net.minecraft.core.Direction direction)
     
    protected final boolean
    isPlacedBy(UUID playerId)
     
    void
    loadAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
     
    protected final net.minecraft.network.chat.Component
    overrideName(net.minecraft.network.chat.Component defaultName)
     
    void
    readConfiguration(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
     
    void
    saveAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
     
    void
    setBlockState(net.minecraft.world.level.block.state.BlockState newBlockState)
     
    protected final void
    setCustomName(net.minecraft.network.chat.Component customName)
     
    void
    setLevel(net.minecraft.world.level.Level level)
     
    void
    setPlacedBy(UUID playerId)
     
    void
     
    void
    updateActiveness(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.state.properties.BooleanProperty activenessProperty)
     
    void
    writeConfiguration(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
     

    Methods inherited from class com.refinedmods.refinedstorage.common.api.support.network.AbstractNetworkNodeContainerBlockEntity

    clearRemoved, containerInitialized, createContainerProvider, getContainerProvider, setRemoved

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

    addEntityType, applyComponents, applyComponentsFromItemStack, collectComponents, components, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getPosFromTag, getType, getUpdatePacket, getUpdateTag, hasLevel, isRemoved, isValidBlockState, loadCustomOnly, loadStatic, loadWithComponents, onlyOpCanSetNbt, parseCustomNameSafe, removeComponentsFromTag, saveCustomAndMetadata, saveCustomOnly, saveToItem, saveWithFullMetadata, saveWithId, saveWithoutMetadata, setChanged, setChanged, setComponents, triggerEvent

    Methods inherited from class java.lang.Object

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

    Methods inherited from interface com.refinedmods.refinedstorage.common.api.configurationcard.ConfigurationCardTarget

    addUpgrade, getUpgrades

    Methods inherited from interface net.minecraft.world.Nameable

    getName, hasCustomName
  • Field Details

  • Constructor Details

    • AbstractBaseNetworkNodeContainerBlockEntity

      protected AbstractBaseNetworkNodeContainerBlockEntity(net.minecraft.world.level.block.entity.BlockEntityType<?> type, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, T networkNode)
  • Method Details

    • createMainContainer

      protected InWorldNetworkNodeContainer createMainContainer(T networkNode)
      Overrides:
      createMainContainer in class AbstractNetworkNodeContainerBlockEntity<T extends com.refinedmods.refinedstorage.api.network.impl.node.AbstractNetworkNode>
    • calculateActive

      protected boolean calculateActive()
    • updateActiveness

      public void updateActiveness(net.minecraft.world.level.block.state.BlockState state, @Nullable net.minecraft.world.level.block.state.properties.BooleanProperty activenessProperty)
    • activenessChanged

      protected void activenessChanged(boolean newActive)
    • doWork

      public void doWork()
    • doesBlockStateChangeWarrantNetworkNodeUpdate

      protected boolean doesBlockStateChangeWarrantNetworkNodeUpdate(net.minecraft.world.level.block.state.BlockState oldBlockState, net.minecraft.world.level.block.state.BlockState newBlockState)
    • setBlockState

      public void setBlockState(net.minecraft.world.level.block.state.BlockState newBlockState)
      Overrides:
      setBlockState in class net.minecraft.world.level.block.entity.BlockEntity
    • setLevel

      public void setLevel(net.minecraft.world.level.Level level)
      Overrides:
      setLevel in class net.minecraft.world.level.block.entity.BlockEntity
    • initialize

      protected final void initialize(net.minecraft.server.level.ServerLevel level)
    • initialize

      protected void initialize(net.minecraft.server.level.ServerLevel level, net.minecraft.core.Direction direction)
    • getNetworkForItem

      @Nullable public Network getNetworkForItem()
      Specified by:
      getNetworkForItem in interface NetworkItemTargetBlockEntity
    • saveAdditional

      public void saveAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
      Overrides:
      saveAdditional in class net.minecraft.world.level.block.entity.BlockEntity
    • loadAdditional

      public void loadAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
      Overrides:
      loadAdditional in class net.minecraft.world.level.block.entity.BlockEntity
    • writeConfiguration

      public void writeConfiguration(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
      Specified by:
      writeConfiguration in interface ConfigurationCardTarget
    • readConfiguration

      public void readConfiguration(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider provider)
      Specified by:
      readConfiguration in interface ConfigurationCardTarget
    • hasRedstoneMode

      protected boolean hasRedstoneMode()
    • getRedstoneMode

      public RedstoneMode getRedstoneMode()
    • setRedstoneMode

      public void setRedstoneMode(RedstoneMode redstoneMode)
    • applyImplicitComponents

      protected void applyImplicitComponents(net.minecraft.world.level.block.entity.BlockEntity.DataComponentInput componentInput)
      Overrides:
      applyImplicitComponents in class net.minecraft.world.level.block.entity.BlockEntity
    • collectImplicitComponents

      protected void collectImplicitComponents(net.minecraft.core.component.DataComponentMap.Builder components)
      Overrides:
      collectImplicitComponents in class net.minecraft.world.level.block.entity.BlockEntity
    • setCustomName

      protected final void setCustomName(@Nullable net.minecraft.network.chat.Component customName)
    • getCustomName

      @Nullable public final net.minecraft.network.chat.Component getCustomName()
      Specified by:
      getCustomName in interface net.minecraft.world.Nameable
    • overrideName

      protected final net.minecraft.network.chat.Component overrideName(net.minecraft.network.chat.Component defaultName)
    • getDisplayName

      public final net.minecraft.network.chat.Component getDisplayName()
      Specified by:
      getDisplayName in interface net.minecraft.world.Nameable
    • setPlacedBy

      public void setPlacedBy(UUID playerId)
      Specified by:
      setPlacedBy in interface PlayerAwareBlockEntity
    • getFakePlayer

      protected final net.minecraft.world.entity.player.Player getFakePlayer(net.minecraft.server.level.ServerLevel serverLevel)
    • isPlacedBy

      protected final boolean isPlacedBy(UUID playerId)