jeremium update
This commit is contained in:
@@ -2,6 +2,10 @@ package net.arcmods.ryantlg.customToolItemClasses.jeremium;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
import net.minecraft.entity.LivingEntity;
|
||||
import net.minecraft.entity.effect.StatusEffectInstance;
|
||||
import net.minecraft.entity.effect.StatusEffects;
|
||||
import net.minecraft.client.item.TooltipContext;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.SwordItem;
|
||||
@@ -18,5 +22,12 @@ public class JeremiumSwordItem extends SwordItem {
|
||||
@Override
|
||||
public void appendTooltip(ItemStack itemStack, World world, List<Text> tooltip, TooltipContext tooltipContext) {
|
||||
tooltip.add( new TranslatableText("item.gamermod.jeremium_sword.tooltip").formatted(Formatting.DARK_PURPLE, Formatting.ITALIC) );
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean postHit(ItemStack stack, LivingEntity attackee, LivingEntity attacker) {
|
||||
attackee.addStatusEffect(new StatusEffectInstance(StatusEffects.SLOWNESS, 200, 3), attacker);
|
||||
return super.postHit(stack, attackee, attacker);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -18,5 +18,5 @@ public class OmniumSwordItem extends SwordItem {
|
||||
@Override
|
||||
public void appendTooltip(ItemStack itemStack, World world, List<Text> tooltip, TooltipContext tooltipContext) {
|
||||
tooltip.add( new TranslatableText("item.gamermod.omnium_sword.tooltip").formatted(Formatting.DARK_PURPLE, Formatting.ITALIC) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user