diff options
Diffstat (limited to 'patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch')
-rw-r--r-- | patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch b/patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch new file mode 100644 index 0000000000..41a99efcc4 --- /dev/null +++ b/patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch @@ -0,0 +1,15 @@ +--- a/net/minecraft/world/entity/monster/Drowned.java ++++ b/net/minecraft/world/entity/monster/Drowned.java +@@ -252,9 +244,9 @@ + + @Override + public void performRangedAttack(LivingEntity target, float distanceFactor) { +- ThrownTrident thrownTrident = new ThrownTrident(this.level(), this, new ItemStack(Items.TRIDENT)); +- double d = target.getX() - this.getX(); +- double d1 = target.getY(0.3333333333333333) - thrownTrident.getY(); ++ ThrownTrident entitythrowntrident = new ThrownTrident(this.level(), this, this.getItemInHand(net.minecraft.world.entity.projectile.ProjectileUtil.getWeaponHoldingHand(this, Items.TRIDENT))); // CraftBukkit - Use Trident in hand like skeletons (SPIGOT-7025) ++ double d0 = target.getX() - this.getX(); ++ double d1 = target.getY(0.3333333333333333D) - entitythrowntrident.getY(); + double d2 = target.getZ() - this.getZ(); + double squareRoot = Math.sqrt(d * d + d2 * d2); + thrownTrident.shoot(d, d1 + squareRoot * 0.2F, d2, 1.6F, (float)(14 - this.level().getDifficulty().getId() * 4)); |