I have a pathing system that I am creating in Unity. When you add nodes to denote the path, I create a empty GameObject and render it in OnGUI as a square. The problem that I have is clicking on the object in the scene view. I am trying to figure out what would be the best way to click the Node, so that I can move and rotate the Node.
I had some ideas, like:
Creating a Cube or some other GameObject with a mesh, and change the layer to Node. Then make the camera cull out the Node layer.
Only in editor mode, create a temp asset and delete it before runtime.
Do a raycast and see what objects are near the click, then pick the closest one.
I have a feeling that I am putting to much thought into it, and suggestions would be greatly appreciated!!
No comments:
Post a Comment