Record Class ProxyBlockAndTintGetter

java.lang.Object
java.lang.Record
codechicken.multipart.util.ProxyBlockAndTintGetter
All Implemented Interfaces:
net.minecraft.world.level.BlockAndTintGetter, net.minecraft.world.level.BlockGetter, net.minecraft.world.level.LevelHeightAccessor, net.neoforged.neoforge.common.extensions.IBlockAndTintGetterExtension, net.neoforged.neoforge.common.extensions.IBlockGetterExtension

public record ProxyBlockAndTintGetter(net.minecraft.world.level.BlockAndTintGetter other, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, net.neoforged.neoforge.model.data.ModelData modelData) extends Record implements net.minecraft.world.level.BlockAndTintGetter
A simple BlockAndTintGetter implementation proxying the world, except for the given position.

Created by covers1624 on 7/18/26.

  • Nested Class Summary

    Nested classes/interfaces inherited from interface net.minecraft.world.level.BlockGetter

    net.minecraft.world.level.BlockGetter.BlockStepVisitor
  • Constructor Summary

    Constructors
    Constructor
    Description
    ProxyBlockAndTintGetter(net.minecraft.world.level.BlockAndTintGetter other, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, net.neoforged.neoforge.model.data.ModelData modelData)
    Creates an instance of a ProxyBlockAndTintGetter record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    final boolean
    Indicates whether some other object is "equal to" this one.
    @Nullable net.minecraft.world.level.block.entity.BlockEntity
    getBlockEntity(net.minecraft.core.BlockPos pos)
     
    net.minecraft.world.level.block.state.BlockState
    getBlockState(net.minecraft.core.BlockPos pos)
     
    int
    getBlockTint(net.minecraft.core.BlockPos pos, net.minecraft.world.level.ColorResolver resolver)
     
    net.minecraft.world.level.material.FluidState
    getFluidState(net.minecraft.core.BlockPos pos)
     
    int
     
    net.minecraft.world.level.lighting.LevelLightEngine
     
    int
     
    net.neoforged.neoforge.model.data.ModelData
    getModelData(net.minecraft.core.BlockPos pos)
     
    float
    getShade(net.minecraft.core.Direction face, boolean shade)
     
    final int
    Returns a hash code value for this object.
    net.neoforged.neoforge.model.data.ModelData
    Returns the value of the modelData record component.
    net.minecraft.world.level.BlockAndTintGetter
    Returns the value of the other record component.
    net.minecraft.core.BlockPos
    pos()
    Returns the value of the pos record component.
    net.minecraft.world.level.block.state.BlockState
    Returns the value of the state record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface net.minecraft.world.level.BlockAndTintGetter

    canSeeSky, getBrightness, getRawBrightness

    Methods inherited from interface net.minecraft.world.level.BlockGetter

    clip, clipWithInteractionOverride, getBlockEntity, getBlockFloorHeight, getBlockFloorHeight, getBlockStates, getLightEmission, isBlockInLine

    Methods inherited from interface net.neoforged.neoforge.common.extensions.IBlockAndTintGetterExtension

    getShade

    Methods inherited from interface net.neoforged.neoforge.common.extensions.IBlockGetterExtension

    getAuxLightManager, getAuxLightManager

    Methods inherited from interface net.minecraft.world.level.LevelHeightAccessor

    getMaxSectionY, getMaxY, getMinSectionY, getSectionIndex, getSectionIndexFromSectionY, getSectionsCount, getSectionYFromSectionIndex, isInsideBuildHeight, isOutsideBuildHeight, isOutsideBuildHeight
  • Constructor Details

    • ProxyBlockAndTintGetter

      public ProxyBlockAndTintGetter(net.minecraft.world.level.BlockAndTintGetter other, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, net.neoforged.neoforge.model.data.ModelData modelData)
      Creates an instance of a ProxyBlockAndTintGetter record class.
      Parameters:
      other - the value for the other record component
      pos - the value for the pos record component
      state - the value for the state record component
      modelData - the value for the modelData record component
  • Method Details

    • getModelData

      public net.neoforged.neoforge.model.data.ModelData getModelData(net.minecraft.core.BlockPos pos)
      Specified by:
      getModelData in interface net.neoforged.neoforge.common.extensions.IBlockGetterExtension
    • getBlockState

      public net.minecraft.world.level.block.state.BlockState getBlockState(net.minecraft.core.BlockPos pos)
      Specified by:
      getBlockState in interface net.minecraft.world.level.BlockGetter
    • getShade

      public float getShade(net.minecraft.core.Direction face, boolean shade)
      Specified by:
      getShade in interface net.minecraft.world.level.BlockAndTintGetter
    • getLightEngine

      public net.minecraft.world.level.lighting.LevelLightEngine getLightEngine()
      Specified by:
      getLightEngine in interface net.minecraft.world.level.BlockAndTintGetter
    • getBlockTint

      public int getBlockTint(net.minecraft.core.BlockPos pos, net.minecraft.world.level.ColorResolver resolver)
      Specified by:
      getBlockTint in interface net.minecraft.world.level.BlockAndTintGetter
    • getBlockEntity

      public @Nullable net.minecraft.world.level.block.entity.BlockEntity getBlockEntity(net.minecraft.core.BlockPos pos)
      Specified by:
      getBlockEntity in interface net.minecraft.world.level.BlockGetter
    • getFluidState

      public net.minecraft.world.level.material.FluidState getFluidState(net.minecraft.core.BlockPos pos)
      Specified by:
      getFluidState in interface net.minecraft.world.level.BlockGetter
    • getHeight

      public int getHeight()
      Specified by:
      getHeight in interface net.minecraft.world.level.LevelHeightAccessor
    • getMinY

      public int getMinY()
      Specified by:
      getMinY in interface net.minecraft.world.level.LevelHeightAccessor
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • other

      public net.minecraft.world.level.BlockAndTintGetter other()
      Returns the value of the other record component.
      Returns:
      the value of the other record component
    • pos

      public net.minecraft.core.BlockPos pos()
      Returns the value of the pos record component.
      Returns:
      the value of the pos record component
    • state

      public net.minecraft.world.level.block.state.BlockState state()
      Returns the value of the state record component.
      Returns:
      the value of the state record component
    • modelData

      public net.neoforged.neoforge.model.data.ModelData modelData()
      Returns the value of the modelData record component.
      Returns:
      the value of the modelData record component