Revision Difference
ents.FindInSphere#563541
<function name="FindInSphere" parent="ents" type="libraryfunc">
<description>
Gets all entities within the specified sphere.
Serverside, this uses a Spatial Partition internally to avoid looping through all entities, so it is more efficient than using <page>ents.GetAll</page> for this purpose.
Clientside, this function internally calls <page>util.IsBoxIntersectingSphere</page>
</description>
<realm>Shared</realm>
<args>
<arg name="origin" type="Vector">Center of the sphere.</arg>
<arg name="radius" type="number">Radius of the sphere.</arg>
</args>
<rets>
<ret name="" type="table">A table of all found <page>Entity</page>s.</ret>
<ret name="" type="table<Entity>">A table of all found <page>Entity</page>s.</ret>
</rets>
</function>