Class PoweredShaftBlockEntity

All Implemented Interfaces:
IHaveCustomOverlayIcon, IHaveGoggleInformation, IHaveHoveringInformation, PartialSafeNBT, SpecialBlockEntityItemRequirement, IInteractionChecker, net.createmod.ponder.api.VirtualBlockEntity, net.neoforged.neoforge.attachment.IAttachmentHolder, net.neoforged.neoforge.common.extensions.IBlockEntityExtension

public class PoweredShaftBlockEntity extends GeneratingKineticBlockEntity
  • Field Details

    • enginePos

      public net.minecraft.core.BlockPos enginePos
    • engineEfficiency

      public float engineEfficiency
    • movementDirection

      public int movementDirection
    • initialTicks

      public int initialTicks
    • capacityKey

      public net.minecraft.world.level.block.Block capacityKey
  • Constructor Details

    • PoweredShaftBlockEntity

      public PoweredShaftBlockEntity(net.minecraft.world.level.block.entity.BlockEntityType<?> typeIn, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)
  • Method Details

    • tick

      public void tick()
      Overrides:
      tick in class GeneratingKineticBlockEntity
    • update

      public void update(net.minecraft.core.BlockPos sourcePos, int direction, float efficiency)
    • remove

      public void remove(net.minecraft.core.BlockPos sourcePos)
    • canBePoweredBy

      public boolean canBePoweredBy(net.minecraft.core.BlockPos globalPos)
    • isPoweredBy

      public boolean isPoweredBy(net.minecraft.core.BlockPos globalPos)
    • write

      protected void write(net.minecraft.nbt.CompoundTag compound, net.minecraft.core.HolderLookup.Provider registries, boolean clientPacket)
      Description copied from class: SmartBlockEntity
      Hook only these in future subclasses of STE
      Overrides:
      write in class KineticBlockEntity
    • read

      protected void read(net.minecraft.nbt.CompoundTag compound, net.minecraft.core.HolderLookup.Provider registries, boolean clientPacket)
      Description copied from class: SmartBlockEntity
      Hook only these in future subclasses of STE
      Overrides:
      read in class KineticBlockEntity
    • getGeneratedSpeed

      public float getGeneratedSpeed()
      Overrides:
      getGeneratedSpeed in class KineticBlockEntity
    • calculateAddedStressCapacity

      public float calculateAddedStressCapacity()
      Overrides:
      calculateAddedStressCapacity in class KineticBlockEntity
    • getRotationAngleOffset

      public int getRotationAngleOffset(net.minecraft.core.Direction.Axis axis)
      Overrides:
      getRotationAngleOffset in class KineticBlockEntity
    • addToGoggleTooltip

      public boolean addToGoggleTooltip(List<net.minecraft.network.chat.Component> tooltip, boolean isPlayerSneaking)
      Description copied from interface: IHaveGoggleInformation
      This method will be called when looking at a BlockEntity that implements this interface
      Specified by:
      addToGoggleTooltip in interface IHaveGoggleInformation
      Overrides:
      addToGoggleTooltip in class GeneratingKineticBlockEntity
      Returns:
      true if the tooltip creation was successful and should be displayed, or false if the overlay should not be displayed
    • addToEngineTooltip

      public boolean addToEngineTooltip(List<net.minecraft.network.chat.Component> tooltip, boolean isPlayerSneaking)