DrawRay position && local/world position ERROR
Was trying to get the transform.position of the top face on a mesh (X0, Y0.5, Z0) Was getting some mistakes and tried to debug with 2 Draw Rays
DrawRay 1:
Debug.DrawRay(TopFaceMid, Vector3.up * 0.4f, Color.blue, 0.1f);
DrawRay 2:
Debug.DrawRay(transform.position, TopFaceMid, Color.blue, 0.1f);
DrawRay1 works perfectly. DrawRay2 starts in the position its supposed to, but ends on a very weird and apparently random spot, even tho its the same position the DrawRay1 starts on.
Any ideas?
PS. This is not exacly what im trying to do, but the error I get is the same. the position its different.
Answer by MilenaRocha · May 09, 2019 at 05:18 AM
Here it is The yellow rays are supposed to be going from those edge vertex (PosAtual) to the mid point/blue dot (TopoAgua)
Your answer
![](https://koobas.hobune.stream/wayback/20220612201018im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Mesh Peeling ,Dynamic Mesh Coiling 0 Answers
Rotate a point around a mesh vertex 1 Answer
Maya Vertex Animation import 1 Answer
Colliders position and scaling are misaligned with object meshes 0 Answers
Seperating isolated triangles into mesh 0 Answers