类 TileIOHandler

java.lang.Object
committee.nova.mods.avaritia.core.io.TileIOHandler

public class TileIOHandler extends Object
IO处理器基础实现类 包含所有通用的方向转换和IO处理逻辑
  • 构造器概要

    构造器
    构造器
    说明
    TileIOHandler(net.minecraft.world.level.block.entity.BlockEntity tileEntity, net.minecraft.world.level.block.state.properties.DirectionProperty facing)
     
  • 方法概要

    修饰符和类型
    方法
    说明
    protected final net.minecraft.core.Direction
    获取方块的实际朝向
    protected final net.minecraft.core.Direction
    getRelativeDirection(net.minecraft.core.Direction relativeSide, net.minecraft.core.Direction blockFacing)
     
    protected final net.minecraft.core.Direction
    getRelativeDirectionFromAbsolute(net.minecraft.core.Direction absoluteDirection, net.minecraft.core.Direction blockFacing)
     
    protected void
    handleActiveInput(net.minecraft.core.Direction side)
    处理从指定方向的主动输入
    void
    处理主动输入输出操作
    protected void
    handleActiveOutput(net.minecraft.core.Direction side)
    处理到指定方向的主动输出
    protected void
    handleMixedIO(net.minecraft.core.Direction side)
    处理指定方向的混合IO(同时支持输入和输出)
    boolean
    shouldAllowPassiveIO(@Nullable net.minecraft.core.Direction side)
    检查被动IO配置,用于getCapability调用

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 构造器详细资料

    • TileIOHandler

      public TileIOHandler(net.minecraft.world.level.block.entity.BlockEntity tileEntity, net.minecraft.world.level.block.state.properties.DirectionProperty facing)
  • 方法详细资料

    • getRelativeDirection

      protected final net.minecraft.core.Direction getRelativeDirection(net.minecraft.core.Direction relativeSide, net.minecraft.core.Direction blockFacing)
    • getRelativeDirectionFromAbsolute

      protected final net.minecraft.core.Direction getRelativeDirectionFromAbsolute(net.minecraft.core.Direction absoluteDirection, net.minecraft.core.Direction blockFacing)
    • getBlockFacing

      protected final net.minecraft.core.Direction getBlockFacing()
      获取方块的实际朝向
    • handleActiveIO

      public void handleActiveIO()
      处理主动输入输出操作
    • handleActiveInput

      protected void handleActiveInput(net.minecraft.core.Direction side)
      处理从指定方向的主动输入
    • handleActiveOutput

      protected void handleActiveOutput(net.minecraft.core.Direction side)
      处理到指定方向的主动输出
    • handleMixedIO

      protected void handleMixedIO(net.minecraft.core.Direction side)
      处理指定方向的混合IO(同时支持输入和输出)
    • shouldAllowPassiveIO

      public boolean shouldAllowPassiveIO(@Nullable @Nullable net.minecraft.core.Direction side)
      检查被动IO配置,用于getCapability调用