Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package narutoStellar.objects.items.jutsus;
- import narutoStellar.objects.items.JutsuBase;
- import net.minecraft.entity.Entity;
- import net.minecraft.entity.player.EntityPlayer;
- import net.minecraft.item.ItemStack;
- import net.minecraft.potion.Potion;
- import net.minecraft.potion.PotionEffect;
- import net.minecraft.world.World;
- public class DrunkenFist extends JutsuBase {
- public DrunkenFist(String name) {
- super(name);
- }
- public int cooldown = 0;
- @Override
- public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer player) {
- if (cooldown > 60);
- player.addPotionEffect(new PotionEffect(Potion.damageBoost.getId(), 20, 2));
- player.addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2));
- player.addPotionEffect(new PotionEffect(Potion.confusion.getId(), 20, 2));
- cooldown = 0;
- return itemStack;
- }
- @Override
- public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5) {
- super.onUpdate(stack, world, entity, par4, par5);
- EntityPlayer player = (EntityPlayer) entity;
- player.getCurrentEquippedItem();
- if(cooldown > 60);
- cooldown = 0;
- cooldown++;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement