collision
1 Attachment(s)
Here's a collision detection method I've created for a project I'm working on. I apologize if someone else has already posted this but I came up with it the other night and wasn't aware of it in the forums. Anyhow it's based on a line segment theory. If there is a line segment AC and there is a point, B, anywhere along line AC then A distance to C is = to (A distance to B) + (B distance to C). Where points A and C are the dummy objects I'm using in the program and B is the movable object. This collision detection should work for any polygon where you cannot use the center for collision detection. There must be a thickness to the center of an object because I had to modify the equation to account for it. I had to use a greater than or equal to with that thickness in it. If anyone has anything that can improve it please do. Willy:)

All times are GMT 5. The time now is 06:40 AM. 
Copyright ©2020, Carnegie Mellon University
Alice 2.x © 19992012, Alice 3.x © 20082012, Carnegie Mellon University. All rights reserved.