From 810240a80d44ecc0217b0bde980fef4a53d773c8 Mon Sep 17 00:00:00 2001 From: Minecon724 Date: Thu, 4 Jul 2024 20:49:24 +0200 Subject: [PATCH] a --- src/main/java/net/pivipi/physics/Physics.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/net/pivipi/physics/Physics.java b/src/main/java/net/pivipi/physics/Physics.java index 651e748..85a9679 100644 --- a/src/main/java/net/pivipi/physics/Physics.java +++ b/src/main/java/net/pivipi/physics/Physics.java @@ -19,10 +19,10 @@ public class Physics { public void applyPhysics(double delta) { velocity = velocity.sub(0, gravity * delta, 0); - VisibleSweepResult result = Collision.willCollideWithGround(5, entity, velocity.mul(delta)); - System.out.println(entity.hasCollision()); - if (result != null) { - System.out.println(result.res); + VisibleSweepResult result = Collision.willCollideWithGround(5, entity, velocity); + System.out.println(result); + if (entity.isOnGround()) { + //System.out.println(result.res); velocity = velocity.mul(0, -bounciness, 0); }