x


Getting Gizmos to draw in my editor window (tool)

I'm working on some automated navigation tools for Unity. I'm creating a EditorWindow, and since I can't debug in unity normally, I want to draw some debug in the scene.

Just as a test, I wanted to draw the bounds of the scene using Gizmos.DrawCube. But EditorWindow class isn't a behavior, so I was wondering how someone would go about this. Would you create some dummy game object, that did the Gizmo rendering for you?

If so, what's the best way to do that via script. Basically, when the build button is hit for my window. I would need to create some object, that I can use for drawing?...What's the unity way to do that (in script)?

more ▼

asked Aug 31 '10 at 05:31 AM

Troy 1 gravatar image

Troy 1
21 1 1 2

(comments are locked)
10|3000 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x168

asked: Aug 31 '10 at 05:31 AM

Seen: 1473 times

Last Updated: Aug 31 '10 at 05:31 AM