From 8948a00d600d9a4f9a7ed352a7d09cd301c534e3 Mon Sep 17 00:00:00 2001 From: LexManos Date: Sat, 15 Sep 2012 19:40:58 -0700 Subject: [PATCH] Readd reverted EntityLiving patch --- .../net/minecraft/src/EntityLiving.java.patch | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/patches/common/net/minecraft/src/EntityLiving.java.patch b/patches/common/net/minecraft/src/EntityLiving.java.patch index 473aae7755..018eefd6a5 100644 --- a/patches/common/net/minecraft/src/EntityLiving.java.patch +++ b/patches/common/net/minecraft/src/EntityLiving.java.patch @@ -142,3 +142,34 @@ } /** +@@ -2180,4 +2228,30 @@ + this.worldObj.spawnParticle("iconcrack_" + par1ItemStack.getItem().shiftedIndex, var4.xCoord, var4.yCoord, var4.zCoord, var3.xCoord, var3.yCoord + 0.05D, var3.zCoord); + } + } ++ ++ /*** ++ * Removes all potion effects that have curativeItem as a curative item for its effect ++ * @param curativeItem The itemstack we are using to cure potion effects ++ */ ++ public void curePotionEffects(ItemStack curativeItem) ++ { ++ Iterator potionKey = activePotionsMap.keySet().iterator(); ++ ++ if (worldObj.isRemote) ++ { ++ return; ++ } ++ ++ while (potionKey.hasNext()) ++ { ++ Integer key = potionKey.next(); ++ PotionEffect effect = (PotionEffect)activePotionsMap.get(key); ++ ++ if (effect.isCurativeItem(curativeItem)) ++ { ++ potionKey.remove(); ++ onFinishedPotionEffect(effect); ++ } ++ } ++ } + }