Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice
  4. Dismiss Notice

Raycast problems

Discussion in '2D' started by OneSketchyGuy, Jan 14, 2019.

  1. OneSketchyGuy

    OneSketchyGuy

    Joined:
    Oct 27, 2016
    Posts:
    14
  2. Nitrousek

    Nitrousek

    Joined:
    Jan 31, 2016
    Posts:
    35
    Instead of weird maths, create placeholder objects that function as start and end positions for raycasts. Other than that, use debugging for solving calculation problems.
     
  3. OneSketchyGuy

    OneSketchyGuy

    Joined:
    Oct 27, 2016
    Posts:
    14
    @Nitrousek Thanks, but I fingered it out. I was using

    Debug.DrawRay(start, end, Color.green); which is retarded for some reason. but I should have used

    Debug.DrawLine(start, end, Color.green);