Getting nearest collision.

This forum is currently in read-only mode.
  • I was just wondering how it would be possible to get the collision that's closest to the Origin Point.

    The Horizontal Line represents the Line that is used to collide and the Vertical Line is supposed to represent the collision point (along with the dot).

    <img src="http://img.photobucket.com/albums/v396/Shadow_Kirby/visualaid000.png">

    <img src="http://img.photobucket.com/albums/v396/Shadow_Kirby/visualaid001.png">

    So could anyone tell me if this is possible? Hope I illustrated the idea well.

    (Edit: Yes, this may be relevant to Defunct.)

  • I'm not sure if I know what you're talking about.

    [quote:1mi2i4u8]I was just wondering how it would be possible to get the collision that's closest to the Origin Point.

    By getting the collision you mean the X/Y coordinates of the point where that line collides with the wall or ummm... and in this context the origin point is supposed to be where that line is tagged on the player? Maybe because it's too early but in spite of those 2 images I can't figure out what you actually mean.

  • By getting the collision you mean the X/Y coordinates of the point where that line collides with the wall or ummm... and in this context the origin point is supposed to be where that line is tagged on the player? Maybe because it's too early but in spite of those 2 images I can't figure out what you actually mean.

    I think that is what I wanted to know.

    Explaining stuff has never been my strong suit. But I may have figured out how to perform what I was getting at...

    LOLSOLVED.

    As you see in this example, but I'm unsure of the lag potential of performing this among other things. If theres any optimised form of this, I'd like to know, until then, it's solved.

    This was made in the latest, or next to latest, version of Construct. So events and objects might differ if your using older versions (Pre 0.99.6 or 0.99.62).

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Yes, now I see what you meant.

    Works like the instant hit laser example basically. Curious how this is of relevance to AWESOME BOT ADVENTURES... I mean DEFUNCT.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)