- Home /
Graphics question: Firing Arcs and AOE indicators
Hi, i'm working on a space strategy game, and i need to show the ship's firing arcs, aoe ability indicators, range indicator, etc.
Example:Firing Arc Example, Firing Arc Example 2, Range Indicator Example
How would i create something like this? using textures is the obvious solution, but the texture should be really high res and it seems unfeasible. Using vector graphics (lines, circles) would solve that problem, but how do i get the nice gradient effect on the edges.. and what if i want to color in the inside of the arc? I also though about using a mesh to represent arcs, and dynamically expand or contract it, but if i want to have a large radius circle, the mesh would have too many polygons.
If someone could point me to an asset store package that has these features, please do, ill be happy to buy it. Or if there's an easier solution, please let me know.
Thanks :)
I would personally use a quad or something similar, then generate the vector graphics on the fly through a custom shader. I'd be happy to help with that, but I don't really have internet at the moment.
I found a script that creates dynamic meshes (cones circles etc), but ill need a shader to give them a gradient and some kind of edge glow, if you know of any shaders that do that, please point me in the right direction :P
Answer by Vattalus · Sep 27, 2016 at 10:35 AM
I found a script that dynamically generates a cone mesh with variable poly count (and it looks great imo). I can use it to generate cones, beams, circle outlines, filled circles, and i think this is the method i'm going to stick with. All i need now is a shader (or multiple) to get some nice edge effects, gradients etc. Any idea where i can find something like that? i have 0 experience writing shaders.
If that is your solution it would be great if you could post it here so others can check it out too :)
There is a good article describing the process of generating the cone mesh here (I believe this is the one located by the author as well) https://gamedev.stackexchange.com/questions/31170/drawing-a-dynamic-indicator-for-a-field-of-view
Your answer
Follow this Question
Related Questions
Problem with a direction indicator for an FPS game 2 Answers
change the length of the vector 1 Answer
Vector 2 3 4 help 1 Answer
Vector based on the rotation of the main camera 1 Answer
Vector-based movement? 1 Answer