mirror of
https://github.com/IT07/a3_vemf_reloaded.git
synced 2024-08-30 16:52:11 +00:00
Syntax
This commit is contained in:
parent
a0c50b385b
commit
b87dcfb4ad
@ -9,41 +9,16 @@
|
||||
Returns: SIDE - unit's side
|
||||
*/
|
||||
|
||||
private ["_r","_f"];
|
||||
private [("_r"),("_f")];
|
||||
_f = getText (configFile >> "CfgVehicles" >> _this >> "faction");
|
||||
if not(_f isEqualTo "") then
|
||||
{
|
||||
scopeName "isNull";
|
||||
if (_f isEqualTo "BLU_G_F") then
|
||||
{
|
||||
_r = WEST;
|
||||
breakOut "isNull";
|
||||
};
|
||||
if (_f isEqualTo "CIV_F") then
|
||||
{
|
||||
_r = civilian;
|
||||
breakOut "isNull";
|
||||
};
|
||||
if (_f isEqualTo "IND_F") then
|
||||
{
|
||||
_r = independent;
|
||||
breakOut "isNull";
|
||||
};
|
||||
if (_f isEqualTo "IND_G_F") then
|
||||
{
|
||||
_r = resistance;
|
||||
breakOut "isNull";
|
||||
};
|
||||
if (_f isEqualTo "OPF_G_F") then
|
||||
{
|
||||
_r = EAST;
|
||||
};
|
||||
} else
|
||||
{
|
||||
["fn_checkSide", 0, format["Failed to find faction of %1", _this]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
scopeName "isEqualTo";
|
||||
if (_f isEqualTo "BLU_G_F") then { _r = WEST; breakOut "isEqualTo" };
|
||||
if (_f isEqualTo "CIV_F") then { _r = civilian; breakOut "isEqualTo" };
|
||||
if (_f isEqualTo "IND_F") then { _r = independent; breakOut "isEqualTo" };
|
||||
if (_f isEqualTo "IND_G_F") then { _r = resistance; breakOut "isEqualTo" };
|
||||
if (_f isEqualTo "OPF_G_F") then { _r = EAST };
|
||||
} else { [("fn_checkSide"),(0),(format["Failed to find faction of %1", _this])] ExecVM ("log" call VEMFr_fnc_scriptPath) };
|
||||
|
||||
if not(isNil "_r") then
|
||||
{
|
||||
_r
|
||||
};
|
||||
|
@ -17,12 +17,12 @@
|
||||
ARRAY - Result
|
||||
*/
|
||||
|
||||
private["_r","_chck","_v","_cfg"];
|
||||
private [("_r"),("_chck"),("_v"),("_cfg")];
|
||||
_r = [];
|
||||
_chck =
|
||||
{
|
||||
if (isNumber _cfg) then { _v = getNumber _cfg };
|
||||
if (isText _cfg) then { _v = getText _cfg };
|
||||
if (isText _cfg) then { _v = toLower (getText _cfg) };
|
||||
if (isArray _cfg) then { _v = getArray _cfg };
|
||||
};
|
||||
|
||||
@ -43,7 +43,7 @@ if (_this isEqualType []) then
|
||||
{
|
||||
if (_this isEqualTypeArray [[],[]]) then
|
||||
{
|
||||
private ["_p","_b"];
|
||||
private [("_p"),("_b")];
|
||||
_p = _this select 0;
|
||||
_b =
|
||||
{
|
||||
|
@ -19,30 +19,32 @@
|
||||
*/
|
||||
|
||||
private [
|
||||
"_r","_this0","_this1","_this2","_this3","_this4","_this5","_this6",
|
||||
"_s0","_s1","_s2","_s3",
|
||||
"_ms0","_arr","_bin","_used","_fltr","_badNames","_maps","_bad",
|
||||
"_pos","_xx","_pos","_hi","_low","_dist","_loc"
|
||||
("_r"),("_this0"),("_this1"),("_this2"),("_this3"),("_this4"),("_this5"),("_this6"),
|
||||
("_s0"),("_s1"),("_s2"),("_s3"),
|
||||
("_ms0"),("_arr"),("_bin"),("_used"),("_fltr"),("_badNames"),("_maps"),("_bad"),
|
||||
("_pos"),("_xx"),("_pos"),("_hi"),("_low"),("_dist"),("_loc")
|
||||
];
|
||||
|
||||
params [
|
||||
["_this0", "", [""]],
|
||||
["_this1", false, [false]],
|
||||
["_this2", [], [[]]],
|
||||
["_this3", -1, [0]],
|
||||
["_this4", -1, [0]],
|
||||
["_this5", -1, [0]],
|
||||
["_this6", "", [""]]
|
||||
[("_this0"),(""),([""])],
|
||||
[("_this1"),(false),([false])],
|
||||
[("_this2"),([]),([[]])],
|
||||
[("_this3"),(-1),([0])],
|
||||
[("_this4"),(-1),([0])],
|
||||
[("_this5"),(-1),([0])],
|
||||
[("_this6"),(""),([""])]
|
||||
];
|
||||
|
||||
([["nonPopulated","noMissionPos","missionDistance","missionList"]] call VEMFr_fnc_config) params ["_s0","_s1","_s2","_s3"];
|
||||
_ms0 = ([["missionSettings",_this6],["skipDistanceReversed"]] call VEMFr_fnc_config) select 0;
|
||||
if (_this6 in _s3) then { _s0 = ([["missionSettings",_this6],["nonPopulated"]] call VEMFr_fnc_config) select 0 };
|
||||
([[("nonPopulated"),("noMissionPos"),("missionDistance"),("missionList")]] call VEMFr_fnc_config) params [("_s0"),("_s1"),("_s2"),("_s3")];
|
||||
_ms0 = ([[("missionSettings"),(_this6)],["skipDistanceReversed"]] call VEMFr_fnc_config) select 0;
|
||||
if (_this6 in _s3) then { _s0 = ([[("missionSettings"),(_this6)],["nonPopulated"]] call VEMFr_fnc_config) select 0 };
|
||||
|
||||
if (_this0 isEqualTo "loc") then
|
||||
{
|
||||
// Get a list of locations close to _this2 (position of player)
|
||||
_arr = nearestLocations [_this2, ["CityCenter","Strategic","StrongpointArea","NameVillage","NameCity","NameCityCapital", if (_s0 isEqualTo 1) then {"nameLocal","Area","BorderCrossing","Hill","fakeTown","Name","RockArea","ViewPoint"}], if (_ms0 > 0) then {_ms0*2} else {worldSize}];
|
||||
_t = [("CityCenter"),("Strategic"),("StrongpointArea"),("NameVillage"),("NameCity"),("NameCityCapital")];
|
||||
if (_s0 isEqualTo "yes") then { _t append [("nameLocal"),("Area"),("BorderCrossing"),("Hill"),("fakeTown"),("Name"),("RockArea"),("ViewPoint")] };
|
||||
_arr = nearestLocations [(_this2),(_t),(if (_ms0 > 0) then {_ms0*2} else {worldSize})];
|
||||
if ((count _arr) > 0) then
|
||||
{
|
||||
_maps = "isClass _x" configClasses (configFile >> "CfgVemfReloaded" >> "blacklists" >> "locations");
|
||||
@ -50,14 +52,14 @@ if (_this0 isEqualTo "loc") then
|
||||
|
||||
if ((toLower worldName) in _maps) then
|
||||
{
|
||||
_bad = ([["blacklists","locations", worldName],["names"]] call VEMFr_fnc_config) select 0
|
||||
_bad = ([[("blacklists"),("locations"),(worldName)],["names"]] call VEMFr_fnc_config) select 0
|
||||
} else
|
||||
{
|
||||
_bad = ([["blacklists","locations","Other"],["names"]] call VEMFr_fnc_config) select 0
|
||||
_bad = ([[("blacklists"),("locations"),("Other")],["names"]] call VEMFr_fnc_config) select 0
|
||||
};
|
||||
|
||||
_bin = [];
|
||||
_used = uiNamespace getVariable ["VEMFrUsedLocs",[]];
|
||||
_used = uiNamespace getVariable [("VEMFrUsedLocs"),([])];
|
||||
|
||||
_fltr =
|
||||
{
|
||||
|
@ -15,12 +15,12 @@
|
||||
BOOLEAN - true if successful
|
||||
*/
|
||||
|
||||
private ["_r","_this0","_m"];
|
||||
private [("_r"),("_this0"),("_m")];
|
||||
params [
|
||||
["_this0", objNull, [objNull]],
|
||||
["_this1", "", [""]],
|
||||
["_this2", "", [""]],
|
||||
["_this3", "", [""]]
|
||||
[("_this0"),(objNull),([objNull])],
|
||||
[("_this1"),(""),([""])],
|
||||
[("_this2"),(""),([""])],
|
||||
[("_this3"),(""),([""])]
|
||||
];
|
||||
|
||||
_r = [];
|
||||
|
@ -20,7 +20,7 @@ if not (isNull _u) then
|
||||
if ((selectRandom _p) isEqualTo 1) then
|
||||
{ // Select random scope
|
||||
_a = getArray (configFile >> "CfgWeapons" >> _w >> "WeaponSlotsInfo" >> "CowsSlot" >> "compatibleItems");
|
||||
if (("allowTWS" call VEMFr_fnc_config) isEqualTo 0) then
|
||||
if (("allowTWS" call VEMFr_fnc_config) isEqualTo "no") then
|
||||
{
|
||||
_bin = [];
|
||||
{
|
||||
|
@ -11,7 +11,7 @@
|
||||
OBJECT - the headless client
|
||||
*/
|
||||
|
||||
private ["_r","_n","_arr","_gl"];
|
||||
private [("_r"),("_n"),("_arr"),("_gl")];
|
||||
_n = "headLessClientNames" call VEMFr_fnc_config;
|
||||
_arr = [];
|
||||
_gl = uiNamespace getVariable "VEMFrHcLoad";
|
||||
|
@ -8,16 +8,16 @@
|
||||
if (isNil "VEMFrHasStarted") then
|
||||
{
|
||||
VEMFrHasStarted = call compileFinal "true";
|
||||
["Launcher", 2, format["/// booting VEMFr v%1 (%2) \\\", getText (configFile >> "CfgPatches" >> "a3_vemf_reloaded" >> "version"), call VEMFr_fnc_whichMod]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("Launcher"),(2),(format["/// booting VEMFr v%1 (%2) \\\", getText (configFile >> "CfgPatches" >> "a3_vemf_reloaded" >> "version"), call VEMFr_fnc_whichMod])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
uiNamespace setVariable ["VEMFrUsedLocs", []];
|
||||
uiNamespace setVariable ["VEMFrHcLoad", [[],[]]];
|
||||
|
||||
if (("overridesToRPT" call VEMFr_fnc_config) isEqualTo 1) then { [] ExecVM ("overrides" call VEMFr_fnc_scriptPath) };
|
||||
if (("overridesToRPT" call VEMFr_fnc_config) isEqualTo "yes") then { [] ExecVM ("overrides" call VEMFr_fnc_scriptPath) };
|
||||
|
||||
{
|
||||
_h = [] ExecVM format["a3_vemf_reloaded\sqf\%1.sqf", _x];
|
||||
if ((_x isEqualTo "checkClasses") OR (_x isEqualTo "spawnStaticAI")) then { waitUntil { if (scriptDone _h) then {true} else {uiSleep 0.1; false} } };
|
||||
} forEach ["checkClasses","missionTimer","REMOTEguard","spawnStaticAI"];
|
||||
} forEach [("checkClasses"),("missionTimer"),("REMOTEguard"),("spawnStaticAI")];
|
||||
|
||||
if ((call VEMFr_fnc_whichMod) isEqualTo "Epoch") then { west setFriend [independent, 0]; independent setFriend [west, 0] };
|
||||
} else { ["Launcher", 0, format["a3_vemf_reloaded FAILED to launch! VEMFrHasStarted (%1) is already defined!", VEMFrHasStarted]] ExecVM ("log" call VEMFr_fnc_scriptPath) };
|
||||
} else { [("Launcher"),(0),(format["a3_vemf_reloaded FAILED to launch! VEMFrHasStarted (%1) is already defined!", VEMFrHasStarted])] ExecVM ("log" call VEMFr_fnc_scriptPath) };
|
||||
|
@ -14,11 +14,11 @@
|
||||
BOOLEAN - true if nothing failed
|
||||
*/
|
||||
|
||||
private ["_r","_this0","_this1","_this2"];
|
||||
private [("_r"),("_this0"),("_this1"),("_this2")];
|
||||
params [
|
||||
["_this0", [], [[]]],
|
||||
["_this1", "", [""]],
|
||||
["_this2", 0, [0]]
|
||||
[("_this0"),([]),([[]])],
|
||||
[("_this1"),(""),([""])],
|
||||
[("_this2"),(0),([0])]
|
||||
];
|
||||
|
||||
if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Static")) then
|
||||
@ -26,19 +26,16 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
scopeName "this";
|
||||
if (_this2 isEqualTo 0) then // Guerilla
|
||||
{
|
||||
private ["_s","_unifs","_headGr","_vests","_packs","_lnchers","_rfles","_pstls","_ls","_lc","_a"];
|
||||
private [("_s"),("_unifs"),("_headGr"),("_vests"),("_packs"),("_lnchers"),("_rfles"),("_pstls"),("_ls"),("_lc"),("_a")];
|
||||
// Define settings
|
||||
([["aiInventory","Guerilla"],["backpacks","faceWear","headGear","launchers","rifles","uniforms","vests"]] call VEMFr_fnc_config) params ["_packs","_faceWr","_headGr","_lnchers","_rfles","_unifs","_vests"];
|
||||
([[("aiInventory"),("Guerilla")],[("backpacks"),("faceWear"),("headGear"),("launchers"),("rifles"),("uniforms"),("vests")]] call VEMFr_fnc_config) params [("_packs"),("_faceWr"),("_headGr"),("_lnchers"),("_rfles"),("_unifs"),("_vests")];
|
||||
{
|
||||
private ["_xx","_g","_a","_pw","_hw"];
|
||||
private [("_xx"),("_g"),("_a"),("_pw"),("_hw")];
|
||||
_xx = _x;
|
||||
// Strip it
|
||||
removeAllWeapons _xx;
|
||||
removeAllItems _xx;
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo 1) then
|
||||
{
|
||||
removeAllAssignedItems _xx;
|
||||
};
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo "yes") then { removeAllAssignedItems _xx };
|
||||
removeVest _xx;
|
||||
removeBackpack _xx;
|
||||
removeGoggles _xx;
|
||||
@ -59,8 +56,8 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_xx addGoggles _g;
|
||||
_g = selectRandom _vests;
|
||||
_xx addVest _g;
|
||||
_ls = [["missionSettings",(_this1)],["allowLaunchers","hasLauncherChance"]] call VEMFr_fnc_config;
|
||||
if ((_ls select 0) isEqualTo 1) then
|
||||
_ls = [[("missionSettings"),(_this1)],[("allowLaunchers"),("hasLauncherChance")]] call VEMFr_fnc_config;
|
||||
if ((_ls select 0) isEqualTo "yes") then
|
||||
{
|
||||
_lc = _ls select 1;
|
||||
if ((_lc isEqualTo 100) OR ((ceil random (100 / _lc) isEqualTo (ceil random (100 / _lc))))) then
|
||||
@ -87,10 +84,10 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
// Select a random weapon
|
||||
_pw = selectRandom _rfles;
|
||||
// Give this guy some ammo
|
||||
_g = [_xx,_pw,"",""] call VEMFr_fnc_giveAmmo;
|
||||
_g = [(_xx),(_pw),(""),("")] call VEMFr_fnc_giveAmmo;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to give ammo to AI: %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to give ammo to AI: %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
_xx addWeapon _pw;
|
||||
_xx selectWeapon _pw;
|
||||
@ -98,7 +95,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_g = [_xx] call VEMFr_fnc_giveWeaponItems;
|
||||
if not _g then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to giveWeaponItems to %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to giveWeaponItems to %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
} forEach _this0;
|
||||
_r = true;
|
||||
@ -107,19 +104,16 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
|
||||
if (_this2 isEqualTo 1) then // Regular police
|
||||
{
|
||||
private ["_s","_headGr","_vests","_unifs","_rfles","_pstls","_packs"];
|
||||
_s = [["aiInventory","PoliceRegular"],["headGear","pistols","rifles","uniforms","vests"]] call VEMFr_fnc_config;
|
||||
_s params ["_headGr","_pstls","_rfles","_unifs","_vests"];
|
||||
private [("_s"),("_headGr"),("_vests"),("_unifs"),("_rfles"),("_pstls"),("_packs")];
|
||||
_s = [[("aiInventory"),("PoliceRegular")],[("headGear"),("pistols"),("rifles"),("uniforms"),("vests")]] call VEMFr_fnc_config;
|
||||
_s params [("_headGr"),("_pstls"),("_rfles"),("_unifs"),("_vests")];
|
||||
{
|
||||
private ["_xx","_g","_pw","_hw"];
|
||||
private [("_xx"),("_g"),("_pw"),("_hw")];
|
||||
_xx = _x;
|
||||
// Strip it
|
||||
removeAllWeapons _xx;
|
||||
removeAllItems _xx;
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo 1) then
|
||||
{
|
||||
removeAllAssignedItems _xx;
|
||||
};
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo "yes") then { removeAllAssignedItems _xx };
|
||||
removeUniform _xx;
|
||||
removeVest _xx;
|
||||
removeBackpack _xx;
|
||||
@ -136,10 +130,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_hw = selectRandom _pstls;
|
||||
// Give this guy some ammo
|
||||
_g = [_xx, _pw, "", _hw] call VEMFr_fnc_giveAmmo;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to give ammo to AI: %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
if (isNil "_g") then { [("fn_loadInv"),(0),(format["FAILED to give ammo to AI: %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath) };
|
||||
_xx addWeapon _pw;
|
||||
_xx selectWeapon _pw;
|
||||
_xx addWeapon _hw;
|
||||
@ -149,10 +140,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
};
|
||||
// Give this guy some weaponItems
|
||||
_g = [_xx] call VEMFr_fnc_giveWeaponItems;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to giveWeaponItems to %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
if (isNil "_g") then { [("fn_loadInv"),(0),(format["FAILED to giveWeaponItems to %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath) };
|
||||
} forEach _this0;
|
||||
_r = true;
|
||||
breakOut "this";
|
||||
@ -160,13 +148,13 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
|
||||
if (_this2 isEqualTo 2) then // Police Special Forces
|
||||
{
|
||||
private ["_s","_rfles","_pstls"];
|
||||
([["aiInventory","PoliceSpecialForces"],["faceWear","headGear","pistols","rifles","uniforms","vests"]] call VEMFr_fnc_config) params ["_faceWr","_headGrr","_pstls","_rfles","_unifs","_vests"];
|
||||
private [("_s"),("_rfles"),("_pstls")];
|
||||
([[("aiInventory"),("PoliceSpecialForces")],[("faceWear"),("headGear"),("pistols"),("rifles"),("uniforms"),("vests")]] call VEMFr_fnc_config) params [("_faceWr"),("_headGrr"),("_pstls"),("_rfles"),("_unifs"),("_vests")];
|
||||
{
|
||||
private ["_xx","_g","_pw","_hw"];
|
||||
private [("_xx"),("_g"),("_pw"),("_hw")];
|
||||
_xx = _x;
|
||||
// Strip it
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo 1) then { removeAllAssignedItems _xx };
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo "yes") then { removeAllAssignedItems _xx };
|
||||
removeAllItems _xx;
|
||||
removeAllWeapons _xx;
|
||||
removeBackpack _xx;
|
||||
@ -185,7 +173,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_g = [_xx, _pw, "", _hw] call VEMFr_fnc_giveAmmo;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to give ammo to AI: %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to give ammo to AI: %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
_xx addWeapon _pw;
|
||||
_xx selectWeapon _pw;
|
||||
@ -197,7 +185,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_g = [_xx] call VEMFr_fnc_giveWeaponItems;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to giveWeaponItems to %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to giveWeaponItems to %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
} forEach _this0;
|
||||
_r = true;
|
||||
@ -205,13 +193,13 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
|
||||
if (_this2 isEqualTo 3) then // Gendarmerie
|
||||
{
|
||||
private ["_rfles","_pstls"];
|
||||
([["aiInventory","Gendarmerie"],["headGear","faceWear","pistols","rifles","uniforms","vests"]] call VEMFr_fnc_config) params ["_headGrr","_facewr","_pstls","_rfles","_unifs","_vests"];
|
||||
private [("_rfles"),("_pstls")];
|
||||
([[("aiInventory"),("Gendarmerie")],[("headGear"),("faceWear"),("pistols"),("rifles"),("uniforms"),("vests")]] call VEMFr_fnc_config) params [("_headGrr"),("_facewr"),("_pstls"),("_rfles"),("_unifs"),("_vests")];
|
||||
{
|
||||
private ["_xx","_g","_pw","_hw"];
|
||||
private [("_xx"),("_g"),("_pw"),("_hw")];
|
||||
_xx = _x;
|
||||
// Strip it
|
||||
if (("removeAllAssignedItems" call VEMFr_fnc_config) isEqualTo 1) then { removeAllAssignedItems _xx };
|
||||
if (("removeAllAssignedItems" call VEMFr_fnc_config) isEqualTo "yes") then { removeAllAssignedItems _xx };
|
||||
removeAllItems _xx;
|
||||
removeAllWeapons _xx;
|
||||
removeBackpack _xx;
|
||||
@ -230,7 +218,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_g = [_xx, _pw, "", _hw] call VEMFr_fnc_giveAmmo;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to give ammo to AI: %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to give ammo to AI: %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
_xx addWeapon _pw;
|
||||
_xx selectWeapon _pw;
|
||||
@ -242,7 +230,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_g = [_xx] call VEMFr_fnc_giveWeaponItems;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to giveWeaponItems to %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to giveWeaponItems to %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
} forEach _this0;
|
||||
_r = true;
|
||||
@ -250,19 +238,16 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
|
||||
if (_this2 isEqualTo 4) then // Raiders
|
||||
{
|
||||
private ["_s","_unifs","_headGr","_vests","_packs","_lnchers","_rfles","_pstls","_ls","_lc","_a"];
|
||||
private [("_s"),("_unifs"),("_headGr"),("_vests"),("_packs"),("_lnchers"),("_rfles"),("_pstls"),("_ls"),("_lc"),("_a")];
|
||||
// Define settings
|
||||
([["aiInventory","ApexBandits"],["backpacks","headGear","launchers","rifles","uniforms","vests"]] call VEMFr_fnc_config) params ["_packs","_headGrr","_lnchers","_rfles","_unifs","_vests"];
|
||||
([[("aiInventory"),("ApexBandits")],[("backpacks"),("headGear"),("launchers"),("rifles"),("uniforms"),("vests")]] call VEMFr_fnc_config) params [("_packs"),("_headGrr"),("_lnchers"),("_rfles"),("_unifs"),("_vests")];
|
||||
{
|
||||
private ["_xx","_g","_a","_pw"];
|
||||
private [("_xx"),("_g"),("_a"),("_pw")];
|
||||
_xx = _x;
|
||||
// Strip it
|
||||
removeAllWeapons _xx;
|
||||
removeAllItems _xx;
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo 1) then
|
||||
{
|
||||
removeAllAssignedItems _xx;
|
||||
};
|
||||
if ("removeAllAssignedItems" call VEMFr_fnc_config isEqualTo "yes") then { removeAllAssignedItems _xx };
|
||||
removeVest _xx;
|
||||
removeBackpack _xx;
|
||||
removeGoggles _xx;
|
||||
@ -281,8 +266,8 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_xx addHeadGear _g;
|
||||
_g = selectRandom _vests;
|
||||
_xx addVest _g;
|
||||
_ls = [["missionSettings",(_this1)],["allowLaunchers","hasLauncherChance"]] call VEMFr_fnc_config;
|
||||
if ((_ls select 0) isEqualTo 1) then
|
||||
_ls = [[("missionSettings"),(_this1)],[("allowLaunchers"),("hasLauncherChance")]] call VEMFr_fnc_config;
|
||||
if ((_ls select 0) isEqualTo "yes") then
|
||||
{
|
||||
_lc = _ls select 1;
|
||||
if ((_lc isEqualTo 100) OR ((ceil random (100 / _lc) isEqualTo (ceil random (100 / _lc))))) then
|
||||
@ -312,7 +297,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_g = [_xx, _pw, "", ""] call VEMFr_fnc_giveAmmo;
|
||||
if (isNil "_g") then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to give ammo to AI: %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to give ammo to AI: %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
_xx addWeapon _pw;
|
||||
_xx selectWeapon _pw;
|
||||
@ -320,7 +305,7 @@ if ((_this1 in ("missionList" call VEMFr_fnc_config)) OR (_this1 isEqualTo "Stat
|
||||
_g = [_xx] call VEMFr_fnc_giveWeaponItems;
|
||||
if not _g then
|
||||
{
|
||||
["fn_loadInv", 0, format["FAILED to giveWeaponItems to %1", _xx]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_loadInv"),(0),(format["FAILED to giveWeaponItems to %1", _xx])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
} forEach _this0;
|
||||
_r = true;
|
||||
|
@ -15,25 +15,20 @@
|
||||
*/
|
||||
|
||||
scopeName "mines";
|
||||
private ["_r","_this0","_this1","_this2","_this3","_s","_ms","_a","_mt"];
|
||||
private [("_r"),("_this0"),("_this1"),("_this2"),("_this3"),("_ms"),("_a"),("_mt")];
|
||||
params [
|
||||
["_this0",[],[[]]],
|
||||
["_this1",-1,[0]],
|
||||
["_this2",-1,[0]],
|
||||
["_this3", "", [""]]
|
||||
[("_this0"),([]),([[]])],
|
||||
[("_this1"),(-1),([0])],
|
||||
[("_this2"),(-1),([0])],
|
||||
[("_this3"),(""),([""])]
|
||||
];
|
||||
|
||||
([["missionSettings",(_this3)],["mines","minesAmount"]] call VEMFr_fnc_config) params ["_ms","_a"];
|
||||
if ((_this3 in ("missionList" call VEMFr_fnc_config)) AND (_ms > 0) AND ((count _this0) isEqualTo 3) AND (_this1 > -1) AND (_this2 > _this1) AND (_a > -1)) then
|
||||
([["missionSettings",(_this3)],["mines","minesAmount"]] call VEMFr_fnc_config) params [("_ms"),("_a")];
|
||||
if ((_this3 in ("missionList" call VEMFr_fnc_config)) AND ((count _this0) isEqualTo 3) AND (_this1 > -1) AND (_this2 > _this1) AND (_a > -1)) then
|
||||
{
|
||||
if (_ms isEqualTo 1) then { _mt = ["ATMine"] };
|
||||
if (_ms isEqualTo 2) then { _mt = ["APERSMine"] };
|
||||
if (_ms isEqualTo 3) then { _mt = ["ATMine","APERSMine"] };
|
||||
if (_ms < 1 OR _ms > 3) then
|
||||
{
|
||||
["fn_mines", 0, "Invalid mines mode!"] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
breakOut "mines"
|
||||
};
|
||||
if (_ms isEqualTo "AT") then { _mt = ["ATMine"] };
|
||||
if (_ms isEqualTo "AP") then { _mt = ["APERSMine"] };
|
||||
if (_ms isEqualTo "ATAP") then { _mt = ["ATMine","APERSMine"] };
|
||||
_r = [];
|
||||
|
||||
for "_m" from 1 to _a do
|
||||
|
@ -12,12 +12,12 @@
|
||||
BOOL - true if player(s) found
|
||||
*/
|
||||
|
||||
private ["_r","_this0","_this1"];
|
||||
private [("_r"),("_this0"),("_this1")];
|
||||
// By default, we assume that there are no players close. The distance check below should prove otherwise if there are players close
|
||||
_r = false;
|
||||
params [
|
||||
["_this0", [], [[]]],
|
||||
["_this1", -1, [0]]
|
||||
[("_this0"),([]),([[]])],
|
||||
[("_this1"),(-1),([0])]
|
||||
];
|
||||
if (((count _this0) isEqualTo 3) AND (_this1 > -1)) then
|
||||
{
|
||||
|
@ -16,37 +16,33 @@
|
||||
ARRAY format [[groups],[50cals]]
|
||||
*/
|
||||
|
||||
private ["_r","_this0","_this1","_this2","_this3","_this4","_this5"];
|
||||
private [("_r"),("_this0"),("_this1"),("_this2"),("_this3"),("_this4"),("_this5")];
|
||||
params [
|
||||
["_this0", [], [[]]],
|
||||
["_this1", 1, [0]],
|
||||
["_this2", 1, [0]],
|
||||
["_this3", -1, [0]],
|
||||
["_this4", "", [""]],
|
||||
["_this5", 175, [0]]
|
||||
[("_this0"),([]),([[]])],
|
||||
[("_this1"),(1),([0])],
|
||||
[("_this2"),(1),([0])],
|
||||
[("_this3"),(-1),([0])],
|
||||
[("_this4"),(""),([""])],
|
||||
[("_this5"),(175),([0])]
|
||||
];
|
||||
|
||||
if (_this4 in ("missionList" call VEMFr_fnc_config)) then
|
||||
{
|
||||
private [
|
||||
"_grps","_s","_ccrcy","_mShk","_mSpd","_stmna","_sptDst","_sptTme",
|
||||
"_crge","_rldSpd","_cmmndng","_gnrl","_gdHss","_nHss","_cl50s","_nts"
|
||||
];
|
||||
private [("_grps"),("_s"),("_ccrcy"),("_mShk"),("_mSpd"),("_stmna"),("_sptDst"),("_sptTme"),("_crge"),("_rldSpd"),("_cmmndng"),("_gnrl"),("_gdHss"),("_nHss"),("_cl50s"),("_nts")];
|
||||
_r = [[],[]];
|
||||
_grps = [];
|
||||
_s = [["aiSkill",(([["aiSkill"],["difficulty"]] call VEMFr_fnc_config) select 0)],["accuracy","aimingShake","aimingSpeed","endurance","spotDistance","spotTime","courage","reloadSpeed","commanding","general"]] call VEMFr_fnc_config;
|
||||
_s params ["_ccrcy","_mShk","_mSpd","_stmna","_sptDst","_sptTme","_crge","_rldSpd","_cmmndng","_gnrl"];
|
||||
_bad = ([["blacklists","buildings"],["classes"]] call VEMFr_fnc_config) select 0;
|
||||
([[("aiSkill"),(([["aiSkill"],["difficulty"]] call VEMFr_fnc_config) select 0)],[("accuracy"),("aimingShake"),("aimingSpeed"),("endurance"),("spotDistance"),("spotTime"),("courage"),("reloadSpeed"),("commanding"),("general")]] call VEMFr_fnc_config) params [("_ccrcy"),("_mShk"),("_mSpd"),("_stmna"),("_sptDst"),("_sptTme"),("_crge"),("_rldSpd"),("_cmmndng"),("_gnrl")];
|
||||
_bad = ([[("blacklists"),("buildings")],["classes"]] call VEMFr_fnc_config) select 0;
|
||||
_gdHss = [];
|
||||
{ // Filter the houses that are too small for one group
|
||||
if not(typeOf _x in _bad) then
|
||||
{
|
||||
if ([_x, _this2] call BIS_fnc_isBuildingEnterable) then
|
||||
if ([(_x),(_this2)] call BIS_fnc_isBuildingEnterable) then
|
||||
{
|
||||
_gdHss pushBack _x;
|
||||
};
|
||||
};
|
||||
} forEach (nearestTerrainObjects [_this0,["House"],_this5]);
|
||||
} forEach (nearestTerrainObjects [(_this0),(["House"]),(_this5)]);
|
||||
|
||||
_gdHss = _gdHss call BIS_fnc_arrayShuffle;
|
||||
_nHss = false;
|
||||
@ -55,7 +51,7 @@ if (_this4 in ("missionList" call VEMFr_fnc_config)) then
|
||||
_nHss = true;
|
||||
};
|
||||
|
||||
_cl50s = ([["missionSettings",(_this4)],["cal50s"]] call VEMFr_fnc_config) select 0;
|
||||
_cl50s = ([[("missionSettings"),(_this4)],["cal50s"]] call VEMFr_fnc_config) select 0;
|
||||
|
||||
_nts = []; // Define units array. the for loops below will fill it with units
|
||||
for "_g" from 1 to _this1 do // Spawn Groups near Position
|
||||
@ -68,7 +64,7 @@ if (_this4 in ("missionList" call VEMFr_fnc_config)) then
|
||||
};
|
||||
};
|
||||
|
||||
private ["_grp","_hs","_hsPstns","_plcd50","_i"];
|
||||
private [("_grp"),("_hs"),("_hsPstns"),("_plcd50"),("_i")];
|
||||
_grp = createGroup ((([[call VEMFr_fnc_whichMod],["unitClass"]] call VEMFr_fnc_config) select 0) call VEMFr_fnc_checkSide);
|
||||
(_r select 0) pushBack _grp;
|
||||
_grp allowFleeing 0;
|
||||
@ -83,10 +79,10 @@ if (_this4 in ("missionList" call VEMFr_fnc_config)) then
|
||||
_plcd50 = false;
|
||||
for "_u" from 1 to _this2 do
|
||||
{
|
||||
private ["_spwnPs","_hmg","_nt"];
|
||||
private [("_spwnPs"),("_hmg"),("_nt")];
|
||||
if _nHss then
|
||||
{
|
||||
_spwnPs = [_this0,20,_this5,1,0,200,0] call BIS_fnc_findSafePos; // Find Nearby Position
|
||||
_spwnPs = [(_this0),(20),(_this5),(1),(0),(200),(0)] call BIS_fnc_findSafePos; // Find Nearby Position
|
||||
} else
|
||||
{
|
||||
_spwnPs = selectRandom _hsPstns;
|
||||
@ -95,14 +91,14 @@ if (_this4 in ("missionList" call VEMFr_fnc_config)) then
|
||||
_plcd50 = true;
|
||||
if (_cl50s > 0) then
|
||||
{
|
||||
_hmg = createVehicle ["O_HMG_01_high_F", _spwnPs, [], 0, "CAN_COLLIDE"];
|
||||
_hmg = createVehicle [("O_HMG_01_high_F"),(_spwnPs),([]),(0),("CAN_COLLIDE")];
|
||||
_hmg setVehicleLock "LOCKEDPLAYER";
|
||||
(_r select 1) pushBack _hmg;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
_nt = _grp createUnit [([[call VEMFr_fnc_whichMod],["unitClass"]] call VEMFr_fnc_config) select 0, _spwnPs, [], 0, "CAN_COLLIDE"]; // Create Unit There
|
||||
_nt = _grp createUnit [(([[call VEMFr_fnc_whichMod],["unitClass"]] call VEMFr_fnc_config) select 0),(_spwnPs),([]),(0),("CAN_COLLIDE")]; // Create Unit There
|
||||
if ((not _nHss) AND (_cl50s > 0)) then
|
||||
{
|
||||
if not(isNil "_hmg") then
|
||||
@ -117,19 +113,19 @@ if (_this4 in ("missionList" call VEMFr_fnc_config)) then
|
||||
_hsPstns deleteAt (_hsPstns find _spwnPs);
|
||||
};
|
||||
|
||||
_nt addMPEventHandler ["mpkilled","if (isDedicated) then { [[(_this select 0),(name(_this select 0))],[(_this select 1),(name(_this select 1))]] ExecVM ('aiKilled' call VEMFr_fnc_scriptPath) }"];
|
||||
_nt addMPEventHandler [("mpkilled"),("if (isDedicated) then { [[(_this select 0),(name(_this select 0))],[(_this select 1),(name(_this select 1))]] ExecVM ('aiKilled' call VEMFr_fnc_scriptPath) }")];
|
||||
|
||||
// Set skills
|
||||
_nt setSkill ["aimingAccuracy", _ccrcy];
|
||||
_nt setSkill ["aimingShake", _mShk];
|
||||
_nt setSkill ["aimingSpeed", _mSpd];
|
||||
_nt setSkill ["endurance", _stmna];
|
||||
_nt setSkill ["spotDistance", _sptDst];
|
||||
_nt setSkill ["spotTime", _sptTme];
|
||||
_nt setSkill ["courage", _crge];
|
||||
_nt setSkill ["reloadSpeed", _rldSpd];
|
||||
_nt setSkill ["commanding", _cmmndng];
|
||||
_nt setSkill ["general", _gnrl];
|
||||
_nt setSkill [("aimingAccuracy"),(_ccrcy)];
|
||||
_nt setSkill [("aimingShake"),(_mShk)];
|
||||
_nt setSkill [("aimingSpeed"),(_mSpd)];
|
||||
_nt setSkill [("endurance"),(_stmna)];
|
||||
_nt setSkill [("spotDistance"),(_sptDst)];
|
||||
_nt setSkill [("spotTime"),(_sptTme)];
|
||||
_nt setSkill [("courage"),(_crge)];
|
||||
_nt setSkill [("reloadSpeed"),(_rldSpd)];
|
||||
_nt setSkill [("commanding"),(_cmmndng)];
|
||||
_nt setSkill [("general"),(_gnrl)];
|
||||
|
||||
_nt enableAI "TARGET";
|
||||
_nt enableAI "AUTOTARGET";
|
||||
@ -145,39 +141,39 @@ if (_this4 in ("missionList" call VEMFr_fnc_config)) then
|
||||
_nt enableAI "PATH";
|
||||
};
|
||||
|
||||
_i = [units _grp, _this4, _this3] call VEMFr_fnc_loadInv; // Load the AI's inventory
|
||||
_i = [(units _grp),(_this4),(_this3)] call VEMFr_fnc_loadInv; // Load the AI's inventory
|
||||
if isNil "_i" then
|
||||
{
|
||||
["fn_spawnInvasionAI", 0, "failed to load AI's inventory..."] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_spawnInvasionAI"),(0),("failed to load AI's inventory...")] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
_grps pushBack _grp; // Push it into the _grps array
|
||||
};
|
||||
|
||||
if (((count _grps) isEqualTo _this1) AND _nHss) then
|
||||
{
|
||||
private ["_wypnts","_wp","_cyc"];
|
||||
private [("_wypnts"),("_wp"),("_cyc")];
|
||||
_wypnts =
|
||||
[
|
||||
[(_this0 select 0), (_this0 select 1)+50, 0],
|
||||
[(_this0 select 0)+50, (_this0 select 1), 0],
|
||||
[(_this0 select 0), (_this0 select 1)-50, 0],
|
||||
[(_this0 select 0)-50, (_this0 select 1), 0]
|
||||
[(_this0 select 0),((_this0 select 1) + 50),(0)],
|
||||
[((_this0 select 0) + 50),(_this0 select 1),(0)],
|
||||
[(_this0 select 0),((_this0 select 1) - 50),(0)],
|
||||
[((_this0 select 0) - 50),(_this0 select 1),(0)]
|
||||
];
|
||||
{ // Make them Patrol
|
||||
for "_z" from 1 to (count _wypnts) do
|
||||
{
|
||||
_wp = _x addWaypoint [(_wypnts select (_z-1)), 10];
|
||||
_wp = _x addWaypoint [(_wypnts select (_z-1)),(10)];
|
||||
_wp setWaypointType "SAD";
|
||||
_wp setWaypointCompletionRadius 20;
|
||||
};
|
||||
_cyc = _x addWaypoint [_this0,10];
|
||||
_cyc = _x addWaypoint [(_this0),(100)];
|
||||
_cyc setWaypointType "CYCLE";
|
||||
_cyc setWaypointCompletionRadius 20;
|
||||
} forEach _grps;
|
||||
};
|
||||
} else
|
||||
{
|
||||
["fn_spawnInvasionAI",0,format["'%1' is not in missionList", _this4]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_spawnInvasionAI"),(0),(format[("'%1' is not in missionList"),(_this4)])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
|
||||
_r
|
||||
|
@ -17,16 +17,16 @@
|
||||
ARRAY with group(s)
|
||||
*/
|
||||
|
||||
private ["_r","_allUnits","_this0","_this1","_this2","_this3","_this4"];
|
||||
private [("_r"),("_allUnits"),("_this0"),("_this1"),("_this2"),("_this3"),("_this4")];
|
||||
_allUnits = [];
|
||||
params [
|
||||
["_this0", [], [[]]],
|
||||
["_this1", 1, [0]],
|
||||
["_this2", 1, [0]],
|
||||
["_this3", -1, [0]],
|
||||
["_this4", "", [""]],
|
||||
["_this5", 0, [0]],
|
||||
["_this6", 20, [0]]
|
||||
[("_this0"),([]),([[]])],
|
||||
[("_this1"),(1),([0])],
|
||||
[("_this2"),(1),([0])],
|
||||
[("_this3"),(-1),([0])],
|
||||
[("_this4"),(""),([""])],
|
||||
[("_this5"),(0),([0])],
|
||||
[("_this6"),(20),([0])]
|
||||
];
|
||||
|
||||
if ((_this4 in ("missionList" call VEMFr_fnc_config)) OR (_this4 isEqualTo "Static")) then
|
||||
@ -34,10 +34,10 @@ if ((_this4 in ("missionList" call VEMFr_fnc_config)) OR (_this4 isEqualTo "Stat
|
||||
scopeName "outer";
|
||||
_r = [];
|
||||
_this0 = [_this0 select 0, _this0 select 1, _this5];
|
||||
private ["_s","_ccrcy","_mshk","_mspd","_stmn","_sptDst","_sptTm","_crg","_rldSpd","_cmmndng","_gnrl","_i","_grp","_unit"];
|
||||
private [("_s"),("_ccrcy"),("_mshk"),("_mspd"),("_stmn"),("_sptDst"),("_sptTm"),("_crg"),("_rldSpd"),("_cmmndng"),("_gnrl"),("_i"),("_grp"),("_unit")];
|
||||
|
||||
_s = [["aiSkill", ([["aiSkill"],["difficulty"]] call VEMFr_fnc_config) select 0],["accuracy","aimingShake","aimingSpeed","endurance","spotDistance","spotTime","courage","reloadSpeed","commanding","general"]] call VEMFr_fnc_config;
|
||||
_s params ["_ccrcy","_mshk","_mspd","_stmn","_sptDst","_sptTm","_crg","_rldSpd","_cmmndng","_gnrl"];
|
||||
_s = [[("aiSkill"),(([["aiSkill"],["difficulty"]] call VEMFr_fnc_config) select 0)],[("accuracy"),("aimingShake"),("aimingSpeed"),("endurance"),("spotDistance"),("spotTime"),("courage"),("reloadSpeed"),("commanding"),("general")]] call VEMFr_fnc_config;
|
||||
_s params [("_ccrcy"),("_mshk"),("_mspd"),("_stmn"),("_sptDst"),("_sptTm"),("_crg"),("_rldSpd"),("_cmmndng"),("_gnrl")];
|
||||
for "_g" from 1 to _this1 do
|
||||
{
|
||||
_grp = createGroup ((([[call VEMFr_fnc_whichMod],["unitClass"]] call VEMFr_fnc_config) select 0) call VEMFr_fnc_checkSide);
|
||||
@ -46,18 +46,18 @@ if ((_this4 in ("missionList" call VEMFr_fnc_config)) OR (_this4 isEqualTo "Stat
|
||||
{
|
||||
_unit = _grp createUnit [(([[call VEMFr_fnc_whichMod],["unitClass"]] call VEMFr_fnc_config) select 0), _this0, [], _this6, "FORM"]; // Create Unit There
|
||||
_allUnits pushBack _unit;
|
||||
_unit addMPEventHandler ["mpkilled","if (isDedicated) then { [[(_this select 0),(name(_this select 0))],[(_this select 1),(name(_this select 1))]] ExecVM ('aiKilled' call VEMFr_fnc_scriptPath) }"];
|
||||
_unit addMPEventHandler [("mpkilled"),("if (isDedicated) then { [[(_this select 0),(name(_this select 0))],[(_this select 1),(name(_this select 1))]] ExecVM ('aiKilled' call VEMFr_fnc_scriptPath) }")];
|
||||
// Set skills
|
||||
_unit setSkill ["aimingAccuracy", _ccrcy];
|
||||
_unit setSkill ["aimingShake", _mshk];
|
||||
_unit setSkill ["aimingSpeed", _mspd];
|
||||
_unit setSkill ["endurance", _stmn];
|
||||
_unit setSkill ["spotDistance", _sptDst];
|
||||
_unit setSkill ["spotTime", _sptTm];
|
||||
_unit setSkill ["courage", _crg];
|
||||
_unit setSkill ["reloadSpeed", _rldSpd];
|
||||
_unit setSkill ["commanding", _cmmndng];
|
||||
_unit setSkill ["general", _gnrl];
|
||||
_unit setSkill [("aimingAccuracy"),(_ccrcy)];
|
||||
_unit setSkill [("aimingShake"),(_mshk)];
|
||||
_unit setSkill [("aimingSpeed"),(_mspd)];
|
||||
_unit setSkill [("endurance"),(_stmn)];
|
||||
_unit setSkill [("spotDistance"),(_sptDst)];
|
||||
_unit setSkill [("spotTime"),(_sptTm)];
|
||||
_unit setSkill [("courage"),(_crg)];
|
||||
_unit setSkill [("reloadSpeed"),(_rldSpd)];
|
||||
_unit setSkill [("commanding"),(_cmmndng)];
|
||||
_unit setSkill [("general"),(_gnrl)];
|
||||
|
||||
_unit enableAI "TARGET";
|
||||
_unit enableAI "AUTOTARGET";
|
||||
@ -75,16 +75,16 @@ if ((_this4 in ("missionList" call VEMFr_fnc_config)) OR (_this4 isEqualTo "Stat
|
||||
_r pushBack _grp;
|
||||
};
|
||||
|
||||
_i = [_allUnits, _this4, _this3] call VEMFr_fnc_loadInv; // Load the AI's inventory
|
||||
_i = [(_allUnits),(_this4),(_this3)] call VEMFr_fnc_loadInv; // Load the AI's inventory
|
||||
if (isNil "_i") then
|
||||
{
|
||||
_r = nil;
|
||||
["fn_spawnVEMFrAI", 0, "failed to load AI's inventory..."] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_spawnVEMFrAI"),(0),("unable to load AI's inventory")] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
breakOut "outer";
|
||||
};
|
||||
} else
|
||||
{
|
||||
["fn_spawnVEMFrAI", 0, format["'%1' is not in missionList or is not equal to 'Static'", _this4]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("fn_spawnVEMFrAI"),(0),(format["'%1' is not in missionList or is not equal to 'Static'", _this4])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
|
||||
_r
|
||||
|
@ -12,25 +12,20 @@
|
||||
BOOL - true if there is a player present
|
||||
*/
|
||||
|
||||
private ["_r","_this0","_this1"];
|
||||
private [("_r"),("_this0"),("_this1")];
|
||||
params [
|
||||
["_this0", [], [[]]],
|
||||
["_this1", -1, [0]]
|
||||
[("_this0"),([]),([[]])],
|
||||
[("_this1"),(-1),([0])]
|
||||
];
|
||||
|
||||
_r = false;
|
||||
if ([_this0, _this1] call VEMFr_fnc_playerNear) then
|
||||
{
|
||||
_r = true;
|
||||
} else
|
||||
if ([(_this0),(_this1)] call VEMFr_fnc_playerNear) then { _r = true }
|
||||
else
|
||||
{
|
||||
private ["_t","_tot"];
|
||||
_t = round time;
|
||||
_tot = ("timeOutTime" call VEMFr_fnc_config)*60;
|
||||
waitUntil { if (([_this0, _this1] call VEMFr_fnc_playerNear) OR (round time - _t > _tot)) then {true} else {uiSleep 4; false} };
|
||||
if ([_this0, _this1] call VEMFr_fnc_playerNear) then
|
||||
{
|
||||
_r = true;
|
||||
};
|
||||
waitUntil { if (([(_this0),(_this1)] call VEMFr_fnc_playerNear) OR (round time - _t > _tot)) then {true} else {uiSleep 4; false} };
|
||||
if ([(_this0),(_this1)] call VEMFr_fnc_playerNear) then { _r = true };
|
||||
};
|
||||
_r
|
||||
|
@ -6,15 +6,15 @@
|
||||
*/
|
||||
|
||||
VEMFrMissionCount = VEMFrMissionCount + 1;
|
||||
_mn = param [0, "", [""]];
|
||||
_mn = param [(0),(""),([""])];
|
||||
if (isNil "VEMFrAttackCount") then { VEMFrAttackCount = 0 };
|
||||
VEMFrAttackCount = VEMFrAttackCount + 1;
|
||||
([["missionSettings",_mn],["maxAttacks","aiSetup","minimumLevel","randomModes"]] call VEMFr_fnc_config) params ["_s0","_s1","_s2","_s3"];
|
||||
([[("missionSettings"),(_mn)],[("maxAttacks"),("aiSetup"),("minimumLevel"),("randomModes")]] call VEMFr_fnc_config) params [("_s0"),("_s1"),("_s2"),("_s3")];
|
||||
if (VEMFrAttackCount <= _s0) then
|
||||
{
|
||||
scopeName "outer";
|
||||
_mod = call VEMFr_fnc_whichMod;
|
||||
_hist = uiNamespace getVariable ["VEMFrAttackedBases",[]];
|
||||
_hist = uiNamespace getVariable [("VEMFrAttackedBases"),([])];
|
||||
_objs = [];
|
||||
{
|
||||
if (((speed _x) < 25) AND ((vehicle _x) isEqualTo _x)) then
|
||||
@ -38,18 +38,18 @@ if (VEMFrAttackCount <= _s0) then
|
||||
{
|
||||
_base = selectRandom _objs;
|
||||
_hist pushBack _base;
|
||||
uiNamespace setVariable ["VEMFrAttackedBases",(_hist)];
|
||||
uiNamespace setVariable [("VEMFrAttackedBases"),(_hist)];
|
||||
_pos = position _base;
|
||||
private "_c";
|
||||
if (_mod isEqualTo "Epoch") then { _c = ["Epoch_Male_F","Epoch_Female_F","Epoch_Female_Camo_F","Epoch_Female_CamoBlue_F","Epoch_Female_CamoBrn_F","Epoch_Female_CamoRed_F","Epoch_Female_Ghillie3_F","Epoch_Female_Ghillie2_F","Epoch_Female_Ghillie1_F","Epoch_Female_Wetsuit_F","Epoch_Female_WetsuitB_F","Epoch_Female_WetsuitC_F","Epoch_Female_WetsuitP_F","Epoch_Female_WetsuitW_F"] };
|
||||
if (_mod isEqualTo "Epoch") then { _c = [("Epoch_Male_F"),("Epoch_Female_F"),("Epoch_Female_Camo_F"),("Epoch_Female_CamoBlue_F"),("Epoch_Female_CamoBrn_F"),("Epoch_Female_CamoRed_F"),("Epoch_Female_Ghillie3_F"),("Epoch_Female_Ghillie2_F"),("Epoch_Female_Ghillie1_F"),("Epoch_Female_Wetsuit_F"),("Epoch_Female_WetsuitB_F"),("Epoch_Female_WetsuitC_F"),("Epoch_Female_WetsuitP_F"),("Epoch_Female_WetsuitW_F")] };
|
||||
if (_mod isEqualTo "Exile") then { _c = ["Exile_Unit_Player"] };
|
||||
_nrPlyr = selectRandom (nearestObjects [_pos, _c,(_base getVariable "ExileTerritorySize")]);
|
||||
if not(isNil "_nrPlyr") then
|
||||
{
|
||||
_baseNm = "a base";
|
||||
if (_mod isEqualTo "Exile") then { _baseNm = _base getVariable ["exileterritoryname","ERROR: UNKNOWN NAME"] };
|
||||
_m = ([[_mod],["aiMode"]] call VEMFr_fnc_config) select 0;
|
||||
if (_s3 isEqualTo 1) then { _m = [0,1,2]; if (("Apex" call VEMFr_fnc_modAppID) in (getDLCs 1)) then { _m pushBack 3; _m pushBack 4 }; _m = selectRandom _m };
|
||||
if (_mod isEqualTo "Exile") then { _baseNm = _base getVariable [("exileterritoryname"),("ERROR: UNKNOWN NAME")] };
|
||||
_m = ([([_mod]),(["aiMode"])] call VEMFr_fnc_config) select 0;
|
||||
if (_s3 isEqualTo "yes") then { _m = [0,1,2]; if (("Apex" call VEMFr_fnc_modAppID) in (getDLCs 1)) then { _m pushBack 3; _m pushBack 4 }; _m = selectRandom _m };
|
||||
_prGrps = [_pos, _s1 select 0, _s1 select 1, _m, _mn, 1000 + (random 1000), 150] call VEMFr_fnc_spawnVEMFrAI;
|
||||
if not(isNil "_prGrps") then
|
||||
{
|
||||
@ -77,8 +77,8 @@ if (VEMFrAttackCount <= _s0) then
|
||||
} forEach _prGrps;
|
||||
_plyrs = nearestObjects [_pos, _c, 275];
|
||||
|
||||
[-1, "NEW BASE ATTACK", format["A para team is on the way to %1 @ %2's location!", _baseNm, name _nrPlyr], _plyrs] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath);
|
||||
["BaseAttack", 1, format["A para team is on the way to %1 @ %2's location!", _baseNm, name _nrPlyr]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[(-1),("NEW BASE ATTACK"),(format[("A para team is on the way to %1 @ %2's location!"),(_baseNm),(name _nrPlyr)]),(_plyrs)] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath);
|
||||
[("BaseAttack"),(1),(format[("A para team is on the way to %1 @ %2's location!"),(_baseNm),(name _nrPlyr)])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
|
||||
while {true} do
|
||||
{
|
||||
@ -91,7 +91,7 @@ if (VEMFrAttackCount <= _s0) then
|
||||
};
|
||||
|
||||
_plyrs = nearestObjects [_pos, _c, 275];
|
||||
[-1, "DEFEATED", format["Base-attack on %1 has been defeated!", _baseNm], _plyrs] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath);
|
||||
[(-1),("DEFEATED"),(format[("Base-attack on %1 has been defeated!"),(_baseNm)]),(_plyrs)] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath);
|
||||
breakOut "outer";
|
||||
} else
|
||||
{
|
||||
@ -100,18 +100,18 @@ if (VEMFrAttackCount <= _s0) then
|
||||
deleteVehicle _x;
|
||||
} forEach (units _x);
|
||||
} forEach _prGrps;
|
||||
["BaseAttack", 0, format["Incorrect amount of total units (%1). Should be %2", _ntCnt, (_s1 select 0) * (_s1 select 1)]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("BaseAttack"),(0),(format[("Incorrect amount of total units (%1). Should be %2"),(_ntCnt),((_s1 select 0) * (_s1 select 1))])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
breakOut "outer";
|
||||
};
|
||||
} else
|
||||
{
|
||||
["BaseAttack", 0, format["Incorrect spawned group count (%1). Should be %2", count _prGrps, _s1 select 0]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("BaseAttack"),(0),(format[("Incorrect spawned group count (%1). Should be %2"),(count _prGrps),(_s1 select 0)])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
breakOut "outer";
|
||||
};
|
||||
} else
|
||||
{
|
||||
_hist deleteAt (_hist find _base);
|
||||
["BaseAttack", 0, "Can not find player near base!"] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("BaseAttack"),(0),("Can not find player near base!")] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
breakOut "outer";
|
||||
};
|
||||
} else { breakOut "outer" };
|
||||
|
@ -6,18 +6,18 @@ VEMFrMissionCount = VEMFrMissionCount + 1;
|
||||
if isNil "VEMFrInvasionCount" then { VEMFrInvasionCount = 0; };
|
||||
VEMFrInvasionCount = VEMFrInvasionCount + 1;
|
||||
_this0 = param [0, "", [""]];
|
||||
if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call VEMFr_fnc_config) select 0)) then
|
||||
if (VEMFrInvasionCount <= (([[("missionSettings"),(_this0)],["maxInvasions"]] call VEMFr_fnc_config) select 0)) then
|
||||
{
|
||||
scopeName "outer";
|
||||
_mod = call VEMFr_fnc_whichMod;
|
||||
|
||||
// Define the settings
|
||||
([
|
||||
["missionSettings",_this0],
|
||||
["groupCount","groupUnits","maxDistancePrefered","skipDistance","useMarker","markCrateVisual","markCrateOnMap","announce","streetLights","streetLightsRestore","streetLightsRange","allowCrateLift","allowRepeat","randomModes","spawnCrateFirst","mines","flairTypes","smokeTypes","minesCleanup","skipDistanceReversed"]
|
||||
] call VEMFr_fnc_config) params ["_ms0","_ms1","_ms2","_ms3","_ms4","_ms5","_ms6","_ms7","_ms8","_ms9","_ms10","_ms11","_ms12","_ms13","_ms14","_ms15","_ms16","_ms17","_ms18","_ms19"];
|
||||
[("missionSettings"),(_this0)],
|
||||
[("groupCount"),("groupUnits"),("maxDistancePrefered"),("skipDistance"),("useMarker"),("markCrateVisual"),("markCrateOnMap"),("announce"),("streetLightsEnabled"),("streetLightsRestore"),("streetLightsRange"),("allowCrateLift"),("allowRepeat"),("randomModes"),("spawnCrateFirst"),("mines"),("flairTypes"),("smokeTypes"),("minesCleanup"),("skipDistanceReversed")]
|
||||
] call VEMFr_fnc_config) params [("_ms0"),("_ms1"),("_ms2"),("_ms3"),("_ms4"),("_ms5"),("_ms6"),("_ms7"),("_ms8"),("_ms9"),("_ms10"),("_ms11"),("_ms12"),("_ms13"),("_ms14"),("_ms15"),("_ms16"),("_ms17"),("_ms18"),("_ms19")];
|
||||
|
||||
([["missionSettings",_this0,"crateParachute"],["enabled","altitude"]] call VEMFr_fnc_config) params ["_cp0","_cp1"];
|
||||
([[("missionSettings"),(_this0),("crateParachute")],[("enabled"),("altitude")]] call VEMFr_fnc_config) params [("_cp0"),("_cp1")];
|
||||
|
||||
_l = ["loc", false, position (selectRandom allPlayers), if (_ms19 > 0) then {_ms19} else {_ms3}, _ms2, if (_ms19 > 0) then {_ms19} else {_ms3}, _this0] call VEMFr_fnc_findPos;
|
||||
if not(isNil "_l") then
|
||||
@ -28,18 +28,18 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
[_this0, 1, format["Invading %1...", _ln]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
|
||||
_m = ([[_mod],["aiMode"]] call VEMFr_fnc_config) select 0;
|
||||
if (_ms13 isEqualTo 1) then { _m = [0,1,2]; if (("Apex" call VEMFr_fnc_modAppID) in (getDLCs 1)) then { _m pushBack 3; _m pushBack 4 }; _m = selectRandom _m };
|
||||
if (_ms7 isEqualTo 1) then
|
||||
if (_ms13 isEqualTo "yes") then { _m = [0,1,2]; if (("Apex" call VEMFr_fnc_modAppID) in (getDLCs 1)) then { _m pushBack 3; _m pushBack 4 }; _m = selectRandom _m };
|
||||
if (_ms7 isEqualTo "yes") then
|
||||
{
|
||||
if (_m isEqualTo 0) then { [_m,"NEW MISSION", format["%1 Guerilla has invaded %2 @ %3", worldName, _ln, mapGridPosition _lp]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 1) then { [_m,"NEW MISSION", format["%1 Police forces are now controlling %2 @ %3", worldName, _ln, mapGridPosition _lp]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 0) then { [(_m),("NEW MISSION"),(format[("%1 Guerilla has invaded %2 @ %3"),(worldName),(_ln),(mapGridPosition _lp)])] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 1) then { [(_m),("NEW MISSION"),(format[("%1 Police forces are now controlling %2 @ %3"),(worldName),(_ln),(mapGridPosition _lp)])] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 2) then { [_m,"NEW MISSION", format["%1 Special Forces are now raiding %2 @ %3", worldName, _ln, mapGridPosition _lp]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 3) then { [1,"NEW MISSION", format["The Gendarmerie has invaded %1 @ %2", _ln, mapGridPosition _lp]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 4) then { [0,"NEW MISSION", format["%1 bandits have taken %2 @ %3", worldName, _ln, mapGridPosition _lp]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
};
|
||||
|
||||
private "_mrkr";
|
||||
if (_ms4 isEqualTo 1) then
|
||||
if (_ms4 isEqualTo "yes") then
|
||||
{ // Create/place the marker if enabled
|
||||
_mrkr = createMarker [format["VEMFrMarker%1", _ln], _lp];
|
||||
_mrkr setMarkerShape "ICON";
|
||||
@ -52,7 +52,7 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
};
|
||||
|
||||
// If enabled, kill all the lights
|
||||
if (_ms8 isEqualTo 0) then
|
||||
if (_ms8 isEqualTo "no") then
|
||||
{
|
||||
{
|
||||
if (damage _x < 0.95) then
|
||||
@ -67,9 +67,9 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
_dSpwnCrt =
|
||||
{
|
||||
// Choose a box
|
||||
_bx = selectRandom (([["missionSettings",_this0],["crateTypes"]] call VEMFr_fnc_config) select 0);
|
||||
_bx = selectRandom (([[("missionSettings"),(_this0)],[("crateTypes")]] call VEMFr_fnc_config) select 0);
|
||||
_ps = [_lp, 0, 200, 0, 0, 300, 0] call bis_fnc_findSafePos;
|
||||
if (_cp0 > 0) then
|
||||
if (_cp0 isEqualTo "yes") then
|
||||
{
|
||||
_cht = createVehicle ["I_Parachute_02_F", _ps, [], 0, "FLY"];
|
||||
if (_mod isEqualTo "Epoch") then { _cht call EPOCH_server_setVToken };
|
||||
@ -113,8 +113,8 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
|
||||
_cl50s = _spwnd select 1;
|
||||
|
||||
([["missionSettings",_this0,"heliPatrol"],["enabled","classesVanilla","classesHeliDLC","classesApex","locked"]] call VEMFr_fnc_config) params ["_hp0","_hp1","_hp2","_hp3","_hp4"];
|
||||
if ((_hp0 > 0) AND ((_m isEqualTo 1) OR (_m isEqualTo 2) OR (_m isEqualTo 3))) then
|
||||
([[("missionSettings"),(_this0),("heliPatrol")],[("enabled"),("classesVanilla"),("classesHeliDLC"),("classesApex"),("locked")]] call VEMFr_fnc_config) params [("_hp0"),("_hp1"),("_hp2"),("_hp3"),("_hp4")];
|
||||
if ((_hp0 isEqualTo "yes") AND ((_m isEqualTo 1) OR (_m isEqualTo 2) OR (_m isEqualTo 3))) then
|
||||
{
|
||||
[_this0, 1, format["Adding a heli patrol to the invasion of %1 at %2", _ln, mapGridPosition _lp]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
_classes = _hp1;
|
||||
@ -124,7 +124,7 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
if (_mod isEqualTo "Epoch") then { _heli call EPOCH_server_setVToken };
|
||||
_heli setPosATL [(getPos _heli) select 0, (getPos _heli) select 1, 750];
|
||||
_heli flyInHeight 80;
|
||||
if (_hp4 isEqualTo 1) then { _heli lock true };
|
||||
if (_hp4 isEqualTo "yes") then { _heli lock true };
|
||||
|
||||
_trrts = allTurrets [_heli, false];
|
||||
|
||||
@ -176,14 +176,14 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
};
|
||||
|
||||
// Place the crate if enabled
|
||||
if (_ms14 isEqualTo 1) then
|
||||
if (_ms14 isEqualTo "yes") then
|
||||
{
|
||||
call _dSpwnCrt;
|
||||
};
|
||||
|
||||
// Place mines if enabled
|
||||
private ["_mnsPlcd","_mines"];
|
||||
if (_ms15 > 0) then
|
||||
private [("_mnsPlcd"),("_mines")];
|
||||
if (_ms15 isEqualTo "yes") then
|
||||
{
|
||||
_mnsPlcd = [_lp, 5, 100, _this0] call VEMFr_fnc_mines;
|
||||
if ((count _mnsPlcd) > 0) then
|
||||
@ -199,39 +199,34 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
_h = [_nts] ExecVM ("killedMonitor" call VEMFr_fnc_scriptPath);
|
||||
waitUntil { if (scriptDone _h) then {true} else {uiSleep 1; false} };
|
||||
|
||||
["DynamicLocationInvasion", 1, format["mission in %1 has been completed!", _ln]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
[("DynamicLocationInvasion"),(1),(format[("mission in %1 has been completed!"),(_ln)])] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
|
||||
if (_ms12 isEqualTo 1) then
|
||||
if (_ms12 isEqualTo "yes") then
|
||||
{
|
||||
_u = uiNamespace getVariable "VEMFrUsedLocs";
|
||||
_u deleteAt (_u find _l);
|
||||
};
|
||||
|
||||
// Broadcast
|
||||
if (_ms7 isEqualTo 1) then
|
||||
if (_ms7 isEqualTo "yes") then
|
||||
{
|
||||
if (_m isEqualTo 0) then { [_m,"MISSION ENDED", format["%1 @ %2 is now clear of %3 Guerillas", _ln, mapGridPosition (_lp), worldName]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 1) then { [_m,"MISSION ENDED", format["%1 @ %2 is now clear of %3 Police Forces", _ln, mapGridPosition (_lp), worldName]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 2) then { [_m,"MISSION ENDED", format["%1 @ %2 is now clear of %3 Special Forces", _ln, mapGridPosition (_lp)]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 3) then { [1,"MISSION ENDED", format["%1 @ %2 is now clear of %3 Gendarmerie", _ln, mapGridPosition _lp, worldName]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 4) then { [0,"MISSION ENDED", format["%1 @ %2 is now clear of %3 bandits", _ln, mapGridPosition _lp, worldName]] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 0) then { [(_m),("MISSION ENDED"),(format[("%1 @ %2 is now clear of %3 Guerillas"),(_ln),(mapGridPosition _lp),(worldName)])] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 1) then { [(_m),("MISSION ENDED"),(format[("%1 @ %2 is now clear of %3 Police Forces"),(_ln),(mapGridPosition _lp),(worldName)])] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 2) then { [(_m),("MISSION ENDED"),(format[("%1 @ %2 is now clear of %3 Special Forces"),(_ln),(mapGridPosition _lp)])] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 3) then { [(1),("MISSION ENDED"),(format[("%1 @ %2 is now clear of %3 Gendarmerie"),(_ln),(mapGridPosition _lp),(worldName)])] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (_m isEqualTo 4) then { [(0),("MISSION ENDED"),(format[("%1 @ %2 is now clear of %3 bandits"),(_ln),(mapGridPosition _lp),(worldName)])] ExecVM ("notificationToClient" call VEMFr_fnc_scriptPath) };
|
||||
};
|
||||
|
||||
// Deal with the 50s
|
||||
if not(isNil "_cl50s") then
|
||||
{
|
||||
_d = ([["missionSettings",_this0],["cal50sDelete"]] call VEMFr_fnc_config) select 0;
|
||||
if (_d > 0) then
|
||||
{
|
||||
{
|
||||
if (_d isEqualTo 1) then { deleteVehicle _x };
|
||||
if (_d isEqualTo 2) then { _x setDamage 1 };
|
||||
} forEach _cl50s;
|
||||
};
|
||||
_d = ([[("missionSettings"),(_this0)],["cal50sDelete"]] call VEMFr_fnc_config) select 0;
|
||||
if (_d isEqualTo "yes") then { { deleteVehicle _x } forEach _cl50s };
|
||||
if (_d isEqualTo "destroy") then { { _x setDamage 1 } forEach _cl50s };
|
||||
};
|
||||
|
||||
if not(isNil "_mrkr") then { deleteMarker _mrkr };
|
||||
if (_ms14 isEqualTo 0) then { call _dSpwnCrt };
|
||||
if (_ms14 isEqualTo "no") then { call _dSpwnCrt };
|
||||
|
||||
// Put a marker on the crate if enabled
|
||||
if not(isNil "_crate") then
|
||||
@ -240,7 +235,7 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
{
|
||||
if not ([getPos _crate, 3] call VEMFr_fnc_playerNear) then
|
||||
{
|
||||
if (_ms5 isEqualTo 1) then
|
||||
if (_ms5 isEqualTo "yes") then
|
||||
{
|
||||
// If night, attach a chemlight
|
||||
if (sunOrMoon <= 0.35) then
|
||||
@ -257,7 +252,7 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
};
|
||||
};
|
||||
|
||||
if (_ms6 isEqualTo 1) then
|
||||
if (_ms6 isEqualTo "yes") then
|
||||
{
|
||||
private "_mrkr";
|
||||
_mrkr = createMarker [format["VEMF_lootCrate_ID%1", random 9000], position _crate];
|
||||
@ -287,7 +282,7 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
// Explode or remove the mines
|
||||
if not(isNil "_mnsPlcd") then
|
||||
{
|
||||
if (_ms18 isEqualTo 2) then
|
||||
if (_ms18 isEqualTo "explode") then
|
||||
{
|
||||
[_this0, _ln, _mnsPlcd] spawn
|
||||
{
|
||||
@ -305,7 +300,7 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
|
||||
_mnsPlcd = nil;
|
||||
};
|
||||
if (_ms18 isEqualTo 1) then
|
||||
if (_ms18 isEqualTo "yes") then
|
||||
{
|
||||
[_mnsPlcd] spawn
|
||||
{
|
||||
@ -319,7 +314,7 @@ if (VEMFrInvasionCount <= (([["missionSettings",_this0],["maxInvasions"]] call V
|
||||
};
|
||||
|
||||
// If enabled, fix all the lights
|
||||
if (_ms9 isEqualTo 1) then
|
||||
if (_ms9 isEqualTo "yes") then
|
||||
{
|
||||
{
|
||||
if (damage _x > 0.94) then
|
||||
|
@ -14,25 +14,25 @@
|
||||
*/
|
||||
|
||||
(_this select 0) params [
|
||||
["_t", objNull, [objNull]],
|
||||
["_nt", "", [""]]
|
||||
[("_t"),(objNull),([objNull])],
|
||||
[("_nt"),(""),([""])]
|
||||
];
|
||||
(_this select 1) params [
|
||||
["_k", objNull, [objNull]],
|
||||
["_nk", "", [""]]
|
||||
[("_k"),(objNull),([objNull])],
|
||||
[("_nk"),(""),([""])]
|
||||
];
|
||||
|
||||
_mod = call VEMFr_fnc_whichMod;
|
||||
if (isPlayer _k) then
|
||||
{
|
||||
scopeName "isPlayer";
|
||||
_mod = call VEMFr_fnc_whichMod;
|
||||
private ["_rspct","_crpt"];
|
||||
private [("_rspct"),("_crpt")];
|
||||
if (_mod isEqualTo "Exile") then
|
||||
{
|
||||
_rspct =
|
||||
{
|
||||
_arr = [[]];
|
||||
(_arr select 0) pushBack [(selectRandom ["AI WACKED","AI CLIPPED","AI WIPED","AI ERASED","AI LYNCHED","AI WRECKED","AI SNUFFED","AI WASTED","AI ZAPPED"]), _rw];
|
||||
(_arr select 0) pushBack [(selectRandom [("AI WACKED"),("AI CLIPPED"),("AI WIPED"),("AI ERASED"),("AI LYNCHED"),("AI WRECKED"),("AI SNUFFED"),("AI WASTED"),("AI ZAPPED")]), _rw];
|
||||
_dist = _t distance _k;
|
||||
_bns = call
|
||||
{
|
||||
@ -120,7 +120,7 @@ if (isPlayer _k) then
|
||||
{
|
||||
if (typeOf (vehicle _t) isEqualTo "Steerable_Parachute_F") then
|
||||
{
|
||||
if ("logCowardKills" call VEMFr_fnc_config isEqualTo 1) then
|
||||
if ("logCowardKills" call VEMFr_fnc_config isEqualTo "yes") then
|
||||
{
|
||||
["fn_aiKilled", 1, format["A coward (%1 @ %2) killed a parachuting AI", _nk, mapGridPosition _k]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
@ -133,7 +133,7 @@ if (isPlayer _k) then
|
||||
};
|
||||
} else // If in vehicle (a.k.a. roadkill)
|
||||
{
|
||||
if (("punishRoadKills" call VEMFr_fnc_config) isEqualTo 1) then
|
||||
if (("punishRoadKills" call VEMFr_fnc_config) isEqualTo "yes") then
|
||||
{
|
||||
if (_mod isEqualTo "Exile") then
|
||||
{
|
||||
@ -147,7 +147,7 @@ if (isPlayer _k) then
|
||||
[_k, "showFragRequest", [[["ROADKILL..."],["Penalty:", -_pnsh]]]] call ExileServer_system_network_send_to;
|
||||
format['setAccountScore:%1:%2', _nwRspct, getPlayerUID _k] call ExileServer_system_database_query_fireAndForget;
|
||||
|
||||
if (("sayKilled" call VEMFr_fnc_config) isEqualTo 1) then { [format["%1 roadkilled %2", _nk, if (("sayKilledName" call VEMFr_fnc_config) > 0) then {_nt + " (AI)"} else {"an AI"}]] ExecVM ("systemChatToClient" call VEMFr_fnc_scriptPath) };
|
||||
if (("sayKilled" call VEMFr_fnc_config) isEqualTo "yes") then { [format["%1 roadkilled %2", _nk, if (("sayKilledName" call VEMFr_fnc_config) isEqualTo "yes") then {_nt + " (AI)"} else {"an AI"}]] ExecVM ("systemChatToClient" call VEMFr_fnc_scriptPath) };
|
||||
};
|
||||
|
||||
if (_mod isEqualTo "Epoch") then
|
||||
@ -165,7 +165,7 @@ if (isPlayer _k) then
|
||||
{
|
||||
if ((typeOf (vehicle _t)) isEqualTo "Steerable_Parachute_F") then
|
||||
{
|
||||
if ("logCowardKills" call VEMFr_fnc_config isEqualTo 1) then
|
||||
if ("logCowardKills" call VEMFr_fnc_config isEqualTo "yes") then
|
||||
{
|
||||
["fn_aiKilled", 1, format["A coward (%1 @ %2) killed a parachuting AI", _nk, mapGridPosition _k]] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
};
|
||||
@ -179,8 +179,8 @@ if (isPlayer _k) then
|
||||
};
|
||||
};
|
||||
|
||||
([["aiCleanup"],["removeLaunchers","aiDeathRemovalEffect","removeHeadGear"]] call VEMFr_fnc_config) params ["_ms0","_ms1","_ms2"];
|
||||
if (_ms0 isEqualTo 1) then
|
||||
([["aiCleanup"],["removeLaunchers","aiDeathRemovalEffect","removeHeadGear"]] call VEMFr_fnc_config) params [("_ms0"),("_ms1"),("_ms2")];
|
||||
if (_ms0 isEqualTo "yes") then
|
||||
{
|
||||
_sw = secondaryWeapon _t;
|
||||
if not(_sw isEqualTo "") then
|
||||
@ -195,12 +195,9 @@ if (isPlayer _k) then
|
||||
} forEach (magazines _t);
|
||||
};
|
||||
};
|
||||
if (_ms2 isEqualTo 1) then // If removeHeadGear setting is enabled
|
||||
{
|
||||
removeHeadGear _t;
|
||||
};
|
||||
if (_ms2 isEqualTo "yes") then { removeHeadGear _t };
|
||||
|
||||
if (_ms1 isEqualTo 1) then // If killEffect enabled
|
||||
if (_ms1 isEqualTo "yes") then // If killEffect enabled
|
||||
{
|
||||
playSound3D ["A3\Missions_F_Bootcamp\data\sounds\vr_shutdown.wss", _t, false, getPosASL _t, 2, 1, 60];
|
||||
for "_u" from 1 to 12 do
|
||||
@ -218,6 +215,13 @@ if (isPlayer _k) then
|
||||
removeAllWeapons _t;
|
||||
// Automatic cleanup yaaay
|
||||
deleteVehicle _t;
|
||||
} else
|
||||
{
|
||||
if (_mod isEqualTo "Exile") then
|
||||
{
|
||||
_v = ([[(_mod)],["aiMoney"]] call VEMFr_fnc_config) select 0;
|
||||
if (_v > 0) then { _t setVariable ["exilemoney",(2 + ((round random _v) - 2)),(true)] };
|
||||
};
|
||||
};
|
||||
|
||||
_t removeAllEventHandlers "MPKilled";
|
||||
|
@ -11,7 +11,7 @@
|
||||
nothing
|
||||
*/
|
||||
|
||||
if (("validateLoot" call VEMFr_fnc_config) isEqualTo 1) then
|
||||
if (("validateLoot" call VEMFr_fnc_config) isEqualTo "yes") then
|
||||
{ // _validateLoot is enabled, go ahead...
|
||||
if (("debugMode" call VEMFr_fnc_config) < 1) then { ["checkLoot", 0, "Can not validate classnames: no output allowed in RPT"] ExecVM ("log" call VEMFr_fnc_scriptPath) }
|
||||
else
|
||||
|
@ -15,9 +15,9 @@
|
||||
*/
|
||||
|
||||
params [
|
||||
["_obj", objNull, [objNull]],
|
||||
["_locName", "", [""]],
|
||||
["_locPos", [], [[]]]
|
||||
[("_obj"),(objNull),([objNull])],
|
||||
[("_locName"),(""),([""])],
|
||||
[("_locPos"),([]),([[]])]
|
||||
];
|
||||
|
||||
_obj setVariable ["isVEMFrCrate", 1, true];
|
||||
@ -27,36 +27,43 @@ clearMagazineCargoGlobal _obj;
|
||||
clearWeaponCargoGlobal _obj;
|
||||
|
||||
([
|
||||
["missionSettings","DynamicLocationInvasion","crateSettings"],
|
||||
["rifleSlotsMax","rifleSlotsMin","pistolSlotsMax","pistolSlotsMin","magSlotsMax","magSlotsMin","attSlotsMax","attSlotsMin","itemSlotsMax","itemSlotsMin",
|
||||
"vestSlotsMax","vestSlotsMin","headGearSlotsMax","headGearSlotsMin","bagSlotsMax","bagSlotsMin"]
|
||||
] call VEMFr_fnc_config) params ["_cs0","_cs1","_cs2","_cs3","_cs4","_cs5","_cs6","_cs7","_cs8","_cs9","_cs10","_cs11","_cs12","_cs13","_cs14","_cs15"];
|
||||
[("missionSettings"),("DynamicLocationInvasion"),("crateSettings")],
|
||||
[("rifleSlotsMax"),("rifleSlotsMin"),("pistolSlotsMax"),("pistolSlotsMin"),("magSlotsMax"),("magSlotsMin"),("attSlotsMax"),("attSlotsMin"),("itemSlotsMax"),("itemSlotsMin"),
|
||||
("vestSlotsMax"),("vestSlotsMin"),("headGearSlotsMax"),("headGearSlotsMin"),("bagSlotsMax"),("bagSlotsMin")]
|
||||
] call VEMFr_fnc_config) params [("_cs0"),("_cs1"),("_cs2"),("_cs3"),("_cs4"),("_cs5"),("_cs6"),("_cs7"),("_cs8"),("_cs9"),("_cs10"),("_cs11"),("_cs12"),("_cs13"),("_cs14"),("_cs15")];
|
||||
|
||||
([
|
||||
["missionSettings","DynamicLocationInvasion","crateLootVanilla"],
|
||||
["attachments","backpacks","headGear",format["items%1", call VEMFr_fnc_whichMod],"magazines","pistols","rifles","vests"]
|
||||
] call VEMFr_fnc_config) params ["_vl0","_vl1","_vl2","_vl3","_vl4","_vl5","_vl6","_vl7"];
|
||||
[("missionSettings"),("DynamicLocationInvasion"),("crateLootVanilla")],
|
||||
[("attachments"),("backpacks"),("headGear"),(format["items%1", call VEMFr_fnc_whichMod]),("magazines"),("pistols"),("rifles"),("vests")]
|
||||
] call VEMFr_fnc_config) params [("_vl0"),("_vl1"),("_vl2"),("_vl3"),("_vl4"),("_vl5"),("_vl6"),("_vl7")];
|
||||
|
||||
if ((call VEMFr_fnc_whichMod) isEqualTo "Exile") then
|
||||
{
|
||||
private "_c";
|
||||
_c = ([["Exile"],["crateMoney"]] call VEMFr_fnc_config) select 0;
|
||||
if (_c > 0) then { _obj setVariable [("ExileMoney"),((_c / 2) + (round random (_c / 2))),(true)] };
|
||||
};
|
||||
|
||||
if (("Apex" call VEMFr_fnc_modAppID) in (getDLCs 1)) then
|
||||
{
|
||||
private ["_el0","_el1","_el2","_el3","_el4","_el5","_el6","_el7"];
|
||||
private [("_el0"),("_el1"),("_el2"),("_el3"),("_el4"),("_el5"),("_el6"),("_el7")];
|
||||
([
|
||||
["missionSettings","DynamicLocationInvasion","crateLootApex"],
|
||||
["attachments","backpacks","headGear","headGearSpecial","magazines","pistols","rifles","vests"]
|
||||
] call VEMFr_fnc_config) params ["_el0","_el1","_el2","_el3","_el4","_el5","_el6","_el7"];
|
||||
[("missionSettings"),("DynamicLocationInvasion"),("crateLootApex")],
|
||||
[("attachments"),("backpacks"),("headGear"),("headGearSpecial"),("magazines"),("pistols"),("rifles"),("vests")]
|
||||
] call VEMFr_fnc_config) params [("_el0"),("_el1"),("_el2"),("_el3"),("_el4"),("_el5"),("_el6"),("_el7")];
|
||||
_vl0 append _el0;
|
||||
_vl1 append _el1;
|
||||
_vl2 append _el2;
|
||||
if ((([["missionSettings","DynamicLocationInvasion","crateSettings"],["allowThermalHelmets"]] call VEMFr_fnc_config) select 0) isEqualTo 1) then { _vl2 append _el3 };
|
||||
if ((([[("missionSettings"),("DynamicLocationInvasion"),("crateSettings")],["allowThermalHelmets"]] call VEMFr_fnc_config) select 0) isEqualTo "yes") then { _vl2 append _el3 };
|
||||
_vl4 append _el4;
|
||||
_vl5 append _el5;
|
||||
_vl6 append _el6;
|
||||
_vl7 append _el7;
|
||||
};
|
||||
|
||||
_bad = ([["blacklists","loot"],["classes"]] call VEMFr_fnc_config) select 0;
|
||||
_bad = ([[("blacklists"),("loot")],["classes"]] call VEMFr_fnc_config) select 0;
|
||||
|
||||
if ((round random 2) isEqualTo 1) then
|
||||
if ((round random 1) isEqualTo 1) then
|
||||
{
|
||||
// Rifles
|
||||
for "_l" from 0 to (_cs0 - _cs1 + floor random _cs1) do
|
||||
@ -66,7 +73,7 @@ if ((round random 2) isEqualTo 1) then
|
||||
};
|
||||
};
|
||||
|
||||
if ((round random 2) isEqualTo 1) then
|
||||
if ((round random 3) isEqualTo 1) then
|
||||
{
|
||||
// Pistols
|
||||
for "_l" from 0 to (_cs2 - _cs3 + floor random _cs3) do
|
||||
|
@ -18,9 +18,9 @@ if (("debugMode" call VEMFr_fnc_config) > 0) then
|
||||
{
|
||||
scopeName "_top";
|
||||
params [
|
||||
["_p", "", [""]],
|
||||
["_t", 3, [0]],
|
||||
["_l", "", [""]]
|
||||
[("_p"),(""),([""])],
|
||||
[("_t"),(3),([0])],
|
||||
[("_l"),(""),([""])]
|
||||
];
|
||||
|
||||
_do = { diag_log text format["IT07: [VEMFr] %1 -- %2: %3", _p, _this, _l] };
|
||||
|
@ -15,14 +15,14 @@
|
||||
*/
|
||||
|
||||
params [
|
||||
["_mt", -1, [-1]],
|
||||
["_title", "", [""]],
|
||||
["_line", "", [""]],
|
||||
["_to", [], [[]]]
|
||||
[("_mt"),(-1),([-1])],
|
||||
[("_title"),(""),([""])],
|
||||
[("_line"),(""),([""])],
|
||||
[("_to"),([]),([[]])]
|
||||
];
|
||||
|
||||
if ((count _to) isEqualTo 0) then { _to = allPlayers };
|
||||
{
|
||||
VEMFrMsgToClient = [[_mt, _title, _line], ""];
|
||||
VEMFrMsgToClient = [[(_mt),(_title),(_line)],("")];
|
||||
(owner _x) publicVariableClient "VEMFrMsgToClient";
|
||||
} forEach _to;
|
||||
|
@ -6,12 +6,12 @@
|
||||
*/
|
||||
|
||||
(_this select 0) params [
|
||||
["_t", objNull, [objNull]],
|
||||
["_nt", "", [""]]
|
||||
[("_t"),(objNull),([objNull])],
|
||||
[("_nt"),(""),([""])]
|
||||
];
|
||||
(_this select 1) params [
|
||||
["_k", objNull, [objNull]],
|
||||
["_nk", "", [""]]
|
||||
[("_k"),(objNull),([objNull])],
|
||||
[("_nk"),(""),([""])]
|
||||
];
|
||||
|
||||
|
||||
@ -21,4 +21,4 @@ else { _crWpn = typeOf (vehicle _k); _cfg = "CfgVehicles" };
|
||||
_dist = _t distance _k;
|
||||
_dspName = getText(configFile >> _cfg >> _crWpn >> "displayName");
|
||||
_dspName = _dspName select [0, _dspName find " "];
|
||||
[format["%1 killed %2 with %3 from %4m", _nk, if (("sayKilledName" call VEMFr_fnc_config) > 0) then {_nt + " (AI)"} else {"an AI"}, _dspName, round _dist]] ExecVM ("systemChatToClient" call VEMFr_fnc_scriptPath);
|
||||
[format["%1 killed %2 with %3 from %4m", _nk, if (("sayKilledName" call VEMFr_fnc_config) isEqualTo "yes") then {_nt + " (AI)"} else {"an AI"}, _dspName, round _dist]] ExecVM ("systemChatToClient" call VEMFr_fnc_scriptPath);
|
||||
|
@ -21,7 +21,7 @@ if not(isNull _grp) then
|
||||
if not(isNil "_force") then { if (_force isEqualType true) then { if _force then { _hcNbld = -1 } } };
|
||||
|
||||
private "_to";
|
||||
if (_hcNbld isEqualTo 1) then
|
||||
if (_hcNbld isEqualTo "yes") then
|
||||
{
|
||||
_arr = [];
|
||||
{
|
||||
|
@ -11,12 +11,10 @@
|
||||
nothing
|
||||
*/
|
||||
|
||||
if ((([["aiStatic"],["enabled"]] call VEMFr_fnc_config) select 0) isEqualTo 1) then
|
||||
([["aiStatic"],[("enabled"),("positions"),("amount")]] call VEMFr_fnc_config) params [("_s0"),("_s1"),("_s2")];
|
||||
if (_s0 isEqualTo "yes") then
|
||||
{
|
||||
["spawnStaticAI", 2, "launching..."] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
([["aiStatic"],["positions","amount"]] call VEMFr_fnc_config) params ["_s0","_s1"];
|
||||
["spawnStaticAI", 2, "spawning AI on positions..."] ExecVM ("log" call VEMFr_fnc_scriptPath);
|
||||
{
|
||||
[_x, 2, _s1 select _foreachindex, ([[call VEMFr_fnc_whichMod],["aiMode"]] call VEMFr_fnc_config) select 0, "Static"] spawn VEMFr_fnc_spawnVEMFrAI;
|
||||
} forEach _s0;
|
||||
_uc = _s2 select _forEachIndex;
|
||||
{ [(_x),(2),((_uc / 2) + (round random (_uc / 2))),(([[call VEMFr_fnc_whichMod],["aiMode"]] call VEMFr_fnc_config) select 0),("Static")] spawn VEMFr_fnc_spawnVEMFrAI } forEach _s1;
|
||||
};
|
||||
|
@ -10,12 +10,12 @@
|
||||
*/
|
||||
|
||||
params [
|
||||
["_line", "", [""]],
|
||||
["_to", [], [[]]]
|
||||
[("_line"),(""),([""])],
|
||||
[("_to"),([]),([[]])]
|
||||
];
|
||||
|
||||
if (_to isEqualTo []) then { _to = allPlayers };
|
||||
{
|
||||
VEMFrMsgToClient = [_line, "sys"];
|
||||
VEMFrMsgToClient = [(_line),("sys")];
|
||||
(owner _x) publicVariableClient "VEMFrMsgToClient";
|
||||
} forEach _to;
|
||||
|
Loading…
Reference in New Issue
Block a user