mirror of
https://github.com/Teh-Dango/Sarge-AI.git
synced 2024-08-30 16:32:11 +00:00
35 lines
816 B
Plaintext
35 lines
816 B
Plaintext
|
/****************************************************************
|
|||
|
File: UPSMON_deadbodies.sqf
|
|||
|
Author: Monsada
|
|||
|
|
|||
|
Description:
|
|||
|
Funci<63>n que devuelve un array con los vehiculos terrestres m<>s cercanos
|
|||
|
Parameter(s):
|
|||
|
<--- object for position search
|
|||
|
<--- max distance from npc
|
|||
|
Returns:
|
|||
|
---> _vehicles: array of vehiclesnetid object
|
|||
|
****************************************************************/
|
|||
|
private["_vehicles","_npc","_bodies","_OCercanos","_distance","_side"];
|
|||
|
|
|||
|
_npc = _this select 0;
|
|||
|
_distance = _this select 1;
|
|||
|
|
|||
|
_OCercanos = [];
|
|||
|
_bodies = objNull;
|
|||
|
|
|||
|
//Buscamos objetos cercanos
|
|||
|
_OCercanos = nearestObjects [_npc,["Man"],_distance];
|
|||
|
|
|||
|
{
|
|||
|
if (!alive _x) then
|
|||
|
{
|
|||
|
if ([_npc,_x,_distance,130] call UPSMON_Haslos) exitwith
|
|||
|
{
|
|||
|
_bodies = _x;
|
|||
|
_bodies
|
|||
|
};
|
|||
|
};
|
|||
|
}foreach _OCercanos;
|
|||
|
|
|||
|
_bodies;
|