diff --git a/src/minecraft/biomesoplenty/api/Potions.java b/src/minecraft/biomesoplenty/api/Potions.java index f464cd81e..0fab7a0cd 100644 --- a/src/minecraft/biomesoplenty/api/Potions.java +++ b/src/minecraft/biomesoplenty/api/Potions.java @@ -6,6 +6,5 @@ import com.google.common.base.Optional; public class Potions { - public static Optional nourishment = Optional.absent(); public static Optional paralysis = Optional.absent(); } diff --git a/src/minecraft/biomesoplenty/configuration/BOPPotions.java b/src/minecraft/biomesoplenty/configuration/BOPPotions.java index 1bc91d67d..3d89c8c7f 100644 --- a/src/minecraft/biomesoplenty/configuration/BOPPotions.java +++ b/src/minecraft/biomesoplenty/configuration/BOPPotions.java @@ -8,7 +8,6 @@ import net.minecraft.potion.Potion; import net.minecraftforge.common.MinecraftForge; import biomesoplenty.api.Potions; import biomesoplenty.potions.PotionEventHandler; -import biomesoplenty.potions.PotionNourishment; import biomesoplenty.potions.PotionParalysis; import com.google.common.base.Optional; @@ -32,8 +31,7 @@ public class BOPPotions private static void intializePotions() { - Potions.nourishment = Optional.of((new PotionNourishment(potionOffset + 0, false, 0)).setPotionName("potion.nourishment")); - Potions.paralysis = Optional.of((new PotionParalysis(potionOffset + 1, true, 16767262)).setPotionName("potion.paralysis")); + Potions.paralysis = Optional.of((new PotionParalysis(potionOffset + 0, true, 16767262)).setPotionName("potion.paralysis")); } private static void registerPotionNames() diff --git a/src/minecraft/biomesoplenty/potions/PotionEventHandler.java b/src/minecraft/biomesoplenty/potions/PotionEventHandler.java index 8df53c41a..f441f5329 100644 --- a/src/minecraft/biomesoplenty/potions/PotionEventHandler.java +++ b/src/minecraft/biomesoplenty/potions/PotionEventHandler.java @@ -1,7 +1,6 @@ package biomesoplenty.potions; import net.minecraft.entity.monster.EntityCreeper; -import net.minecraft.entity.player.EntityPlayer; import net.minecraftforge.event.ForgeSubscribe; import net.minecraftforge.event.entity.living.EnderTeleportEvent; import net.minecraftforge.event.entity.living.LivingEvent.LivingUpdateEvent; @@ -12,23 +11,6 @@ public class PotionEventHandler @ForgeSubscribe public void onEntityUpdate(LivingUpdateEvent event) { - if (event.entityLiving.isPotionActive(Potions.nourishment.get())) - { - if (event.entityLiving.worldObj.rand.nextInt(150) == 0) - { - if (!event.entityLiving.worldObj.isRemote) - if (event.entityLiving instanceof EntityPlayer) { - ((EntityPlayer)event.entityLiving).getFoodStats().addStats(1, 0); - } - } - - if (event.entityLiving.getActivePotionEffect(Potions.nourishment.get()).getDuration() == 0) - { - event.entityLiving.removePotionEffect(Potions.nourishment.get().id); - return; - } - } - if (event.entityLiving.isPotionActive(Potions.paralysis.get())) { event.entityLiving.motionX = 0.0; diff --git a/src/minecraft/biomesoplenty/potions/PotionNourishment.java b/src/minecraft/biomesoplenty/potions/PotionNourishment.java deleted file mode 100644 index 74084b20d..000000000 --- a/src/minecraft/biomesoplenty/potions/PotionNourishment.java +++ /dev/null @@ -1,30 +0,0 @@ -package biomesoplenty.potions; - -import net.minecraft.client.Minecraft; -import net.minecraft.client.resources.ResourceLocation; -import net.minecraft.potion.Potion; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class PotionNourishment extends Potion -{ - public PotionNourishment(int par1, boolean par2, int par3) - { - super(par1, par2, par3); - this.setIconIndex(0, 0); - } - - @Override - @SideOnly(Side.CLIENT) - public int getStatusIconIndex() - { - Minecraft.getMinecraft().renderEngine.func_110577_a(new ResourceLocation("biomesoplenty:textures/potions/BOPPotionFX.png")); - return 0; - } - - @Override - public boolean isReady(int par1, int par2) - { - return par1 >= 1; - } -} \ No newline at end of file