Interface FabricBlockModelShaper
public interface FabricBlockModelShaper
Note: This interface is automatically implemented on
BlockModelShaper via Mixin and interface injection.-
Method Summary
Modifier and TypeMethodDescriptiondefault net.minecraft.client.renderer.texture.TextureAtlasSpritegetParticleIcon(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockAndTintGetter level, net.minecraft.core.BlockPos pos) Alternative forBlockModelShaper.getParticleIcon(BlockState)that additionally accepts aBlockAndTintGetterandBlockPosto invokeFabricBlockStateModel.particleIcon(BlockAndTintGetter, BlockPos, BlockState).
-
Method Details
-
getParticleIcon
default net.minecraft.client.renderer.texture.TextureAtlasSprite getParticleIcon(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockAndTintGetter level, net.minecraft.core.BlockPos pos) Alternative forBlockModelShaper.getParticleIcon(BlockState)that additionally accepts aBlockAndTintGetterandBlockPosto invokeFabricBlockStateModel.particleIcon(BlockAndTintGetter, BlockPos, BlockState). Prefer using this method over the vanilla alternative when applicable to correctly retrieve context-aware particle sprites. If level context is not available, use the vanilla method instead of passing empty level context to this method.- Parameters:
state- The block state whose model to retrieve the particle sprite from.level- The level in which the block exists. Should not be empty (i.e. notEmptyBlockAndTintGetter).pos- The position of the block in the level.- Returns:
- the particle sprite
-