- Home /
Question by
siddharth3322 · Jan 04, 2018 at 02:53 PM ·
raycastphysics2ddebugdrawray
Debug Draw for BoxCast and CapsuleCast
I am looking for debug draw related help for BoxCast and CapsuleCast so it become useful in programming rather than doing just guessing.
I found that for RayCast, there is DrawRay available for giving you proper measurement for ray cast.
Debug.DrawRay(new Vector2(slicer0[0].position.x, slicer0[0].position.y), new Vector2(slicer0[0].right.x, slicer0[0].right.y) * 5f, Color.red, 0.1f);
hit = Physics2D.Raycast(new Vector2(slicer0[i].position.x, slicer0[i].position.y), new Vector2(slicer0[i].right.x, slicer0[i].right.y), 10f, boxMask);
So something similar available for BoxCast and CapsuleCast in Unity ??
Comment
Your answer
Follow this Question
Related Questions
Raycast not drawing 1 Answer
What does direction do for a physics.raycast besides direction? (read details) 1 Answer
How can I get the rotation of Handles.DrawLine to match up with an Objects forward? 0 Answers
2D Raycast not detecting right layer 1 Answer
why Raycast2D doesn't work properly? 0 Answers