diff --git a/@ExileServer/addons/a3_dms/FSM/missions.fsm b/@ExileServer/addons/a3_dms/FSM/missions.fsm
index d21dd70..55b85d5 100644
--- a/@ExileServer/addons/a3_dms/FSM/missions.fsm
+++ b/@ExileServer/addons/a3_dms/FSM/missions.fsm
@@ -138,11 +138,11 @@ class FSM
name = "Check_Mission_Running";
itemno = 6;
init = /*%FSM*/"if(DMS_DEBUG) then {" \n
- " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_MissionsMonitor""];" \n
+ " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_fnc_MissionsMonitor""];" \n
"};" \n
"" \n
"_missionsMonitor = diag_tickTime;" \n
- "call DMS_MissionsMonitor;"/*%FSM*/;
+ "call DMS_fnc_MissionsMonitor;"/*%FSM*/;
precondition = /*%FSM*/""/*%FSM*/;
class Links
{
@@ -166,11 +166,11 @@ class FSM
name = "Mission_Cleanup";
itemno = 11;
init = /*%FSM*/"if(DMS_DEBUG) then {" \n
- " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_CleanUpManager""];" \n
+ " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_fnc_CleanUpManager""];" \n
"};" \n
"" \n
"_cleanupTime = diag_tickTime;" \n
- "call DMS_CleanUpManager;"/*%FSM*/;
+ "call DMS_fnc_CleanUpManager;"/*%FSM*/;
precondition = /*%FSM*/""/*%FSM*/;
class Links
{
@@ -223,11 +223,11 @@ class FSM
name = "Select_Mission";
itemno = 15;
init = /*%FSM*/"if(DMS_DEBUG) then {" \n
- " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_selectMission""];" \n
+ " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_fnc_SelectMission""];" \n
"};" \n
"" \n
"_selectMission = diag_tickTime;" \n
- "call DMS_selectMission;"/*%FSM*/;
+ "call DMS_fnc_SelectMission;"/*%FSM*/;
precondition = /*%FSM*/""/*%FSM*/;
class Links
{
@@ -251,11 +251,11 @@ class FSM
name = "Set_AI_Ownership";
itemno = 18;
init = /*%FSM*/"if(DMS_DEBUG) then {" \n
- " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_SetAILocality""];" \n
+ " diag_log format [""DMS_DEBUG FSM CHECK :: calling DMS_fnc_SetAILocality""];" \n
"};" \n
"" \n
"_aiLocality = diag_tickTime;" \n
- "call DMS_AILocalityManager;"/*%FSM*/;
+ "call DMS_fnc_AILocalityManager;"/*%FSM*/;
precondition = /*%FSM*/""/*%FSM*/;
class Links
{
diff --git a/@ExileServer/addons/a3_dms/config.cpp b/@ExileServer/addons/a3_dms/config.cpp
index e427dbb..5614bef 100644
--- a/@ExileServer/addons/a3_dms/config.cpp
+++ b/@ExileServer/addons/a3_dms/config.cpp
@@ -1,5 +1,7 @@
-class CfgPatches {
- class A3_dms {
+class CfgPatches
+{
+ class A3_dms
+ {
units[] = {};
weapons[] = {};
a3_DMS_version = 2.0;
@@ -7,17 +9,48 @@ class CfgPatches {
requiredAddons[] = {"exile_client","exile_server_config"};
};
};
-class CfgFunctions {
- class dms {
- class main {
+class CfgFunctions
+{
+ class DMS
+ {
+ class main
+ {
file = "\x\addons\dms";
class DMS_preInit
{
preInit = 1;
};
- class DMS_postInit {
+ class DMS_postInit
+ {
postInit = 1;
};
};
+ class compiles
+ {
+ file = "\x\addons\dms\scripts";
+ class AddMissionToMonitor {};
+ class AILocalityManager {};
+ class BroadcastMissionStatus {};
+ class CleanUp {};
+ class CleanUpManager {};
+ class CreateMarker {};
+ class FillCrate {};
+ class FindSafePos {};
+ class FindSuppressor {};
+ class IsNearWater {};
+ class MissionsMonitor {};
+ class MissionSuccessState {};
+ class OnKilled {};
+ class RemoveMarkers {};
+ class SelectMagazine {};
+ class SelectMission {};
+ class SetAILocality {};
+ class SetGroupBehavior {};
+ class SpawnAIGroup {};
+ class SpawnAISoldier {};
+ class SpawnCrate {};
+ class SpawnNonPersistentVehicle {};
+ class TargetsKilled {};
+ };
};
};
diff --git a/@ExileServer/addons/a3_dms/config.sqf b/@ExileServer/addons/a3_dms/config.sqf
index 9898f25..87a1bd5 100644
--- a/@ExileServer/addons/a3_dms/config.sqf
+++ b/@ExileServer/addons/a3_dms/config.sqf
@@ -21,8 +21,8 @@ DMS_DEBUG = false;
DMS_AI_KillPercent = 100; // The percent amount of AI that need to be killed for "killPercent" mission requirement (NOT IMPLEMENTED)
- DMS_BanditMoneyGainOnKill = 100; // The amount of Poptabs gained for killing a bandit
- DMS_BanditRepGainOnKill = 25; // The amount of Respect gained for killing a bandit
+ DMS_BanditMoneyGainOnKill = 50; // The amount of Poptabs gained for killing a bandit
+ DMS_BanditRepGainOnKill = 10; // The amount of Respect gained for killing a bandit
DMS_MissionMarkerWinDot = true; // Keep the mission marker dot with a "win" message after mission is over
DMS_MissionMarkerLoseDot = true; // Keep the mission marker dot with a "lose" message after mission is over
@@ -51,11 +51,11 @@ DMS_DEBUG = false;
//Mission notification settings
DMS_PlayerNotificationTypes = [ // Notification types. Supported values are: ["dynamicTextRequest", "standardHintRequest", "systemChatRequest"]
- //"dynamicTextRequest", <--- Currently won't work.
+ //"dynamicTextRequest", <--- Won't work in Exile v0.9.19
"standardHintRequest",
"systemChatRequest"
];
- DMS_dynamicText_Size = "0.55"; // Dynamic Text size for "dynamicTextRequest" notification type.
+ DMS_dynamicText_Size = "0.65"; // Dynamic Text size for "dynamicTextRequest" notification type.
DMS_dynamicText_Color = "#FFCC00"; // Dynamic Text color for "dynamicTextRequest" notification type.
DMS_MissionTypes = [ // List of missions with spawn chances. If they add up to 100%, they represent the percentage chance each one will spawn
@@ -523,6 +523,6 @@ DMS_DEBUG = false;
// Debug Overwrites
if(DMS_DEBUG) then {
DMS_TimeBetweenMissions = [30,60];
- DMS_MissionTimeOut = [240,300];
+ DMS_MissionTimeOut = [60,90];
diag_log format ["DMS_DEBUG CONFIG :: Overriding DMS_TimeBetweenMissions (%1) and DMS_MissionTimeOut (%2)",DMS_TimeBetweenMissions,DMS_MissionTimeOut];
};
\ No newline at end of file
diff --git a/@ExileServer/addons/a3_dms/fn_DMS_postInit.sqf b/@ExileServer/addons/a3_dms/fn_DMS_postInit.sqf
index a34e71e..71bfe61 100644
--- a/@ExileServer/addons/a3_dms/fn_DMS_postInit.sqf
+++ b/@ExileServer/addons/a3_dms/fn_DMS_postInit.sqf
@@ -3,9 +3,6 @@
Made for Defent for Defents Mission System
And for Numenadayz.com
Written by eraser1
-
-
- [_delay, _function, _params, _persistance] call ExileServer_system_thread_addTask;
*/
RESISTANCE setFriend[WEST,0];
@@ -15,16 +12,6 @@ EAST setFriend[RESISTANCE,0];
EAST setFriend[WEST,0];
WEST setFriend[EAST,0];
-_code =
-{
- "DMS_HC_INIT" addPublicVariableEventHandler
- {
- DMS_HC_Object = _this select 1 select 0;
- diag_log format ["DMS Headless Client :: DMS_HC_Object = %1 | serverTime: %2",DMS_HC_Object,(_this select 1 select 1)];
- };
-};
-[0, _code, [], false] call ExileServer_system_thread_addTask;
-
if(DMS_StaticMission) then
{
diff --git a/@ExileServer/addons/a3_dms/fn_DMS_preInit.sqf b/@ExileServer/addons/a3_dms/fn_DMS_preInit.sqf
index 1372c9e..8788017 100644
--- a/@ExileServer/addons/a3_dms/fn_DMS_preInit.sqf
+++ b/@ExileServer/addons/a3_dms/fn_DMS_preInit.sqf
@@ -1,43 +1,17 @@
/*
- DMS Pre-init (compiles)
+ DMS Pre-init
Written by eraser1 (trainwreckdayz.com)
*/
-/* compiles
-spawn_static = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\spawn_static.sqf";
-heli_para = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\heli_para.sqf";
-heli_patrol = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\heli_patrol.sqf";
-vehicle_patrol = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\vehicle_patrol.sqf";
-vehicle_monitor = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\vehicle_monitor.sqf";
+/* Future stuff
+DMS_SpawnStatic = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SpawnStatic.sqf";
+DMS_HeliPara = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\HeliPara.sqf";
+DMS_HeliPatrol = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\HeliPatrol.sqf";
+DMS_VehPatrol = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\VehPatrol.sqf";
+DMS_VehMonitor = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\VehMonitor.sqf";
*/
-DMS_HC_Object = objNull;
-
-//Completed or WIP
-DMS_selectMission = compileFinal preprocessFileLineNumbers "\x\addons\dms\missions\SelectMission.sqf";
-DMS_MissionsMonitor = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\MissionsMonitor.sqf";
-DMS_MissionSuccessState = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\MissionSuccessState.sqf";
-DMS_findSafePos = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\FindSafePos.sqf";
-DMS_BroadcastMissionStatus = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\BroadcastMissionStatus.sqf";
-DMS_CleanUp = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\CleanUp.sqf";
-DMS_CleanUpManager = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\CleanUpManager.sqf";
-DMS_isPlayerNearbyARRAY = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\IsPlayerNearbyARRAY.sqf";
-DMS_FillCrate = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\FillCrate.sqf";
-DMS_isNearWater = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\IsNearWater.sqf";
-DMS_RemoveMarkers = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\RemoveMarkers.sqf";
-DMS_selectMagazine = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SelectMagazine.sqf";
-DMS_TargetsKilled = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\TargetsKilled.sqf";
-DMS_SpawnAIGroup = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SpawnAIGroup.sqf";
-DMS_SpawnAISoldier = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SpawnAISoldier.sqf";
-DMS_OnKilled = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\OnKilled.sqf";
-DMS_SetGroupBehavior = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SetGroupBehavior.sqf";
-DMS_AddMissionToMonitor = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\AddMissionToMonitor.sqf";
-DMS_CreateMarker = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\CreateMarker.sqf";
-DMS_FindSuppressor = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\FindSuppressor.sqf";
-DMS_SpawnCrate = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SpawnCrate.sqf";
-DMS_SetAILocality = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SetAILocality.sqf";
-DMS_AILocalityManager = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\AILocalityManager.sqf";
-DMS_SpawnNonPersistentVehicle = compileFinal preprocessFileLineNumbers "\x\addons\dms\scripts\SpawnNonPersistentVehicle.sqf";
+DMS_HC_Object = objNull;
//Load config
call compileFinal preprocessFileLineNumbers "\x\addons\dms\config.sqf";
\ No newline at end of file
diff --git a/@ExileServer/addons/a3_dms/missions/bauhaus.sqf b/@ExileServer/addons/a3_dms/missions/bauhaus.sqf
index 1faef66..f276088 100644
--- a/@ExileServer/addons/a3_dms/missions/bauhaus.sqf
+++ b/@ExileServer/addons/a3_dms/missions/bauhaus.sqf
@@ -5,7 +5,7 @@
Called from DMS_selectMission
*/
-private ["_num", "_side", "_pos", "_difficulty", "_AICount", "_group", "_crate", "_crate_loot_values", "_msgStart", "_msgWIN", "_msgLOSE", "_missionName", "_missionAIUnits", "_missionObjs", "_markers", "_time", "_added","_wreck"];
+private ["_num", "_side", "_pos", "_difficulty", "_AICount", "_group", "_crate1", "_crate_loot_values1", "_crate2", "_crate_loot_values2", "_msgStart", "_msgWIN", "_msgLOSE", "_missionName", "_missionAIUnits", "_missionObjs", "_markers", "_time", "_added","_wreck"];
// For logging purposes
_num = DMS_MissionCount;
@@ -16,7 +16,7 @@ _side = "bandit";
// find position
-_pos = [10,100] call DMS_findSafePos;
+_pos = [10,100] call DMS_fnc_findSafePos;
// Set general mission difficulty
@@ -34,21 +34,28 @@ _group =
"random", // "random","hardcore","difficult","moderate", or "easy"
"random", // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // "bandit","hero", etc.
-] call DMS_SpawnAIGroup;
+] call DMS_fnc_SpawnAIGroup;
-// Create Crate
-_crate = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
+// Create Crates
+_crate1 = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
+_crate2 = ["Box_NATO_Wps_F",[(_pos select 0)+2,(_pos select 1)-1,0]] call DMS_fnc_SpawnCrate;
_wreck = createVehicle ["Land_Wreck_Ural_F",[(_pos select 0) - 10, (_pos select 1),-0.2],[], 0, "CAN_COLLIDE"];
// Set crate loot values
-_crate_loot_values =
+_crate_loot_values1 =
[
2, // Weapons
15, // Items
2 // Backpacks
];
+_crate_loot_values2 =
+[
+ 1, // Weapons
+ 20, // Items
+ 5 // Backpacks
+];
// Define mission-spawned AI Units
@@ -61,8 +68,8 @@ _missionAIUnits =
_missionObjs =
[
[_wreck],
- [_crate],
- _crate_loot_values
+ [],
+ [[_crate1,_crate_loot_values1],[_crate2,_crate_loot_values2]]
];
// Define Mission Start message
@@ -84,7 +91,7 @@ _markers =
_pos,
_missionName,
_difficulty
-] call DMS_CreateMarker;
+] call DMS_fnc_CreateMarker;
// Record time here (for logging purposes, otherwise you could just put "diag_tickTime" into the "DMS_AddMissionToMonitor" parameters directly)
_time = diag_tickTime;
@@ -112,7 +119,7 @@ _added =
[_msgWIN,_msgLOSE],
_markers,
_side
-] call DMS_AddMissionToMonitor;
+] call DMS_fnc_AddMissionToMonitor;
// Check to see if it was added correctly, otherwise delete the stuff
if !(_added) exitWith
@@ -126,8 +133,12 @@ if !(_added) exitWith
} forEach _missionAIUnits;
_cleanup pushBack ((_missionObjs select 0)+(_missionObjs select 1));
+
+ {
+ _cleanup pushBack (_x select 0);
+ } foreach (_missionObjs select 2);
- _cleanup call DMS_CleanUp;
+ _cleanup call DMS_fnc_CleanUp;
// Delete the markers directly
@@ -140,7 +151,7 @@ if !(_added) exitWith
// Notify players
-_msgStart call DMS_BroadcastMissionStatus;
+_msgStart call DMS_fnc_BroadcastMissionStatus;
diff --git a/@ExileServer/addons/a3_dms/missions/lost_battalion.sqf b/@ExileServer/addons/a3_dms/missions/lost_battalion.sqf
index 3f48d8f..f59d52d 100644
--- a/@ExileServer/addons/a3_dms/missions/lost_battalion.sqf
+++ b/@ExileServer/addons/a3_dms/missions/lost_battalion.sqf
@@ -16,7 +16,7 @@ _side = "bandit";
// find position
-_pos = [10,100] call DMS_findSafePos;
+_pos = [10,100] call DMS_fnc_findSafePos;
// Set general mission difficulty
@@ -34,12 +34,11 @@ _group =
"random", // "random","hardcore","difficult","moderate", or "easy"
"random", // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // "bandit","hero", etc.
-] call DMS_SpawnAIGroup;
+] call DMS_fnc_SpawnAIGroup;
// Create Crate
-_crate = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
-_crate2 = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
+_crate = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
// Set crate loot values
_crate_loot_values =
@@ -59,9 +58,9 @@ _missionAIUnits =
// Define mission-spawned objects and loot values
_missionObjs =
[
- [], // No spawned buildings
- [_crate,_crate2],
- _crate_loot_values
+ [],
+ [],
+ [[_crate,_crate_loot_values]]
];
// Define Mission Start message
@@ -83,7 +82,7 @@ _markers =
_pos,
_missionName,
_difficulty
-] call DMS_CreateMarker;
+] call DMS_fnc_CreateMarker;
// Record time here (for logging purposes, otherwise you could just put "diag_tickTime" into the "DMS_AddMissionToMonitor" parameters directly)
_time = diag_tickTime;
@@ -111,7 +110,7 @@ _added =
[_msgWIN,_msgLOSE],
_markers,
_side
-] call DMS_AddMissionToMonitor;
+] call DMS_fnc_AddMissionToMonitor;
// Check to see if it was added correctly, otherwise delete the stuff
if !(_added) exitWith
@@ -125,8 +124,12 @@ if !(_added) exitWith
} forEach _missionAIUnits;
_cleanup pushBack ((_missionObjs select 0)+(_missionObjs select 1));
+
+ {
+ _cleanup pushBack (_x select 0);
+ } foreach (_missionObjs select 2);
- _cleanup call DMS_CleanUp;
+ _cleanup call DMS_fnc_CleanUp;
// Delete the markers directly
@@ -139,7 +142,7 @@ if !(_added) exitWith
// Notify players
-_msgStart call DMS_BroadcastMissionStatus;
+_msgStart call DMS_fnc_BroadcastMissionStatus;
diff --git a/@ExileServer/addons/a3_dms/missions/mission1.sqf b/@ExileServer/addons/a3_dms/missions/mission1.sqf
index 40fbe7f..1028d45 100644
--- a/@ExileServer/addons/a3_dms/missions/mission1.sqf
+++ b/@ExileServer/addons/a3_dms/missions/mission1.sqf
@@ -16,7 +16,7 @@ _side = "bandit";
// find position
-_pos = [10,100] call DMS_findSafePos;
+_pos = [10,100] call DMS_fnc_findSafePos;
// Set general mission difficulty
@@ -34,11 +34,11 @@ _group =
"random", // "random","hardcore","difficult","moderate", or "easy"
"random", // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // "bandit","hero", etc.
-] call DMS_SpawnAIGroup;
+] call DMS_fnc_SpawnAIGroup;
// Create Crate
-_crate = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
+_crate = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
// Set crate loot values
_crate_loot_values =
@@ -58,9 +58,9 @@ _missionAIUnits =
// Define mission-spawned objects and loot values
_missionObjs =
[
- [], // No spawned buildings
- [_crate],
- _crate_loot_values
+ [],
+ [],
+ [[_crate,_crate_loot_values]]
];
// Define Mission Start message
@@ -82,7 +82,7 @@ _markers =
_pos,
_missionName,
_difficulty
-] call DMS_CreateMarker;
+] call DMS_fnc_CreateMarker;
// Record time here (for logging purposes, otherwise you could just put "diag_tickTime" into the "DMS_AddMissionToMonitor" parameters directly)
_time = diag_tickTime;
@@ -110,7 +110,7 @@ _added =
[_msgWIN,_msgLOSE],
_markers,
_side
-] call DMS_AddMissionToMonitor;
+] call DMS_fnc_AddMissionToMonitor;
// Check to see if it was added correctly, otherwise delete the stuff
if !(_added) exitWith
@@ -124,8 +124,12 @@ if !(_added) exitWith
} forEach _missionAIUnits;
_cleanup pushBack ((_missionObjs select 0)+(_missionObjs select 1));
+
+ {
+ _cleanup pushBack (_x select 0);
+ } foreach (_missionObjs select 2);
- _cleanup call DMS_CleanUp;
+ _cleanup call DMS_fnc_CleanUp;
// Delete the markers directly
@@ -138,7 +142,7 @@ if !(_added) exitWith
// Notify players
-_msgStart call DMS_BroadcastMissionStatus;
+_msgStart call DMS_fnc_BroadcastMissionStatus;
diff --git a/@ExileServer/addons/a3_dms/missions/mission2.sqf b/@ExileServer/addons/a3_dms/missions/mission2.sqf
index 82ef7eb..7fa6a91 100644
--- a/@ExileServer/addons/a3_dms/missions/mission2.sqf
+++ b/@ExileServer/addons/a3_dms/missions/mission2.sqf
@@ -13,7 +13,7 @@ _side = "bandit";
// find position
-_pos = call DMS_findSafePos;
+_pos = call DMS_fnc_findSafePos;
// Set general mission difficulty
@@ -31,11 +31,11 @@ _group =
"random", // "random","hardcore","difficult","moderate", or "easy"
"random", // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // "bandit","hero", etc.
-] call DMS_SpawnAIGroup;
+] call DMS_fnc_SpawnAIGroup;
// Create Crate
-_crate = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
+_crate = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
// Set crate loot values
_crate_loot_values =
@@ -56,10 +56,9 @@ _missionAIUnits =
_missionObjs =
[
[], // No spawned buildings
- [_crate],
- _crate_loot_values
+ [],
+ [[_crate,_crate_loot_values]]
];
-
// Define Mission Start message
_msgStart = format["A group of mercenaries has been spotted at %1! Kill them and take their equipment!",mapGridPosition _pos];
@@ -79,7 +78,7 @@ _markers =
_pos,
_missionName,
_difficulty
-] call DMS_CreateMarker;
+] call DMS_fnc_CreateMarker;
// Record time here (for logging purposes, otherwise you could just put "diag_tickTime" into the "DMS_AddMissionToMonitor" parameters directly)
_time = diag_tickTime;
@@ -107,7 +106,7 @@ _added =
[_msgWIN,_msgLOSE],
_markers,
_side
-] call DMS_AddMissionToMonitor;
+] call DMS_fnc_AddMissionToMonitor;
// Check to see if it was added correctly, otherwise delete the stuff
if !(_added) exitWith
@@ -121,8 +120,12 @@ if !(_added) exitWith
} forEach _missionAIUnits;
_cleanup pushBack ((_missionObjs select 0)+(_missionObjs select 1));
+
+ {
+ _cleanup pushBack (_x select 0);
+ } foreach (_missionObjs select 2);
- _cleanup call DMS_CleanUp;
+ _cleanup call DMS_fnc_CleanUp;
// Delete the markers directly
@@ -135,7 +138,7 @@ if !(_added) exitWith
// Notify players
-_msgStart call DMS_BroadcastMissionStatus;
+_msgStart call DMS_fnc_BroadcastMissionStatus;
diff --git a/@ExileServer/addons/a3_dms/missions/mission3.sqf b/@ExileServer/addons/a3_dms/missions/mission3.sqf
index d79f114..235bf74 100644
--- a/@ExileServer/addons/a3_dms/missions/mission3.sqf
+++ b/@ExileServer/addons/a3_dms/missions/mission3.sqf
@@ -13,7 +13,7 @@ _side = "bandit";
// find position
-_pos = call DMS_findSafePos;
+_pos = call DMS_fnc_findSafePos;
// Set general mission difficulty
@@ -31,11 +31,11 @@ _group =
"difficult", // "random","hardcore","difficult","moderate", or "easy"
"random", // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // "bandit","hero", etc.
-] call DMS_SpawnAIGroup;
+] call DMS_fnc_SpawnAIGroup;
// Create Crate
-_crate = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
+_crate = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
// Set crate loot values
_crate_loot_values =
@@ -56,8 +56,8 @@ _missionAIUnits =
_missionObjs =
[
[], // No spawned buildings
- [_crate],
- _crate_loot_values
+ [],
+ [[_crate,_crate_loot_values]]
];
// Define Mission Start message
@@ -79,7 +79,7 @@ _markers =
_pos,
_missionName,
_difficulty
-] call DMS_CreateMarker;
+] call DMS_fnc_CreateMarker;
// Record time here (for logging purposes, otherwise you could just put "diag_tickTime" into the "DMS_AddMissionToMonitor" parameters directly)
_time = diag_tickTime;
@@ -107,7 +107,7 @@ _added =
[_msgWIN,_msgLOSE],
_markers,
_side
-] call DMS_AddMissionToMonitor;
+] call DMS_fnc_AddMissionToMonitor;
// Check to see if it was added correctly, otherwise delete the stuff
if !(_added) exitWith
@@ -121,8 +121,12 @@ if !(_added) exitWith
} forEach _missionAIUnits;
_cleanup pushBack ((_missionObjs select 0)+(_missionObjs select 1));
+
+ {
+ _cleanup pushBack (_x select 0);
+ } foreach (_missionObjs select 2);
- _cleanup call DMS_CleanUp;
+ _cleanup call DMS_fnc_CleanUp;
// Delete the markers directly
@@ -135,7 +139,7 @@ if !(_added) exitWith
// Notify players
-_msgStart call DMS_BroadcastMissionStatus;
+_msgStart call DMS_fnc_BroadcastMissionStatus;
diff --git a/@ExileServer/addons/a3_dms/missions/mission4.sqf b/@ExileServer/addons/a3_dms/missions/mission4.sqf
index ef29091..2be559a 100644
--- a/@ExileServer/addons/a3_dms/missions/mission4.sqf
+++ b/@ExileServer/addons/a3_dms/missions/mission4.sqf
@@ -13,7 +13,7 @@ _side = "bandit";
// find position
-_pos = call DMS_findSafePos;
+_pos = call DMS_fnc_findSafePos;
// Set general mission difficulty
@@ -31,11 +31,11 @@ _group =
"hardcore", // "random","hardcore","difficult","moderate", or "easy"
"random", // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // "bandit","hero", etc.
-] call DMS_SpawnAIGroup;
+] call DMS_fnc_SpawnAIGroup;
// Create Crate
-_crate = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
+_crate = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
// Set crate loot values
_crate_loot_values =
@@ -56,8 +56,8 @@ _missionAIUnits =
_missionObjs =
[
[], // No spawned buildings
- [_crate],
- _crate_loot_values
+ [],
+ [[_crate,_crate_loot_values]]
];
// Define Mission Start message
@@ -79,7 +79,7 @@ _markers =
_pos,
_missionName,
_difficulty
-] call DMS_CreateMarker;
+] call DMS_fnc_CreateMarker;
// Record time here (for logging purposes, otherwise you could just put "diag_tickTime" into the "DMS_AddMissionToMonitor" parameters directly)
_time = diag_tickTime;
@@ -107,7 +107,7 @@ _added =
[_msgWIN,_msgLOSE],
_markers,
_side
-] call DMS_AddMissionToMonitor;
+] call DMS_fnc_AddMissionToMonitor;
// Check to see if it was added correctly, otherwise delete the stuff
if !(_added) exitWith
@@ -121,8 +121,12 @@ if !(_added) exitWith
} forEach _missionAIUnits;
_cleanup pushBack ((_missionObjs select 0)+(_missionObjs select 1));
+
+ {
+ _cleanup pushBack (_x select 0);
+ } foreach (_missionObjs select 2);
- _cleanup call DMS_CleanUp;
+ _cleanup call DMS_fnc_CleanUp;
// Delete the markers directly
@@ -135,7 +139,7 @@ if !(_added) exitWith
// Notify players
-_msgStart call DMS_BroadcastMissionStatus;
+_msgStart call DMS_fnc_BroadcastMissionStatus;
diff --git a/@ExileServer/addons/a3_dms/missions/walmart.sqf b/@ExileServer/addons/a3_dms/missions/walmart.sqf
index a5f451f..a14c455 100644
--- a/@ExileServer/addons/a3_dms/missions/walmart.sqf
+++ b/@ExileServer/addons/a3_dms/missions/walmart.sqf
@@ -16,7 +16,7 @@ _side = "bandit";
// find position
-_pos = [10,100] call DMS_findSafePos;
+_pos = [10,100] call DMS_fnc_findSafePos;
// Set general mission difficulty
@@ -34,11 +34,11 @@ _group =
"random", // "random","hardcore","difficult","moderate", or "easy"
"random", // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // "bandit","hero", etc.
-] call DMS_SpawnAIGroup;
+] call DMS_fnc_SpawnAIGroup;
// Create Crate
-_crate = ["Box_NATO_Wps_F",_pos] call DMS_SpawnCrate;
+_crate = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
_wreck1 = createVehicle ["Land_i_Shop_01_V1_F",[(_pos select 0) - 10, (_pos select 1),-0.1],[], 0, "CAN_COLLIDE"];
_wreck2 = createVehicle ["Land_Sacks_goods_F",[(_pos select 0) - 2, (_pos select 1),-0.8],[], 0, "CAN_COLLIDE"];
_wreck3 = createVehicle ["Land_StallWater_F",[(_pos select 0) - 5, (_pos select 1),-0.8],[], 0, "CAN_COLLIDE"];
@@ -64,8 +64,8 @@ _missionAIUnits =
_missionObjs =
[
[_wreck1,_wreck2,_wreck3,_wreck4,_wreck5],
- [_crate],
- _crate_loot_values
+ [],
+ [[_crate,_crate_loot_values]]
];
// Define Mission Start message
@@ -87,7 +87,7 @@ _markers =
_pos,
_missionName,
_difficulty
-] call DMS_CreateMarker;
+] call DMS_fnc_CreateMarker;
// Record time here (for logging purposes, otherwise you could just put "diag_tickTime" into the "DMS_AddMissionToMonitor" parameters directly)
_time = diag_tickTime;
@@ -115,7 +115,7 @@ _added =
[_msgWIN,_msgLOSE],
_markers,
_side
-] call DMS_AddMissionToMonitor;
+] call DMS_fnc_AddMissionToMonitor;
// Check to see if it was added correctly, otherwise delete the stuff
if !(_added) exitWith
@@ -130,7 +130,7 @@ if !(_added) exitWith
_cleanup pushBack ((_missionObjs select 0)+(_missionObjs select 1));
- _cleanup call DMS_CleanUp;
+ _cleanup call DMS_fnc_CleanUp;
// Delete the markers directly
@@ -143,7 +143,7 @@ if !(_added) exitWith
// Notify players
-_msgStart call DMS_BroadcastMissionStatus;
+_msgStart call DMS_fnc_BroadcastMissionStatus;
diff --git a/@ExileServer/addons/a3_dms/scripts/MissionsMonitor.sqf b/@ExileServer/addons/a3_dms/scripts/MissionsMonitor.sqf
deleted file mode 100644
index f463d97..0000000
--- a/@ExileServer/addons/a3_dms/scripts/MissionsMonitor.sqf
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- DMS_MissionStatusCheck
-
- Created by eraser1
-
- Each mission has its own index in "DMS_Mission_Arr".
- Every index is a subarray with the values:
- [
- _pos,
- _completionInfo, //<--- More info in "DMS_AddMissionToMonitor"
- [_timeStarted,_timeUntilFail],
- [_AIUnit1,_AIUnit2,...,_AIUnitX],
- [
- [_cleanupObj1,_cleanupObj2,...,_cleanupObjX],
- [_crate,_vehicle1,_vehicle2,...,_vehicleX],
- [_crate_loot_values]
- ],
- [_msgWIN,_msgLose],
- [_markerDot,_markerCircle],
- _side
- ]
-*/
-if (DMS_Mission_Arr isEqualTo []) exitWith // Empty array, no missions running
-{
- /* Removed because RPT spam
- if (DMS_DEBUG) then
- {
- diag_log "DMS_DEBUG MissionStatusCheck :: DMS_Mission_Arr is empty!";
- };
- */
-};
-
-
-_index = 0;
-{
- call
- {
- if (DMS_DEBUG) then
- {
- diag_log format ["DMS_DEBUG MissionStatusCheck :: Checking Mission Status (index %1): %2",_index,_x];
- };
- _pos = _x select 0;
- _success = (_x select 1) call DMS_MissionSuccessState;
- _timeStarted = _x select 2 select 0;
- _timeUntilFail = _x select 2 select 1;
- _units = _x select 3;
- _buildings = _x select 4 select 0;
- _loot = _x select 4 select 1;
- _crate_loot_values = _x select 4 select 2;
- _msgWIN = _x select 5 select 0;
- _msgLose = _x select 5 select 1;
- _markers = _x select 6;
- _missionSide = _x select 7;
-
- if (_success) exitWith
- {
- DMS_CleanUpList pushBack [_units+_buildings,diag_tickTime,DMS_CompletedMissionCleanupTime];
-
- if (_missionSide == "bandit") then
- {
- DMS_RunningBMissionCount = DMS_RunningBMissionCount - 1;
- }
- else
- {
- // Not yet implemented
- };
-
- _arr = DMS_Mission_Arr deleteAt _index;
-
- [_loot select 0,_crate_loot_values] call DMS_FillCrate;
- _msgWIN call DMS_BroadcastMissionStatus;
- [_markers,"win"] call DMS_RemoveMarkers;
-
- if (DMS_DEBUG) then
- {
- diag_log format ["DMS_DEBUG MissionStatusCheck :: Mission Success at %1 with message %2.",_pos,_msgWIN];
- };
- };
-
- if (DMS_MissionTimeoutReset && {[_pos,DMS_MissionTimeoutResetRange] call ExileServer_util_position_isPlayerNearby}) exitWith
- {
- _x set [2,[diag_tickTime,_timeUntilFail]];
-
- if (DMS_DEBUG) then
- {
- diag_log format ["DMS_DEBUG MissionStatusCheck :: Mission Timeout Extended at %1 with timeout after %2 seconds. Position: %3",diag_tickTime,_timeUntilFail,_pos];
- };
- };
-
- if ((diag_tickTime-_timeStarted)>_timeUntilFail) exitWith
- {
- //Nobody is nearby so just cleanup objects from here
- (_units+_buildings+_loot) call DMS_CleanUp;
-
- if (_missionSide == "bandit") then
- {
- DMS_RunningBMissionCount = DMS_RunningBMissionCount - 1;
- }
- else
- {
- // Not yet implemented
- };
-
- _arr = DMS_Mission_Arr deleteAt _index;
-
- _msgLose call DMS_BroadcastMissionStatus;
- [_markers,"lose"] call DMS_RemoveMarkers;
-
- if (DMS_DEBUG) then
- {
- diag_log format ["DMS_DEBUG MissionStatusCheck :: Mission Fail at %1 with message %2.",_pos,_msgLose];
- };
- };
- };
- _index = _index + 1;
-} forEach DMS_Mission_Arr;
\ No newline at end of file
diff --git a/@ExileServer/addons/a3_dms/scripts/AILocalityManager.sqf b/@ExileServer/addons/a3_dms/scripts/fn_AILocalityManager.sqf
similarity index 91%
rename from @ExileServer/addons/a3_dms/scripts/AILocalityManager.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_AILocalityManager.sqf
index e43092b..473bda5 100644
--- a/@ExileServer/addons/a3_dms/scripts/AILocalityManager.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_AILocalityManager.sqf
@@ -1,5 +1,5 @@
/*
- DMS_AILocalityManager
+ DMS_fnc_AILocalityManager
Created by Defent and eraser1
Offloads AI groups to a nearby client in order to improve server performance.
@@ -34,7 +34,7 @@ if !(DMS_ai_offload_to_client) exitWith {};
if ((isNull _owner) || {(_owner distance2D _leader)>3500}) then
{
- [_group,_leader] call DMS_SetAILocality;
+ [_group,_leader] call DMS_fnc_SetAILocality;
};
}
else
diff --git a/@ExileServer/addons/a3_dms/scripts/AddMissionToMonitor.sqf b/@ExileServer/addons/a3_dms/scripts/fn_AddMissionToMonitor.sqf
similarity index 83%
rename from @ExileServer/addons/a3_dms/scripts/AddMissionToMonitor.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_AddMissionToMonitor.sqf
index 0399cdb..5c26c6b 100644
--- a/@ExileServer/addons/a3_dms/scripts/AddMissionToMonitor.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_AddMissionToMonitor.sqf
@@ -1,5 +1,5 @@
/*
- DMS_AddMissionToMonitor
+ DMS_fnc_AddMissionToMonitor
Created by eraser1
Parses and adds mission information to "DMS_Mission_Arr" for Mission Monitoring.
@@ -34,20 +34,23 @@
],
[
[_cleanupObj1,_cleanupObj2,...,_cleanupObjX],
- [_crate,_vehicle1,_vehicle2,...,_vehicleX],
- _crate_loot_values
+ [_vehicle1,_vehicle2,...,_vehicleX],
+ [
+ [_crate1,_crate_loot_values1],
+ [_crate2,_crate_loot_values2]
+ ]
],
[_msgWIN,_msgLose],
[_markerDot,_markerCircle],
_side
- ] call DMS_AddMissionToMonitor;
+ ] call DMS_fnc_AddMissionToMonitor;
Returns whether or not info was added successfully
"_completionInfo", "_timeOutInfo", "_inputUnits", "_missionObjs", "_messages", "_markers", "_side", "_timeStarted", "_timeUntilFail"
*/
-private ["_added", "_pos", "_OK", "_completionInfo", "_timeOutInfo", "_inputUnits", "_missionObjs", "_messages", "_markers", "_timeStarted", "_timeUntilFail", "_buildings", "_loot", "_crate_loot_values", "_msgWIN", "_msgLose", "_markerDot", "_markerCircle", "_side","_arr"];
+private ["_added", "_pos", "_OK", "_completionInfo", "_timeOutInfo", "_inputUnits", "_missionObjs", "_messages", "_markers", "_timeStarted", "_timeUntilFail", "_buildings", "_vehs", "_crate_info_array", "_msgWIN", "_msgLose", "_markerDot", "_markerCircle", "_side","_arr"];
_added = false;
@@ -66,7 +69,7 @@ _OK = params
if (!_OK) exitWith
{
- diag_log format ["DMS ERROR :: Calling DMS_AddMissionToMonitor with invalid parameters: %1",_this];
+ diag_log format ["DMS ERROR :: Calling DMS_fnc_AddMissionToMonitor with invalid parameters: %1",_this];
false;
};
@@ -105,8 +108,8 @@ try
_OK = _missionObjs params
[
["_buildings","",[[]]],
- ["_loot","",[[]]],
- ["_crate_loot_values","",[[]],[3]]
+ ["_vehs","",[[]]],
+ ["_crate_info_array","",[[]]]
];
if (!_OK) then
@@ -147,8 +150,8 @@ try
_units,
[
_buildings,
- _loot,
- _crate_loot_values
+ _vehs,
+ _crate_info_array
],
[
_msgWIN,
diff --git a/@ExileServer/addons/a3_dms/scripts/BroadcastMissionStatus.sqf b/@ExileServer/addons/a3_dms/scripts/fn_BroadcastMissionStatus.sqf
similarity index 85%
rename from @ExileServer/addons/a3_dms/scripts/BroadcastMissionStatus.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_BroadcastMissionStatus.sqf
index 9cfcf31..9ce15b8 100644
--- a/@ExileServer/addons/a3_dms/scripts/BroadcastMissionStatus.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_BroadcastMissionStatus.sqf
@@ -1,9 +1,9 @@
/*
- DMS_BroadcastMissionStatus
+ DMS_fnc_BroadcastMissionStatus
Created by eraser1
Usage:
- _message call DMS_BroadcastMissionStatus;
+ _message call DMS_fnc_BroadcastMissionStatus;
Requires "DMS_PlayerNotificationTypes".
diff --git a/@ExileServer/addons/a3_dms/scripts/CleanUp.sqf b/@ExileServer/addons/a3_dms/scripts/fn_CleanUp.sqf
similarity index 86%
rename from @ExileServer/addons/a3_dms/scripts/CleanUp.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_CleanUp.sqf
index 04b24f6..a45f511 100644
--- a/@ExileServer/addons/a3_dms/scripts/CleanUp.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_CleanUp.sqf
@@ -1,5 +1,5 @@
/*
- DMS_CleanUp
+ DMS_fnc_CleanUp
Created by eraser1
Usage:
@@ -8,10 +8,10 @@
_objectOrGroup2,
...
_objectOrGroupN
- ] call DMS_CleanUp;
+ ] call DMS_fnc_CleanUp;
Alternative Usage:
- _objectOrGroup call DMS_CleanUp;
+ _objectOrGroup call DMS_fnc_CleanUp;
*/
@@ -22,10 +22,6 @@ if (DMS_DEBUG) then
if !((typeName _this) == "ARRAY") then
{
- if (DMS_DEBUG) then
- {
- diag_log ("DMS_DEBUG CleanUp :: Converting single object into array: "+str _this);
- };
_this = [_this];
};
@@ -95,9 +91,9 @@ _clean =
{
diag_log format ["DMS_DEBUG CleanUp :: Doing recursive call for ARRAY: %1",_x];
};
- _x call DMS_CleanUp;
+ _x call DMS_fnc_CleanUp;
};
- diag_log format ["DMS ERROR :: Attempted to call DMS_CleanUp on non- group or object %1 from array %2",_x,_this];
+ diag_log format ["DMS ERROR :: Attempted to call DMS_fnc_CleanUp on non- group or object %1 from array %2",_x,_this];
};
} forEach _this;
diff --git a/@ExileServer/addons/a3_dms/scripts/CleanUpManager.sqf b/@ExileServer/addons/a3_dms/scripts/fn_CleanUpManager.sqf
similarity index 80%
rename from @ExileServer/addons/a3_dms/scripts/CleanUpManager.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_CleanUpManager.sqf
index 98800ba..7d9e319 100644
--- a/@ExileServer/addons/a3_dms/scripts/CleanUpManager.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_CleanUpManager.sqf
@@ -1,5 +1,5 @@
/*
- DMS_CleanUpManager
+ DMS_fnc_CleanUpManager
Created by eraser1
Objects to be cleaned up together have an entry in "DMS_CleanUpList"
@@ -36,12 +36,12 @@ if (DMS_CleanUpList isEqualTo []) exitWith {}; // Empty array, no objects to cl
if (!_OK) then
{
- diag_log format ["DMS ERROR :: Invalid parameters for DMS_CleanUpManager: %1 replaced with %2",_x,[_objs,_timeAddedToList,_timeUntilClean]];
+ diag_log format ["DMS ERROR :: Invalid parameters for DMS_fnc_CleanUpManager: %1 replaced with %2",_x,[_objs,_timeAddedToList,_timeUntilClean]];
};
if ((diag_tickTime-_timeAddedToList)>=_timeUntilClean) then
{
- _objs call DMS_CleanUp;
+ _objs call DMS_fnc_CleanUp;
}
else
{
diff --git a/@ExileServer/addons/a3_dms/scripts/CreateMarker.sqf b/@ExileServer/addons/a3_dms/scripts/fn_CreateMarker.sqf
similarity index 95%
rename from @ExileServer/addons/a3_dms/scripts/CreateMarker.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_CreateMarker.sqf
index a35c2f0..a599af8 100644
--- a/@ExileServer/addons/a3_dms/scripts/CreateMarker.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_CreateMarker.sqf
@@ -1,5 +1,5 @@
/*
- DMS_CreateMarker
+ DMS_fnc_CreateMarker
Created by Defent and eraser1
Usage:
@@ -7,7 +7,7 @@
_pos, // Array: Position of the markers
_text, // String: The text on the map marker that will appear on the map
_difficulty, // !!!OPTIONAL!!! String: "hardcore","difficult","moderate", "easy", OR custom color
- ] call DMS_CreateMarker;
+ ] call DMS_fnc_CreateMarker;
Returns markers in format:
[
diff --git a/@ExileServer/addons/a3_dms/scripts/FillCrate.sqf b/@ExileServer/addons/a3_dms/scripts/fn_FillCrate.sqf
similarity index 97%
rename from @ExileServer/addons/a3_dms/scripts/FillCrate.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_FillCrate.sqf
index f495183..d823c3b 100644
--- a/@ExileServer/addons/a3_dms/scripts/FillCrate.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_FillCrate.sqf
@@ -1,5 +1,5 @@
/*
- DMS_FillCrate
+ DMS_fnc_FillCrate
Original credit goes to WAI: https://github.com/nerdalertdk/WICKED-AI
Edited by eraser1
@@ -12,7 +12,7 @@
_items,
_backpacks
]
- ] call DMS_FillCrate;
+ ] call DMS_fnc_FillCrate;
Each loot argument can be an explicitly defined array of weapons with a number to spawn, or simply a number and weapons defined in the config.sqf are used
*/
@@ -87,7 +87,7 @@ if ((_wepCount>0) && {count _weps>0}) then
for "_i" from 1 to _wepCount do
{
_weapon = _weps call BIS_fnc_selectRandom;
- _ammo = _weapon call DMS_selectMagazine;
+ _ammo = _weapon call DMS_fnc_selectMagazine;
if ((typeName _weapon)=="STRING") then
{
_weapon = [_weapon,1];
diff --git a/@ExileServer/addons/a3_dms/scripts/findSafePos.sqf b/@ExileServer/addons/a3_dms/scripts/fn_FindSafePos.sqf
similarity index 94%
rename from @ExileServer/addons/a3_dms/scripts/findSafePos.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_FindSafePos.sqf
index 4b124eb..7b27a34 100644
--- a/@ExileServer/addons/a3_dms/scripts/findSafePos.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_FindSafePos.sqf
@@ -1,12 +1,12 @@
/*
- DMS_findSafePos
+ DMS_fnc_findSafePos
Created by eraser1
Usage:
[
_nearestObjectMinDistance, // (OPTIONAL) Number: Minimum distance from nearest object
_maxTerrainGradient // (OPTIONAL) Number: Maximum terrain gradient (slope)
- ] call DMS_findSafePos;
+ ] call DMS_fnc_findSafePos;
*/
@@ -32,7 +32,7 @@ while{!_validspot} do {
try
{
// Check for nearby water
- if ([_pos,DMS_WaterNearBlacklist] call DMS_isNearWater) exitWith
+ if ([_pos,DMS_WaterNearBlacklist] call DMS_fnc_isNearWater) exitWith
{
throw ("water");
};
diff --git a/@ExileServer/addons/a3_dms/scripts/FindSuppressor.sqf b/@ExileServer/addons/a3_dms/scripts/fn_FindSuppressor.sqf
similarity index 91%
rename from @ExileServer/addons/a3_dms/scripts/FindSuppressor.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_FindSuppressor.sqf
index 2909a90..1ee6a88 100644
--- a/@ExileServer/addons/a3_dms/scripts/FindSuppressor.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_FindSuppressor.sqf
@@ -1,10 +1,10 @@
/*
- DMS_FindSuppressor
- Taken from WAI
+ DMS_fnc_FindSuppressor
+ Originally from WAI
Modified by eraser1 & Defent
Usage:
- _weaponClassName call DMS_FindSuppressor;
+ _weaponClassName call DMS_fnc_FindSuppressor;
*/
diff --git a/@ExileServer/addons/a3_dms/scripts/IsNearWater.sqf b/@ExileServer/addons/a3_dms/scripts/fn_IsNearWater.sqf
similarity index 72%
rename from @ExileServer/addons/a3_dms/scripts/IsNearWater.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_IsNearWater.sqf
index a4b293a..8973d38 100644
--- a/@ExileServer/addons/a3_dms/scripts/IsNearWater.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_IsNearWater.sqf
@@ -1,3 +1,15 @@
+/*
+ DMS_fnc_IsNearWater
+ All credit goes to WAI
+
+ Usage:
+ [
+ _position,
+ _radius
+ ] call DMS_fnc_IsNearWater
+
+*/
+
private["_result","_position","_radius"];
_result = false;
diff --git a/@ExileServer/addons/a3_dms/scripts/MissionSuccessState.sqf b/@ExileServer/addons/a3_dms/scripts/fn_MissionSuccessState.sqf
similarity index 84%
rename from @ExileServer/addons/a3_dms/scripts/MissionSuccessState.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_MissionSuccessState.sqf
index 4ea22e6..3c9d55e 100644
--- a/@ExileServer/addons/a3_dms/scripts/MissionSuccessState.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_MissionSuccessState.sqf
@@ -1,5 +1,5 @@
/*
- DMS_MissionSuccessState
+ DMS_fnc_MissionSuccessState
Created by eraser1
Usage:
@@ -8,7 +8,7 @@
[_completionType2,_completionArgs2],
...
[_completionTypeN,_completionArgsN]
- ] call DMS_MissionSuccessState;
+ ] call DMS_fnc_MissionSuccessState;
*/
if !((typeName _this) == "ARRAY") exitWith
@@ -47,11 +47,11 @@ _success = true;
// Using switch-do so that future cases can be added easily
case "kill":
{
- _success = _completionArgs call DMS_TargetsKilled;
+ _success = _completionArgs call DMS_fnc_TargetsKilled;
};
case "killPercent":
{
- _success = _completionArgs call DMS_TargetsKilledPercent;//<---TODO
+ _success = _completionArgs call DMS_fnc_TargetsKilledPercent;//<---TODO
};
case "playerNear":
{
diff --git a/@ExileServer/addons/a3_dms/scripts/fn_MissionsMonitor.sqf b/@ExileServer/addons/a3_dms/scripts/fn_MissionsMonitor.sqf
new file mode 100644
index 0000000..6bb3665
--- /dev/null
+++ b/@ExileServer/addons/a3_dms/scripts/fn_MissionsMonitor.sqf
@@ -0,0 +1,119 @@
+/*
+ DMS_fnc_MissionStatusCheck
+
+ Created by eraser1
+
+ Each mission has its own index in "DMS_Mission_Arr".
+ Every index is a subarray with the values:
+ [
+ _pos,
+ _completionInfo, //<--- More info in "DMS_AddMissionToMonitor"
+ [_timeStarted,_timeUntilFail],
+ [_AIUnit1,_AIUnit2,...,_AIUnitX],
+ [
+ [_cleanupObj1,_cleanupObj2,...,_cleanupObjX],
+ [_vehicle1,_vehicle2,...,_vehicleX],
+ [
+ [_crate1,_crate_loot_values1],
+ [_crate2,_crate_loot_values2]
+ ]
+ ],
+ [_msgWIN,_msgLose],
+ [_markerDot,_markerCircle],
+ _side
+ ]
+*/
+if (DMS_Mission_Arr isEqualTo []) exitWith {}; // Empty array, no missions running
+
+private ["_pos", "_success", "_timeStarted", "_timeUntilFail", "_units", "_buildings", "_vehs", "_crate_info_array", "_msgWIN", "_msgLose", "_markers", "_missionSide", "_arr", "_cleanupList"];
+
+
+{
+ try
+ {
+ if (DMS_DEBUG) then
+ {
+ diag_log format ["DMS_DEBUG MissionStatusCheck :: Checking Mission Status (index %1): %2",_forEachIndex,_x];
+ };
+ _pos = _x select 0;
+ _success = (_x select 1) call DMS_fnc_MissionSuccessState;
+ _timeStarted = _x select 2 select 0;
+ _timeUntilFail = _x select 2 select 1;
+ _units = _x select 3;
+ _buildings = _x select 4 select 0;
+ _vehs = _x select 4 select 1;
+ _crate_info_array = _x select 4 select 2;
+ _msgWIN = _x select 5 select 0;
+ _msgLose = _x select 5 select 1;
+ _markers = _x select 6;
+ _missionSide = _x select 7;
+
+ if (_success) then
+ {
+ DMS_CleanUpList pushBack [_units+_buildings,diag_tickTime,DMS_CompletedMissionCleanupTime];
+
+ if (_missionSide == "bandit") then
+ {
+ DMS_RunningBMissionCount = DMS_RunningBMissionCount - 1;
+ }
+ else
+ {
+ // Not yet implemented
+ };
+
+ _arr = DMS_Mission_Arr deleteAt _forEachIndex;
+
+ {
+ _x call DMS_fnc_FillCrate;
+ } forEach _crate_info_array;
+
+ _msgWIN call DMS_fnc_BroadcastMissionStatus;
+ [_markers,"win"] call DMS_fnc_RemoveMarkers;
+
+ throw format ["Mission Success at %1 with message %2.",_pos,_msgWIN];
+ };
+
+ if (DMS_MissionTimeoutReset && {[_pos,DMS_MissionTimeoutResetRange] call ExileServer_util_position_isPlayerNearby}) then
+ {
+ _x set [2,[diag_tickTime,_timeUntilFail]];
+
+ throw format ["Mission Timeout Extended at %1 with timeout after %2 seconds. Position: %3",diag_tickTime,_timeUntilFail,_pos];
+ };
+
+ if ((diag_tickTime-_timeStarted)>_timeUntilFail) then
+ {
+ //Nobody is nearby so just cleanup objects from here
+ _cleanupList = (_units+_buildings+_vehs);
+
+ {
+ _cleanupList pushBack (_x select 0);
+ } forEach _crate_info_array;
+
+ _cleanupList call DMS_fnc_CleanUp;
+
+
+ if (_missionSide == "bandit") then
+ {
+ DMS_RunningBMissionCount = DMS_RunningBMissionCount - 1;
+ }
+ else
+ {
+ // Not yet implemented
+ };
+
+ _arr = DMS_Mission_Arr deleteAt _forEachIndex;
+
+ _msgLose call DMS_fnc_BroadcastMissionStatus;
+ [_markers,"lose"] call DMS_fnc_RemoveMarkers;
+
+ throw format ["Mission Fail at %1 with message %2.",_pos,_msgLose];
+ };
+ }
+ catch
+ {
+ if (DMS_DEBUG) then
+ {
+ diag_log format ["DMS_DEBUG MissionStatusCheck :: %1",_exception];
+ };
+ };
+} forEach DMS_Mission_Arr;
\ No newline at end of file
diff --git a/@ExileServer/addons/a3_dms/scripts/OnKilled.sqf b/@ExileServer/addons/a3_dms/scripts/fn_OnKilled.sqf
similarity index 96%
rename from @ExileServer/addons/a3_dms/scripts/OnKilled.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_OnKilled.sqf
index e5ed638..2bd99fc 100644
--- a/@ExileServer/addons/a3_dms/scripts/OnKilled.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_OnKilled.sqf
@@ -1,5 +1,5 @@
/*
- DMS_OnKilled
+ DMS_fnc_OnKilled
Created by eraser1 and Defent
Influenced by WAI
@@ -11,7 +11,7 @@
],
_side, // "bandit" only for now
_type // not currently used
- ] call DMS_OnKilled;
+ ] call DMS_fnc_OnKilled;
*/
@@ -68,7 +68,7 @@ else
if(DMS_ai_remove_launchers && {_launcher != ""}) then
{
- _rockets = _launcher call DMS_selectMagazine;
+ _rockets = _launcher call DMS_fnc_selectMagazine;
_unit removeWeapon _launcher;
{
diff --git a/@ExileServer/addons/a3_dms/scripts/RemoveMarkers.sqf b/@ExileServer/addons/a3_dms/scripts/fn_RemoveMarkers.sqf
similarity index 96%
rename from @ExileServer/addons/a3_dms/scripts/RemoveMarkers.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_RemoveMarkers.sqf
index 8ce72e7..73ae653 100644
--- a/@ExileServer/addons/a3_dms/scripts/RemoveMarkers.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_RemoveMarkers.sqf
@@ -1,5 +1,5 @@
/*
- DMS_RemoveMarkers
+ DMS_fnc_RemoveMarkers
Created by eraser1
Usage:
@@ -9,7 +9,7 @@
_markerCircle
],
_status
- ] call DMS_RemoveMarkers;
+ ] call DMS_fnc_RemoveMarkers;
*/
private ["_markerDot","_markerCircle","_status"];
diff --git a/@ExileServer/addons/a3_dms/scripts/SelectMagazine.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SelectMagazine.sqf
similarity index 77%
rename from @ExileServer/addons/a3_dms/scripts/SelectMagazine.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SelectMagazine.sqf
index 6755ba2..ba64160 100644
--- a/@ExileServer/addons/a3_dms/scripts/SelectMagazine.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SelectMagazine.sqf
@@ -1,9 +1,9 @@
/*
- DMS_selectMagazine
+ DMS_fnc_selectMagazine
Created by eraser1
Usage:
- _weaponClassName call DMS_selectMagazine;
+ _weaponClassName call DMS_fnc_selectMagazine;
Apply magazine type filters if needed
*/
diff --git a/@ExileServer/addons/a3_dms/missions/SelectMission.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SelectMission.sqf
similarity index 97%
rename from @ExileServer/addons/a3_dms/missions/SelectMission.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SelectMission.sqf
index 82e893d..7b4a574 100644
--- a/@ExileServer/addons/a3_dms/missions/SelectMission.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SelectMission.sqf
@@ -1,5 +1,5 @@
/*
- DMS_selectMission
+ DMS_fnc_selectMission
Influenced by WAI
Created by eraser1
diff --git a/@ExileServer/addons/a3_dms/scripts/SetAILocality.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SetAILocality.sqf
similarity index 95%
rename from @ExileServer/addons/a3_dms/scripts/SetAILocality.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SetAILocality.sqf
index 89558f4..a829c12 100644
--- a/@ExileServer/addons/a3_dms/scripts/SetAILocality.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SetAILocality.sqf
@@ -1,12 +1,12 @@
/*
- DMS_SetAILocality
+ DMS_fnc_SetAILocality
Created by Defent and eraser1
Usage:
[
_groupOrUnit,
_posOrObject // Does not have to be defined if element 1 is a unit
- ] call DMS_SetAILocality;
+ ] call DMS_fnc_SetAILocality;
Makes a random player within 3 KM of the AI unit or group the owner.
Offloading AI can increase server performance.
diff --git a/@ExileServer/addons/a3_dms/scripts/SetGroupBehavior.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SetGroupBehavior.sqf
similarity index 90%
rename from @ExileServer/addons/a3_dms/scripts/SetGroupBehavior.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SetGroupBehavior.sqf
index 6a757fd..6ee6fdf 100644
--- a/@ExileServer/addons/a3_dms/scripts/SetGroupBehavior.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SetGroupBehavior.sqf
@@ -1,5 +1,5 @@
/*
- DMS_SetGroupBehavior
+ DMS_fnc_SetGroupBehavior
Created by eraser1
Usage:
@@ -7,7 +7,7 @@
_group,
_pos,
_difficulty
- ] call DMS_SetGroupBehavior;
+ ] call DMS_fnc_SetGroupBehavior;
*/
diff --git a/@ExileServer/addons/a3_dms/scripts/SpawnAIGroup.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SpawnAIGroup.sqf
similarity index 94%
rename from @ExileServer/addons/a3_dms/scripts/SpawnAIGroup.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SpawnAIGroup.sqf
index d8f328e..908bddc 100644
--- a/@ExileServer/addons/a3_dms/scripts/SpawnAIGroup.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SpawnAIGroup.sqf
@@ -1,5 +1,5 @@
/*
- DMS_SpawnAIGroup
+ DMS_fnc_SpawnAIGroup
Created by eraser1
Based off of WAI
@@ -10,7 +10,7 @@
_difficulty, // "random","hardcore","difficult","moderate", or "easy"
_type // "random","assault","MG","sniper" or "unarmed" OR [_type,_launcher]
_side // Only "bandit" is supported atm
- ] call DMS_SpawnAIGroup;
+ ] call DMS_fnc_SpawnAIGroup;
Returns AI Group
*/
@@ -74,7 +74,7 @@ if(_pos_z == 0) then
_group = createGroup (missionNamespace getVariable [format ["DMS_%1Side",_side],EAST]);
for "_i" from 1 to _count do {
- _unit = [_group,[_pos_x,_pos_y,_pos_z],_type,_difficulty,_side] call DMS_SpawnAISoldier;
+ _unit = [_group,[_pos_x,_pos_y,_pos_z],_type,_difficulty,_side] call DMS_fnc_SpawnAISoldier;
};
// An AI will definitely spawn with a launcher if you define type
@@ -104,7 +104,7 @@ _group setFormation "WEDGE";
if(_pos_z == 0) then
{
- [_group,_pos,_difficulty] call DMS_SetGroupBehavior;
+ [_group,_pos,_difficulty] call DMS_fnc_SetGroupBehavior;
};
diff --git a/@ExileServer/addons/a3_dms/scripts/SpawnAISoldier.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SpawnAISoldier.sqf
similarity index 90%
rename from @ExileServer/addons/a3_dms/scripts/SpawnAISoldier.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SpawnAISoldier.sqf
index 0c9fcb7..807b9ef 100644
--- a/@ExileServer/addons/a3_dms/scripts/SpawnAISoldier.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SpawnAISoldier.sqf
@@ -1,5 +1,5 @@
/*
- DMS_SpawnAISoldier
+ DMS_fnc_SpawnAISoldier
Created by eraser1
Based off of WAI
@@ -11,7 +11,7 @@
_difficulty, // "random","hardcore","difficult","moderate", or "easy"
_side, // "bandit","hero", etc.
_customGearSet // OPTIONAL: Manually defined AI gear.
- ] call DMS_SpawnAIGroup;
+ ] call DMS_fnc_SpawnAIGroup;
Usage for _customGearSet:
[
@@ -79,11 +79,21 @@ removeGoggles _unit;
// Give default items
if !(DMS_ai_default_items isEqualTo []) then
{
- {_unit linkItem _x;} forEach DMS_ai_default_items;
+ {
+ // "Why doesn't linkItem work with any of these? Because fuck you, that's why" - BIS
+ if (_x in ["Binocular","Rangefinder","Laserdesignator","Laserdesignator_02","Laserdesignator_03"]) then
+ {
+ _unit addWeapon _x;
+ }
+ else
+ {
+ _unit linkItem _x;
+ };
+ } forEach DMS_ai_default_items;
};
-switch (_type) do
+switch (toLower _type) do
{
case "random" : {_type = DMS_random_AI call BIS_fnc_selectRandom;};
case "unarmed" : {_type = "assault";_unarmed = true;};
@@ -97,10 +107,21 @@ if (!_useCustomGear) then
if !(_type in DMS_ai_SupportedClasses) exitWith
{
diag_log format ["DMS ERROR :: DMS_SpawnAISoldier called with unsupported _type: %1 | _this: %2",_type,_this];
- };// No more idiot-proofing for the following configs
+ };
+
// Equipment (Stuff that goes in the toolbelt slots)
- {_unit linkItem _x;} forEach (missionNamespace getVariable [format ["DMS_%1_equipment",_type],[]]);
+ {
+ if (_x in ["Binocular","Rangefinder","Laserdesignator","Laserdesignator_02","Laserdesignator_03"]) then
+ {
+ _unit addWeapon _x;
+ }
+ else
+ {
+ _unit linkItem _x;
+ };
+ } forEach (missionNamespace getVariable [format ["DMS_%1_equipment",_type],[]]);
+
// Items (Loot stuff that goes in uniform/vest/backpack)
{_unit addItem _x;} forEach (missionNamespace getVariable [format ["DMS_%1_items",_type],[]]);
@@ -143,7 +164,7 @@ if (!_useCustomGear) then
if((random 100) <= (missionNamespace getVariable [format["DMS_%1_suppressor_chance",_type],0])) then
{
- _suppressor = _weapon call DMS_FindSuppressor;
+ _suppressor = _weapon call DMS_fnc_FindSuppressor;
if(_suppressor != "") then
{
_unit addPrimaryWeaponItem _suppressor;
@@ -266,7 +287,7 @@ else
// Soldier killed event handler
-_unit addMPEventHandler ["MPKilled",'if (isServer) then {[_this, '+str _side+', "soldier"] call DMS_OnKilled;};'];
+_unit addMPEventHandler ["MPKilled",'if (isServer) then {[_this, '+str _side+', "soldier"] call DMS_fnc_OnKilled;};'];
_unit enableAI "TARGET";
_unit enableAI "AUTOTARGET";
diff --git a/@ExileServer/addons/a3_dms/scripts/SpawnCrate.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SpawnCrate.sqf
similarity index 90%
rename from @ExileServer/addons/a3_dms/scripts/SpawnCrate.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SpawnCrate.sqf
index 1546826..e8db6d5 100644
--- a/@ExileServer/addons/a3_dms/scripts/SpawnCrate.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SpawnCrate.sqf
@@ -1,12 +1,12 @@
/*
- DMS_SpawnCrate
+ DMS_fnc_SpawnCrate
Created by eraser1
Usage:
[
_crateClassName,
_pos
- ] call DMS_SpawnCrate;
+ ] call DMS_fnc_SpawnCrate;
Returns crate object
*/
diff --git a/@ExileServer/addons/a3_dms/scripts/SpawnNonPersistentVehicle.sqf b/@ExileServer/addons/a3_dms/scripts/fn_SpawnNonPersistentVehicle.sqf
similarity index 90%
rename from @ExileServer/addons/a3_dms/scripts/SpawnNonPersistentVehicle.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_SpawnNonPersistentVehicle.sqf
index bea059b..6f10527 100644
--- a/@ExileServer/addons/a3_dms/scripts/SpawnNonPersistentVehicle.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_SpawnNonPersistentVehicle.sqf
@@ -1,5 +1,5 @@
/*
- DMS_SpawnNonPersistentVehicle
+ DMS_fnc_SpawnNonPersistentVehicle
Spawn a non-saved vehicle in Exile
@@ -10,12 +10,12 @@
[
_vehicleClass, // STRING: Classname of the vehicle
_pos // ARRAY: Position to spawn it at (roughly)
- ] call DMS_SpawnNonPersistentVehicle;
+ ] call DMS_fnc_SpawnNonPersistentVehicle;
Returns the vehicle object of the created vehicle.
EXAMPLE:
- _exampleVeh = ['Exile_Chopper_Hummingbird_Green',_pos] call DMS_SpawnNonPersistentVehicle;
+ _exampleVeh = ['Exile_Chopper_Hummingbird_Green',_pos] call DMS_fnc_SpawnNonPersistentVehicle;
*/
diff --git a/@ExileServer/addons/a3_dms/scripts/TargetsKilled.sqf b/@ExileServer/addons/a3_dms/scripts/fn_TargetsKilled.sqf
similarity index 93%
rename from @ExileServer/addons/a3_dms/scripts/TargetsKilled.sqf
rename to @ExileServer/addons/a3_dms/scripts/fn_TargetsKilled.sqf
index 28aa97c..a00fa16 100644
--- a/@ExileServer/addons/a3_dms/scripts/TargetsKilled.sqf
+++ b/@ExileServer/addons/a3_dms/scripts/fn_TargetsKilled.sqf
@@ -1,5 +1,5 @@
/*
- DMS_TargetsKilled
+ DMS_fnc_TargetsKilled
Created by eraser1
Usage:
@@ -7,7 +7,7 @@
_unit,
_group,
_object
- ] call DMS_TargetsKilled;
+ ] call DMS_fnc_TargetsKilled;
Will accept non-array argument of group, unit, or object.
*/
diff --git a/@ExileServer/addons/a3_dms/scripts/isPlayerNearbyARRAY.sqf b/@ExileServer/addons/a3_dms/scripts/isPlayerNearbyARRAY.sqf
deleted file mode 100644
index 4162acd..0000000
--- a/@ExileServer/addons/a3_dms/scripts/isPlayerNearbyARRAY.sqf
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- DMS_isPlayerNearbyARRAY
- Created by eraser1
-
- Usage:
- [
- [
- _position_or_object1,
- _position_or_object2,
- ...
- _position_or_objectN
- ],
- _radius
- ] call DMS_isPlayerNearbyARRAY;
-
-
- ***DEPRECATED***
-*/
-
-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_DEBUG IsPlayerNearbyARRAY :: %1 is within %2m of %3!",_plyr,_radius,_x];
- };
- };
- } forEach _posArray;
- };
-} forEach allPlayers;
-_result
\ No newline at end of file