From f955b1f2aec82fc180d5fcfa781b34bbe7b2285e Mon Sep 17 00:00:00 2001 From: Bloepiloepi <59421074+Bloepiloepi@users.noreply.github.com> Date: Wed, 18 Aug 2021 20:37:16 +0200 Subject: [PATCH] Fix knockback strength --- src/main/java/net/minestom/server/entity/Entity.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/net/minestom/server/entity/Entity.java b/src/main/java/net/minestom/server/entity/Entity.java index 467ba35ad..efc050fa9 100644 --- a/src/main/java/net/minestom/server/entity/Entity.java +++ b/src/main/java/net/minestom/server/entity/Entity.java @@ -1431,7 +1431,7 @@ public class Entity implements Viewable, Tickable, TagHandler, PermissionHandler //TODO check possible side effects of unnatural TPS (other than 20TPS) final Vec velocityModifier = new Vec(x, z) .normalize() - .mul(strength * MinecraftServer.TICK_PER_SECOND / 2); + .mul(strength * MinecraftServer.TICK_PER_SECOND); setVelocity(new Vec(velocity.x() / 2d - velocityModifier.x(), onGround ? Math.min(.4d, velocity.y() / 2d + strength) * MinecraftServer.TICK_PER_SECOND : velocity.y(), velocity.z() / 2d - velocityModifier.z()