Feel dumb to post here again in less then a week but... I´m trying to make an ablity on my weapon that adds an slowness effect when the other 3 effects are gone Is there any way to do that? also if it helps here is the code of my weapon class
Hello guys! I'm making a mod that adds some weapons with abilitys to the game, however when using the ability I want to damage the sword by an x amount of it's durability, its there anyway a could do that?
Hello everyone! I am new to forge and I starting following a tutorial for this and I need help on my first mod. So what i am trying to do here is to add a cooldown after right clicking. I've done the RightClickItem event and it works correctly however every solution I see uses Spigot or Bukkit and I think thats only for Plugins can Anyone help please?
Heres the code I have for my event. thanks in advance!
@SubscribeEvent
public static void Beastmode(PlayerInteractEvent.RightClickItem event) {
PlayerEntity player = event.getPlayer();
if (event.getEntityLiving().getHeldItemMainhand().getItem() == RegistryHandler.WOLFBLOOD_SWORD.get()) {
player.addPotionEffect(new EffectInstance(Effects.SPEED, 10 * 20));
player.addPotionEffect(new EffectInstance(Effects.STRENGTH, 10 * 20, 1));
}
}
}
0
Feel dumb to post here again in less then a week but... I´m trying to make an ablity on my weapon that adds an slowness effect when the other 3 effects are gone Is there any way to do that? also if it helps here is the code of my weapon class
0
This works perfectly! thank you so much for your help, also is there some place where you could see all of this methods?
0
Hello guys! I'm making a mod that adds some weapons with abilitys to the game, however when using the ability I want to damage the sword by an x amount of it's durability, its there anyway a could do that?
0
it works perfectly!
Thank you so much for the help, I've been looking everywhere for a solution but I was only finding a solution for bukkit/spigot
0
Hello everyone! I am new to forge and I starting following a tutorial for this and I need help on my first mod. So what i am trying to do here is to add a cooldown after right clicking. I've done the RightClickItem event and it works correctly however every solution I see uses Spigot or Bukkit and I think thats only for Plugins can Anyone help please?
Heres the code I have for my event. thanks in advance!