From 2bac5f3298af1c09576cfaaa2b3bcce019d04e91 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Fri, 26 Mar 2021 23:09:34 -0400 Subject: ball: Initialize other ball in collision loop --- diff --git a/src/ball.c b/src/ball.c index 1386cfd..2a2c721 100644 --- a/src/ball.c +++ b/src/ball.c @@ -100,7 +100,7 @@ db_balls_collisions(struct db_ball *ball) int col_x; int col_y; - for (; other != NULL; other = other->next) { + for (other = ball->next; other != NULL; other = other->next) { if (db_col_pt_cir_cir(ball->x, ball->y, ball->r, other->x, other->y, other->r, &col_x, &col_y)) { -- cgit v0.9.1