Draw a circle arround objects

Hello Everybody,

i want draw a circle around objects in the game... I researched many techniques about that example : gizmos, projector... Which is good for the best performance and fps ?

I working about 3D Tower Defences game and i want know my objects defence radius.

How can i make that? I wait your ideas

Thank you for your help

Regards

Vincenzo

I'm not sure of the best performance method, but here are a couple ideas. I would avoid projectors if you can because they can cause many draw calls.

  1. A four vert. plane with a radius texture would be very efficient. This is probably the fastest method to implement and for performance. The only drawback is that it is difficult to line up on uneven terrain. And, another benefit, if you are using Unity IPhone, the planes can be batched together.

  2. Gizmos don't show up in builds so they would be almost useless in the actual build.

  3. You could use a GUI Texture and several cameras to achieve the same look. The 4 vert plane idea is probably faster, but if you have uneven terrain then the Texture would always be drawn on top of the ground.

  4. You could use the shader tricks tutorial example where it lerps in a texture based on distance from a point. That takes some programming knowledge, but would let you do some other effects also, and the defense radius would be exactly on the ground.

  5. You could use a projector, but they often cause lots of draw calls. It would cause you defense radius to fit tightly to the ground though.

Sphere around object with a transparent texture of an arrow or line or whatever you want.