(EntityLivingBase entityLivingBaseIn, int p_76394_2_)
| 148 | } |
| 149 | |
| 150 | public void performEffect(EntityLivingBase entityLivingBaseIn, int p_76394_2_) |
| 151 | { |
| 152 | if (this.id == regeneration.id) |
| 153 | { |
| 154 | if (entityLivingBaseIn.getHealth() < entityLivingBaseIn.getMaxHealth()) |
| 155 | { |
| 156 | entityLivingBaseIn.heal(1.0F); |
| 157 | } |
| 158 | } |
| 159 | else if (this.id == poison.id) |
| 160 | { |
| 161 | if (entityLivingBaseIn.getHealth() > 1.0F) |
| 162 | { |
| 163 | entityLivingBaseIn.attackEntityFrom(DamageSource.magic, 1.0F); |
| 164 | } |
| 165 | } |
| 166 | else if (this.id == wither.id) |
| 167 | { |
| 168 | entityLivingBaseIn.attackEntityFrom(DamageSource.wither, 1.0F); |
| 169 | } |
| 170 | else if (this.id == hunger.id && entityLivingBaseIn instanceof EntityPlayer) |
| 171 | { |
| 172 | ((EntityPlayer)entityLivingBaseIn).addExhaustion(0.025F * (float)(p_76394_2_ + 1)); |
| 173 | } |
| 174 | else if (this.id == saturation.id && entityLivingBaseIn instanceof EntityPlayer) |
| 175 | { |
| 176 | if (!entityLivingBaseIn.worldObj.isRemote) |
| 177 | { |
| 178 | ((EntityPlayer)entityLivingBaseIn).getFoodStats().addStats(p_76394_2_ + 1, 1.0F); |
| 179 | } |
| 180 | } |
| 181 | else if ((this.id != heal.id || entityLivingBaseIn.isEntityUndead()) && (this.id != harm.id || !entityLivingBaseIn.isEntityUndead())) |
| 182 | { |
| 183 | if (this.id == harm.id && !entityLivingBaseIn.isEntityUndead() || this.id == heal.id && entityLivingBaseIn.isEntityUndead()) |
| 184 | { |
| 185 | entityLivingBaseIn.attackEntityFrom(DamageSource.magic, (float)(6 << p_76394_2_)); |
| 186 | } |
| 187 | } |
| 188 | else |
| 189 | { |
| 190 | entityLivingBaseIn.heal((float)Math.max(4 << p_76394_2_, 0)); |
| 191 | } |
| 192 | } |
| 193 | |
| 194 | public void affectEntity(Entity p_180793_1_, Entity p_180793_2_, EntityLivingBase entityLivingBaseIn, int p_180793_4_, double p_180793_5_) |
| 195 | { |
nothing calls this directly
no test coverage detected