-
Notifications
You must be signed in to change notification settings - Fork 2
Balls sometimes stick together instead of bouncing. #1
Copy link
Copy link
Open
Description
Hello!
Very nice little ball collision simulator :)
I noticed that sometimes the balls stick together instead of bouncing. Take it with a grain of salt, but I think it's because the way you defined the "approaching" function, so that sometimes the balls are not approaching (they are already going past each other) but the function thinks they are approaching, because it only depends on the velocities. I changed the definition and it seems to work better, the balls don't seem to get stuck any more. Shall I open a pull request? Sorry, I'm new to Github, I don't know how this works ;)
Here's my fork.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels