4 template <
class Locator >
10 bool acquire_on_location )
14 if ( cmend != cmbegin && !
is_null( location ) ) {
19 if ( location != cmend && !cm->
Iterable( location ) ) {
22 if (location == cmend)
26 }
else if (location != cmend) {
31 if (acquire_on_location)
35 check->init( cm, location );
36 if (!acquire_on_location) {
42 while (workA || workB) {
44 && !check->cullless( tless ) ) {
45 float rad = (*tless)->
radius;
46 if ( rad != 0.0
f && ( check->BoltsOrUnits() || ( check->UnitsOnly() == (rad > 0) ) ) ) {
48 check->NeedDistance() ? ( (*tless)->GetPosition()-thispos ).
Magnitude()-fabs( rad )-thisrad : 0;
49 if ( !check->acquire( trad, tless ) )
56 }
else {workA =
false; }
if ( workB
58 && !check->cullmore( tmore ) ) {
59 float rad = (*tmore)->
radius;
60 if (rad!=0.0
f&&(check->BoltsOrUnits()||(check->UnitsOnly()==(rad>0)))) {
62 check->NeedDistance() ? ( (*tmore)->GetPosition()-thispos ).
Magnitude()-fabs( rad )-thisrad : 0;
63 if ( !check->acquire( trad, tmore ) )
67 }
else {workB =
false; }}
71 template <
class Locator >
76 QVector thispos = (**location).GetPosition();
77 float thisrad = fabs( (*location)->radius );
106 this->location = parent;
107 startkey = (*location)->getKey();
113 return rad != FLT_MAX && (startkey-rad) > (*tless)->getKey();
117 return rad != FLT_MAX && (startkey+rad) < (*tmore)->getKey();
121 if (distance < rad) {
153 isUnit = (*i)->radius > 0;
204 , maxUnitRadius( maxUnitRadius ) {}
226 return tmp > (*tless)->getKey();
237 return action.acquire( (*i)->ref.unit, dist );
283 return retval = ( ( (
const void*) ( (*i)->ref.unit ) ) == unit );