Creating Square Ranges

Started by CobraKill, May 29, 2013, 10:43:28 PM

Previous topic - Next topic

CobraKill

Is it possible to create a square range? I'm hoping to make an emitter that get stronger when a unit is present on a rectangular square plateau. Can I make the range rectangular?

EDIT: Hunter Killer helped me in chat.
Never trust a computer that doesn't fit through your nearest window.

Hunter Seeker

If i wanted to do this I would:
find the area as a square i wanted with length L
take the sqrt(2)* L/2 and round up    ->radius of circle for getunitsinrange
use a do loop to exclude units if they have a x/y over/under the desired square.
It is quite possible there is another easier way to do this however.
Aspire to Inspire