+#ifndef MENUQC
+entity(vector org, float rad, .entity tofield) _findradius_tofield = #22;
+#define FOREACH_ENTITY_RADIUS(org, dist, cond, body) FOREACH_ENTITY_RADIUS_UNORDERED(org, dist, cond, body)
+.entity _FOREACH_ENTITY_RADIUS_next;
+noref string _FOREACH_ENTITY_RADIUS_mutex;
+#define FOREACH_ENTITY_RADIUS_UNORDERED(org, dist, cond, body) \
+ MACRO_BEGIN { \
+ if (_FOREACH_ENTITY_RADIUS_mutex) LOG_SEVEREF("Loop mutex held by %s", _FOREACH_ENTITY_RADIUS_mutex); \
+ _FOREACH_ENTITY_RADIUS_mutex = __FUNC__; \
+ entity _foundchain_first = _findradius_tofield(org, dist, _FOREACH_ENTITY_RADIUS_next); \
+ FOREACH_LIST(_foundchain, _FOREACH_ENTITY_RADIUS_next, cond, body); \
+ _FOREACH_ENTITY_RADIUS_mutex = string_null; \
+ } MACRO_END
+#endif
+