diff options
Diffstat (limited to 'patch-remap/mache-spigotflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch')
-rw-r--r-- | patch-remap/mache-spigotflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/patch-remap/mache-spigotflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch b/patch-remap/mache-spigotflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch new file mode 100644 index 0000000000..67ee44fa5b --- /dev/null +++ b/patch-remap/mache-spigotflower-stripped/net/minecraft/world/entity/monster/Drowned.java.patch @@ -0,0 +1,20 @@ +--- a/net/minecraft/world/entity/monster/Drowned.java ++++ b/net/minecraft/world/entity/monster/Drowned.java +@@ -260,12 +243,11 @@ + } + + @Override +- @Override +- public void performRangedAttack(LivingEntity livingentity, float f) { +- ThrownTrident throwntrident = new ThrownTrident(this.level(), this, new ItemStack(Items.TRIDENT)); +- double d0 = livingentity.getX() - this.getX(); +- double d1 = livingentity.getY(0.3333333333333333D) - throwntrident.getY(); +- double d2 = livingentity.getZ() - this.getZ(); ++ public void performRangedAttack(LivingEntity target, float distanceFactor) { ++ 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 d3 = Math.sqrt(d0 * d0 + d2 * d2); + + throwntrident.shoot(d0, d1 + d3 * 0.20000000298023224D, d2, 1.6F, (float) (14 - this.level().getDifficulty().getId() * 4)); |