int FireSystem_GetFiresInSphere( CFire **pList, int listMax, bool onlyActiveFires, const Vector &origin, float radius ) { CFireSphere sphereEnum( pList, listMax, onlyActiveFires, origin, radius ); partition->EnumerateElementsInSphere( PARTITION_ENGINE_NON_STATIC_EDICTS, origin, radius, false, &sphereEnum ); return sphereEnum.GetCount(); }
//----------------------------------------------------------------------------- // Purpose: Pass in an array of pointers and an array size, it fills the array and returns the number inserted // Input : **pList - // listMax - // ¢er - // radius - // flagMask - // Output : int //----------------------------------------------------------------------------- int UTIL_EntitiesInSphere( C_BaseEntity **pList, int listMax, const Vector ¢er, float radius, int flagMask, int partitionMask ) { CFlaggedEntitiesEnum sphereEnum( pList, listMax, flagMask ); partition->EnumerateElementsInSphere( partitionMask, center, radius, false, &sphereEnum ); return sphereEnum.GetCount(); }
//----------------------------------------------------------------------------- // Purpose: Pass in an array of pointers and an array size, it fills the array and returns the number inserted // Input : **pList - // listMax - // ¢er - // radius - // flagMask - // Output : int //----------------------------------------------------------------------------- int UTIL_EntitiesInSphere( C_BaseEntity **pList, int listMax, const Vector ¢er, float radius, int flagMask ) { CFlaggedEntitiesEnum sphereEnum( pList, listMax, flagMask ); partition->EnumerateElementsInSphere( PARTITION_CLIENT_NON_STATIC_EDICTS, center, radius, false, &sphereEnum ); return sphereEnum.GetCount(); }