@@ -1,14 +1,14 @@
|
||||
--- a/net/minecraft/server/EntityAgeable.java
|
||||
+++ b/net/minecraft/server/EntityAgeable.java
|
||||
@@ -10,6 +10,7 @@
|
||||
@@ -8,6 +8,7 @@
|
||||
protected int b;
|
||||
protected int c;
|
||||
private float bD = -1.0F;
|
||||
private float bE;
|
||||
protected int d;
|
||||
+ public boolean ageLocked; // CraftBukkit
|
||||
|
||||
protected EntityAgeable(EntityTypes<?> entitytypes, World world) {
|
||||
protected EntityAgeable(EntityTypes<? extends EntityAgeable> entitytypes, World world) {
|
||||
super(entitytypes, world);
|
||||
@@ -29,7 +30,7 @@
|
||||
@@ -30,7 +31,7 @@
|
||||
if (entityageable != null) {
|
||||
entityageable.setAgeRaw(-24000);
|
||||
entityageable.setPositionRotation(this.locX, this.locY, this.locZ, 0.0F, 0.0F);
|
||||
@@ -17,27 +17,28 @@
|
||||
if (itemstack.hasName()) {
|
||||
entityageable.setCustomName(itemstack.getName());
|
||||
}
|
||||
@@ -97,12 +98,14 @@
|
||||
@@ -103,6 +104,7 @@
|
||||
super.b(nbttagcompound);
|
||||
nbttagcompound.setInt("Age", this.getAge());
|
||||
nbttagcompound.setInt("ForcedAge", this.b);
|
||||
nbttagcompound.setInt("ForcedAge", this.c);
|
||||
+ nbttagcompound.setBoolean("AgeLocked", this.ageLocked); // CraftBukkit
|
||||
}
|
||||
|
||||
public void a(NBTTagCompound nbttagcompound) {
|
||||
@Override
|
||||
@@ -110,6 +112,7 @@
|
||||
super.a(nbttagcompound);
|
||||
this.setAgeRaw(nbttagcompound.getInt("Age"));
|
||||
this.b = nbttagcompound.getInt("ForcedAge");
|
||||
this.c = nbttagcompound.getInt("ForcedAge");
|
||||
+ this.ageLocked = nbttagcompound.getBoolean("AgeLocked"); // CraftBukkit
|
||||
}
|
||||
|
||||
public void a(DataWatcherObject<?> datawatcherobject) {
|
||||
@@ -115,7 +118,7 @@
|
||||
|
||||
@Override
|
||||
@@ -124,7 +127,7 @@
|
||||
@Override
|
||||
public void movementTick() {
|
||||
super.movementTick();
|
||||
- if (this.world.isClientSide) {
|
||||
+ if (this.world.isClientSide || ageLocked) { // CraftBukkit
|
||||
if (this.c > 0) {
|
||||
if (this.c % 4 == 0) {
|
||||
this.world.addParticle(Particles.z, this.locX + (double) (this.random.nextFloat() * this.width * 2.0F) - (double) this.width, this.locY + 0.5D + (double) (this.random.nextFloat() * this.length), this.locZ + (double) (this.random.nextFloat() * this.width * 2.0F) - (double) this.width, 0.0D, 0.0D, 0.0D);
|
||||
if (this.d > 0) {
|
||||
if (this.d % 4 == 0) {
|
||||
this.world.addParticle(Particles.HAPPY_VILLAGER, this.locX + (double) (this.random.nextFloat() * this.getWidth() * 2.0F) - (double) this.getWidth(), this.locY + 0.5D + (double) (this.random.nextFloat() * this.getHeight()), this.locZ + (double) (this.random.nextFloat() * this.getWidth() * 2.0F) - (double) this.getWidth(), 0.0D, 0.0D, 0.0D);
|
||||
|
||||
Reference in New Issue
Block a user