develop #21
@@ -17,6 +17,7 @@
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "mission_settings.hpp"
|
||||
#include "framework\script_mod.hpp"
|
||||
#include "defines\ApprovedAssets.hpp"
|
||||
#include "defines\BattalionInfo.hpp"
|
||||
#include "defines\DisallowedEquipment.hpp"
|
||||
@@ -94,7 +95,7 @@ class Params
|
||||
|
||||
class cfgFunctions
|
||||
{
|
||||
#include "functions\CfgFunctions.hpp"
|
||||
#include "framework\CfgFunctions.hpp"
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@ class milsim
|
||||
{
|
||||
class settings
|
||||
{
|
||||
file = "framework\settings";
|
||||
class setDefaults { postInit = 1; };
|
||||
class addCBASettings { postInit = 1; };
|
||||
class addAARChatHandler { postInit = 1; };
|
||||
@@ -10,11 +11,13 @@ class milsim
|
||||
|
||||
class init
|
||||
{
|
||||
file = "framework\init";
|
||||
class initServer { postInit = 1;}; //needs refactor
|
||||
class initPlayerLocal { postInit = 1;};
|
||||
};
|
||||
|
||||
class fbcb2 {
|
||||
file = "framework\fbcb2";
|
||||
class initFBCB2 { postInit = 1; };
|
||||
class processFBCB2RadioFrequencies {};
|
||||
class processFBCB2SmokeColors {};
|
||||
@@ -22,16 +25,17 @@ class milsim
|
||||
class hintFBCB2AssetStatus {};
|
||||
};
|
||||
class fbcb2_util {
|
||||
file = "functions\fbcb2\util";
|
||||
file = "framework\fbcb2\util";
|
||||
class createOrUpdateDiaryRecord {};
|
||||
};
|
||||
class fbcb2_radioFrequencies {
|
||||
file = "functions\fbcb2\radioFrequencies";
|
||||
file = "framework\fbcb2\radioFrequencies";
|
||||
class formatRadioElementForDiary {};
|
||||
class generateElementFrequencyRecordText {};
|
||||
};
|
||||
|
||||
class client {
|
||||
file = "framework\client";
|
||||
class addZenModules { postInit = 1; };
|
||||
class addDNI_PlayerFPS { postInit = 1; }; // needs refactor
|
||||
class bindEventHandlers { postInit = 1; };
|
||||
@@ -43,18 +47,21 @@ class milsim
|
||||
};
|
||||
|
||||
class server {
|
||||
file = "framework\server";
|
||||
class addServerStatsPFH {};
|
||||
class calculateServerStats {};
|
||||
class logPlayerInventory {};
|
||||
};
|
||||
|
||||
class ambience {
|
||||
file = "framework\ambience";
|
||||
class flakInitVehicle {};
|
||||
class flakEH {};
|
||||
};
|
||||
|
||||
class map
|
||||
{
|
||||
file = "framework\map";
|
||||
class initMapCopy { postInit = 1; };
|
||||
class copyMapFromPlayer {}; //needs refactor
|
||||
class getPlayerMapMarkers {}; //needs refactor
|
||||
@@ -62,9 +69,11 @@ class milsim
|
||||
class mapMarkerToString {}; //needs refactor
|
||||
class stringToMapMarker {}; //needs refactor
|
||||
};
|
||||
};
|
||||
|
||||
class util
|
||||
{
|
||||
class milsim_util {
|
||||
class functions {
|
||||
file = "framework\util";
|
||||
class logMissionInfo { postInit = 1; };
|
||||
class addPlayerInfoToArray {};
|
||||
class log {};
|
||||
@@ -78,14 +87,9 @@ class milsim
|
||||
|
||||
class milsim_resupply {
|
||||
class functions {
|
||||
file = "functions\resupply";
|
||||
class createAmmoBox {};
|
||||
file = "framework\resupply\functions";
|
||||
class init {postInit=1;};
|
||||
class createBox {};
|
||||
class createCSWBox {};
|
||||
class createLaunchersBox {};
|
||||
class createMedicalBox {};
|
||||
class createMortarBox {};
|
||||
class createWeaponsBox {};
|
||||
class getSupplyCratesCfg {};
|
||||
class addArsenalObjectSpawnBoxActions {};
|
||||
class addCBASettings {postInit=1;};
|
||||
@@ -94,7 +98,7 @@ class milsim_resupply {
|
||||
|
||||
class milsim_fbcb2_assets {
|
||||
class functions {
|
||||
file = "functions\fbcb2\assets";
|
||||
file = "framework\fbcb2\assets";
|
||||
class updateAssetDiary {};
|
||||
class removeAssetDiaryRecords {};
|
||||
class getMagsForWeapon {};
|
||||
@@ -103,21 +107,31 @@ class milsim_fbcb2_assets {
|
||||
class getVehicleData {};
|
||||
};
|
||||
class assetsByBase {
|
||||
file = "functions\fbcb2\assets\byBase";
|
||||
file = "framework\fbcb2\assets\byBase";
|
||||
class getAssetsByBase {};
|
||||
class getStartingAssetsByBase {};
|
||||
class updateAssetsByBase {};
|
||||
};
|
||||
class markers {
|
||||
file = "functions\fbcb2\assets\markers";
|
||||
file = "framework\fbcb2\assets\markers";
|
||||
class showMarkersOnMap {};
|
||||
class removeMarkersOnMap {};
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
class milsim_vehicleFlags {
|
||||
class functions {
|
||||
file = "framework\vehicleFlags\functions";
|
||||
class init {postInit=1;};
|
||||
class getActionsFlagCategories {};
|
||||
class getVehicleFlagsCfg {};
|
||||
class isClassExcluded {};
|
||||
};
|
||||
};
|
||||
|
||||
class milsim_reinsert {
|
||||
class server {
|
||||
file = "functions\reinsert\server";
|
||||
file = "framework\reinsert\server";
|
||||
class initServer { postInit = 1; };
|
||||
class addToQueue {};
|
||||
class globalShowQueue {};
|
||||
@@ -126,20 +140,10 @@ class milsim_reinsert {
|
||||
class validateQueue {};
|
||||
};
|
||||
class client {
|
||||
file = "functions\reinsert\client";
|
||||
file = "framework\reinsert\client";
|
||||
class initClient { postInit = 1; };
|
||||
class addAceSelfActions {};
|
||||
class addCheckQueueSelfAction {};
|
||||
class requestShowQueue {};
|
||||
};
|
||||
};
|
||||
|
||||
class milsim_vehicleFlags {
|
||||
class functions {
|
||||
file = "functions\vehicleFlags";
|
||||
class initVehicleFlags {postInit = 1};
|
||||
class getActionsFlagCategories {};
|
||||
class getVehicleFlagsCfg {};
|
||||
class isClassExcluded{};
|
||||
};
|
||||
};
|
||||
@@ -8,8 +8,8 @@ player addEventHandler["Respawn",
|
||||
[
|
||||
"client",
|
||||
"RESPAWNED WHILE UNCONSCIOUS",
|
||||
[_unit] call milsim_fnc_addPlayerInfoToArray
|
||||
] remoteExec ["milsim_fnc_log", 2];
|
||||
[_unit] call milsim_util_fnc_addPlayerInfoToArray
|
||||
] remoteExec ["milsim_util_fnc_log", 2];
|
||||
// format["%1 was unconscious then clicked the respawn button", name _unit] remoteExec["systemChat", 0];
|
||||
};
|
||||
}
|
||||
@@ -43,11 +43,11 @@ addMissionEventHandler ["HandleChatMessage",
|
||||
|
||||
|
||||
["ace_arsenal_displayClosed", {
|
||||
[player] remoteExec ["milsim_fnc_logPlayerInventory", 2];
|
||||
[player] remoteExec ["milsim_util_fnc_logPlayerInventory", 2];
|
||||
}] call CBA_fnc_addEventHandler;
|
||||
|
||||
[missionNamespace, "arsenalClosed", {
|
||||
[player] remoteExec ["milsim_fnc_logPlayerInventory", 2];
|
||||
[player] remoteExec ["milsim_util_fnc_logPlayerInventory", 2];
|
||||
}] call BIS_fnc_addScriptedEventHandler;
|
||||
|
||||
diag_log text "[MILSIM] (client) event handlers bound";
|
||||
@@ -23,7 +23,7 @@ private _assetsStartedAtThisBaseVar = "milsim_fbcb2_assets_assetsStartedAtThisBa
|
||||
private _asset = _x;
|
||||
// avoid duplicates
|
||||
if (_asset in _allSaved) then {continue};
|
||||
private _closestBase = [_asset] call milsim_fnc_getNearestBase;
|
||||
private _closestBase = [_asset] call milsim_util_fnc_getNearestBase;
|
||||
if (isNull _closestBase) then {
|
||||
// no base found
|
||||
continue;
|
||||
@@ -66,7 +66,7 @@ private _assetsStartedAtThisBaseVar = "milsim_fbcb2_assets_assetsStartedAtThisBa
|
||||
// avoid duplicates
|
||||
if (_asset in _allSaved) then {continue};
|
||||
|
||||
private _closestBase = [_asset] call milsim_fnc_getNearestBase;
|
||||
private _closestBase = [_asset] call milsim_util_fnc_getNearestBase;
|
||||
if (isNull _closestBase) then {
|
||||
// no base found
|
||||
continue;
|
||||
@@ -156,10 +156,10 @@ if !(_isInit || _logCurrentAssets) exitWith {};
|
||||
"fbcb2_assets",
|
||||
"CURRENT ASSETS",
|
||||
[
|
||||
["baseName", [[_base] call milsim_fnc_getNameOfBase]],
|
||||
["baseName", [[_base] call milsim_util_fnc_getNameOfBase]],
|
||||
["asset", _x]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
} forEach _baseAssetsHashes;
|
||||
};
|
||||
|
||||
@@ -170,10 +170,10 @@ if !(_isInit || _logCurrentAssets) exitWith {};
|
||||
"fbcb2_assets",
|
||||
"STARTING ASSETS",
|
||||
[
|
||||
["baseName", [[_base] call milsim_fnc_getNameOfBase]],
|
||||
["baseName", [[_base] call milsim_util_fnc_getNameOfBase]],
|
||||
["asset", _x]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
} forEach _baseAssetsHashes;
|
||||
};
|
||||
} forEach milsim_baseObjects;
|
||||
@@ -180,6 +180,6 @@ private _distinctVehiclesClassNames = [];
|
||||
["assetCount", count _vehicles],
|
||||
["distinctAssetCount", count _distinctVehiclesClassNames]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
|
||||
true;
|
||||
@@ -61,7 +61,7 @@ if (not (count _baseMarkerStore > 0)) then {
|
||||
_newMarker setMarkerTypeLocal "mil_flag";
|
||||
_newMarker setMarkerColorLocal "ColorGreen";
|
||||
_newMarker setMarkerSizeLocal [0.7, 0.7];
|
||||
_newMarker setMarkerTextLocal ([_base] call milsim_fnc_getNameOfBase);
|
||||
_newMarker setMarkerTextLocal ([_base] call milsim_util_fnc_getNameOfBase);
|
||||
|
||||
_baseMarkerStore pushBack [
|
||||
_base,
|
||||
@@ -4,7 +4,7 @@
|
||||
////////////////////////////////////////
|
||||
// Get info from missionConfigFile
|
||||
////////////////////////////////////////
|
||||
private _battalionInfoCfg = call milsim_fnc_getBattalionCfg;
|
||||
private _battalionInfoCfg = call milsim_util_fnc_getBattalionCfg;
|
||||
private _battalionElementCfgs = [_battalionInfoCfg >> "Command"] call BIS_fnc_returnChildren;
|
||||
|
||||
////////////////////////////////////////
|
||||
@@ -62,8 +62,8 @@ _freqLeadingSpace = _freqLeadingSpace joinString "";
|
||||
_ELEMENT_FREQ_SIZE,
|
||||
_ELEMENT_FREQ_FONT,
|
||||
_FREQ_TEXT_COLOR,
|
||||
[_role, "right", " ", _FREQ_PAD_LENGTH] call milsim_fnc_padString,
|
||||
[_srStr, "right", " ", _FREQ_PAD_LENGTH] call milsim_fnc_padString,
|
||||
[_role, "right", " ", _FREQ_PAD_LENGTH] call milsim_util_fnc_padString,
|
||||
[_srStr, "right", " ", _FREQ_PAD_LENGTH] call milsim_util_fnc_padString,
|
||||
_lrStr
|
||||
];
|
||||
} forEach (getArray (_cfg >> "frequencies"));
|
||||
@@ -51,8 +51,8 @@ private _headers = [
|
||||
_ELEMENT_FREQ_SIZE,
|
||||
_ELEMENT_FREQ_FONT,
|
||||
_FREQ_TEXT_COLOR,
|
||||
["ROLE", "right", " ", _FREQ_PAD_LENGTH] call milsim_fnc_padString,
|
||||
["SR", "right", " ", _FREQ_PAD_LENGTH] call milsim_fnc_padString,
|
||||
["ROLE", "right", " ", _FREQ_PAD_LENGTH] call milsim_util_fnc_padString,
|
||||
["SR", "right", " ", _FREQ_PAD_LENGTH] call milsim_util_fnc_padString,
|
||||
"LR"
|
||||
]
|
||||
];
|
||||
@@ -71,7 +71,7 @@ if (_shouldProcessChildCfgs) then {
|
||||
private _lines = [_cfg, _recurseCounter+1] call milsim_fnc_formatRadioElementForDiary;
|
||||
// private _lines = [_cfg, _indentCount] call t;
|
||||
_allText pushBack (_lines joinString "<br/>");
|
||||
}] call milsim_fnc_recurseSubclasses;
|
||||
}] call milsim_util_fnc_recurseSubclasses;
|
||||
} else {
|
||||
// or if the param was false, just add the battalion element
|
||||
private _lines = [_battalionElement, 1] call milsim_fnc_formatRadioElementForDiary;
|
||||
14
framework/init/fn_initPlayerLocal.sqf
Normal file
14
framework/init/fn_initPlayerLocal.sqf
Normal file
@@ -0,0 +1,14 @@
|
||||
if ( !hasInterface ) exitWith {};
|
||||
|
||||
if (!isServer) then {
|
||||
["milsim_logText", {
|
||||
params [["_strArray", [""], [[]]]];
|
||||
{
|
||||
diag_log text _x;
|
||||
} forEach _strArray;
|
||||
}] call CBA_fnc_addEventHandler;
|
||||
};
|
||||
|
||||
["InitializePlayer", [player, true]] call BIS_fnc_dynamicGroups;
|
||||
|
||||
nil;
|
||||
@@ -13,8 +13,8 @@ private _fileForReinsertAction = [
|
||||
{ // statement
|
||||
params ["_target", "_player", "_params"];
|
||||
// find nearest base or location
|
||||
private _base = [_player] call milsim_fnc_getNearestBase;
|
||||
private _baseName = [_base] call milsim_fnc_getNameOfBase;
|
||||
private _base = [_player] call milsim_util_fnc_getNearestBase;
|
||||
private _baseName = [_base] call milsim_util_fnc_getNameOfBase;
|
||||
// send event to server
|
||||
["milsim_reinsert_fileReinsertRequest", [_player, _base]] call CBA_fnc_serverEvent;
|
||||
// notify player their request was filed
|
||||
@@ -23,7 +23,7 @@ private _fileForReinsertAction = [
|
||||
{ // condition
|
||||
params ["_target", "_player", "_params"];
|
||||
// find nearest base or location
|
||||
private _base = [_player] call milsim_fnc_getNearestBase;
|
||||
private _base = [_player] call milsim_util_fnc_getNearestBase;
|
||||
private _baseDistance = _player distance _base;
|
||||
|
||||
private _maxRangeToReady = missionNamespace getVariable ["milsim_reinsert_setting_reinsertion_maxRangeToReady", 400];
|
||||
@@ -12,7 +12,7 @@ if (!isServer) exitWith {
|
||||
["player", _player],
|
||||
["base", _base]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
};
|
||||
if (
|
||||
isNull _player ||
|
||||
@@ -25,7 +25,7 @@ if (
|
||||
["player", _player],
|
||||
["base", _base]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
};
|
||||
|
||||
|
||||
@@ -41,16 +41,16 @@ publicVariable "milsim_reinsert_reinsertionQueue";
|
||||
|
||||
// log to rpt
|
||||
private _logParams = [
|
||||
["filedAtBase", [_base] call milsim_fnc_getNameOfBase],
|
||||
["filedAtBase", [_base] call milsim_util_fnc_getNameOfBase],
|
||||
["filedAtBaseDistance", _player distance _base],
|
||||
["closestBase", [_nearestBase] call milsim_fnc_getNameOfBase],
|
||||
["closestBase", [_nearestBase] call milsim_util_fnc_getNameOfBase],
|
||||
["closestBaseDistance", _player distance _nearestBase],
|
||||
["maxDistanceSetting", _maxRangeToReady],
|
||||
["inQueueDuration", diag_tickTime - _timeFiled]
|
||||
];
|
||||
_logParams = [_player, _logParams] call milsim_fnc_addPlayerInfoToArray;
|
||||
_logParams = [_player, _logParams] call milsim_util_fnc_addPlayerInfoToArray;
|
||||
[
|
||||
"respawn_reinsertion",
|
||||
"PLAYER FILED REQUEST",
|
||||
_logParams
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
@@ -21,7 +21,7 @@ if (count _timeoutPlayers > 0) then {
|
||||
private _thisBase = _x;
|
||||
|
||||
// Add line for base name
|
||||
_playerLines pushBack ([[_thisBase] call milsim_fnc_getNameOfBase, 1, [0,1,0,1]]);
|
||||
_playerLines pushBack ([[_thisBase] call milsim_util_fnc_getNameOfBase, 1, [0,1,0,1]]);
|
||||
|
||||
// Get players under this base
|
||||
private _thisBasePlayers = _timeoutPlayers select {_x#1 isEqualTo _thisBase};
|
||||
@@ -35,7 +35,7 @@ if (count _timeoutPlayers > 0) then {
|
||||
{ // for each player under this base, add a line
|
||||
_x params ["_player", "_base", "_timeFiled"];
|
||||
// get the closest base to the player
|
||||
private _nearestBase = [_player] call milsim_fnc_getNearestBase;
|
||||
private _nearestBase = [_player] call milsim_util_fnc_getNearestBase;
|
||||
|
||||
// add player to array of players under bases
|
||||
_playerLines pushBack ([format [
|
||||
@@ -47,19 +47,19 @@ if (count _timeoutPlayers > 0) then {
|
||||
|
||||
// log to rpt
|
||||
private _logParams = [
|
||||
["filedAtBase", [_base] call milsim_fnc_getNameOfBase],
|
||||
["filedAtBase", [_base] call milsim_util_fnc_getNameOfBase],
|
||||
["filedAtBaseDistance", _player distance _base],
|
||||
["closestBase", [_nearestBase] call milsim_fnc_getNameOfBase],
|
||||
["closestBase", [_nearestBase] call milsim_util_fnc_getNameOfBase],
|
||||
["closestBaseDistance", _player distance _nearestBase],
|
||||
["maxDistanceSetting", _maxRangeToReady],
|
||||
["inQueueDuration", diag_tickTime - _timeFiled]
|
||||
];
|
||||
_logParams = [_player, _logParams] call milsim_fnc_addPlayerInfoToArray;
|
||||
_logParams = [_player, _logParams] call milsim_util_fnc_addPlayerInfoToArray;
|
||||
[
|
||||
"respawn_reinsertion",
|
||||
"PLAYER WAITING OVER TIMEOUT",
|
||||
_logParams
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
} forEach _thisBasePlayers;
|
||||
} forEach _basesWithPeople;
|
||||
|
||||
@@ -7,7 +7,7 @@ if (!isServer) exitWith {
|
||||
[
|
||||
["player", _player]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
};
|
||||
if (isNull _player) exitWith {
|
||||
[
|
||||
@@ -16,7 +16,7 @@ if (isNull _player) exitWith {
|
||||
[
|
||||
["player", _player]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
};
|
||||
|
||||
// get entries for this player from queue
|
||||
@@ -39,19 +39,19 @@ publicVariable "milsim_reinsert_reinsertionQueue";
|
||||
// get first entry (longest wait)
|
||||
(_unitArrs#0) params ["_player", "_base", "_timeFiled"]; // _unitArr = [unit, base, timeInQueue]
|
||||
// get the closest base to the player
|
||||
private _nearestBase = [_player] call milsim_fnc_getNearestBase;
|
||||
private _nearestBase = [_player] call milsim_util_fnc_getNearestBase;
|
||||
// log to rpt
|
||||
private _logParams = [
|
||||
["filedAtBase", [_base] call milsim_fnc_getNameOfBase],
|
||||
["filedAtBase", [_base] call milsim_util_fnc_getNameOfBase],
|
||||
["filedAtBaseDistance", _player distance _base],
|
||||
["closestBase", [_nearestBase] call milsim_fnc_getNameOfBase],
|
||||
["closestBase", [_nearestBase] call milsim_util_fnc_getNameOfBase],
|
||||
["closestBaseDistance", _player distance _nearestBase],
|
||||
["maxDistanceSetting", _maxRangeToReady],
|
||||
["inQueueDuration", diag_tickTime - _timeFiled]
|
||||
];
|
||||
_logParams = [_player, _logParams] call milsim_fnc_addPlayerInfoToArray;
|
||||
_logParams = [_player, _logParams] call milsim_util_fnc_addPlayerInfoToArray;
|
||||
[
|
||||
"respawn_reinsertion",
|
||||
"PLAYER RESCINDED REQUEST",
|
||||
_logParams
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
@@ -25,12 +25,12 @@ if (isNull _userObject) exitWith {
|
||||
};
|
||||
|
||||
// log to rpt
|
||||
private _logParams = [_userObject, []] call milsim_fnc_addPlayerInfoToArray;
|
||||
private _logParams = [_userObject, []] call milsim_util_fnc_addPlayerInfoToArray;
|
||||
[
|
||||
"respawn_reinsertion",
|
||||
"SHOW QUEUE REQUESTED",
|
||||
_logParams
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
|
||||
private _queue = missionNamespace getVariable ["milsim_reinsert_reinsertionQueue", []];
|
||||
// get base objects from queue
|
||||
@@ -48,7 +48,7 @@ if (count _basesWithPeople isEqualTo 0) then {
|
||||
// forEach _basesWithPeople
|
||||
{
|
||||
private _thisBase = _x;
|
||||
private _baseName = [_thisBase] call milsim_fnc_getNameOfBase;
|
||||
private _baseName = [_thisBase] call milsim_util_fnc_getNameOfBase;
|
||||
|
||||
// generate player lines for this base
|
||||
private _playerLines = _queue select {
|
||||
@@ -7,26 +7,26 @@ private _maxRangeToReady = missionNamespace getVariable ["milsim_reinsert_settin
|
||||
|
||||
private _distanceToOriginalBase = _player distance _base;
|
||||
// get the closest base to the player
|
||||
private _nearestBase = [_player] call milsim_fnc_getNearestBase;
|
||||
private _nearestBase = [_player] call milsim_util_fnc_getNearestBase;
|
||||
private _isCloseEnoughToAnyBase = (_player distance _nearestBase) < _maxRangeToReady;
|
||||
|
||||
if (not _isCloseEnoughToAnyBase || not (alive _player)) then {
|
||||
// don't include player in updated queue
|
||||
// log to rpt
|
||||
private _logParams = [
|
||||
["filedAtBase", [_base] call milsim_fnc_getNameOfBase],
|
||||
["filedAtBase", [_base] call milsim_util_fnc_getNameOfBase],
|
||||
["filedAtBaseDistance", _player distance _base],
|
||||
["closestBase", [_nearestBase] call milsim_fnc_getNameOfBase],
|
||||
["closestBase", [_nearestBase] call milsim_util_fnc_getNameOfBase],
|
||||
["closestBaseDistance", _player distance _nearestBase],
|
||||
["maxDistanceSetting", _maxRangeToReady],
|
||||
["inQueueDuration", diag_tickTime - _timeFiled]
|
||||
];
|
||||
_logParams = [_player, _logParams] call milsim_fnc_addPlayerInfoToArray;
|
||||
_logParams = [_player, _logParams] call milsim_util_fnc_addPlayerInfoToArray;
|
||||
[
|
||||
"respawn_reinsertion",
|
||||
"PLAYER DEQUEUED AUTOMATICALLY",
|
||||
_logParams
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
// continue loop
|
||||
continue
|
||||
};
|
||||
@@ -36,19 +36,19 @@ private _maxRangeToReady = missionNamespace getVariable ["milsim_reinsert_settin
|
||||
// if player's base has changed, log to rpt
|
||||
if (_base != _nearestBase) then {
|
||||
private _logParams = [
|
||||
["filedAtBase", [_base] call milsim_fnc_getNameOfBase],
|
||||
["filedAtBase", [_base] call milsim_util_fnc_getNameOfBase],
|
||||
["filedAtBaseDistance", _player distance _base],
|
||||
["closestBase", [_nearestBase] call milsim_fnc_getNameOfBase],
|
||||
["closestBase", [_nearestBase] call milsim_util_fnc_getNameOfBase],
|
||||
["closestBaseDistance", _player distance _nearestBase],
|
||||
["maxDistanceSetting", _maxRangeToReady],
|
||||
["inQueueDuration", diag_tickTime - _timeFiled]
|
||||
];
|
||||
_logParams = [_player, _logParams] call milsim_fnc_addPlayerInfoToArray;
|
||||
_logParams = [_player, _logParams] call milsim_util_fnc_addPlayerInfoToArray;
|
||||
[
|
||||
"respawn_reinsertion",
|
||||
"PLAYER BASE WAS UPDATED",
|
||||
_logParams
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
};
|
||||
} forEach milsim_reinsert_reinsertionQueue;
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
// adds a scroll wheel action to all arsenal boxes to spawn different supply crate types
|
||||
|
||||
private _arsenalBoxClassName = "Land_PaperBox_open_full_F";
|
||||
@@ -8,7 +10,7 @@ private _arsenalBoxes = (allMissionObjects _arsenalBoxClassName) select {
|
||||
count (actionIDs _x) > 0;
|
||||
};
|
||||
|
||||
private _supplyCratesCfg = call milsim_resupply_fnc_getSupplyCratesCfg;
|
||||
private _supplyCratesCfg = call FUNC(getSupplyCratesCfg);
|
||||
private _supplyCrateTypesCfgs = _supplyCratesCfg call BIS_fnc_returnChildren;
|
||||
|
||||
{
|
||||
@@ -25,7 +27,7 @@ private _supplyCrateTypesCfgs = _supplyCratesCfg call BIS_fnc_returnChildren;
|
||||
objNull,
|
||||
configName _supplyCrateCfg,
|
||||
getPos _target
|
||||
] call milsim_resupply_fnc_createBox;
|
||||
] call FUNC(createBox);
|
||||
}, [_cfg], 0, false, true, "", ""];
|
||||
} forEach _supplyCrateTypesCfgs;
|
||||
} forEach _arsenalBoxes;
|
||||
25
framework/resupply/functions/fn_addCBASettings.sqf
Normal file
25
framework/resupply/functions/fn_addCBASettings.sqf
Normal file
@@ -0,0 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
[
|
||||
QGVAR(setting_allowSupplyBoxScrollWheelSpawning), // variable
|
||||
"CHECKBOX", // type
|
||||
["Allow Spawning Boxes from Arsenal Box", "If true, adds scroll wheel options to arsenal boxes to spawn supply boxes"], // title
|
||||
[QUOTE(SETTINGS_GROUP_NAME), QUOTE(COMPONENT_BEAUTIFIED)], // category
|
||||
false, // default value
|
||||
true, // global setting
|
||||
{
|
||||
params ["_value"];
|
||||
[
|
||||
QUOTE(COMPONENT),
|
||||
"SETTING CHANGED",
|
||||
[
|
||||
[
|
||||
"setting",
|
||||
QGVAR(setting_allowSupplyBoxScrollWheelSpawning)
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call EFUNC(util,log);
|
||||
},
|
||||
true // requires mission restart
|
||||
] call CBA_fnc_addSetting;
|
||||
@@ -27,7 +27,8 @@
|
||||
["weapon", (weaponCargo cursorObject) call BIS_fnc_consolidateArray]
|
||||
]];
|
||||
*/
|
||||
|
||||
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
params [
|
||||
["_box", objNull, [objNull]],
|
||||
@@ -36,7 +37,7 @@ params [
|
||||
];
|
||||
|
||||
// get defs class
|
||||
private _supplyCratesCfg = call milsim_resupply_fnc_getSupplyCratesCfg;
|
||||
private _supplyCratesCfg = call FUNC(getSupplyCratesCfg);
|
||||
if (!isClass _supplyCratesCfg) exitWith {
|
||||
["Resupply Boxes: Failed to load crate definitions, possibly a bad edit?"] call BIS_fnc_error;
|
||||
objNull;
|
||||
2
framework/resupply/functions/fn_getSupplyCratesCfg.sqf
Normal file
2
framework/resupply/functions/fn_getSupplyCratesCfg.sqf
Normal file
@@ -0,0 +1,2 @@
|
||||
#include "..\script_component.hpp"
|
||||
(missionConfigFile >> "SupplyCrates");
|
||||
12
framework/resupply/functions/fn_init.sqf
Normal file
12
framework/resupply/functions/fn_init.sqf
Normal file
@@ -0,0 +1,12 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
// 5 seconds after the client is loaded, add the resupply action to all arsenal boxes
|
||||
[
|
||||
{time > 5},
|
||||
{
|
||||
if (missionNamespace getVariable [
|
||||
QGVAR(setting_allowSupplyBoxScrollWheelSpawning),
|
||||
false
|
||||
]) then {call FUNC(addSpawnBoxActions)}
|
||||
}
|
||||
] call CBA_fnc_waitUntilAndExecute;
|
||||
3
framework/resupply/script_component.hpp
Normal file
3
framework/resupply/script_component.hpp
Normal file
@@ -0,0 +1,3 @@
|
||||
#define COMPONENT resupply
|
||||
#define COMPONENT_BEAUTIFIED Resupply
|
||||
#include "../script_mod.hpp"
|
||||
5
framework/script_macros.hpp
Normal file
5
framework/script_macros.hpp
Normal file
@@ -0,0 +1,5 @@
|
||||
// all text before cba include
|
||||
#define SETTINGS_GROUP_NAME 17th Battalion
|
||||
|
||||
|
||||
#include "\x\cba\addons\main\script_macros_mission.hpp"
|
||||
10
framework/script_mod.hpp
Normal file
10
framework/script_mod.hpp
Normal file
@@ -0,0 +1,10 @@
|
||||
#define PREFIX milsim
|
||||
|
||||
#include "script_version.hpp"
|
||||
|
||||
#define VERSION MAJOR.MINOR.PATCHLVL
|
||||
#define VERSION_STR MAJOR.MINOR.PATCHLVL
|
||||
#define VERSION_AR MAJOR,MINOR,PATCHLVL
|
||||
|
||||
// should always be last
|
||||
#include "script_macros.hpp"
|
||||
4
framework/script_version.hpp
Normal file
4
framework/script_version.hpp
Normal file
@@ -0,0 +1,4 @@
|
||||
#define MAJOR 3
|
||||
#define MINOR 2
|
||||
#define PATCHLVL 1
|
||||
#define BUILD 0
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
Function: milsim_fnc_logPlayerInventory
|
||||
Function: milsim_util_fnc_logPlayerInventory
|
||||
|
||||
Description:
|
||||
Checks a player's inventory for non-compliant items and logs results to all machines.
|
||||
@@ -22,7 +22,7 @@ if (!isPlayer _player) exitWith {
|
||||
"logPlayerInventory",
|
||||
"PARAM PLAYER IS NOT A PLAYER",
|
||||
[["player", _player]]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
};
|
||||
|
||||
// testing
|
||||
@@ -55,8 +55,8 @@ _playerItems pushBack (uniform _player);
|
||||
[
|
||||
"logPlayerInventory",
|
||||
"CHECKING PLAYER INVENTORY",
|
||||
[_player] call milsim_fnc_addPlayerInfoToArray
|
||||
] call milsim_fnc_log;
|
||||
[_player] call milsim_util_fnc_addPlayerInfoToArray
|
||||
] call milsim_util_fnc_log;
|
||||
|
||||
////////////////////////////////////////
|
||||
// HARDCODED DISALLOWED ITEMS - see functions/definitions/DisallowedEquipment.hpp
|
||||
@@ -117,8 +117,8 @@ if (count _allFoundItemsSoFar isEqualTo 0) exitWith {
|
||||
[
|
||||
"logPlayerInventory",
|
||||
"PLAYER INVENTORY IS COMPLIANT",
|
||||
[_player] call milsim_fnc_addPlayerInfoToArray
|
||||
] call milsim_fnc_log;
|
||||
[_player] call milsim_util_fnc_addPlayerInfoToArray
|
||||
] call milsim_util_fnc_log;
|
||||
};
|
||||
|
||||
// Log all non-compliant items
|
||||
@@ -138,7 +138,7 @@ if (count _allFoundItemsSoFar isEqualTo 0) exitWith {
|
||||
["category", _categoryLabel],
|
||||
["className", _itemClassName],
|
||||
["displayName", [_itemConfig] call BIS_fnc_displayName]
|
||||
]] call milsim_fnc_addPlayerInfoToArray
|
||||
] call milsim_fnc_log;
|
||||
]] call milsim_util_fnc_addPlayerInfoToArray
|
||||
] call milsim_util_fnc_log;
|
||||
} forEach _items;
|
||||
} forEach _foundItemsKeyValue;
|
||||
@@ -146,7 +146,7 @@
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
}
|
||||
] call CBA_fnc_addSetting;
|
||||
|
||||
@@ -169,7 +169,7 @@
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
}
|
||||
] call CBA_fnc_addSetting;
|
||||
|
||||
@@ -192,7 +192,7 @@
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
}
|
||||
] call CBA_fnc_addSetting;
|
||||
|
||||
@@ -215,7 +215,7 @@
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
}
|
||||
] call CBA_fnc_addSetting;
|
||||
|
||||
@@ -238,7 +238,7 @@
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
}
|
||||
] call CBA_fnc_addSetting;
|
||||
|
||||
@@ -264,7 +264,7 @@
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
}
|
||||
] call CBA_fnc_addSetting;
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
[
|
||||
"init",
|
||||
"CHAT COMMAND RESPAWN",
|
||||
[player] call milsim_fnc_addPlayerInfoToArray
|
||||
] remoteExec ["milsim_fnc_log", 2];
|
||||
[player] call milsim_util_fnc_addPlayerInfoToArray
|
||||
] remoteExec ["milsim_util_fnc_log", 2];
|
||||
|
||||
// systemChat to all remote machines
|
||||
format["%1 claims they were glitched and respawned (%2)", name player, netID player] remoteExec["systemChat", -_clientID];
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
Function: milsim_fnc_log
|
||||
Function: milsim_util_fnc_log
|
||||
|
||||
Description:
|
||||
Used to log messages to the server RPT file.
|
||||
@@ -20,4 +20,4 @@
|
||||
["LOGIC", playableSlotsNumber sideLogic] // 5 is LOGIC side
|
||||
]]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
] call milsim_util_fnc_log;
|
||||
@@ -1,6 +1,8 @@
|
||||
if (!hasInterface) exitWith {};
|
||||
|
||||
private _vehicleFlagsCfg = call milsim_vehicleFlags_fnc_getVehicleFlagsCfg;
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
private _vehicleFlagsCfg = call FUNC(getVehicleFlagsCfg);
|
||||
|
||||
if (!isClass _vehicleFlagsCfg) exitWith {
|
||||
["WARNING: Vehicle Flags: Vehicle Flags config not found. Vehicle Flags will not be available."] call BIS_fnc_error;
|
||||
@@ -34,7 +36,7 @@ private _flagCategoryCfgs = (_vehicleFlagsCfg >> "FlagCategories") call BIS_fnc_
|
||||
// _params params ["_parentActionID", "_flagCategories"];
|
||||
|
||||
// check if vehicle is excluded
|
||||
private _excluded = [typeOf _target] call milsim_vehicleFlags_fnc_isClassExcluded;
|
||||
private _excluded = [typeOf _target] call FUNC(isClassExcluded);
|
||||
if (_excluded || !alive _target) exitWith {false};
|
||||
|
||||
true;
|
||||
@@ -47,7 +49,7 @@ private _flagCategoryCfgs = (_vehicleFlagsCfg >> "FlagCategories") call BIS_fnc_
|
||||
_params params ["_rootActionID", "_flagCategoryCfgs"];
|
||||
|
||||
// return category child actions with individual flag actions nested as children
|
||||
[_rootActionID, _flagCategoryCfgs] call milsim_vehicleFlags_fnc_getActionsFlagCategories;
|
||||
[_rootActionID, _flagCategoryCfgs] call FUNC(getActionsFlagCategories);
|
||||
|
||||
}, // child code
|
||||
[_rootActionID, _flagCategoryCfgs], // params
|
||||
3
framework/vehicleFlags/script_component.hpp
Normal file
3
framework/vehicleFlags/script_component.hpp
Normal file
@@ -0,0 +1,3 @@
|
||||
#define COMPONENT vehicleFlags
|
||||
#define COMPONENT_BEAUTIFIED Vehicle Flags
|
||||
#include "../script_mod.hpp"
|
||||
@@ -1,25 +0,0 @@
|
||||
if ( !hasInterface ) exitWith {};
|
||||
|
||||
if (!isServer) then {
|
||||
["milsim_logText", {
|
||||
params [["_strArray", [""], [[]]]];
|
||||
{
|
||||
diag_log text _x;
|
||||
} forEach _strArray;
|
||||
}] call CBA_fnc_addEventHandler;
|
||||
};
|
||||
|
||||
// 5 seconds after the client is loaded, add the resupply action to all arsenal boxes
|
||||
[
|
||||
{time > 5},
|
||||
{
|
||||
if (missionNamespace getVariable [
|
||||
"milsim_resupply_setting_allowSupplyBoxScrollWheelSpawning",
|
||||
false
|
||||
]) then {call milsim_resupply_fnc_addSpawnBoxActions}
|
||||
}
|
||||
] call CBA_fnc_waitUntilAndExecute;
|
||||
|
||||
["InitializePlayer", [player, true]] call BIS_fnc_dynamicGroups;
|
||||
|
||||
nil;
|
||||
@@ -1,22 +0,0 @@
|
||||
[
|
||||
"milsim_resupply_setting_allowSupplyBoxScrollWheelSpawning", // variable
|
||||
"CHECKBOX", // type
|
||||
["Enabled", "If true, adds scroll wheel options to arsenal boxes to spawn supply boxes"], // title
|
||||
["17th Battalion", "Resupply"], // category
|
||||
false, // default value
|
||||
true, // global setting
|
||||
{
|
||||
params ["_value"];
|
||||
[
|
||||
"resupply",
|
||||
"SETTING CHANGED",
|
||||
[
|
||||
[
|
||||
"setting",
|
||||
"milsim_resupply_setting_allowSupplyBoxScrollWheelSpawning"
|
||||
],
|
||||
["newValue", _value]
|
||||
]
|
||||
] call milsim_fnc_log;
|
||||
}
|
||||
] call CBA_fnc_addSetting;
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* Author: Hizumi
|
||||
*
|
||||
* Create Ammo resupply box for the 17th Battalion
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicle - <OBJECT>
|
||||
* 1: Position - <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* Function executed <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [box] call milsim_fnc_createAmmoBox; // create ammo box via init line of editor object
|
||||
* [objNull, pos] call milsim_fnc_createAmmoBox; // create ammo box via zeus module
|
||||
*
|
||||
* Public: Yes
|
||||
*
|
||||
* Note: For gathering:
|
||||
formatText ["%1", [
|
||||
["containerClassname", typeOf cursorObject],
|
||||
["backpack", (backpackCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["item", (itemCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazine", (magazineCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazineAmmo", magazinesAmmoCargo cursorObject],
|
||||
["weapon", (weaponCargo cursorObject) call BIS_fnc_consolidateArray]
|
||||
]];
|
||||
*/
|
||||
|
||||
|
||||
params [
|
||||
["_box", objNull, [objNull]],
|
||||
["_pos", [0,0,0], [[]], 3]
|
||||
];
|
||||
|
||||
[_box, "AMMO LIGHT", _pos] call milsim_fnc_createBox;
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* Author: Hizumi & IndigoFox
|
||||
*
|
||||
* Create Ammo resupply box for the 17th Battalion
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicle - <OBJECT>
|
||||
* 1: Position - <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* Function executed <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [box] call milsim_fnc_createCSWBox; // create ammo box via init line of editor object
|
||||
* [objNull, pos] call milsim_fnc_createCSWBox; // create ammo box via zeus module
|
||||
*
|
||||
* Public: Yes
|
||||
*
|
||||
* Note: For gathering:
|
||||
formatText ["%1", [
|
||||
["containerClassname", typeOf cursorObject],
|
||||
["backpack", (backpackCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["item", (itemCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazine", (magazineCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazineAmmo", magazinesAmmoCargo cursorObject],
|
||||
["weapon", (weaponCargo cursorObject) call BIS_fnc_consolidateArray]
|
||||
]];
|
||||
*/
|
||||
|
||||
|
||||
params [
|
||||
["_box", objNull, [objNull]],
|
||||
["_pos", [0,0,0], [[]], 3]
|
||||
];
|
||||
|
||||
[_box, "CSW", _pos] call milsim_fnc_createBox;
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* Author: Hizumi & IndigoFox
|
||||
*
|
||||
* Create Ammo resupply box for the 17th Battalion
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicle - <OBJECT>
|
||||
* 1: Position - <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* Function executed <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [box] call milsim_fnc_createLaunchersBox; // create ammo box via init line of editor object
|
||||
* [objNull, pos] call milsim_fnc_createLaunchersBox; // create ammo box via zeus module
|
||||
*
|
||||
* Public: Yes
|
||||
*
|
||||
* Note: For gathering:
|
||||
formatText ["%1", [
|
||||
["containerClassname", typeOf cursorObject],
|
||||
["backpack", (backpackCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["item", (itemCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazine", (magazineCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazineAmmo", magazinesAmmoCargo cursorObject],
|
||||
["weapon", (weaponCargo cursorObject) call BIS_fnc_consolidateArray]
|
||||
]];
|
||||
*/
|
||||
|
||||
|
||||
params [
|
||||
["_box", objNull, [objNull]],
|
||||
["_pos", [0,0,0], [[]], 3]
|
||||
];
|
||||
|
||||
[_box, "LAUNCHERS", _pos] call milsim_fnc_createBox;
|
||||
@@ -1,26 +0,0 @@
|
||||
/*
|
||||
* Author: Hizumi
|
||||
*
|
||||
* Create Ammo resupply box for the 17th Battalion
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicle - <OBJECT>
|
||||
* 1: Position - <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* Function executed <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [box] call milsim_fnc_createMedicalBox; // create ammo box via init line of editor object
|
||||
* [objNull, pos] call milsim_fnc_createMedicalBox // create ammo box via zeus module
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
|
||||
params [
|
||||
["_box", objNull, [objNull]],
|
||||
["_pos", [0,0,0], [[]], 3]
|
||||
];
|
||||
|
||||
[_box, "MEDICAL", _pos] call milsim_fnc_createBox;
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* Author: Hizumi & IndigoFox
|
||||
*
|
||||
* Create Mortar resupply box for the 17th Battalion
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicle - <OBJECT>
|
||||
* 1: Position - <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* Function executed <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [box] call milsim_fnc_createMortarBox; // create mortar ammo box via init line of editor object
|
||||
* [objNull, pos] call milsim_fnc_createMortarBox; // create mortar ammo box via zeus module
|
||||
*
|
||||
* Public: Yes
|
||||
*
|
||||
* Note: For gathering:
|
||||
formatText ["%1", [
|
||||
["containerClassname", typeOf cursorObject],
|
||||
["backpack", (backpackCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["item", (itemCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazine", (magazineCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazineAmmo", magazinesAmmoCargo cursorObject],
|
||||
["weapon", (weaponCargo cursorObject) call BIS_fnc_consolidateArray]
|
||||
]];
|
||||
*/
|
||||
|
||||
|
||||
params [
|
||||
["_box", objNull, [objNull]],
|
||||
["_pos", [0,0,0], [[]], 3]
|
||||
];
|
||||
|
||||
[_box, "AMMO MORTAR", _pos] call milsim_fnc_createBox;
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* Author: Hizumi
|
||||
*
|
||||
* Create Ammo resupply box for the 17th Battalion
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicle - <OBJECT>
|
||||
* 1: Position - <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* Function executed <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [box] call milsim_fnc_createWeaponsBox; // create ammo box via init line of editor object
|
||||
* [objNull, pos] call milsim_fnc_createWeaponsBox; // create ammo box via zeus module
|
||||
*
|
||||
* Public: Yes
|
||||
*
|
||||
* Note: For gathering:
|
||||
formatText ["%1", [
|
||||
["containerClassname", typeOf cursorObject],
|
||||
["backpack", (backpackCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["item", (itemCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazine", (magazineCargo cursorObject) call BIS_fnc_consolidateArray],
|
||||
["magazineAmmo", magazinesAmmoCargo cursorObject],
|
||||
["weapon", (weaponCargo cursorObject) call BIS_fnc_consolidateArray]
|
||||
]];
|
||||
*/
|
||||
|
||||
|
||||
params [
|
||||
["_box", objNull, [objNull]],
|
||||
["_pos", [0,0,0], [[]], 3]
|
||||
];
|
||||
|
||||
[_box, "AMMO HEAVY", _pos] call milsim_fnc_createBox;
|
||||
@@ -1 +0,0 @@
|
||||
(missionConfigFile >> "SupplyCrates");
|
||||
Reference in New Issue
Block a user