DMS_Exile/@ExileServer/addons/a3_dms/scripts/isPlayerNearbyARRAY.sqf
eraser1 9110ffc675 Beginning Steps of DMS Rewrite
***!!!THIS COMMIT WILL NOT WORK. DO NOT BOTHER COMPILING IT. THIS IS
SIMPLY A "SAVE POINT"!!!***

I copied a lot of WAI stuff (specifically the config.sqf) as a template
for the desired levels of customization that I want in the end.

Created a couple unique DMS config values w/ comments (all variables
prefixed with DMS_ in config.sqf)

Created BroadCastMissionStatus (with a variety of options)

Edited cleanup.sqf to take ARRAY params. It also won't clean up objects
if there is a player within 20m of it (I will probably improve/replace
the function later)

Replaced original crate function with WAI (because of customizability.
Will probably rewrite using BIS_fnc_param)

Fixed the PBOPREFIX

MissionStatusCheck is set up the way I want it, with all functions it
uses ready as well.

Made Exile and exile_server_config a necessary addon.

Created preInit for compiling code (postInit simply launches it now)

All functions added/changed so far have debug reports (if
DMS_DEBUG=true)
2015-08-27 02:44:23 -05:00

24 lines
442 B
Plaintext

private["_posArray","_radius","_result"];
_posArray = _this select 0;
_radius = _this select 1;
_result = false;
{
if (_result) exitWith {};
_plyr = _x;
if (alive _plyr) then
{
{
if (_plyr distance _x <= _radius) exitWith
{
_result = true;
if (DMS_DEBUG) then
{
diag_log format["DMS :: %1 is within %2m of %3!",_plyr,_radius,_x];
};
};
false;
} count _posArray;
};
false;
} count allPlayers;
_result