@@ -21,7 +21,7 @@
|
||||
}
|
||||
|
||||
protected MobEffectList(MobEffectInfo mobeffectinfo, int i) {
|
||||
@@ -32,11 +37,11 @@
|
||||
@@ -32,26 +37,37 @@
|
||||
public void tick(EntityLiving entityliving, int i) {
|
||||
if (this == MobEffects.REGENERATION) {
|
||||
if (entityliving.getHealth() < entityliving.getMaxHealth()) {
|
||||
@@ -35,8 +35,9 @@
|
||||
}
|
||||
} else if (this == MobEffects.WITHER) {
|
||||
entityliving.damageEntity(DamageSource.WITHER, 1.0F);
|
||||
@@ -44,14 +49,25 @@
|
||||
((EntityHuman) entityliving).applyExhaustion(0.005F * (float) (i + 1));
|
||||
} else if (this == MobEffects.HUNGER && entityliving instanceof EntityHuman) {
|
||||
- ((EntityHuman) entityliving).applyExhaustion(0.005F * (float) (i + 1));
|
||||
+ ((EntityHuman) entityliving).applyExhaustion(0.005F * (float) (i + 1), org.bukkit.event.entity.EntityExhaustionEvent.ExhaustionReason.HUNGER_EFFECT); // CraftBukkit - EntityExhaustionEvent
|
||||
} else if (this == MobEffects.SATURATION && entityliving instanceof EntityHuman) {
|
||||
if (!entityliving.world.isClientSide) {
|
||||
- ((EntityHuman) entityliving).getFoodData().eat(i + 1, 1.0F);
|
||||
|
||||
Reference in New Issue
Block a user