Class SandPaperItem
java.lang.Object
net.minecraftforge.registries.ForgeRegistryEntry<net.minecraft.world.item.Item>
net.minecraft.world.item.Item
com.simibubi.create.content.curiosities.tools.SandPaperItem
- All Implemented Interfaces:
CustomUseEffectsItem,net.minecraft.world.level.ItemLike,net.minecraftforge.common.extensions.IForgeItem,net.minecraftforge.registries.IForgeRegistryEntry<net.minecraft.world.item.Item>
@ParametersAreNonnullByDefault
public class SandPaperItem
extends net.minecraft.world.item.Item
implements CustomUseEffectsItem
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.item.Item
net.minecraft.world.item.Item.PropertiesNested classes/interfaces inherited from class net.minecraftforge.registries.ForgeRegistryEntry
net.minecraftforge.registries.ForgeRegistryEntry.UncheckedRegistryEntry<V extends net.minecraftforge.registries.IForgeRegistryEntry<V>> -
Field Summary
Fields inherited from class net.minecraft.world.item.Item
BASE_ATTACK_DAMAGE_UUID, BASE_ATTACK_SPEED_UUID, BY_BLOCK, canRepair, category, EAT_DURATION, MAX_BAR_WIDTH, MAX_STACK_SIZEFields inherited from class net.minecraftforge.registries.ForgeRegistryEntry
delegate -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancanPerformAction(net.minecraft.world.item.ItemStack stack, net.minecraftforge.common.ToolAction toolAction) net.minecraft.world.item.ItemStackfinishUsingItem(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.Level worldIn, net.minecraft.world.entity.LivingEntity entityLiving) net.minecraft.sounds.SoundEventintnet.minecraft.world.item.UseAnimgetUseAnimation(net.minecraft.world.item.ItemStack stack) intgetUseDuration(net.minecraft.world.item.ItemStack stack) voidinitializeClient(Consumer<net.minecraftforge.client.IItemRenderProperties> consumer) voidreleaseUsing(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.Level worldIn, net.minecraft.world.entity.LivingEntity entityLiving, int timeLeft) shouldTriggerUseEffects(net.minecraft.world.item.ItemStack stack, net.minecraft.world.entity.LivingEntity entity) Called to determine if use effects should be applied for this item.static voidspawnParticles(net.minecraft.world.phys.Vec3 location, net.minecraft.world.item.ItemStack polishedStack, net.minecraft.world.level.Level world) booleantriggerUseEffects(net.minecraft.world.item.ItemStack stack, net.minecraft.world.entity.LivingEntity entity, int count, Random random) Called when use effects should be applied for this item.net.minecraft.world.InteractionResultHolder<net.minecraft.world.item.ItemStack>use(net.minecraft.world.level.Level worldIn, net.minecraft.world.entity.player.Player playerIn, net.minecraft.world.InteractionHand handIn) net.minecraft.world.InteractionResultuseOn(net.minecraft.world.item.context.UseOnContext context) Methods inherited from class net.minecraft.world.item.Item
allowdedIn, appendHoverText, asItem, builtInRegistryHolder, byBlock, byId, canAttackBlock, canBeDepleted, canBeHurtBy, canFitInsideContainerItems, fillItemCategory, getBarColor, getBarWidth, getCraftingRemainingItem, getDefaultAttributeModifiers, getDefaultInstance, getDescription, getDescriptionId, getDescriptionId, getDestroySpeed, getDrinkingSound, getEquipSound, getFoodProperties, getId, getItemCategory, getMaxDamage, getMaxStackSize, getName, getOrCreateDescriptionId, getPlayerPOVHitResult, getRarity, getRenderPropertiesInternal, getTooltipImage, hasCraftingRemainingItem, hurtEnemy, interactLivingEntity, inventoryTick, isBarVisible, isComplex, isCorrectToolForDrops, isEdible, isEnchantable, isFireResistant, isFoil, isRepairable, isValidRepairItem, mineBlock, onCraftedBy, onDestroyed, onUseTick, overrideOtherStackedOnMe, overrideStackedOnOther, shouldOverrideMultiplayerNbt, toString, useOnRelease, verifyTagAfterLoadMethods inherited from class net.minecraftforge.registries.ForgeRegistryEntry
getRegistryName, getRegistryType, setRegistryName, setRegistryName, setRegistryNameMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraftforge.common.extensions.IForgeItem
canApplyAtEnchantingTable, canContinueUsing, canDisableShield, canElytraFly, canEquip, canWalkOnPowderedSnow, createEntity, damageItem, doesSneakBypassUse, elytraFlightTick, getArmorTexture, getAttributeModifiers, getBurnTime, getContainerItem, getCreativeTabs, getCreatorModId, getDamage, getDefaultTooltipHideFlags, getEntityLifespan, getEquipmentSlot, getFoodProperties, getHighlightTip, getItemEnchantability, getItemStackLimit, getMaxDamage, getShareTag, getSweepHitBox, getXpRepairRatio, hasContainerItem, hasCustomEntity, initCapabilities, isBookEnchantable, isCorrectToolForDrops, isDamageable, isDamaged, isEnderMask, isPiglinCurrency, makesPiglinsNeutral, onArmorTick, onBlockStartBreak, onDestroyed, onDroppedByPlayer, onEntityItemUpdate, onEntitySwing, onHorseArmorTick, onItemUseFirst, onLeftClickEntity, onUsingTick, readShareTag, setDamage, shouldCauseBlockBreakReset, shouldCauseReequipAnimation
-
Constructor Details
-
SandPaperItem
public SandPaperItem(net.minecraft.world.item.Item.Properties properties)
-
-
Method Details
-
use
public net.minecraft.world.InteractionResultHolder<net.minecraft.world.item.ItemStack> use(net.minecraft.world.level.Level worldIn, net.minecraft.world.entity.player.Player playerIn, net.minecraft.world.InteractionHand handIn) - Overrides:
usein classnet.minecraft.world.item.Item
-
finishUsingItem
public net.minecraft.world.item.ItemStack finishUsingItem(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.Level worldIn, net.minecraft.world.entity.LivingEntity entityLiving) - Overrides:
finishUsingItemin classnet.minecraft.world.item.Item
-
spawnParticles
public static void spawnParticles(net.minecraft.world.phys.Vec3 location, net.minecraft.world.item.ItemStack polishedStack, net.minecraft.world.level.Level world) -
releaseUsing
public void releaseUsing(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.Level worldIn, net.minecraft.world.entity.LivingEntity entityLiving, int timeLeft) - Overrides:
releaseUsingin classnet.minecraft.world.item.Item
-
useOn
public net.minecraft.world.InteractionResult useOn(net.minecraft.world.item.context.UseOnContext context) - Overrides:
useOnin classnet.minecraft.world.item.Item
-
canPerformAction
public boolean canPerformAction(net.minecraft.world.item.ItemStack stack, net.minecraftforge.common.ToolAction toolAction) - Specified by:
canPerformActionin interfacenet.minecraftforge.common.extensions.IForgeItem
-
shouldTriggerUseEffects
public Boolean shouldTriggerUseEffects(net.minecraft.world.item.ItemStack stack, net.minecraft.world.entity.LivingEntity entity) Description copied from interface:CustomUseEffectsItemCalled to determine if use effects should be applied for this item.- Specified by:
shouldTriggerUseEffectsin interfaceCustomUseEffectsItem- Parameters:
stack- The ItemStack being used.entity- The LivingEntity using the item.- Returns:
- null for default behavior, or boolean to override default behavior
-
triggerUseEffects
public boolean triggerUseEffects(net.minecraft.world.item.ItemStack stack, net.minecraft.world.entity.LivingEntity entity, int count, Random random) Description copied from interface:CustomUseEffectsItemCalled when use effects should be applied for this item.- Specified by:
triggerUseEffectsin interfaceCustomUseEffectsItem- Parameters:
stack- The ItemStack being used.entity- The LivingEntity using the item.count- The amount of times effects should be applied. Can safely be ignored.random- The LivingEntity's Random.- Returns:
- if the default behavior should be cancelled or not
-
getEatingSound
public net.minecraft.sounds.SoundEvent getEatingSound()- Overrides:
getEatingSoundin classnet.minecraft.world.item.Item
-
getUseAnimation
public net.minecraft.world.item.UseAnim getUseAnimation(net.minecraft.world.item.ItemStack stack) - Overrides:
getUseAnimationin classnet.minecraft.world.item.Item
-
getUseDuration
public int getUseDuration(net.minecraft.world.item.ItemStack stack) - Overrides:
getUseDurationin classnet.minecraft.world.item.Item
-
getEnchantmentValue
public int getEnchantmentValue()- Overrides:
getEnchantmentValuein classnet.minecraft.world.item.Item
-
initializeClient
- Overrides:
initializeClientin classnet.minecraft.world.item.Item
-