mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-14 19:55:52 -07:00
Update to mcdev rename revision 01 for 1.8.1
This commit is contained in:
@@ -62,7 +62,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
protected float O = 0.1F;
|
||||
protected float P = 0.02F;
|
||||
private int f = 0;
|
||||
public EntityFish hookedFish = null;
|
||||
public EntityFishingHook hookedFish = null;
|
||||
|
||||
public EntityHuman(World world) {
|
||||
super(world);
|
||||
@@ -152,7 +152,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
|
||||
super.s_();
|
||||
if (!this.world.isStatic && this.activeContainer != null && !this.activeContainer.b(this)) {
|
||||
this.x();
|
||||
this.closeInventory();
|
||||
this.activeContainer = this.defaultContainer;
|
||||
}
|
||||
|
||||
@@ -251,7 +251,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
return this.health <= 0 || this.isSleeping();
|
||||
}
|
||||
|
||||
protected void x() {
|
||||
protected void closeInventory() {
|
||||
this.activeContainer = this.defaultContainer;
|
||||
}
|
||||
|
||||
@@ -267,7 +267,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
}
|
||||
|
||||
private int o() {
|
||||
return this.a(MobEffectList.e) ? 6 - (1 + this.b(MobEffectList.e).c()) * 1 : (this.a(MobEffectList.f) ? 6 + (1 + this.b(MobEffectList.f).c()) * 2 : 6);
|
||||
return this.hasEffect(MobEffectList.FASTER_DIG) ? 6 - (1 + this.getEffect(MobEffectList.FASTER_DIG).getAmplifier()) * 1 : (this.hasEffect(MobEffectList.SLOWER_DIG) ? 6 + (1 + this.getEffect(MobEffectList.SLOWER_DIG).getAmplifier()) * 2 : 6);
|
||||
}
|
||||
|
||||
protected void c_() {
|
||||
@@ -291,7 +291,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
--this.n;
|
||||
}
|
||||
|
||||
if (this.world.spawnMonsters == 0 && this.health < 20 && this.ticksLived % 20 * 12 == 0) {
|
||||
if (this.world.difficulty == 0 && this.health < 20 && this.ticksLived % 20 * 12 == 0) {
|
||||
// CraftBukkit - added regain reason of "REGEN" for filtering purposes.
|
||||
this.c(1, RegainReason.REGEN);
|
||||
}
|
||||
@@ -301,7 +301,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
super.s();
|
||||
this.aj = this.O;
|
||||
this.ak = this.P;
|
||||
if (this.at()) {
|
||||
if (this.isSprinting()) {
|
||||
this.aj = (float) ((double) this.aj + (double) this.O * 0.3D);
|
||||
this.ak = (float) ((double) this.ak + (double) this.P * 0.3D);
|
||||
}
|
||||
@@ -442,12 +442,12 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
f /= 5.0F;
|
||||
}
|
||||
|
||||
if (this.a(MobEffectList.e)) {
|
||||
f *= 1.0F + (float) (this.b(MobEffectList.e).c() + 1) * 0.2F;
|
||||
if (this.hasEffect(MobEffectList.FASTER_DIG)) {
|
||||
f *= 1.0F + (float) (this.getEffect(MobEffectList.FASTER_DIG).getAmplifier() + 1) * 0.2F;
|
||||
}
|
||||
|
||||
if (this.a(MobEffectList.f)) {
|
||||
f *= 1.0F - (float) (this.b(MobEffectList.f).c() + 1) * 0.2F;
|
||||
if (this.hasEffect(MobEffectList.SLOWER_DIG)) {
|
||||
f *= 1.0F - (float) (this.getEffect(MobEffectList.SLOWER_DIG).getAmplifier() + 1) * 0.2F;
|
||||
}
|
||||
|
||||
return f;
|
||||
@@ -534,15 +534,15 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
Entity entity = damagesource.getEntity();
|
||||
|
||||
if (entity instanceof EntityMonster || entity instanceof EntityArrow) {
|
||||
if (this.world.spawnMonsters == 0) {
|
||||
if (this.world.difficulty == 0) {
|
||||
i = 0;
|
||||
}
|
||||
|
||||
if (this.world.spawnMonsters == 1) {
|
||||
if (this.world.difficulty == 1) {
|
||||
i = i / 3 + 1;
|
||||
}
|
||||
|
||||
if (this.world.spawnMonsters == 3) {
|
||||
if (this.world.difficulty == 3) {
|
||||
i = i * 3 / 2;
|
||||
}
|
||||
}
|
||||
@@ -726,11 +726,11 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
// CraftBukkit end
|
||||
|
||||
if (flag1) {
|
||||
if (this.at()) {
|
||||
if (this.isSprinting()) {
|
||||
entity.b((double) (-MathHelper.sin(this.yaw * 3.1415927F / 180.0F) * 1.0F), 0.1D, (double) (MathHelper.cos(this.yaw * 3.1415927F / 180.0F) * 1.0F));
|
||||
this.motX *= 0.6D;
|
||||
this.motZ *= 0.6D;
|
||||
this.g(false);
|
||||
this.setSprinting(false);
|
||||
}
|
||||
|
||||
if (flag) {
|
||||
@@ -975,7 +975,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
protected void S() {
|
||||
super.S();
|
||||
this.a(StatisticList.u, 1);
|
||||
if (this.at()) {
|
||||
if (this.isSprinting()) {
|
||||
this.b(0.8F);
|
||||
} else {
|
||||
this.b(0.2F);
|
||||
@@ -1026,7 +1026,7 @@ public abstract class EntityHuman extends EntityLiving {
|
||||
i = Math.round(MathHelper.a(d0 * d0 + d2 * d2) * 100.0F);
|
||||
if (i > 0) {
|
||||
this.a(StatisticList.l, i);
|
||||
if (this.at()) {
|
||||
if (this.isSprinting()) {
|
||||
this.b(0.099999994F * (float) i * 0.01F);
|
||||
} else {
|
||||
this.b(0.01F * (float) i * 0.01F);
|
||||
|
Reference in New Issue
Block a user