类 DiggerItem
java.lang.Object
net.minecraft.world.item.Item
net.minecraft.world.item.TieredItem
net.minecraft.world.item.DiggerItem
- 所有已实现的接口:
FeatureElement
,Vanishable
,ItemLike
,IForgeItem
- 直接已知子类:
AxeItem
,HoeItem
,PickaxeItem
,ShovelItem
-
嵌套类概要
从类继承的嵌套类/接口 net.minecraft.world.item.Item
Item.Properties
-
字段概要
字段修饰符和类型字段说明private final float
private final com.google.common.collect.Multimap<Attribute,
AttributeModifier> protected final float
从类继承的字段 net.minecraft.world.item.Item
BASE_ATTACK_DAMAGE_UUID, BASE_ATTACK_SPEED_UUID, BY_BLOCK, canRepair, EAT_DURATION, MAX_BAR_WIDTH, MAX_STACK_SIZE
从接口继承的字段 net.minecraft.world.flag.FeatureElement
FILTERED_REGISTRIES
-
构造器概要
构造器构造器说明DiggerItem
(float pAttackDamageModifier, float pAttackSpeedModifier, Tier pTier, TagKey<Block> pBlocks, Item.Properties pProperties) -
方法概要
修饰符和类型方法说明float
com.google.common.collect.Multimap<Attribute,
AttributeModifier> getDefaultAttributeModifiers
(EquipmentSlot pEquipmentSlot) float
getDestroySpeed
(ItemStack pStack, BlockState pState) boolean
hurtEnemy
(ItemStack pStack, LivingEntity pTarget, LivingEntity pAttacker) boolean
isCorrectToolForDrops
(ItemStack stack, BlockState state) ItemStack sensitive version ofItem.isCorrectToolForDrops(BlockState)
boolean
isCorrectToolForDrops
(BlockState pBlock) 已过时。boolean
mineBlock
(ItemStack pStack, Level pLevel, BlockState pState, BlockPos pPos, LivingEntity pEntityLiving) 从类继承的方法 net.minecraft.world.item.TieredItem
getEnchantmentValue, getTier, isValidRepairItem
从类继承的方法 net.minecraft.world.item.Item
appendHoverText, asItem, builtInRegistryHolder, byBlock, byId, canAttackBlock, canBeDepleted, canBeHurtBy, canFitInsideContainerItems, finishUsingItem, getBarColor, getBarWidth, getCraftingRemainingItem, getDefaultInstance, getDescription, getDescriptionId, getDescriptionId, getDrinkingSound, getEatingSound, getFoodProperties, getId, getMaxDamage, getMaxStackSize, getName, getOrCreateDescriptionId, getPlayerPOVHitResult, getRarity, getRenderPropertiesInternal, getTooltipImage, getUseAnimation, getUseDuration, hasCraftingRemainingItem, initializeClient, interactLivingEntity, inventoryTick, isBarVisible, isComplex, isEdible, isEnchantable, isFireResistant, isFoil, isRepairable, onCraftedBy, onDestroyed, onUseTick, overrideOtherStackedOnMe, overrideStackedOnOther, releaseUsing, requiredFeatures, shouldOverrideMultiplayerNbt, toString, use, useOn, useOnRelease, verifyTagAfterLoad
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
从接口继承的方法 net.minecraft.world.flag.FeatureElement
isEnabled
从接口继承的方法 net.minecraftforge.common.extensions.IForgeItem
canApplyAtEnchantingTable, canContinueUsing, canDisableShield, canElytraFly, canEquip, canGrindstoneRepair, canPerformAction, canWalkOnPowderedSnow, createEntity, damageItem, doesSneakBypassUse, elytraFlightTick, getAllEnchantments, getArmorTexture, getAttributeModifiers, getBurnTime, getCraftingRemainingItem, getCreatorModId, getDamage, getDefaultTooltipHideFlags, getEnchantmentLevel, getEnchantmentValue, getEntityLifespan, getEquipmentSlot, getFoodProperties, getHighlightTip, getMaxDamage, getMaxStackSize, getShareTag, getSweepHitBox, getXpRepairRatio, hasCraftingRemainingItem, hasCustomEntity, initCapabilities, isBookEnchantable, isDamageable, isDamaged, isEnderMask, isNotReplaceableByPickAction, isPiglinCurrency, makesPiglinsNeutral, onArmorTick, onBlockStartBreak, onDestroyed, onDroppedByPlayer, onEntityItemUpdate, onEntitySwing, onHorseArmorTick, onItemUseFirst, onLeftClickEntity, onStopUsing, readShareTag, setDamage, shouldCauseBlockBreakReset, shouldCauseReequipAnimation
-
字段详细资料
-
blocks
-
speed
protected final float speed -
attackDamageBaseline
private final float attackDamageBaseline -
defaultModifiers
-
-
构造器详细资料
-
DiggerItem
public DiggerItem(float pAttackDamageModifier, float pAttackSpeedModifier, Tier pTier, TagKey<Block> pBlocks, Item.Properties pProperties)
-
-
方法详细资料
-
getDestroySpeed
- 覆盖:
getDestroySpeed
在类中Item
-
hurtEnemy
-
mineBlock
public boolean mineBlock(ItemStack pStack, Level pLevel, BlockState pState, BlockPos pPos, LivingEntity pEntityLiving) -
getDefaultAttributeModifiers
public com.google.common.collect.Multimap<Attribute,AttributeModifier> getDefaultAttributeModifiers(EquipmentSlot pEquipmentSlot) - 覆盖:
getDefaultAttributeModifiers
在类中Item
-
getAttackDamage
public float getAttackDamage() -
isCorrectToolForDrops
已过时。- 覆盖:
isCorrectToolForDrops
在类中Item
-
isCorrectToolForDrops
从接口复制的说明:IForgeItem
ItemStack sensitive version ofItem.isCorrectToolForDrops(BlockState)
- 指定者:
isCorrectToolForDrops
在接口中IForgeItem
- 参数:
stack
- The itemstack used to harvest the blockstate
- The block trying to harvest- 返回:
- true if the stack can harvest the block
-