ID:267911
 
Hey, I think some of you know me, anyway...

I'm curious how you can make it to where you can tell what objs/mobs are within a specific amount of squares from an object. I'm curious because of objs being used as 'troops' in a game I'm working on, and each of them has a range to attack. Such as, Warriors can only attack within 1 square of themsleves but Archers can attack with 2 to 3 squares. Anyway, how would you go about doing this?
I'm pretty sure that only works for the user, not the obj's view...
You could use something along the lines of oview().
In response to Jon88
Could you elaborate, please?
In response to Devourer Of Souls
Nope! oview(),view(),range(), and orange() have two, count'em, TWO arguments... range and center, and center can be ANY atom. You don't even have to worry about the order.

If you put:

view(6,anobjhere)

or

orange(aturfhere,6)

it'll figure it out.
get_dist() works nicely.
In response to Foomer
He wants a list of objs and mobs that are within a specific range, not to check if a group of objs and mobs are within a specific range or not.