From d4604b12660d01fd216e578f5b51e1c0eefa1ab0 Mon Sep 17 00:00:00 2001 From: waynemwashuma <94756970+waynemwashuma@users.noreply.github.com> Date: Fri, 6 Sep 2024 11:47:20 +0300 Subject: [PATCH] Fixes #1 --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index d313922..5a3a790 100644 --- a/index.js +++ b/index.js @@ -60,7 +60,7 @@ function demoGrid(grid, renderer, number = 10) { bounceoff(canvasBound, velocity, bounds) grid.update(clients, bounds) const collided = grid.getCollisionPairs(checker, clients) - .flatMap(e => [bounds[e.b], bounds[e.b]]) + .flatMap(e => [bounds[e.a], bounds[e.b]]) grid.draw(ctx) ctx.strokeStyle = "white"