mirror of
https://github.com/Defent/DMS_Exile.git
synced 2024-08-30 16:52:12 +00:00
e8eedfa538
* NEW CONFIG VALUES: ```DMS_MarkerPosRandomization```, ```DMS_MarkerPosRandomRadius```, and ```DMS_RandomMarkerBrush``` * With the above configs, you can randomize the marker positions in a random position around the actual mission center. * You can also "force" DMS_fnc_CreateMarker to randomize (or not randomize) the marker position with optional boolean parameter of index 3. * Changed the default (non-randomized) circle marker "brush". It should be a solid circle. * Created new functions ```DMS_fnc_SelectOffsetPos``` and ```DMS_fnc_SelectRandomVal``` * Adjusted a couple functions to use them. * Fixed ```DMS_fnc_IsNearWater```.
35 lines
448 B
Plaintext
35 lines
448 B
Plaintext
/*
|
|
DMS_fnc_IsNearWater
|
|
Original function by WAI
|
|
Improved by eraser1
|
|
|
|
Usage:
|
|
[
|
|
_position,
|
|
_radius
|
|
] call DMS_fnc_IsNearWater
|
|
|
|
*/
|
|
|
|
private["_result","_position","_radius"];
|
|
|
|
_result = false;
|
|
_position = _this select 0;
|
|
_radius = _this select 1;
|
|
|
|
try
|
|
{
|
|
for "_i" from 0 to 359 step 45 do
|
|
{
|
|
if (surfaceIsWater ([_position,_radius,_i] call DMS_fnc_SelectOffsetPos)) then
|
|
{
|
|
throw true;
|
|
};
|
|
};
|
|
}
|
|
catch
|
|
{
|
|
_result = true;
|
|
};
|
|
|
|
_result |