Package net.minecraft.block
Class FireBlock
- java.lang.Object
-
- All Implemented Interfaces:
IItemProvider,IForgeBlock,IForgeRegistryEntry<Block>
public class FireBlock extends AbstractFireBlock
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class net.minecraft.block.Block
Block.RenderSideCacheKey
-
Nested classes/interfaces inherited from class net.minecraft.block.AbstractBlock
AbstractBlock.AbstractBlockState, AbstractBlock.IExtendedPositionPredicate<A>, AbstractBlock.IPositionPredicate, AbstractBlock.OffsetType, AbstractBlock.Properties
-
Nested classes/interfaces inherited from class net.minecraftforge.registries.ForgeRegistryEntry
ForgeRegistryEntry.UncheckedRegistryEntry<V extends IForgeRegistryEntry<V>>
-
-
Field Summary
Fields Modifier and Type Field Description static IntegerPropertyAGEprivate it.unimi.dsi.fastutil.objects.Object2IntMap<Block>burnOddsstatic BooleanPropertyEASTprivate static VoxelShapeEAST_AABBprivate it.unimi.dsi.fastutil.objects.Object2IntMap<Block>flameOddsstatic BooleanPropertyNORTHprivate static VoxelShapeNORTH_AABBprivate static java.util.Map<Direction,BooleanProperty>PROPERTY_BY_DIRECTIONprivate java.util.Map<BlockState,VoxelShape>shapesCachestatic BooleanPropertySOUTHprivate static VoxelShapeSOUTH_AABBstatic BooleanPropertyUPprivate static VoxelShapeUP_AABBstatic BooleanPropertyWESTprivate static VoxelShapeWEST_AABB-
Fields inherited from class net.minecraft.block.AbstractFireBlock
DOWN_AABB
-
Fields inherited from class net.minecraft.block.Block
BLOCK_STATE_REGISTRY, LOGGER, RANDOM, stateDefinition
-
Fields inherited from class net.minecraft.block.AbstractBlock
drops, dynamicShape, explosionResistance, friction, hasCollision, isRandomlyTicking, jumpFactor, material, properties, soundType, speedFactor, UPDATE_SHAPE_ORDER
-
Fields inherited from class net.minecraftforge.registries.ForgeRegistryEntry
delegate
-
-
Constructor Summary
Constructors Constructor Description FireBlock(AbstractBlock.Properties p_i48397_1_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static voidbootStrap()private static VoxelShapecalculateShape(BlockState p_242673_0_)protected booleancanBurn(BlockState p_196446_1_)Deprecated.booleancanCatchFire(IBlockReader world, BlockPos pos, Direction face)Side sensitive version that calls the block function.booleancanSurvive(BlockState p_196260_1_, IWorldReader p_196260_2_, BlockPos p_196260_3_)protected voidcreateBlockStateDefinition(StateContainer.Builder<Block,BlockState> p_206840_1_)intgetBurnOdd(BlockState p_220274_1_)Deprecated.private intgetFireOdds(IWorldReader p_176538_1_, BlockPos p_176538_2_)private static intgetFireTickDelay(java.util.Random p_235495_0_)intgetFlameOdds(BlockState p_220275_1_)Deprecated.VoxelShapegetShape(BlockState p_220053_1_, IBlockReader p_220053_2_, BlockPos p_220053_3_, ISelectionContext p_220053_4_)BlockStategetStateForPlacement(BlockItemUseContext p_196258_1_)protected BlockStategetStateForPlacement(IBlockReader p_196448_1_, BlockPos p_196448_2_)private BlockStategetStateWithAge(IWorld p_235494_1_, BlockPos p_235494_2_, int p_235494_3_)protected booleanisNearRain(World p_176537_1_, BlockPos p_176537_2_)private booleanisValidFireLocation(IBlockReader p_196447_1_, BlockPos p_196447_2_)voidonPlace(BlockState p_220082_1_, World p_220082_2_, BlockPos p_220082_3_, BlockState p_220082_4_, boolean p_220082_5_)private voidsetFlammable(Block p_180686_1_, int p_180686_2_, int p_180686_3_)voidtick(BlockState p_225534_1_, ServerWorld p_225534_2_, BlockPos p_225534_3_, java.util.Random p_225534_4_)private voidtryCatchFire(World p_176536_1_, BlockPos p_176536_2_, int p_176536_3_, java.util.Random p_176536_4_, int p_176536_5_, Direction face)BlockStateupdateShape(BlockState p_196271_1_, Direction p_196271_2_, BlockState p_196271_3_, IWorld p_196271_4_, BlockPos p_196271_5_, BlockPos p_196271_6_)-
Methods inherited from class net.minecraft.block.AbstractFireBlock
animateTick, canBePlacedAt, entityInside, getState, playerWillDestroy
-
Methods inherited from class net.minecraft.block.Block
appendHoverText, asBlock, asItem, box, byItem, canSupportCenter, canSupportRigidBlock, canSustainPlant, defaultBlockState, destroy, dropFromExplosion, dropResources, dropResources, dropResources, fallOn, fillItemCategory, getCloneItemStack, getDescriptionId, getDrops, getDrops, getExplosionResistance, getFriction, getHarvestLevel, getHarvestTool, getId, getJumpFactor, getName, getSoundType, getSpeedFactor, getStateDefinition, getTags, handleRain, hasDynamicShape, is, is, isExceptionForConnection, isFaceFull, isPossibleToRespawnInThis, isRandomlyTicking, isShapeFullBlock, playerDestroy, popExperience, popResource, propagatesSkylightDown, pushEntitiesUp, registerDefaultState, setPlacedBy, shouldRenderFace, stateById, stepOn, toString, updateEntityAfterFallOn, updateFromNeighbourShapes, updateOrDestroy, updateOrDestroy, wasExploded
-
Methods inherited from class net.minecraft.block.AbstractBlock
attack, canBeReplaced, canBeReplaced, defaultMaterialColor, getAnalogOutputSignal, getBlockSupportShape, getCollisionShape, getDestroyProgress, getDirectSignal, getDrops, getFluidState, getInteractionShape, getLightBlock, getLootTable, getMenuProvider, getOcclusionShape, getOffsetType, getPistonPushReaction, getRenderShape, getSeed, getShadeBrightness, getSignal, getVisualShape, hasAnalogOutputSignal, isAir, isEntityBlock, isPathfindable, isSignalSource, mirror, neighborChanged, onProjectileHit, onRemove, randomTick, rotate, skipRendering, spawnAfterBreak, triggerEvent, updateIndirectNeighbourShapes, use, useShapeForLightOcclusion
-
Methods inherited from class net.minecraftforge.registries.ForgeRegistryEntry
getRegistryName, getRegistryType, setRegistryName, setRegistryName, setRegistryName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface net.minecraftforge.common.extensions.IForgeBlock
addDestroyEffects, addHitEffects, addLandingEffects, addRunningEffects, canBeReplacedByLeaves, canBeReplacedByLogs, canConnectRedstone, canCreatureSpawn, canDropFromExplosion, canEntityDestroy, canHarvestBlock, canStickTo, catchFire, collisionExtendsVertically, createTileEntity, getAiPathNodeType, getBeaconColorMultiplier, getBedDirection, getBedSpawnPosition, getBlock, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getFireSpreadSpeed, getFlammability, getFogColor, getLightValue, getPickBlock, getRespawnPosition, getSlipperiness, getSoundType, getStateAtViewpoint, getToolModifiedState, getWeakChanges, hasTileEntity, isAir, isBed, isBurning, isConduitFrame, isFertile, isFireSource, isFlammable, isLadder, isPortalFrame, isScaffolding, isSlimeBlock, isStickyBlock, isToolEffective, makesOpenTrapdoorAboveClimbable, observedNeighborChange, onBlockExploded, onNeighborChange, onPlantGrow, removedByPlayer, rotate, setBedOccupied, shouldCheckWeakPower, shouldDisplayFluidOverlay
-
-
-
-
Field Detail
-
AGE
public static final IntegerProperty AGE
-
NORTH
public static final BooleanProperty NORTH
-
EAST
public static final BooleanProperty EAST
-
SOUTH
public static final BooleanProperty SOUTH
-
WEST
public static final BooleanProperty WEST
-
UP
public static final BooleanProperty UP
-
PROPERTY_BY_DIRECTION
private static final java.util.Map<Direction,BooleanProperty> PROPERTY_BY_DIRECTION
-
UP_AABB
private static final VoxelShape UP_AABB
-
WEST_AABB
private static final VoxelShape WEST_AABB
-
EAST_AABB
private static final VoxelShape EAST_AABB
-
NORTH_AABB
private static final VoxelShape NORTH_AABB
-
SOUTH_AABB
private static final VoxelShape SOUTH_AABB
-
shapesCache
private final java.util.Map<BlockState,VoxelShape> shapesCache
-
flameOdds
private final it.unimi.dsi.fastutil.objects.Object2IntMap<Block> flameOdds
-
burnOdds
private final it.unimi.dsi.fastutil.objects.Object2IntMap<Block> burnOdds
-
-
Constructor Detail
-
FireBlock
public FireBlock(AbstractBlock.Properties p_i48397_1_)
-
-
Method Detail
-
calculateShape
private static VoxelShape calculateShape(BlockState p_242673_0_)
-
updateShape
public BlockState updateShape(BlockState p_196271_1_, Direction p_196271_2_, BlockState p_196271_3_, IWorld p_196271_4_, BlockPos p_196271_5_, BlockPos p_196271_6_)
- Overrides:
updateShapein classAbstractBlock
-
getShape
public VoxelShape getShape(BlockState p_220053_1_, IBlockReader p_220053_2_, BlockPos p_220053_3_, ISelectionContext p_220053_4_)
- Overrides:
getShapein classAbstractFireBlock
-
getStateForPlacement
public BlockState getStateForPlacement(BlockItemUseContext p_196258_1_)
- Overrides:
getStateForPlacementin classAbstractFireBlock
-
getStateForPlacement
protected BlockState getStateForPlacement(IBlockReader p_196448_1_, BlockPos p_196448_2_)
-
canSurvive
public boolean canSurvive(BlockState p_196260_1_, IWorldReader p_196260_2_, BlockPos p_196260_3_)
- Overrides:
canSurvivein classAbstractBlock
-
tick
public void tick(BlockState p_225534_1_, ServerWorld p_225534_2_, BlockPos p_225534_3_, java.util.Random p_225534_4_)
- Overrides:
tickin classAbstractBlock
-
getBurnOdd
@Deprecated public int getBurnOdd(BlockState p_220274_1_)
Deprecated.
-
getFlameOdds
@Deprecated public int getFlameOdds(BlockState p_220275_1_)
Deprecated.
-
tryCatchFire
private void tryCatchFire(World p_176536_1_, BlockPos p_176536_2_, int p_176536_3_, java.util.Random p_176536_4_, int p_176536_5_, Direction face)
-
getStateWithAge
private BlockState getStateWithAge(IWorld p_235494_1_, BlockPos p_235494_2_, int p_235494_3_)
-
isValidFireLocation
private boolean isValidFireLocation(IBlockReader p_196447_1_, BlockPos p_196447_2_)
-
getFireOdds
private int getFireOdds(IWorldReader p_176538_1_, BlockPos p_176538_2_)
-
canBurn
@Deprecated protected boolean canBurn(BlockState p_196446_1_)
Deprecated.- Specified by:
canBurnin classAbstractFireBlock
-
onPlace
public void onPlace(BlockState p_220082_1_, World p_220082_2_, BlockPos p_220082_3_, BlockState p_220082_4_, boolean p_220082_5_)
- Overrides:
onPlacein classAbstractFireBlock
-
getFireTickDelay
private static int getFireTickDelay(java.util.Random p_235495_0_)
-
createBlockStateDefinition
protected void createBlockStateDefinition(StateContainer.Builder<Block,BlockState> p_206840_1_)
- Overrides:
createBlockStateDefinitionin classBlock
-
setFlammable
private void setFlammable(Block p_180686_1_, int p_180686_2_, int p_180686_3_)
-
canCatchFire
public boolean canCatchFire(IBlockReader world, BlockPos pos, Direction face)
Side sensitive version that calls the block function.- Parameters:
world- The current worldpos- Block positionface- The side the fire is coming from- Returns:
- True if the face can catch fire.
-
bootStrap
public static void bootStrap()
-
-