summaryrefslogtreecommitdiffstats
path: root/src/main/java/net/minecraft/server/ItemFood.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/net/minecraft/server/ItemFood.java')
-rw-r--r--src/main/java/net/minecraft/server/ItemFood.java46
1 files changed, 23 insertions, 23 deletions
diff --git a/src/main/java/net/minecraft/server/ItemFood.java b/src/main/java/net/minecraft/server/ItemFood.java
index 755e13c8..c0dc28bc 100644
--- a/src/main/java/net/minecraft/server/ItemFood.java
+++ b/src/main/java/net/minecraft/server/ItemFood.java
@@ -6,20 +6,20 @@ public class ItemFood extends Item {
public final int a;
private final int b;
- private final float bR;
- private final boolean bS;
- private boolean bT;
- private int bU;
+ private final float bS;
+ private final boolean bT;
+ private boolean bU;
private int bV;
private int bW;
- private float bX;
+ private int bX;
+ private float bY;
public ItemFood(int i, int j, float f, boolean flag) {
super(i);
this.a = 32;
this.b = j;
- this.bS = flag;
- this.bR = f;
+ this.bT = flag;
+ this.bS = f;
}
public ItemFood(int i, int j, boolean flag) {
@@ -31,16 +31,16 @@ public class ItemFood extends Item {
// CraftBukkit start
int oldFoodLevel = entityhuman.getFoodData().foodLevel;
- FoodLevelChangeEvent event = new FoodLevelChangeEvent(entityhuman.getBukkitEntity(), Math.min(this.n() + entityhuman.getFoodData().foodLevel, 20));
+ FoodLevelChangeEvent event = new FoodLevelChangeEvent(entityhuman.getBukkitEntity(), Math.min(this.o() + entityhuman.getFoodData().foodLevel, 20));
entityhuman.world.getServer().getPluginManager().callEvent(event);
if (!event.isCancelled()) {
- entityhuman.getFoodData().a(event.getFoodLevel() - oldFoodLevel, this.o());
+ entityhuman.getFoodData().a(event.getFoodLevel() - oldFoodLevel, this.p());
}
// CraftBukkit end
- if (!world.isStatic && this.bU > 0 && world.random.nextFloat() < this.bX) {
- entityhuman.addEffect(new MobEffect(this.bU, this.bV * 20, this.bW));
+ if (!world.isStatic && this.bV > 0 && world.random.nextFloat() < this.bY) {
+ entityhuman.addEffect(new MobEffect(this.bV, this.bW * 20, this.bX));
}
return itemstack;
@@ -55,35 +55,35 @@ public class ItemFood extends Item {
}
public ItemStack a(ItemStack itemstack, World world, EntityHuman entityhuman) {
- if (entityhuman.b(this.bT)) {
+ if (entityhuman.b(this.bU)) {
entityhuman.a(itemstack, this.c(itemstack));
}
return itemstack;
}
- public int n() {
+ public int o() {
return this.b;
}
- public float o() {
- return this.bR;
+ public float p() {
+ return this.bS;
}
- public boolean p() {
- return this.bS;
+ public boolean q() {
+ return this.bT;
}
public ItemFood a(int i, int j, int k, float f) {
- this.bU = i;
- this.bV = j;
- this.bW = k;
- this.bX = f;
+ this.bV = i;
+ this.bW = j;
+ this.bX = k;
+ this.bY = f;
return this;
}
- public ItemFood q() {
- this.bT = true;
+ public ItemFood r() {
+ this.bU = true;
return this;
}