类 FlowerPotBlock
java.lang.Object
net.minecraft.world.level.block.state.BlockBehaviour
net.minecraft.world.level.block.Block
net.minecraft.world.level.block.FlowerPotBlock
- 所有已实现的接口:
FeatureElement
,ItemLike
,IBlockExtension
-
嵌套类概要
从类继承的嵌套类/接口 net.minecraft.world.level.block.Block
Block.ShapePairKey
从类继承的嵌套类/接口 net.minecraft.world.level.block.state.BlockBehaviour
BlockBehaviour.BlockStateBase, BlockBehaviour.OffsetFunction, BlockBehaviour.OffsetType, BlockBehaviour.Properties, BlockBehaviour.StateArgumentPredicate<A>, BlockBehaviour.StatePredicate
-
字段概要
字段修饰符和类型字段说明static final com.mojang.serialization.MapCodec
<FlowerPotBlock> private final Supplier
<FlowerPotBlock> private final Map
<ResourceLocation, Supplier<? extends Block>> private final Block
Neo: Field accesses are redirected togetPotted()
with a coremod.private static final VoxelShape
从类继承的字段 net.minecraft.world.level.block.Block
BLOCK_STATE_REGISTRY, INDESTRUCTIBLE, INSTANT, stateDefinition, UPDATE_ALL, UPDATE_ALL_IMMEDIATE, UPDATE_CLIENTS, UPDATE_IMMEDIATE, UPDATE_INVISIBLE, UPDATE_KNOWN_SHAPE, UPDATE_LIMIT, UPDATE_MOVE_BY_PISTON, UPDATE_NEIGHBORS, UPDATE_NONE, UPDATE_SKIP_ALL_SIDEEFFECTS, UPDATE_SKIP_BLOCK_ENTITY_SIDEEFFECTS, UPDATE_SKIP_ON_PLACE, UPDATE_SKIP_SHAPE_UPDATE_ON_WIRE, UPDATE_SUPPRESS_DROPS
从类继承的字段 net.minecraft.world.level.block.state.BlockBehaviour
descriptionId, drops, dynamicShape, explosionResistance, friction, hasCollision, isRandomlyTicking, jumpFactor, properties, requiredFeatures, soundType, speedFactor, UPDATE_SHAPE_ORDER
从接口继承的字段 net.minecraft.world.flag.FeatureElement
FILTERED_REGISTRIES
-
构造器概要
构造器构造器说明FlowerPotBlock
(Supplier<FlowerPotBlock> emptyPot, Supplier<? extends Block> p_53528_, BlockBehaviour.Properties properties) For mod use, eliminates the need to extend this class, and prevents modded flower pots from altering vanilla behavior.FlowerPotBlock
(Block p_53528_, BlockBehaviour.Properties p_53529_) 已过时。 -
方法概要
修饰符和类型方法说明void
addPlant
(ResourceLocation flower, Supplier<? extends Block> fullPot) Maps the given flower to the filled pot it is for.com.mojang.serialization.MapCodec
<FlowerPotBlock> codec()
protected ItemStack
getCloneItemStack
(LevelReader p_304505_, BlockPos p_53532_, BlockState p_53533_, boolean p_388306_) Map
<ResourceLocation, Supplier<? extends Block>> Returns all the filled pots that can be spawned from filling this pot.protected VoxelShape
getShape
(BlockState p_53556_, BlockGetter p_53557_, BlockPos p_53558_, CollisionContext p_53559_) private boolean
isEmpty()
protected boolean
isPathfindable
(BlockState p_53535_, PathComputationType p_53538_) protected boolean
isRandomlyTicking
(BlockState p_383068_) opposite
(BlockState p_383006_) protected void
randomTick
(BlockState p_382880_, ServerLevel p_383169_, BlockPos p_382955_, RandomSource p_383144_) protected BlockState
updateShape
(BlockState p_53547_, LevelReader p_374311_, ScheduledTickAccess p_374506_, BlockPos p_53551_, Direction p_53548_, BlockPos p_53552_, BlockState p_53549_, RandomSource p_374435_) protected InteractionResult
useItemOn
(ItemStack p_316610_, BlockState p_316240_, Level p_316456_, BlockPos p_316502_, Player p_316491_, InteractionHand p_316444_, BlockHitResult p_316826_) protected InteractionResult
useWithoutItem
(BlockState p_316363_, Level p_316655_, BlockPos p_316654_, Player p_316338_, BlockHitResult p_316518_) 从类继承的方法 net.minecraft.world.level.block.Block
animateTick, asBlock, asItem, box, boxes, boxZ, boxZ, boxZ, builtInRegistryHolder, byItem, canSupportCenter, canSupportRigidBlock, column, column, createBlockStateDefinition, cube, cube, defaultBlockState, destroy, dropFromExplosion, dropResources, dropResources, dropResources, fallOn, getDrops, getDrops, getExplosionResistance, getFriction, getId, getJumpFactor, getName, getShapeForEachState, getShapeForEachState, getSpeedFactor, getStateDefinition, getStateForPlacement, handlePrecipitation, hasDynamicShape, isExceptionForConnection, isFaceFull, isPossibleToRespawnInThis, isShapeFullBlock, playerDestroy, playerWillDestroy, popExperience, popResource, popResourceFromFace, pushEntitiesUp, registerDefaultState, setPlacedBy, shouldRenderFace, shouldRenderFace, spawnDestroyParticles, stateById, stepOn, toString, tryDropExperience, updateEntityMovementAfterFallOn, updateFromNeighbourShapes, updateOrDestroy, updateOrDestroy, wasExploded, withPropertiesOf
从类继承的方法 net.minecraft.world.level.block.state.BlockBehaviour
affectNeighborsAfterRemoval, attack, canBeReplaced, canBeReplaced, canSurvive, defaultDestroyTime, defaultMapColor, entityInside, getAnalogOutputSignal, getBlockSupportShape, getCollisionShape, getDescriptionId, getDestroyProgress, getDirectSignal, getDrops, getEntityInsideCollisionShape, getFluidState, getInteractionShape, getLightBlock, getLootTable, getMaxHorizontalOffset, getMaxVerticalOffset, getMenuProvider, getOcclusionShape, getRenderShape, getSeed, getShadeBrightness, getSignal, getSoundType, getVisualShape, hasAnalogOutputSignal, isAir, isCollisionShapeFullBlock, isSignalSource, mirror, neighborChanged, onExplosionHit, onPlace, onProjectileHit, propagatesSkylightDown, properties, propertiesCodec, requiredFeatures, rotate, simpleCodec, skipRendering, spawnAfterBreak, tick, triggerEvent, updateIndirectNeighbourShapes, useShapeForLightOcclusion
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
从接口继承的方法 net.minecraft.world.flag.FeatureElement
isEnabled
从接口继承的方法 net.neoforged.neoforge.common.extensions.IBlockExtension
addLandingEffects, addRunningEffects, canBeHydrated, canConnectRedstone, canDropFromExplosion, canEntityDestroy, canHarvestBlock, canStickTo, canSustainPlant, collisionExtendsVertically, getAdjacentBlockPathType, getAppearance, getBeaconColorMultiplier, getBedDirection, getBlockPathType, getBubbleColumnDirection, getCloneItemStack, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getFireSpreadSpeed, getFlammability, getFriction, getLightEmission, getMapColor, getPistonPushReaction, getRespawnPosition, getSoundType, getStateAtViewpoint, getToolModifiedState, getWeakChanges, hasDynamicLightEmission, hidesNeighborFace, isBed, isBurning, isConduitFrame, isEmpty, isFertile, isFireSource, isFlammable, isLadder, isPortalFrame, isScaffolding, isSlimeBlock, isStickyBlock, makesOpenTrapdoorAboveClimbable, onBlockExploded, onBlockStateChange, onCaughtFire, onDestroyedByPlayer, onDestroyedByPushReaction, onNeighborChange, onTreeGrow, playFallSound, playStepSound, rotate, setBedOccupied, shouldCheckWeakPower, shouldDisplayFluidOverlay, shouldHideAdjacentFluidFace, supportsExternalFaceHiding
-
字段详细资料
-
CODEC
-
POTTED_BY_CONTENT
-
SHAPE
-
potted
Neo: Field accesses are redirected togetPotted()
with a coremod. -
fullPots
-
emptyPot
-
flowerDelegate
-
-
构造器详细资料
-
FlowerPotBlock
已过时。 -
FlowerPotBlock
public FlowerPotBlock(@Nullable Supplier<FlowerPotBlock> emptyPot, Supplier<? extends Block> p_53528_, BlockBehaviour.Properties properties) For mod use, eliminates the need to extend this class, and prevents modded flower pots from altering vanilla behavior.- 参数:
emptyPot
- The empty pot for this pot, or null for self.
-
-
方法详细资料
-
codec
-
getShape
protected VoxelShape getShape(BlockState p_53556_, BlockGetter p_53557_, BlockPos p_53558_, CollisionContext p_53559_) - 覆盖:
getShape
在类中BlockBehaviour
-
useItemOn
protected InteractionResult useItemOn(ItemStack p_316610_, BlockState p_316240_, Level p_316456_, BlockPos p_316502_, Player p_316491_, InteractionHand p_316444_, BlockHitResult p_316826_) - 覆盖:
useItemOn
在类中BlockBehaviour
-
useWithoutItem
protected InteractionResult useWithoutItem(BlockState p_316363_, Level p_316655_, BlockPos p_316654_, Player p_316338_, BlockHitResult p_316518_) - 覆盖:
useWithoutItem
在类中BlockBehaviour
-
getCloneItemStack
protected ItemStack getCloneItemStack(LevelReader p_304505_, BlockPos p_53532_, BlockState p_53533_, boolean p_388306_) - 覆盖:
getCloneItemStack
在类中BlockBehaviour
-
isEmpty
private boolean isEmpty() -
updateShape
protected BlockState updateShape(BlockState p_53547_, LevelReader p_374311_, ScheduledTickAccess p_374506_, BlockPos p_53551_, Direction p_53548_, BlockPos p_53552_, BlockState p_53549_, RandomSource p_374435_) - 覆盖:
updateShape
在类中BlockBehaviour
-
getPotted
-
isPathfindable
- 覆盖:
isPathfindable
在类中BlockBehaviour
-
getEmptyPot
-
addPlant
Maps the given flower to the filled pot it is for. Call this on the empty pot block. Attempting to call this on a filled pot will throw an exception.- 参数:
flower
- The ResourceLocation of the flower block. Not flower itemfullPot
- The filled flower pot to map the flower block to
-
getFullPotsView
Returns all the filled pots that can be spawned from filling this pot. (If this pot is filled, returned map will be empty) -
isRandomlyTicking
- 覆盖:
isRandomlyTicking
在类中BlockBehaviour
-
randomTick
protected void randomTick(BlockState p_382880_, ServerLevel p_383169_, BlockPos p_382955_, RandomSource p_383144_) - 覆盖:
randomTick
在类中BlockBehaviour
-
opposite
-