Package net.minecraft.item
Class SwordItem
java.lang.Object
net.minecraft.item.Item
net.minecraft.item.SwordItem
- Mappings:
Namespace Name official acsintermediary net/minecraft/class_1101named net/minecraft/item/SwordItem
-
Field Summary
FieldsFields inherited from class net.minecraft.item.Item
ATTACK_DAMAGE_MODIFIER_UUID, damageable, field_6201, field_6941, handheld, maxCount, RANDOM, REGISTRY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns whether the item can be repaired via an anvil or crafting table.floatReturns a map containing entity attributes that are modified by the itemintReturns the enchantability of an Item.intgetMaxUseTime(ItemStack stack) floatgetMiningSpeedMultiplier(ItemStack stack, Block block) getUseAction(ItemStack stack) Returns the UseAction for an item when the item is used.booleanisEffectiveOn(Block block) booleanReturns whether the item is supposed to look as handheld.booleanmethod_3356(ItemStack itemStack, World world, Block block, int int2, int int3, int int4, LivingEntity livingEntity) booleanonEntityHit(ItemStack stack, LivingEntity entity1, LivingEntity entity2) onStartUse(ItemStack stack, World world, PlayerEntity player) Methods inherited from class net.minecraft.item.Item
appendItemStacks, appendTooltip, byRawId, canUseOnEntity, fromBlock, getDisplayColor, getDisplayName, getFromId, getItemGroup, getItemstackTranslatedName, getMaxCount, getMaxDamage, getMeta, getRarity, getRawId, getRecipeRemainder, getStatusEffectString, getTranslationKey, getTranslationKey, hasEnchantmentGlint, hasStatusEffectString, hasSubTypes, inventoryTick, isDamageable, isEnchantable, isFood, isNetworkSynced, isUnbreakable, method_3343, method_3355, method_3369, method_3378, method_3380, method_3397, method_5462, method_5463, method_6324, onCraft, onFinishUse, onHit, onUseStopped, setHandheld, setItemGroup, setMaxCount, setMaxDamage, setRecipeRemainder, setStatusEffectString, setTranslationKey, setUnbreakable, setup, shouldRotate, shouldSyncNbtToClient
-
Field Details
-
attackMultiplier
private float attackMultiplier- Mappings:
Namespace Name Mixin selector official aLacs;a:Fintermediary field_6950Lnet/minecraft/class_1101;field_6950:Fnamed attackMultiplierLnet/minecraft/item/SwordItem;attackMultiplier:F
-
field_4411
- Mappings:
Namespace Name Mixin selector official bLacs;b:Labn;intermediary field_4411Lnet/minecraft/class_1101;field_4411:Lnet/minecraft/class_1070;named field_4411Lnet/minecraft/item/SwordItem;field_4411:Lnet/minecraft/item/ToolMaterial;
-
-
Constructor Details
-
SwordItem
-
-
Method Details
-
getAttackDamage
public float getAttackDamage()- Mappings:
Namespace Name Mixin selector official iLacs;i()Fintermediary method_4632Lnet/minecraft/class_1101;method_4632()Fnamed getAttackDamageLnet/minecraft/item/SwordItem;getAttackDamage()F
-
getMiningSpeedMultiplier
- Overrides:
getMiningSpeedMultiplierin classItem- Mappings:
Namespace Name Mixin selector official aLabm;a(Labo;Laht;)Fintermediary method_3351Lnet/minecraft/class_1069;method_3351(Lnet/minecraft/class_1071;Lnet/minecraft/class_197;)Fnamed getMiningSpeedMultiplierLnet/minecraft/item/Item;getMiningSpeedMultiplier(Lnet/minecraft/item/ItemStack;Lnet/minecraft/block/Block;)F
-
onEntityHit
- Overrides:
onEntityHitin classItem- Mappings:
Namespace Name Mixin selector official aLabm;a(Labo;Lrg;Lrg;)Zintermediary method_3354Lnet/minecraft/class_1069;method_3354(Lnet/minecraft/class_1071;Lnet/minecraft/class_1699;Lnet/minecraft/class_1699;)Znamed onEntityHitLnet/minecraft/item/Item;onEntityHit(Lnet/minecraft/item/ItemStack;Lnet/minecraft/entity/LivingEntity;Lnet/minecraft/entity/LivingEntity;)Z
-
method_3356
public boolean method_3356(ItemStack itemStack, World world, Block block, int int2, int int3, int int4, LivingEntity livingEntity) - Overrides:
method_3356in classItem- Mappings:
Namespace Name Mixin selector official aLabm;a(Labo;Lafm;Laht;IIILrg;)Zintermediary method_3356Lnet/minecraft/class_1069;method_3356(Lnet/minecraft/class_1071;Lnet/minecraft/class_1150;Lnet/minecraft/class_197;IIILnet/minecraft/class_1699;)Znamed method_3356Lnet/minecraft/item/Item;method_3356(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/World;Lnet/minecraft/block/Block;IIILnet/minecraft/entity/LivingEntity;)Z
-
isHandheld
Returns whether the item is supposed to look as handheld.- Overrides:
isHandheldin classItem- Mappings:
Namespace Name Mixin selector official fLabm;f()Zintermediary method_3372Lnet/minecraft/class_1069;method_3372()Znamed isHandheldLnet/minecraft/item/Item;isHandheld()Z
-
getUseAction
Returns the UseAction for an item when the item is used. Used by food, potions, bows, etc.- Overrides:
getUseActionin classItem- Parameters:
stack- The ItemStack that was used- See Also:
- Mappings:
Namespace Name Mixin selector official dLabm;d(Labo;)Lact;intermediary method_3366Lnet/minecraft/class_1069;method_3366(Lnet/minecraft/class_1071;)Lnet/minecraft/class_1099;named getUseActionLnet/minecraft/item/Item;getUseAction(Lnet/minecraft/item/ItemStack;)Lnet/minecraft/util/UseAction;
-
getMaxUseTime
- Overrides:
getMaxUseTimein classItem- Mappings:
Namespace Name Mixin selector official d_Labm;d_(Labo;)Iintermediary method_3350Lnet/minecraft/class_1069;method_3350(Lnet/minecraft/class_1071;)Inamed getMaxUseTimeLnet/minecraft/item/Item;getMaxUseTime(Lnet/minecraft/item/ItemStack;)I
-
onStartUse
- Overrides:
onStartUsein classItem- Mappings:
Namespace Name Mixin selector official aLabm;a(Labo;Lafm;Lxk;)Labo;intermediary method_3358Lnet/minecraft/class_1069;method_3358(Lnet/minecraft/class_1071;Lnet/minecraft/class_1150;Lnet/minecraft/class_988;)Lnet/minecraft/class_1071;named onStartUseLnet/minecraft/item/Item;onStartUse(Lnet/minecraft/item/ItemStack;Lnet/minecraft/world/World;Lnet/minecraft/entity/player/PlayerEntity;)Lnet/minecraft/item/ItemStack;
-
isEffectiveOn
- Overrides:
isEffectiveOnin classItem- Mappings:
Namespace Name Mixin selector official bLabm;b(Laht;)Zintermediary method_3346Lnet/minecraft/class_1069;method_3346(Lnet/minecraft/class_197;)Znamed isEffectiveOnLnet/minecraft/item/Item;isEffectiveOn(Lnet/minecraft/block/Block;)Z
-
getEnchantability
public int getEnchantability()Returns the enchantability of an Item. Used by tools and armor- Overrides:
getEnchantabilityin classItem- Returns:
- Enchantability
- See Also:
- Mappings:
Namespace Name Mixin selector official cLabm;c()Iintermediary method_3362Lnet/minecraft/class_1069;method_3362()Inamed getEnchantabilityLnet/minecraft/item/Item;getEnchantability()I
-
getToolMaterial
- Mappings:
Namespace Name Mixin selector official jLacs;j()Ljava/lang/String;intermediary method_3465Lnet/minecraft/class_1101;method_3465()Ljava/lang/String;named getToolMaterialLnet/minecraft/item/SwordItem;getToolMaterial()Ljava/lang/String;
-
canRepair
Returns whether the item can be repaired via an anvil or crafting table.- Overrides:
canRepairin classItem- Mappings:
Namespace Name Mixin selector official aLabm;a(Labo;Labo;)Zintermediary method_4615Lnet/minecraft/class_1069;method_4615(Lnet/minecraft/class_1071;Lnet/minecraft/class_1071;)Znamed canRepairLnet/minecraft/item/Item;canRepair(Lnet/minecraft/item/ItemStack;Lnet/minecraft/item/ItemStack;)Z
-
getAttributeModifierMap
Returns a map containing entity attributes that are modified by the item- Overrides:
getAttributeModifierMapin classItem- Mappings:
Namespace Name Mixin selector official kLabm;k()Lcom/google/common/collect/Multimap;intermediary method_6326Lnet/minecraft/class_1069;method_6326()Lcom/google/common/collect/Multimap;named getAttributeModifierMapLnet/minecraft/item/Item;getAttributeModifierMap()Lcom/google/common/collect/Multimap;
-