Compare commits
88 Commits
master
...
v0.96.7-hu
Author | SHA1 | Date |
---|---|---|
Wyqer | e0d78e7a93 | |
Wyqer | 34594ddf9e | |
Wyqer | a9b8319e68 | |
Wyqer | 555b2802de | |
Christian | 7a2ab40b52 | |
Wyqer | e15001cc7a | |
Christian | bc5d9008c8 | |
Filip Maciejewski | 5a4b31452d | |
Filip Maciejewski | eda1efa426 | |
FatRefrigerator | 6fe4f99935 | |
Wyqer | 3affa39a46 | |
Wyqer | 2d3c7d8691 | |
Wyqer | d3e6ef7841 | |
Wyqer | 6e7405e4a9 | |
Wyqer | 150513683a | |
Wyqer | ff2b52b778 | |
Wyqer | 153b41d2e0 | |
Wyqer | 3d6ec00155 | |
Wyqer | f19f9f3c99 | |
Wyqer | 0261bd1060 | |
Wyqer | 2d8c30deff | |
Wyqer | c91255da11 | |
Wyqer | d9320b96e2 | |
Wyqer | 4f69f32e9b | |
Wyqer | 7f473430f7 | |
Christian | 87db8f8367 | |
Wyqer | 67d2652369 | |
Wyqer | 40fd1af4ef | |
Wyqer | 1a2c24fc45 | |
Wyqer | c4cb9a4f1f | |
Wyqer | 486732e490 | |
Christian | d719097beb | |
Wyqer | 42a47a9243 | |
Wyqer | d3793232cf | |
Wyqer | 8be9a575e9 | |
Christian | 9b18557353 | |
Christian | 2815e8a2f4 | |
Christian | 6e593c8e9d | |
Eogos | 2a7954750c | |
Eogos | f3fead3d42 | |
Eogos | 0ce37485f1 | |
Eogos | 527d216a0a | |
Filip Maciejewski | 3162afb14d | |
Eogos | a225b8943c | |
Eogos | 64fb4ee1cd | |
Filip Maciejewski | c78cf4b6ef | |
Filip Maciejewski | d8a0fa189b | |
Filip Maciejewski | 0979da1e4d | |
Filip Maciejewski | d8fee01026 | |
Filip Maciejewski | 764d24c1f9 | |
Filip Maciejewski | 40cb0084cc | |
Filip Maciejewski | 029ca722d9 | |
Eogos | 75fafef376 | |
Ozan Eğitmen | fe3a82792c | |
Eogos | 4c1e48832f | |
Eogos | 6c628e4db7 | |
Eogos | 4531184404 | |
Filip Maciejewski | 063b6c3db0 | |
Filip Maciejewski | e1a9acffae | |
Filip Maciejewski | 5cc2846c20 | |
Filip Maciejewski | e72a4d127b | |
Wyqer | c786da322c | |
Wyqer | c7d2a871b1 | |
Filip Maciejewski | 23282845b0 | |
Filip Maciejewski | 5fdc36877f | |
Filip Maciejewski | de359ef575 | |
Filip Maciejewski | 05a4d38e33 | |
Filip Maciejewski | 3b13e0a6a5 | |
Filip Maciejewski | 48a6dae8a7 | |
Filip Maciejewski | 197f1b64d5 | |
Filip Maciejewski | 62538b1d0f | |
Filip Maciejewski | a2efefea40 | |
Filip Maciejewski | 5a7d47e23a | |
Filip Maciejewski | 17ae30bfc4 | |
Filip Maciejewski | d921748c8d | |
Filip Maciejewski | 979105a05e | |
Filip Maciejewski | dcc80d2fbf | |
Filip Maciejewski | f971b74829 | |
Filip Maciejewski | 4f36159e9f | |
Filip Maciejewski | 754732b1c7 | |
Filip Maciejewski | 3aa06587ad | |
Filip Maciejewski | f2bd5ae71a | |
Filip Maciejewski | 6a0db6c5eb | |
Filip Maciejewski | be4a8adeac | |
Filip Maciejewski | ed045c9344 | |
Filip Maciejewski | a2bdcee716 | |
Filip Maciejewski | b76f6e0ef7 | |
Filip Maciejewski | ee00bcd730 |
|
@ -0,0 +1,65 @@
|
|||
{
|
||||
"sqf.enableCBA": true,
|
||||
"sqf.enableACE3": true,
|
||||
"files.associations": {
|
||||
"*.hpp": "sqf"
|
||||
},
|
||||
"sqflint.ignoredVariables": [
|
||||
"_input0",
|
||||
"_thisArgs",
|
||||
"_thisId",
|
||||
"_thisType"
|
||||
],
|
||||
"psi-header.lang-config": [
|
||||
{
|
||||
"license": "Custom",
|
||||
"language": "sqf",
|
||||
"rootDirFileName": "description.ext",
|
||||
"begin": "/*",
|
||||
"prefix": " ",
|
||||
"end": "*/",
|
||||
"forceToTop": true
|
||||
}
|
||||
],
|
||||
"psi-header.changes-tracking": {
|
||||
"isActive": true,
|
||||
"include": ["sqf"],
|
||||
"modDate": "Last Update:",
|
||||
"modDateFormat": "YYYY-MM-DD",
|
||||
"autoHeader": "manualSave"
|
||||
},
|
||||
"psi-header.license-text": [
|
||||
"MIT License - http://www.opensource.org/licenses/MIT"
|
||||
],
|
||||
"psi-header.templates": [
|
||||
{
|
||||
"language": "sqf",
|
||||
"template": [
|
||||
"File: <<filename>>",
|
||||
"Author: KP Liberation Dev Team - https://github.com/KillahPotatoes",
|
||||
"Date: <<filecreated('YYYY-MM-DD')>>",
|
||||
"Last Update:",
|
||||
"License: MIT License - http://www.opensource.org/licenses/MIT",
|
||||
"",
|
||||
"Description:",
|
||||
" No description added yet.",
|
||||
"",
|
||||
"Parameter(s):",
|
||||
" _localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]",
|
||||
"",
|
||||
"Returns:",
|
||||
" Function reached the end [BOOL]"
|
||||
]
|
||||
}
|
||||
],
|
||||
"todo-tree.highlights.defaultHighlight": {
|
||||
"type": "tag",
|
||||
"foreground": "yellow",
|
||||
"background": "red",
|
||||
"opacity": 50,
|
||||
"iconColour": "green"
|
||||
},
|
||||
"todo-tree.general.statusBar": "tags",
|
||||
"todo-tree.tree.showCountsInTree": true,
|
||||
"todo-tree.tree.flat": true
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
class KPLIB
|
||||
{
|
||||
class functions
|
||||
{
|
||||
file = "functions";
|
||||
class checkClass {};
|
||||
class cleanOpforVehicle {};
|
||||
class forceBluforCrew {};
|
||||
class getAdaptiveVehicle {};
|
||||
class getCommander {};
|
||||
class getFobName {};
|
||||
class getForceRatio {};
|
||||
class getGroupType {};
|
||||
class getLoadout {};
|
||||
class getLocationName {};
|
||||
class getMobileRespawns {};
|
||||
class getNearbyPlayers {};
|
||||
class getOpforFactor {};
|
||||
class getOpforSpawnPoint {};
|
||||
class getPlayerCount {};
|
||||
class getSquadComp {};
|
||||
class hasPermission {};
|
||||
};
|
||||
};
|
|
@ -108,7 +108,7 @@ waitUntil { !isNil "GRLIB_nametag_units" };
|
|||
if ( _nextunit getVariable [ "FAR_isUnconscious", 0 ] == 1 ) then {
|
||||
_drawicon = wounded_icon;
|
||||
} else {
|
||||
if ( _nextunit == [] call F_getCommander ) then {
|
||||
if ( _nextunit == [] call KPLIB_fnc_getCommander ) then {
|
||||
_drawicon = commander_icon;
|
||||
} else {
|
||||
if ( _nextunit == (leader group _nextunit) && (count (units group _nextunit) > 1 ) ) then {
|
||||
|
@ -136,4 +136,4 @@ waitUntil { !isNil "GRLIB_nametag_units" };
|
|||
} foreach GRLIB_nametag_units;
|
||||
};
|
||||
|
||||
}] call BIS_fnc_addStackedEventHandler;
|
||||
}] call BIS_fnc_addStackedEventHandler;
|
||||
|
|
|
@ -4,7 +4,7 @@ respawnButton = 1;
|
|||
disabledAI = true;
|
||||
|
||||
enableDebugConsole = 1;
|
||||
allowFunctionsLog = 0;
|
||||
allowFunctionsLog = 1;
|
||||
unsafeCVL = 1;
|
||||
|
||||
briefingName = $STR_MISSION_TITLE;
|
||||
|
@ -32,13 +32,17 @@ minPlayerDistance = 1000;
|
|||
#include "ui\liberation_notifications.hpp"
|
||||
#include "ui\mission_params.hpp"
|
||||
|
||||
class CfgFunctions {
|
||||
#include "CfgFunctions.hpp"
|
||||
};
|
||||
|
||||
class CfgDebriefing
|
||||
{
|
||||
class End1
|
||||
{
|
||||
title = $STR_SORRY;
|
||||
subtitle = "";
|
||||
description = $STR_COMMANDER_NOT_AUTHORIZED;
|
||||
pictureBackground = "";
|
||||
};
|
||||
class End1
|
||||
{
|
||||
title = $STR_SORRY;
|
||||
subtitle = "";
|
||||
description = $STR_COMMANDER_NOT_AUTHORIZED;
|
||||
pictureBackground = "";
|
||||
};
|
||||
};
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
/*
|
||||
File: fn_checkClass.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Checks if given classname is available in currently loaded modset.
|
||||
|
||||
Parameter(s):
|
||||
_classname - Classname of class to check [STRING, defaults to ""]
|
||||
|
||||
Returns:
|
||||
Classname in config [BOOL]
|
||||
*/
|
||||
|
||||
params [
|
||||
["_classname", "", [""]]
|
||||
];
|
||||
|
||||
if (isClass (configFile >> "CfgVehicles" >> _classname)) then {
|
||||
true
|
||||
} else {
|
||||
if (isServer) then {diag_log format ["[KP LIBERATION] [PRESETS] %1 not found in CfgVehicles", _classname];};
|
||||
false
|
||||
};
|
|
@ -0,0 +1,28 @@
|
|||
/*
|
||||
File: fn_cleanOpforVehicle.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Deletes given vehicle, if not an opfor vehicle captured by players.
|
||||
|
||||
Parameter(s):
|
||||
_veh - Vehicle to delete if not captured [OBJECT, defaults to objNull]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
|
||||
params [
|
||||
["_veh", objNull, [objNull]]
|
||||
];
|
||||
|
||||
if (isNull _veh) exitWith {["Null object given"] call BIS_fnc_error; false};
|
||||
|
||||
if (_veh getVariable ["GRLIB_captured", false]) then {
|
||||
deleteVehicle _veh;
|
||||
};
|
||||
|
||||
true
|
|
@ -0,0 +1,47 @@
|
|||
/*
|
||||
File: fn_forceBluforCrew.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Creates vehicle crew from vehicle config.
|
||||
If the crew isn't the same side as the players, it'll create a player side crew.
|
||||
|
||||
Parameter(s):
|
||||
_veh - Vehicle to add the blufor crew to [OBJECT, defaults to objNull]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
|
||||
params [
|
||||
["_veh", objNull, [objNull]]
|
||||
];
|
||||
|
||||
// Create regular config crew
|
||||
private _grp = createVehicleCrew _veh;
|
||||
|
||||
// If the config crew isn't the correct side, replace it with the crew classnames from the preset
|
||||
if ((side _grp) != GRLIB_side_friendly) then {
|
||||
{deleteVehicle _x} forEach (units _grp);
|
||||
|
||||
_grp = createGroup [GRLIB_side_friendly, true];
|
||||
while {count units _grp < 3} do {
|
||||
[crewman_classname, getPos _veh, _grp] call F_createManagedUnit;
|
||||
};
|
||||
((units _grp) select 0) moveInDriver _veh;
|
||||
((units _grp) select 1) moveInGunner _veh;
|
||||
((units _grp) select 2) moveInCommander _veh;
|
||||
|
||||
// Delete crew which isn't in the vehicle due to e.g. no commander seat
|
||||
{
|
||||
if (isNull objectParent _x) then {deleteVehicle _x};
|
||||
} forEach (units _grp);
|
||||
};
|
||||
|
||||
// Set the crew to safe behaviour
|
||||
_grp setBehaviour "SAFE";
|
||||
|
||||
true
|
|
@ -0,0 +1,22 @@
|
|||
/*
|
||||
File: fn_getAdaptiveVehicle.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Provides a vehicle classname depending on the combat readiness.
|
||||
|
||||
Parameter(s):
|
||||
NONE
|
||||
|
||||
Returns:
|
||||
Vehicle classname [STRING]
|
||||
*/
|
||||
|
||||
if (combat_readiness < 40) then {
|
||||
selectRandom opfor_vehicles_low_intensity
|
||||
} else {
|
||||
selectRandom opfor_vehicles
|
||||
};
|
|
@ -0,0 +1,18 @@
|
|||
/*
|
||||
File: fn_getCommander.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Returns the actual commander object.
|
||||
|
||||
Parameter(s):
|
||||
NONE
|
||||
|
||||
Returns:
|
||||
Commander [OBJECT]
|
||||
*/
|
||||
|
||||
missionNamespace getVariable ["commandant", objNull]
|
|
@ -0,0 +1,36 @@
|
|||
/*
|
||||
File: fn_getFobName.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
params [ "_fob" ];
|
||||
private [ "_fobindex", "_currentidx", "_fobname" ];
|
||||
|
||||
_fobname = "";
|
||||
_fobindex = -1;
|
||||
_currentidx = 0;
|
||||
{
|
||||
if ( _x distance _fob < 100 ) then {
|
||||
_fobindex = _currentidx;
|
||||
};
|
||||
_currentidx = _currentidx + 1;
|
||||
} foreach GRLIB_all_fobs;
|
||||
|
||||
_fobname = "";
|
||||
if ( _fobindex != -1 ) then {
|
||||
_fobname = military_alphabet select _fobindex;
|
||||
};
|
||||
|
||||
_fobname
|
|
@ -0,0 +1,40 @@
|
|||
/*
|
||||
File: fn_getForceRatio.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
params [ "_sector" ];
|
||||
private [ "_actual_capture_size", "_red_forces", "_blue_forces", "_ratio" ];
|
||||
|
||||
_actual_capture_size = GRLIB_capture_size;
|
||||
if ( _sector in sectors_bigtown ) then {
|
||||
_actual_capture_size = GRLIB_capture_size * 1.4;
|
||||
};
|
||||
|
||||
_red_forces = [ (markerpos _sector), _actual_capture_size, GRLIB_side_enemy ] call F_getUnitsCount;
|
||||
_blue_forces = [ (markerpos _sector), _actual_capture_size, GRLIB_side_friendly ] call F_getUnitsCount;
|
||||
_ratio = -1;
|
||||
|
||||
if (_red_forces > 0) then {
|
||||
_ratio = _blue_forces / ( _red_forces + _blue_forces );
|
||||
} else {
|
||||
if ( _sector in blufor_sectors || _blue_forces != 0 ) then {
|
||||
_ratio = 1;
|
||||
} else {
|
||||
_ratio = 0;
|
||||
};
|
||||
};
|
||||
|
||||
_ratio
|
|
@ -0,0 +1,79 @@
|
|||
/*
|
||||
File: fn_getGroupType.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
params [ "_grp" ];
|
||||
private [ "_grouptype", "_vehicletype" ];
|
||||
|
||||
_grouptype = 'infantry';
|
||||
_vehicletype = '';
|
||||
{
|
||||
if ( vehicle _x != _x && _vehicletype == '' ) then {
|
||||
if ( ((gunner vehicle _x) == _x) || ((driver vehicle _x) == _x) || ((commander vehicle _x) == _x) ) then {
|
||||
_vehicletype = typeof vehicle _x;
|
||||
};
|
||||
};
|
||||
} foreach units _grp;
|
||||
|
||||
if ((_grouptype == 'infantry') && (_vehicletype != '')) then {
|
||||
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'heavy';
|
||||
};
|
||||
} foreach heavy_vehicles;
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'air';
|
||||
};
|
||||
} foreach air_vehicles;
|
||||
};
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'light';
|
||||
};
|
||||
} foreach light_vehicles;
|
||||
};
|
||||
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'support';
|
||||
};
|
||||
} foreach support_vehicles;
|
||||
};
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'static';
|
||||
};
|
||||
} foreach static_vehicles;
|
||||
};
|
||||
|
||||
// Check if vehicle config says it's an UAV, if it is always set its _grouptype to 'uav'
|
||||
if ( (_vehicletype call F_isClassUAV) ) then {
|
||||
_grouptype = 'uav';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
_grouptype
|
|
@ -0,0 +1,297 @@
|
|||
/*
|
||||
File: fn_getLoadout.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
/*
|
||||
|
||||
AUTHOR: aeroson
|
||||
NAME: get_loadout.sqf
|
||||
VERSION: 3.4
|
||||
|
||||
DOWNLOAD & PARTICIPATE:
|
||||
https://github.com/aeroson/a3-loadout
|
||||
http://forums.bistudio.com/showthread.php?148577-GET-SET-Loadout-(saves-and-loads-pretty-much-everything)
|
||||
|
||||
DESCRIPTION:
|
||||
I guarantee backwards compatibility.
|
||||
These scripts allows you set/get (load/save)all of the unit's gear, including:
|
||||
uniform, vest, backpack, contents of it, all quiped items, all three weapons with their attachments, currently loaded magazines and number of ammo in magazines.
|
||||
All this while preserving order of items.
|
||||
Useful for saving/loading loadouts.
|
||||
Ideal for revive scripts where you have to set exactly the same loadout to newly created unit.
|
||||
Uses workaround with placeholders to add vest/backpack items, so items stay where you put them.
|
||||
|
||||
PARAMETER(S):
|
||||
0 : target unit
|
||||
1 : (optional) array of options, default [] :
|
||||
"ammo" will save ammo count of partially emptied magazines
|
||||
"repetitive" intended for repetitive use, will not use selectWeapon, means no visible effect on solder, but will not save magazines of assigned items such as laser designator batteries
|
||||
|
||||
RETURNS:
|
||||
Array : array of strings/arrays containing target unit's loadout, to be used by fnc_set_loadout.sqf
|
||||
|
||||
addAction support:
|
||||
Saves player's loadout into global var loadout
|
||||
|
||||
*/
|
||||
|
||||
private ["_target","_options","_saveMagsAmmo","_isRepetitive","_isOnFoot","_currentWeapon","_currentMode","_isFlashlightOn","_isIRLaserOn","_magazinesAmmo","_loadedMagazines","_saveWeaponMagazines","_getMagsAmmo","_backPackItems","_assignedItems","_data"];
|
||||
|
||||
_options = [];
|
||||
|
||||
// addAction support
|
||||
if(count _this < 4) then {
|
||||
#define PARAM_START private ["_PARAM_INDEX"]; _PARAM_INDEX=0;
|
||||
#define PARAM_REQ(A) if (count _this <= _PARAM_INDEX) exitWith { systemChat format["required param '%1' not supplied in file:'%2' at line:%3", #A ,__FILE__,__LINE__]; }; A = _this select _PARAM_INDEX; _PARAM_INDEX=_PARAM_INDEX+1;
|
||||
#define PARAM(A,B) A = B; if (count _this > _PARAM_INDEX) then { A = _this select _PARAM_INDEX; }; _PARAM_INDEX=_PARAM_INDEX+1;
|
||||
PARAM_START
|
||||
PARAM_REQ(_target)
|
||||
PARAM(_options,[])
|
||||
} else {
|
||||
_target = player;
|
||||
};
|
||||
|
||||
_saveMagsAmmo = "ammo" in _options;
|
||||
_isRepetitive = "repetitive" in _options;
|
||||
_isOnFoot = vehicle _target == _target;
|
||||
|
||||
_currentWeapon = "";
|
||||
_currentMode = "";
|
||||
_isFlashlightOn = false;
|
||||
_isIRLaserOn = false;
|
||||
|
||||
_magazinesAmmo = magazinesAmmoFull _target;
|
||||
|
||||
// save weapon mode and muzzle
|
||||
if(_isOnFoot) then {
|
||||
_currentWeapon = currentMuzzle _target;
|
||||
_currentMode = currentWeaponMode _target;
|
||||
_isFlashlightOn = _target isFlashlightOn _currentWeapon;
|
||||
_isIRLaserOn = _target isIRLaserOn _currentWeapon;
|
||||
} else {
|
||||
_currentWeapon = currentWeapon _target;
|
||||
};
|
||||
|
||||
|
||||
_loadedMagazines=[];
|
||||
|
||||
// universal weapon saving
|
||||
_saveWeaponMagazines = {
|
||||
private ["_weapon","_magazines","_muzzles","_saveMagazine"];
|
||||
_weapon = _this select 0;
|
||||
_magazines = [];
|
||||
|
||||
_saveMagazine = { // find, save and eat mag for _weapon
|
||||
private ["_weapon","_magazine","_ammo"];
|
||||
_weapon = _this select 0;
|
||||
_magazine = "";
|
||||
_ammo = 0;
|
||||
{
|
||||
if((_x select 4)==_weapon) then {
|
||||
_magazine = _x select 0;
|
||||
_ammo = _x select 1;
|
||||
_x = -1;
|
||||
};
|
||||
} forEach _magazinesAmmo;
|
||||
_magazinesAmmo = _magazinesAmmo - [-1];
|
||||
if(_magazine!="") then {
|
||||
if(_saveMagsAmmo) then {
|
||||
_magazines set [count _magazines, [_magazine, _ammo]];
|
||||
} else {
|
||||
_magazines set [count _magazines, _magazine];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
if(_weapon != "") then {
|
||||
[_weapon] call _saveMagazine;
|
||||
_muzzles = configFile>>"CfgWeapons">>_weapon>>"muzzles";
|
||||
if(isArray(_muzzles)) then {
|
||||
{ // add one mag for each muzzle
|
||||
if (_x != "this") then {
|
||||
[_x] call _saveMagazine;
|
||||
};
|
||||
} forEach getArray(_muzzles);
|
||||
};
|
||||
};
|
||||
|
||||
_loadedMagazines set [count _loadedMagazines, _magazines];
|
||||
};
|
||||
|
||||
// save loaded mags for each weapon separetely, since some weapons can use same magazines
|
||||
[primaryWeapon _target] call _saveWeaponMagazines;
|
||||
[handgunWeapon _target] call _saveWeaponMagazines;
|
||||
[secondaryWeapon _target] call _saveWeaponMagazines;
|
||||
|
||||
_getMagsAmmo = { // default function with _saveMagsAmmo == false
|
||||
_this select 0;
|
||||
};
|
||||
if(_saveMagsAmmo) then {
|
||||
// check if input array contains magazine, if it does, find it add ammo count
|
||||
_getMagsAmmo = {
|
||||
private ["_items","_location","_item","_itemIndex"];
|
||||
_items = _this select 0;
|
||||
_location = _this select 1;
|
||||
{
|
||||
_item = _x;
|
||||
_itemIndex = _forEachIndex;
|
||||
{
|
||||
if((_x select 4)==_location && (_x select 0)==_item) then {
|
||||
_items set[_itemIndex, [_item, _x select 1]];
|
||||
_x = -1;
|
||||
};
|
||||
} forEach _magazinesAmmo;
|
||||
_magazinesAmmo = _magazinesAmmo - [-1];
|
||||
} forEach _items;
|
||||
_items;
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
// get backpack items
|
||||
_cargo = getbackpackcargo (unitbackpack _target);
|
||||
_backpacks = [];
|
||||
{
|
||||
for "_i" from 1 to ((_cargo select 1) select _foreachindex) do {
|
||||
_backpacks set [count _backpacks, _x];
|
||||
};
|
||||
} foreach (_cargo select 0);
|
||||
_backPackItems = (backpackitems _target) + _backpacks;
|
||||
|
||||
// get assigned items, headgear and goggles is not part of assignedItems
|
||||
_assignedItems = assignedItems _target;
|
||||
_headgear = headgear _target;
|
||||
_goggles = goggles _target;
|
||||
if((_headgear != "") && !(_headgear in _assignedItems)) then {
|
||||
_assignedItems set [count _assignedItems, _headgear];
|
||||
};
|
||||
if((_goggles != "") && !(_goggles in _assignedItems)) then {
|
||||
_assignedItems set [count _assignedItems, _goggles];
|
||||
};
|
||||
|
||||
|
||||
|
||||
/*
|
||||
// use this once magazinesAmmoFull is fixed and shows magazines of assignedItems
|
||||
|
||||
// get magazines of everything else except weapons, most likely assigned items
|
||||
// only ["Uniform","Vest","Backpack"] locations remain, weapon locations have already been eaten
|
||||
_magazines = [];
|
||||
{
|
||||
if(_x select 2) then {
|
||||
if(_saveMagsAmmo) then {
|
||||
_magazines set[count _magazines, [_x select 0, _x select 1]];
|
||||
} else {
|
||||
_magazines set[count _magazines, _x select 0];
|
||||
};
|
||||
_x = -1;
|
||||
};
|
||||
} forEach _magazinesAmmo;
|
||||
_magazinesAmmo = _magazinesAmmo - [-1];
|
||||
_loadedMagazines set [3, _magazines];
|
||||
*/
|
||||
|
||||
|
||||
// old method using selectWeapon, cycles and tries to selectWeapon all assigned items
|
||||
if(!_isRepetitive) then {
|
||||
private ["_weaponHasChanged"];
|
||||
_weaponHasChanged = false;
|
||||
|
||||
// get magazines of all assigned items
|
||||
_magazines = [];
|
||||
{
|
||||
_target selectWeapon _x;
|
||||
if(currentWeapon _target==_x) then {
|
||||
_weaponHasChanged = true;
|
||||
_magazine = currentMagazine _target;
|
||||
if(_magazine != "") then {
|
||||
if(_saveMagsAmmo) then {
|
||||
_magazines set[count _magazines, [_magazine, _target ammo _x]];
|
||||
} else {
|
||||
_magazines set[count _magazines, _magazine];
|
||||
};
|
||||
};
|
||||
};
|
||||
} forEach _assignedItems;
|
||||
_loadedMagazines set [3, _magazines];
|
||||
|
||||
// select back originaly selected weapon and mode, only if weapon has changed
|
||||
if(_weaponHasChanged) then {
|
||||
if(_isOnFoot) then {
|
||||
if(_currentWeapon != "" && _currentMode != "") then {
|
||||
_muzzles = 0;
|
||||
while{ (_currentWeapon != currentMuzzle _target || _currentMode != currentWeaponMode _target ) && _muzzles < 200 } do {
|
||||
_target action ["SWITCHWEAPON", _target, _target, _muzzles];
|
||||
_muzzles = _muzzles + 1;
|
||||
};
|
||||
if(_isFlashlightOn) then {
|
||||
_target action ["GunLightOn"];
|
||||
} else {
|
||||
_target action ["GunLightOff"];
|
||||
};
|
||||
if(_isIRLaserOn) then {
|
||||
_target action ["IRLaserOn"];
|
||||
} else {
|
||||
_target action ["IRLaserOff"];
|
||||
};
|
||||
};
|
||||
} else {
|
||||
_currentMode = "";
|
||||
};
|
||||
if(_currentMode == "") then {
|
||||
if(_currentWeapon=="") then {
|
||||
_target action ["SWITCHWEAPON", _target, _target, 0];
|
||||
} else {
|
||||
_target selectWeapon _currentWeapon;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
_data = [
|
||||
_assignedItems, //0 []
|
||||
|
||||
primaryWeapon _target, //1 ""
|
||||
primaryWeaponItems _target, //2 []
|
||||
|
||||
handgunWeapon _target, //3 ""
|
||||
handgunItems _target, //4 []
|
||||
|
||||
secondaryWeapon _target, //5 ""
|
||||
secondaryWeaponItems _target, //6 []
|
||||
|
||||
uniform _target, //7 ""
|
||||
[uniformItems _target, "Uniform"] call _getMagsAmmo, //8 ["magazine without ammo count",["magazine with ammo count",30], ....]
|
||||
|
||||
vest _target, //9 ""
|
||||
[vestItems _target, "Vest"] call _getMagsAmmo, //10
|
||||
|
||||
backpack _target, //11 ""
|
||||
[_backPackItems, "Backpack"] call _getMagsAmmo, //12
|
||||
|
||||
_loadedMagazines, //13 (optional) [[primary mags],[handgun mags],[secondary mags],[other mags]]
|
||||
_currentWeapon, //14 (optional) ""
|
||||
_currentMode //15 (optional) ""
|
||||
];
|
||||
|
||||
// addAction support
|
||||
if(count _this < 4) then {
|
||||
_data;
|
||||
} else {
|
||||
loadout = _data;
|
||||
//playSound3D ["A3\Sounds_F\sfx\ZoomOut.wav", _target];
|
||||
};
|
|
@ -0,0 +1,28 @@
|
|||
/*
|
||||
File: fn_getLocationName.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
params [ "_attacked_position" ];
|
||||
private [ "_attacked_string" ];
|
||||
|
||||
_attacked_string = [_attacked_position] call KPLIB_fnc_getFobName;
|
||||
if ( _attacked_string == "" ) then {
|
||||
_attacked_string = markerText ( [50, _attacked_position ] call F_getNearestSector );
|
||||
} else {
|
||||
_attacked_string = format [ "FOB %1", _attacked_string ];
|
||||
};
|
||||
|
||||
_attacked_string
|
|
@ -0,0 +1,27 @@
|
|||
/*
|
||||
File: fn_getMobileRespawns.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
private _respawn_trucks_unsorted = vehicles select {
|
||||
(typeof _x == Respawn_truck_typename || typeof _x == huron_typename ) &&
|
||||
_x distance2d startbase > 500 &&
|
||||
!surfaceIsWater (getpos _x) &&
|
||||
(isTouchingGround _x || {5 > ((getPos _x) select 2)}) &&
|
||||
alive _x &&
|
||||
speed _x < 5
|
||||
};
|
||||
|
||||
[_respawn_trucks_unsorted, [], {(getpos _x) select 0}, 'ASCEND'] call BIS_fnc_sortBy
|
|
@ -0,0 +1,20 @@
|
|||
/*
|
||||
File: fn_getNearbyPlayers.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
params [ "_searchposition", "_distance"];
|
||||
|
||||
allPlayers select {alive _x && _x distance _searchposition < _distance}
|
|
@ -0,0 +1,22 @@
|
|||
/*
|
||||
File: fn_getOpforFactor.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Returns the opfor factor to scale down enemy forces, if "adapt to player count" mission param is enabled.
|
||||
|
||||
Parameter(s):
|
||||
NONE
|
||||
|
||||
Returns:
|
||||
Opfor factor [NUMBER]
|
||||
*/
|
||||
|
||||
if !(GRLIB_adaptive_opfor) exitWith {1};
|
||||
|
||||
private _bluforcount = (0.2 * (GRLIB_side_friendly countSide allUnits)) + ([] call KPLIB_fnc_getPlayerCount);
|
||||
|
||||
(0.5 + (_bluforcount / 25.0)) min 1
|
|
@ -0,0 +1,108 @@
|
|||
/*
|
||||
File: fn_getOpforSpawnPoint.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Gets a random opfor spawn point marker name respecting following conditions:
|
||||
* Wasn't used already in the current session (server restart to server restart)
|
||||
* Distance to blufor FOBs and sectors is more than given min distance
|
||||
* Distance to blufor FOBs and sectors is less than given max distance
|
||||
* Distance to an opfor sector is less than 2000m (to avoid strange spawn in blufor territory)
|
||||
* If nearest is set to true, the valid spawn point which is nearest to any blufor sector/FOB is returned
|
||||
* If a position is given, the closest valid spawn point to that position is returned
|
||||
|
||||
Parameter(s):
|
||||
_min - Minimum distance to any blufor sector or FOB [NUMBER, defaults to 2000]
|
||||
_max - Maximum distance to any blufor sector or FOB [NUMBER, defaults to 20000]
|
||||
_nearest - Provide the nearest spawn point of valid points [BOOL, defaults to false]
|
||||
_pos - Position if the nearest spawn point to this should be selected [POSITION, defaults to [0, 0, 0]]
|
||||
|
||||
Returns:
|
||||
Opfor spawn point [STRING]
|
||||
*/
|
||||
|
||||
params [
|
||||
["_min", 2000, [0]],
|
||||
["_max", 20000, [0]],
|
||||
["_nearest", false, [false]],
|
||||
["_pos", [0, 0, 0], [[]], [2, 3]]
|
||||
];
|
||||
|
||||
private _possibleSpawns = [];
|
||||
|
||||
// Only check for opfor spawn points which aren't used already in the current session
|
||||
private _spawnsToCheck = sectors_opfor;
|
||||
if (!isNil "used_positions") then {
|
||||
_spawnsToCheck = sectors_opfor - used_positions;
|
||||
};
|
||||
|
||||
private ["_valid", "_current", "_distances"];
|
||||
{
|
||||
_valid = true;
|
||||
_current = _x;
|
||||
|
||||
// Shouldn't be too close to the current/last position of a secondary mission
|
||||
if (!isNil "secondary_objective_position" && _valid) then {
|
||||
if !(secondary_objective_position isEqualTo []) then {
|
||||
_valid = !(((markerPos _current) distance2d secondary_objective_position) < 500);
|
||||
};
|
||||
};
|
||||
|
||||
if (_valid) then {
|
||||
// Fetch distances to FOBs
|
||||
_distances = (GRLIB_all_fobs apply {(markerPos _current) distance2d _x}) select {_x < _max};
|
||||
|
||||
// Fetch distances to blufor sectors
|
||||
_distances append ((blufor_sectors apply {(markerPos _current) distance2d (markerPos _x)}) select {_x < _max});
|
||||
|
||||
// Invalid, if all sectors and FOBs are further away than given max distance
|
||||
if (_distances isEqualTo []) then {
|
||||
_valid = false;
|
||||
} else {
|
||||
// Invalid, if one sector or FOB is closer than min distance
|
||||
_distances sort true;
|
||||
if ((_distances select 0) < _min) then {
|
||||
_valid = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
// Make sure that there is an opfor sector in sensible range to spawn
|
||||
if (_valid) then {
|
||||
if ((sectors_allSectors - blufor_sectors) findIf {((markerPos _current) distance2D (markerPos _x)) < 2000} < 0) then {
|
||||
_valid = false;
|
||||
};
|
||||
};
|
||||
|
||||
// Make sure that there is no blufor unit inside min dist to spawn
|
||||
if (_valid) then {
|
||||
if (([markerpos _current, _min, GRLIB_side_friendly] call F_getUnitsCount) > 0) then {
|
||||
_valid = false;
|
||||
};
|
||||
};
|
||||
|
||||
// Add distance and marker name to possible spawn, if still valid
|
||||
if (_valid) then {
|
||||
_possibleSpawns pushBack [_distances select 0, _current];
|
||||
};
|
||||
} forEach _spawnsToCheck;
|
||||
|
||||
// Return empty string, if no possible spawn point was found
|
||||
if (_possibleSpawns isEqualTo []) exitWith {diag_log "[KP LIBERATION] [WARNING] No opfor spawn point found"; ""};
|
||||
|
||||
// Return nearest spawn point to a blufor sector/FOB, if selected via parameter
|
||||
if (_nearest) exitWith {
|
||||
_possibleSpawns sort true;
|
||||
(_possibeSpawns select 0) select 1
|
||||
};
|
||||
|
||||
// Return nearest spawn point to given position, if provided
|
||||
if !(_pos isEqualTo [0, 0, 0]) exitWith {
|
||||
([_possibleSpawns apply {_x select 1}, [_pos] , {_input0 distance (markerPos _x)} , "ASCEND"] call BIS_fnc_sortBy) select 0
|
||||
};
|
||||
|
||||
// Return random spawn point
|
||||
(selectRandom _possibleSpawns) select 1
|
|
@ -0,0 +1,18 @@
|
|||
/*
|
||||
File: fn_getPlayerCount.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Returns the number of connected players without counting headless clients.
|
||||
|
||||
Parameter(s):
|
||||
NONE
|
||||
|
||||
Returns:
|
||||
Amount of players [NUMBER]
|
||||
*/
|
||||
|
||||
count (allPlayers - entities "HeadlessClient_F")
|
|
@ -0,0 +1,30 @@
|
|||
/*
|
||||
File: fn_getSectorRange.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
No description added yet.
|
||||
|
||||
Parameter(s):
|
||||
_localVariable - Description [DATATYPE, defaults to DEFAULTVALUE]
|
||||
|
||||
Returns:
|
||||
Function reached the end [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
params ["_opforcount"];
|
||||
|
||||
private _corrected_sector_size = GRLIB_sector_size;
|
||||
|
||||
if (_opforcount >= (0.5 * GRLIB_sector_cap)) then {
|
||||
if (_opforcount <= GRLIB_sector_cap) then {
|
||||
_corrected_sector_size = GRLIB_sector_size - (GRLIB_sector_size * 0.5 * ((_opforcount / GRLIB_sector_cap) - 0.5));
|
||||
} else {
|
||||
_corrected_sector_size = GRLIB_sector_size * 0.75;
|
||||
};
|
||||
};
|
||||
|
||||
_corrected_sector_size
|
|
@ -0,0 +1,58 @@
|
|||
/*
|
||||
File: fn_getSquadComp.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Provides an infantry squad composition of classnames in accordance to the current weights to adapt to the players playstyle.
|
||||
|
||||
Parameter(s):
|
||||
_type - Type of infantry. Army or militia [STRING, defaults to "army"]
|
||||
|
||||
Returns:
|
||||
Array of infantry classnames [ARRAY]
|
||||
*/
|
||||
|
||||
params [
|
||||
["_type", "army", [""]]
|
||||
];
|
||||
|
||||
private _squadcomp = [];
|
||||
|
||||
if (_type == "army") then {
|
||||
private _selected = false;
|
||||
private _randomchance = 0;
|
||||
_squadcomp = opfor_squad_8_standard;
|
||||
|
||||
if (armor_weight > 40 && !_selected) then {
|
||||
_randomchance = (armor_weight - 35) * 1.4;
|
||||
if ((random 100) < _randomchance) then {
|
||||
_selected = true;
|
||||
_squadcomp = opfor_squad_8_tankkillers;
|
||||
};
|
||||
};
|
||||
|
||||
if (air_weight > 40 && !_selected) then {
|
||||
_randomchance = (air_weight - 35) * 1.4;
|
||||
if ((random 100) < _randomchance) then {
|
||||
_selected = true;
|
||||
_squadcomp = opfor_squad_8_airkillers;
|
||||
};
|
||||
};
|
||||
|
||||
if (infantry_weight > 40 && !_selected) then {
|
||||
_randomchance = (infantry_weight - 35) * 1.4;
|
||||
if ((random 100) < _randomchance) then {
|
||||
_selected = true;
|
||||
_squadcomp = opfor_squad_8_infkillers;
|
||||
};
|
||||
};
|
||||
} else {
|
||||
private _multiplier = 1;
|
||||
if (GRLIB_unitcap < 1) then {_multiplier = GRLIB_unitcap;};
|
||||
while {count _squadcomp < (10 * _multiplier)} do {_squadcomp pushback (selectRandom militia_squad)};
|
||||
};
|
||||
|
||||
_squadcomp
|
|
@ -0,0 +1,37 @@
|
|||
/*
|
||||
File: fn_hasPermission.sqf
|
||||
Author: KP Liberation Dev Team - https://github.com/KillahPotatoes
|
||||
Date: 2019-11-25
|
||||
Last Update: 2019-11-25
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Checks if local player has the given permission granted.
|
||||
|
||||
Parameter(s):
|
||||
_permission - Permission to check [NUMBER, defaults to -1]
|
||||
|
||||
Returns:
|
||||
Has permission granted [BOOL]
|
||||
*/
|
||||
|
||||
params [
|
||||
["_permission", -1, [0]]
|
||||
];
|
||||
|
||||
if (_permission isEqualTo -1) exitWith {["No permission number given"] call BIS_fnc_error; false};
|
||||
if (!GRLIB_permissions_param) exitWith {true};
|
||||
|
||||
if (isNil "GRLIB_last_permission_check_time") then {GRLIB_last_permission_check_time = -1000;};
|
||||
if (isNil "GRLIB_permissions_cache") then {GRLIB_permissions_cache = [];};
|
||||
|
||||
if (time > GRLIB_last_permission_check_time + 10) then {
|
||||
GRLIB_last_permission_check_time = time;
|
||||
GRLIB_permissions_cache = (GRLIB_permissions select {(_x select 0) isEqualTo (getPlayerUID player)}) select 2;
|
||||
};
|
||||
|
||||
if (count GRLIB_permissions_cache > _permission) then {
|
||||
GRLIB_permissions_cache select _permission
|
||||
} else {
|
||||
false
|
||||
};
|
|
@ -8,6 +8,7 @@ if (!isServer) then {waitUntil {!isNil "KP_serverParamsFetched"};};
|
|||
[] call compileFinal preprocessFileLineNumbers "scripts\shared\fetch_params.sqf";
|
||||
[] call compileFinal preprocessFileLineNumbers "kp_liberation_config.sqf";
|
||||
[] call compileFinal preprocessFileLineNumbers "presets\init_presets.sqf";
|
||||
KPLIB_objectInitsCache = createSimpleObject ["a3\weapons_f\empty.p3d", [-7580, -7580, 0], true];
|
||||
[] call compileFinal preprocessFileLineNumbers "kp_objectInits.sqf";
|
||||
|
||||
[] execVM "GREUH\scripts\GREUH_activate.sqf";
|
||||
|
|
|
@ -15,6 +15,13 @@ KP_liberation_medical_vehicles = [
|
|||
"CUP_B_LR_Ambulance_CZ_W",
|
||||
"CUP_B_LR_Ambulance_GB_D",
|
||||
"CUP_B_LR_Ambulance_GB_W",
|
||||
"CUP_B_FV432_GB_Ambulance",
|
||||
"CUP_B_S1203_Ambulance_CDF",
|
||||
"CUP_B_UH1Y_MEV_USMC",
|
||||
"CUP_B_UH60M_Unarmed_FFV_MEV_US",
|
||||
"CUP_B_BMP2_AMB_CZ",
|
||||
"CUP_B_BMP2_AMB_CZ_Des",
|
||||
"CUP_B_HMMWV_Ambulance_ACR",
|
||||
"gm_gc_army_ural375d_medic_win",
|
||||
"gm_gc_army_ural375d_medic",
|
||||
"gm_ge_army_u1300l_medic_win_rc",
|
||||
|
@ -166,6 +173,8 @@ KP_liberation_fuel_max = 45;
|
|||
Name of the savegame namespace inside of the [ServerProfileName].vars.Arma3Profile file. */
|
||||
GRLIB_save_key = "KP_LIBERATION_" + (toUpper worldName) + "_SAVEGAME";
|
||||
|
||||
KP_liberation_save_interval = 20; // Interval in seconds for automatic save.
|
||||
|
||||
GRLIB_side_friendly = WEST; // Friendly side.
|
||||
GRLIB_side_enemy = EAST; // Enemy side.
|
||||
GRLIB_side_resistance = RESISTANCE; // Resistance side.
|
||||
|
@ -230,6 +239,18 @@ KP_liberation_battlegroup_clearance = [
|
|||
"song_bin_tanh"
|
||||
];
|
||||
|
||||
/* Slot independent commander action access.
|
||||
The Steam UIDs entered in this array will allow corresponding players to access the commander actions (rights, production, etc.),
|
||||
even if they are not in the commander slot. */
|
||||
KP_liberation_commander_actions = [
|
||||
/*
|
||||
Example:
|
||||
"1324678",
|
||||
"5468711",
|
||||
"2156347"
|
||||
*/
|
||||
];
|
||||
|
||||
/* - Default arsenal blacklist method.
|
||||
Useless if you're using anything other than "kp_liberation_arsenal = 0;" above. A whitelisted arsenal is always more performance friendly then a blacklisted arsenal.
|
||||
REMEMBER: All static turret and UAV bags should be defined here, to stop players from exploiting free resources via the virtual arsenal. */
|
||||
|
@ -314,9 +335,6 @@ blacklisted_from_arsenal = [
|
|||
"O_UAV_06_medical_backpack_F",
|
||||
"O_UGV_02_Demining_backpack_F",
|
||||
"O_UGV_02_Science_backpack_F",
|
||||
"optic_Nightstalker",
|
||||
"optic_tws_mg",
|
||||
"optic_tws",
|
||||
"RHS_AGS30_Gun_Bag",
|
||||
"RHS_AGS30_Tripod_Bag",
|
||||
"RHS_DShkM_Gun_Bag",
|
||||
|
@ -499,6 +517,7 @@ box_transport_config = [
|
|||
["C_Van_02_service_F", -5, [0,0.5,0], [0,-1.75,0]],
|
||||
["C_Van_02_transport_F", -5, [0,-1.75,0]],
|
||||
["C_Van_02_vehicle_F", -5, [0,0.5,0], [0,-1.75,0]],
|
||||
["CUP_B_C130J_Cargo_USMC",-10,[0,0.6,-3.76],[0,-0.9,-3.76],[0,-2.5,-3.76],[0,-4.2,-3.76],[0,2.2,-3.76],[0,3.8,-3.76],[0,5.5,-3.76]],
|
||||
["CUP_B_CH47F_GB", -8, [0,-3.535,-1.9], [0,-1.819,-1.9], [0,0.98,-1.9], [0,3.037,-1.9]],
|
||||
["CUP_B_CH47F_USA", -8, [0,-3.535,-1.9], [0,-1.819,-1.9], [0,0.98,-1.9], [0,3.037,-1.9]],
|
||||
["CUP_B_CH53E_USMC", -8, [0,7.566,-3], [0,5.749,-3], [0,3.847,-3], [0,2,-3], [0,0.338,-3]],
|
||||
|
@ -571,7 +590,7 @@ box_transport_config = [
|
|||
["O_T_Truck_03_transport_ghex_F", -6.5, [0,-0.8,0.4], [0,-2.4,0.4], [0,-4.0,0.4]],
|
||||
["O_Truck_03_covered_F", -6.5, [0,-0.8,0.4], [0,-2.4,0.4], [0,-4.0,0.4]],
|
||||
["O_Truck_03_transport_F", -6.5, [0,-0.8,0.4], [0,-2.4,0.4], [0,-4.0,0.4]],
|
||||
["RHS_C130J", -9.5, [-0.8,4.5,1.9], [0.8,4.5,1.9], [-0.8,4.5,3.1], [0.8,4.5,3.1], [-0.8,3.0,1.9], [0.8,3.0,1.9], [-0.8,3.0,3.1], [0.8,3.0,3.1], [-0.8,2.0,1.9], [0.8,2.0,1.9], [-0.8,2.0,3.1], [0.8,2.0,3.1], [-0.8,1.0,1.9], [0.8,1.0,1.9], [-0.8,1.0,3.1], [0.8,1.0,3.1], [-0.8,0.0,1.9], [0.8,0.0,1.9], [-0.8,0.0,3.1], [0.8,0.0,3.1], [-0.8,-1.0,1.9], [0.8,-1.0,1.9], [-0.8,-1.0,3.1], [0.8,-1.0,3.1]],
|
||||
["RHS_C130J", -9.5, [-0.8,8.0,-4.0], [0.8,8.0,-4.0], [-0.8,8.0,-2.8], [0.8,8.0,-2.8], [-0.8,6.5,-4.0], [0.8,6.5,-4.0], [-0.8,6.5,-2.8], [0.8,6.5,-2.8], [-0.8,5.0,-4.0], [0.8,5.0,-4.0], [-0.8,5.0,-2.8], [0.8,5.0,-2.8], [-0.8,3.5,-4.0], [0.8,3.5,-4.0], [-0.8,3.5,-2.8], [0.8,3.5,-2.8], [-0.8,2.0,-4.0], [0.8,2.0,-4.0], [-0.8,2.0,-2.8], [0.8,2.0,-2.8], [-0.8,0.5,-4.0], [0.8,0.5,-4.0], [-0.8,0.5,-2.8], [0.8,0.5,-2.8]],
|
||||
["RHS_CH_47F_10", -8, [0,2.2,-1.7], [0,0.5,-1.7], [0,-1.2,-1.7]],
|
||||
["RHS_CH_47F_light", -8, [0,2.2,-1.7], [0,0.5,-1.7], [0,-1.2,-1.7]],
|
||||
["RHS_CH_47F", -8, [0,2.2,-1.7], [0,0.5,-1.7], [0,-1.2,-1.7]],
|
||||
|
@ -587,8 +606,8 @@ box_transport_config = [
|
|||
["RHS_Ural_Open_MSV_01", -6.5, [0,-0.2,0.55], [0,-1.4,0.55], [0,-2.55,0.55]],
|
||||
["RHS_Ural_Open_VDV_01", -6.5, [0,-0.2,0.55], [0,-1.4,0.55], [0,-2.55,0.55]],
|
||||
["RHS_Ural_VDV_01", -6.5, [0,-0.2,0.55], [0,-1.4,0.55], [0,-2.55,0.55]],
|
||||
["rhsusf_CH53E_USMC_D", -11.0, [0,2.5,1.4], [0,2.5,2.6], [0,1.0,1.4], [0,1.0,2.6], [0,-0.5,1.4], [0,-0.5,2.6], [0,-0.5,1.4], [0,-0.5,2.6], [0,-2.0,1.4], [0,-2.5,2.6], [0,-3.5,1.4], [0,-3.5,2.6]],
|
||||
["rhsusf_CH53E_USMC", -11.0, [0,2.5,1.4], [0,2.5,2.6], [0,1.0,1.4], [0,1.0,2.6], [0,-0.5,1.4], [0,-0.5,2.6], [0,-0.5,1.4], [0,-0.5,2.6], [0,-2.0,1.4], [0,-2.5,2.6], [0,-3.5,1.4], [0,-3.5,2.6]],
|
||||
["rhsusf_CH53E_USMC_D", -11.0, [0,7,-3.2], [0,7,-2.0], [0,5.5,-3.2], [0,5.5,-2.0], [0,4,-3.2], [0,4,-2.0], [0,2.5,-3.2], [0,2.5,-2.0], [0,1.0,-3.2], [0,1.0,-2.0], [0,-0.5,-3.2], [0,-0.5,-2.0]],
|
||||
["rhsusf_CH53E_USMC", -11.0, [0,7,-3.2], [0,7,-2.0], [0,5.5,-3.2], [0,5.5,-2.0], [0,4,-3.2], [0,4,-2.0], [0,2.5,-3.2], [0,2.5,-2.0], [0,1.0,-3.2], [0,1.0,-2.0], [0,-0.5,-3.2], [0,-0.5,-2.0]],
|
||||
["rhsusf_M1078A1P2_B_D_flatbed_fmtv_usarmy", -5.0, [0,-0.2,0.45], [0,-1.9,0.45]],
|
||||
["rhsusf_M1078A1P2_B_D_fmtv_usarmy", -5.0, [0,-0.2,0.45], [0,-1.9,0.45]],
|
||||
["rhsusf_M1078A1P2_B_M2_D_flatbed_fmtv_usarmy", -5.0, [0,-0.2,0.45], [0,-1.9,0.45]],
|
||||
|
@ -631,6 +650,9 @@ box_transport_config = [
|
|||
["UK3CB_BAF_Merlin_HC4_18_GPMG_Arctic", -7.5, [0.25,3.7,-1.5], [0.25,1.6,-1.5], [0.25,-0.4,-1.5]],
|
||||
["UK3CB_BAF_Merlin_HC4_32_Arctic", -7.5, [0.25,3.7,-1.5], [0.25,1.6,-1.5], [0.25,-0.4,-1.5]],
|
||||
["UK3CB_BAF_Merlin_HC4_CSAR_Arctic", -7.5, [0.25,3.7,-1.5], [0.25,1.6,-1.5], [0.25,-0.4,-1.5]],
|
||||
["USAF_C17",-10,[-1.2,14.4,-0.43],[-1.2,12.8,-0.43],[-1.2,11.1,-0.43],[-1.2,9.5,-0.43],[-1.2,7.9,-0.43],[-1.2,6.3,-0.43],[-1.2,4.6,-0.43],[-1.2,3,-0.43],[-1.2,1.4,-0.43],[-1.2,-0.1,-0.43],[-1.2,-1.8,-0.43],[1.2,14.4,-0.43],[1.2,12.8,-0.43],[1.2,11.2,-0.43],[1.2,9.6,-0.43],[1.2,7.9,-0.43],[1.2,6.3,-0.43],[1.2,4.7,-0.43],[1.2,3.1,-0.43],[1.2,1.5,-0.43],[1.2,0,-0.43],[1.2,-1.7,-0.43],[-1.2,14.5,1.22],[-1.2,12.8,1.22],[-1.2,11.2,1.2],[-1.2,9.5,1.22],[-1.2,7.9,1.22],[-1.2,6.3,1.22],[-1.2,4.7,1.22],[-1.2,3,1.22],[-1.2,1.4,1.22],[-1.2,-0.1,1.22],[-1.2,-1.7,1.22],[1.2,14.5,1.22],[1.2,12.8,1.22],[1.2,11.2,1.22],[1.2,9.6,1.22],[1.2,8,1.22],[1.2,6.3,1.22],[1.2,4.7,1.22],[1.2,3.1,1.22],[1.2,1.5,1.22],[1.2,0,1.22],[1.2,-1.6,1.22]],
|
||||
["USAF_C130J",-10,[0,3.6,2.08],[0,2,2.08],[0,0.3,2.08],[0,-1.3,2.08]],
|
||||
["USAF_C130J_Cargo",-10,[0,3.6,2.08],[0,2,2.08],[0,0.3,2.08],[0,-1.3,2.08],[0,5.3,2.08],[0,7,2.08]],
|
||||
["uns_M35A2_Open", -5, [0,-0.6,0.1], [0,-2.3,0.1]],
|
||||
["uns_M35A2", -5, [0,-0.6,0.1], [0,-2.3,0.1]],
|
||||
["uns_m37b1", -5, [0,-1.8,0.15]],
|
||||
|
@ -814,6 +836,10 @@ boats_names = [
|
|||
"O_Boat_Transport_01_F",
|
||||
"O_T_Boat_Armed_01_hmg_F",
|
||||
"O_T_Boat_Transport_01_F",
|
||||
"CUP_B_MK10_GB",
|
||||
"CUP_B_RHIB_USMC",
|
||||
"CUP_B_RHIB2Turret_USMC",
|
||||
"CUP_B_LCU1600_USMC",
|
||||
"rhsusf_mkvsoc",
|
||||
"sfp_gruppbat",
|
||||
"sfp_rbb_norrkoping",
|
||||
|
|
|
@ -1,13 +1,23 @@
|
|||
/* - Specific object init codes depending on classnames.
|
||||
Format = [Array of classnames as strings, Code to apply]
|
||||
_this is the reference to the object with the classname */
|
||||
/*
|
||||
Specific object init codes depending on classnames.
|
||||
|
||||
Format = [Array of classnames as strings <ARRAY>, Code to apply <CODE>, Allow inheritance <BOOL>]
|
||||
_this is the reference to the object with the classname
|
||||
|
||||
Example:
|
||||
KPLIB_objectInits = [
|
||||
[["O_soldierU_F"], {systemChat "CSAT urban soldier was spawned!"}],
|
||||
[["CAManBase"], {systemChat format ["Some human named '%1' was spawned!", name _this]}, true]
|
||||
];
|
||||
];
|
||||
*/
|
||||
|
||||
KPLIB_objectInits = [
|
||||
// Set KP logo on white flag
|
||||
[["Flag_White_F"], {_this setFlagTexture "res\flag_kp_co.paa";}],
|
||||
|
||||
// Add helipads to zeus, as they can't be recycled after built
|
||||
[["Land_HelipadSquare_F", "Land_HelipadCircle_F", "Land_HelipadRescue_F", "LAND_uns_Heli_pad", "Helipad", "LAND_uns_evac_pad", "LAND_uns_Heli_H"], {{[_x, [[_this], true]] remoteExecCall ["addCuratorEditableObjects", 2]} forEach allCurators;}],
|
||||
[["Helipad_base_F", "LAND_uns_Heli_pad", "Helipad", "LAND_uns_evac_pad", "LAND_uns_Heli_H"], {{[_x, [[_this], true]] remoteExecCall ["addCuratorEditableObjects", 2]} forEach allCurators;}, true],
|
||||
|
||||
// Add ViV action to FOB box
|
||||
[[FOB_box_typename], {_this call F_setFobMass; [_this] remoteExecCall ["F_setLoadableViV", 0, _this];}],
|
||||
|
|
|
@ -79,6 +79,7 @@ light_vehicles = [
|
|||
["CUP_B_LR_Transport_CZ_D",200,0,50], // Land Rover 110 (Transport) Desert
|
||||
["CUP_B_LR_MG_CZ_D",200,40,50], // Land Rover 110 (M2) Desert
|
||||
["CUP_B_LR_Special_CZ_D",250,100,50], // Land Rover 110 (Special) Desert
|
||||
["CUP_B_HMMWV_Ambulance_ACR",225,0,50], // HMMWV (Ambulance)
|
||||
["CUP_B_HMMWV_DSHKM_GPK_ACR",225,60,50], // HMMWV M1114 DSHKM
|
||||
["CUP_B_HMMWV_M2_GPK_ACR",225,60,50], // HMMWV M1114 M2
|
||||
["CUP_B_HMMWV_AGS_GPK_ACR",225,80,50], // HMMWV M1114 AGS
|
||||
|
@ -91,10 +92,12 @@ light_vehicles = [
|
|||
];
|
||||
|
||||
heavy_vehicles = [
|
||||
["CUP_B_BRDM2_HQ_CZ_Des",200,25,200], // BRDM-2 (HQ) (Desert)
|
||||
["CUP_B_BRDM2_CZ_Des",200,200,200], // BRDM-2 (Desert)
|
||||
["I_APC_Wheeled_03_cannon_F",500,400,300], // Pandur II
|
||||
["CUP_I_BMP1_TK_GUE",300,300,200], // BVP-1
|
||||
["CUP_B_BMP2_CZ_Des",400,350,200], // BVP-2
|
||||
["CUP_B_BMP2_AMB_CZ_Des",350,0,200], // BVP-2 Ambulance
|
||||
["B_APC_Tracked_01_AA_F",500,450,400], // IFV-6a Cheetah
|
||||
["CUP_O_T72_RU",600,500,400], // T-72
|
||||
["CUP_B_T72_CZ",800,500,450] // T-72M4CZ
|
||||
|
|
|
@ -88,10 +88,13 @@ light_vehicles = [
|
|||
];
|
||||
|
||||
heavy_vehicles = [
|
||||
["CUP_B_BRDM2_HQ_CZ",200,25,200], // BRDM-2 (HQ)
|
||||
["CUP_B_BRDM2_CZ",200,200,200], // BRDM-2
|
||||
["CUP_B_RM70_CZ",300,750,175], // RM-70
|
||||
["I_APC_Wheeled_03_cannon_F",500,400,300], // Pandur II
|
||||
["CUP_I_BMP1_TK_GUE",300,300,200], // BVP-1
|
||||
["CUP_B_BMP2_CZ",400,350,200], // BVP-2
|
||||
["CUP_B_BMP2_AMB_CZ",350,0,200], // BVP-2 Ambulance
|
||||
["B_APC_Tracked_01_AA_F",500,450,400], // IFV-6a Cheetah
|
||||
["CUP_O_T72_RU",600,500,400], // T72
|
||||
["CUP_B_T72_CZ",800,500,450] // T-72M4CZ
|
||||
|
@ -316,6 +319,7 @@ elite_vehicles = [
|
|||
"CUP_B_Dingo_GL_CZ_Wdl", // Dingo 2 (GL) (Woodland)
|
||||
"QIN_Titus_WDL", // Nexter Titus
|
||||
"QIN_Titus_arx20_WDL", // Nexter Titus ARX20
|
||||
"CUP_B_RM70_CZ", // RM-70
|
||||
"I_APC_Wheeled_03_cannon_F", // Pandur II
|
||||
"CUP_B_BMP2_CZ", // BVP-2
|
||||
"B_APC_Tracked_01_AA_F", // IFV-6a Cheetah
|
||||
|
|
|
@ -117,8 +117,6 @@ air_vehicles = [
|
|||
static_vehicles = [
|
||||
["CUP_B_L111A1_BAF_DDPM",25,40,0], // L111A1 Machine Gun
|
||||
["CUP_B_L111A1_MiniTripod_BAF_DDPM",25,40,0], // L111A1 Minitripod
|
||||
["B_static_AT_F",50,100,0], // Static Titan Launcher (AT)
|
||||
["B_static_AA_F",50,100,0], // Static Titan Launcher (AA)
|
||||
["CUP_WV_B_CRAM",500,500,0], // C-RAM
|
||||
["CUP_WV_B_SS_Launcher",750,500,0], // Mk-29 GMLS
|
||||
["CUP_WV_B_RAM_Launcher",750,750,0], // Mk-49 GMLS
|
||||
|
@ -206,7 +204,7 @@ buildings = [
|
|||
];
|
||||
|
||||
support_vehicles = [
|
||||
[Arsenal_typename,0,0,0],
|
||||
[Arsenal_typename,100,200,0],
|
||||
[Respawn_truck_typename,200,0,100],
|
||||
[FOB_box_typename,300,500,0],
|
||||
[FOB_truck_typename,300,500,75],
|
||||
|
|
|
@ -18,7 +18,7 @@ FOB_typename = "Land_Cargo_HQ_V3_F"; // This
|
|||
FOB_box_typename = "B_Slingload_01_Cargo_F"; // This is the FOB as a container.
|
||||
FOB_truck_typename = "CUP_B_MTVR_Repair_USA"; // This is the FOB as a vehicle.
|
||||
Arsenal_typename = "B_supplyCrate_F"; // This is the virtual arsenal as portable supply crates.
|
||||
Respawn_truck_typename = "CUP_B_LR_Ambulance_GB_W"; // This is the mobile respawn (and medical) truck.
|
||||
Respawn_truck_typename = "CUP_B_FV432_GB_Ambulance"; // This is the mobile respawn (and medical) truck.
|
||||
huron_typename = "CUP_B_CH47F_GB"; // This is Spartan 01, a multipurpose mobile respawn as a helicopter.
|
||||
crewman_classname = "CUP_B_BAF_Soldier_Crew_DPM"; // This defines the crew for vehicles.
|
||||
pilot_classname = "CUP_B_BAF_Soldier_Helipilot_DPM"; // This defines the pilot for helicopters.
|
||||
|
@ -76,6 +76,7 @@ infantry_units = [
|
|||
|
||||
light_vehicles = [
|
||||
["CUP_B_LR_Transport_GB_W",75,0,50], // Land Rover 110 (Transport) Woodland
|
||||
["CUP_B_LR_Ambulance_GB_W",75,0,50], // Land Rover 110 (Ambulance) Woodland
|
||||
["CUP_B_LR_MG_GB_W",75,50,50], // Land Rover 110 (M2) Woodland
|
||||
["CUP_B_LR_Special_M2_GB_W",100,80,50], // Land Rover 110 (M2 Special) Woodland
|
||||
["CUP_B_LR_Special_GMG_GB_W",100,100,50], // Land Rover 110 (GMG Special) Woodland
|
||||
|
@ -93,6 +94,7 @@ light_vehicles = [
|
|||
heavy_vehicles = [
|
||||
["CUP_B_FV432_Bulldog_GB_W",300,100,150], // FV432 Bulldog M240 [Woodland]
|
||||
["CUP_B_FV432_Bulldog_GB_W_RWS",300,250,150], // FV432 Bulldog M2 RWS [Woodland]
|
||||
["CUP_B_FV432_Mortar",350,500,150], // FV432 Mortar
|
||||
["CUP_B_MCV80_GB_W",300,450,275], // MCV-80 Warrior (Woodland)
|
||||
["CUP_B_MCV80_GB_W_SLAT",400,450,275], // MCV-80 Warrior (SLAT - Woodland)
|
||||
["CUP_B_FV510_GB_W",350,550,275], // FV510 Warrior (Woodland)
|
||||
|
@ -117,8 +119,6 @@ air_vehicles = [
|
|||
static_vehicles = [
|
||||
["CUP_B_L111A1_BAF_DPM",25,40,0], // L111A1 Machine Gun
|
||||
["CUP_B_L111A1_MiniTripod_BAF_DPM",25,40,0], // L111A1 Minitripod
|
||||
["B_static_AT_F",50,100,0], // Static Titan Launcher (AT)
|
||||
["B_static_AA_F",50,100,0], // Static Titan Launcher (AA)
|
||||
["CUP_WV_B_CRAM",500,500,0], // C-RAM
|
||||
["CUP_WV_B_SS_Launcher",750,500,0], // Mk-29 GMLS
|
||||
["CUP_WV_B_RAM_Launcher",750,750,0], // Mk-49 GMLS
|
||||
|
@ -206,7 +206,7 @@ buildings = [
|
|||
];
|
||||
|
||||
support_vehicles = [
|
||||
[Arsenal_typename,0,0,0],
|
||||
[Arsenal_typename,100,200,0],
|
||||
[Respawn_truck_typename,200,0,100],
|
||||
[FOB_box_typename,300,500,0],
|
||||
[FOB_truck_typename,300,500,75],
|
||||
|
@ -222,6 +222,7 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["CUP_B_MK10_GB",100,0,50], // LCU Mk.10
|
||||
["CUP_B_TowingTractor_GB",50,0,25], // Towing Tractor
|
||||
["CUP_B_MTVR_Repair_USMC",425,0,75], // MTVR Repair
|
||||
["CUP_B_MTVR_Refuel_USMC",125,0,375], // MTVR Refuel
|
||||
|
@ -324,6 +325,7 @@ blufor_squad_para = [
|
|||
*/
|
||||
elite_vehicles = [
|
||||
"CUP_B_MCV80_GB_W_SLAT", // MCV-80 Warrior (SLAT - Woodland)
|
||||
"CUP_B_FV432_Mortar", // FV432 Mortar
|
||||
"CUP_B_FV510_GB_W", // FV510 Warrior (Woodland)
|
||||
"CUP_B_FV510_GB_W_SLAT", // FV510 Warrior (SLAT - Woodland)
|
||||
"CUP_B_Challenger2_Woodland_BAF", // FV4034 Challenger 2 (Woodland)
|
||||
|
|
|
@ -69,6 +69,7 @@ infantry_units = [
|
|||
];
|
||||
|
||||
light_vehicles = [
|
||||
["CUP_B_S1203_Ambulance_CDF",75,0,50], // Škoda S1203 (Ambulance)
|
||||
["CUP_B_UAZ_Unarmed_CDF",75,0,50], // UAZ
|
||||
["CUP_B_UAZ_MG_CDF",100,60,50], // UAZ (DShKM)
|
||||
["CUP_B_UAZ_AGS30_CDF",100,80,50], // UAZ (AGS-30)
|
||||
|
@ -106,6 +107,7 @@ static_vehicles = [
|
|||
["CUP_B_DSHkM_MiniTripod_CDF",25,40,0], // DShKM Minitripod
|
||||
["CUP_B_AGS_CDF",25,60,0], // AGS-30
|
||||
["CUP_B_SPG9_CDF",50,100,0], // SPG-9
|
||||
["CUP_B_Igla_AA_pod_CDF",100,200,0], // Igla AA Pod
|
||||
["CUP_B_ZU23_CDF",100,300,0], // ZU-23
|
||||
["B_Mortar_01_F",80,150,0], // Mk6 Mortar
|
||||
["CUP_B_2b14_82mm_CDF",80,150,0], // Podnos 2B14
|
||||
|
@ -193,7 +195,7 @@ buildings = [
|
|||
];
|
||||
|
||||
support_vehicles = [
|
||||
[Arsenal_typename,0,0,0],
|
||||
[Arsenal_typename,100,200,0],
|
||||
[Respawn_truck_typename,200,0,100],
|
||||
[FOB_box_typename,300,500,0],
|
||||
[FOB_truck_typename,300,500,75],
|
||||
|
|
|
@ -5,7 +5,9 @@
|
|||
- CUP Units
|
||||
|
||||
Optional Mods:
|
||||
- None
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -98,16 +100,30 @@ heavy_vehicles = [
|
|||
];
|
||||
|
||||
air_vehicles = [
|
||||
["CUP_B_AH6M_USA",200,100,100], // AH-6M
|
||||
["CUP_B_UH60M_Unarmed_FFV_MEV_US",300,0,200], // UH-60M MEDVAC (Unarmed/FFV)
|
||||
["CUP_B_UH60M_US",300,25,200], // UH-60M
|
||||
["CUP_B_UH60M_FFV_US",300,50,200], // UH-60M (FFV)
|
||||
["USAF_C130J",200,0,250], // C-130J Super Hercules
|
||||
["USAF_C130J_Cargo",200,0,250], // C-130J Super Hercules (Cargo)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["CUP_B_AH6M_USA",200,100,100], // AH-6M
|
||||
["CUP_B_MH60L_DAP_2x_US",400,250,225], // MH-60L DAP (2 Stores)
|
||||
["CUP_B_MH60L_DAP_4x_US",400,500,225], // MH-60L DAP (4 Stores)
|
||||
["CUP_B_AH64_DL_USA",500,600,300], // AH-64
|
||||
["CUP_B_AH64D_DL_USA",700,600,200], // AH-64D
|
||||
["CUP_B_AH6X_USA",300,0,100], // AH-6X Littlebird ULB
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["USAF_MQ9",500,750,200], // MQ-9 Reaper
|
||||
["CUP_B_A10_DYN_USA",1000,800,400], // A-10A Thunderbolt II
|
||||
["CUP_B_MH47E_USA",250,100,200] // MH-47E
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["CUP_B_AH6X_USA",300,0,100] // AH-6X Littlebird ULB
|
||||
];
|
||||
|
||||
static_vehicles = [
|
||||
|
@ -202,7 +218,7 @@ buildings = [
|
|||
];
|
||||
|
||||
support_vehicles = [
|
||||
[Arsenal_typename,0,0,0],
|
||||
[Arsenal_typename,100,200,0],
|
||||
[Respawn_truck_typename,200,0,100],
|
||||
[FOB_box_typename,300,500,0],
|
||||
[FOB_truck_typename,300,500,75],
|
||||
|
@ -218,6 +234,19 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["CUP_B_TowingTractor_USA",50,0,75], // Towing Tractor
|
||||
["CUP_B_MTVR_Repair_USA",425,0,75], // MTVR Repair
|
||||
["CUP_B_MTVR_Refuel_USA",125,0,375], // MTVR Refuel
|
||||
|
@ -323,6 +352,14 @@ elite_vehicles = [
|
|||
"CUP_WV_B_SS_Launcher", // Mk-29 GMLS
|
||||
"CUP_WV_B_RAM_Launcher", // Mk-49 GMLS
|
||||
"CUP_B_A10_DYN_USA", // A-10A Thunderbolt II
|
||||
"USAF_MQ9", // MQ-9 Reaper
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"CUP_B_AH64D_DL_USA", // AH-64D
|
||||
"CUP_B_MH60L_DAP_2x_US", // MH-60L DAP (2 Stores)
|
||||
"CUP_B_MH60L_DAP_4x_US", // MH-60L DAP (4 Stores)
|
||||
|
|
|
@ -5,7 +5,9 @@
|
|||
- CUP Units
|
||||
|
||||
Optional Mods:
|
||||
- None
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -99,17 +101,31 @@ heavy_vehicles = [
|
|||
];
|
||||
|
||||
air_vehicles = [
|
||||
["CUP_B_AH6M_USA",200,100,100], // AH-6M
|
||||
["CUP_B_UH60M_Unarmed_FFV_MEV_US",300,0,200], // UH-60M MEDVAC (Unarmed/FFV)
|
||||
["CUP_B_UH60M_US",300,25,200], // UH-60M
|
||||
["CUP_B_UH60M_FFV_US",300,50,200], // UH-60M (FFV)
|
||||
["USAF_C130J",200,0,250], // C-130J Super Hercules
|
||||
["USAF_C130J_Cargo",200,0,250], // C-130J Super Hercules (Cargo)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["CUP_B_AH6M_USA",200,100,100], // AH-6M
|
||||
["CUP_B_MH60L_DAP_2x_US",400,250,225], // MH-60L DAP (2 Stores)
|
||||
["CUP_B_MH60L_DAP_4x_US",400,500,225], // MH-60L DAP (4 Stores)
|
||||
["CUP_B_AH64_DL_USA",500,600,300], // AH-64
|
||||
["CUP_B_AH64D_DL_USA",700,600,200], // AH-64D
|
||||
["CUP_B_AH6X_USA",300,0,100], // AH-6X Littlebird ULB
|
||||
["CUP_B_A10_DYN_USA",1000,800,400], // A-10A Thunderbolt II
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["USAF_MQ9",500,750,200], // MQ-9 Reaper
|
||||
["CUP_B_AC47_Spooky_USA",600,300,400], // AC-47D Spooky
|
||||
["CUP_B_MH47E_USA",250,100,200] // MH-47E
|
||||
["CUP_B_A10_DYN_USA",1000,800,400], // A-10A Thunderbolt II
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["CUP_B_AH6X_USA",300,0,100] // AH-6X Littlebird ULB
|
||||
];
|
||||
|
||||
static_vehicles = [
|
||||
|
@ -204,7 +220,7 @@ buildings = [
|
|||
];
|
||||
|
||||
support_vehicles = [
|
||||
[Arsenal_typename,0,0,0],
|
||||
[Arsenal_typename,100,200,0],
|
||||
[Respawn_truck_typename,200,0,100],
|
||||
[FOB_box_typename,300,500,0],
|
||||
[FOB_truck_typename,300,500,75],
|
||||
|
@ -220,6 +236,19 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["CUP_B_TowingTractor_USA",50,0,75], // Towing Tractor
|
||||
["CUP_B_MTVR_Repair_USMC",425,0,75], // MTVR Repair
|
||||
["CUP_B_MTVR_Refuel_USMC",125,0,375], // MTVR Refuel
|
||||
|
@ -325,6 +354,14 @@ elite_vehicles = [
|
|||
"CUP_WV_B_SS_Launcher", // Mk-29 GMLS
|
||||
"CUP_WV_B_RAM_Launcher", // Mk-49 GMLS
|
||||
"CUP_B_A10_DYN_USA", // A-10A Thunderbolt II
|
||||
"USAF_MQ9", // MQ-9 Reaper
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"CUP_B_AH64D_DL_USA", // AH-64D
|
||||
"CUP_B_MH60L_DAP_2x_US", // MH-60L DAP (2 Stores)
|
||||
"CUP_B_MH60L_DAP_4x_US", // MH-60L DAP (4 Stores)
|
||||
|
|
|
@ -5,7 +5,9 @@
|
|||
- CUP Units
|
||||
|
||||
Optional Mods:
|
||||
- None
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -23,7 +25,7 @@ huron_typename = "CUP_B_CH53E_USMC"; // This
|
|||
crewman_classname = "CUP_B_USMC_Crewman_FROG_DES"; // This defines the crew for vehicles.
|
||||
pilot_classname = "CUP_B_USMC_Pilot"; // This defines the pilot for helicopters.
|
||||
KP_liberation_little_bird_classname = "CUP_B_UH1Y_UNA_USMC"; // These are the little birds which spawn on the Freedom or at Chimera base.
|
||||
KP_liberation_boat_classname = "CUP_B_RHIB2Turret_USMC"; // These are the boats which spawn at the stern of the Freedom.
|
||||
KP_liberation_boat_classname = "CUP_B_Zodiac_USMC"; // These are the boats which spawn at the stern of the Freedom.
|
||||
KP_liberation_truck_classname = "CUP_B_MTVR_USA"; // These are the trucks which are used in the logistic convoy system.
|
||||
KP_liberation_small_storage_building = "ContainmentArea_02_sand_F"; // A small storage area for resources.
|
||||
KP_liberation_large_storage_building = "ContainmentArea_01_sand_F"; // A large storage area for resources.
|
||||
|
@ -77,7 +79,9 @@ light_vehicles = [
|
|||
["CUP_B_RG31_M2_OD_USA",100,50,50], // RG-31 M2
|
||||
["CUP_B_RG31E_M2_OD_USA",100,50,50], // RG-31 Mk5E M2
|
||||
["CUP_B_RG31_Mk19_OD_USA",100,80,50], // RG-31 Mk.19
|
||||
["CUP_B_MTVR_USA",125,0,75] // MTVR
|
||||
["CUP_B_MTVR_USA",125,0,75], // MTVR
|
||||
["CUP_B_RHIB_USMC",150,100,100], // RHIB
|
||||
["CUP_B_RHIB2Turret_USMC",250,200,100] // RHIB (Mk19)
|
||||
];
|
||||
|
||||
heavy_vehicles = [
|
||||
|
@ -94,15 +98,28 @@ heavy_vehicles = [
|
|||
];
|
||||
|
||||
air_vehicles = [
|
||||
["CUP_B_UH1Y_MEV_USMC",200,0,100], // UH-1Y Venom (MEDVAC)
|
||||
["CUP_B_UH1Y_Gunship_Dynamic_USMC",200,100,100], // UH-1Y Venom (Gunship)
|
||||
["CUP_B_MH60S_FFV_USMC",250,25,200], // MH-60S Seahawk (FFV)
|
||||
["CUP_B_UH60S_USN",250,50,200], // MH-60S Seahawk (M3M)
|
||||
["CUP_B_C130J_USMC",200,0,250], // C-130J
|
||||
["CUP_B_C130J_Cargo_USMC",200,0,250], // C-130J (VIV)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["CUP_B_AH1Z_Dynamic_USMC",500,500,200], // AH-1Z
|
||||
["CUP_B_MH60L_DAP_2x_USN",450,400,250], // MH-60S Knighthawk (ESSS x2)
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["CUP_B_USMC_DYN_MQ9",500,500,200], // MQ-9 Reaper
|
||||
["CUP_B_AV8B_DYN_USMC",1000,800,400], // AV-8B Harrier II
|
||||
["CUP_B_F35B_Stealth_USMC",1000,1200,400], // F-35B Lightning II (Stealth)
|
||||
["CUP_B_F35B_USMC",1500,1750,450], // F-35B Lightning II
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["CUP_B_F35B_Stealth_USMC",2500,2000,750], // F-35B Lightning II (Stealth)
|
||||
["CUP_B_F35B_USMC",2500,2250,750], // F-35B Lightning II
|
||||
["CUP_B_MV22_USMC_RAMPGUN",750,100,500], // MV-22B Osprey (Ramp Gun)
|
||||
["CUP_B_MV22_USMC",750,0,500], // MV-22B Osprey
|
||||
["CUP_B_MV22_VIV_USMC",750,0,500] // MV-22B Osprey (VIV)
|
||||
|
@ -200,7 +217,7 @@ buildings = [
|
|||
];
|
||||
|
||||
support_vehicles = [
|
||||
[Arsenal_typename,0,0,0],
|
||||
[Arsenal_typename,100,200,0],
|
||||
[Respawn_truck_typename,200,0,100],
|
||||
[FOB_box_typename,300,500,0],
|
||||
[FOB_truck_typename,300,500,75],
|
||||
|
@ -216,6 +233,20 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["CUP_B_LCU1600_USMC",250,0,175], // LCU-1610
|
||||
["CUP_B_TowingTractor_USMC",50,0,75], // Towing Tractor
|
||||
["CUP_B_MTVR_Repair_USA",425,0,75], // MTVR Repair
|
||||
["CUP_B_MTVR_Refuel_USA",125,0,375], // MTVR Refuel
|
||||
|
@ -323,6 +354,13 @@ elite_vehicles = [
|
|||
"CUP_WV_B_RAM_Launcher", // Mk-49 GMLS
|
||||
"CUP_B_F35B_Stealth_USMC", // F-35B Lightning II (Stealth)
|
||||
"CUP_B_AV8B_DYN_USMC", // AV-8B Harrier II
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"CUP_B_AH1Z_Dynamic_USMC", // AH-1Z
|
||||
"CUP_B_MH60L_DAP_2x_USN", // MH-60S Knighthawk (ESSS x2)
|
||||
"CUP_B_M1A1_DES_USMC", // M1A1 Abrams (Desert)
|
||||
|
|
|
@ -5,7 +5,9 @@
|
|||
- CUP Units
|
||||
|
||||
Optional Mods:
|
||||
- None
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -23,7 +25,7 @@ huron_typename = "CUP_B_CH53E_USMC"; // This
|
|||
crewman_classname = "CUP_B_USMC_Crewman_FROG_WDL"; // This defines the crew for vehicles.
|
||||
pilot_classname = "CUP_B_USMC_Pilot"; // This defines the pilot for helicopters.
|
||||
KP_liberation_little_bird_classname = "CUP_B_UH1Y_UNA_USMC"; // These are the little birds which spawn on the Freedom or at Chimera base.
|
||||
KP_liberation_boat_classname = "CUP_B_RHIB2Turret_USMC"; // These are the boats which spawn at the stern of the Freedom.
|
||||
KP_liberation_boat_classname = "CUP_B_Zodiac_USMC"; // These are the boats which spawn at the stern of the Freedom.
|
||||
KP_liberation_truck_classname = "CUP_B_MTVR_USMC"; // These are the trucks which are used in the logistic convoy system.
|
||||
KP_liberation_small_storage_building = "ContainmentArea_02_sand_F"; // A small storage area for resources.
|
||||
KP_liberation_large_storage_building = "ContainmentArea_01_sand_F"; // A large storage area for resources.
|
||||
|
@ -78,7 +80,9 @@ light_vehicles = [
|
|||
["CUP_B_RG31_M2_OD_USMC",100,50,50], // RG-31 M2
|
||||
["CUP_B_RG31E_M2_OD_USMC",100,50,50], // RG-31 Mk5E M2
|
||||
["CUP_B_RG31_Mk19_OD_USMC",100,80,50], // RG-31 Mk.19
|
||||
["CUP_B_MTVR_USMC",125,0,75] // MTVR
|
||||
["CUP_B_MTVR_USMC",125,0,75], // MTVR
|
||||
["CUP_B_RHIB_USMC",150,100,100], // RHIB
|
||||
["CUP_B_RHIB2Turret_USMC",250,200,100] // RHIB (Mk19)
|
||||
];
|
||||
|
||||
heavy_vehicles = [
|
||||
|
@ -95,15 +99,28 @@ heavy_vehicles = [
|
|||
];
|
||||
|
||||
air_vehicles = [
|
||||
["CUP_B_UH1Y_MEV_USMC",200,0,100], // UH-1Y Venom (MEDVAC)
|
||||
["CUP_B_UH1Y_Gunship_Dynamic_USMC",200,100,100], // UH-1Y Venom (Gunship)
|
||||
["CUP_B_MH60S_FFV_USMC",250,25,200], // MH-60S Seahawk (FFV)
|
||||
["CUP_B_UH60S_USN",250,50,200], // MH-60S Seahawk (M3M)
|
||||
["USAF_C130J",200,0,250], // C-130J Super Hercules
|
||||
["USAF_C130J_Cargo",200,0,250], // C-130J Super Hercules (Cargo)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["CUP_B_AH1Z_Dynamic_USMC",500,500,200], // AH-1Z
|
||||
["CUP_B_MH60L_DAP_2x_USN",450,400,250], // MH-60S Knighthawk (ESSS x2)
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["CUP_B_USMC_DYN_MQ9",500,500,200], // MQ-9 Reaper
|
||||
["CUP_B_AV8B_DYN_USMC",1000,800,400], // AV-8B Harrier II
|
||||
["CUP_B_F35B_Stealth_USMC",1000,1200,400], // F-35B Lightning II (Stealth)
|
||||
["CUP_B_F35B_USMC",1500,1750,450], // F-35B Lightning II
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["CUP_B_F35B_Stealth_USMC",2500,2000,750], // F-35B Lightning II (Stealth)
|
||||
["CUP_B_F35B_USMC",2500,2250,750], // F-35B Lightning II
|
||||
["CUP_B_MV22_USMC_RAMPGUN",750,100,500], // MV-22B Osprey (Ramp Gun)
|
||||
["CUP_B_MV22_USMC",750,0,500], // MV-22B Osprey
|
||||
["CUP_B_MV22_VIV_USMC",750,0,500] // MV-22B Osprey (VIV)
|
||||
|
@ -201,7 +218,7 @@ buildings = [
|
|||
];
|
||||
|
||||
support_vehicles = [
|
||||
[Arsenal_typename,0,0,0],
|
||||
[Arsenal_typename,100,200,0],
|
||||
[Respawn_truck_typename,200,0,100],
|
||||
[FOB_box_typename,300,500,0],
|
||||
[FOB_truck_typename,300,500,75],
|
||||
|
@ -217,6 +234,20 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["CUP_B_LCU1600_USMC",250,0,175], // LCU-1610
|
||||
["CUP_B_TowingTractor_USMC",50,0,75], // Towing Tractor
|
||||
["CUP_B_MTVR_Repair_USMC",425,0,75], // MTVR Repair
|
||||
["CUP_B_MTVR_Refuel_USMC",125,0,375], // MTVR Refuel
|
||||
|
@ -324,6 +355,13 @@ elite_vehicles = [
|
|||
"CUP_WV_B_RAM_Launcher", // Mk-49 GMLS
|
||||
"CUP_B_F35B_Stealth_USMC", // F-35B Lightning II (Stealth)
|
||||
"CUP_B_AV8B_DYN_USMC", // AV-8B Harrier II
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"CUP_B_AH1Z_Dynamic_USMC", // AH-1Z
|
||||
"CUP_B_MH60L_DAP_2x_USN", // MH-60S Knighthawk (ESSS x2)
|
||||
"CUP_B_M1A1_Woodland_USMC", // M1A1 Abrams (Woodland)
|
||||
|
|
|
@ -9,6 +9,9 @@
|
|||
- F/A-18
|
||||
- CUP Weapons
|
||||
- CUP Vehicles
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -169,18 +172,31 @@ air_vehicles = [
|
|||
["rhsusf_CH53E_USMC",300,0,175], // CH-53E Super Stallion
|
||||
["rhsusf_CH53E_USMC_GAU21",300,100,175], // CH-53E Super Stallion (GAU-21)
|
||||
["B_Heli_Transport_03_F",300,80,175], // CH-67 Huron (Armed)
|
||||
["USAF_C130J",200,0,250], // C-130J Super Hercules
|
||||
["USAF_C130J_Cargo",200,0,250], // C-130J Super Hercules (Cargo)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["B_UAV_02_dynamicLoadout_F",400,300,200], // MQ-4A Greyhawk
|
||||
["B_T_UAV_03_dynamicLoadout_F",450,500,250], // MQ-12 Falcon
|
||||
["B_UAV_05_F",500,500,200], // UCAV Sentinel
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["USAF_MQ9",500,750,200], // MQ-9 Reaper
|
||||
["I_Plane_Fighter_03_dynamicLoadout_F",500,400,350], // A-143 Buzzard (AA)
|
||||
["B_Plane_CAS_01_dynamicLoadout_F",1000,800,400], // A-164 Wipeout (CAS)
|
||||
["RHS_A10",1000,1000,400], // A-10A (CAS)
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["I_Plane_Fighter_04_F",1000,1200,400], // A-149 Gryphon
|
||||
["FIR_F15C",1250,1250,450], // F-15C Eagle
|
||||
["FIR_F15D",1250,1250,450], // F-15D Eagle
|
||||
["FIR_F15E",1250,1500,450], // F-15E Strike Eagle
|
||||
["JS_JC_FA18E",1500,1750,450], // F/A-18 E Super Hornet
|
||||
["JS_JC_FA18F",1500,1750,450], // F/A-18 F Super Hornet
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["B_Plane_Fighter_01_F",1500,1750,450], // F/A-181 Black Wasp II
|
||||
["B_Plane_Fighter_01_Stealth_F",1500,1750,450], // F/A-181 Black Wasp II (Stealth)
|
||||
["B_T_VTOL_01_armed_F",750,1500,500], // V-44 X Blackfish (Armed)
|
||||
|
@ -298,6 +314,19 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["CUP_B_TowingTractor_NATO",50,0,25], // Towing Tractor
|
||||
["B_T_APC_Tracked_01_CRV_F",500,250,350], // CRV-6e Bobcat
|
||||
["B_T_Truck_01_Repair_F",325,0,75], // HEMTT Repair
|
||||
|
@ -421,6 +450,14 @@ elite_vehicles = [
|
|||
"B_Plane_CAS_01_dynamicLoadout_F", // A-164 Wipeout (CAS)
|
||||
"I_Plane_Fighter_04_F", // A-149 Gryphon
|
||||
"RHS_A10", // A-10A (CAS)
|
||||
"USAF_MQ9", // MQ-9 Reaper
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"FIR_F15C", // F-15C Eagle
|
||||
"FIR_F15D", // F-15D Eagle
|
||||
"FIR_F15E", // F-15E Strike Eagle
|
||||
|
|
|
@ -9,6 +9,9 @@
|
|||
- F/A-18
|
||||
- CUP Weapons
|
||||
- CUP Vehicles
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -175,18 +178,31 @@ air_vehicles = [
|
|||
["rhsusf_CH53E_USMC",300,0,175], // CH-53E Super Stallion
|
||||
["rhsusf_CH53E_USMC_GAU21_D",300,100,175], // CH-53E Super Stallion (GAU-21)
|
||||
["B_Heli_Transport_03_F",300,80,175], // CH-67 Huron (Armed)
|
||||
["USAF_C130J",200,0,250], // C-130J Super Hercules
|
||||
["USAF_C130J_Cargo",200,0,250], // C-130J Super Hercules (Cargo)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["B_UAV_02_dynamicLoadout_F",400,400,200], // MQ-4A Greyhawk
|
||||
["B_T_UAV_03_dynamicLoadout_F",450,500,250], // MQ-12 Falcon
|
||||
["B_UAV_05_F",500,500,200], // UCAV Sentinel
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["USAF_MQ9",500,750,200], // MQ-9 Reaper
|
||||
["I_Plane_Fighter_03_dynamicLoadout_F",500,400,350], // A-143 Buzzard
|
||||
["B_Plane_CAS_01_dynamicLoadout_F",1000,800,400], // A-164 Wipeout (CAS)
|
||||
["RHS_A10",1000,1000,400], // A-10A (CAS)
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["I_Plane_Fighter_04_F",1000,1200,400], // A-149 Gryphon
|
||||
["FIR_F15C",1250,1250,450], // F-15C Eagle
|
||||
["FIR_F15D",1250,1250,450], // F-15D Eagle
|
||||
["FIR_F15E",1250,1500,450], // F-15E Strike Eagle
|
||||
["JS_JC_FA18E",1500,1750,450], // F/A-18 E Super Hornet
|
||||
["JS_JC_FA18F",1500,1750,450], // F/A-18 F Super Hornet
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["B_Plane_Fighter_01_F",1500,1750,450], // F/A-181 Black Wasp II
|
||||
["B_Plane_Fighter_01_Stealth_F",1500,1750,450], // F/A-181 Black Wasp II (Stealth)
|
||||
["B_T_VTOL_01_armed_F",750,1500,500], // V-44 X Blackfish (Armed)
|
||||
|
@ -304,6 +320,19 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["CUP_B_TowingTractor_NATO",50,0,25], // Towing Tractor
|
||||
["B_APC_Tracked_01_CRV_F",500,250,350], // CRV-6e Bobcat
|
||||
["B_Truck_01_Repair_F",325,0,75], // HEMTT Repair
|
||||
|
@ -426,6 +455,14 @@ elite_vehicles = [
|
|||
"B_Plane_CAS_01_dynamicLoadout_F", // A-164 Wipeout (CAS)
|
||||
"I_Plane_Fighter_04_F", // A-149 Gryphon
|
||||
"RHS_A10", // A-10A (CAS)
|
||||
"USAF_MQ9", // MQ-9 Reaper
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"FIR_F15C", // F-15C Eagle
|
||||
"FIR_F15D", // F-15D Eagle
|
||||
"FIR_F15E", // F-15E Strike Eagle
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
Optional Mods:
|
||||
- F-15C
|
||||
- F/A-18
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -136,15 +139,28 @@ air_vehicles = [
|
|||
["RHS_CH_47F_10",275,80,175], // CH-47 Chinook (Armed)
|
||||
["rhsusf_CH53E_USMC_D",300,0,175], // CH-53E Super Stallion
|
||||
["rhsusf_CH53E_USMC_GAU21_D",300,100,175], // CH-53E Super Stallion (GAU-21)
|
||||
["USAF_C130J",200,0,250], // C-130J Super Hercules
|
||||
["USAF_C130J_Cargo",200,0,250], // C-130J Super Hercules (Cargo)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["B_UAV_02_dynamicLoadout_F",400,300,200], // MQ-4A Greyhawk
|
||||
["B_T_UAV_03_dynamicLoadout_F",450,500,250], // MQ-12 Falcon
|
||||
["B_UAV_05_F",500,500,200], // UCAV Sentinel
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["USAF_MQ9",500,750,200], // MQ-9 Reaper
|
||||
["RHS_A10",1000,1000,400], // A-10A (CAS)
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["FIR_F15C",1250,1250,450], // F-15C Eagle
|
||||
["FIR_F15D",1250,1250,450], // F-15D Eagle
|
||||
["FIR_F15E",1250,1500,450], // F-15E Strike Eagle
|
||||
["JS_JC_FA18E",1500,1750,450], // F/A-18 E Super Hornet
|
||||
["JS_JC_FA18F",1500,1750,450], // F/A-18 F Super Hornet
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["B_Plane_Fighter_01_F",1500,1750,450], // F/A-181 Black Wasp II
|
||||
["B_Plane_Fighter_01_Stealth_F",1500,1750,450], // F/A-181 Black Wasp II (Stealth)
|
||||
["B_T_VTOL_01_armed_F",750,1500,500], // V-44 X Blackfish (Armed)
|
||||
|
@ -259,6 +275,19 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["B_APC_Tracked_01_CRV_F",500,250,350], // CRV-6e Bobcat
|
||||
["rhsusf_M1239_M2_Deploy_socom_d",450,200,300], // M1239 AUV (Deploy, M2)
|
||||
["rhsusf_M1239_MK19_Deploy_socom_d",450,250,300], // M1239 AUV (Deploy, Mk19)
|
||||
|
@ -371,6 +400,14 @@ elite_vehicles = [
|
|||
"B_UAV_02_dynamicLoadout_F", // MQ-4A Greyhawk
|
||||
"B_T_UAV_03_dynamicLoadout_F", // MQ-12 Falcon
|
||||
"B_UAV_05_F", // UCAV Sentinel
|
||||
"USAF_MQ9", // MQ-9 Reaper
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"RHS_A10", // A-10A (CAS)
|
||||
"FIR_F15C", // F-15C Eagle
|
||||
"FIR_F15D", // F-15D Eagle
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
Optional Mods:
|
||||
- F-15C
|
||||
- F/A-18
|
||||
- USAF Main Pack
|
||||
- USAF Fighters Pack
|
||||
- USAF Utility Pack
|
||||
*/
|
||||
|
||||
/*
|
||||
|
@ -129,15 +132,28 @@ air_vehicles = [
|
|||
["RHS_CH_47F_10",275,80,175], // CH-47 Chinook (Armed)
|
||||
["rhsusf_CH53E_USMC",300,0,175], // CH-53E Super Stallion
|
||||
["rhsusf_CH53E_USMC_GAU21",300,100,175], // CH-53E Super Stallion (GAU-21)
|
||||
["USAF_C130J",200,0,250], // C-130J Super Hercules
|
||||
["USAF_C130J_Cargo",200,0,250], // C-130J Super Hercules (Cargo)
|
||||
["USAF_C17",500,0,400], // C-17 Globemaster III
|
||||
["usaf_kc135",600,0,2500], // KC-135 Stratotanker
|
||||
["B_UAV_02_dynamicLoadout_F",400,300,200], // MQ-4A Greyhawk
|
||||
["B_T_UAV_03_dynamicLoadout_F",450,500,250], // MQ-12 Falcon
|
||||
["B_UAV_05_F",500,500,200], // UCAV Sentinel
|
||||
["USAF_RQ4A",500,0,200], // RQ-4A Global Hawk
|
||||
["USAF_MQ9",500,750,200], // MQ-9 Reaper
|
||||
["RHS_A10",1000,1000,400], // A-10A (CAS)
|
||||
["USAF_A10",1500,1000,400], // A-10C Thunderbolt II
|
||||
["FIR_F15C",1250,1250,450], // F-15C Eagle
|
||||
["FIR_F15D",1250,1250,450], // F-15D Eagle
|
||||
["FIR_F15E",1250,1500,450], // F-15E Strike Eagle
|
||||
["JS_JC_FA18E",1500,1750,450], // F/A-18 E Super Hornet
|
||||
["JS_JC_FA18F",1500,1750,450], // F/A-18 F Super Hornet
|
||||
["USAF_F22",1800,2000,500], // F-22A Raptor
|
||||
["USAF_F22_EWP_AA",1800,2100,500], // F-22A Raptor (EWP-AA)
|
||||
["USAF_F22_EWP_AG",1800,2100,500], // F-22A Raptor (EWP-AG)
|
||||
["USAF_F22_Heavy",1800,2250,500], // F-22A Raptor (Heavy)
|
||||
["USAF_F35A_STEALTH",2250,2000,750], // F-35A Lightning II
|
||||
["USAF_F35A",2250,2250,750], // F-35A Lightning II (Heavy)
|
||||
["B_Plane_Fighter_01_F",1500,1750,450], // F/A-181 Black Wasp II
|
||||
["B_Plane_Fighter_01_Stealth_F",1500,1750,450], // F/A-181 Black Wasp II (Stealth)
|
||||
["B_T_VTOL_01_armed_F",750,1500,500], // V-44 X Blackfish (Armed)
|
||||
|
@ -252,6 +268,19 @@ support_vehicles = [
|
|||
["ACE_Box_82mm_Mo_Illum",50,10,0],
|
||||
["ACE_Wheel",10,0,0],
|
||||
["ACE_Track",10,0,0],
|
||||
["USAF_missileCart_W_AGM114",50,150,0], // Missile Cart (AGM-114)
|
||||
["USAF_missileCart_AGMMix",50,150,0], // Missile Cart (AGM-65 Mix)
|
||||
["USAF_missileCart_AGM1",50,150,0], // Missile Cart (AGM-65D)
|
||||
["USAF_missileCart_AGM2",50,150,0], // Missile Cart (AGM-65E)
|
||||
["USAF_missileCart_AGM3",50,150,0], // Missile Cart (AGM-65K)
|
||||
["USAF_missileCart_AA1",50,150,0], // Missile Cart (AIM-9M/AIM-120)
|
||||
["USAF_missileCart_AA2",50,150,0], // Missile Cart (AIM-9X/AIM-120)
|
||||
["USAF_missileCart_GBU12_green",50,150,0], // Missile Cart (GBU12 Green)
|
||||
["USAF_missileCart_GBU12_maritime",50,150,0], // Missile Cart (GBU12 Maritime)
|
||||
["USAF_missileCart_GBU12",50,150,0], // Missile Cart (GBU12)
|
||||
["USAF_missileCart_Gbu31",50,150,0], // Missile Cart (GBU31)
|
||||
["USAF_missileCart_GBU39",50,150,0], // Missile Cart (GBU39)
|
||||
["USAF_missileCart_Mk82",50,150,0], // Missile Cart (Mk82)
|
||||
["B_APC_Tracked_01_CRV_F",500,250,350], // CRV-6e Bobcat
|
||||
["rhsusf_M977A4_REPAIR_BKIT_usarmy_wd",325,0,75], // M977A4 Repair
|
||||
["rhsusf_M978A4_BKIT_usarmy_wd",125,0,275], // M978A4 Fuel
|
||||
|
@ -361,6 +390,14 @@ elite_vehicles = [
|
|||
"B_UAV_02_dynamicLoadout_F", // MQ-4A Greyhawk
|
||||
"B_T_UAV_03_dynamicLoadout_F", // MQ-12 Falcon
|
||||
"B_UAV_05_F", // UCAV Sentinel
|
||||
"USAF_MQ9", // MQ-9 Reaper
|
||||
"USAF_A10", // A-10C Thunderbolt II
|
||||
"USAF_F22", // F-22A Raptor
|
||||
"USAF_F22_EWP_AA", // F-22A Raptor (EWP-AA)
|
||||
"USAF_F22_EWP_AG", // F-22A Raptor (EWP-AG)
|
||||
"USAF_F22_Heavy", // F-22A Raptor (Heavy)
|
||||
"USAF_F35A_STEALTH", // F-35A Lightning II
|
||||
"USAF_F35A", // F-35A Lightning II (Heavy)
|
||||
"RHS_A10", // A-10A (CAS)
|
||||
"FIR_F15C", // F-15C Eagle
|
||||
"FIR_F15D", // F-15D Eagle
|
||||
|
|
|
@ -1,3 +1,9 @@
|
|||
if (isServer) then {
|
||||
diag_log format ["[KP LIBERATION] [PRESETS] ----- Server starts preset initialization - time: %1", diag_ticktime];
|
||||
diag_log "[KP LIBERATION] [PRESETS] Not found vehicles listed below are not an issue in general. It just sorts out vehicles from not loaded mods.";
|
||||
diag_log "[KP LIBERATION] [PRESETS] Only if you e.g. use a CUP preset and you get messages about missing CUP classes, then check your loaded mods.";
|
||||
};
|
||||
|
||||
switch (KP_liberation_preset_blufor) do {
|
||||
case 1: {[] call compileFinal preprocessFileLineNumbers "presets\blufor\apex.sqf";};
|
||||
case 2: {[] call compileFinal preprocessFileLineNumbers "presets\blufor\3cbBAF_mtp.sqf";};
|
||||
|
@ -140,12 +146,12 @@ GRLIB_ignore_colisions_when_building = [
|
|||
|
||||
/* !!! DO NOT EDIT BELOW !!! */
|
||||
// Preset arrays
|
||||
infantry_units = [infantry_units] call F_filterMods;
|
||||
light_vehicles = [light_vehicles] call F_filterMods;
|
||||
heavy_vehicles = [heavy_vehicles] call F_filterMods;
|
||||
air_vehicles = [air_vehicles] call F_filterMods;
|
||||
support_vehicles = [support_vehicles] call F_filterMods;
|
||||
static_vehicles = [static_vehicles] call F_filterMods;
|
||||
infantry_units = infantry_units select {[( _x select 0)] call KPLIB_fnc_checkClass};
|
||||
light_vehicles = light_vehicles select {[( _x select 0)] call KPLIB_fnc_checkClass};
|
||||
heavy_vehicles = heavy_vehicles select {[( _x select 0)] call KPLIB_fnc_checkClass};
|
||||
air_vehicles = air_vehicles select {[( _x select 0)] call KPLIB_fnc_checkClass};
|
||||
support_vehicles = support_vehicles select {[( _x select 0)] call KPLIB_fnc_checkClass};
|
||||
static_vehicles = static_vehicles select {[( _x select 0)] call KPLIB_fnc_checkClass};
|
||||
// Preset classes arrays
|
||||
light_vehicles_classes = light_vehicles apply {toLower (_x select 0)};
|
||||
heavy_vehicles_classes = heavy_vehicles apply {toLower (_x select 0)};
|
||||
|
@ -160,23 +166,23 @@ air_vehicles_classes = air_vehicles apply {toLower (_x select 0)};
|
|||
};
|
||||
} forEach support_vehicles + [huron_typename];
|
||||
|
||||
buildings = [buildings] call F_filterMods;
|
||||
buildings = buildings select {[( _x select 0)] call KPLIB_fnc_checkClass};
|
||||
build_lists = [[],infantry_units,light_vehicles,heavy_vehicles,air_vehicles,static_vehicles,buildings,support_vehicles,squads];
|
||||
KP_liberation_storage_buildings = [KP_liberation_small_storage_building,KP_liberation_large_storage_building];
|
||||
KP_liberation_crates = [KP_liberation_supply_crate,KP_liberation_ammo_crate,KP_liberation_fuel_crate];
|
||||
KP_liberation_upgrade_buildings = [KP_liberation_recycle_building,KP_liberation_air_vehicle_building,KP_liberation_heli_slot_building,KP_liberation_plane_slot_building];
|
||||
KP_liberation_air_slots = [KP_liberation_heli_slot_building,KP_liberation_plane_slot_building];
|
||||
militia_squad = militia_squad select {[_x] call F_checkClass};
|
||||
militia_vehicles = militia_vehicles select {[_x] call F_checkClass};
|
||||
opfor_vehicles = opfor_vehicles select {[_x] call F_checkClass};
|
||||
opfor_vehicles_low_intensity = opfor_vehicles_low_intensity select {[_x] call F_checkClass};
|
||||
opfor_battlegroup_vehicles = opfor_battlegroup_vehicles select {[_x] call F_checkClass};
|
||||
opfor_battlegroup_vehicles_low_intensity = opfor_battlegroup_vehicles_low_intensity select {[_x] call F_checkClass};
|
||||
opfor_troup_transports = opfor_troup_transports select {[_x] call F_checkClass};
|
||||
opfor_choppers = opfor_choppers select {[_x] call F_checkClass};
|
||||
opfor_air = opfor_air select {[_x] call F_checkClass};
|
||||
civilians = civilians select {[_x] call F_checkClass};
|
||||
civilian_vehicles = civilian_vehicles select {[_x] call F_checkClass};
|
||||
militia_squad = militia_squad select {[_x] call KPLIB_fnc_checkClass};
|
||||
militia_vehicles = militia_vehicles select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_vehicles = opfor_vehicles select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_vehicles_low_intensity = opfor_vehicles_low_intensity select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_battlegroup_vehicles = opfor_battlegroup_vehicles select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_battlegroup_vehicles_low_intensity = opfor_battlegroup_vehicles_low_intensity select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_troup_transports = opfor_troup_transports select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_choppers = opfor_choppers select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_air = opfor_air select {[_x] call KPLIB_fnc_checkClass};
|
||||
civilians = civilians select {[_x] call KPLIB_fnc_checkClass};
|
||||
civilian_vehicles = civilian_vehicles select {[_x] call KPLIB_fnc_checkClass};
|
||||
military_alphabet = ["Alpha","Bravo","Charlie","Delta","Echo","Foxtrot","Golf","Hotel","India","Juliet","Kilo","Lima","Mike","November","Oscar","Papa","Quebec","Romeo","Sierra","Tango","Uniform","Victor","Whiskey","X-Ray","Yankee","Zulu"];
|
||||
land_vehicles_classnames = (opfor_vehicles + militia_vehicles);
|
||||
opfor_squad_8_standard = [opfor_squad_leader,opfor_team_leader,opfor_machinegunner,opfor_heavygunner,opfor_medic,opfor_marksman,opfor_grenadier,opfor_rpg];
|
||||
|
@ -200,10 +206,12 @@ zeropos = [0,0,0];
|
|||
squads_names = [localize "STR_LIGHT_RIFLE_SQUAD", localize "STR_RIFLE_SQUAD", localize "STR_AT_SQUAD", localize "STR_AA_SQUAD", localize "STR_RECON_SQUAD", localize "STR_PARA_SQUAD"];
|
||||
ammobox_transports_typenames = [];
|
||||
{ammobox_transports_typenames pushback (_x select 0)} foreach box_transport_config;
|
||||
ammobox_transports_typenames = ammobox_transports_typenames select {[_x] call F_checkClass};
|
||||
elite_vehicles = elite_vehicles select {[_x] call F_checkClass};
|
||||
ammobox_transports_typenames = ammobox_transports_typenames select {[_x] call KPLIB_fnc_checkClass};
|
||||
elite_vehicles = elite_vehicles select {[_x] call KPLIB_fnc_checkClass};
|
||||
opfor_infantry = [opfor_sentry,opfor_rifleman,opfor_grenadier,opfor_squad_leader,opfor_team_leader,opfor_marksman,opfor_machinegunner,opfor_heavygunner,opfor_medic,opfor_rpg,opfor_at,opfor_aa,opfor_officer,opfor_sharpshooter,opfor_sniper,opfor_engineer];
|
||||
GRLIB_intel_file = "Land_File1_F";
|
||||
GRLIB_intel_laptop = "Land_Laptop_device_F";
|
||||
GRLIB_sar_wreck = "Land_Wreck_Heli_Attack_01_F";
|
||||
GRLIB_sar_fire = "test_EmptyObjectForFireBig";
|
||||
|
||||
if (isServer) then {diag_log format ["[KP LIBERATION] [PRESETS] ----- Server finished preset initialization - time: %1", diag_ticktime];};
|
||||
|
|
|
@ -33,12 +33,19 @@ waitUntil {!isNil "one_eco_done"};
|
|||
waitUntil {one_synchro_done};
|
||||
waitUntil {one_eco_done};
|
||||
|
||||
private _nearfob = [] call F_getNearestFob;
|
||||
private _fobdistance = 9999;
|
||||
private _nearest_sector = [GRLIB_fob_range] call F_getNearestSector;
|
||||
private _prod_sector = [];
|
||||
private _directAccess = (getPlayerUID player) in KP_liberation_commander_actions || {player == ([] call KPLIB_fnc_getCommander)} || {[] call F_isAdmin};
|
||||
|
||||
while {true} do {
|
||||
|
||||
private _nearfob = [] call F_getNearestFob;
|
||||
private _fobdistance = 9999;
|
||||
private _nearest_sector = [GRLIB_fob_range] call F_getNearestSector;
|
||||
private _prod_sector = [];
|
||||
_nearfob = [] call F_getNearestFob;
|
||||
_fobdistance = 9999;
|
||||
_nearest_sector = [GRLIB_fob_range] call F_getNearestSector;
|
||||
_prod_sector = [];
|
||||
|
||||
{
|
||||
if ((_x select 1) == _nearest_sector) exitWith {_prod_sector = _x};
|
||||
} forEach KP_liberation_production;
|
||||
|
@ -123,7 +130,7 @@ while {true} do {
|
|||
};
|
||||
};
|
||||
|
||||
if (_fobdistance < _distfob && alive player && vehicle player == player && (([ player, 3] call F_fetchPermission) || (player == ([] call F_getCommander) || [] call F_isAdmin))) then {
|
||||
if (_fobdistance < _distfob && alive player && vehicle player == player && (([3] call KPLIB_fnc_hasPermission) || _directAccess)) then {
|
||||
if (_idact_build == -1) then {
|
||||
_idact_build = player addAction ["<t color='#FFFF00'>" + localize "STR_BUILD_ACTION" + "</t> <img size='2' image='res\ui_build.paa'/>","scripts\client\build\open_build_menu.sqf","",-985,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -134,7 +141,7 @@ while {true} do {
|
|||
};
|
||||
};
|
||||
|
||||
if ((count _nearfobbox != 0) && (alive player) && (vehicle player == player) && !(surfaceIsWater getpos player) && ((player distance startbase) > 1000) && (([player, 3] call F_fetchPermission) || (player == ([] call F_getCommander) || [] call F_isAdmin)) && !FOB_build_in_progress) then {
|
||||
if ((count _nearfobbox != 0) && (alive player) && (vehicle player == player) && !(surfaceIsWater getpos player) && ((player distance startbase) > 1000) && (([3] call KPLIB_fnc_hasPermission) || _directAccess) && !FOB_build_in_progress) then {
|
||||
if (_idact_buildfob == -1) then {
|
||||
_idact_buildfob = player addAction ["<t color='#FFFF00'>" + localize "STR_FOB_ACTION" + "</t> <img size='2' image='res\ui_deployfob.paa'/>","scripts\client\build\do_build_fob.sqf","",-990,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -145,7 +152,7 @@ while {true} do {
|
|||
};
|
||||
};
|
||||
|
||||
if (_fobdistance < _distredeploy && alive player && vehicle player == player && (player == ([] call F_getCommander) || [] call F_isAdmin)) then {
|
||||
if (_fobdistance < _distredeploy && alive player && vehicle player == player && _directAccess) then {
|
||||
if (_idact_repackage == -1) then {
|
||||
_idact_repackage = player addAction ["<t color='#FFFF00'>" + localize "STR_FOB_REPACKAGE" + "</t> <img size='2' image='res\ui_deployfob.paa'/>","scripts\client\actions\do_repackage_fob.sqf","",-991,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -156,7 +163,7 @@ while {true} do {
|
|||
};
|
||||
};
|
||||
|
||||
if ((count GRLIB_all_fobs > 0) && (GRLIB_endgame == 0) && (_fobdistance < _distredeploy || (player distance startbase) < 200) && alive player && vehicle player == player && (([player, 5] call F_fetchPermission) || (player == ([] call F_getCommander) || [] call F_isAdmin))) then {
|
||||
if ((count GRLIB_all_fobs > 0) && (GRLIB_endgame == 0) && (_fobdistance < _distredeploy || (player distance startbase) < 200) && alive player && vehicle player == player && (([5] call KPLIB_fnc_hasPermission) || _directAccess)) then {
|
||||
if (_idact_secondary == -1) then {
|
||||
_idact_secondary = player addAction ["<t color='#FFFF00'>" + localize "STR_SECONDARY_OBJECTIVES" + "</t>","scripts\client\ui\secondary_ui.sqf","",-992,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -168,7 +175,7 @@ while {true} do {
|
|||
};
|
||||
|
||||
if ((count _prod_sector) == 12) then {
|
||||
if (alive player && vehicle player == player && ([player, 3] call F_fetchPermission) && ((count (_prod_sector select 3)) == 0)) then {
|
||||
if (alive player && vehicle player == player && ([3] call KPLIB_fnc_hasPermission || _directAccess) && ((count (_prod_sector select 3)) == 0)) then {
|
||||
if (_idact_sectorstorage == -1) then {
|
||||
_idact_sectorstorage = player addAction ["<t color='#FFFF00'>" + localize "STR_SECSTORAGEBUILD_ACTION" + "</t>","scripts\client\build\do_sector_build.sqf",[KP_liberation_small_storage_building, _prod_sector],-993,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -178,7 +185,7 @@ while {true} do {
|
|||
_idact_sectorstorage = -1;
|
||||
};
|
||||
};
|
||||
if (alive player && vehicle player == player && ([player, 3] call F_fetchPermission) && ((count (_prod_sector select 3)) == 3) && !(_prod_sector select 4)) then {
|
||||
if (alive player && vehicle player == player && ([3] call KPLIB_fnc_hasPermission || _directAccess) && ((count (_prod_sector select 3)) == 3) && !(_prod_sector select 4)) then {
|
||||
if (_idact_supplyfacility == -1) then {
|
||||
_idact_supplyfacility = player addAction ["<t color='#FFFF00'>" + localize "STR_SECSUPPLYBUILD_ACTION" + "</t>","scripts\client\build\do_sector_build.sqf",["supply", _prod_sector],-994,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -188,7 +195,7 @@ while {true} do {
|
|||
_idact_supplyfacility = -1;
|
||||
};
|
||||
};
|
||||
if (alive player && vehicle player == player && ([player, 3] call F_fetchPermission) && ((count (_prod_sector select 3)) == 3) && !(_prod_sector select 5)) then {
|
||||
if (alive player && vehicle player == player && ([3] call KPLIB_fnc_hasPermission || _directAccess) && ((count (_prod_sector select 3)) == 3) && !(_prod_sector select 5)) then {
|
||||
if (_idact_ammofacility == -1) then {
|
||||
_idact_ammofacility = player addAction ["<t color='#FFFF00'>" + localize "STR_SECAMMOBUILD_ACTION" + "</t>","scripts\client\build\do_sector_build.sqf",["ammo", _prod_sector],-995,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -198,7 +205,7 @@ while {true} do {
|
|||
_idact_ammofacility = -1;
|
||||
};
|
||||
};
|
||||
if (alive player && vehicle player == player && ([player, 3] call F_fetchPermission) && ((count (_prod_sector select 3)) == 3) && !(_prod_sector select 6)) then {
|
||||
if (alive player && vehicle player == player && ([3] call KPLIB_fnc_hasPermission || _directAccess) && ((count (_prod_sector select 3)) == 3) && !(_prod_sector select 6)) then {
|
||||
if (_idact_fuelfacility == -1) then {
|
||||
_idact_fuelfacility = player addAction ["<t color='#FFFF00'>" + localize "STR_SECFUELBUILD_ACTION" + "</t>","scripts\client\build\do_sector_build.sqf",["fuel", _prod_sector],-996,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -238,7 +245,7 @@ while {true} do {
|
|||
};
|
||||
};
|
||||
|
||||
if (((_fobdistance < _distfob) || ((count _prod_sector) == 12)) && (player == ([] call F_getCommander) || [] call F_isAdmin) && alive player && vehicle player == player && ((count KP_liberation_production) > 0)) then {
|
||||
if (((_fobdistance < _distfob) || ((count _prod_sector) == 12)) && _directAccess && alive player && vehicle player == player && ((count KP_liberation_production) > 0)) then {
|
||||
if (_idact_production == -1) then {
|
||||
_idact_production = player addAction ["<t color='#FF8000'>" + localize "STR_PRODUCTION_ACTION" + "</t>","scripts\client\commander\open_production.sqf","",-998,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -250,7 +257,7 @@ while {true} do {
|
|||
};
|
||||
|
||||
if (KP_liberation_ailogistics) then {
|
||||
if ((_fobdistance < _distfob) && (player == ([] call F_getCommander) || [] call F_isAdmin) && alive player && vehicle player == player && (((count GRLIB_all_fobs) + (count KP_liberation_production)) > 1)) then {
|
||||
if ((_fobdistance < _distfob) && _directAccess && alive player && vehicle player == player && (((count GRLIB_all_fobs) + (count KP_liberation_production)) > 1)) then {
|
||||
if (_idact_logistic == -1) then {
|
||||
_idact_logistic = player addAction ["<t color='#FF8000'>" + localize "STR_LOGISTIC_ACTION" + "</t>","scripts\client\commander\open_logistic.sqf","",-999,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -262,7 +269,7 @@ while {true} do {
|
|||
};
|
||||
};
|
||||
|
||||
if ((player == ([] call F_getCommander) || [] call F_isAdmin) && alive player && vehicle player == player && GRLIB_permissions_param) then {
|
||||
if (_directAccess && alive player && vehicle player == player && GRLIB_permissions_param) then {
|
||||
if (_idact_commander == -1) then {
|
||||
_idact_commander = player addAction ["<t color='#FF8000'>" + localize "STR_COMMANDER_ACTION" + "</t> <img size='2' image='\a3\Ui_F_Curator\Data\Displays\RscDisplayCurator\modeGroups_ca.paa'/>","scripts\client\commander\open_permissions.sqf","",-1001,false,true,"","build_confirmed == 0"];
|
||||
};
|
||||
|
@ -284,7 +291,7 @@ while {true} do {
|
|||
};
|
||||
};
|
||||
|
||||
if (_fobdistance < _distfob && alive player && vehicle player == player && (player == ([] call F_getCommander) || [] call F_isAdmin)) then {
|
||||
if (_fobdistance < _distfob && alive player && vehicle player == player && _directAccess) then {
|
||||
if (_idact_clearance == -1) then {
|
||||
_idact_clearance = player addAction [
|
||||
"<t color='#FFFF00'>" + localize "STR_CLEARANCE_ACTION" + "</t>",
|
||||
|
|
|
@ -4,7 +4,7 @@ _actionned_intel_items = [];
|
|||
|
||||
while { true } do {
|
||||
|
||||
if ( [ player, 5 ] call F_fetchPermission ) then {
|
||||
if ([5] call KPLIB_fnc_hasPermission) then {
|
||||
|
||||
_near_people = (getPosATL player) nearEntities [["Man"], 5];
|
||||
_near_intel = (getPosATL player) nearEntities [[GRLIB_intel_laptop, GRLIB_intel_file], 5];
|
||||
|
|
|
@ -80,8 +80,6 @@ while { dialog && (alive player) && edit_loadout == 0 } do {
|
|||
[player, [profileNamespace, _loaded_loadout]] call BIS_fnc_loadInventory;
|
||||
};
|
||||
|
||||
[player] call F_correctLaserBatteries;
|
||||
|
||||
if (KP_liberation_arsenalUsePreset) then {
|
||||
if ([_backpack] call F_checkGear) then {
|
||||
hint format [ localize "STR_HINT_LOADOUT_LOADED", _loaded_loadout param [0]];
|
||||
|
@ -97,7 +95,7 @@ while { dialog && (alive player) && edit_loadout == 0 } do {
|
|||
};
|
||||
|
||||
if ( respawn_loadout > 0 ) then {
|
||||
GRLIB_respawn_loadout = [ player, ["repetitive"] ] call F_getLoadout;
|
||||
GRLIB_respawn_loadout = [ player, ["repetitive"] ] call KPLIB_fnc_getLoadout;
|
||||
hint localize "STR_MAKE_RESPAWN_LOADOUT_HINT";
|
||||
respawn_loadout = 0;
|
||||
};
|
||||
|
@ -105,7 +103,7 @@ while { dialog && (alive player) && edit_loadout == 0 } do {
|
|||
if ( load_from_player >= 0 ) then {
|
||||
private _playerselected = ( _loadplayers select load_from_player ) select 1;
|
||||
if ( alive _playerselected ) then {
|
||||
[ player, [ _playerselected, ["repetitive"] ] call F_getLoadout ] call F_setLoadout;
|
||||
[player, [_playerselected, ["repetitive"]] call KPLIB_fnc_getLoadout] call F_setLoadout;
|
||||
hint format [ localize "STR_LOAD_PLAYER_LOADOUT_HINT", name _playerselected ];
|
||||
};
|
||||
load_from_player = -1;
|
||||
|
|
|
@ -21,7 +21,7 @@ while {true} do {
|
|||
waitUntil {sleep 1; count GRLIB_all_fobs > 0};
|
||||
waitUntil {sleep 2; (player distance ([] call F_getNearestFob)) < GRLIB_fob_range};
|
||||
|
||||
if ([player, 4] call F_fetchPermission) then {
|
||||
if ([4] call KPLIB_fnc_hasPermission) then {
|
||||
private _detected_vehicles = (getPos player) nearObjects veh_action_detect_distance select {
|
||||
(((typeof _x in _recycleable_classnames ) && (({alive _x} count (crew _x)) == 0 || (unitIsUAV _x)) && ((locked _x == 0 || locked _x == 1))) ||
|
||||
((typeOf _x) in _building_classnames) ||
|
||||
|
@ -29,7 +29,12 @@ while {true} do {
|
|||
((typeOf _x) in KP_liberation_upgrade_buildings) ||
|
||||
((typeOf _x) in KP_liberation_ace_crates)) &&
|
||||
(alive _x) &&
|
||||
((count(attachedObjects _x) == 0) || ((typeOf _x) == "rhsusf_mkvsoc")) &&
|
||||
(
|
||||
// ignore null objects left by Advanced Towing
|
||||
// see https://github.com/sethduda/AdvancedTowing/pull/46
|
||||
(((attachedObjects _x) select {!isNull _X}) isEqualTo [])
|
||||
|| ((typeOf _x) == "rhsusf_mkvsoc")
|
||||
) &&
|
||||
(_x distance startbase > 1000) &&
|
||||
(_x distance ( [] call F_getNearestFob) < GRLIB_fob_range) &&
|
||||
(getObjectType _x >= 8)
|
||||
|
|
|
@ -5,7 +5,7 @@ veh_action_distance = 10;
|
|||
|
||||
while { true } do {
|
||||
|
||||
if ( [ player, 5 ] call F_fetchPermission ) then {
|
||||
if (5] call KPLIB_fnc_hasPermission) then {
|
||||
|
||||
_detected_vehicles = ((getpos player) nearEntities [["Tank","APC","IFV","Car"], veh_action_distance]) select {
|
||||
(count crew _x) == 0 &&
|
||||
|
|
|
@ -12,7 +12,7 @@ _managed_areas = [];
|
|||
|
||||
while {true} do {
|
||||
|
||||
if ([player, 5] call F_fetchPermission) then {
|
||||
if ([5] call KPLIB_fnc_hasPermission) then {
|
||||
|
||||
_nearammoboxes = ((getpos player) nearEntities [KP_liberation_crates,10]);
|
||||
_neartransporttrucks = ((getpos player) nearEntities [ammobox_transports_typenames,10]);
|
||||
|
@ -77,7 +77,7 @@ while {true} do {
|
|||
_next_box removeAction (_next_box getVariable ["KP_crate_push_action", -1]);
|
||||
}
|
||||
} foreach _managed_boxes;
|
||||
|
||||
|
||||
_checked_areas = [];
|
||||
|
||||
{
|
||||
|
|
|
@ -7,7 +7,7 @@ if (((_this select 3) select 0) == KP_liberation_small_storage_building) then {
|
|||
build_confirmed = 1;
|
||||
build_invalid = 0;
|
||||
KP_vector = true;
|
||||
|
||||
|
||||
_sectorpos = getMarkerPos ([GRLIB_fob_range] call F_getNearestSector);
|
||||
|
||||
_idactcancel = player addAction ["<t color='#B0FF00'>" + localize "STR_CANCEL" + "</t> <img size='2' image='res\ui_cancel.paa'/>",{build_confirmed = 3;},"",-725,false,true,"","build_confirmed == 1"];
|
||||
|
@ -36,7 +36,7 @@ if (((_this select 3) select 0) == KP_liberation_small_storage_building) then {
|
|||
if ((surfaceIsWater _truepos) || (surfaceIsWater getpos player) || ((_truepos distance _sectorpos) > GRLIB_fob_range)) then {
|
||||
_building setpos _ghost_spot;
|
||||
build_invalid = 1;
|
||||
|
||||
|
||||
if(((surfaceIsWater _truepos) || (surfaceIsWater getpos player))) then {
|
||||
GRLIB_ui_notif = localize "STR_BUILD_ERROR_WATER";
|
||||
};
|
||||
|
@ -54,12 +54,18 @@ if (((_this select 3) select 0) == KP_liberation_small_storage_building) then {
|
|||
_building setVectorUp surfaceNormal position _building;
|
||||
};
|
||||
|
||||
if (build_invalid == 1) then {
|
||||
GRLIB_ui_notif = "";
|
||||
};
|
||||
|
||||
build_invalid = 0;
|
||||
};
|
||||
|
||||
sleep 0.05;
|
||||
};
|
||||
|
||||
|
||||
GRLIB_ui_notif = "";
|
||||
|
||||
if (!alive player || build_confirmed == 3) then {
|
||||
deleteVehicle _building;
|
||||
};
|
||||
|
@ -90,7 +96,7 @@ if (((_this select 3) select 0) == KP_liberation_small_storage_building) then {
|
|||
player removeAction _idactcancel;
|
||||
player removeAction _idactplace;
|
||||
player removeAction _idactvector;
|
||||
|
||||
|
||||
remoteExec ["check_sector_ress_remote_call",2];
|
||||
|
||||
build_confirmed = 0;
|
||||
|
|
|
@ -7,7 +7,7 @@ private [ "_commanderobj", "_tagmatch", "_idmatch", "_namematch" ];
|
|||
waitUntil { alive player };
|
||||
sleep 1;
|
||||
|
||||
_commanderobj = [] call F_getCommander;
|
||||
_commanderobj = [] call KPLIB_fnc_getCommander;
|
||||
if ( !isNull _commanderobj ) then {
|
||||
if ( player == _commanderobj && !([] call F_isAdmin)) then {
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ while {true} do {
|
|||
};
|
||||
|
||||
if (KP_liberation_mobilerespawn) then {
|
||||
private _respawn_trucks = [] call F_getMobileRespawns;
|
||||
private _respawn_trucks = [] call KPLIB_fnc_getMobileRespawns;
|
||||
|
||||
if (count _markers_mobilespawns != count _respawn_trucks) then {
|
||||
{deleteMarkerLocal _x;} forEach _markers_mobilespawns;
|
||||
|
|
|
@ -18,7 +18,7 @@ while { true } do {
|
|||
(count units _x > 0) && (side _x == GRLIB_side_friendly && (((leader _x) distance (getmarkerpos GRLIB_respawn_marker) > 100) && ((leader _x) distance startbase > 500))))) then {
|
||||
clearGroupIcons _x;
|
||||
_localgroup = _x;
|
||||
_grouptype = [_localgroup] call F_getGroupType;
|
||||
_grouptype = [_localgroup] call KPLIB_fnc_getGroupType;
|
||||
_groupicon = "";
|
||||
switch (_grouptype) do {
|
||||
case "infantry": { _groupicon = "b_inf" };
|
||||
|
|
|
@ -14,7 +14,7 @@ private _permissibleVehicles = [
|
|||
private _permissionIdx = _permissibleVehicles findIf {_vehicleClass in (_x select 0)};
|
||||
if (_permissionIdx isEqualTo -1) exitWith {};
|
||||
|
||||
if !([player, _permissionIdx] call F_fetchPermission) exitWith {
|
||||
if !([_permissionIdx] call KPLIB_fnc_hasPermission) exitWith {
|
||||
moveOut player;
|
||||
hint localize (_permissibleVehicles select _permissionIdx select 1);
|
||||
};
|
||||
|
|
|
@ -5,7 +5,7 @@ if ( isNil "sector_timer" ) then { sector_timer = 0 };
|
|||
params [ "_fob", "_status" ];
|
||||
private [ "_fobname" ];
|
||||
|
||||
_fobname = [ _fob ] call F_getFobName;
|
||||
_fobname = [_fob] call KPLIB_fnc_getFobName;
|
||||
|
||||
if ( _status == 0 ) then {
|
||||
[ "lib_fob_built", [ _fobname ] ] call BIS_fnc_showNotification;
|
||||
|
@ -27,4 +27,4 @@ if ( _status == 3 ) then {
|
|||
[ "lib_fob_safe", [ _fobname ] ] call BIS_fnc_showNotification;
|
||||
"opfor_capture_marker" setMarkerPosLocal markers_reset;
|
||||
sector_timer = 0;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -9,7 +9,7 @@ if ( time > GRLIB_last_incoming_notif_time + 60 ) then {
|
|||
GRLIB_last_incoming_notif_time = time;
|
||||
|
||||
private [ "_attack_location_name" ];
|
||||
_attack_location_name = [ _attack_destination ] call F_getLocationName;
|
||||
_attack_location_name = [_attack_destination] call KPLIB_fnc_getLocationName;
|
||||
|
||||
[ "lib_incoming", [ _attack_location_name ] ] call BIS_fnc_showNotification;
|
||||
|
||||
|
@ -20,4 +20,4 @@ if ( time > GRLIB_last_incoming_notif_time + 60 ) then {
|
|||
|
||||
sleep 250;
|
||||
deleteMarkerLocal _mrk;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -92,7 +92,7 @@ while {true} do {
|
|||
|
||||
if (KP_liberation_mobilerespawn) then {
|
||||
if (KP_liberation_respawn_time <= time) then {
|
||||
private _respawn_trucks = call F_getMobileRespawns;
|
||||
private _respawn_trucks = [] call KPLIB_fnc_getMobileRespawns;
|
||||
|
||||
for [ {_idx=0},{_idx < count _respawn_trucks},{_idx=_idx+1} ] do {
|
||||
choiceslist = choiceslist + [[format ["%1 - %2", localize "STR_RESPAWN_TRUCK",mapGridPosition (getposATL (_respawn_trucks select _idx))],getposATL (_respawn_trucks select _idx),(_respawn_trucks select _idx)]];
|
||||
|
|
|
@ -67,7 +67,7 @@ while { dialog && alive player && dostartsecondary == 0 } do {
|
|||
|
||||
if ( dostartsecondary == 1 ) then {
|
||||
private _index = lbCurSel 101;
|
||||
if !([2000,999999,false] call F_findOpforSpawnPoint isEqualTo "") then {
|
||||
if !(([2000,999999,false] call KPLIB_fnc_getOpforSpawnPoint) isEqualTo "") then {
|
||||
[_index] remoteExec ["start_secondary_remote_call", 2];
|
||||
} else {
|
||||
hint "There is not enough enemy territory left for secondary missions.";
|
||||
|
|
|
@ -101,7 +101,7 @@ while { true } do {
|
|||
KP_liberation_ammo = KP_liberation_ammo_global;
|
||||
KP_liberation_fuel = KP_liberation_fuel_global;
|
||||
} else {
|
||||
_resource_area = toUpper ([_nearfob] call F_getFobName);
|
||||
_resource_area = toUpper ([_nearfob] call KPLIB_fnc_getFobName);
|
||||
KP_liberation_supplies = ((_actual_fob select 0) select 1);
|
||||
KP_liberation_ammo = ((_actual_fob select 0) select 2);
|
||||
KP_liberation_fuel = ((_actual_fob select 0) select 3);
|
||||
|
@ -125,7 +125,7 @@ while { true } do {
|
|||
if ((getmarkerpos "opfor_capture_marker") distance markers_reset > 100 ) then {
|
||||
|
||||
private [ "_attacked_string" ];
|
||||
_attacked_string = [ markerpos "opfor_capture_marker" ] call F_getLocationName;
|
||||
_attacked_string = [markerpos "opfor_capture_marker"] call KPLIB_fnc_getLocationName;
|
||||
|
||||
((uiNamespace getVariable 'GUI_OVERLAY') displayCtrl (401)) ctrlShow true;
|
||||
((uiNamespace getVariable 'GUI_OVERLAY') displayCtrl (402)) ctrlSetText _attacked_string;
|
||||
|
@ -216,7 +216,7 @@ while { true } do {
|
|||
if ( [ markerpos _nearest_active_sector, _zone_size ] call F_sectorOwnership == GRLIB_side_resistance ) then { _colorzone = "ColorCivilian" };
|
||||
"zone_capture" setmarkercolorlocal _colorzone;
|
||||
|
||||
_ratio = [_nearest_active_sector] call F_getForceRatio;
|
||||
_ratio = [_nearest_active_sector] call KPLIB_fnc_getForceRatio;
|
||||
_barwidth = 0.084 * safezoneW * _ratio;
|
||||
_bar = (uiNamespace getVariable 'GUI_OVERLAY') displayCtrl (244);
|
||||
_bar ctrlSetPosition [(ctrlPosition _bar) select 0,(ctrlPosition _bar) select 1,_barwidth,(ctrlPosition _bar) select 3];
|
||||
|
|
|
@ -1,54 +1,53 @@
|
|||
_grp = _this select 0;
|
||||
_infantry = false;
|
||||
params [
|
||||
["_grp", grpNull, [grpNull]]
|
||||
];
|
||||
|
||||
if ( count _this == 2 ) then {
|
||||
_infantry = true;
|
||||
if (isNull _grp) exitWith {};
|
||||
if (isNil "reset_battlegroups_ai") then {reset_battlegroups_ai = false};
|
||||
|
||||
sleep (5 + (random 5));
|
||||
|
||||
private _objPos = ([getPos (leader _grp)] call F_getNearestBluforObjective) select 0;
|
||||
|
||||
[_objPos] remoteExec ["remote_call_incoming"];
|
||||
|
||||
private _startpos = getPos (leader _grp);
|
||||
|
||||
private _waypoint = [];
|
||||
while {((getPos (leader _grp)) distance _startpos) < 100} do {
|
||||
|
||||
while {!((waypoints _grp) isEqualTo [])} do {deleteWaypoint ((waypoints _grp) select 0);};
|
||||
{_x doFollow leader _grp} forEach units _grp;
|
||||
|
||||
_startpos = getPos (leader _grp);
|
||||
|
||||
_waypoint = _grp addWaypoint [_objPos, 100];
|
||||
_waypoint setWaypointType "MOVE";
|
||||
_waypoint setWaypointSpeed "NORMAL";
|
||||
_waypoint setWaypointBehaviour "SAFE";
|
||||
_waypoint setWaypointCombatMode "YELLOW";
|
||||
_waypoint setWaypointCompletionRadius 30;
|
||||
|
||||
_waypoint = _grp addWaypoint [_objPos, 100];
|
||||
_waypoint setWaypointType "SAD";
|
||||
_waypoint = _grp addWaypoint [_objPos, 100];
|
||||
_waypoint setWaypointType "SAD";
|
||||
_waypoint = _grp addWaypoint [_objPos, 100];
|
||||
_waypoint setWaypointType "SAD";
|
||||
_waypoint = _grp addWaypoint [_objPos, 100];
|
||||
_waypoint setWaypointType "CYCLE";
|
||||
|
||||
sleep 90;
|
||||
};
|
||||
|
||||
if (isNil "reset_battlegroups_ai" ) then { reset_battlegroups_ai = false };
|
||||
waitUntil {
|
||||
sleep 5;
|
||||
(((units _grp) select {alive _x}) isEqualTo []) || reset_battlegroups_ai
|
||||
};
|
||||
|
||||
sleep (3 + (random 3));
|
||||
sleep (5 + (random 5));
|
||||
reset_battlegroups_ai = false;
|
||||
|
||||
while { ( count units _grp != 0 ) && ( GRLIB_endgame == 0 ) } do {
|
||||
|
||||
sleep (5 + (random 5));
|
||||
|
||||
private _objectivepos = ([getpos (leader _grp)] call F_getNearestBluforObjective) select 0;
|
||||
|
||||
[_objectivepos] remoteExec ["remote_call_incoming"];
|
||||
|
||||
private _startpos = getpos (leader _grp);
|
||||
|
||||
while { ((getpos (leader _grp)) distance _startpos) < 100 } do {
|
||||
|
||||
while {(count (waypoints _grp)) != 0} do {deleteWaypoint ((waypoints _grp) select 0);};
|
||||
{_x doFollow leader _grp} foreach units _grp;
|
||||
|
||||
_startpos = getpos (leader _grp);
|
||||
|
||||
private _waypoint = _grp addWaypoint [_objectivepos, 100];
|
||||
_waypoint setWaypointType "MOVE";
|
||||
_waypoint setWaypointSpeed "NORMAL";
|
||||
_waypoint setWaypointBehaviour "SAFE";
|
||||
_waypoint setWaypointCombatMode "YELLOW";
|
||||
_waypoint setWaypointCompletionRadius 30;
|
||||
|
||||
_waypoint = _grp addWaypoint [_objectivepos, 100];
|
||||
_waypoint setWaypointType "SAD";
|
||||
_waypoint = _grp addWaypoint [_objectivepos, 100];
|
||||
_waypoint setWaypointType "SAD";
|
||||
_waypoint = _grp addWaypoint [_objectivepos, 100];
|
||||
_waypoint setWaypointType "SAD";
|
||||
_waypoint = _grp addWaypoint [_objectivepos, 100];
|
||||
_waypoint setWaypointType "CYCLE";
|
||||
|
||||
sleep 180;
|
||||
};
|
||||
|
||||
waitUntil {
|
||||
sleep 5;
|
||||
( { alive _x } count (units _grp) == 0) || reset_battlegroups_ai;
|
||||
};
|
||||
sleep (5 + (random 5));
|
||||
reset_battlegroups_ai = false;
|
||||
};
|
||||
if (!((units _grp) isEqualTo []) && (GRLIB_endgame == 0)) then {
|
||||
[_grp] spawn battlegroup_ai;
|
||||
};
|
||||
|
|
|
@ -10,7 +10,7 @@ private _range = 40;
|
|||
while {_move_is_disabled && local _unit && alive _unit && !(captive _unit)} do {
|
||||
|
||||
if !(_sector isEqualTo "") then {
|
||||
_ratio = [_sector] call F_getForceRatio;
|
||||
_ratio = [_sector] call KPLIB_fnc_getForceRatio;
|
||||
};
|
||||
|
||||
_range = floor (linearConversion [0, 1, _ratio, 0, GRLIB_capture_size / 3 * 2, true]);
|
||||
|
|
|
@ -1,65 +1,74 @@
|
|||
_troup_transport = _this select 0;
|
||||
_transport_group = (group (driver _troup_transport));
|
||||
_start_pos = getpos _troup_transport;
|
||||
_dat_objective = ([getpos _troup_transport] call F_getNearestBluforObjective) select 0;
|
||||
_unload_distance = 1000;
|
||||
params [
|
||||
["_transVeh", objNull, [objNull]]
|
||||
];
|
||||
|
||||
if (isNull _transVeh) exitWith {};
|
||||
sleep 1;
|
||||
_initial_crewcount = count crew _troup_transport;
|
||||
|
||||
waitUntil { sleep 0.2; !(alive _troup_transport) || !(alive (driver _troup_transport)) || (((_troup_transport distance _dat_objective) < _unload_distance) && (!(surfaceIsWater (getpos _troup_transport)))) };
|
||||
private _transGrp = (group (driver _transVeh));
|
||||
private _start_pos = getpos _transVeh;
|
||||
private _objPos = ([getpos _transVeh] call F_getNearestBluforObjective) select 0;
|
||||
private _unload_distance = 500;
|
||||
private _crewcount = count crew _transVeh;
|
||||
|
||||
if ((alive _troup_transport) && (alive (driver _troup_transport))) then {
|
||||
_troupgrp = createGroup [GRLIB_side_enemy, true];
|
||||
waitUntil {
|
||||
sleep 0.2;
|
||||
!(alive _transVeh) ||
|
||||
!(alive (driver _transVeh)) ||
|
||||
(((_transVeh distance _objPos) < _unload_distance) && !(surfaceIsWater (getpos _transVeh)))
|
||||
};
|
||||
|
||||
while {(count (waypoints _troupgrp)) != 0} do {deleteWaypoint ((waypoints _troupgrp) select 0);};
|
||||
if ((alive _transVeh) && (alive (driver _transVeh))) then {
|
||||
_infGrp = createGroup [GRLIB_side_enemy, true];
|
||||
|
||||
{
|
||||
_x createUnit [_start_pos, _troupgrp,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
} foreach (["army"] call F_getAdaptiveSquadComp);
|
||||
{
|
||||
[_x, _start_pos, _infGrp, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
} foreach ([] call KPLIB_fnc_getSquadComp);
|
||||
|
||||
{ _x moveInCargo _troup_transport } foreach (units _troupgrp);
|
||||
while {(count (waypoints _troupgrp)) != 0} do {deleteWaypoint ((waypoints _troupgrp) select 0);};
|
||||
{_x moveInCargo _transVeh} forEach (units _infGrp);
|
||||
|
||||
sleep 3;
|
||||
while {(count (waypoints _infGrp)) != 0} do {deleteWaypoint ((waypoints _infGrp) select 0);};
|
||||
|
||||
_transport_waypoint = _transport_group addWaypoint [getpos _troup_transport, 0,0];
|
||||
_transport_waypoint setWaypointType "TR UNLOAD";
|
||||
_transport_waypoint setWaypointCompletionRadius 200;
|
||||
sleep 3;
|
||||
|
||||
_troops_waypoint = _troupgrp addWaypoint [getpos _troup_transport, 0];
|
||||
_troops_waypoint setWaypointType "GETOUT";
|
||||
_troops_waypoint setWaypointCompletionRadius 200;
|
||||
private _transVehWp = _transGrp addWaypoint [getpos _transVeh, 0,0];
|
||||
_transVehWp setWaypointType "TR UNLOAD";
|
||||
_transVehWp setWaypointCompletionRadius 200;
|
||||
|
||||
_troops_waypoint synchronizeWaypoint [_transport_waypoint];
|
||||
private _infWp = _infGrp addWaypoint [getpos _transVeh, 0];
|
||||
_infWp setWaypointType "GETOUT";
|
||||
_infWp setWaypointCompletionRadius 200;
|
||||
|
||||
{ unassignVehicle _troup_transport } forEach (units _troupgrp);
|
||||
_troupgrp leaveVehicle _troup_transport;
|
||||
(units _troupgrp) allowGetIn false;
|
||||
_infWp synchronizeWaypoint [_transVehWp];
|
||||
|
||||
_troops_waypoint_2 = _troupgrp addWaypoint [getpos _troup_transport, 250];
|
||||
_troops_waypoint_2 setWaypointType "MOVE";
|
||||
_troops_waypoint_2 setWaypointCompletionRadius 5;
|
||||
{unassignVehicle _transVeh} forEach (units _infGrp);
|
||||
_infGrp leaveVehicle _transVeh;
|
||||
(units _infGrp) allowGetIn false;
|
||||
|
||||
waitUntil { sleep 0.3; _initial_crewcount >= count crew _troup_transport };
|
||||
private _infWp_2 = _infGrp addWaypoint [getpos _transVeh, 250];
|
||||
_infWp_2 setWaypointType "MOVE";
|
||||
_infWp_2 setWaypointCompletionRadius 5;
|
||||
|
||||
sleep 5;
|
||||
waitUntil {sleep 0.5; _crewcount >= count crew _transVeh};
|
||||
|
||||
while {(count (waypoints _transport_group)) != 0} do {deleteWaypoint ((waypoints _transport_group) select 0);};
|
||||
sleep 5;
|
||||
|
||||
_waypoint2 = _transport_group addWaypoint [_dat_objective, 100];
|
||||
_waypoint2 setWaypointType "SAD";
|
||||
_waypoint2 setWaypointSpeed "NORMAL";
|
||||
_waypoint2 setWaypointBehaviour "COMBAT";
|
||||
_waypoint2 setWaypointCombatMode "RED";
|
||||
_waypoint2 setWaypointCompletionRadius 30;
|
||||
while {(count (waypoints _transGrp)) != 0} do {deleteWaypoint ((waypoints _transGrp) select 0);};
|
||||
|
||||
_waypoint2 = _transport_group addWaypoint [_dat_objective, 100];
|
||||
_waypoint2 setWaypointType "SAD";
|
||||
_transVehWp = _transGrp addWaypoint [_objPos, 100];
|
||||
_transVehWp setWaypointType "SAD";
|
||||
_transVehWp setWaypointSpeed "NORMAL";
|
||||
_transVehWp setWaypointBehaviour "COMBAT";
|
||||
_transVehWp setWaypointCombatMode "RED";
|
||||
_transVehWp setWaypointCompletionRadius 30;
|
||||
|
||||
_waypoint2 = _transport_group addWaypoint [_dat_objective, 100];
|
||||
_waypoint2 setWaypointType "CYCLE";
|
||||
_transVehWp = _transGrp addWaypoint [_objPos, 100];
|
||||
_transVehWp setWaypointType "SAD";
|
||||
|
||||
sleep 10;
|
||||
_transVehWp = _transGrp addWaypoint [_objPos, 100];
|
||||
_transVehWp setWaypointType "CYCLE";
|
||||
|
||||
[_troupgrp, true] spawn battlegroup_ai;
|
||||
};
|
||||
sleep 10;
|
||||
|
||||
[_infGrp] spawn battlegroup_ai;
|
||||
};
|
||||
|
|
|
@ -8,7 +8,7 @@ sleep 1800;
|
|||
|
||||
while { GRLIB_csat_aggressivity >= 0.9 && GRLIB_endgame == 0 } do {
|
||||
|
||||
_sleeptime = (1800 + (random 1800)) / (([] call F_adaptiveOpforFactor) * GRLIB_csat_aggressivity);
|
||||
_sleeptime = (1800 + (random 1800)) / (([] call KPLIB_fnc_getOpforFactor) * GRLIB_csat_aggressivity);
|
||||
|
||||
if ( combat_readiness >= 80 ) then { _sleeptime = _sleeptime * 0.75 };
|
||||
if ( combat_readiness >= 90 ) then { _sleeptime = _sleeptime * 0.75 };
|
||||
|
@ -43,4 +43,4 @@ while { GRLIB_csat_aggressivity >= 0.9 && GRLIB_endgame == 0 } do {
|
|||
[ _target_pos ] spawn spawn_air;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,22 +1,29 @@
|
|||
private [ "_sleeptime", "_countplayers" ];
|
||||
private ["_sleeptime"];
|
||||
|
||||
sleep ( 900 / GRLIB_csat_aggressivity );
|
||||
uiSleep (900 / GRLIB_csat_aggressivity);
|
||||
while {GRLIB_csat_aggressivity > 0.9 && GRLIB_endgame == 0} do {
|
||||
|
||||
while { GRLIB_csat_aggressivity > 0.9 && GRLIB_endgame == 0 } do {
|
||||
_sleeptime = (2100 + (random 2100)) / (([] call KPLIB_fnc_getOpforFactor) * GRLIB_csat_aggressivity);
|
||||
|
||||
_sleeptime = (2100 + (random 2100)) / (([] call F_adaptiveOpforFactor) * GRLIB_csat_aggressivity);
|
||||
if (combat_readiness >= 80) then {_sleeptime = _sleeptime * 0.75};
|
||||
if (combat_readiness >= 90) then {_sleeptime = _sleeptime * 0.75};
|
||||
if (combat_readiness >= 95) then {_sleeptime = _sleeptime * 0.75};
|
||||
|
||||
if ( combat_readiness >= 80 ) then { _sleeptime = _sleeptime * 0.75 };
|
||||
if ( combat_readiness >= 90 ) then { _sleeptime = _sleeptime * 0.75 };
|
||||
if ( combat_readiness >= 95 ) then { _sleeptime = _sleeptime * 0.75 };
|
||||
uiSleep _sleeptime;
|
||||
|
||||
sleep _sleeptime;
|
||||
if (!isNil "GRLIB_last_battlegroup_time") then {
|
||||
waitUntil {
|
||||
uiSleep 5;
|
||||
diag_tickTime > (GRLIB_last_battlegroup_time + (2100 / GRLIB_csat_aggressivity))
|
||||
};
|
||||
};
|
||||
|
||||
if ( !isNil "GRLIB_last_battlegroup_time" ) then {
|
||||
waitUntil { sleep 5; time > ( GRLIB_last_battlegroup_time + ( 2100 / GRLIB_csat_aggressivity ) ) };
|
||||
};
|
||||
|
||||
if ((count (allPlayers - entities "HeadlessClient_F") >= (10 / GRLIB_csat_aggressivity)) && ([] call F_opforCap < GRLIB_battlegroup_cap) && (combat_readiness >= 70) && (diag_fps > 15.0)) then {
|
||||
[] spawn spawn_battlegroup;
|
||||
};
|
||||
if (
|
||||
(count (allPlayers - entities "HeadlessClient_F") >= (10 / GRLIB_csat_aggressivity)) &&
|
||||
([] call F_opforCap < GRLIB_battlegroup_cap) &&
|
||||
(combat_readiness >= 70) &&
|
||||
(diag_fps > 15.0)
|
||||
) then {
|
||||
[] spawn spawn_battlegroup;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,74 +1,78 @@
|
|||
if ( GRLIB_endgame == 1 ) exitWith {};
|
||||
params [
|
||||
["_spawn_marker", "", [""]]
|
||||
];
|
||||
|
||||
private [ "_bg_groups", "_target_size", "_vehicle_pool" ];
|
||||
_bg_groups = [];
|
||||
if (GRLIB_endgame == 1) exitWith {};
|
||||
|
||||
last_battlegroup_size = 0;
|
||||
_spawn_marker = "";
|
||||
if ( count _this == 1 ) then {
|
||||
_spawn_marker = [ 2000, 10000, false, _this select 0 ] call F_findOpforSpawnPoint;
|
||||
if !(_spawn_marker isEqualTo "") then {
|
||||
_spawn_marker = [2000, 10000, false, _spawn_marker] call KPLIB_fnc_getOpforSpawnPoint;
|
||||
} else {
|
||||
_spawn_marker = [ 2000, 10000, false ] call F_findOpforSpawnPoint;
|
||||
_spawn_marker = [2000, 10000, false] call KPLIB_fnc_getOpforSpawnPoint;
|
||||
};
|
||||
|
||||
if !(_spawn_marker isEqualTo "") then {
|
||||
|
||||
_vehicle_pool = opfor_battlegroup_vehicles;
|
||||
if ( combat_readiness < 50 ) then {
|
||||
_vehicle_pool = opfor_battlegroup_vehicles_low_intensity;
|
||||
};
|
||||
GRLIB_last_battlegroup_time = diag_tickTime;
|
||||
|
||||
if ( _spawn_marker != "" ) then {
|
||||
private _bg_groups = [];
|
||||
private _battlegroup_size = 0;
|
||||
private _vehicle_pool = [opfor_battlegroup_vehicles, opfor_battlegroup_vehicles_low_intensity] select (combat_readiness < 50);
|
||||
private _selected_opfor_battlegroup = [];
|
||||
|
||||
GRLIB_last_battlegroup_time = time;
|
||||
private _target_size = GRLIB_battlegroup_size * ([] call KPLIB_fnc_getOpforFactor) * (sqrt GRLIB_csat_aggressivity);
|
||||
if (_target_size >= 16) then {_target_size = 16;};
|
||||
if (combat_readiness < 60) then {_target_size = round (_target_size * 0.65);};
|
||||
|
||||
_selected_opfor_battlegroup = [];
|
||||
_target_size = GRLIB_battlegroup_size * ([] call F_adaptiveOpforFactor) * (sqrt GRLIB_csat_aggressivity);
|
||||
if ( _target_size >= 16 ) then { _target_size = 16; };
|
||||
if ( combat_readiness < 60 ) then { _target_size = round (_target_size * 0.65) };
|
||||
while { count _selected_opfor_battlegroup < _target_size } do {
|
||||
_selected_opfor_battlegroup pushback (selectRandom _vehicle_pool);
|
||||
};
|
||||
while {count _selected_opfor_battlegroup < _target_size} do {
|
||||
_selected_opfor_battlegroup pushback (selectRandom _vehicle_pool);
|
||||
};
|
||||
|
||||
[_spawn_marker] remoteExec ["remote_call_battlegroup"];
|
||||
[_spawn_marker] remoteExec ["remote_call_battlegroup"];
|
||||
|
||||
if (worldName in KP_liberation_battlegroup_clearance) then {
|
||||
[markerpos _spawn_marker, 15] call F_createClearance;
|
||||
};
|
||||
|
||||
{
|
||||
_nextgrp = createGroup [GRLIB_side_enemy, true];
|
||||
_vehicle = [markerpos _spawn_marker, _x] call F_libSpawnVehicle;
|
||||
sleep 0.5;
|
||||
(crew _vehicle) joinSilent _nextgrp;
|
||||
[_nextgrp] spawn battlegroup_ai;
|
||||
_bg_groups pushback _nextgrp;
|
||||
if ( ( _x in opfor_troup_transports ) && ( [] call F_opforCap < GRLIB_battlegroup_cap ) ) then {
|
||||
[_vehicle] spawn troup_transport;
|
||||
};
|
||||
last_battlegroup_size = last_battlegroup_size + 1;
|
||||
} foreach _selected_opfor_battlegroup;
|
||||
private ["_nextgrp", "_vehicle"];
|
||||
{
|
||||
_nextgrp = createGroup [GRLIB_side_enemy, true];
|
||||
_vehicle = [markerpos _spawn_marker, _x] call F_libSpawnVehicle;
|
||||
|
||||
if ( GRLIB_csat_aggressivity > 0.9 ) then {
|
||||
[([markerpos _spawn_marker] call F_getNearestBluforObjective) select 0] spawn spawn_air;
|
||||
};
|
||||
sleep 0.5;
|
||||
|
||||
sleep 5;
|
||||
(crew _vehicle) joinSilent _nextgrp;
|
||||
[_nextgrp] spawn battlegroup_ai;
|
||||
_bg_groups pushback _nextgrp;
|
||||
|
||||
combat_readiness = combat_readiness - (round ((last_battlegroup_size / 2) + (random (last_battlegroup_size / 2))));
|
||||
if ( combat_readiness < 0 ) then { combat_readiness = 0 };
|
||||
if ((_x in opfor_troup_transports) && ([] call F_opforCap < GRLIB_battlegroup_cap)) then {
|
||||
if (_vehicle isKindOf "Air") then {
|
||||
[([markerPos _spawn_marker] call F_getNearestBluforObjective) select 0, _vehicle] spawn send_paratroopers;
|
||||
} else {
|
||||
[_vehicle] spawn troup_transport;
|
||||
};
|
||||
};
|
||||
|
||||
stats_hostile_battlegroups = stats_hostile_battlegroups + 1;
|
||||
_battlegroup_size = _battlegroup_size + 1;
|
||||
} forEach _selected_opfor_battlegroup;
|
||||
|
||||
{
|
||||
if ( local _x ) then {
|
||||
_headless_client = [] call F_lessLoadedHC;
|
||||
if ( !isNull _headless_client ) then {
|
||||
_x setGroupOwner ( owner _headless_client );
|
||||
};
|
||||
};
|
||||
sleep 3;
|
||||
if (GRLIB_csat_aggressivity > 0.9) then {
|
||||
[([markerpos _spawn_marker] call F_getNearestBluforObjective) select 0] spawn spawn_air;
|
||||
};
|
||||
|
||||
} foreach _bg_groups;
|
||||
sleep 5;
|
||||
|
||||
combat_readiness = combat_readiness - (round ((_battlegroup_size / 2) + (random (_battlegroup_size / 2))));
|
||||
if (combat_readiness < 0) then {combat_readiness = 0};
|
||||
|
||||
stats_hostile_battlegroups = stats_hostile_battlegroups + 1;
|
||||
|
||||
{
|
||||
if (local _x) then {
|
||||
_headless_client = [] call F_lessLoadedHC;
|
||||
if (!isNull _headless_client) then {
|
||||
_x setGroupOwner (owner _headless_client);
|
||||
};
|
||||
};
|
||||
sleep 3;
|
||||
} forEach _bg_groups;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -20,10 +20,9 @@ while {true} do {
|
|||
private _house = (nearestObjects [[((getMarkerPos _sector select 0) - 100 + (random 200)), ((getMarkerPos _sector select 1) - 100 + (random 200))],["House", "Building"], 100]) select 0;
|
||||
|
||||
private _grp = createGroup [GRLIB_side_civilian, true];
|
||||
private _informant = _grp createUnit [(selectRandom civilians), getMarkerPos _sector, [], 0, "NONE"];
|
||||
private _informant = [selectRandom civilians, getMarkerPos _sector, _grp] call F_createManagedUnit;
|
||||
private _waiting_time = KP_liberation_civinfo_duration;
|
||||
|
||||
_informant addMPEventHandler ["MPKilled", {_this spawn kill_manager}];
|
||||
_informant setPos (selectRandom (_house buildingPos -1));
|
||||
_informant setUnitPos "UP";
|
||||
sleep 1;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
if (KP_liberation_civinfo_debug > 0) then {private _text = format ["[KP LIBERATION] [CIVINFO] civinfo_task.sqf spawned on: %1", debug_source];_text remoteExec ["diag_log",2];};
|
||||
|
||||
private _spawn_marker = [2000,999999,false] call F_findOpforSpawnPoint;
|
||||
private _spawn_marker = [2000,999999,false] call KPLIB_fnc_getOpforSpawnPoint;
|
||||
private _roadObj = [markerPos _spawn_marker, 400, []] call BIS_fnc_nearestRoad;
|
||||
|
||||
if (isNull _roadObj) exitWith {if (KP_liberation_civinfo_debug > 0) then {private _text = "[KP LIBERATION] [CIVINFO] civinfo_task.sqf -> no road found";_text remoteExec ["diag_log",2];};};
|
||||
|
@ -14,9 +14,10 @@ _veh setDir (getDir _roadObj);
|
|||
} forEach ((getAllHitPointsDamage _veh) select 0);
|
||||
|
||||
private _grp = createGroup [GRLIB_side_enemy, true];
|
||||
private _hvt = _grp createUnit [opfor_officer, getPos _roadObj, [], 30, "NONE"];
|
||||
private _hvt = [opfor_officer, getPos _roadObj, _grp, "CAPTAIN", 30] call F_createManagedUnit;
|
||||
|
||||
for "_i" from 1 to 4 do {
|
||||
(selectRandom militia_squad) createUnit [_grp, _grp, "this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]"];
|
||||
[selectRandom militia_squad, _grp, _grp] call F_createManagedUnit;
|
||||
sleep 0.1;
|
||||
};
|
||||
|
||||
|
@ -46,7 +47,7 @@ private _marker_pos = [((((getPos _roadObj) select 0) + 200) - random 400),((((g
|
|||
private _time_remaining = KP_liberation_civinfo_task_duration;
|
||||
|
||||
while {(alive _hvt) && _time_remaining > 0} do {
|
||||
uiSleep 1;
|
||||
uiSleep 1;
|
||||
private _player_near = false;
|
||||
{
|
||||
if (((_x distance _veh) < 1000) && (alive _x)) exitWith {_player_near = true};
|
||||
|
|
|
@ -11,11 +11,10 @@ private _markers = [];
|
|||
|
||||
for "_i" from 1 to _count do {
|
||||
private _pos = (markerPos _sector) getPos [(50 + (random 150)), (random 360)];
|
||||
while {(surfaceIsWater _pos) || ((count ([_pos, 30] call F_getNearbyPlayers)) > 0)} do {
|
||||
while {(surfaceIsWater _pos) || ((count ([_pos, 30] call KPLIB_fnc_getNearbyPlayers)) > 0)} do {
|
||||
_pos = (markerPos _sector) getPos [(50 + (random 200)), (random 360)];
|
||||
};
|
||||
private _civ = _grp createUnit [(selectRandom civilians), _pos, [], 0, "NONE"];
|
||||
_civ addMPEventHandler ["MPKilled", {_this spawn kill_manager}];
|
||||
private _civ = [selectRandom civilians, _pos, _grp] call F_createManagedUnit;
|
||||
_civ setDir (random 360);
|
||||
{_civ disableAI _x} forEach ["ANIM", "TARGET", "AUTOTARGET", "MOVE"];
|
||||
removeAllItems _civ;
|
||||
|
|
|
@ -5,11 +5,11 @@ while { true } do {
|
|||
{
|
||||
_nextveh = _x;
|
||||
if ( alive _nextveh && ( typeOf _nextveh ) in all_hostile_classnames ) then {
|
||||
if ( _nextveh getVariable [ "GRLIB_captured", 0 ] == 0 ) then {
|
||||
if (_nextveh getVariable ["GRLIB_captured", false]) then {
|
||||
{
|
||||
if ( alive _x ) then {
|
||||
if ( side group _x == GRLIB_side_friendly ) exitWith {
|
||||
_nextveh setVariable [ "GRLIB_captured", 1, true ];
|
||||
_nextveh setVariable ["GRLIB_captured", true, true];
|
||||
};
|
||||
};
|
||||
} foreach (crew _x);
|
||||
|
@ -22,4 +22,4 @@ while { true } do {
|
|||
|
||||
sleep 3;
|
||||
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
_save_interval = 20;
|
||||
|
||||
while { GRLIB_endgame == 0 } do {
|
||||
sleep _save_interval;
|
||||
doSaveTrigger = true;
|
||||
while {GRLIB_endgame == 0} do {
|
||||
sleep KP_liberation_save_interval;
|
||||
doSaveTrigger = true;
|
||||
};
|
||||
|
|
|
@ -34,6 +34,8 @@ private _resourceStorages = [];
|
|||
private _stats = [];
|
||||
// Collection array for the enemy weights
|
||||
private _weights = [];
|
||||
// All mines around FOBs
|
||||
private _allMines = [];
|
||||
|
||||
/*
|
||||
--- Globals ---
|
||||
|
@ -168,6 +170,7 @@ if (!isNil "greuh_liberation_savegame") then {
|
|||
KP_liberation_production = greuh_liberation_savegame select 16;
|
||||
KP_liberation_production_markers = greuh_liberation_savegame select 17;
|
||||
resources_intel = greuh_liberation_savegame select 18;
|
||||
_allMines = greuh_liberation_savegame param [19, []];
|
||||
|
||||
stats_ammo_produced = _stats select 0;
|
||||
stats_ammo_spent = _stats select 1;
|
||||
|
@ -327,7 +330,7 @@ if (!isNil "greuh_liberation_savegame") then {
|
|||
|
||||
// Add blufor crew, if it had crew or is a UAV
|
||||
if ((unitIsUAV _object) || _hascrew) then {
|
||||
[_object] call F_forceBluforCrew;
|
||||
[_object] call KPLIB_fnc_forceBluforCrew;
|
||||
};
|
||||
|
||||
// Apply kill manager handling, if not excluded
|
||||
|
@ -337,7 +340,7 @@ if (!isNil "greuh_liberation_savegame") then {
|
|||
|
||||
// Set captured variable, if it's an OPFOR vehicle
|
||||
if (_class in all_hostile_classnames) then {
|
||||
_object setVariable ["GRLIB_captured", 1, true];
|
||||
_object setVariable ["GRLIB_captured", true, true];
|
||||
};
|
||||
|
||||
// Prevent damage for the FOB building
|
||||
|
@ -372,6 +375,22 @@ if (!isNil "greuh_liberation_savegame") then {
|
|||
|
||||
if (KP_liberation_savegame_debug > 0) then {diag_log "[KP LIBERATION] [SAVE] Saved buildings placed";};
|
||||
|
||||
{
|
||||
_x params ["_minePos", "_dirAndUp", "_class", "_known"];
|
||||
|
||||
private _mine = createVehicle [_class, _minePos, [], 0];
|
||||
_mine setPosWorld _minePos;
|
||||
_mine setVectorDirAndUp _dirAndUp;
|
||||
|
||||
// reveal mine to player side if it was detected
|
||||
if (_known) then {
|
||||
GRLIB_side_friendly revealMine _mine;
|
||||
};
|
||||
|
||||
} forEach _allMines;
|
||||
|
||||
if (KP_liberation_savegame_debug > 0) then {diag_log "[KP LIBERATION] [SAVE] Saved mines placed";};
|
||||
|
||||
// Spawn saved resource storages and their content
|
||||
{
|
||||
_x params ["_class", "_pos", "_vecDir", "_vecUp", "_supply", "_ammo", "_fuel"];
|
||||
|
@ -380,7 +399,7 @@ if (!isNil "greuh_liberation_savegame") then {
|
|||
if (_class in _classnamesToSave) then {
|
||||
|
||||
// Create object without damage handling and simulation
|
||||
private _object = createVehicle [_class, _pos, [], 0, "CAN_COLLIDE"];;
|
||||
private _object = createVehicle [_class, _pos, [], 0, "CAN_COLLIDE"];
|
||||
_object allowdamage false;
|
||||
_object enableSimulation false;
|
||||
|
||||
|
@ -443,7 +462,7 @@ if (!isNil "greuh_liberation_savegame") then {
|
|||
_x params ["_spawnPos", "_units"];
|
||||
private _grp = createGroup [GRLIB_side_friendly, true];
|
||||
{
|
||||
_x createUnit [[_spawnPos, _grp] select (_forEachIndex > 0), _grp, 'this addMPEventHandler ["MPKilled", {_this spawn kill_manager}]'];
|
||||
[_x, [_spawnPos, _grp] select (_forEachIndex > 0), _grp] call F_createManagedUnit;
|
||||
} forEach _units;
|
||||
} forEach _aiGroups;
|
||||
} else {
|
||||
|
@ -455,7 +474,7 @@ if (!isNil "greuh_liberation_savegame") then {
|
|||
private _unit = _x;
|
||||
private _pos = [(_unit select 1) select 0, (_unit select 1) select 1, ((_unit select 1) select 2) + 0.2];
|
||||
private _dir = _unit select 2;
|
||||
(_unit select 0) createUnit [ _pos, _grp, 'this addMPEventHandler ["MPKilled", {_this spawn kill_manager}]'];
|
||||
[(_unit select 0), _pos, _grp] call F_createManagedUnit;
|
||||
private _nextobj = ((units _grp) select ((count (units _grp)) - 1));
|
||||
_nextobj setDir _dir;
|
||||
_nextobj setPosATL _pos;
|
||||
|
@ -477,7 +496,7 @@ publicVariable "KP_liberation_clearances";
|
|||
GRLIB_vehicle_to_military_base_links = GRLIB_vehicle_to_military_base_links select {((_x select 0) in elite_vehicles) && ((_x select 1) in sectors_military)};
|
||||
|
||||
// Remove links for vehicles of possibly removed mods
|
||||
GRLIB_vehicle_to_military_base_links = GRLIB_vehicle_to_military_base_links select {[_x select 0] call F_checkClass};
|
||||
GRLIB_vehicle_to_military_base_links = GRLIB_vehicle_to_military_base_links select {[_x select 0] call KPLIB_fnc_checkClass};
|
||||
|
||||
// Check for additions in the locked vehicles array
|
||||
private _lockedVehCount = count GRLIB_vehicle_to_military_base_links;
|
||||
|
@ -532,6 +551,7 @@ while {true} do {
|
|||
|
||||
private _allObjects = [];
|
||||
private _allStorages = [];
|
||||
private _allMines = [];
|
||||
|
||||
// Get all blufor groups
|
||||
private _allBlueGroups = allGroups select {
|
||||
|
@ -565,6 +585,15 @@ while {true} do {
|
|||
// Add to save array
|
||||
_aiGroups pushBack [getPosATL (leader _x), (_grpUnits apply {typeOf _x})];
|
||||
} forEach (_allBlueGroups select {(_fobPos distance2D (leader _x)) < (GRLIB_fob_range * 2)});
|
||||
|
||||
// Save all mines around FOB
|
||||
private _fobMines = allMines inAreaArray [_fobPos, GRLIB_fob_range * 2, GRLIB_fob_range * 2];
|
||||
_allMines append (_fobMines apply {[
|
||||
getPosWorld _x,
|
||||
[vectorDirVisual _x, vectorUpVisual _x],
|
||||
typeOf _x,
|
||||
_x mineDetectedBy GRLIB_side_friendly
|
||||
]});
|
||||
} forEach GRLIB_all_fobs;
|
||||
|
||||
// Save all fetched objects
|
||||
|
@ -572,7 +601,7 @@ while {true} do {
|
|||
// Position data
|
||||
private _savedpos = getPosWorld _x;
|
||||
private _savedvecdir = vectorDirVisual _x;
|
||||
private _savedvecup = vectorUpVisual _x;;
|
||||
private _savedvecup = vectorUpVisual _x;
|
||||
private _class = typeOf _x;
|
||||
private _hascrew = false;
|
||||
|
||||
|
@ -592,9 +621,9 @@ while {true} do {
|
|||
// Save all storages and resources
|
||||
{
|
||||
// Position data
|
||||
private _savedpos = getPosWorld _x;;
|
||||
private _savedpos = getPosWorld _x;
|
||||
private _savedvecdir = vectorDirVisual _x;
|
||||
private _savedvecup = vectorUpVisual _x;;
|
||||
private _savedvecup = vectorUpVisual _x;
|
||||
private _class = typeof _x;
|
||||
|
||||
// Resource variables
|
||||
|
@ -686,7 +715,8 @@ while {true} do {
|
|||
KP_liberation_logistics,
|
||||
KP_liberation_production,
|
||||
KP_liberation_production_markers,
|
||||
resources_intel
|
||||
resources_intel,
|
||||
_allMines
|
||||
];
|
||||
|
||||
// Write data in the severs profileNamespace
|
||||
|
|
|
@ -1,18 +1,17 @@
|
|||
if (!isDedicated) exitWith {};
|
||||
|
||||
private ["_serverDuration","_timeStart","_timeSinceStart","_shutdownSuccess","_timeUntilRestart","_30minspassed","_15minspassed","_5minspassed","_60secondspassed"];
|
||||
|
||||
_serverDuration = (KP_liberation_restart * 60 * 60);
|
||||
|
||||
diag_log format ["[KP LIBERATION] [RESTART] Restart Timer Set To %1", _serverDuration];
|
||||
|
||||
_30minspassed = false;
|
||||
_15minspassed = false;
|
||||
_5minspassed = false;
|
||||
_60secondspassed = false;
|
||||
private _30minspassed = false;
|
||||
private _15minspassed = false;
|
||||
private _5minspassed = false;
|
||||
private _60secondspassed = false;
|
||||
|
||||
_timeStart = diag_tickTime;
|
||||
private _timeStart = diag_tickTime;
|
||||
|
||||
private ["_timeSinceStart","_timeUntilRestart"];
|
||||
while{true} do
|
||||
{
|
||||
_timeSinceStart = diag_tickTime - _timeStart;
|
||||
|
@ -57,8 +56,8 @@ while{true} do
|
|||
diag_log "[KP LIBERATION] [RESTART] Restart timeout elapsed, attempting server shutdown.";
|
||||
sleep 5;
|
||||
|
||||
_myPass = call compile preprocessFileLineNumbers "\userconfig\restart\myPass.hpp";
|
||||
_shutdownSuccess = _myPass serverCommand "#restart";//you can change with #restartserver if you want to restart the server process(Windows Dedicated Only).
|
||||
private _myPass = call compile preprocessFileLineNumbers "\userconfig\restart\myPass.hpp";
|
||||
private _shutdownSuccess = _myPass serverCommand (["#restart", "#restartserver"] select ((productVersion select 6) isEqualTo "Windows"));
|
||||
|
||||
if(_shutdownSuccess) then
|
||||
{
|
||||
|
|
|
@ -19,7 +19,7 @@ while { true } do {
|
|||
} foreach allUnits;
|
||||
|
||||
{
|
||||
if (((typeof _x in _vehicleClassnames) || (_x getVariable ["GRLIB_captured", 0] == 1)) && ((_x distance startbase > 1000) && (isNull attachedTo _x) || (typeof _x == huron_typename)) && alive _x ) then {
|
||||
if (((typeof _x in _vehicleClassnames) || (_x getVariable ["GRLIB_captured", false])) && ((_x distance startbase > 1000) && (isNull attachedTo _x) || (typeof _x == huron_typename)) && alive _x ) then {
|
||||
_zeusunits pushback _x;
|
||||
};
|
||||
} foreach vehicles;
|
||||
|
|
|
@ -13,7 +13,7 @@ while { GRLIB_endgame == 0 } do {
|
|||
_spawnsector = "";
|
||||
_usable_sectors = [];
|
||||
{
|
||||
if ( ( ( [ getmarkerpos _x , 1000 , GRLIB_side_friendly ] call F_getUnitsCount ) == 0 ) && ( count ( [ getmarkerpos _x , 3500 ] call F_getNearbyPlayers ) > 0 ) ) then {
|
||||
if ((([getmarkerpos _x, 1000, GRLIB_side_friendly] call F_getUnitsCount) == 0) && (count ([getmarkerpos _x, 3500] call KPLIB_fnc_getNearbyPlayers) > 0)) then {
|
||||
_usable_sectors pushback _x;
|
||||
}
|
||||
|
||||
|
@ -26,7 +26,7 @@ while { GRLIB_endgame == 0 } do {
|
|||
if ( random 100 < 33) then {
|
||||
_civnumber = 1 + (floor (random 2));
|
||||
while { count units _grp < _civnumber } do {
|
||||
(selectRandom civilians) createUnit [ markerpos _spawnsector, _grp, "this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
[selectRandom civilians, markerPos _spawnsector, _grp, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
};
|
||||
_grpspeed = "LIMITED";
|
||||
} else {
|
||||
|
@ -39,7 +39,7 @@ while { GRLIB_endgame == 0 } do {
|
|||
|
||||
_spawnpos = getpos _nearestroad;
|
||||
|
||||
(selectRandom civilians) createUnit [_spawnpos, _grp, "this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
[selectRandom civilians, _spawnpos, _grp, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
_civveh = (selectRandom civilian_vehicles) createVehicle _spawnpos;
|
||||
_civveh setpos _spawnpos;
|
||||
_civveh addMPEventHandler ['MPKilled', {_this spawn kill_manager}];
|
||||
|
@ -56,7 +56,7 @@ while { GRLIB_endgame == 0 } do {
|
|||
_sectors_patrol = [];
|
||||
_patrol_startpos = getpos (leader _grp);
|
||||
{
|
||||
if ( (_patrol_startpos distance (markerpos _x) < 5000 ) && ( count ( [ getmarkerpos _x , 4000 ] call F_getNearbyPlayers ) > 0 ) ) then {
|
||||
if ((_patrol_startpos distance (markerpos _x) < 5000) && (count ([getmarkerpos _x, 4000] call KPLIB_fnc_getNearbyPlayers) > 0)) then {
|
||||
_sectors_patrol pushback _x;
|
||||
};
|
||||
} foreach (sectors_bigtown + sectors_capture + sectors_factory);
|
||||
|
@ -99,11 +99,11 @@ while { GRLIB_endgame == 0 } do {
|
|||
|
||||
waitUntil {
|
||||
sleep (30 + (random 30));
|
||||
( ( ( { alive _x } count ( units _grp ) ) == 0 ) || ( count ( [ getpos leader _grp , 4000 ] call F_getNearbyPlayers ) == 0 ) )
|
||||
((({alive _x} count (units _grp)) == 0) || (count ([getpos leader _grp, 4000] call KPLIB_fnc_getNearbyPlayers) == 0))
|
||||
};
|
||||
|
||||
if ( count (units _grp) > 0 ) then {
|
||||
if ( count ( [ getpos leader _grp , 4000 ] call F_getNearbyPlayers ) == 0 ) then {
|
||||
if (count ([getpos leader _grp, 4000] call KPLIB_fnc_getNearbyPlayers) == 0) then {
|
||||
|
||||
if ( !(isNull _civveh) ) then {
|
||||
if ( { ( alive _x ) && (side group _x == GRLIB_side_friendly ) } count (crew _civveh) == 0 ) then {
|
||||
|
@ -117,4 +117,4 @@ while { GRLIB_endgame == 0 } do {
|
|||
};
|
||||
|
||||
sleep 150 + (random (150));
|
||||
};
|
||||
};
|
||||
|
|
|
@ -18,7 +18,7 @@ while { GRLIB_endgame == 0 } do {
|
|||
|
||||
_spawn_marker = "";
|
||||
while { _spawn_marker == "" } do {
|
||||
_spawn_marker = [2000,5000,true] call F_findOpforSpawnPoint;
|
||||
_spawn_marker = [2000,5000,true] call KPLIB_fnc_getOpforSpawnPoint;
|
||||
if ( _spawn_marker == "" ) then {
|
||||
sleep (150 + (random 150));
|
||||
};
|
||||
|
@ -28,9 +28,9 @@ while { GRLIB_endgame == 0 } do {
|
|||
|
||||
if (_is_infantry) then {
|
||||
_grp = createGroup [GRLIB_side_enemy, true];
|
||||
_squad = ["army"] call F_getAdaptiveSquadComp;
|
||||
_squad = [] call KPLIB_fnc_getSquadComp;
|
||||
{
|
||||
_x createUnit [_sector_spawn_pos, _grp,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
[_x, _sector_spawn_pos, _grp, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
} foreach _squad;
|
||||
} else {
|
||||
|
||||
|
@ -38,7 +38,7 @@ while { GRLIB_endgame == 0 } do {
|
|||
if ( (combat_readiness > 75) && ((random 100) > 85) ) then {
|
||||
_vehicle_object = [_sector_spawn_pos, selectRandom opfor_choppers] call F_libSpawnVehicle;
|
||||
} else {
|
||||
_vehicle_object = [_sector_spawn_pos, [] call F_getAdaptiveVehicle] call F_libSpawnVehicle;
|
||||
_vehicle_object = [_sector_spawn_pos, [] call KPLIB_fnc_getAdaptiveVehicle] call F_libSpawnVehicle;
|
||||
};
|
||||
|
||||
sleep 0.5;
|
||||
|
@ -67,7 +67,7 @@ while { GRLIB_endgame == 0 } do {
|
|||
_patrol_continue = false;
|
||||
{
|
||||
if ( vehicle _x != _x ) then {
|
||||
[ (vehicle _x) ] call F_cleanOpforVehicle;
|
||||
[(vehicle _x)] call KPLIB_fnc_cleanOpforVehicle;
|
||||
};
|
||||
deleteVehicle _x;
|
||||
} foreach (units _grp);
|
||||
|
@ -80,4 +80,4 @@ while { GRLIB_endgame == 0 } do {
|
|||
sleep (600.0 / GRLIB_difficulty_modifier);
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,27 +1,42 @@
|
|||
params ["_targetsector"];
|
||||
private _targetpos = getMarkerPos _targetsector;
|
||||
private _spawnsector = ([sectors_airspawn, [_targetpos], {(markerpos _x) distance _input0}, "ASCEND"] call BIS_fnc_sortBy) select 0;
|
||||
params [
|
||||
["_targetsector", "", ["",[]]],
|
||||
["_chopper_type", objNull, [objNull]]
|
||||
];
|
||||
|
||||
private _chopper_type = selectRandom opfor_choppers;
|
||||
if (_targetsector isEqualTo "") exitWith {};
|
||||
|
||||
while {!(_chopper_type in opfor_troup_transports)} do {
|
||||
_chopper_type = selectRandom opfor_choppers;
|
||||
private _targetpos = _targetsector;
|
||||
if (_targetpos isEqualType "") then {
|
||||
_targetpos = getMarkerPos _targetsector;
|
||||
};
|
||||
private _spawnsector = ([sectors_airspawn, [_targetpos], {(markerpos _x) distance _input0}, "ASCEND"] call BIS_fnc_sortBy) select 0;
|
||||
private _newvehicle = objNull;
|
||||
private _pilot_group = grpNull;
|
||||
if (isNull _chopper_type) then {
|
||||
_chopper_type = selectRandom opfor_choppers;
|
||||
|
||||
private _newvehicle = createVehicle [_chopper_type, markerpos _spawnsector, [], 0, "FLY"];
|
||||
createVehicleCrew _newvehicle;
|
||||
sleep 0.1;
|
||||
while {!(_chopper_type in opfor_troup_transports)} do {
|
||||
_chopper_type = selectRandom opfor_choppers;
|
||||
};
|
||||
|
||||
private _pilot_group = createGroup [GRLIB_side_enemy, true];
|
||||
(crew _newvehicle) joinSilent _pilot_group;
|
||||
_newvehicle = createVehicle [_chopper_type, markerpos _spawnsector, [], 0, "FLY"];
|
||||
createVehicleCrew _newvehicle;
|
||||
sleep 0.1;
|
||||
|
||||
_pilot_group = createGroup [GRLIB_side_enemy, true];
|
||||
(crew _newvehicle) joinSilent _pilot_group;
|
||||
|
||||
_newvehicle addMPEventHandler ["MPKilled", {_this spawn kill_manager}];
|
||||
{_x addMPEventHandler ["MPKilled", {_this spawn kill_manager}];} forEach (crew _newvehicle);
|
||||
} else {
|
||||
_newvehicle = _chopper_type;
|
||||
_pilot_group = group _newvehicle;
|
||||
};
|
||||
|
||||
private _para_group = createGroup [GRLIB_side_enemy, true];
|
||||
|
||||
_newvehicle addMPEventHandler ["MPKilled", {_this spawn kill_manager}];
|
||||
{_x addMPEventHandler ["MPKilled", {_this spawn kill_manager}];} forEach (crew _newvehicle);
|
||||
|
||||
while {(count (units _para_group)) < 8} do {
|
||||
opfor_paratrooper createUnit [getmarkerpos _spawnsector, _para_group, "this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]"];
|
||||
[opfor_paratrooper, markerPos _spawnsector, _para_group] call F_createManagedUnit;
|
||||
};
|
||||
|
||||
{removeBackpack _x; _x addBackPack "B_parachute"; _x moveInCargo _newvehicle;} forEach (units _para_group);
|
||||
|
@ -72,15 +87,15 @@ _pilot_group setCurrentWaypoint [_para_group, 1];
|
|||
_newvehicle flyInHeight 100;
|
||||
|
||||
waitUntil {sleep 1;
|
||||
!(alive _newvehicle) || (damage _newvehicle > 0.2 ) || (_newvehicle distance _targetpos < 400 )
|
||||
!(alive _newvehicle) || (damage _newvehicle > 0.2 ) || (_newvehicle distance _targetpos < 400)
|
||||
};
|
||||
|
||||
_newvehicle flyInHeight 100;
|
||||
|
||||
{
|
||||
unassignVehicle _x;
|
||||
moveout _x;
|
||||
sleep 0.5;
|
||||
unassignVehicle _x;
|
||||
moveout _x;
|
||||
sleep 0.5;
|
||||
} forEach (units _para_group);
|
||||
|
||||
_newvehicle flyInHeight 100;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
private _convoy_destinations_markers = [];
|
||||
private _load_box_fnc = compileFinal preprocessFileLineNumbers "scripts\client\ammoboxes\do_load_box.sqf";
|
||||
|
||||
while { count _convoy_destinations_markers < 3 } do { _convoy_destinations_markers pushback ([2000,999999,false] call F_findOpforSpawnPoint); };
|
||||
while { count _convoy_destinations_markers < 3 } do { _convoy_destinations_markers pushback ([2000,999999,false] call KPLIB_fnc_getOpforSpawnPoint); };
|
||||
|
||||
private _couldnt_spawn = false;
|
||||
{ if ( _x == "" ) exitWith { _couldnt_spawn = true; }; } foreach _convoy_destinations_markers;
|
||||
|
@ -76,7 +76,9 @@ _waypoint setWaypointType "CYCLE";
|
|||
_waypoint setWaypointCompletionRadius 50;
|
||||
|
||||
private _troops_group = createGroup [GRLIB_side_enemy, true];
|
||||
{_x createUnit [_spawnpos, _troops_group,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];} foreach (["army"] call F_getAdaptiveSquadComp);
|
||||
{
|
||||
[_x, _spawnpos, _troops_group, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
} foreach ([] call KPLIB_fnc_getSquadComp);
|
||||
{_x moveInCargo _troop_vehicle} foreach (units _troops_group);
|
||||
|
||||
private _convoy_marker = createMarkerLocal [ format [ "convoymarker%1", round time], getpos _transport_vehicle ];
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
|
||||
_defenders_amount = (15 * (sqrt (GRLIB_unitcap))) min 15;
|
||||
|
||||
_spawn_marker = [2000,999999,false] call F_findOpforSpawnPoint;
|
||||
_spawn_marker = [2000,999999,false] call KPLIB_fnc_getOpforSpawnPoint;
|
||||
if (_spawn_marker == "") exitWith {diag_log "[KP LIBERATION] [ERROR] Could not find position for fob hunting mission";};
|
||||
|
||||
used_positions pushBack _spawn_marker;
|
||||
|
@ -85,10 +85,10 @@ while {(count _idxselected) < _defenders_amount && (count _idxselected) < (count
|
|||
];
|
||||
|
||||
_nextpos = [((_base_position select 0) + (_nextpos select 0)), ((_base_position select 1) + (_nextpos select 1)), (_nextpos select 2)];
|
||||
_nextclass createUnit [_nextpos, _grpdefenders, "nextdefender = this; this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
nextdefender setdir _nextdir;
|
||||
nextdefender setpos _nextpos;
|
||||
[nextdefender] spawn building_defence_ai;
|
||||
private _nextDefender = [_nextclass, _nextpos, _grpdefenders, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
_nextDefender setdir _nextdir;
|
||||
_nextDefender setpos _nextpos;
|
||||
[_nextDefender] spawn building_defence_ai;
|
||||
} forEach _idxselected;
|
||||
|
||||
private _sentryMax = ceil ((3 + (floor (random 4))) * (sqrt (GRLIB_unitcap)));
|
||||
|
@ -96,7 +96,7 @@ private _sentryMax = ceil ((3 + (floor (random 4))) * (sqrt (GRLIB_unitcap)));
|
|||
_grpsentry = createGroup [GRLIB_side_enemy, true];
|
||||
_base_sentry_pos = [(_base_position select 0) + ((_base_corners select 0) select 0), (_base_position select 1) + ((_base_corners select 0) select 1), 0];
|
||||
for [{_idx=0}, {_idx < _sentryMax}, {_idx=_idx+1}] do {
|
||||
opfor_sentry createUnit [_base_sentry_pos, _grpsentry,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
[opfor_sentry, _base_sentry_pos, _grpsentry, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
};
|
||||
|
||||
while {(count (waypoints _grpsentry)) != 0} do {deleteWaypoint ((waypoints _grpsentry) select 0);};
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
private _spawn_marker = [ 2000, 999999, false ] call F_findOpforSpawnPoint;
|
||||
private _spawn_marker = [ 2000, 999999, false ] call KPLIB_fnc_getOpforSpawnPoint;
|
||||
if ( _spawn_marker == "" ) exitWith { diag_log "[KP LIBERATION] [ERROR] Could not find position for search and rescue mission"; };
|
||||
used_positions pushbackUnique _spawn_marker;
|
||||
|
||||
|
@ -17,10 +17,13 @@ _helofire setpos (getpos _helowreck);
|
|||
|
||||
private _pilotsGrp = createGroup [GRLIB_side_enemy, true];
|
||||
private _pilotsPos = (getpos _helowreck) getPos [25, random 360];
|
||||
pilot_classname createUnit [ _pilotsPos, _pilotsGrp,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
|
||||
[pilot_classname, _pilotsPos, _pilotsGrp, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
sleep 0.2;
|
||||
pilot_classname createUnit [_pilotsPos getPos [1, random 360], _pilotsGrp,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
|
||||
[pilot_classname, _pilotsPos getPos [1, random 360], _pilotsGrp, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
sleep 2;
|
||||
|
||||
private _pilotUnits = units _pilotsGrp;
|
||||
{
|
||||
[ _x, true ] spawn prisonner_ai;
|
||||
|
@ -36,7 +39,9 @@ private _patrolcorners = [
|
|||
[ (getpos _helowreck select 0) - 40, (getpos _helowreck select 1) + 40, 0 ]
|
||||
];
|
||||
|
||||
{ _x createUnit [ _patrolcorners select 0, _grppatrol,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"]; } foreach (["army"] call F_getAdaptiveSquadComp);
|
||||
{
|
||||
[_x, _patrolcorners select 0, _grppatrol, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
} foreach ([] call KPLIB_fnc_getSquadComp);
|
||||
|
||||
while {(count (waypoints _grppatrol)) != 0} do {deleteWaypoint ((waypoints _grppatrol) select 0);};
|
||||
{
|
||||
|
@ -56,7 +61,7 @@ private _grpsentry = createGroup [GRLIB_side_enemy, true];
|
|||
private _nbsentry = 2 + (floor (random 3));
|
||||
|
||||
for [ {_idx=0},{_idx < _nbsentry},{_idx=_idx+1} ] do {
|
||||
opfor_sentry createUnit [_pilotsPos getPos [1, random 360], _grpsentry,"this addMPEventHandler [""MPKilled"", {_this spawn kill_manager}]", 0.5, "private"];
|
||||
[opfor_sentry, _pilotsPos getPos [1, random 360], _grpsentry, "PRIVATE", 0.5] call F_createManagedUnit;
|
||||
};
|
||||
|
||||
(leader _grpsentry) setDir (random 360);
|
||||
|
|
|
@ -8,7 +8,9 @@ if ( _ownership != GRLIB_side_enemy ) exitWith {};
|
|||
|
||||
if ( GRLIB_blufor_defenders ) then {
|
||||
_grp = creategroup [GRLIB_side_friendly, true];
|
||||
{ _x createUnit [ _thispos, _grp,'this addMPEventHandler ["MPKilled", {_this spawn kill_manager}]']; } foreach blufor_squad_inf;
|
||||
{
|
||||
[_x, _thispos, _grp] call F_createManagedUnit;
|
||||
} foreach blufor_squad_inf;
|
||||
sleep 3;
|
||||
_grp setBehaviour "COMBAT";
|
||||
};
|
||||
|
|
|
@ -13,7 +13,9 @@ if ( _sector in sectors_military ) then {
|
|||
|
||||
if ( GRLIB_blufor_defenders ) then {
|
||||
_grp = creategroup [GRLIB_side_friendly, true];
|
||||
{ _x createUnit [ markerpos _sector, _grp,'this addMPEventHandler ["MPKilled", {_this spawn kill_manager}]']; } foreach _squad_type;
|
||||
{
|
||||
[_x, markerPos _sector, _grp] call F_createManagedUnit;
|
||||
} foreach _squad_type;
|
||||
sleep 3;
|
||||
_grp setBehaviour "COMBAT";
|
||||
};
|
||||
|
|
|
@ -16,7 +16,7 @@ private _sectorpos = getmarkerpos _sector;
|
|||
private _stopit = false;
|
||||
private _spawncivs = false;
|
||||
private _building_ai_max = 0;
|
||||
private _infsquad = "militia";
|
||||
private _infsquad = "army";
|
||||
private _building_range = 50;
|
||||
private _local_capture_size = GRLIB_capture_size;
|
||||
private _iedcount = 0;
|
||||
|
@ -41,23 +41,23 @@ active_sectors pushback _sector; publicVariable "active_sectors";
|
|||
private _opforcount = [] call F_opforCap;
|
||||
[_sector, _opforcount] call wait_to_spawn_sector;
|
||||
|
||||
if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] call F_getCorrectedSectorRange, GRLIB_side_friendly] call F_getUnitsCount) > 0)) then {
|
||||
if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] call KPLIB_fnc_getSectorRange, GRLIB_side_friendly] call F_getUnitsCount) > 0)) then {
|
||||
|
||||
if (_sector in sectors_bigtown) then {
|
||||
if (combat_readiness > 30) then {_infsquad = "army";};
|
||||
if (combat_readiness < 30) then {_infsquad = "militia";};
|
||||
|
||||
_squad1 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
_squad2 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
if (GRLIB_unitcap >= 1) then {_squad3 = ([_infsquad] call F_getAdaptiveSquadComp);};
|
||||
if (GRLIB_unitcap >= 1.5) then {_squad4 = ([_infsquad] call F_getAdaptiveSquadComp);};
|
||||
_squad1 = ([_infsquad] call KPLIB_fnc_getSquadComp);
|
||||
_squad2 = ([_infsquad] call KPLIB_fnc_getSquadComp);
|
||||
if (GRLIB_unitcap >= 1) then {_squad3 = ([_infsquad] call KPLIB_fnc_getSquadComp);};
|
||||
if (GRLIB_unitcap >= 1.5) then {_squad4 = ([_infsquad] call KPLIB_fnc_getSquadComp);};
|
||||
|
||||
_vehtospawn = [(selectRandom militia_vehicles),(selectRandom militia_vehicles)];
|
||||
if ((random 100) > (66 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback (selectRandom militia_vehicles);};
|
||||
if ((random 100) > (50 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback (selectRandom militia_vehicles);};
|
||||
if (_infsquad == "army") then {
|
||||
_vehtospawn pushback ([] call F_getAdaptiveVehicle);
|
||||
_vehtospawn pushback ([] call F_getAdaptiveVehicle);
|
||||
if ((random 100) > (33 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback ([] call F_getAdaptiveVehicle);};
|
||||
_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);
|
||||
_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);
|
||||
if ((random 100) > (33 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);};
|
||||
};
|
||||
|
||||
_spawncivs = true;
|
||||
|
@ -79,18 +79,18 @@ if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] cal
|
|||
};
|
||||
|
||||
if (_sector in sectors_capture) then {
|
||||
if (combat_readiness > 50) then {_infsquad = "army";};
|
||||
if (combat_readiness < 50) then {_infsquad = "militia";};
|
||||
|
||||
_squad1 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
if (GRLIB_unitcap >= 1.25) then {_squad2 = ([_infsquad] call F_getAdaptiveSquadComp);};
|
||||
_squad1 = ([_infsquad] call KPLIB_fnc_getSquadComp);
|
||||
if (GRLIB_unitcap >= 1.25) then {_squad2 = ([_infsquad] call KPLIB_fnc_getSquadComp);};
|
||||
|
||||
if ((random 100) > (66 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback (selectRandom militia_vehicles);};
|
||||
if ((random 100) > (33 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback (selectRandom militia_vehicles);};
|
||||
if (_infsquad == "army") then {
|
||||
_vehtospawn pushback (selectRandom militia_vehicles);
|
||||
if ((random 100) > (33 / GRLIB_difficulty_modifier)) then {
|
||||
_vehtospawn pushback ([] call F_getAdaptiveVehicle);
|
||||
_squad3 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);
|
||||
_squad3 = ([_infsquad] call KPLIB_fnc_getSquadComp);
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -112,18 +112,16 @@ if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] cal
|
|||
};
|
||||
|
||||
if (_sector in sectors_military) then {
|
||||
_infsquad = "army";
|
||||
_squad1 = ([] call KPLIB_fnc_getSquadComp);
|
||||
_squad2 = ([] call KPLIB_fnc_getSquadComp);
|
||||
if (GRLIB_unitcap >= 1.5) then {_squad3 = ([] call KPLIB_fnc_getSquadComp);};
|
||||
|
||||
_squad1 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
_squad2 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
if (GRLIB_unitcap >= 1.5) then {_squad3 = ([_infsquad] call F_getAdaptiveSquadComp);};
|
||||
|
||||
_vehtospawn = [([] call F_getAdaptiveVehicle),([] call F_getAdaptiveVehicle)];
|
||||
_vehtospawn = [([] call KPLIB_fnc_getAdaptiveVehicle),([] call KPLIB_fnc_getAdaptiveVehicle)];
|
||||
if ((random 100) > (33 / GRLIB_difficulty_modifier)) then {
|
||||
_vehtospawn pushback ([] call F_getAdaptiveVehicle);
|
||||
_squad4 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);
|
||||
_squad4 = ([] call KPLIB_fnc_getSquadComp);
|
||||
};
|
||||
if ((random 100) > (66 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback ([] call F_getAdaptiveVehicle);};
|
||||
if ((random 100) > (66 / GRLIB_difficulty_modifier)) then {_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);};
|
||||
|
||||
_spawncivs = false;
|
||||
|
||||
|
@ -132,12 +130,12 @@ if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] cal
|
|||
};
|
||||
|
||||
if (_sector in sectors_factory) then {
|
||||
if (combat_readiness > 40) then {_infsquad = "army";};
|
||||
if (combat_readiness < 40) then {_infsquad = "militia";};
|
||||
|
||||
_squad1 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
if (GRLIB_unitcap >= 1.25) then {_squad2 = ([_infsquad] call F_getAdaptiveSquadComp);};
|
||||
_squad1 = ([_infsquad] call KPLIB_fnc_getSquadComp);
|
||||
if (GRLIB_unitcap >= 1.25) then {_squad2 = ([_infsquad] call KPLIB_fnc_getSquadComp);};
|
||||
|
||||
if ((random 100) > 66) then {_vehtospawn pushback ([] call F_getAdaptiveVehicle);};
|
||||
if ((random 100) > 66) then {_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);};
|
||||
if ((random 100) > 33) then {_vehtospawn pushback (selectRandom militia_vehicles);};
|
||||
|
||||
_spawncivs = false;
|
||||
|
@ -158,13 +156,11 @@ if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] cal
|
|||
};
|
||||
|
||||
if (_sector in sectors_tower) then {
|
||||
_infsquad = "army";
|
||||
_squad1 = ([] call KPLIB_fnc_getSquadComp);
|
||||
if (combat_readiness > 30) then {_squad2 = ([] call KPLIB_fnc_getSquadComp);};
|
||||
if (GRLIB_unitcap >= 1.5) then {_squad3 = ([] call KPLIB_fnc_getSquadComp);};
|
||||
|
||||
_squad1 = ([_infsquad] call F_getAdaptiveSquadComp);
|
||||
if (combat_readiness > 30) then {_squad2 = ([_infsquad] call F_getAdaptiveSquadComp);};
|
||||
if (GRLIB_unitcap >= 1.5) then {_squad3 = ([_infsquad] call F_getAdaptiveSquadComp);};
|
||||
|
||||
if((random 100) > 95) then {_vehtospawn pushback ([] call F_getAdaptiveVehicle);};
|
||||
if((random 100) > 95) then {_vehtospawn pushback ([] call KPLIB_fnc_getAdaptiveVehicle);};
|
||||
|
||||
_spawncivs = false;
|
||||
|
||||
|
@ -176,7 +172,7 @@ if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] cal
|
|||
if (KP_liberation_sectorspawn_debug > 0) then {private _text = format ["[KP LIBERATION] [SECTORSPAWN] Sector %1 (%2) - manage_one_sector calculated -> _infsquad: %3 - _squad1: %4 - _squad2: %5 - _squad3: %6 - _squad4: %7 - _vehtospawn: %8 - _building_ai_max: %9", (markerText _sector), _sector, _infsquad, (count _squad1), (count _squad2), (count _squad3), (count _squad4), (count _vehtospawn), _building_ai_max];_text remoteExec ["diag_log",2];};
|
||||
|
||||
if (_building_ai_max > 0 && GRLIB_adaptive_opfor) then {
|
||||
_building_ai_max = round (_building_ai_max * ([] call F_adaptiveOpforFactor));
|
||||
_building_ai_max = round (_building_ai_max * ([] call KPLIB_fnc_getOpforFactor));
|
||||
};
|
||||
|
||||
{
|
||||
|
@ -271,11 +267,11 @@ if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] cal
|
|||
deleteVehicle _x;
|
||||
};
|
||||
} else {
|
||||
[_x] call F_cleanOpforVehicle;
|
||||
[_x] call KPLIB_fnc_cleanOpforVehicle;
|
||||
};
|
||||
} forEach _managed_units;
|
||||
} else {
|
||||
if (([_sectorpos, (([_opforcount] call F_getCorrectedSectorRange) + 300), GRLIB_side_friendly] call F_getUnitsCount) == 0) then {
|
||||
if (([_sectorpos, (([_opforcount] call KPLIB_fnc_getSectorRange) + 300), GRLIB_side_friendly] call F_getUnitsCount) == 0) then {
|
||||
_sector_despawn_tickets = _sector_despawn_tickets - 1;
|
||||
} else {
|
||||
// start counting running minutes after ADDITIONAL_TICKETS_DELAY
|
||||
|
@ -293,7 +289,7 @@ if ((!(_sector in blufor_sectors)) && (([getmarkerpos _sector, [_opforcount] cal
|
|||
if (_x isKindOf "Man") then {
|
||||
deleteVehicle _x;
|
||||
} else {
|
||||
[_x] call F_cleanOpforVehicle;
|
||||
[_x] call KPLIB_fnc_cleanOpforVehicle;
|
||||
};
|
||||
} forEach _managed_units;
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ while {GRLIB_endgame == 0} do {
|
|||
|
||||
if (_opforcount < GRLIB_sector_cap) then {
|
||||
|
||||
if (([getmarkerpos _nextsector, [_opforcount] call F_getCorrectedSectorRange, GRLIB_side_friendly] call F_getUnitsCount > 0) && !(_nextsector in active_sectors)) then {
|
||||
if (([getmarkerpos _nextsector, [_opforcount] call KPLIB_fnc_getSectorRange, GRLIB_side_friendly] call F_getUnitsCount > 0) && !(_nextsector in active_sectors)) then {
|
||||
|
||||
_hc = [] call F_lessLoadedHC;
|
||||
|
||||
|
@ -35,7 +35,7 @@ while {GRLIB_endgame == 0} do {
|
|||
};
|
||||
sleep 0.25;
|
||||
} forEach (sectors_allSectors - blufor_sectors);
|
||||
|
||||
|
||||
if (KP_liberation_sectorspawn_debug > 0) then {
|
||||
_timer = _timer + 1;
|
||||
if ((_timer % 5) == 0) then {
|
||||
|
|
|
@ -2,7 +2,7 @@ params ["_sector", "_opforcount"];
|
|||
|
||||
if (KP_liberation_sectorspawn_debug > 0) then {private _text = format ["[KP LIBERATION] [SECTORSPAWN] Sector %1 (%2) - Time: %3 - waiting to spawn sector...", (markerText _sector), _sector, time];_text remoteExec ["diag_log",2];};
|
||||
|
||||
private _corrected_size = [_opforcount] call F_getCorrectedSectorRange;
|
||||
private _corrected_size = [_opforcount] call KPLIB_fnc_getSectorRange;
|
||||
sleep 0.1;
|
||||
private _unitscount = [getmarkerpos _sector, _corrected_size , GRLIB_side_friendly] call F_getUnitsCount;
|
||||
|
||||
|
|
|
@ -1,13 +1,10 @@
|
|||
|
||||
/*
|
||||
Methods
|
||||
*/
|
||||
|
||||
// Get parameter
|
||||
#define GET_PARAM(outVar, paramName, paramDefault) outVar = [paramName,paramDefault] call F_getSaveableParam;\
|
||||
publicVariable #outVar
|
||||
#define GET_PARAM(outVar, paramName, paramDefault) outVar = [paramName,paramDefault] call F_getSaveableParam;\
|
||||
publicVariable #outVar;\
|
||||
diag_log format ["[KP LIBERATION] [PARAM] %1: %2", paramName, outVar]
|
||||
|
||||
// Get parameter and convert to bool
|
||||
#define GET_PARAM_BOOL(outVar, paramName, paramDefault) outVar = [paramName,paramDefault] call F_getSaveableParam;\
|
||||
if (outVar == 1) then {outVar = true} else {outVar = false};\
|
||||
publicVariable #outVar
|
||||
#define GET_PARAM_BOOL(outVar, paramName, paramDefault) outVar = [paramName,paramDefault] call F_getSaveableParam;\
|
||||
if (outVar == 1) then {outVar = true} else {outVar = false};\
|
||||
publicVariable #outVar;\
|
||||
diag_log format ["[KP LIBERATION] [PARAM] %1: %2", paramName, outVar]
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#include "defines.hpp"
|
||||
|
||||
// Check if ACE is running
|
||||
if (isClass (configfile >> "CfgPatches" >> "ace_common")) then {KP_liberation_ace = true; diag_log "[KP LIBERATION] ACE detected. Deactivating resupply and weather scripts from Liberation."} else {KP_liberation_ace = false};
|
||||
if (isClass (configfile >> "CfgPatches" >> "ace_common")) then {KP_liberation_ace = true; diag_log "[KP LIBERATION] ACE detected. Deactivating resupply script from Liberation."} else {KP_liberation_ace = false};
|
||||
|
||||
/* Not saveable params */
|
||||
GRLIB_param_wipe_savegame_1 = ["WipeSave1",0] call bis_fnc_getParamValue;
|
||||
|
@ -19,11 +19,26 @@ KP_load_params = ["LoadSaveParams", 1] call BIS_fnc_getParamValue;
|
|||
|
||||
if(isServer) then {
|
||||
/* Saveable params */
|
||||
diag_log format ["[KP LIBERATION] [PARAM] ----- Server starts parameter initialization - time: %1", diag_ticktime];
|
||||
switch (KP_load_params) do {
|
||||
case 0: {
|
||||
diag_log "[KP LIBERATION] [PARAM] Save/Load is set to SAVE";
|
||||
};
|
||||
case 1: {
|
||||
diag_log "[KP LIBERATION] [PARAM] Save/Load is set to LOAD";
|
||||
};
|
||||
case 2: {
|
||||
diag_log "[KP LIBERATION] [PARAM] Save/Load is set to USE SELECTED";
|
||||
};
|
||||
default {
|
||||
diag_log "[KP LIBERATION] [PARAM] Save/Load has no valid value";
|
||||
};
|
||||
};
|
||||
|
||||
// Deactivate BI Revive when ACE Medical is running
|
||||
if (isClass (configfile >> "CfgPatches" >> "ace_medical")) then {
|
||||
bis_reviveParam_mode = 0; publicVariable "bis_reviveParam_mode";
|
||||
diag_log "[KP LIBERATION] ACE Medical detected. Deactivating BI Revive System."
|
||||
diag_log "[KP LIBERATION] [PARAM] ACE Medical detected. Deactivating BI Revive System."
|
||||
} else {
|
||||
GET_PARAM(bis_reviveParam_mode, "ReviveMode", 1);
|
||||
};
|
||||
|
@ -40,7 +55,7 @@ if(isServer) then {
|
|||
GET_PARAM(GRLIB_time_factor, "DayDuration", 12);
|
||||
GET_PARAM(GRLIB_resources_multiplier, "ResourcesMultiplier", 3);
|
||||
GET_PARAM(GRLIB_unitcap, "Unitcap", 2);
|
||||
GET_PARAM(GRLIB_civilian_activity, "civilians", 1);
|
||||
GET_PARAM(GRLIB_civilian_activity, "Civilians", 1);
|
||||
GET_PARAM(GRLIB_halo_param, "HaloJump", 1);
|
||||
GET_PARAM(GRLIB_cleanup_vehicles, "CleanupVehicles", 2);
|
||||
GET_PARAM(GRLIB_csat_aggressivity, "Aggressivity", 2);
|
||||
|
@ -86,7 +101,7 @@ if(isServer) then {
|
|||
KP_serverParamsFetched = true;
|
||||
publicVariable "KP_serverParamsFetched";
|
||||
|
||||
diag_log "[KP LIBERATION] [PARAM] Server finished parameters initialization.";
|
||||
diag_log format ["[KP LIBERATION] [PARAM] ----- Server finished parameter initialization - time: %1", diag_ticktime];
|
||||
};
|
||||
|
||||
// Fix for not working float values in mission params
|
||||
|
|
|
@ -1,14 +0,0 @@
|
|||
private _ratio = 1.0;
|
||||
|
||||
if (GRLIB_adaptive_opfor) then {
|
||||
private _bluforcount = 0.2 * (GRLIB_side_friendly countSide allUnits);
|
||||
_bluforcount = _bluforcount + (count (allPlayers - entities "HeadlessClient_F"));
|
||||
|
||||
_ratio = 0.5 + (_bluforcount / 25.0);
|
||||
|
||||
if (_ratio > 1.0) then {
|
||||
_ratio = 1.0;
|
||||
};
|
||||
};
|
||||
|
||||
_ratio
|
|
@ -1,13 +0,0 @@
|
|||
params ["_classtotest"];
|
||||
|
||||
private _return = false;
|
||||
|
||||
if (isClass (configFile >> "CfgVehicles" >> _classtotest)) then {
|
||||
_return = true;
|
||||
} else {
|
||||
if (isServer) then {
|
||||
diag_log format ["[KP LIBERATION] [CHECKCLASS] %1 not found in CfgVehicles", _classtotest];
|
||||
};
|
||||
};
|
||||
|
||||
_return
|
|
@ -1,7 +0,0 @@
|
|||
params [ "_veh" ];
|
||||
|
||||
if ( isNull _veh ) exitWith {};
|
||||
|
||||
if ( _veh getVariable ["GRLIB_captured", 0] == 0 ) then {
|
||||
deleteVehicle _veh;
|
||||
};
|
|
@ -1,13 +0,0 @@
|
|||
params ["_unit"];
|
||||
|
||||
if (
|
||||
(_unit hasWeapon "Laserdesignator") ||
|
||||
(_unit hasWeapon "Laserdesignator_01_khk_F") ||
|
||||
(_unit hasWeapon "Laserdesignator_02") ||
|
||||
(_unit hasWeapon "Laserdesignator_02_ghex_F") ||
|
||||
(_unit hasWeapon "Laserdesignator_03")
|
||||
) then {
|
||||
if !("Laserbatteries" in (magazines _unit)) then {
|
||||
_unit addMagazine "Laserbatteries";
|
||||
};
|
||||
};
|
|
@ -1,25 +0,0 @@
|
|||
params ["_source", "_permission"];
|
||||
|
||||
if (isNil "GRLIB_last_permission_check_time") then {GRLIB_last_permission_check_time = -1000;};
|
||||
if (isNil "GRLIB_permissions_cache") then {GRLIB_permissions_cache = [];};
|
||||
|
||||
private _ret = false;
|
||||
|
||||
if (!GRLIB_permissions_param) then {
|
||||
_ret = true;
|
||||
} else {
|
||||
if (!(isNil "GRLIB_permissions") && !(isNull _source)) then {
|
||||
|
||||
if ( time > GRLIB_last_permission_check_time + 10) then {
|
||||
GRLIB_last_permission_check_time = time;
|
||||
private _uidvar = getPlayerUID _source;
|
||||
{if (_uidvar == _x select 0) exitWith {GRLIB_permissions_cache = [] + (_x select 2)};} foreach GRLIB_permissions;
|
||||
};
|
||||
|
||||
if (count GRLIB_permissions_cache > _permission) then {
|
||||
_ret = GRLIB_permissions_cache select _permission;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
_ret
|
|
@ -1,2 +0,0 @@
|
|||
params [ "_classname" ];
|
||||
_classname select {[( _x select 0)] call F_checkClass}
|
|
@ -1,103 +0,0 @@
|
|||
params ["_mindist", "_maxdist", "_try_nearest", ["_spawn_target", ""]];
|
||||
|
||||
private _increment = 500;
|
||||
private _opfor_spawn_point = "";
|
||||
private _all_possible_sectors = sectors_opfor;
|
||||
private _filtered_possible_sectors = [];
|
||||
|
||||
{
|
||||
private _current_sector = _x;
|
||||
private _accept_current_sector = true;
|
||||
private _current_sector_distance = 99999;
|
||||
|
||||
if (!isNil "secondary_objective_position") then {
|
||||
if (count secondary_objective_position != 0) then {
|
||||
if (((markerpos _current_sector) distance secondary_objective_position) < 500) then {
|
||||
_accept_current_sector = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
if (!isNil "used_positions") then {
|
||||
if (_current_sector in used_positions) then {
|
||||
_accept_current_sector = false;
|
||||
};
|
||||
};
|
||||
|
||||
{
|
||||
if (((markerpos _current_sector) distance _x) < _mindist) then {
|
||||
_accept_current_sector = false;
|
||||
} else {
|
||||
if (((markerpos _current_sector) distance (_x)) < _current_sector_distance) then {
|
||||
_current_sector_distance = ((markerpos _current_sector ) distance (_x));
|
||||
};
|
||||
};
|
||||
} forEach GRLIB_all_fobs;
|
||||
|
||||
if (_accept_current_sector) then {
|
||||
{
|
||||
if (((markerpos _current_sector) distance (markerpos _x)) < _mindist ) then {
|
||||
_accept_current_sector = false;
|
||||
} else {
|
||||
if (((markerpos _current_sector) distance (markerpos _x)) < _current_sector_distance) then {
|
||||
_current_sector_distance = ((markerpos _current_sector) distance (markerpos _x));
|
||||
};
|
||||
};
|
||||
} forEach blufor_sectors;
|
||||
};
|
||||
|
||||
if (_accept_current_sector) then {
|
||||
private _one_opfor_sector_in_range = false;
|
||||
{
|
||||
if (((markerpos _current_sector) distance (markerpos _x)) < 2000) exitWith {_one_opfor_sector_in_range = true;}
|
||||
} forEach (sectors_allSectors - blufor_sectors);
|
||||
_accept_current_sector = _one_opfor_sector_in_range;
|
||||
};
|
||||
|
||||
if (_accept_current_sector) then {
|
||||
if (([markerpos _current_sector, _mindist, GRLIB_side_friendly] call F_getUnitsCount) != 0) then {
|
||||
_accept_current_sector = false;
|
||||
};
|
||||
};
|
||||
|
||||
if (_accept_current_sector) then {
|
||||
_filtered_possible_sectors pushback [_current_sector,_current_sector_distance];
|
||||
};
|
||||
} forEach _all_possible_sectors;
|
||||
|
||||
if (count _filtered_possible_sectors != 0) then {
|
||||
|
||||
private _nearest_possible_sectors = [];
|
||||
|
||||
if (_try_nearest) then {
|
||||
private _maxsearchdist = _mindist + _increment;
|
||||
while {(count _nearest_possible_sectors == 0) && (_maxsearchdist <= _maxdist)} do {
|
||||
{
|
||||
_nextsector = _x select 0;
|
||||
_nextdistance = _x select 1;
|
||||
if (_nextdistance < _maxsearchdist) exitWith {_nearest_possible_sectors pushback _nextsector;};
|
||||
} forEach _filtered_possible_sectors;
|
||||
_maxsearchdist = _maxsearchdist + _increment;
|
||||
};
|
||||
} else {
|
||||
{
|
||||
_nextsector = _x select 0;
|
||||
_nextdistance = _x select 1;
|
||||
if (_nextdistance < _maxdist) then {
|
||||
_nearest_possible_sectors pushback _nextsector;
|
||||
};
|
||||
} foreach _filtered_possible_sectors;
|
||||
};
|
||||
|
||||
if (count _nearest_possible_sectors != 0) then {
|
||||
if (_spawn_target == "") then {
|
||||
_opfor_spawn_point = _nearest_possible_sectors select (floor (random (count _nearest_possible_sectors)));
|
||||
} else {
|
||||
_opfor_spawn_point = ([_nearest_possible_sectors, [_spawn_target] , {(getmarkerpos _input0) distance (getmarkerpos _x)} , "ASCEND"] call BIS_fnc_sortBy) select 0;
|
||||
};
|
||||
} else {
|
||||
diag_log "[KP LIBERATION] [WARNING] No opfor spawn point found";
|
||||
};
|
||||
};
|
||||
|
||||
_opfor_spawn_point
|
|
@ -1,21 +0,0 @@
|
|||
params [ "_veh" ];
|
||||
private [ "_grp" ];
|
||||
|
||||
createVehicleCrew _veh;
|
||||
|
||||
if ( count crew _veh > 0 ) then {
|
||||
if ( side (group ((crew _veh) select 0)) != GRLIB_side_friendly ) then {
|
||||
{ deleteVehicle _x } foreach (crew _veh);
|
||||
|
||||
_grp = createGroup [GRLIB_side_friendly, true];
|
||||
while { count units _grp < 3 } do {
|
||||
crewman_classname createUnit [ getPos _veh, _grp, 'this addMPEventHandler ["MPKilled", {_this spawn kill_manager}] '];
|
||||
};
|
||||
((units _grp) select 0) moveInDriver _veh;
|
||||
((units _grp) select 1) moveInGunner _veh;
|
||||
((units _grp) select 2) moveInCommander _veh;
|
||||
|
||||
{ if ( vehicle _x == _x ) then { deleteVehicle _x }; } foreach (units _grp);
|
||||
};
|
||||
(group ((crew _veh) select 0)) setBehaviour "SAFE";
|
||||
};
|
|
@ -1,39 +0,0 @@
|
|||
params [["_type","milita"]];
|
||||
|
||||
private _squadcomp = [];
|
||||
|
||||
if (_type == "army") then {
|
||||
private _specialists = false;
|
||||
private _randomchance = -55;
|
||||
_squadcomp = opfor_squad_8_standard;
|
||||
|
||||
if (armor_weight > 40 && !_specialists) then {
|
||||
_randomchance = (armor_weight - 40) * 1.35;
|
||||
if ((random 100) < _randomchance) then {
|
||||
_specialists = true;
|
||||
_squadcomp = opfor_squad_8_tankkillers;
|
||||
};
|
||||
};
|
||||
|
||||
if (air_weight > 40 && !_specialists) then {
|
||||
_randomchance = (air_weight - 40) * 1.35;
|
||||
if ((random 100) < _randomchance) then {
|
||||
_specialists = true;
|
||||
_squadcomp = opfor_squad_8_airkillers;
|
||||
};
|
||||
};
|
||||
|
||||
if (infantry_weight > 40 && !_specialists) then {
|
||||
_randomchance = (infantry_weight - 40) * 1.35;
|
||||
if ((random 100) < _randomchance) then {
|
||||
_specialists = true;
|
||||
_squadcomp = opfor_squad_8_infkillers;
|
||||
};
|
||||
};
|
||||
} else {
|
||||
private _multiplier = 1;
|
||||
if (GRLIB_unitcap < 1) then {_multiplier = GRLIB_unitcap;};
|
||||
while {count _squadcomp < (10 * _multiplier)} do {_squadcomp pushback (selectRandom militia_squad)};
|
||||
};
|
||||
|
||||
_squadcomp
|
|
@ -1,7 +0,0 @@
|
|||
private _vehicle_to_spawn = selectRandom opfor_vehicles;
|
||||
|
||||
if (combat_readiness < 35) then {
|
||||
_vehicle_to_spawn = selectRandom opfor_vehicles_low_intensity;
|
||||
};
|
||||
|
||||
_vehicle_to_spawn;
|
|
@ -1,9 +0,0 @@
|
|||
private [ "_commanderobj" ];
|
||||
|
||||
_commanderobj = objNull;
|
||||
|
||||
if (!isNil "commandant") then {
|
||||
{ if ( _x == commandant ) exitWith { _commanderobj = _x }; } foreach allPlayers;
|
||||
};
|
||||
|
||||
_commanderobj
|
|
@ -1,13 +0,0 @@
|
|||
params ["_opforcount"];
|
||||
|
||||
private _corrected_sector_size = GRLIB_sector_size;
|
||||
|
||||
if (_opforcount >= (0.5 * GRLIB_sector_cap)) then {
|
||||
if (_opforcount <= GRLIB_sector_cap) then {
|
||||
_corrected_sector_size = GRLIB_sector_size - (GRLIB_sector_size * 0.5 * ((_opforcount / GRLIB_sector_cap) - 0.5));
|
||||
} else {
|
||||
_corrected_sector_size = GRLIB_sector_size * 0.75;
|
||||
};
|
||||
};
|
||||
|
||||
_corrected_sector_size
|
|
@ -1,19 +0,0 @@
|
|||
params [ "_fob" ];
|
||||
private [ "_fobindex", "_currentidx", "_fobname" ];
|
||||
|
||||
_fobname = "";
|
||||
_fobindex = -1;
|
||||
_currentidx = 0;
|
||||
{
|
||||
if ( _x distance _fob < 100 ) then {
|
||||
_fobindex = _currentidx;
|
||||
};
|
||||
_currentidx = _currentidx + 1;
|
||||
} foreach GRLIB_all_fobs;
|
||||
|
||||
_fobname = "";
|
||||
if ( _fobindex != -1 ) then {
|
||||
_fobname = military_alphabet select _fobindex;
|
||||
};
|
||||
|
||||
_fobname
|
|
@ -1,23 +0,0 @@
|
|||
params [ "_sector" ];
|
||||
private [ "_actual_capture_size", "_red_forces", "_blue_forces", "_ratio" ];
|
||||
|
||||
_actual_capture_size = GRLIB_capture_size;
|
||||
if ( _sector in sectors_bigtown ) then {
|
||||
_actual_capture_size = GRLIB_capture_size * 1.4;
|
||||
};
|
||||
|
||||
_red_forces = [ (markerpos _sector), _actual_capture_size, GRLIB_side_enemy ] call F_getUnitsCount;
|
||||
_blue_forces = [ (markerpos _sector), _actual_capture_size, GRLIB_side_friendly ] call F_getUnitsCount;
|
||||
_ratio = -1;
|
||||
|
||||
if (_red_forces > 0) then {
|
||||
_ratio = _blue_forces / ( _red_forces + _blue_forces );
|
||||
} else {
|
||||
if ( _sector in blufor_sectors || _blue_forces != 0 ) then {
|
||||
_ratio = 1;
|
||||
} else {
|
||||
_ratio = 0;
|
||||
};
|
||||
};
|
||||
|
||||
_ratio
|
|
@ -1,62 +0,0 @@
|
|||
params [ "_grp" ];
|
||||
private [ "_grouptype", "_vehicletype" ];
|
||||
|
||||
_grouptype = 'infantry';
|
||||
_vehicletype = '';
|
||||
{
|
||||
if ( vehicle _x != _x && _vehicletype == '' ) then {
|
||||
if ( ((gunner vehicle _x) == _x) || ((driver vehicle _x) == _x) || ((commander vehicle _x) == _x) ) then {
|
||||
_vehicletype = typeof vehicle _x;
|
||||
};
|
||||
};
|
||||
} foreach units _grp;
|
||||
|
||||
if ((_grouptype == 'infantry') && (_vehicletype != '')) then {
|
||||
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'heavy';
|
||||
};
|
||||
} foreach heavy_vehicles;
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'air';
|
||||
};
|
||||
} foreach air_vehicles;
|
||||
};
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'light';
|
||||
};
|
||||
} foreach light_vehicles;
|
||||
};
|
||||
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'support';
|
||||
};
|
||||
} foreach support_vehicles;
|
||||
};
|
||||
|
||||
if ( _grouptype == 'infantry' ) then {
|
||||
{
|
||||
if ( _vehicletype == (_x select 0)) then {
|
||||
_grouptype = 'static';
|
||||
};
|
||||
} foreach static_vehicles;
|
||||
};
|
||||
|
||||
// Check if vehicle config says it's an UAV, if it is always set its _grouptype to 'uav'
|
||||
if ( (_vehicletype call F_isClassUAV) ) then {
|
||||
_grouptype = 'uav';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
_grouptype
|
|
@ -1,280 +0,0 @@
|
|||
/*
|
||||
|
||||
AUTHOR: aeroson
|
||||
NAME: get_loadout.sqf
|
||||
VERSION: 3.4
|
||||
|
||||
DOWNLOAD & PARTICIPATE:
|
||||
https://github.com/aeroson/a3-loadout
|
||||
http://forums.bistudio.com/showthread.php?148577-GET-SET-Loadout-(saves-and-loads-pretty-much-everything)
|
||||
|
||||
DESCRIPTION:
|
||||
I guarantee backwards compatibility.
|
||||
These scripts allows you set/get (load/save)all of the unit's gear, including:
|
||||
uniform, vest, backpack, contents of it, all quiped items, all three weapons with their attachments, currently loaded magazines and number of ammo in magazines.
|
||||
All this while preserving order of items.
|
||||
Useful for saving/loading loadouts.
|
||||
Ideal for revive scripts where you have to set exactly the same loadout to newly created unit.
|
||||
Uses workaround with placeholders to add vest/backpack items, so items stay where you put them.
|
||||
|
||||
PARAMETER(S):
|
||||
0 : target unit
|
||||
1 : (optional) array of options, default [] :
|
||||
"ammo" will save ammo count of partially emptied magazines
|
||||
"repetitive" intended for repetitive use, will not use selectWeapon, means no visible effect on solder, but will not save magazines of assigned items such as laser designator batteries
|
||||
|
||||
RETURNS:
|
||||
Array : array of strings/arrays containing target unit's loadout, to be used by fnc_set_loadout.sqf
|
||||
|
||||
addAction support:
|
||||
Saves player's loadout into global var loadout
|
||||
|
||||
*/
|
||||
|
||||
private ["_target","_options","_saveMagsAmmo","_isRepetitive","_isOnFoot","_currentWeapon","_currentMode","_isFlashlightOn","_isIRLaserOn","_magazinesAmmo","_loadedMagazines","_saveWeaponMagazines","_getMagsAmmo","_backPackItems","_assignedItems","_data"];
|
||||
|
||||
_options = [];
|
||||
|
||||
// addAction support
|
||||
if(count _this < 4) then {
|
||||
#define PARAM_START private ["_PARAM_INDEX"]; _PARAM_INDEX=0;
|
||||
#define PARAM_REQ(A) if (count _this <= _PARAM_INDEX) exitWith { systemChat format["required param '%1' not supplied in file:'%2' at line:%3", #A ,__FILE__,__LINE__]; }; A = _this select _PARAM_INDEX; _PARAM_INDEX=_PARAM_INDEX+1;
|
||||
#define PARAM(A,B) A = B; if (count _this > _PARAM_INDEX) then { A = _this select _PARAM_INDEX; }; _PARAM_INDEX=_PARAM_INDEX+1;
|
||||
PARAM_START
|
||||
PARAM_REQ(_target)
|
||||
PARAM(_options,[])
|
||||
} else {
|
||||
_target = player;
|
||||
};
|
||||
|
||||
_saveMagsAmmo = "ammo" in _options;
|
||||
_isRepetitive = "repetitive" in _options;
|
||||
_isOnFoot = vehicle _target == _target;
|
||||
|
||||
_currentWeapon = "";
|
||||
_currentMode = "";
|
||||
_isFlashlightOn = false;
|
||||
_isIRLaserOn = false;
|
||||
|
||||
_magazinesAmmo = magazinesAmmoFull _target;
|
||||
|
||||
// save weapon mode and muzzle
|
||||
if(_isOnFoot) then {
|
||||
_currentWeapon = currentMuzzle _target;
|
||||
_currentMode = currentWeaponMode _target;
|
||||
_isFlashlightOn = _target isFlashlightOn _currentWeapon;
|
||||
_isIRLaserOn = _target isIRLaserOn _currentWeapon;
|
||||
} else {
|
||||
_currentWeapon = currentWeapon _target;
|
||||
};
|
||||
|
||||
|
||||
_loadedMagazines=[];
|
||||
|
||||
// universal weapon saving
|
||||
_saveWeaponMagazines = {
|
||||
private ["_weapon","_magazines","_muzzles","_saveMagazine"];
|
||||
_weapon = _this select 0;
|
||||
_magazines = [];
|
||||
|
||||
_saveMagazine = { // find, save and eat mag for _weapon
|
||||
private ["_weapon","_magazine","_ammo"];
|
||||
_weapon = _this select 0;
|
||||
_magazine = "";
|
||||
_ammo = 0;
|
||||
{
|
||||
if((_x select 4)==_weapon) then {
|
||||
_magazine = _x select 0;
|
||||
_ammo = _x select 1;
|
||||
_x = -1;
|
||||
};
|
||||
} forEach _magazinesAmmo;
|
||||
_magazinesAmmo = _magazinesAmmo - [-1];
|
||||
if(_magazine!="") then {
|
||||
if(_saveMagsAmmo) then {
|
||||
_magazines set [count _magazines, [_magazine, _ammo]];
|
||||
} else {
|
||||
_magazines set [count _magazines, _magazine];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
if(_weapon != "") then {
|
||||
[_weapon] call _saveMagazine;
|
||||
_muzzles = configFile>>"CfgWeapons">>_weapon>>"muzzles";
|
||||
if(isArray(_muzzles)) then {
|
||||
{ // add one mag for each muzzle
|
||||
if (_x != "this") then {
|
||||
[_x] call _saveMagazine;
|
||||
};
|
||||
} forEach getArray(_muzzles);
|
||||
};
|
||||
};
|
||||
|
||||
_loadedMagazines set [count _loadedMagazines, _magazines];
|
||||
};
|
||||
|
||||
// save loaded mags for each weapon separetely, since some weapons can use same magazines
|
||||
[primaryWeapon _target] call _saveWeaponMagazines;
|
||||
[handgunWeapon _target] call _saveWeaponMagazines;
|
||||
[secondaryWeapon _target] call _saveWeaponMagazines;
|
||||
|
||||
_getMagsAmmo = { // default function with _saveMagsAmmo == false
|
||||
_this select 0;
|
||||
};
|
||||
if(_saveMagsAmmo) then {
|
||||
// check if input array contains magazine, if it does, find it add ammo count
|
||||
_getMagsAmmo = {
|
||||
private ["_items","_location","_item","_itemIndex"];
|
||||
_items = _this select 0;
|
||||
_location = _this select 1;
|
||||
{
|
||||
_item = _x;
|
||||
_itemIndex = _forEachIndex;
|
||||
{
|
||||
if((_x select 4)==_location && (_x select 0)==_item) then {
|
||||
_items set[_itemIndex, [_item, _x select 1]];
|
||||
_x = -1;
|
||||
};
|
||||
} forEach _magazinesAmmo;
|
||||
_magazinesAmmo = _magazinesAmmo - [-1];
|
||||
} forEach _items;
|
||||
_items;
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
// get backpack items
|
||||
_cargo = getbackpackcargo (unitbackpack _target);
|
||||
_backpacks = [];
|
||||
{
|
||||
for "_i" from 1 to ((_cargo select 1) select _foreachindex) do {
|
||||
_backpacks set [count _backpacks, _x];
|
||||
};
|
||||
} foreach (_cargo select 0);
|
||||
_backPackItems = (backpackitems _target) + _backpacks;
|
||||
|
||||
// get assigned items, headgear and goggles is not part of assignedItems
|
||||
_assignedItems = assignedItems _target;
|
||||
_headgear = headgear _target;
|
||||
_goggles = goggles _target;
|
||||
if((_headgear != "") && !(_headgear in _assignedItems)) then {
|
||||
_assignedItems set [count _assignedItems, _headgear];
|
||||
};
|
||||
if((_goggles != "") && !(_goggles in _assignedItems)) then {
|
||||
_assignedItems set [count _assignedItems, _goggles];
|
||||
};
|
||||
|
||||
|
||||
|
||||
/*
|
||||
// use this once magazinesAmmoFull is fixed and shows magazines of assignedItems
|
||||
|
||||
// get magazines of everything else except weapons, most likely assigned items
|
||||
// only ["Uniform","Vest","Backpack"] locations remain, weapon locations have already been eaten
|
||||
_magazines = [];
|
||||
{
|
||||
if(_x select 2) then {
|
||||
if(_saveMagsAmmo) then {
|
||||
_magazines set[count _magazines, [_x select 0, _x select 1]];
|
||||
} else {
|
||||
_magazines set[count _magazines, _x select 0];
|
||||
};
|
||||
_x = -1;
|
||||
};
|
||||
} forEach _magazinesAmmo;
|
||||
_magazinesAmmo = _magazinesAmmo - [-1];
|
||||
_loadedMagazines set [3, _magazines];
|
||||
*/
|
||||
|
||||
|
||||
// old method using selectWeapon, cycles and tries to selectWeapon all assigned items
|
||||
if(!_isRepetitive) then {
|
||||
private ["_weaponHasChanged"];
|
||||
_weaponHasChanged = false;
|
||||
|
||||
// get magazines of all assigned items
|
||||
_magazines = [];
|
||||
{
|
||||
_target selectWeapon _x;
|
||||
if(currentWeapon _target==_x) then {
|
||||
_weaponHasChanged = true;
|
||||
_magazine = currentMagazine _target;
|
||||
if(_magazine != "") then {
|
||||
if(_saveMagsAmmo) then {
|
||||
_magazines set[count _magazines, [_magazine, _target ammo _x]];
|
||||
} else {
|
||||
_magazines set[count _magazines, _magazine];
|
||||
};
|
||||
};
|
||||
};
|
||||
} forEach _assignedItems;
|
||||
_loadedMagazines set [3, _magazines];
|
||||
|
||||
// select back originaly selected weapon and mode, only if weapon has changed
|
||||
if(_weaponHasChanged) then {
|
||||
if(_isOnFoot) then {
|
||||
if(_currentWeapon != "" && _currentMode != "") then {
|
||||
_muzzles = 0;
|
||||
while{ (_currentWeapon != currentMuzzle _target || _currentMode != currentWeaponMode _target ) && _muzzles < 200 } do {
|
||||
_target action ["SWITCHWEAPON", _target, _target, _muzzles];
|
||||
_muzzles = _muzzles + 1;
|
||||
};
|
||||
if(_isFlashlightOn) then {
|
||||
_target action ["GunLightOn"];
|
||||
} else {
|
||||
_target action ["GunLightOff"];
|
||||
};
|
||||
if(_isIRLaserOn) then {
|
||||
_target action ["IRLaserOn"];
|
||||
} else {
|
||||
_target action ["IRLaserOff"];
|
||||
};
|
||||
};
|
||||
} else {
|
||||
_currentMode = "";
|
||||
};
|
||||
if(_currentMode == "") then {
|
||||
if(_currentWeapon=="") then {
|
||||
_target action ["SWITCHWEAPON", _target, _target, 0];
|
||||
} else {
|
||||
_target selectWeapon _currentWeapon;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
_data = [
|
||||
_assignedItems, //0 []
|
||||
|
||||
primaryWeapon _target, //1 ""
|
||||
primaryWeaponItems _target, //2 []
|
||||
|
||||
handgunWeapon _target, //3 ""
|
||||
handgunItems _target, //4 []
|
||||
|
||||
secondaryWeapon _target, //5 ""
|
||||
secondaryWeaponItems _target, //6 []
|
||||
|
||||
uniform _target, //7 ""
|
||||
[uniformItems _target, "Uniform"] call _getMagsAmmo, //8 ["magazine without ammo count",["magazine with ammo count",30], ....]
|
||||
|
||||
vest _target, //9 ""
|
||||
[vestItems _target, "Vest"] call _getMagsAmmo, //10
|
||||
|
||||
backpack _target, //11 ""
|
||||
[_backPackItems, "Backpack"] call _getMagsAmmo, //12
|
||||
|
||||
_loadedMagazines, //13 (optional) [[primary mags],[handgun mags],[secondary mags],[other mags]]
|
||||
_currentWeapon, //14 (optional) ""
|
||||
_currentMode //15 (optional) ""
|
||||
];
|
||||
|
||||
// addAction support
|
||||
if(count _this < 4) then {
|
||||
_data;
|
||||
} else {
|
||||
loadout = _data;
|
||||
//playSound3D ["A3\Sounds_F\sfx\ZoomOut.wav", _target];
|
||||
};
|
|
@ -1,11 +0,0 @@
|
|||
params [ "_attacked_position" ];
|
||||
private [ "_attacked_string" ];
|
||||
|
||||
_attacked_string = [ _attacked_position ] call F_getFobName;
|
||||
if ( _attacked_string == "" ) then {
|
||||
_attacked_string = markerText ( [50, _attacked_position ] call F_getNearestSector );
|
||||
} else {
|
||||
_attacked_string = format [ "FOB %1", _attacked_string ];
|
||||
};
|
||||
|
||||
_attacked_string
|
|
@ -1,10 +0,0 @@
|
|||
private _respawn_trucks_unsorted = vehicles select {
|
||||
(typeof _x == Respawn_truck_typename || typeof _x == huron_typename ) &&
|
||||
_x distance2d startbase > 500 &&
|
||||
!surfaceIsWater (getpos _x) &&
|
||||
isTouchingGround _x &&
|
||||
alive _x &&
|
||||
speed _x < 5
|
||||
};
|
||||
|
||||
[_respawn_trucks_unsorted, [], {(getpos _x) select 0}, 'ASCEND'] call BIS_fnc_sortBy
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue