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 IntegerProperty
AGE
private it.unimi.dsi.fastutil.objects.Object2IntMap<Block>
burnOdds
static BooleanProperty
EAST
private static VoxelShape
EAST_AABB
private it.unimi.dsi.fastutil.objects.Object2IntMap<Block>
flameOdds
static BooleanProperty
NORTH
private static VoxelShape
NORTH_AABB
private static java.util.Map<Direction,BooleanProperty>
PROPERTY_BY_DIRECTION
private java.util.Map<BlockState,VoxelShape>
shapesCache
static BooleanProperty
SOUTH
private static VoxelShape
SOUTH_AABB
static BooleanProperty
UP
private static VoxelShape
UP_AABB
static BooleanProperty
WEST
private static VoxelShape
WEST_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 void
bootStrap()
private static VoxelShape
calculateShape(BlockState p_242673_0_)
protected boolean
canBurn(BlockState p_196446_1_)
Deprecated.boolean
canCatchFire(IBlockReader world, BlockPos pos, Direction face)
Side sensitive version that calls the block function.boolean
canSurvive(BlockState p_196260_1_, IWorldReader p_196260_2_, BlockPos p_196260_3_)
protected void
createBlockStateDefinition(StateContainer.Builder<Block,BlockState> p_206840_1_)
int
getBurnOdd(BlockState p_220274_1_)
Deprecated.private int
getFireOdds(IWorldReader p_176538_1_, BlockPos p_176538_2_)
private static int
getFireTickDelay(java.util.Random p_235495_0_)
int
getFlameOdds(BlockState p_220275_1_)
Deprecated.VoxelShape
getShape(BlockState p_220053_1_, IBlockReader p_220053_2_, BlockPos p_220053_3_, ISelectionContext p_220053_4_)
BlockState
getStateForPlacement(BlockItemUseContext p_196258_1_)
protected BlockState
getStateForPlacement(IBlockReader p_196448_1_, BlockPos p_196448_2_)
private BlockState
getStateWithAge(IWorld p_235494_1_, BlockPos p_235494_2_, int p_235494_3_)
protected boolean
isNearRain(World p_176537_1_, BlockPos p_176537_2_)
private boolean
isValidFireLocation(IBlockReader p_196447_1_, BlockPos p_196447_2_)
void
onPlace(BlockState p_220082_1_, World p_220082_2_, BlockPos p_220082_3_, BlockState p_220082_4_, boolean p_220082_5_)
private void
setFlammable(Block p_180686_1_, int p_180686_2_, int p_180686_3_)
void
tick(BlockState p_225534_1_, ServerWorld p_225534_2_, BlockPos p_225534_3_, java.util.Random p_225534_4_)
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)
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_)
-
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:
updateShape
in classAbstractBlock
-
getShape
public VoxelShape getShape(BlockState p_220053_1_, IBlockReader p_220053_2_, BlockPos p_220053_3_, ISelectionContext p_220053_4_)
- Overrides:
getShape
in classAbstractFireBlock
-
getStateForPlacement
public BlockState getStateForPlacement(BlockItemUseContext p_196258_1_)
- Overrides:
getStateForPlacement
in 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:
canSurvive
in classAbstractBlock
-
tick
public void tick(BlockState p_225534_1_, ServerWorld p_225534_2_, BlockPos p_225534_3_, java.util.Random p_225534_4_)
- Overrides:
tick
in 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:
canBurn
in 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:
onPlace
in classAbstractFireBlock
-
getFireTickDelay
private static int getFireTickDelay(java.util.Random p_235495_0_)
-
createBlockStateDefinition
protected void createBlockStateDefinition(StateContainer.Builder<Block,BlockState> p_206840_1_)
- Overrides:
createBlockStateDefinition
in 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()
-
-