Results 1 to 12 of 12

Thread: Line and shape collision detection

Threaded View

  1. #6

    Thread Starter
    New Member Mr. Magoo's Avatar
    Join Date
    Mar 2004
    Location
    Ispa, Anarticia
    Posts
    8
    Ya'll have been great trying to help me with this and maybe I'm just slow. I take and insert a component which is a line onto my form inside of a picture box. The line goes from the bottom left corner (as the start point) and ends at the top right of the picture box (as the ending point). The line has the properties of x1 x2 y1 and y2. I then grab a shape component and add it to my picture box and make it a circle. I put the circle in the top left corner of the picture box. I then use a horizontal scroll bar to move the shape horizontally and a vertical scrollbar to move the circle vertically. I'm looking to code collision detection when the circle hits the line no matter where on the line that it touches.

    I do very much thank you for your replys to my post, but I am really not understanding how I can relate your formulas to this. Algebra just wasn't and still isn't one of my strong points. Could you please break it down a bit further for me please. Thankx
    Last edited by Mr. Magoo; Mar 20th, 2004 at 08:44 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width