|
|
|
|
@@ -1,4 +1,4 @@
|
|
|
|
|
From 9a086e607299747527b138c0f5227d1ca039560e Mon Sep 17 00:00:00 2001
|
|
|
|
|
From a64d82bf60a0044ead61b859b66502aca110e2fd Mon Sep 17 00:00:00 2001
|
|
|
|
|
From: William Blake Galbreath <blake.galbreath@gmail.com>
|
|
|
|
|
Date: Tue, 30 Apr 2019 19:17:21 -0500
|
|
|
|
|
Subject: [PATCH] Integrate ridables
|
|
|
|
|
@@ -10,44 +10,39 @@ Subject: [PATCH] Integrate ridables
|
|
|
|
|
.../java/net/minecraft/server/EntityCow.java | 14 ++++
|
|
|
|
|
.../net/minecraft/server/EntityCreeper.java | 14 ++++
|
|
|
|
|
.../net/minecraft/server/EntityEnderman.java | 15 ++++
|
|
|
|
|
.../net/minecraft/server/EntityGuardian.java | 3 +-
|
|
|
|
|
.../net/minecraft/server/EntityHorse.java | 10 ++-
|
|
|
|
|
.../minecraft/server/EntityHorseAbstract.java | 4 +-
|
|
|
|
|
.../server/EntityHorseChestedAbstract.java | 18 +++--
|
|
|
|
|
.../minecraft/server/EntityHorseDonkey.java | 3 +
|
|
|
|
|
.../net/minecraft/server/EntityHorseMule.java | 3 +
|
|
|
|
|
.../minecraft/server/EntityHorseSkeleton.java | 15 ++--
|
|
|
|
|
.../minecraft/server/EntityHorseZombie.java | 15 ++--
|
|
|
|
|
.../minecraft/server/EntityHorseZombie.java | 12 +--
|
|
|
|
|
.../net/minecraft/server/EntityHuman.java | 14 +++-
|
|
|
|
|
.../minecraft/server/EntityInsentient.java | 35 +++++++++
|
|
|
|
|
.../net/minecraft/server/EntityIronGolem.java | 15 ++++
|
|
|
|
|
.../net/minecraft/server/EntityLiving.java | 20 ++++-
|
|
|
|
|
.../net/minecraft/server/EntityLlama.java | 46 +++++++++--
|
|
|
|
|
.../net/minecraft/server/EntityMagmaCube.java | 2 +-
|
|
|
|
|
.../net/minecraft/server/EntityLiving.java | 19 ++++-
|
|
|
|
|
.../net/minecraft/server/EntityLlama.java | 37 ++++++++-
|
|
|
|
|
.../minecraft/server/EntityMushroomCow.java | 14 ++++
|
|
|
|
|
.../net/minecraft/server/EntityOcelot.java | 14 ++++
|
|
|
|
|
.../java/net/minecraft/server/EntityPig.java | 25 ++++++
|
|
|
|
|
.../net/minecraft/server/EntityPolarBear.java | 15 ++++
|
|
|
|
|
.../net/minecraft/server/EntitySheep.java | 14 ++++
|
|
|
|
|
.../net/minecraft/server/EntitySnowman.java | 15 ++++
|
|
|
|
|
.../server/EntityTameableAnimal.java | 13 ++--
|
|
|
|
|
.../server/EntityTameableAnimal.java | 6 ++
|
|
|
|
|
.../net/minecraft/server/EntityTypes.java | 6 ++
|
|
|
|
|
.../java/net/minecraft/server/EntityWolf.java | 14 ++++
|
|
|
|
|
.../net/minecraft/server/RecipeItemStack.java | 6 +-
|
|
|
|
|
.../java/net/pl3x/purpur/PurpurConfig.java | 4 +
|
|
|
|
|
.../purpur/controller/ControllerLookWASD.java | 44 +++++++++++
|
|
|
|
|
.../purpur/controller/ControllerMoveWASD.java | 78 +++++++++++++++++++
|
|
|
|
|
.../craftbukkit/entity/CraftLivingEntity.java | 12 +++
|
|
|
|
|
34 files changed, 506 insertions(+), 45 deletions(-)
|
|
|
|
|
create mode 100644 src/main/java/net/pl3x/purpur/PurpurConfig.java
|
|
|
|
|
30 files changed, 488 insertions(+), 28 deletions(-)
|
|
|
|
|
create mode 100644 src/main/java/net/pl3x/purpur/controller/ControllerLookWASD.java
|
|
|
|
|
create mode 100644 src/main/java/net/pl3x/purpur/controller/ControllerMoveWASD.java
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/ControllerJump.java b/src/main/java/net/minecraft/server/ControllerJump.java
|
|
|
|
|
index 5d6260de..f9b71ac0 100644
|
|
|
|
|
index 489beed2..041f0763 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/ControllerJump.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/ControllerJump.java
|
|
|
|
|
@@ -8,6 +8,7 @@ public class ControllerJump {
|
|
|
|
|
@@ -9,6 +9,7 @@ public class ControllerJump {
|
|
|
|
|
this.b = entityinsentient;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -56,10 +51,10 @@ index 5d6260de..f9b71ac0 100644
|
|
|
|
|
this.a = true;
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
|
|
|
|
index fcf1560e..d5d7ae56 100644
|
|
|
|
|
index 89a8bbe3..caa07f8b 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/Entity.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/Entity.java
|
|
|
|
|
@@ -97,6 +97,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
@@ -96,6 +96,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
private int id;
|
|
|
|
|
public boolean j; public boolean blocksEntitySpawning() { return j; } // Paper - OBFHELPER
|
|
|
|
|
public final List<Entity> passengers;
|
|
|
|
|
@@ -67,7 +62,7 @@ index fcf1560e..d5d7ae56 100644
|
|
|
|
|
protected int k;
|
|
|
|
|
private Entity vehicle;
|
|
|
|
|
public boolean attachedToPlayer;
|
|
|
|
|
@@ -2090,6 +2091,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
@@ -2115,6 +2116,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
return this.k <= 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -80,7 +75,7 @@ index fcf1560e..d5d7ae56 100644
|
|
|
|
|
public void ejectPassengers() {
|
|
|
|
|
for (int i = this.passengers.size() - 1; i >= 0; --i) {
|
|
|
|
|
((Entity) this.passengers.get(i)).stopRiding();
|
|
|
|
|
@@ -2139,6 +2146,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
@@ -2167,6 +2174,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
// Spigot end
|
|
|
|
|
if (!this.world.isClientSide && entity instanceof EntityHuman && !(this.bO() instanceof EntityHuman)) {
|
|
|
|
|
this.passengers.add(0, entity);
|
|
|
|
|
@@ -88,7 +83,7 @@ index fcf1560e..d5d7ae56 100644
|
|
|
|
|
} else {
|
|
|
|
|
this.passengers.add(entity);
|
|
|
|
|
}
|
|
|
|
|
@@ -2174,6 +2182,11 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
@@ -2205,6 +2213,11 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
// Spigot end
|
|
|
|
|
@@ -101,7 +96,7 @@ index fcf1560e..d5d7ae56 100644
|
|
|
|
|
entity.k = 60;
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityChicken.java b/src/main/java/net/minecraft/server/EntityChicken.java
|
|
|
|
|
index 3bfbf475..67d0b8dc 100644
|
|
|
|
|
index 070a9e7b..cf3730b3 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityChicken.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityChicken.java
|
|
|
|
|
@@ -18,6 +18,11 @@ public class EntityChicken extends EntityAnimal {
|
|
|
|
|
@@ -125,11 +120,10 @@ index 3bfbf475..67d0b8dc 100644
|
|
|
|
|
this.a(SoundEffects.ENTITY_CHICKEN_EGG, 1.0F, (this.random.nextFloat() - this.random.nextFloat()) * 0.2F + 1.0F);
|
|
|
|
|
this.forceDrops = true; // CraftBukkit
|
|
|
|
|
this.a((IMaterial) Items.EGG);
|
|
|
|
|
@@ -151,4 +156,14 @@ public class EntityChicken extends EntityAnimal {
|
|
|
|
|
public EntityAgeable createChild(EntityAgeable entityageable) {
|
|
|
|
|
return this.b(entityageable);
|
|
|
|
|
@@ -72,6 +77,16 @@ public class EntityChicken extends EntityAnimal {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
+
|
|
|
|
|
|
|
|
|
|
+ // Purpur start - processInteract
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public boolean a(EntityHuman entityhuman, EnumHand enumhand) {
|
|
|
|
|
@@ -139,9 +133,12 @@ index 3bfbf475..67d0b8dc 100644
|
|
|
|
|
+ return tryRide(entityhuman, enumhand);
|
|
|
|
|
+ }
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
}
|
|
|
|
|
+
|
|
|
|
|
public void c(float f, float f1) {}
|
|
|
|
|
|
|
|
|
|
protected SoundEffect D() {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityCow.java b/src/main/java/net/minecraft/server/EntityCow.java
|
|
|
|
|
index b4b22eed..30567242 100644
|
|
|
|
|
index efd2a0ee..231ade5c 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityCow.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityCow.java
|
|
|
|
|
@@ -11,6 +11,11 @@ public class EntityCow extends EntityAnimal {
|
|
|
|
|
@@ -173,7 +170,7 @@ index b4b22eed..30567242 100644
|
|
|
|
|
|
|
|
|
|
if (itemstack.getItem() == Items.BUCKET && !entityhuman.abilities.canInstantlyBuild && !this.isBaby()) {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityCreeper.java b/src/main/java/net/minecraft/server/EntityCreeper.java
|
|
|
|
|
index 72b4735d..d24420af 100644
|
|
|
|
|
index 945a75dd..588bba0a 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityCreeper.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityCreeper.java
|
|
|
|
|
@@ -22,6 +22,11 @@ public class EntityCreeper extends EntityMonster {
|
|
|
|
|
@@ -205,10 +202,10 @@ index 72b4735d..d24420af 100644
|
|
|
|
|
|
|
|
|
|
if (itemstack.getItem() == Items.FLINT_AND_STEEL) {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityEnderman.java b/src/main/java/net/minecraft/server/EntityEnderman.java
|
|
|
|
|
index c5747147..e3eab72e 100644
|
|
|
|
|
index 94504044..7ac728ba 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityEnderman.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityEnderman.java
|
|
|
|
|
@@ -22,6 +22,11 @@ public class EntityEnderman extends EntityMonster {
|
|
|
|
|
@@ -21,6 +21,11 @@ public class EntityEnderman extends EntityMonster {
|
|
|
|
|
this.setSize(0.6F, 2.9F);
|
|
|
|
|
this.Q = 1.0F;
|
|
|
|
|
this.a(PathType.WATER, -1.0F);
|
|
|
|
|
@@ -220,7 +217,7 @@ index c5747147..e3eab72e 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void n() {
|
|
|
|
|
@@ -251,6 +256,16 @@ public class EntityEnderman extends EntityMonster {
|
|
|
|
|
@@ -243,6 +248,16 @@ public class EntityEnderman extends EntityMonster {
|
|
|
|
|
return LootTables.C;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -237,25 +234,11 @@ index c5747147..e3eab72e 100644
|
|
|
|
|
public void setCarried(@Nullable IBlockData iblockdata) {
|
|
|
|
|
this.datawatcher.set(EntityEnderman.c, Optional.ofNullable(iblockdata));
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityGuardian.java b/src/main/java/net/minecraft/server/EntityGuardian.java
|
|
|
|
|
index 0383b2c0..2e9c5dce 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityGuardian.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityGuardian.java
|
|
|
|
|
@@ -351,8 +351,7 @@ public class EntityGuardian extends EntityMonster {
|
|
|
|
|
return (entityliving instanceof EntityHuman || entityliving instanceof EntitySquid) && entityliving.h(this.a) > 9.0D;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
- // $FF: synthetic method
|
|
|
|
|
- public boolean test(@Nullable Object object) {
|
|
|
|
|
+ public boolean test(@Nullable EntityLiving object) { // Purpur - decompile error
|
|
|
|
|
return this.a((EntityLiving)object);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHorse.java b/src/main/java/net/minecraft/server/EntityHorse.java
|
|
|
|
|
index f2019638..ed264e7e 100644
|
|
|
|
|
index 1b9425f3..ff7f1a61 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHorse.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHorse.java
|
|
|
|
|
@@ -183,12 +183,14 @@ public class EntityHorse extends EntityHorseAbstract {
|
|
|
|
|
@@ -191,12 +191,14 @@ public class EntityHorse extends EntityHorseAbstract {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -275,7 +258,7 @@ index f2019638..ed264e7e 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHorseAbstract.java b/src/main/java/net/minecraft/server/EntityHorseAbstract.java
|
|
|
|
|
index 894f7bc9..890cc11d 100644
|
|
|
|
|
index 95327763..3e80c82d 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHorseAbstract.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHorseAbstract.java
|
|
|
|
|
@@ -80,7 +80,7 @@ public abstract class EntityHorseAbstract extends EntityAnimal implements IInven
|
|
|
|
|
@@ -304,7 +287,7 @@ index 894f7bc9..890cc11d 100644
|
|
|
|
|
this.dH();
|
|
|
|
|
SoundEffect soundeffect = this.dB();
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHorseChestedAbstract.java b/src/main/java/net/minecraft/server/EntityHorseChestedAbstract.java
|
|
|
|
|
index dea95807..f40dc796 100644
|
|
|
|
|
index 6eddc2a8..7fa0c8fc 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHorseChestedAbstract.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHorseChestedAbstract.java
|
|
|
|
|
@@ -146,8 +146,12 @@ public abstract class EntityHorseChestedAbstract extends EntityHorseAbstract {
|
|
|
|
|
@@ -342,11 +325,11 @@ index dea95807..f40dc796 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHorseDonkey.java b/src/main/java/net/minecraft/server/EntityHorseDonkey.java
|
|
|
|
|
index 627ba103..d5939106 100644
|
|
|
|
|
index 65c40e72..cd0828cc 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHorseDonkey.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHorseDonkey.java
|
|
|
|
|
@@ -5,6 +5,9 @@ import javax.annotation.Nullable;
|
|
|
|
|
public class EntityHorseDonkey extends EntityHorseChestedAbstract {
|
|
|
|
|
@@ -6,6 +6,9 @@ public class EntityHorseDonkey extends EntityHorseChestedAbstract {
|
|
|
|
|
|
|
|
|
|
public EntityHorseDonkey(World world) {
|
|
|
|
|
super(EntityTypes.DONKEY, world);
|
|
|
|
|
+ // Purpur start
|
|
|
|
|
@@ -356,11 +339,11 @@ index 627ba103..d5939106 100644
|
|
|
|
|
|
|
|
|
|
@Nullable
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHorseMule.java b/src/main/java/net/minecraft/server/EntityHorseMule.java
|
|
|
|
|
index e6bd20fb..7e7d0449 100644
|
|
|
|
|
index d17c3e81..874ea280 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHorseMule.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHorseMule.java
|
|
|
|
|
@@ -5,6 +5,9 @@ import javax.annotation.Nullable;
|
|
|
|
|
public class EntityHorseMule extends EntityHorseChestedAbstract {
|
|
|
|
|
@@ -6,6 +6,9 @@ public class EntityHorseMule extends EntityHorseChestedAbstract {
|
|
|
|
|
|
|
|
|
|
public EntityHorseMule(World world) {
|
|
|
|
|
super(EntityTypes.MULE, world);
|
|
|
|
|
+ // Purpur start
|
|
|
|
|
@@ -370,10 +353,10 @@ index e6bd20fb..7e7d0449 100644
|
|
|
|
|
|
|
|
|
|
@Nullable
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHorseSkeleton.java b/src/main/java/net/minecraft/server/EntityHorseSkeleton.java
|
|
|
|
|
index 17850e85..3d3a7b27 100644
|
|
|
|
|
index 0a092acd..05c963c3 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHorseSkeleton.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHorseSkeleton.java
|
|
|
|
|
@@ -9,6 +9,9 @@ public class EntityHorseSkeleton extends EntityHorseAbstract {
|
|
|
|
|
@@ -10,6 +10,9 @@ public class EntityHorseSkeleton extends EntityHorseAbstract {
|
|
|
|
|
|
|
|
|
|
public EntityHorseSkeleton(World world) {
|
|
|
|
|
super(EntityTypes.SKELETON_HORSE, world);
|
|
|
|
|
@@ -383,8 +366,8 @@ index 17850e85..3d3a7b27 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void initAttributes() {
|
|
|
|
|
@@ -141,18 +144,20 @@ public class EntityHorseSkeleton extends EntityHorseAbstract {
|
|
|
|
|
ItemStack itemstack = entityhuman.b(enumhand);
|
|
|
|
|
@@ -142,18 +145,20 @@ public class EntityHorseSkeleton extends EntityHorseAbstract {
|
|
|
|
|
|
|
|
|
|
if (itemstack.getItem() instanceof ItemMonsterEgg) {
|
|
|
|
|
return super.a(entityhuman, enumhand);
|
|
|
|
|
- } else if (!this.isTamed()) {
|
|
|
|
|
@@ -405,26 +388,16 @@ index 17850e85..3d3a7b27 100644
|
|
|
|
|
} else {
|
|
|
|
|
if (!itemstack.isEmpty()) {
|
|
|
|
|
- if (itemstack.getItem() == Items.SADDLE && !this.dV()) {
|
|
|
|
|
+ if (!this.isBaby() && itemstack.getItem() == Items.SADDLE && !this.dV()) {// Purpur - don't open inventory on babies
|
|
|
|
|
+ if (!this.isBaby() && itemstack.getItem() == Items.SADDLE && !this.isSaddled()) { // Purpur - don't open inventory on babies
|
|
|
|
|
this.c(entityhuman);
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHorseZombie.java b/src/main/java/net/minecraft/server/EntityHorseZombie.java
|
|
|
|
|
index 4b928d2c..554a5a25 100644
|
|
|
|
|
index a1873f55..9dac0c25 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHorseZombie.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHorseZombie.java
|
|
|
|
|
@@ -5,6 +5,9 @@ import javax.annotation.Nullable;
|
|
|
|
|
public class EntityHorseZombie extends EntityHorseAbstract {
|
|
|
|
|
public EntityHorseZombie(World world) {
|
|
|
|
|
super(EntityTypes.ZOMBIE_HORSE, world);
|
|
|
|
|
+ // Purpur start
|
|
|
|
|
+ this.canBeRiddenInWater = true;
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
}
|
|
|
|
|
@@ -49,18 +49,20 @@ public class EntityHorseZombie extends EntityHorseAbstract {
|
|
|
|
|
|
|
|
|
|
protected void initAttributes() {
|
|
|
|
|
@@ -47,18 +50,20 @@ public class EntityHorseZombie extends EntityHorseAbstract {
|
|
|
|
|
ItemStack itemstack = entityhuman.b(enumhand);
|
|
|
|
|
if (itemstack.getItem() instanceof ItemMonsterEgg) {
|
|
|
|
|
return super.a(entityhuman, enumhand);
|
|
|
|
|
- } else if (!this.isTamed()) {
|
|
|
|
|
@@ -445,15 +418,15 @@ index 4b928d2c..554a5a25 100644
|
|
|
|
|
} else {
|
|
|
|
|
if (!itemstack.isEmpty()) {
|
|
|
|
|
- if (!this.dV() && itemstack.getItem() == Items.SADDLE) {
|
|
|
|
|
+ if (!this.isBaby() && !this.dV() && itemstack.getItem() == Items.SADDLE) { // Purpur - don't open inventory on babies
|
|
|
|
|
+ if (!this.isBaby() && itemstack.getItem() == Items.SADDLE && !this.isSaddled()) { // Purpur - don't open inventory on babies
|
|
|
|
|
this.c(entityhuman);
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityHuman.java b/src/main/java/net/minecraft/server/EntityHuman.java
|
|
|
|
|
index 28700155..7ecd9d43 100644
|
|
|
|
|
index fdbe9a2a..3fbfa6d7 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityHuman.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityHuman.java
|
|
|
|
|
@@ -374,8 +374,20 @@ public abstract class EntityHuman extends EntityLiving {
|
|
|
|
|
@@ -372,8 +372,20 @@ public abstract class EntityHuman extends EntityLiving {
|
|
|
|
|
this.activeContainer = this.defaultContainer;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -462,8 +435,8 @@ index 28700155..7ecd9d43 100644
|
|
|
|
|
+
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public void setSneaking(boolean sneaking) {
|
|
|
|
|
+ if (mounting && !sneaking) {
|
|
|
|
|
+ mounting = false;
|
|
|
|
|
+ if (this.mounting && !sneaking) {
|
|
|
|
|
+ this.mounting = false;
|
|
|
|
|
+ }
|
|
|
|
|
+ super.setSneaking(sneaking);
|
|
|
|
|
+ }
|
|
|
|
|
@@ -471,15 +444,15 @@ index 28700155..7ecd9d43 100644
|
|
|
|
|
+
|
|
|
|
|
public void aH() {
|
|
|
|
|
- if (!this.world.isClientSide && this.isSneaking() && this.isPassenger()) {
|
|
|
|
|
+ if (this.isSneaking() && this.isPassenger() && !mounting) { // Purpur
|
|
|
|
|
+ if (this.isSneaking() && this.isPassenger() && !this.mounting) { // Purpur
|
|
|
|
|
this.stopRiding();
|
|
|
|
|
this.setSneaking(false);
|
|
|
|
|
} else {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityInsentient.java b/src/main/java/net/minecraft/server/EntityInsentient.java
|
|
|
|
|
index fd4a77c1..7fa3ddcd 100644
|
|
|
|
|
index d1ec201d..6da1b350 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityInsentient.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityInsentient.java
|
|
|
|
|
@@ -502,6 +502,7 @@ public abstract class EntityInsentient extends EntityLiving {
|
|
|
|
|
@@ -515,6 +515,7 @@ public abstract class EntityInsentient extends EntityLiving {
|
|
|
|
|
this.bh = f;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -487,7 +460,7 @@ index fd4a77c1..7fa3ddcd 100644
|
|
|
|
|
public void o(float f) {
|
|
|
|
|
super.o(f);
|
|
|
|
|
this.r(f);
|
|
|
|
|
@@ -1308,4 +1309,38 @@ public abstract class EntityInsentient extends EntityLiving {
|
|
|
|
|
@@ -1310,4 +1311,38 @@ public abstract class EntityInsentient extends EntityLiving {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
@@ -527,10 +500,10 @@ index fd4a77c1..7fa3ddcd 100644
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityIronGolem.java b/src/main/java/net/minecraft/server/EntityIronGolem.java
|
|
|
|
|
index 419c1aed..b3693393 100644
|
|
|
|
|
index ae269270..8140fa12 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityIronGolem.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityIronGolem.java
|
|
|
|
|
@@ -15,6 +15,11 @@ public class EntityIronGolem extends EntityGolem {
|
|
|
|
|
@@ -14,6 +14,11 @@ public class EntityIronGolem extends EntityGolem {
|
|
|
|
|
public EntityIronGolem(World world) {
|
|
|
|
|
super(EntityTypes.IRON_GOLEM, world);
|
|
|
|
|
this.setSize(1.4F, 2.7F);
|
|
|
|
|
@@ -542,9 +515,9 @@ index 419c1aed..b3693393 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void n() {
|
|
|
|
|
@@ -195,4 +200,14 @@ public class EntityIronGolem extends EntityGolem {
|
|
|
|
|
@@ -190,4 +195,14 @@ public class EntityIronGolem extends EntityGolem {
|
|
|
|
|
|
|
|
|
|
return iblockdata1.q() && SpawnerCreature.a(iblockdata2, iblockdata2.s()) && SpawnerCreature.a(iblockdata, FluidTypes.a.i()) && iworldreader.getCubes(this, this.getBoundingBox()) && iworldreader.a_(this, this.getBoundingBox());
|
|
|
|
|
return iblockdata1.q() && SpawnerCreature.a(iblockdata2, iblockdata2.s()) && SpawnerCreature.a(iblockdata, FluidTypes.EMPTY.i()) && iworldreader.getCubes(this, this.getBoundingBox()) && iworldreader.a_(this, this.getBoundingBox());
|
|
|
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+ // Purpur start - processInteract
|
|
|
|
|
@@ -558,7 +531,7 @@ index 419c1aed..b3693393 100644
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityLiving.java b/src/main/java/net/minecraft/server/EntityLiving.java
|
|
|
|
|
index 923bc0cc..6889e0ef 100644
|
|
|
|
|
index 4d5459d2..df9568fc 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityLiving.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityLiving.java
|
|
|
|
|
@@ -90,9 +90,9 @@ public abstract class EntityLiving extends Entity {
|
|
|
|
|
@@ -574,7 +547,7 @@ index 923bc0cc..6889e0ef 100644
|
|
|
|
|
public float bk;
|
|
|
|
|
protected int bl;
|
|
|
|
|
protected double bm;
|
|
|
|
|
@@ -346,8 +346,17 @@ public abstract class EntityLiving extends Entity {
|
|
|
|
|
@@ -346,8 +346,16 @@ public abstract class EntityLiving extends Entity {
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -589,11 +562,10 @@ index 923bc0cc..6889e0ef 100644
|
|
|
|
|
public boolean aY() {
|
|
|
|
|
- return false;
|
|
|
|
|
+ return canBeRiddenInWater;
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void cb() {
|
|
|
|
|
@@ -2081,10 +2090,12 @@ public abstract class EntityLiving extends Entity {
|
|
|
|
|
@@ -2082,10 +2090,12 @@ public abstract class EntityLiving extends Entity {
|
|
|
|
|
this.aK += this.aJ;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -606,7 +578,7 @@ index 923bc0cc..6889e0ef 100644
|
|
|
|
|
public void o(float f) {
|
|
|
|
|
this.bI = f;
|
|
|
|
|
}
|
|
|
|
|
@@ -2492,6 +2503,7 @@ public abstract class EntityLiving extends Entity {
|
|
|
|
|
@@ -2499,6 +2509,7 @@ public abstract class EntityLiving extends Entity {
|
|
|
|
|
this.fallDistance = 0.0F;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -615,18 +587,10 @@ index 923bc0cc..6889e0ef 100644
|
|
|
|
|
this.bg = flag;
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityLlama.java b/src/main/java/net/minecraft/server/EntityLlama.java
|
|
|
|
|
index 0cf53b69..0ca06818 100644
|
|
|
|
|
index 82a32c61..12b68665 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityLlama.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityLlama.java
|
|
|
|
|
@@ -1,5 +1,7 @@
|
|
|
|
|
package net.minecraft.server;
|
|
|
|
|
|
|
|
|
|
+import org.bukkit.entity.Llama;
|
|
|
|
|
+
|
|
|
|
|
import java.util.function.Predicate;
|
|
|
|
|
import javax.annotation.Nullable;
|
|
|
|
|
|
|
|
|
|
@@ -16,6 +18,29 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
@@ -18,6 +18,29 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
public EntityLlama(World world) {
|
|
|
|
|
super(EntityTypes.LLAMA, world);
|
|
|
|
|
this.setSize(0.9F, 1.87F);
|
|
|
|
|
@@ -656,16 +620,7 @@ index 0cf53b69..0ca06818 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void setStrength(int i) {
|
|
|
|
|
@@ -271,7 +296,7 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
return entityanimal != this && entityanimal instanceof EntityLlama && this.eb() && ((EntityLlama)entityanimal).eb();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
- public EntityLlama b(EntityAgeable entityageable) {
|
|
|
|
|
+ public EntityLlama createChild(EntityAgeable entityageable) { // Purpur - decompile error
|
|
|
|
|
EntityLlama entityllama1 = EntityTypes.LLAMA.create(world); // Paper
|
|
|
|
|
this.a(entityageable, entityllama1);
|
|
|
|
|
EntityLlama entityllama2 = (EntityLlama)entityageable;
|
|
|
|
|
@@ -323,6 +348,18 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
@@ -346,6 +369,18 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -684,7 +639,7 @@ index 0cf53b69..0ca06818 100644
|
|
|
|
|
public void ek() {
|
|
|
|
|
if (this.bQ != null) {
|
|
|
|
|
this.bQ.bR = null;
|
|
|
|
|
@@ -337,7 +374,7 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
@@ -360,7 +395,7 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public boolean el() {
|
|
|
|
|
@@ -693,36 +648,11 @@ index 0cf53b69..0ca06818 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public boolean inCaravan() { return this.em(); } // Paper - OBFHELPER
|
|
|
|
|
@@ -372,10 +409,7 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
|
|
|
|
|
public void s(boolean var1) {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
- // $FF: synthetic method
|
|
|
|
|
- public EntityAgeable createChild(EntityAgeable entityageable) {
|
|
|
|
|
- return this.b(entityageable);
|
|
|
|
|
- }
|
|
|
|
|
+ // Purpur - decompile error (removed ambiguous synthetic method)
|
|
|
|
|
|
|
|
|
|
static class a extends PathfinderGoalNearestAttackableTarget<EntityWolf> {
|
|
|
|
|
public a(EntityLlama entityllama) {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityMagmaCube.java b/src/main/java/net/minecraft/server/EntityMagmaCube.java
|
|
|
|
|
index 8d61ae58..453b8144 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityMagmaCube.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityMagmaCube.java
|
|
|
|
|
@@ -21,7 +21,7 @@ public class EntityMagmaCube extends EntitySlime {
|
|
|
|
|
return iworldreader.a_(this, this.getBoundingBox()) && iworldreader.getCubes(this, this.getBoundingBox()) && !iworldreader.containsLiquid(this.getBoundingBox());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
- protected void setSize(int i, boolean flag) {
|
|
|
|
|
+ public void setSize(int i, boolean flag) { // Purpur - decompile error (protected -> public)
|
|
|
|
|
super.setSize(i, flag);
|
|
|
|
|
this.getAttributeInstance(GenericAttributes.h).setValue((double)(i * 3));
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityMushroomCow.java b/src/main/java/net/minecraft/server/EntityMushroomCow.java
|
|
|
|
|
index 842ce472..23be71cf 100644
|
|
|
|
|
index 4a74145b..a7277d84 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityMushroomCow.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityMushroomCow.java
|
|
|
|
|
@@ -9,9 +9,23 @@ public class EntityMushroomCow extends EntityCow {
|
|
|
|
|
@@ -14,9 +14,23 @@ public class EntityMushroomCow extends EntityCow {
|
|
|
|
|
super(EntityTypes.MOOSHROOM, world);
|
|
|
|
|
this.setSize(0.9F, 1.4F);
|
|
|
|
|
this.bF = Blocks.MYCELIUM;
|
|
|
|
|
@@ -747,7 +677,7 @@ index 842ce472..23be71cf 100644
|
|
|
|
|
|
|
|
|
|
if (itemstack.getItem() == Items.BOWL && this.getAge() >= 0 && !entityhuman.abilities.canInstantlyBuild) {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityOcelot.java b/src/main/java/net/minecraft/server/EntityOcelot.java
|
|
|
|
|
index 90a7e00a..848e8f6e 100644
|
|
|
|
|
index 13c84bda..bee1532a 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityOcelot.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityOcelot.java
|
|
|
|
|
@@ -15,6 +15,11 @@ public class EntityOcelot extends EntityTameableAnimal {
|
|
|
|
|
@@ -779,10 +709,10 @@ index 90a7e00a..848e8f6e 100644
|
|
|
|
|
|
|
|
|
|
if (this.isTamed()) {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityPig.java b/src/main/java/net/minecraft/server/EntityPig.java
|
|
|
|
|
index b0802e12..c3f197e9 100644
|
|
|
|
|
index d1689dc3..50efffcf 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityPig.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityPig.java
|
|
|
|
|
@@ -16,6 +16,11 @@ public class EntityPig extends EntityAnimal {
|
|
|
|
|
@@ -19,6 +19,11 @@ public class EntityPig extends EntityAnimal {
|
|
|
|
|
public EntityPig(World world) {
|
|
|
|
|
super(EntityTypes.PIG, world);
|
|
|
|
|
this.setSize(0.9F, 0.9F);
|
|
|
|
|
@@ -794,7 +724,7 @@ index b0802e12..c3f197e9 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void n() {
|
|
|
|
|
@@ -96,6 +101,15 @@ public class EntityPig extends EntityAnimal {
|
|
|
|
|
@@ -99,6 +104,15 @@ public class EntityPig extends EntityAnimal {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public boolean a(EntityHuman entityhuman, EnumHand enumhand) {
|
|
|
|
|
@@ -810,7 +740,7 @@ index b0802e12..c3f197e9 100644
|
|
|
|
|
if (!super.a(entityhuman, enumhand)) {
|
|
|
|
|
ItemStack itemstack = entityhuman.b(enumhand);
|
|
|
|
|
|
|
|
|
|
@@ -111,6 +125,17 @@ public class EntityPig extends EntityAnimal {
|
|
|
|
|
@@ -114,6 +128,17 @@ public class EntityPig extends EntityAnimal {
|
|
|
|
|
} else if (itemstack.getItem() == Items.SADDLE) {
|
|
|
|
|
itemstack.a(entityhuman, (EntityLiving) this, enumhand);
|
|
|
|
|
return true;
|
|
|
|
|
@@ -829,10 +759,10 @@ index b0802e12..c3f197e9 100644
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityPolarBear.java b/src/main/java/net/minecraft/server/EntityPolarBear.java
|
|
|
|
|
index cb3e45f1..50c3e03d 100644
|
|
|
|
|
index dbb534c9..77de1a7d 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityPolarBear.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityPolarBear.java
|
|
|
|
|
@@ -12,6 +12,11 @@ public class EntityPolarBear extends EntityAnimal {
|
|
|
|
|
@@ -15,6 +15,11 @@ public class EntityPolarBear extends EntityAnimal {
|
|
|
|
|
public EntityPolarBear(World world) {
|
|
|
|
|
super(EntityTypes.POLAR_BEAR, world);
|
|
|
|
|
this.setSize(1.3F, 1.4F);
|
|
|
|
|
@@ -843,8 +773,8 @@ index cb3e45f1..50c3e03d 100644
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public EntityAgeable createChild(EntityAgeable var1) {
|
|
|
|
|
@@ -129,6 +134,16 @@ public class EntityPolarBear extends EntityAnimal {
|
|
|
|
|
public EntityAgeable createChild(EntityAgeable entityageable) {
|
|
|
|
|
@@ -130,6 +135,16 @@ public class EntityPolarBear extends EntityAnimal {
|
|
|
|
|
return 0.98F;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -858,14 +788,14 @@ index cb3e45f1..50c3e03d 100644
|
|
|
|
|
+ }
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
+
|
|
|
|
|
public GroupDataEntity prepare(DifficultyDamageScaler var1, @Nullable GroupDataEntity object, @Nullable NBTTagCompound var3) {
|
|
|
|
|
if (object instanceof EntityPolarBear.b) {
|
|
|
|
|
if (((EntityPolarBear.b)object).a) {
|
|
|
|
|
public GroupDataEntity prepare(DifficultyDamageScaler difficultydamagescaler, @Nullable GroupDataEntity groupdataentity, @Nullable NBTTagCompound nbttagcompound) {
|
|
|
|
|
if (groupdataentity instanceof EntityPolarBear.b) {
|
|
|
|
|
if (((EntityPolarBear.b) groupdataentity).a) {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntitySheep.java b/src/main/java/net/minecraft/server/EntitySheep.java
|
|
|
|
|
index db4c3aa6..05b0d4b2 100644
|
|
|
|
|
index c35d1eef..78ce8211 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntitySheep.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntitySheep.java
|
|
|
|
|
@@ -69,6 +69,11 @@ public class EntitySheep extends EntityAnimal {
|
|
|
|
|
@@ -67,6 +67,11 @@ public class EntitySheep extends EntityAnimal {
|
|
|
|
|
public EntitySheep(World world) {
|
|
|
|
|
super(EntityTypes.SHEEP, world);
|
|
|
|
|
this.setSize(0.9F, 1.3F);
|
|
|
|
|
@@ -877,7 +807,7 @@ index db4c3aa6..05b0d4b2 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void n() {
|
|
|
|
|
@@ -167,6 +172,15 @@ public class EntitySheep extends EntityAnimal {
|
|
|
|
|
@@ -150,6 +155,15 @@ public class EntitySheep extends EntityAnimal {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public boolean a(EntityHuman entityhuman, EnumHand enumhand) {
|
|
|
|
|
@@ -894,7 +824,7 @@ index db4c3aa6..05b0d4b2 100644
|
|
|
|
|
|
|
|
|
|
if (itemstack.getItem() == Items.SHEARS && !this.isSheared() && !this.isBaby()) {
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntitySnowman.java b/src/main/java/net/minecraft/server/EntitySnowman.java
|
|
|
|
|
index 7518d997..46b06256 100644
|
|
|
|
|
index 277ef077..0a7c8872 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntitySnowman.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntitySnowman.java
|
|
|
|
|
@@ -13,6 +13,11 @@ public class EntitySnowman extends EntityGolem implements IRangedEntity {
|
|
|
|
|
@@ -934,36 +864,24 @@ index 7518d997..46b06256 100644
|
|
|
|
|
|
|
|
|
|
if (this.hasPumpkin()) { if (itemstack.getItem() == Items.SHEARS) { // Purpur
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityTameableAnimal.java b/src/main/java/net/minecraft/server/EntityTameableAnimal.java
|
|
|
|
|
index 02eb7eb6..9e8fafbf 100644
|
|
|
|
|
index 5262ede2..d3d4c5df 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityTameableAnimal.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityTameableAnimal.java
|
|
|
|
|
@@ -126,6 +126,13 @@ public abstract class EntityTameableAnimal extends EntityAnimal implements Entit
|
|
|
|
|
|
|
|
|
|
@@ -123,6 +123,12 @@ public abstract class EntityTameableAnimal extends EntityAnimal implements Entit
|
|
|
|
|
this.datawatcher.set(EntityTameableAnimal.bD, Optional.ofNullable(uuid));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
+ // Purpur start
|
|
|
|
|
+ public boolean isOwner(EntityLiving entityliving) {
|
|
|
|
|
+ UUID owner = getOwnerUUID();
|
|
|
|
|
+ return owner != null && owner.equals(entityliving.getUniqueID());
|
|
|
|
|
+ public boolean isOwner(EntityHuman entityhuman) {
|
|
|
|
|
+ return entityhuman != null && entityhuman.getUniqueID() == getOwnerUUID();
|
|
|
|
|
+ }
|
|
|
|
|
+ // Purpur end
|
|
|
|
|
+
|
|
|
|
|
@Nullable
|
|
|
|
|
public EntityLiving getOwner() {
|
|
|
|
|
try {
|
|
|
|
|
@@ -182,9 +189,5 @@ public abstract class EntityTameableAnimal extends EntityAnimal implements Entit
|
|
|
|
|
super.die(damagesource);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
- // $FF: synthetic method
|
|
|
|
|
- @Nullable
|
|
|
|
|
- public Entity getOwner() {
|
|
|
|
|
- return this.getOwner();
|
|
|
|
|
- }
|
|
|
|
|
+ // Purpur - decompile error (removed ambiguous synthetic method)
|
|
|
|
|
}
|
|
|
|
|
public void c(EntityHuman entityhuman) {
|
|
|
|
|
this.setTamed(true);
|
|
|
|
|
this.setOwnerUUID(entityhuman.getUniqueID());
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityTypes.java b/src/main/java/net/minecraft/server/EntityTypes.java
|
|
|
|
|
index 29d5ef4c..b832067e 100644
|
|
|
|
|
index 24ca3511..2356b879 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityTypes.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityTypes.java
|
|
|
|
|
@@ -253,6 +253,12 @@ public class EntityTypes<T extends Entity> {
|
|
|
|
|
@@ -980,10 +898,10 @@ index 29d5ef4c..b832067e 100644
|
|
|
|
|
if (this.aW == null) {
|
|
|
|
|
this.aW = SystemUtils.a("entity", IRegistry.ENTITY_TYPE.getKey(this));
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityWolf.java b/src/main/java/net/minecraft/server/EntityWolf.java
|
|
|
|
|
index 68db6af6..93aea0b0 100644
|
|
|
|
|
index 46d8e0a1..1edba183 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/EntityWolf.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityWolf.java
|
|
|
|
|
@@ -25,6 +25,11 @@ public class EntityWolf extends EntityTameableAnimal {
|
|
|
|
|
@@ -24,6 +24,11 @@ public class EntityWolf extends EntityTameableAnimal {
|
|
|
|
|
super(EntityTypes.WOLF, world);
|
|
|
|
|
this.setSize(0.6F, 0.85F);
|
|
|
|
|
this.setTamed(false);
|
|
|
|
|
@@ -995,7 +913,7 @@ index 68db6af6..93aea0b0 100644
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void n() {
|
|
|
|
|
@@ -246,6 +251,15 @@ public class EntityWolf extends EntityTameableAnimal {
|
|
|
|
|
@@ -245,6 +250,15 @@ public class EntityWolf extends EntityTameableAnimal {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public boolean a(EntityHuman entityhuman, EnumHand enumhand) {
|
|
|
|
|
@@ -1011,40 +929,6 @@ index 68db6af6..93aea0b0 100644
|
|
|
|
|
ItemStack itemstack = entityhuman.b(enumhand);
|
|
|
|
|
Item item = itemstack.getItem();
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/RecipeItemStack.java b/src/main/java/net/minecraft/server/RecipeItemStack.java
|
|
|
|
|
index b4c0ee88..29e99e67 100644
|
|
|
|
|
--- a/src/main/java/net/minecraft/server/RecipeItemStack.java
|
|
|
|
|
+++ b/src/main/java/net/minecraft/server/RecipeItemStack.java
|
|
|
|
|
@@ -44,6 +44,7 @@ public final class RecipeItemStack implements Predicate<ItemStack> {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
+ public boolean test (@Nullable ItemStack itemstack) { return a(itemstack); } // Purpur - OBFHELPER
|
|
|
|
|
public boolean a(@Nullable ItemStack itemstack) {
|
|
|
|
|
if (itemstack == null) {
|
|
|
|
|
return false;
|
|
|
|
|
@@ -172,10 +173,7 @@ public final class RecipeItemStack implements Predicate<ItemStack> {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
- // $FF: synthetic method
|
|
|
|
|
- public boolean test(@Nullable Object object) {
|
|
|
|
|
- return this.a((ItemStack)object);
|
|
|
|
|
- }
|
|
|
|
|
+ // Purpur - decompile error (removed ambiguous synthetic method)
|
|
|
|
|
|
|
|
|
|
public interface Provider {
|
|
|
|
|
Collection<ItemStack> a();
|
|
|
|
|
diff --git a/src/main/java/net/pl3x/purpur/PurpurConfig.java b/src/main/java/net/pl3x/purpur/PurpurConfig.java
|
|
|
|
|
new file mode 100644
|
|
|
|
|
index 00000000..70e95544
|
|
|
|
|
--- /dev/null
|
|
|
|
|
+++ b/src/main/java/net/pl3x/purpur/PurpurConfig.java
|
|
|
|
|
@@ -0,0 +1,4 @@
|
|
|
|
|
+package net.pl3x.purpur;
|
|
|
|
|
+
|
|
|
|
|
+public class PurpurConfig {
|
|
|
|
|
+}
|
|
|
|
|
diff --git a/src/main/java/net/pl3x/purpur/controller/ControllerLookWASD.java b/src/main/java/net/pl3x/purpur/controller/ControllerLookWASD.java
|
|
|
|
|
new file mode 100644
|
|
|
|
|
index 00000000..22e45e81
|
|
|
|
|
|