From 279541676e2ce05498af6e7afd1ca0b2521076c7 Mon Sep 17 00:00:00 2001 From: GitHawk Date: Fri, 26 Feb 2016 11:30:22 +0100 Subject: [PATCH 01/36] Expanded module and string table --- addons/rearm/ACE_Settings.hpp | 7 +++++++ .../functions/fnc_moduleRearmSettings.sqf | 2 ++ addons/rearm/stringtable.xml | 18 +++++++++++++++++- 3 files changed, 26 insertions(+), 1 deletion(-) diff --git a/addons/rearm/ACE_Settings.hpp b/addons/rearm/ACE_Settings.hpp index f4d6562807..0d15701c06 100644 --- a/addons/rearm/ACE_Settings.hpp +++ b/addons/rearm/ACE_Settings.hpp @@ -6,4 +6,11 @@ class ACE_Settings { typeName = "SCALAR"; values[] = {CSTRING(RearmSettings_vehicle), CSTRING(RearmSettings_magazine), CSTRING(RearmSettings_caliber)}; }; + class GVAR(supply) { + displayName = CSTRING(RearmSettings_supply_DisplayName); + description = CSTRING(RearmSettings_supply_Description); + value = 0; + typeName = "SCALAR"; + values[] = {CSTRING(RearmSettings_unlimited), CSTRING(RearmSettings_caliber), CSTRING(RearmSettings_magazineSupply)}; + }; }; diff --git a/addons/rearm/functions/fnc_moduleRearmSettings.sqf b/addons/rearm/functions/fnc_moduleRearmSettings.sqf index af627862da..ae4a56563c 100644 --- a/addons/rearm/functions/fnc_moduleRearmSettings.sqf +++ b/addons/rearm/functions/fnc_moduleRearmSettings.sqf @@ -22,5 +22,7 @@ params ["_logic", "", ["_activated", false, [false]]]; if (!_activated) exitWith {}; [_logic, QGVAR(level), "level"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(supply), "supply"] call EFUNC(common,readSettingFromModule); diag_log text format ["[ACE]: Rearm Module Initialized on level: %1", GVAR(level)]; +diag_log text format ["[ACE]: Rearm Module Initialized on supply: %1", GVAR(supply)]; diff --git a/addons/rearm/stringtable.xml b/addons/rearm/stringtable.xml index a4b037c5a5..0b4fe1c90f 100644 --- a/addons/rearm/stringtable.xml +++ b/addons/rearm/stringtable.xml @@ -71,6 +71,22 @@ Ammontare basato sul calibro Cantidad basada en el calibre + + Ammunition supply + Munitionsvorat + + + How much ammunition does an ammo truck carry? + Wie viel Munition transportiert ein Munitionslaster? + + + Unlimited ammo supply + Unbegrenzter Munitionsvorat + + + Only specific Magazines + Nur bestimmte Magazine + Rearm Aufmunitionieren @@ -313,4 +329,4 @@ FAB-250M-54 - \ No newline at end of file + From 91c6341bc85b7ee41455ac3f2a3d25be39bd8dad Mon Sep 17 00:00:00 2001 From: Githawk Date: Sat, 27 Feb 2016 20:31:07 +0100 Subject: [PATCH 02/36] Implementation --- addons/rearm/ACE_Settings.hpp | 2 +- addons/rearm/CfgVehicles.hpp | 50 +++++++++++ addons/rearm/XEH_PREP.hpp | 12 +++ .../functions/fnc_addMagazineToSupply.sqf | 64 ++++++++++++++ .../rearm/functions/fnc_addRearmActions.sqf | 39 +++++---- .../fnc_addVehicleMagazinesToSupply.sqf | 42 +++++++++ .../functions/fnc_canReadSupplyCounter.sqf | 26 ++++++ .../rearm/functions/fnc_canRearmVehicle.sqf | 26 ++++++ addons/rearm/functions/fnc_canTakeAmmo.sqf | 3 +- addons/rearm/functions/fnc_createDummy.sqf | 7 +- addons/rearm/functions/fnc_dropAmmo.sqf | 6 +- addons/rearm/functions/fnc_getCaliber.sqf | 48 +++++++++++ .../functions/fnc_getConfigMagazines.sqf | 14 +-- .../rearm/functions/fnc_getMaxMagazines.sqf | 3 +- .../functions/fnc_getNeedRearmMagazines.sqf | 7 +- addons/rearm/functions/fnc_getSupplyCount.sqf | 27 ++++++ .../functions/fnc_getVehicleMagazines.sqf | 23 +++++ .../rearm/functions/fnc_hasEnoughSupply.sqf | 39 +++++++++ .../rearm/functions/fnc_magazineInSupply.sqf | 39 +++++++++ addons/rearm/functions/fnc_pickUpAmmo.sqf | 5 +- .../rearm/functions/fnc_readSupplyCounter.sqf | 75 ++++++++++++++++ addons/rearm/functions/fnc_rearm.sqf | 35 ++------ .../functions/fnc_rearmEntireVehicle.sqf | 5 +- .../fnc_rearmEntireVehicleSuccess.sqf | 14 +-- .../fnc_rearmEntireVehicleSuccessLocal.sqf | 47 ++++++---- addons/rearm/functions/fnc_rearmSuccess.sqf | 3 +- .../rearm/functions/fnc_rearmSuccessLocal.sqf | 12 ++- .../fnc_removeMagazineFromSupply.sqf | 86 +++++++++++++++++++ addons/rearm/functions/fnc_setSupplyCount.sqf | 23 +++++ addons/rearm/functions/fnc_storeAmmo.sqf | 12 ++- addons/rearm/functions/fnc_takeAmmo.sqf | 26 +----- addons/rearm/functions/fnc_takeSuccess.sqf | 15 ++-- addons/rearm/stringtable.xml | 24 ++++++ 33 files changed, 719 insertions(+), 140 deletions(-) create mode 100644 addons/rearm/functions/fnc_addMagazineToSupply.sqf create mode 100644 addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf create mode 100644 addons/rearm/functions/fnc_canReadSupplyCounter.sqf create mode 100644 addons/rearm/functions/fnc_canRearmVehicle.sqf create mode 100644 addons/rearm/functions/fnc_getCaliber.sqf create mode 100644 addons/rearm/functions/fnc_getSupplyCount.sqf create mode 100644 addons/rearm/functions/fnc_getVehicleMagazines.sqf create mode 100644 addons/rearm/functions/fnc_hasEnoughSupply.sqf create mode 100644 addons/rearm/functions/fnc_magazineInSupply.sqf create mode 100644 addons/rearm/functions/fnc_readSupplyCounter.sqf create mode 100644 addons/rearm/functions/fnc_removeMagazineFromSupply.sqf create mode 100644 addons/rearm/functions/fnc_setSupplyCount.sqf diff --git a/addons/rearm/ACE_Settings.hpp b/addons/rearm/ACE_Settings.hpp index 0d15701c06..fb69018436 100644 --- a/addons/rearm/ACE_Settings.hpp +++ b/addons/rearm/ACE_Settings.hpp @@ -11,6 +11,6 @@ class ACE_Settings { description = CSTRING(RearmSettings_supply_Description); value = 0; typeName = "SCALAR"; - values[] = {CSTRING(RearmSettings_unlimited), CSTRING(RearmSettings_caliber), CSTRING(RearmSettings_magazineSupply)}; + values[] = {CSTRING(RearmSettings_unlimited), CSTRING(RearmSettings_limited), CSTRING(RearmSettings_magazineSupply)}; }; }; diff --git a/addons/rearm/CfgVehicles.hpp b/addons/rearm/CfgVehicles.hpp index 30548aed76..acd8ab62a1 100644 --- a/addons/rearm/CfgVehicles.hpp +++ b/addons/rearm/CfgVehicles.hpp @@ -15,6 +15,26 @@ #define MACRO_REARM_TRUCK_ACTIONS \ class ACE_Actions : ACE_Actions { \ class ACE_MainActions : ACE_MainActions { \ + class GVAR(ReadSupplyCounter) { \ + displayName = CSTRING(ReadSupplyCounter); \ + distance = REARM_ACTION_DISTANCE; \ + condition = QUOTE(_this call FUNC(canReadSupplyCounter)); \ + statement = QUOTE(_this call FUNC(readSupplyCounter)); \ + exceptions[] = {"isNotInside"}; \ + showDisabled = 0; \ + priority = 2; \ + icon = PATHTOF(ui\icon_rearm_interact.paa); \ + }; \ + class GVAR(Rearm) { \ + displayName = CSTRING(Rearm); \ + distance = REARM_ACTION_DISTANCE; \ + condition = QUOTE(_this call FUNC(canRearmVehicle)); \ + insertChildren = QUOTE(_target call FUNC(addRearmActions)); \ + exceptions[] = {"isNotInside"}; \ + showDisabled = 0; \ + priority = 2; \ + icon = PATHTOF(ui\icon_rearm_interact.paa); \ + }; \ class GVAR(TakeAmmo) { \ displayName = CSTRING(TakeAmmo); \ distance = REARM_ACTION_DISTANCE; \ @@ -36,6 +56,9 @@ }; \ }; +#define MACRO_REARM_DEFAULT_SUPPLY \ + GVAR(defaultSupply) = 1200; + class CfgVehicles { class ACE_Module; class ACE_moduleRearmSettings : ACE_Module { @@ -69,6 +92,26 @@ class CfgVehicles { }; }; }; + class supply { + displayName = CSTRING(RearmSettings_supply_DisplayName); + description = CSTRING(RearmSettings_supply_Description); + typeName = "NUMBER"; + class values { + class unlimited { + name = CSTRING(RearmSettings_unlimited); + value = 0; + default = 1; + }; + class magazine { + name = CSTRING(RearmSettings_limited); + value = 1; + }; + class caliber { + name = CSTRING(RearmSettings_magazineSupply); + value = 2; + }; + }; + }; }; class ModuleDescription { description = CSTRING(RearmSettings_Module_Description); @@ -110,6 +153,7 @@ class CfgVehicles { class Truck_03_base_F : Truck_F {}; class O_Truck_03_ammo_F : Truck_03_base_F { transportAmmo = 0; + MACRO_REARM_DEFAULT_SUPPLY MACRO_REARM_TRUCK_ACTIONS }; @@ -117,10 +161,12 @@ class CfgVehicles { class Truck_02_Ammo_base_F : Truck_02_base_F {}; class I_Truck_02_ammo_F : Truck_02_Ammo_base_F { transportAmmo = 0; + MACRO_REARM_DEFAULT_SUPPLY MACRO_REARM_TRUCK_ACTIONS }; class O_Truck_02_Ammo_F : Truck_02_Ammo_base_F { transportAmmo = 0; + MACRO_REARM_DEFAULT_SUPPLY MACRO_REARM_TRUCK_ACTIONS }; @@ -129,6 +175,7 @@ class CfgVehicles { class B_Truck_01_mover_F : B_Truck_01_transport_F {}; class B_Truck_01_ammo_F : B_Truck_01_mover_F { transportAmmo = 0; + MACRO_REARM_DEFAULT_SUPPLY MACRO_REARM_TRUCK_ACTIONS }; @@ -137,12 +184,14 @@ class CfgVehicles { class Heli_Transport_04_base_F : Helicopter_Base_H {}; class O_Heli_Transport_04_ammo_F : Heli_Transport_04_base_F { transportAmmo = 0; + MACRO_REARM_DEFAULT_SUPPLY MACRO_REARM_TRUCK_ACTIONS }; class Pod_Heli_Transport_04_base_F: StaticWeapon {}; class Land_Pod_Heli_Transport_04_ammo_F: Pod_Heli_Transport_04_base_F { transportAmmo = 0; + MACRO_REARM_DEFAULT_SUPPLY MACRO_REARM_TRUCK_ACTIONS }; @@ -161,6 +210,7 @@ class CfgVehicles { class B_Slingload_01_Ammo_F : Slingload_01_Base_F { XEH_ENABLED; transportAmmo = 0; + MACRO_REARM_DEFAULT_SUPPLY MACRO_REARM_TRUCK_ACTIONS }; diff --git a/addons/rearm/XEH_PREP.hpp b/addons/rearm/XEH_PREP.hpp index 8e3c10cd2c..03e08fd4b0 100644 --- a/addons/rearm/XEH_PREP.hpp +++ b/addons/rearm/XEH_PREP.hpp @@ -1,26 +1,38 @@ +PREP(addMagazineToSupply); PREP(addRearmActions); +PREP(addVehicleMagazinesToSupply); +PREP(canReadSupplyCounter); PREP(canRearm); +PREP(canRearmVehicle); PREP(canStoreAmmo); PREP(canTakeAmmo); PREP(createDummy); PREP(disable); PREP(dropAmmo); +PREP(getCaliber); PREP(getConfigMagazines); PREP(getMaxMagazines); PREP(getNeedRearmMagazines); +PREP(getSupplyCount); +PREP(getVehicleMagazines); PREP(grabAmmo); PREP(handleKilled); PREP(handleUnconscious); +PREP(hasEnoughSupply); +PREP(magazineInSupply); PREP(makeDummy); PREP(moduleRearmSettings); PREP(pickUpAmmo); +PREP(readSupplyCounter); PREP(rearm); PREP(rearmEntireVehicle); PREP(rearmEntireVehicleSuccess); PREP(rearmEntireVehicleSuccessLocal); PREP(rearmSuccess); PREP(rearmSuccessLocal); +PREP(removeMagazineFromSupply); +PREP(setSupplyCount); PREP(storeAmmo); PREP(takeAmmo); PREP(takeSuccess); diff --git a/addons/rearm/functions/fnc_addMagazineToSupply.sqf b/addons/rearm/functions/fnc_addMagazineToSupply.sqf new file mode 100644 index 0000000000..781af9e2f4 --- /dev/null +++ b/addons/rearm/functions/fnc_addMagazineToSupply.sqf @@ -0,0 +1,64 @@ +/* + * Author: GitHawk + * Adds magazines to the supply. + * + * Argument: + * 0: Target + * 1: Magazine Classname + * 2: Only partial + * + * Return value: + * None + * + * Example: + * [ammo_truck, "32Rnd_155mm_Mo_shells"] call ace_rearm_fnc_addMagazineToSupply + * + * Public: Yes + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]], ["_partial", false, [false]]]; + +if (isNull _target || + {_magazineClass isEqualTo ""} || + {GVAR(supply) == 0}) exitWith {}; + +// With limited supply, we add the caliber to the supply count +if (GVAR(supply) == 1) then { + private _supply = [_target] call FUNC(getSupplyCount); + ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; + if (!_partial || {GVAR(level) == 1}) then { + [_target, _supply + _cal] call FUNC(setSupplyCount); + } else { + private _magazinePart = ((REARM_COUNT select _idx) / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; + [_target, (_supply + (_cal * _magazinePart))] call FUNC(setSupplyCount); + }; +}; + +// With magazine specific supply, we add or update the magazineSupply array +if (GVAR(supply) == 2) then { + private _magazineSupply = _target getVariable [QGVAR(magazineSupply), []]; + private _magazineIdx = -1; + { + _x params ["_magazine", "_rounds"]; + if ((_magazine isEqualTo _magazineClass)) exitWith { + _magazineIdx = _forEachIndex; + }; + } forEach _magazineSupply; + + private _roundsPerTransaction = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); + if (_partial) then { + _roundsPerTransaction = _roundsPerTransaction min (REARM_COUNT select _idx); + }; + if (_magazineIdx == -1) then { + if (count _magazineSupply == 0) then { + _magazineSupply = [[_magazineClass, _roundsPerTransaction]]; + } else { + _magazineSupply append [[_magazineClass, _roundsPerTransaction]]; + } + } else { + (_magazineSupply select _magazineIdx) params ["", "_rounds"]; + _magazineSupply set [_magazineIdx, [_magazineClass, (_rounds + _roundsPerTransaction)]]; + }; + _target setVariable [QGVAR(magazineSupply), _magazineSupply, true]; +}; diff --git a/addons/rearm/functions/fnc_addRearmActions.sqf b/addons/rearm/functions/fnc_addRearmActions.sqf index 6040fd6fc5..b2b388a3fd 100644 --- a/addons/rearm/functions/fnc_addRearmActions.sqf +++ b/addons/rearm/functions/fnc_addRearmActions.sqf @@ -15,25 +15,24 @@ */ #include "script_component.hpp" -private ["_vehicleActions", "_actions", "_action", "_vehicles", "_vehicle", "_needToAdd", "_magazineHelper", "_turretPath", "_magazines", "_magazine", "_icon", "_cnt"]; params [["_target", objNull, [objNull]]]; -_vehicles = nearestObjects [_target, ["AllVehicles"], 20]; +private _vehicles = nearestObjects [_target, ["AllVehicles"], 20]; if (count _vehicles < 2) exitWith {false}; // Rearming needs at least 2 vehicles -_vehicleActions = []; +private _vehicleActions = []; { - _actions = []; - _vehicle = _x; - _needToAdd = false; - _action = []; + private _actions = []; + private _vehicle = _x; + private _needToAdd = false; + private _action = []; if !((_vehicle == _target) || (_vehicle isKindOf "CAManBase")) then { - _magazineHelper = []; + private _magazineHelper = []; { - _turretPath = _x; - _magazines = [_vehicle, _turretPath] call FUNC(getConfigMagazines); + private _turretPath = _x; + private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); { - _magazine = _x; + private _magazine = _x; _currentMagazines = { _x == _magazine } count (_vehicle magazinesTurret _turretPath); if ((_currentMagazines < ([_vehicle, _turretPath, _magazine] call FUNC(getMaxMagazines))) && !(_magazine in _magazineHelper)) then { _action = [_magazine, @@ -43,9 +42,11 @@ _vehicleActions = []; {true}, {}, [_magazine, _vehicle]] call EFUNC(interact_menu,createAction); - _actions pushBack [_action, [], _target]; - _magazineHelper pushBack _magazine; - _needToAdd = true; + if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_target, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_target, _magazine] call FUNC(magazineInSupply))}) then { + _actions pushBack [_action, [], _target]; + _magazineHelper pushBack _magazine; + _needToAdd = true; + }; } else { if (((_vehicle magazineTurretAmmo [_magazine, _turretPath]) < getNumber (configFile >> "CfgMagazines" >> _magazine >> "count")) && !(_magazine in _magazineHelper)) then { _action = [_magazine, @@ -55,16 +56,18 @@ _vehicleActions = []; {true}, {}, [_magazine, _vehicle]] call EFUNC(interact_menu,createAction); - _actions pushBack [_action, [], _target]; - _magazineHelper pushBack _magazine; - _needToAdd = true; + if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_target, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_target, _magazine] call FUNC(magazineInSupply))}) then { + _actions pushBack [_action, [], _target]; + _magazineHelper pushBack _magazine; + _needToAdd = true; + }; }; }; } forEach _magazines; } forEach REARM_TURRET_PATHS; }; if (_needToAdd && !(_vehicle getVariable [QGVAR(disabled), false])) then { - _icon = getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "Icon"); + private _icon = getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "Icon"); if !((_icon select [0, 1]) == "\") then { _icon = ""; }; diff --git a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf new file mode 100644 index 0000000000..17ec5494d1 --- /dev/null +++ b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf @@ -0,0 +1,42 @@ +/* + * Author: GitHawk + * Adds all magazines of a vehicle to the supply. + * + * Argument: + * 0: Ammo Truck + * 1: Vehicle + * or + * 0: Ammo Truck + * 1: Vehicle class + * + * Return value: + * None + * + * Example: + * [ammo_truck, tank] call ace_rearm_fnc_addVehicleMagazinesToSupply + * [ammo_truck, "B_MBT_01_arty_F"] call ace_rearm_fnc_addVehicleMagazinesToSupply + * + * Public: Yes + */ +#include "script_component.hpp" + +params [["_ammoTruck", objNull, [objNull]], ["_vehicle", objNull, [objNull, ""]]]; + +if (isNull _ammoTruck || + {typeName _vehicle == "OBJECT" && {isNull _vehicle}}) exitWith {}; + +private _string = ""; +if (typeName _vehicle == "OBJECT") then { + _string = typeOf _vehicle; +}; +if (typeName _vehicle == "STRING") then { + _string = _vehicle; +}; +if (_string == "") exitWith {[]}; +{ + private _turretPath = _x; + private _magazines = [_string, _turretPath] call FUNC(getConfigMagazines); + { + [_ammoTruck, _x] call FUNC(addMagazineToSupply); + } forEach _magazines; +} forEach REARM_TURRET_PATHS; diff --git a/addons/rearm/functions/fnc_canReadSupplyCounter.sqf b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf new file mode 100644 index 0000000000..f6991c1c27 --- /dev/null +++ b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf @@ -0,0 +1,26 @@ +/* + * Author: GitHawk + * Checks if unit can read supply counter. + * + * Arguments: + * 0: Ammo Truck + * 1: Unit + * + * Return Value: + * Can read supply counter + * + * Example: + * [truck, player] call ace_rearm_fnc_canReadSupplyCounter + * + * Public: No + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; + +!(isNull _unit || + {!(_unit isKindOf "CAManBase")} || + {!local _unit} || + {!alive _target} || + {(_target distance _unit) > REARM_ACTION_DISTANCE} || + {GVAR(supply) == 0}) diff --git a/addons/rearm/functions/fnc_canRearmVehicle.sqf b/addons/rearm/functions/fnc_canRearmVehicle.sqf new file mode 100644 index 0000000000..29de8b2a2c --- /dev/null +++ b/addons/rearm/functions/fnc_canRearmVehicle.sqf @@ -0,0 +1,26 @@ +/* + * Author: GitHawk + * Check if a unit can rearm a vehicle. + * + * Arguments: + * 0: Target + * 1: Unit + * + * Return Value: + * Can Pick Up Ammo + * + * Example: + * [player, tank] call ace_rearm_fnc_canRearmVehicle + * + * Public: No + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; + +!(isNull _unit || + {!(_unit isKindOf "CAManBase")} || + {!local _unit} || + {(_target distance _unit) > REARM_ACTION_DISTANCE} || + {!isNull (_unit getVariable [QGVAR(dummy), objNull])} || + {GVAR(level) > 0}) diff --git a/addons/rearm/functions/fnc_canTakeAmmo.sqf b/addons/rearm/functions/fnc_canTakeAmmo.sqf index 496e7a12a4..2bb4676c4f 100644 --- a/addons/rearm/functions/fnc_canTakeAmmo.sqf +++ b/addons/rearm/functions/fnc_canTakeAmmo.sqf @@ -22,4 +22,5 @@ params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; {!(_unit isKindOf "CAManBase")} || {!local _unit} || {(_target distance _unit) > REARM_ACTION_DISTANCE} || - {!isNull (_unit getVariable [QGVAR(dummy), objNull])}) + {!isNull (_unit getVariable [QGVAR(dummy), objNull])} || + {GVAR(level) == 0}) diff --git a/addons/rearm/functions/fnc_createDummy.sqf b/addons/rearm/functions/fnc_createDummy.sqf index 38955fb806..d2fbdec4c0 100644 --- a/addons/rearm/functions/fnc_createDummy.sqf +++ b/addons/rearm/functions/fnc_createDummy.sqf @@ -16,12 +16,11 @@ */ #include "script_component.hpp" -private ["_ammo", "_dummyName", "_dummy"]; params [["_unit", objNull, [objNull]], ["_magazineClass", "", [""]]]; -_ammo = getText (configFile >> "CfgMagazines" >> _magazineClass >> "ammo"); -_dummyName = getText (configFile >> "CfgAmmo" >> _ammo >> QGVAR(dummy)); -_dummy = objNull; +private _ammo = getText (configFile >> "CfgMagazines" >> _magazineClass >> "ammo"); +private _dummyName = getText (configFile >> "CfgAmmo" >> _ammo >> QGVAR(dummy)); +private _dummy = objNull; if !(_dummyName == "") then { _dummy = _dummyName createVehicle (position _unit); } else { diff --git a/addons/rearm/functions/fnc_dropAmmo.sqf b/addons/rearm/functions/fnc_dropAmmo.sqf index 48433c2f4a..1634a76c00 100644 --- a/addons/rearm/functions/fnc_dropAmmo.sqf +++ b/addons/rearm/functions/fnc_dropAmmo.sqf @@ -17,10 +17,9 @@ */ #include "script_component.hpp" -private ["_dummy", "_actionID"]; params [["_unit", objNull, [objNull]], ["_delete", false, [false]], ["_unholster", true, [true]]]; -_dummy = _unit getVariable [QGVAR(dummy), objNull]; +private _dummy = _unit getVariable [QGVAR(dummy), objNull]; if !(isNull _dummy) then { detach _dummy; if (_delete) then { @@ -29,9 +28,8 @@ if !(isNull _dummy) then { _dummy setVelocity [0,0,-0.1]; }; _unit setVariable [QGVAR(dummy), objNull]; - //_unit setVariable [QEGVAR(dragging,isCarrying), false, true]; // breaks things, since it hides interact menu on _target }; -_actionID = _unit getVariable [QGVAR(ReleaseActionID), -1]; +private _actionID = _unit getVariable [QGVAR(ReleaseActionID), -1]; if (_actionID != -1) then { _unit removeAction _actionID; _unit setVariable [QGVAR(ReleaseActionID), nil]; diff --git a/addons/rearm/functions/fnc_getCaliber.sqf b/addons/rearm/functions/fnc_getCaliber.sqf new file mode 100644 index 0000000000..fad222a571 --- /dev/null +++ b/addons/rearm/functions/fnc_getCaliber.sqf @@ -0,0 +1,48 @@ +/* + * Author: GitHawk + * Check whether enough supply is left to take the magazine. + * + * Argument: + * 0: Magazine Classname + * + * Return value: + * 0: Caliber information + * 0: Rounded caliber + * 1: Caliber index + * + * Example: + * ["500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_hasEnoughSupply + * + * Public: No + */ +#include "script_component.hpp" + +params [["_magazineClass", "", [""]]]; + +if (_magazineClass isEqualTo "") exitWith {[8, 2]}; + +private _ammo = getText (configFile >> "CfgMagazines" >> _magazineClass >> "ammo"); +private _tmpCal = getNumber (configFile >> "CfgAmmo" >> _ammo >> "ace_caliber"); +private _cal = 8; +if (_tmpCal > 0) then { + _cal = _tmpCal; +} else { + _tmpCal = getNumber (configFile >> "CfgAmmo" >> _ammo >> QGVAR(caliber)); + if (_tmpCal > 0) then { + _cal = _tmpCal; + } else { + diag_log format ["[ACE] ERROR: Undefined Ammo [%1 : %2]", _ammo, inheritsFrom (configFile >> "CfgAmmo" >> _ammo)]; + if (_ammo isKindOf "BulletBase") then { + _cal = 8; + } else { + _cal = 100; + }; + }; +}; +_cal = round _cal; +private _idx = REARM_CALIBERS find _cal; +if (_idx == -1 ) then { + _idx = 2; +}; + +[_cal, _idx] diff --git a/addons/rearm/functions/fnc_getConfigMagazines.sqf b/addons/rearm/functions/fnc_getConfigMagazines.sqf index dce6c5da64..6fb9dcebfe 100644 --- a/addons/rearm/functions/fnc_getConfigMagazines.sqf +++ b/addons/rearm/functions/fnc_getConfigMagazines.sqf @@ -3,30 +3,32 @@ * Returns all magazines a turret can hold according to config. * * Arguments: - * 0: Target + * 0: Vehicle class * 1: Turret Path * * Return Value: * Magazine classes in TurretPath * * Example: - * [vehicle, [0]] call ace_rearm_fnc_getConfigMagazines + * ["B_MBT_01_arty_F", [0]] call ace_rearm_fnc_getVehicleMagazines * * Public: No */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_turretPath", [], [[]]]]; +params [["_cfgString", "", [""]], ["_turretPath", [], [[]]]]; -if (isNull _target) exitWith {[]}; +if (_cfgString == "") exitWith {[]}; -_cfg = configFile >> "CfgVehicles" >> (typeOf _target) >> "Turrets"; +private _cfg = configFile >> "CfgVehicles" >> _cfgString >> "Turrets"; + +if !(isClass _cfg) exitWith {[]}; if (count _turretPath == 1) then { _turretPath params ["_subPath"]; if (_subPath == -1) exitWith { - _cfg = configFile >> "CfgVehicles" >> (typeOf _target); + _cfg = configFile >> "CfgVehicles" >> _cfgString; }; if (count _cfg > _subPath) then { diff --git a/addons/rearm/functions/fnc_getMaxMagazines.sqf b/addons/rearm/functions/fnc_getMaxMagazines.sqf index b6211333f0..729f9e405a 100644 --- a/addons/rearm/functions/fnc_getMaxMagazines.sqf +++ b/addons/rearm/functions/fnc_getMaxMagazines.sqf @@ -17,10 +17,9 @@ */ #include "script_component.hpp" -private ["_count", "_cfg"]; params [["_target", objNull, [objNull]], ["_turretPath", [], [[]]], ["_magazineClass", "", [""]]]; if (isNull _target) exitWith {0}; -_count = {_x == _magazineClass} count ([_target, _turretPath] call FUNC(getConfigMagazines)); +private _count = {_x == _magazineClass} count ([_target, _turretPath] call FUNC(getVehicleMagazines)); _count diff --git a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf index f56b437708..ee4c3d4876 100644 --- a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf +++ b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf @@ -19,15 +19,14 @@ */ #include "script_component.hpp" -private ["_return", "_magazines", "_currentMagazines"]; params ["_target", "_magazineClass"]; -_return = [false, [], 0]; +private _return = [false, [], 0]; { - _magazines = [_target, _x] call FUNC(getConfigMagazines); + private _magazines = [_target, _x] call FUNC(getVehicleMagazines); if (_magazineClass in _magazines) then { - _currentMagazines = {_x == _magazineClass} count (_target magazinesTurret _x); + private _currentMagazines = {_x == _magazineClass} count (_target magazinesTurret _x); if ((_target magazineTurretAmmo [_magazineClass, _x]) < getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count")) exitWith { _return = [true, _x, _currentMagazines]; diff --git a/addons/rearm/functions/fnc_getSupplyCount.sqf b/addons/rearm/functions/fnc_getSupplyCount.sqf new file mode 100644 index 0000000000..e2f881380e --- /dev/null +++ b/addons/rearm/functions/fnc_getSupplyCount.sqf @@ -0,0 +1,27 @@ +/* + * Author: GitHawk + * Get the supply count. + * + * Argument: + * 0: Target + * + * Return value: + * Supply count + * + * Example: + * [ammo_truck] call ace_rearm_fnc_getSupplyCount + * + * Public: Yes + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]]]; + +private _supply = _target getVariable QGVAR(currentSupply); + +if (isNil "_supply") then { + _supply = getNumber (configFile >> "CfgVehicles" >> typeOf _target >> QGVAR(defaultSupply)); + _target setVariable [QGVAR(currentSupply), _supply, true]; +}; + +_supply diff --git a/addons/rearm/functions/fnc_getVehicleMagazines.sqf b/addons/rearm/functions/fnc_getVehicleMagazines.sqf new file mode 100644 index 0000000000..abc0a761a7 --- /dev/null +++ b/addons/rearm/functions/fnc_getVehicleMagazines.sqf @@ -0,0 +1,23 @@ +/* + * Author: GitHawk, Jonpas + * Returns all magazines a turret can hold according to config. + * + * Arguments: + * 0: Target + * 1: Turret Path + * + * Return Value: + * Magazine classes in TurretPath + * + * Example: + * [vehicle, [0]] call ace_rearm_fnc_getVehicleMagazines + * + * Public: No + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_turretPath", [], [[]]]]; + +if (isNull _target) exitWith {[]}; + +([typeOf _target, _turretPath] call FUNC(getConfigMagazines)) diff --git a/addons/rearm/functions/fnc_hasEnoughSupply.sqf b/addons/rearm/functions/fnc_hasEnoughSupply.sqf new file mode 100644 index 0000000000..8caf0f3f45 --- /dev/null +++ b/addons/rearm/functions/fnc_hasEnoughSupply.sqf @@ -0,0 +1,39 @@ +/* + * Author: GitHawk + * Check whether enough supply is left to take the magazine. + * + * Argument: + * 0: Target + * 1: Magazine Classname + * + * Return value: + * Enough supply + * + * Example: + * [ammo_truck, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_hasEnoughSupply + * + * Public: No + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]]]; + +if (isNull _target || + {_magazineClass isEqualTo ""}) exitWith {false}; + +// With infinite supply, there is always enough +if (GVAR(supply) == 0) exitWith {true}; +// With magazine specific supply, we need to check stored magazines +if (GVAR(supply) == 2) exitWith {_this call FUNC(magazineInSupply)}; + +private _supply = [_target] call FUNC(getSupplyCount); +([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; + +// With caliber based rearming, we only need partial supply +if (GVAR(level) == 2) exitWith { + // If REARM_COUNT is bigger than the magazine size, we might get a bigger number than 1 + private _magazinePart = ((REARM_COUNT select _idx) / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; + (_cal * _magazinePart <= _supply) +}; + +(_cal <= _supply) diff --git a/addons/rearm/functions/fnc_magazineInSupply.sqf b/addons/rearm/functions/fnc_magazineInSupply.sqf new file mode 100644 index 0000000000..a11ab8c25e --- /dev/null +++ b/addons/rearm/functions/fnc_magazineInSupply.sqf @@ -0,0 +1,39 @@ +/* + * Author: GitHawk + * Returns true if the magazine is in the current supply + * + * Argument: + * 0: Target + * 1: Magazine Classname + * + * Return value: + * Magazine in supply + * + * Example: + * [ammo_truck, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_magazineInSupply + * + * Public: No + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]]]; + +if (isNull _target || + {_magazineClass isEqualTo ""}) exitWith {false}; + +// With limited supply, we need to check supply +if (GVAR(supply) == 1) exitWith {_this call FUNC(hasEnoughSupply)}; +// With magazine specific supply, we need to check them +if (GVAR(supply) == 2) exitWith { + private _magazineSupply = _target getVariable [QGVAR(magazineSupply), []]; + private _magazinePresent = false; + { + _x params ["_magazine", "_rounds"]; + if ((_magazine isEqualTo _magazineClass) && (_rounds > 0)) exitWith {_magazinePresent = true; }; + false + } count _magazineSupply; + _magazinePresent +}; + +// With infinite supply, the is always one left +true diff --git a/addons/rearm/functions/fnc_pickUpAmmo.sqf b/addons/rearm/functions/fnc_pickUpAmmo.sqf index 546fc318b7..ac1ab0a00a 100644 --- a/addons/rearm/functions/fnc_pickUpAmmo.sqf +++ b/addons/rearm/functions/fnc_pickUpAmmo.sqf @@ -16,16 +16,13 @@ */ #include "script_component.hpp" -private ["_magazineClass"]; params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; -_dummy = _unit getVariable [QGVAR(dummy), objNull]; +private _dummy = _unit getVariable [QGVAR(dummy), objNull]; if !(isNull _dummy) exitWith {}; -//_target attachTo [_unit, [0,0.7,0], "pelvis"]; _target attachTo [_unit, [0,1,0], "pelvis"]; { [[_target, [[-1,0,0],[0,0,1]]], QFUNC(makeDummy), _x] call EFUNC(common,execRemoteFnc); } count (position _unit nearObjects ["CAManBase", 100]); _unit setVariable [QGVAR(dummy), _target]; -//_unit setVariable [QEGVAR(dragging,isCarrying), true, true]; // breaks things, since it hides interact menu on _target diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf new file mode 100644 index 0000000000..4c96e926c6 --- /dev/null +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -0,0 +1,75 @@ +/* + * Author: GitHawk + * Get the remaining fuel amount + * + * Arguments: + * 0: Ammo Truck + * 1: Unit + * + * Return Value: + * None + * + * Example: + * [ammo_truck, player] call ace_rearm_fnc_readSupplyCounter + * + * Public: No + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; + +if (GVAR(supply) == 0) exitWith {}; + +if (GVAR(supply) == 1) then { + [ + 5, + [_unit, _target, [_target] call FUNC(getSupplyCount)], + { + params ["_args"]; + _args params [["_unit", objNull, [objNull]], ["_target", objNull, [objNull]], ["_supplyCount", 0, [0]]]; + if (_supplyCount > 0 ) then { + ["displayTextStructured", [_unit], [[LSTRING(Hint_RemainingSupplyPoints), _supplyCount], 2, _unit]] call EFUNC(common,targetEvent); + } else { + ["displayTextStructured", [_unit], [LSTRING(Hint_EmptySupplyPoints), 2, _unit]] call EFUNC(common,targetEvent); + }; + true + }, + {true}, + localize LSTRING(ReadSupplyCounterAction), + {true}, + ["isnotinside"] + ] call EFUNC(common,progressBar); +} else { + [ + 5, + [_unit, _target], + { + params ["_args"]; + _args params [["_unit", objNull, [objNull]], ["_target", objNull, [objNull]]]; + private _supply = 1.5; + private _numChars = count (localize LSTRING(Hint_RemainingAmmo)); + private _text = ""; + private _magazines = _target getVariable QGVAR(magazineSupply); + if !(isNil "_magazines") then { + { + _x params ["_magazineClass", "_rounds"]; + private _line = format ["%1: %2", getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), _rounds]; + _numChars = _numChars max (count _line); + _text = format ["%1
%2", _text, _line]; + _supply = _supply + 0.5; + } forEach _magazines; + diag_log _text; + }; + if (_supply > 1.5) then { + ["displayTextStructured", [_unit], [[LSTRING(Hint_RemainingAmmo), _text], _supply, _unit, (_numChars/2.9)]] call EFUNC(common,targetEvent); + } else { + ["displayTextStructured", [_unit], [LSTRING(Hint_Empty), 2, _unit]] call EFUNC(common,targetEvent); + }; + true + }, + {true}, + localize LSTRING(ReadSupplyCounterAction), + {true}, + ["isnotinside"] + ] call EFUNC(common,progressBar); +}; diff --git a/addons/rearm/functions/fnc_rearm.sqf b/addons/rearm/functions/fnc_rearm.sqf index 61009b085d..7ea08596e5 100644 --- a/addons/rearm/functions/fnc_rearm.sqf +++ b/addons/rearm/functions/fnc_rearm.sqf @@ -15,40 +15,17 @@ */ #include "script_component.hpp" -private ["_magazineClass", "_ammo", "_tmpCal", "_cal", "_idx", "_needRearmMags", "_magazineDisplayName"]; params [["_unit", objNull, [objNull]]]; -_dummy = _unit getVariable [QGVAR(dummy), objNull]; +private _dummy = _unit getVariable [QGVAR(dummy), objNull]; if (isNull _dummy) exitwith {false}; -_magazineClass = _dummy getVariable QGVAR(magazineClass); +private _magazineClass = _dummy getVariable QGVAR(magazineClass); if (isNil "_magazineClass") exitWith {false}; -_ammo = getText (configFile >> "CfgMagazines" >> _magazineClass >> "ammo"); -_tmpCal = getNumber (configFile >> "CfgAmmo" >> _ammo >> "ace_caliber"); -_cal = 8; -if (_tmpCal > 0) then { - _cal = _tmpCal; -} else { - _tmpCal = getNumber (configFile >> "CfgAmmo" >> _ammo >> QGVAR(caliber)); - if (_tmpCal > 0) then { - _cal = _tmpCal; - } else { - diag_log format ["[ACE] ERROR: Undefined Ammo [%1 : %2]", _ammo, inheritsFrom (configFile >> "CfgAmmo" >> _ammo)]; - if (_ammo isKindOf "BulletBase") then { - _cal = 8; - } else { - _cal = 100; - }; - }; -}; -_cal = round _cal; -_idx = REARM_CALIBERS find _cal; -if (_idx == -1) then { - _idx = 2; -}; +([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; // Get magazines that can be rearmed -_needRearmMags = [_target, _magazineClass] call FUNC(getNeedRearmMagazines); +private _needRearmMags = [_target, _magazineClass] call FUNC(getNeedRearmMagazines); _needRearmMags params ["_needRearm", "_turretPath", "_cnt"]; // Exit if no magazines need rearming @@ -56,9 +33,7 @@ if (!_needRearm) exitWith { diag_log format ["[ACE] ERROR: Could not find turret for %1 in %2", _magazineClass, typeOf _target]; }; -//hint format ["Magazine: %1\nAmmo: %2\nCaliber: %3\nIndex: %4\nTurretPath: %5\nREARM_DURATION_REARM: %6\nCount: %7", _magazine, _ammo, _cal, _idx, _turretPath, (REARM_DURATION_REARM select _idx), (REARM_COUNT select _idx)]; - -_magazineDisplayName = getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"); +private _magazineDisplayName = getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"); if (_magazineDisplayName == "") then { _magazineDisplayName = _magazineClass; diag_log format ["[ACE] ERROR: Magazine is missing display name [%1]", _magazineClass]; diff --git a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf index 27fd20c528..4c8076f5f8 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf @@ -16,11 +16,12 @@ * Public: No */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_vehicle", objNull, [objNull]]]; // _target is for future possible finite ammo, _unit placeholder + +params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_vehicle", objNull, [objNull]]]; [ 10, - _vehicle, + [_target, _vehicle], FUNC(rearmEntireVehicleSuccess), "", format [localize LSTRING(BasicRearmAction), getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf index c12286516c..1e1e58c86a 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf @@ -3,28 +3,30 @@ * Rearm an entire vehicle. * * Arguments: - * 0: Vehicle + * 0: Rearm information + * 0: Target + * 1: Vehicle - * 1: TurretPath + * 0: Target + * 1: Vehicle + * 2: TurretPath * * Return Value: * None * * Example: - * [tank, [0]] call ace_rearm_fnc_rearmEntireVehicleSuccessLocal + * [ammo_truck, tank, [0]] call ace_rearm_fnc_rearmEntireVehicleSuccessLocal * * Public: No */ #include "script_component.hpp" -private ["_magazines", "_magazine", "_currentMagazines", "_maxMagazines", "_maxRounds", "_currentRounds"]; -params [["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; +params [["_target", objNull, [objNull]], ["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; -_magazines = [_vehicle, _turretPath] call FUNC(getConfigMagazines); +private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); +if (isNil "_magazines") exitWith {}; { - _magazine = _x; - _currentMagazines = { _x == _magazine } count (_vehicle magazinesTurret _turretPath); - _maxMagazines = [_vehicle, _turretPath, _magazine] call FUNC(getMaxMagazines); - _maxRounds = getNumber (configFile >> "CfgMagazines" >> _magazine >> "count"); - _currentRounds = _vehicle magazineTurretAmmo [_magazine, _turretPath]; + private _magazine = _x; + private _currentMagazines = { _x == _magazine } count (_vehicle magazinesTurret _turretPath); + private _maxMagazines = [_vehicle, _turretPath, _magazine] call FUNC(getMaxMagazines); + private _maxRounds = getNumber (configFile >> "CfgMagazines" >> _magazine >> "count"); + private _currentRounds = _vehicle magazineTurretAmmo [_magazine, _turretPath]; TRACE_7("Rearmed Turret",_vehicle,_turretPath,_currentMagazines,_maxMagazines,_currentRounds,_maxRounds,_magazine); @@ -34,11 +35,27 @@ _magazines = [_vehicle, _turretPath] call FUNC(getConfigMagazines); _currentMagazines = _currentMagazines + 1; }; if (_currentMagazines < _maxMagazines) then { - _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; - for "_idx" from 1 to (_maxMagazines - _currentMagazines) do { - _vehicle addMagazineTurret [_magazine, _turretPath]; + private _success = true; + if (GVAR(supply) > 0) then { + _success = [_target, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); + }; + if (_success) then { + _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; + for "_idx" from 1 to (_maxMagazines - _currentMagazines) do { + _success = true; + if (GVAR(supply) > 0) then { + _success = [_target, _magazine, _maxRounds] call FUNC(removeMagazineFromSupply); + }; + _vehicle addMagazineTurret [_magazine, _turretPath]; + }; }; } else { - _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; + private _success = true; + if (GVAR(supply) > 0) then { + _success = [_target, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); + }; + if (_success) then { + _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; + }; }; } foreach _magazines; diff --git a/addons/rearm/functions/fnc_rearmSuccess.sqf b/addons/rearm/functions/fnc_rearmSuccess.sqf index 81cda9f262..79341a99e5 100644 --- a/addons/rearm/functions/fnc_rearmSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmSuccess.sqf @@ -21,7 +21,6 @@ */ #include "script_component.hpp" -private ["_dummy", "_weaponSelect", "_turretOwnerID"]; params [["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]]]; _args params ["_target", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; @@ -32,7 +31,7 @@ if (local _unit) then { }; if (isServer) then { - _turretOwnerID = _target turretOwner _turretPath; + private _turretOwnerID = _target turretOwner _turretPath; if (_turretOwnerID == 0) then { [_this, QFUNC(rearmSuccessLocal), _target] call EFUNC(common,execRemoteFnc); } else { diff --git a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf index 1789767cfd..22923d5452 100644 --- a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf @@ -21,21 +21,19 @@ */ #include "script_component.hpp" -private ["_rounds", "_currentRounds", "_maxMagazines", "_currentMagazines", "_dummy", "_weaponSelect"]; params [["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]]]; _args params ["_target", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; -//hint format ["Target: %1\nTurretPath: %2\nNumMagazines: %3\nMagazine: %4\nNumRounds: %5\nUnit: %6", _target, _turretPath, _numMagazines, _magazineClass, _numRounds, _unit]; +private _rounds = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); +private _currentRounds = 0; +private _maxMagazines = [_target, _turretPath, _magazineClass] call FUNC(getMaxMagazines); -_rounds = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); -_currentRounds = 0; - -_maxMagazines = [_target, _turretPath, _magazineClass] call FUNC(getMaxMagazines); if (_maxMagazines == 1) then { - _currentMagazines = { _x == _magazineClass } count (_target magazinesTurret _turretPath); + private _currentMagazines = { _x == _magazineClass } count (_target magazinesTurret _turretPath); if (_currentMagazines == 0 && {!(_turretPath isEqualTo [-1])}) then { // Driver gun will always retain it's magazines _target addMagazineTurret [_magazineClass, _turretPath]; + _target setMagazineTurretAmmo [_magazineClass, 0, _turretPath]; }; if (GVAR(level) == 1) then { // Fill magazine completely diff --git a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf new file mode 100644 index 0000000000..5c59221f7a --- /dev/null +++ b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf @@ -0,0 +1,86 @@ +/* + * Author: GitHawk + * Removes a magazine from the supply. + * + * Argument: + * 0: Target + * 1: Magazine Classname + * 2: Number of Rounds to withdraw + * + * Return value: + * Magazine was removed + * + * Example: + * [ammo_truck, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_removeMagazineFromSupply + * + * Public: Yes + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]], ["_numRounds", -1, [0]]]; + +if (isNull _target || + {_magazineClass isEqualTo ""}) exitWith {false}; + +private _return = false; +([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; + +if (GVAR(supply) == 1) then { + private _supply = [_target] call FUNC(getSupplyCount); + if (GVAR(level) == 2) then { + // Remove partial magazine supply count + private _rearmAmount = (REARM_COUNT select _idx); + if (_numRounds > 0) then { + _rearmAmount = _numRounds; + }; + private _magazinePart = (_rearmAmount / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; + if (_supply >= (_cal * _magazinePart)) then { + [_target, (_supply - (_cal * _magazinePart))] call FUNC(setSupplyCount); + _return = true; + }; + } else { + // Remove entire magazine supply count + if (_supply >= _cal) then { + [_target, (_supply - _cal)] call FUNC(setSupplyCount); + _return = true; + }; + }; +}; +if (GVAR(supply) == 2) then { + private _magazineSupply = _target getVariable [QGVAR(magazineSupply), []]; + private _magazineIdx = -1; + { + _x params ["_magazine"]; + if ((_magazine isEqualTo _magazineClass)) exitWith { + _magazineIdx = _forEachIndex; + }; + } forEach _magazineSupply; + if (_magazineIdx == -1) exitWith {false}; + + (_magazineSupply select _magazineIdx) params ["", "_rounds"]; + + private _configRounds = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); + if (GVAR(level) == 2) then { + // With caliber based rearming, we need to remove the correct amount + private _rearmAmount = (REARM_COUNT select _idx); + if (_numRounds > 0) then { + if (_numRounds > _rearmAmount) then { + _rearmAmount = ceil (_numRounds / _rearmAmount); + }; + }; + private _roundsPerTransaction = _rearmAmount min _configRounds; + if (_rounds >= _roundsPerTransaction) then { + _magazineSupply set [_magazineIdx, [_magazineClass, (_rounds - _roundsPerTransaction)]]; + _target setVariable [QGVAR(magazineSupply), _magazineSupply, true]; + _return = true; + }; + } else { + // Remove entire magazine + if (_rounds >= _configRounds) then { + _magazineSupply set [_magazineIdx, [_magazineClass, (_rounds - _configRounds)]]; + _target setVariable [QGVAR(magazineSupply), _magazineSupply, true]; + _return = true; + }; + }; +}; +_return diff --git a/addons/rearm/functions/fnc_setSupplyCount.sqf b/addons/rearm/functions/fnc_setSupplyCount.sqf new file mode 100644 index 0000000000..846ec98ea2 --- /dev/null +++ b/addons/rearm/functions/fnc_setSupplyCount.sqf @@ -0,0 +1,23 @@ +/* + * Author: GitHawk + * Sets the supply count. + * + * Argument: + * 0: Target + * 1: Supply Count + * + * Return value: + * None + * + * Example: + * [ammo_truck, 1000] call ace_rearm_fnc_setSupplyCount + * + * Public: Yes + */ +#include "script_component.hpp" + +params [["_target", objNull, [objNull]], ["_supply", 0, [0]]]; + +if (isNull _target) exitWith {}; + +_target setVariable [QGVAR(currentSupply), (_supply max 0), true]; diff --git a/addons/rearm/functions/fnc_storeAmmo.sqf b/addons/rearm/functions/fnc_storeAmmo.sqf index 262affb1ef..7026c9429a 100644 --- a/addons/rearm/functions/fnc_storeAmmo.sqf +++ b/addons/rearm/functions/fnc_storeAmmo.sqf @@ -16,16 +16,20 @@ */ #include "script_component.hpp" -private "_dummy"; params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; -_dummy = _unit getVariable [QGVAR(dummy), objNull]; +private _dummy = _unit getVariable [QGVAR(dummy), objNull]; if (isNull _dummy) exitwith {}; [ 5, - _unit, - {params ["_unit"]; [_unit, true, true] call FUNC(dropAmmo)}, + [_unit, _target, _dummy], + { + params ["_args"]; + _args params ["_unit", "_target", "_dummy"]; + [_target, (_dummy getVariable [QGVAR(magazineClass), ""]), true] call FUNC(addMagazineToSupply); + [_unit, true, true] call FUNC(dropAmmo); + }, "", format [localize LSTRING(StoreAmmoAction), getText(configFile >> "CfgMagazines" >> (_dummy getVariable QGVAR(magazineClass)) >> "displayName"), getText(configFile >> "CfgVehicles" >> (typeOf _target) >> "displayName")], {true}, diff --git a/addons/rearm/functions/fnc_takeAmmo.sqf b/addons/rearm/functions/fnc_takeAmmo.sqf index d2de1e1b59..776d88fc66 100644 --- a/addons/rearm/functions/fnc_takeAmmo.sqf +++ b/addons/rearm/functions/fnc_takeAmmo.sqf @@ -19,34 +19,10 @@ */ #include "script_component.hpp" -private ["_ammo", "_tmpCal", "_cal", "_idx"]; - params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_args", ["", objNull], [[]]]]; _args params ["_magazineClass", "_vehicle"]; -_ammo = getText (configFile >> "CfgMagazines" >> _magazineClass >> "ammo"); -_tmpCal = getNumber (configFile >> "CfgAmmo" >> _ammo >> "ace_caliber"); -_cal = 8; -if (_tmpCal > 0) then { - _cal = _tmpCal; -} else { - _tmpCal = getNumber (configFile >> "CfgAmmo" >> _ammo >> QGVAR(caliber)); - if (_tmpCal > 0) then { - _cal = _tmpCal; - } else { - diag_log format ["[ACE] ERROR: Undefined Ammo [%1 : %2]", _ammo, inheritsFrom (configFile >> "CfgAmmo" >> _ammo)]; - if (_ammo isKindOf "BulletBase") then { - _cal = 8; - } else { - _cal = 100; - }; - }; -}; -_cal = round _cal; -_idx = REARM_CALIBERS find _cal; -if (_idx == -1 ) then { - _idx = 2; -}; +([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; REARM_HOLSTER_WEAPON diff --git a/addons/rearm/functions/fnc_takeSuccess.sqf b/addons/rearm/functions/fnc_takeSuccess.sqf index 6d5966c9f9..b83f82aa2a 100644 --- a/addons/rearm/functions/fnc_takeSuccess.sqf +++ b/addons/rearm/functions/fnc_takeSuccess.sqf @@ -18,15 +18,20 @@ */ #include "script_component.hpp" -private ["_ammo", "_dummyName", "_dummy", "_actionID"]; -params [["_args", [objNull, "", objNull], [[]]]]; -_args params ["_unit", "_magazineClass", "_target"]; // _target is for future possible finite ammo +params [["_args", [objNull, "", objNull], [[]], 3]]; +_args params ["_unit", "_magazineClass", "_target"]; + +private _success = true; +if (GVAR(supply) > 0) then { + _success = [_target, _magazineClass] call FUNC(removeMagazineFromSupply); +}; +if !(_success) exitWith {}; [_unit, "forceWalk", QGVAR(vehRearm), true] call EFUNC(common,statusEffect_set); -_dummy = [_unit, _magazineClass] call FUNC(createDummy); +private _dummy = [_unit, _magazineClass] call FUNC(createDummy); [_dummy, _unit] call FUNC(pickUpAmmo); -_actionID = _unit addAction [ +private _actionID = _unit addAction [ format ["%1", localize ELSTRING(dragging,Drop)], '(_this select 0) call FUNC(dropAmmo)', nil, diff --git a/addons/rearm/stringtable.xml b/addons/rearm/stringtable.xml index 0b4fe1c90f..97ae997dd9 100644 --- a/addons/rearm/stringtable.xml +++ b/addons/rearm/stringtable.xml @@ -83,10 +83,34 @@ Unlimited ammo supply Unbegrenzter Munitionsvorat + + Limited ammo supply based on caliber + Begrenzter, kaliberabhängiger Munitionsvorat + Only specific Magazines Nur bestimmte Magazine + + Check remaining ammunition + Verbleibende Munition prüfen + + + Checking remaining ammunition... + Überprüfe verbleibende Munition... + + + There is ammunition worth %1 points left. + Es ist noch Munition für %1 Punkte übrig. + + + The following ammunition is left:%1 + Folgende Munition ist übrig:%1 + + + There is no ammunition left. + Es ist keine Munition übrig. + Rearm Aufmunitionieren From 8b87f1b43a1535d9737838e3cf344df2edc9018a Mon Sep 17 00:00:00 2001 From: Githawk Date: Sat, 27 Feb 2016 20:37:47 +0100 Subject: [PATCH 03/36] Custom width displayTextStructured Adding width as optional fourth parameter --- addons/common/functions/fnc_displayTextStructured.sqf | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/addons/common/functions/fnc_displayTextStructured.sqf b/addons/common/functions/fnc_displayTextStructured.sqf index 9fff7bb056..0271f8f3ff 100644 --- a/addons/common/functions/fnc_displayTextStructured.sqf +++ b/addons/common/functions/fnc_displayTextStructured.sqf @@ -1,11 +1,12 @@ /* - * Author: commy2, Glowbal + * Author: commy2, Glowbal, GitHawk * Display a structured text. * * Arguments: * 0: Text * 1: Size of the textbox (default: 1.5) * 2: Target Unit. Will only display if target is the player controlled object (default: ACE_player) + * 3: Custom Width * * Return Value: * None @@ -14,7 +15,7 @@ */ #include "script_component.hpp" -params ["_text", ["_size", 1.5], ["_target", ACE_player]]; +params ["_text", ["_size", 1.5], ["_target", ACE_player], ["_width", 10]]; if (_target != ACE_player) exitWith {}; @@ -52,9 +53,9 @@ private _wPos = profilenamespace getVariable ["IGUI_GRID_ACE_displayText_W", (10 private _hPos = profilenamespace getVariable ["IGUI_GRID_ACE_displayText_H", (2 *((((safezoneW / safezoneH) min 1.2) / 1.2) / 25))]; */ -private _xPos = ((safezoneX + safezoneW) - (10 *(((safezoneW / safezoneH) min 1.2) / 40)) - 2.9 *(((safezoneW / safezoneH) min 1.2) / 40)); +private _xPos = ((safezoneX + safezoneW) - (_width *(((safezoneW / safezoneH) min 1.2) / 40)) - 2.9 *(((safezoneW / safezoneH) min 1.2) / 40)); private _yPos = safeZoneY + 0.175 * safezoneH; -private _wPos = (10 *(((safezoneW / safezoneH) min 1.2) / 40)); +private _wPos = (_width *(((safezoneW / safezoneH) min 1.2) / 40)); private _hPos = (2 *((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)); // Zeus Interface Open and Display would be under the "CREATE" list From 734c8b196289ed1ce2d45d726fed49f432771dcf Mon Sep 17 00:00:00 2001 From: Githawk Date: Sat, 27 Feb 2016 20:45:04 +0100 Subject: [PATCH 04/36] Minor fix --- addons/rearm/functions/fnc_readSupplyCounter.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf index 4c96e926c6..bbbaa0ef84 100644 --- a/addons/rearm/functions/fnc_readSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk - * Get the remaining fuel amount + * Get the remaining ammunition amount * * Arguments: * 0: Ammo Truck From 3d7c51bdf174d18c36c87e516eb43d4d4b1a097e Mon Sep 17 00:00:00 2001 From: Githawk Date: Sat, 27 Feb 2016 21:05:19 +0100 Subject: [PATCH 05/36] Cleanup --- .../functions/fnc_addMagazineToSupply.sqf | 16 +++---- .../rearm/functions/fnc_addRearmActions.sqf | 18 ++++---- .../fnc_addVehicleMagazinesToSupply.sqf | 6 +-- .../functions/fnc_canReadSupplyCounter.sqf | 8 ++-- addons/rearm/functions/fnc_canRearm.sqf | 15 +++--- .../rearm/functions/fnc_canRearmVehicle.sqf | 8 ++-- addons/rearm/functions/fnc_canStoreAmmo.sqf | 6 +-- addons/rearm/functions/fnc_canTakeAmmo.sqf | 6 +-- addons/rearm/functions/fnc_createDummy.sqf | 2 +- addons/rearm/functions/fnc_disable.sqf | 6 +-- addons/rearm/functions/fnc_dropAmmo.sqf | 4 +- addons/rearm/functions/fnc_getCaliber.sqf | 2 +- .../rearm/functions/fnc_getMaxMagazines.sqf | 8 ++-- .../functions/fnc_getNeedRearmMagazines.sqf | 12 ++--- addons/rearm/functions/fnc_getSupplyCount.sqf | 10 ++-- .../functions/fnc_getVehicleMagazines.sqf | 8 ++-- .../rearm/functions/fnc_hasEnoughSupply.sqf | 8 ++-- .../rearm/functions/fnc_magazineInSupply.sqf | 8 ++-- addons/rearm/functions/fnc_pickUpAmmo.sqf | 12 ++--- .../rearm/functions/fnc_readSupplyCounter.sqf | 14 +++--- addons/rearm/functions/fnc_rearm.sqf | 6 +-- .../functions/fnc_rearmEntireVehicle.sqf | 4 +- .../fnc_rearmEntireVehicleSuccess.sqf | 8 ++-- .../fnc_rearmEntireVehicleSuccessLocal.sqf | 10 ++-- addons/rearm/functions/fnc_rearmSuccess.sqf | 10 ++-- .../rearm/functions/fnc_rearmSuccessLocal.sqf | 46 +++++++++---------- .../fnc_removeMagazineFromSupply.sqf | 18 ++++---- addons/rearm/functions/fnc_setSupplyCount.sqf | 8 ++-- addons/rearm/functions/fnc_storeAmmo.sqf | 18 ++++---- addons/rearm/functions/fnc_takeAmmo.sqf | 4 +- addons/rearm/functions/fnc_takeSuccess.sqf | 6 +-- 31 files changed, 157 insertions(+), 158 deletions(-) diff --git a/addons/rearm/functions/fnc_addMagazineToSupply.sqf b/addons/rearm/functions/fnc_addMagazineToSupply.sqf index 781af9e2f4..2f2879010c 100644 --- a/addons/rearm/functions/fnc_addMagazineToSupply.sqf +++ b/addons/rearm/functions/fnc_addMagazineToSupply.sqf @@ -3,7 +3,7 @@ * Adds magazines to the supply. * * Argument: - * 0: Target + * 0: Ammo Truck * 1: Magazine Classname * 2: Only partial * @@ -17,27 +17,27 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]], ["_partial", false, [false]]]; +params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]], ["_partial", false, [false]]]; -if (isNull _target || +if (isNull _truck || {_magazineClass isEqualTo ""} || {GVAR(supply) == 0}) exitWith {}; // With limited supply, we add the caliber to the supply count if (GVAR(supply) == 1) then { - private _supply = [_target] call FUNC(getSupplyCount); + private _supply = [_truck] call FUNC(getSupplyCount); ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; if (!_partial || {GVAR(level) == 1}) then { - [_target, _supply + _cal] call FUNC(setSupplyCount); + [_truck, _supply + _cal] call FUNC(setSupplyCount); } else { private _magazinePart = ((REARM_COUNT select _idx) / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; - [_target, (_supply + (_cal * _magazinePart))] call FUNC(setSupplyCount); + [_truck, (_supply + (_cal * _magazinePart))] call FUNC(setSupplyCount); }; }; // With magazine specific supply, we add or update the magazineSupply array if (GVAR(supply) == 2) then { - private _magazineSupply = _target getVariable [QGVAR(magazineSupply), []]; + private _magazineSupply = _truck getVariable [QGVAR(magazineSupply), []]; private _magazineIdx = -1; { _x params ["_magazine", "_rounds"]; @@ -60,5 +60,5 @@ if (GVAR(supply) == 2) then { (_magazineSupply select _magazineIdx) params ["", "_rounds"]; _magazineSupply set [_magazineIdx, [_magazineClass, (_rounds + _roundsPerTransaction)]]; }; - _target setVariable [QGVAR(magazineSupply), _magazineSupply, true]; + _truck setVariable [QGVAR(magazineSupply), _magazineSupply, true]; }; diff --git a/addons/rearm/functions/fnc_addRearmActions.sqf b/addons/rearm/functions/fnc_addRearmActions.sqf index b2b388a3fd..d6e37b86b6 100644 --- a/addons/rearm/functions/fnc_addRearmActions.sqf +++ b/addons/rearm/functions/fnc_addRearmActions.sqf @@ -15,9 +15,9 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]]]; -private _vehicles = nearestObjects [_target, ["AllVehicles"], 20]; +private _vehicles = nearestObjects [_truck, ["AllVehicles"], 20]; if (count _vehicles < 2) exitWith {false}; // Rearming needs at least 2 vehicles private _vehicleActions = []; @@ -26,7 +26,7 @@ private _vehicleActions = []; private _vehicle = _x; private _needToAdd = false; private _action = []; - if !((_vehicle == _target) || (_vehicle isKindOf "CAManBase")) then { + if !((_vehicle == _truck) || (_vehicle isKindOf "CAManBase")) then { private _magazineHelper = []; { private _turretPath = _x; @@ -42,8 +42,8 @@ private _vehicleActions = []; {true}, {}, [_magazine, _vehicle]] call EFUNC(interact_menu,createAction); - if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_target, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_target, _magazine] call FUNC(magazineInSupply))}) then { - _actions pushBack [_action, [], _target]; + if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_truck, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_truck, _magazine] call FUNC(magazineInSupply))}) then { + _actions pushBack [_action, [], _truck]; _magazineHelper pushBack _magazine; _needToAdd = true; }; @@ -56,8 +56,8 @@ private _vehicleActions = []; {true}, {}, [_magazine, _vehicle]] call EFUNC(interact_menu,createAction); - if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_target, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_target, _magazine] call FUNC(magazineInSupply))}) then { - _actions pushBack [_action, [], _target]; + if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_truck, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_truck, _magazine] call FUNC(magazineInSupply))}) then { + _actions pushBack [_action, [], _truck]; _magazineHelper pushBack _magazine; _needToAdd = true; }; @@ -79,7 +79,7 @@ private _vehicleActions = []; {true}, {}, _vehicle] call EFUNC(interact_menu,createAction); - _vehicleActions pushBack [_action, [], _target]; + _vehicleActions pushBack [_action, [], _truck]; } else { _action = [_vehicle, getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName"), @@ -88,7 +88,7 @@ private _vehicleActions = []; {true}, {}, []] call EFUNC(interact_menu,createAction); - _vehicleActions pushBack [_action, _actions, _target]; + _vehicleActions pushBack [_action, _actions, _truck]; }; }; } forEach _vehicles; diff --git a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf index 17ec5494d1..5f7288cf51 100644 --- a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf +++ b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf @@ -20,9 +20,9 @@ */ #include "script_component.hpp" -params [["_ammoTruck", objNull, [objNull]], ["_vehicle", objNull, [objNull, ""]]]; +params [["_truck", objNull, [objNull]], ["_vehicle", objNull, [objNull, ""]]]; -if (isNull _ammoTruck || +if (isNull _truck || {typeName _vehicle == "OBJECT" && {isNull _vehicle}}) exitWith {}; private _string = ""; @@ -37,6 +37,6 @@ if (_string == "") exitWith {[]}; private _turretPath = _x; private _magazines = [_string, _turretPath] call FUNC(getConfigMagazines); { - [_ammoTruck, _x] call FUNC(addMagazineToSupply); + [_truck, _x] call FUNC(addMagazineToSupply); } forEach _magazines; } forEach REARM_TURRET_PATHS; diff --git a/addons/rearm/functions/fnc_canReadSupplyCounter.sqf b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf index f6991c1c27..f3b4fdba12 100644 --- a/addons/rearm/functions/fnc_canReadSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf @@ -10,17 +10,17 @@ * Can read supply counter * * Example: - * [truck, player] call ace_rearm_fnc_canReadSupplyCounter + * [ammo_truck, player] call ace_rearm_fnc_canReadSupplyCounter * * Public: No */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || {!local _unit} || - {!alive _target} || - {(_target distance _unit) > REARM_ACTION_DISTANCE} || + {!alive _truck} || + {(_truck distance _unit) > REARM_ACTION_DISTANCE} || {GVAR(supply) == 0}) diff --git a/addons/rearm/functions/fnc_canRearm.sqf b/addons/rearm/functions/fnc_canRearm.sqf index 202524dd10..8ea0c69c50 100644 --- a/addons/rearm/functions/fnc_canRearm.sqf +++ b/addons/rearm/functions/fnc_canRearm.sqf @@ -3,27 +3,26 @@ * Check if a unit can rearm. * * Arguments: - * 0: Target + * 0: Vehicle * 1: Unit * * Return Value: * Can Rearm * * Example: - * [player, tank] call ace_rearm_fnc_canRearm + * [tank, player] call ace_rearm_fnc_canRearm * * Public: No */ #include "script_component.hpp" -private ["_dummy","_magazineClass"]; -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_vehicle", objNull, [objNull]], ["_unit", objNull, [objNull]]]; -if (GVAR(level) == 0 || {isNull _unit} || {!(_unit isKindOf "CAManBase")} || {!local _unit} || {_target distance _unit > REARM_ACTION_DISTANCE} || {_target getVariable [QGVAR(disabled), false]}) exitWith {false}; +if (GVAR(level) == 0 || {isNull _unit} || {!(_unit isKindOf "CAManBase")} || {!local _unit} || {_vehicle distance _unit > REARM_ACTION_DISTANCE} || {_vehicle getVariable [QGVAR(disabled), false]}) exitWith {false}; -_dummy = _unit getVariable [QGVAR(dummy), objNull]; +private _dummy = _unit getVariable [QGVAR(dummy), objNull]; if (isNull _dummy) exitwith {false}; -_magazineClass = _dummy getVariable QGVAR(magazineClass); +private _magazineClass = _dummy getVariable QGVAR(magazineClass); if (isNil "_magazineClass") exitWith {false}; -([_target, _magazineClass] call FUNC(getNeedRearmMagazines)) select 0 +([_vehicle, _magazineClass] call FUNC(getNeedRearmMagazines)) select 0 diff --git a/addons/rearm/functions/fnc_canRearmVehicle.sqf b/addons/rearm/functions/fnc_canRearmVehicle.sqf index 29de8b2a2c..5d953e8e08 100644 --- a/addons/rearm/functions/fnc_canRearmVehicle.sqf +++ b/addons/rearm/functions/fnc_canRearmVehicle.sqf @@ -3,24 +3,24 @@ * Check if a unit can rearm a vehicle. * * Arguments: - * 0: Target + * 0: Vehicle * 1: Unit * * Return Value: * Can Pick Up Ammo * * Example: - * [player, tank] call ace_rearm_fnc_canRearmVehicle + * [tank, player] call ace_rearm_fnc_canRearmVehicle * * Public: No */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_vehicle", objNull, [objNull]], ["_unit", objNull, [objNull]]]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || {!local _unit} || - {(_target distance _unit) > REARM_ACTION_DISTANCE} || + {(_vehicle distance _unit) > REARM_ACTION_DISTANCE} || {!isNull (_unit getVariable [QGVAR(dummy), objNull])} || {GVAR(level) > 0}) diff --git a/addons/rearm/functions/fnc_canStoreAmmo.sqf b/addons/rearm/functions/fnc_canStoreAmmo.sqf index a3139d6f11..6e6061c5ee 100644 --- a/addons/rearm/functions/fnc_canStoreAmmo.sqf +++ b/addons/rearm/functions/fnc_canStoreAmmo.sqf @@ -10,16 +10,16 @@ * Can Store Ammo * * Example: - * [player, tank] call ace_rearm_fnc_canStoreAmmo + * [ammo_truck, player] call ace_rearm_fnc_canStoreAmmo * * Public: No */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || {!local _unit} || - {(_target distance _unit) > REARM_ACTION_DISTANCE} || + {(_truck distance _unit) > REARM_ACTION_DISTANCE} || {isNull (_unit getVariable [QGVAR(dummy), objNull])}) diff --git a/addons/rearm/functions/fnc_canTakeAmmo.sqf b/addons/rearm/functions/fnc_canTakeAmmo.sqf index 2bb4676c4f..2ae5b26b65 100644 --- a/addons/rearm/functions/fnc_canTakeAmmo.sqf +++ b/addons/rearm/functions/fnc_canTakeAmmo.sqf @@ -10,17 +10,17 @@ * Can Pick Up Ammo * * Example: - * [player, tank] call ace_rearm_fnc_canTakeAmmo + * [ammo_truck, player] call ace_rearm_fnc_canTakeAmmo * * Public: No */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || {!local _unit} || - {(_target distance _unit) > REARM_ACTION_DISTANCE} || + {(_truck distance _unit) > REARM_ACTION_DISTANCE} || {!isNull (_unit getVariable [QGVAR(dummy), objNull])} || {GVAR(level) == 0}) diff --git a/addons/rearm/functions/fnc_createDummy.sqf b/addons/rearm/functions/fnc_createDummy.sqf index d2fbdec4c0..86d0d04223 100644 --- a/addons/rearm/functions/fnc_createDummy.sqf +++ b/addons/rearm/functions/fnc_createDummy.sqf @@ -10,7 +10,7 @@ * Created Dummy * * Example: - * ["500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_createDummy + * [player, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_createDummy * * Public: No */ diff --git a/addons/rearm/functions/fnc_disable.sqf b/addons/rearm/functions/fnc_disable.sqf index b5e8b77d04..47d073efca 100644 --- a/addons/rearm/functions/fnc_disable.sqf +++ b/addons/rearm/functions/fnc_disable.sqf @@ -3,7 +3,7 @@ * Disables rearm for a vehicle. * * Arguments: - * 0: Target + * 0: Vehicle * 1: Disable * * Return Value: @@ -17,5 +17,5 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_disable", true, [true]]]; -_target setVariable [QGVAR(disabled), _disable, true]; +params [["_vehicle", objNull, [objNull]], ["_disable", true, [true]]]; +_vehicle setVariable [QGVAR(disabled), _disable, true]; diff --git a/addons/rearm/functions/fnc_dropAmmo.sqf b/addons/rearm/functions/fnc_dropAmmo.sqf index 1634a76c00..4d87370e3c 100644 --- a/addons/rearm/functions/fnc_dropAmmo.sqf +++ b/addons/rearm/functions/fnc_dropAmmo.sqf @@ -4,8 +4,8 @@ * * Arguments: * 0: Unit - * 1: Delete dummy object (optional) - * 2: Unholster Weapon (optional) + * 1: Delete dummy object + * 2: Unholster Weapon * * Return Value: * None diff --git a/addons/rearm/functions/fnc_getCaliber.sqf b/addons/rearm/functions/fnc_getCaliber.sqf index fad222a571..23521d825e 100644 --- a/addons/rearm/functions/fnc_getCaliber.sqf +++ b/addons/rearm/functions/fnc_getCaliber.sqf @@ -11,7 +11,7 @@ * 1: Caliber index * * Example: - * ["500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_hasEnoughSupply + * ["500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_getCaliber * * Public: No */ diff --git a/addons/rearm/functions/fnc_getMaxMagazines.sqf b/addons/rearm/functions/fnc_getMaxMagazines.sqf index 729f9e405a..1b1bd9ef9f 100644 --- a/addons/rearm/functions/fnc_getMaxMagazines.sqf +++ b/addons/rearm/functions/fnc_getMaxMagazines.sqf @@ -3,7 +3,7 @@ * Calculates the maximum number of magazines a turret can hold according to config. * * Arguments: - * 0: Target + * 0: Vehicle * 1: Turret Path * 2: Magazine Classname * @@ -17,9 +17,9 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_turretPath", [], [[]]], ["_magazineClass", "", [""]]]; +params [["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]], ["_magazineClass", "", [""]]]; -if (isNull _target) exitWith {0}; +if (isNull _vehicle) exitWith {0}; -private _count = {_x == _magazineClass} count ([_target, _turretPath] call FUNC(getVehicleMagazines)); +private _count = {_x == _magazineClass} count ([_vehicle, _turretPath] call FUNC(getVehicleMagazines)); _count diff --git a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf index ee4c3d4876..3bf6882e1f 100644 --- a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf +++ b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf @@ -3,7 +3,7 @@ * Get rearm return value. * * Arguments: - * 0: Target + * 0: Vehicle * 1: Magazine Classname * * Return Value: @@ -19,20 +19,20 @@ */ #include "script_component.hpp" -params ["_target", "_magazineClass"]; +params ["_vehicle", "_magazineClass"]; private _return = [false, [], 0]; { - private _magazines = [_target, _x] call FUNC(getVehicleMagazines); + private _magazines = [_vehicle, _x] call FUNC(getVehicleMagazines); if (_magazineClass in _magazines) then { - private _currentMagazines = {_x == _magazineClass} count (_target magazinesTurret _x); + private _currentMagazines = {_x == _magazineClass} count (_vehicle magazinesTurret _x); - if ((_target magazineTurretAmmo [_magazineClass, _x]) < getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count")) exitWith { + if ((_vehicle magazineTurretAmmo [_magazineClass, _x]) < getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count")) exitWith { _return = [true, _x, _currentMagazines]; }; - if (_currentMagazines < ([_target, _x, _magazineClass] call FUNC(getMaxMagazines))) exitWith { + if (_currentMagazines < ([_vehicle, _x, _magazineClass] call FUNC(getMaxMagazines))) exitWith { _return = [true, _x, _currentMagazines]; }; }; diff --git a/addons/rearm/functions/fnc_getSupplyCount.sqf b/addons/rearm/functions/fnc_getSupplyCount.sqf index e2f881380e..c3a8b1df3b 100644 --- a/addons/rearm/functions/fnc_getSupplyCount.sqf +++ b/addons/rearm/functions/fnc_getSupplyCount.sqf @@ -3,7 +3,7 @@ * Get the supply count. * * Argument: - * 0: Target + * 0: Ammo Truck * * Return value: * Supply count @@ -15,13 +15,13 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]]]; -private _supply = _target getVariable QGVAR(currentSupply); +private _supply = _truck getVariable QGVAR(currentSupply); if (isNil "_supply") then { - _supply = getNumber (configFile >> "CfgVehicles" >> typeOf _target >> QGVAR(defaultSupply)); - _target setVariable [QGVAR(currentSupply), _supply, true]; + _supply = getNumber (configFile >> "CfgVehicles" >> typeOf _truck >> QGVAR(defaultSupply)); + _truck setVariable [QGVAR(currentSupply), _supply, true]; }; _supply diff --git a/addons/rearm/functions/fnc_getVehicleMagazines.sqf b/addons/rearm/functions/fnc_getVehicleMagazines.sqf index abc0a761a7..ac687993c7 100644 --- a/addons/rearm/functions/fnc_getVehicleMagazines.sqf +++ b/addons/rearm/functions/fnc_getVehicleMagazines.sqf @@ -3,7 +3,7 @@ * Returns all magazines a turret can hold according to config. * * Arguments: - * 0: Target + * 0: Vehicle * 1: Turret Path * * Return Value: @@ -16,8 +16,8 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_turretPath", [], [[]]]]; +params [["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; -if (isNull _target) exitWith {[]}; +if (isNull _vehicle) exitWith {[]}; -([typeOf _target, _turretPath] call FUNC(getConfigMagazines)) +([typeOf _vehicle, _turretPath] call FUNC(getConfigMagazines)) diff --git a/addons/rearm/functions/fnc_hasEnoughSupply.sqf b/addons/rearm/functions/fnc_hasEnoughSupply.sqf index 8caf0f3f45..ef7c906c54 100644 --- a/addons/rearm/functions/fnc_hasEnoughSupply.sqf +++ b/addons/rearm/functions/fnc_hasEnoughSupply.sqf @@ -3,7 +3,7 @@ * Check whether enough supply is left to take the magazine. * * Argument: - * 0: Target + * 0: Ammo Truck * 1: Magazine Classname * * Return value: @@ -16,9 +16,9 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]]]; +params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]]]; -if (isNull _target || +if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; // With infinite supply, there is always enough @@ -26,7 +26,7 @@ if (GVAR(supply) == 0) exitWith {true}; // With magazine specific supply, we need to check stored magazines if (GVAR(supply) == 2) exitWith {_this call FUNC(magazineInSupply)}; -private _supply = [_target] call FUNC(getSupplyCount); +private _supply = [_truck] call FUNC(getSupplyCount); ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; // With caliber based rearming, we only need partial supply diff --git a/addons/rearm/functions/fnc_magazineInSupply.sqf b/addons/rearm/functions/fnc_magazineInSupply.sqf index a11ab8c25e..ddb925d929 100644 --- a/addons/rearm/functions/fnc_magazineInSupply.sqf +++ b/addons/rearm/functions/fnc_magazineInSupply.sqf @@ -3,7 +3,7 @@ * Returns true if the magazine is in the current supply * * Argument: - * 0: Target + * 0: Ammo Truck * 1: Magazine Classname * * Return value: @@ -16,16 +16,16 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]]]; +params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]]]; -if (isNull _target || +if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; // With limited supply, we need to check supply if (GVAR(supply) == 1) exitWith {_this call FUNC(hasEnoughSupply)}; // With magazine specific supply, we need to check them if (GVAR(supply) == 2) exitWith { - private _magazineSupply = _target getVariable [QGVAR(magazineSupply), []]; + private _magazineSupply = _truck getVariable [QGVAR(magazineSupply), []]; private _magazinePresent = false; { _x params ["_magazine", "_rounds"]; diff --git a/addons/rearm/functions/fnc_pickUpAmmo.sqf b/addons/rearm/functions/fnc_pickUpAmmo.sqf index ac1ab0a00a..e8c2b1fe84 100644 --- a/addons/rearm/functions/fnc_pickUpAmmo.sqf +++ b/addons/rearm/functions/fnc_pickUpAmmo.sqf @@ -16,13 +16,13 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_dummy", objNull, [objNull]], ["_unit", objNull, [objNull]]]; -private _dummy = _unit getVariable [QGVAR(dummy), objNull]; -if !(isNull _dummy) exitWith {}; +private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; +if !(isNull _attachedDummy) exitWith {}; -_target attachTo [_unit, [0,1,0], "pelvis"]; +_dummy attachTo [_unit, [0,1,0], "pelvis"]; { - [[_target, [[-1,0,0],[0,0,1]]], QFUNC(makeDummy), _x] call EFUNC(common,execRemoteFnc); + [[_dummy, [[-1,0,0],[0,0,1]]], QFUNC(makeDummy), _x] call EFUNC(common,execRemoteFnc); } count (position _unit nearObjects ["CAManBase", 100]); -_unit setVariable [QGVAR(dummy), _target]; +_unit setVariable [QGVAR(dummy), _dummy]; diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf index bbbaa0ef84..88485040ba 100644 --- a/addons/rearm/functions/fnc_readSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk - * Get the remaining ammunition amount + * Get the remaining ammunition amount. * * Arguments: * 0: Ammo Truck @@ -16,17 +16,17 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; if (GVAR(supply) == 0) exitWith {}; if (GVAR(supply) == 1) then { [ 5, - [_unit, _target, [_target] call FUNC(getSupplyCount)], + [_unit, _truck, [_truck] call FUNC(getSupplyCount)], { params ["_args"]; - _args params [["_unit", objNull, [objNull]], ["_target", objNull, [objNull]], ["_supplyCount", 0, [0]]]; + _args params [["_unit", objNull, [objNull]], ["_truck", objNull, [objNull]], ["_supplyCount", 0, [0]]]; if (_supplyCount > 0 ) then { ["displayTextStructured", [_unit], [[LSTRING(Hint_RemainingSupplyPoints), _supplyCount], 2, _unit]] call EFUNC(common,targetEvent); } else { @@ -42,14 +42,14 @@ if (GVAR(supply) == 1) then { } else { [ 5, - [_unit, _target], + [_unit, _truck], { params ["_args"]; - _args params [["_unit", objNull, [objNull]], ["_target", objNull, [objNull]]]; + _args params [["_unit", objNull, [objNull]], ["_truck", objNull, [objNull]]]; private _supply = 1.5; private _numChars = count (localize LSTRING(Hint_RemainingAmmo)); private _text = ""; - private _magazines = _target getVariable QGVAR(magazineSupply); + private _magazines = _truck getVariable QGVAR(magazineSupply); if !(isNil "_magazines") then { { _x params ["_magazineClass", "_rounds"]; diff --git a/addons/rearm/functions/fnc_rearm.sqf b/addons/rearm/functions/fnc_rearm.sqf index 7ea08596e5..20848b3c8b 100644 --- a/addons/rearm/functions/fnc_rearm.sqf +++ b/addons/rearm/functions/fnc_rearm.sqf @@ -17,9 +17,9 @@ params [["_unit", objNull, [objNull]]]; -private _dummy = _unit getVariable [QGVAR(dummy), objNull]; -if (isNull _dummy) exitwith {false}; -private _magazineClass = _dummy getVariable QGVAR(magazineClass); +private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; +if (isNull _attachedDummy) exitwith {false}; +private _magazineClass = _attachedDummy getVariable QGVAR(magazineClass); if (isNil "_magazineClass") exitWith {false}; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; diff --git a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf index 4c8076f5f8..5453910530 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf @@ -17,11 +17,11 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_vehicle", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]], "", ["_vehicle", objNull, [objNull]]]; [ 10, - [_target, _vehicle], + [_truck, _vehicle], FUNC(rearmEntireVehicleSuccess), "", format [localize LSTRING(BasicRearmAction), getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf index 1e1e58c86a..6b71a3b66e 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Rearm information - * 0: Target + * 0: Ammo Truck * 1: Vehicle + * 0: Ammo Truck * 1: Vehicle * 2: TurretPath * @@ -17,7 +17,7 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; +params [["_truck", objNull, [objNull]], ["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); if (isNil "_magazines") exitWith {}; @@ -37,14 +37,14 @@ if (isNil "_magazines") exitWith {}; if (_currentMagazines < _maxMagazines) then { private _success = true; if (GVAR(supply) > 0) then { - _success = [_target, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); + _success = [_truck, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); }; if (_success) then { _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; for "_idx" from 1 to (_maxMagazines - _currentMagazines) do { _success = true; if (GVAR(supply) > 0) then { - _success = [_target, _magazine, _maxRounds] call FUNC(removeMagazineFromSupply); + _success = [_truck, _magazine, _maxRounds] call FUNC(removeMagazineFromSupply); }; _vehicle addMagazineTurret [_magazine, _turretPath]; }; @@ -52,7 +52,7 @@ if (isNil "_magazines") exitWith {}; } else { private _success = true; if (GVAR(supply) > 0) then { - _success = [_target, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); + _success = [_truck, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); }; if (_success) then { _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; diff --git a/addons/rearm/functions/fnc_rearmSuccess.sqf b/addons/rearm/functions/fnc_rearmSuccess.sqf index 79341a99e5..28622332a9 100644 --- a/addons/rearm/functions/fnc_rearmSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmSuccess.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Params - * 0: Target + * 0: Vehicle * 1: Unit * 2: Turret Path * 3: Number of magazines @@ -22,18 +22,18 @@ #include "script_component.hpp" params [["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]]]; -_args params ["_target", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; +_args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; -//hint format ["Target: %1\nTurretPath: %2\nNumMagazines: %3\nMagazine: %4\nNumRounds: %5", _target, _turretPath, _numMagazines, _magazineClass, _numRounds]; +//hint format ["Vehicle: %1\nTurretPath: %2\nNumMagazines: %3\nMagazine: %4\nNumRounds: %5", _vehicle, _turretPath, _numMagazines, _magazineClass, _numRounds]; if (local _unit) then { [_unit, true, true] call FUNC(dropAmmo); }; if (isServer) then { - private _turretOwnerID = _target turretOwner _turretPath; + private _turretOwnerID = _vehicle turretOwner _turretPath; if (_turretOwnerID == 0) then { - [_this, QFUNC(rearmSuccessLocal), _target] call EFUNC(common,execRemoteFnc); + [_this, QFUNC(rearmSuccessLocal), _vehicle] call EFUNC(common,execRemoteFnc); } else { EGVAR(common,remoteFnc) = [_this, QFUNC(rearmSuccessLocal), 0]; _turretOwnerID publicVariableClient QEGVAR(common,remoteFnc); diff --git a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf index 22923d5452..c840f43436 100644 --- a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Params - * 0: Target + * 0: Vehicle * 1: Unit * 2: Turret Path * 3: Number of magazines @@ -22,67 +22,67 @@ #include "script_component.hpp" params [["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]]]; -_args params ["_target", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; +_args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; private _rounds = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); private _currentRounds = 0; -private _maxMagazines = [_target, _turretPath, _magazineClass] call FUNC(getMaxMagazines); +private _maxMagazines = [_vehicle, _turretPath, _magazineClass] call FUNC(getMaxMagazines); if (_maxMagazines == 1) then { - private _currentMagazines = { _x == _magazineClass } count (_target magazinesTurret _turretPath); + private _currentMagazines = { _x == _magazineClass } count (_vehicle magazinesTurret _turretPath); if (_currentMagazines == 0 && {!(_turretPath isEqualTo [-1])}) then { // Driver gun will always retain it's magazines - _target addMagazineTurret [_magazineClass, _turretPath]; - _target setMagazineTurretAmmo [_magazineClass, 0, _turretPath]; + _vehicle addMagazineTurret [_magazineClass, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, 0, _turretPath]; }; if (GVAR(level) == 1) then { // Fill magazine completely - _target setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _rounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _target) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); } else { // Fill only at most _numRounds - _target setMagazineTurretAmmo [_magazineClass, ((_target magazineTurretAmmo [_magazineClass, _turretPath]) + _numRounds) min _rounds, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, ((_vehicle magazineTurretAmmo [_magazineClass, _turretPath]) + _numRounds) min _rounds, _turretPath]; ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _numRounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _target) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); }; } else { for "_idx" from 1 to (_maxMagazines+1) do { - _currentRounds = _target magazineTurretAmmo [_magazineClass, _turretPath]; + _currentRounds = _vehicle magazineTurretAmmo [_magazineClass, _turretPath]; if (_currentRounds > 0 || {_idx == (_maxMagazines+1)}) exitWith { if (_idx == (_maxMagazines+1) && {!(_turretPath isEqualTo [-1])}) then { - _target addMagazineTurret [_magazineClass, _turretPath]; + _vehicle addMagazineTurret [_magazineClass, _turretPath]; }; if (GVAR(level) == 2) then { - //hint format ["Target: %1\nTurretPath: %2\nNumMagazines: %3\nMaxMagazines %4\nMagazine: %5\nNumRounds: %6\nMagazine: %7", _target, _turretPath, _numMagazines, _maxMagazines, _currentRounds, _numRounds, _magazineClass]; + //hint format ["Target: %1\nTurretPath: %2\nNumMagazines: %3\nMaxMagazines %4\nMagazine: %5\nNumRounds: %6\nMagazine: %7", _vehicle, _turretPath, _numMagazines, _maxMagazines, _currentRounds, _numRounds, _magazineClass]; // Fill only at most _numRounds if ((_currentRounds + _numRounds) > _rounds) then { - _target setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; if (_numMagazines < _maxMagazines) then { - _target addMagazineTurret [_magazineClass, _turretPath]; - _target setMagazineTurretAmmo [_magazineClass, _currentRounds + _numRounds - _rounds, _turretPath]; + _vehicle addMagazineTurret [_magazineClass, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, _currentRounds + _numRounds - _rounds, _turretPath]; }; } else { - _target setMagazineTurretAmmo [_magazineClass, _currentRounds + _numRounds, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, _currentRounds + _numRounds, _turretPath]; }; ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _numRounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _target) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); } else { // Fill current magazine completely and fill next magazine partially - _target setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; if (_numMagazines < _maxMagazines) then { - _target addMagazineTurret [_magazineClass, _turretPath]; - _target setMagazineTurretAmmo [_magazineClass, _currentRounds, _turretPath]; + _vehicle addMagazineTurret [_magazineClass, _turretPath]; + _vehicle setMagazineTurretAmmo [_magazineClass, _currentRounds, _turretPath]; }; ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _rounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _target) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); }; }; - _target removeMagazineTurret [_magazineClass, _turretPath]; + _vehicle removeMagazineTurret [_magazineClass, _turretPath]; _numMagazines = _numMagazines - 1; }; }; diff --git a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf index 5c59221f7a..4d7c18cd16 100644 --- a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf +++ b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf @@ -3,7 +3,7 @@ * Removes a magazine from the supply. * * Argument: - * 0: Target + * 0: Ammo Truck * 1: Magazine Classname * 2: Number of Rounds to withdraw * @@ -17,16 +17,16 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_magazineClass", "", [""]], ["_numRounds", -1, [0]]]; +params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]], ["_numRounds", -1, [0]]]; -if (isNull _target || +if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; private _return = false; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; if (GVAR(supply) == 1) then { - private _supply = [_target] call FUNC(getSupplyCount); + private _supply = [_truck] call FUNC(getSupplyCount); if (GVAR(level) == 2) then { // Remove partial magazine supply count private _rearmAmount = (REARM_COUNT select _idx); @@ -35,19 +35,19 @@ if (GVAR(supply) == 1) then { }; private _magazinePart = (_rearmAmount / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; if (_supply >= (_cal * _magazinePart)) then { - [_target, (_supply - (_cal * _magazinePart))] call FUNC(setSupplyCount); + [_truck, (_supply - (_cal * _magazinePart))] call FUNC(setSupplyCount); _return = true; }; } else { // Remove entire magazine supply count if (_supply >= _cal) then { - [_target, (_supply - _cal)] call FUNC(setSupplyCount); + [_truck, (_supply - _cal)] call FUNC(setSupplyCount); _return = true; }; }; }; if (GVAR(supply) == 2) then { - private _magazineSupply = _target getVariable [QGVAR(magazineSupply), []]; + private _magazineSupply = _truck getVariable [QGVAR(magazineSupply), []]; private _magazineIdx = -1; { _x params ["_magazine"]; @@ -71,14 +71,14 @@ if (GVAR(supply) == 2) then { private _roundsPerTransaction = _rearmAmount min _configRounds; if (_rounds >= _roundsPerTransaction) then { _magazineSupply set [_magazineIdx, [_magazineClass, (_rounds - _roundsPerTransaction)]]; - _target setVariable [QGVAR(magazineSupply), _magazineSupply, true]; + _truck setVariable [QGVAR(magazineSupply), _magazineSupply, true]; _return = true; }; } else { // Remove entire magazine if (_rounds >= _configRounds) then { _magazineSupply set [_magazineIdx, [_magazineClass, (_rounds - _configRounds)]]; - _target setVariable [QGVAR(magazineSupply), _magazineSupply, true]; + _truck setVariable [QGVAR(magazineSupply), _magazineSupply, true]; _return = true; }; }; diff --git a/addons/rearm/functions/fnc_setSupplyCount.sqf b/addons/rearm/functions/fnc_setSupplyCount.sqf index 846ec98ea2..8900480207 100644 --- a/addons/rearm/functions/fnc_setSupplyCount.sqf +++ b/addons/rearm/functions/fnc_setSupplyCount.sqf @@ -3,7 +3,7 @@ * Sets the supply count. * * Argument: - * 0: Target + * 0: Ammo Truck * 1: Supply Count * * Return value: @@ -16,8 +16,8 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_supply", 0, [0]]]; +params [["_truck", objNull, [objNull]], ["_supply", 0, [0]]]; -if (isNull _target) exitWith {}; +if (isNull _truck) exitWith {}; -_target setVariable [QGVAR(currentSupply), (_supply max 0), true]; +_truck setVariable [QGVAR(currentSupply), (_supply max 0), true]; diff --git a/addons/rearm/functions/fnc_storeAmmo.sqf b/addons/rearm/functions/fnc_storeAmmo.sqf index 7026c9429a..4f4c2f956f 100644 --- a/addons/rearm/functions/fnc_storeAmmo.sqf +++ b/addons/rearm/functions/fnc_storeAmmo.sqf @@ -3,35 +3,35 @@ * Stores ammo in an ammo truck. * * Arguments: - * 0: Target + * 0: Ammo Truck * 1: Unit * * Return Value: * None * * Example: - * [player, dummy] call ace_rearm_fnc_storeAmmo + * [ammo_truck, player] call ace_rearm_fnc_storeAmmo * * Public: No */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; -private _dummy = _unit getVariable [QGVAR(dummy), objNull]; -if (isNull _dummy) exitwith {}; +private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; +if (isNull _attachedDummy) exitwith {}; [ 5, - [_unit, _target, _dummy], + [_unit, _truck, _attachedDummy], { params ["_args"]; - _args params ["_unit", "_target", "_dummy"]; - [_target, (_dummy getVariable [QGVAR(magazineClass), ""]), true] call FUNC(addMagazineToSupply); + _args params ["_unit", "_truck", "_attachedDummy"]; + [_truck, (_attachedDummy getVariable [QGVAR(magazineClass), ""]), true] call FUNC(addMagazineToSupply); [_unit, true, true] call FUNC(dropAmmo); }, "", - format [localize LSTRING(StoreAmmoAction), getText(configFile >> "CfgMagazines" >> (_dummy getVariable QGVAR(magazineClass)) >> "displayName"), getText(configFile >> "CfgVehicles" >> (typeOf _target) >> "displayName")], + format [localize LSTRING(StoreAmmoAction), getText(configFile >> "CfgMagazines" >> (_attachedDummy getVariable QGVAR(magazineClass)) >> "displayName"), getText(configFile >> "CfgVehicles" >> (typeOf _truck) >> "displayName")], {true}, ["isnotinside"] ] call EFUNC(common,progressBar); diff --git a/addons/rearm/functions/fnc_takeAmmo.sqf b/addons/rearm/functions/fnc_takeAmmo.sqf index 776d88fc66..07a7854ebf 100644 --- a/addons/rearm/functions/fnc_takeAmmo.sqf +++ b/addons/rearm/functions/fnc_takeAmmo.sqf @@ -19,7 +19,7 @@ */ #include "script_component.hpp" -params [["_target", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_args", ["", objNull], [[]]]]; +params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_args", ["", objNull], [[]]]]; _args params ["_magazineClass", "_vehicle"]; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; @@ -28,7 +28,7 @@ REARM_HOLSTER_WEAPON [ (REARM_DURATION_TAKE select _idx), - [_unit, _magazineClass, _target], + [_unit, _magazineClass, _truck], FUNC(takeSuccess), "", format [localize LSTRING(TakeAction), getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], diff --git a/addons/rearm/functions/fnc_takeSuccess.sqf b/addons/rearm/functions/fnc_takeSuccess.sqf index b83f82aa2a..34006117c8 100644 --- a/addons/rearm/functions/fnc_takeSuccess.sqf +++ b/addons/rearm/functions/fnc_takeSuccess.sqf @@ -19,11 +19,11 @@ #include "script_component.hpp" params [["_args", [objNull, "", objNull], [[]], 3]]; -_args params ["_unit", "_magazineClass", "_target"]; +_args params ["_unit", "_magazineClass", "_truck"]; private _success = true; if (GVAR(supply) > 0) then { - _success = [_target, _magazineClass] call FUNC(removeMagazineFromSupply); + _success = [_truck, _magazineClass] call FUNC(removeMagazineFromSupply); }; if !(_success) exitWith {}; @@ -39,6 +39,6 @@ private _actionID = _unit addAction [ false, true, "", - '!isNull (_target getVariable [QGVAR(dummy), objNull])' + '!isNull (_truck getVariable [QGVAR(dummy), objNull])' ]; _unit setVariable [QGVAR(ReleaseActionID), _actionID]; From 3e2b01afca1d84bfdc303fc261a4e7e178b6907a Mon Sep 17 00:00:00 2001 From: Githawk Date: Sat, 27 Feb 2016 21:12:50 +0100 Subject: [PATCH 06/36] Another minor fix --- addons/rearm/functions/fnc_getCaliber.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/rearm/functions/fnc_getCaliber.sqf b/addons/rearm/functions/fnc_getCaliber.sqf index 23521d825e..28113a31ad 100644 --- a/addons/rearm/functions/fnc_getCaliber.sqf +++ b/addons/rearm/functions/fnc_getCaliber.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk - * Check whether enough supply is left to take the magazine. + * Get the caliber of the ammo in a magazine and return its parameters. * * Argument: * 0: Magazine Classname From 8e6b4f4ffb57f2ea905c99c60249a01cea9a79a1 Mon Sep 17 00:00:00 2001 From: Githawk Date: Sat, 27 Feb 2016 21:14:23 +0100 Subject: [PATCH 07/36] More docu fixes --- addons/rearm/functions/fnc_getConfigMagazines.sqf | 4 ++-- addons/rearm/functions/fnc_getVehicleMagazines.sqf | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/rearm/functions/fnc_getConfigMagazines.sqf b/addons/rearm/functions/fnc_getConfigMagazines.sqf index 6fb9dcebfe..89113e2815 100644 --- a/addons/rearm/functions/fnc_getConfigMagazines.sqf +++ b/addons/rearm/functions/fnc_getConfigMagazines.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk, Jonpas - * Returns all magazines a turret can hold according to config. + * Returns all magazines a turret of a vehicle class can hold according to config. * * Arguments: * 0: Vehicle class @@ -10,7 +10,7 @@ * Magazine classes in TurretPath * * Example: - * ["B_MBT_01_arty_F", [0]] call ace_rearm_fnc_getVehicleMagazines + * ["B_MBT_01_arty_F", [0]] call ace_rearm_fnc_getConfigMagazines * * Public: No */ diff --git a/addons/rearm/functions/fnc_getVehicleMagazines.sqf b/addons/rearm/functions/fnc_getVehicleMagazines.sqf index ac687993c7..94664e534d 100644 --- a/addons/rearm/functions/fnc_getVehicleMagazines.sqf +++ b/addons/rearm/functions/fnc_getVehicleMagazines.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk, Jonpas - * Returns all magazines a turret can hold according to config. + * Returns all magazines a turret of a vehicle object can hold according to config. * * Arguments: * 0: Vehicle From 349b05a89bd293bf023518f34b7e9f0f005448c6 Mon Sep 17 00:00:00 2001 From: GitHawk Date: Mon, 29 Feb 2016 15:21:33 +0100 Subject: [PATCH 08/36] Removed forgotten diag_log --- addons/rearm/functions/fnc_readSupplyCounter.sqf | 1 - 1 file changed, 1 deletion(-) diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf index 88485040ba..48a0a73352 100644 --- a/addons/rearm/functions/fnc_readSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -58,7 +58,6 @@ if (GVAR(supply) == 1) then { _text = format ["%1
%2", _text, _line]; _supply = _supply + 0.5; } forEach _magazines; - diag_log _text; }; if (_supply > 1.5) then { ["displayTextStructured", [_unit], [[LSTRING(Hint_RemainingAmmo), _text], _supply, _unit, (_numChars/2.9)]] call EFUNC(common,targetEvent); From 8dc99a4a4e63b059b62601cb5b36461a3b765121 Mon Sep 17 00:00:00 2001 From: Githawk Date: Sun, 6 Mar 2016 11:14:34 +0100 Subject: [PATCH 09/36] Replacing execRemoteFnc with events --- addons/rearm/XEH_postInit.sqf | 12 ++++++++++++ addons/rearm/functions/fnc_pickUpAmmo.sqf | 2 +- .../functions/fnc_rearmEntireVehicleSuccess.sqf | 5 ++--- addons/rearm/functions/fnc_rearmSuccess.sqf | 5 ++--- 4 files changed, 17 insertions(+), 7 deletions(-) diff --git a/addons/rearm/XEH_postInit.sqf b/addons/rearm/XEH_postInit.sqf index c22b84ffb4..801f3a6a91 100644 --- a/addons/rearm/XEH_postInit.sqf +++ b/addons/rearm/XEH_postInit.sqf @@ -6,3 +6,15 @@ if (isServer) then { addMissionEventHandler ["HandleDisconnect", {params ["_unit"]; [_unit] call FUNC(dropAmmo)}]; }; + +[QGVAR(makeDummyEH), { + _this call FUNC(makeDummy); +}] call EFUNC(common,addEventHandler); + +[QGVAR(rearmEntireVehicleSuccessLocalEH), { + _this call FUNC(rearmEntireVehicleSuccessLocal); +}] call EFUNC(common,addEventHandler); + +[QGVAR(rearmSuccessLocalEH), { + _this call FUNC(rearmSuccessLocal); +}] call EFUNC(common,addEventHandler); diff --git a/addons/rearm/functions/fnc_pickUpAmmo.sqf b/addons/rearm/functions/fnc_pickUpAmmo.sqf index e8c2b1fe84..3b3bbb9034 100644 --- a/addons/rearm/functions/fnc_pickUpAmmo.sqf +++ b/addons/rearm/functions/fnc_pickUpAmmo.sqf @@ -23,6 +23,6 @@ if !(isNull _attachedDummy) exitWith {}; _dummy attachTo [_unit, [0,1,0], "pelvis"]; { - [[_dummy, [[-1,0,0],[0,0,1]]], QFUNC(makeDummy), _x] call EFUNC(common,execRemoteFnc); + [QGVAR(makeDummyEH), _x, [_dummy, [[-1,0,0],[0,0,1]]]] call EFUNC(common,objectEvent); } count (position _unit nearObjects ["CAManBase", 100]); _unit setVariable [QGVAR(dummy), _dummy]; diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf index 6b71a3b66e..ccce6eec57 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf @@ -24,10 +24,9 @@ if (isServer) then { { _turretOwnerID = _vehicle turretOwner _x; if (_turretOwnerID == 0) then { - [[_truck, _vehicle, _x], QFUNC(rearmEntireVehicleSuccessLocal), _truck] call EFUNC(common,execRemoteFnc); + [QGVAR(rearmEntireVehicleSuccessLocalEH), _truck, [_truck, _vehicle, _x]] call EFUNC(common,objectEvent); } else { - EGVAR(common,remoteFnc) = [[_truck, _vehicle, _x], QFUNC(rearmEntireVehicleSuccessLocal), 0]; - _turretOwnerID publicVariableClient QEGVAR(common,remoteFnc); + [QGVAR(rearmEntireVehicleSuccessLocalEH), _turretOwnerID, [_truck, _vehicle, _x]] call EFUNC(common,targetEvent); }; } count REARM_TURRET_PATHS; } else { diff --git a/addons/rearm/functions/fnc_rearmSuccess.sqf b/addons/rearm/functions/fnc_rearmSuccess.sqf index 28622332a9..7db711edfd 100644 --- a/addons/rearm/functions/fnc_rearmSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmSuccess.sqf @@ -33,10 +33,9 @@ if (local _unit) then { if (isServer) then { private _turretOwnerID = _vehicle turretOwner _turretPath; if (_turretOwnerID == 0) then { - [_this, QFUNC(rearmSuccessLocal), _vehicle] call EFUNC(common,execRemoteFnc); + [QGVAR(rearmSuccessLocalEH), _vehicle, _this] call EFUNC(common,objectEvent); } else { - EGVAR(common,remoteFnc) = [_this, QFUNC(rearmSuccessLocal), 0]; - _turretOwnerID publicVariableClient QEGVAR(common,remoteFnc); + [QGVAR(rearmSuccessLocalEH), _turretOwnerID, _this] call EFUNC(common,targetEvent); }; } else { [_this, QFUNC(rearmSuccess), 1] call EFUNC(common,execRemoteFnc); From 29cd940fd0bd15d1004435a2591aa56369dcd06a Mon Sep 17 00:00:00 2001 From: GitHawk Date: Mon, 7 Mar 2016 07:15:01 +0100 Subject: [PATCH 10/36] Added server events --- addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf | 2 +- addons/rearm/functions/fnc_rearmSuccess.sqf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf index ccce6eec57..87145eccea 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf @@ -30,5 +30,5 @@ if (isServer) then { }; } count REARM_TURRET_PATHS; } else { - [_this, QFUNC(rearmEntireVehicleSuccess), 1] call EFUNC(common,execRemoteFnc); + [QGVAR(rearmEntireVehicleSuccessLocalEH), _this] call EFUNC(common,serverEvent); }; diff --git a/addons/rearm/functions/fnc_rearmSuccess.sqf b/addons/rearm/functions/fnc_rearmSuccess.sqf index 7db711edfd..003689c00b 100644 --- a/addons/rearm/functions/fnc_rearmSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmSuccess.sqf @@ -38,5 +38,5 @@ if (isServer) then { [QGVAR(rearmSuccessLocalEH), _turretOwnerID, _this] call EFUNC(common,targetEvent); }; } else { - [_this, QFUNC(rearmSuccess), 1] call EFUNC(common,execRemoteFnc); + [QGVAR(rearmSuccessLocalEH), _this] call EFUNC(common,serverEvent); }; From d0509830e3a77ac2bd76796404aff401a4aa74d4 Mon Sep 17 00:00:00 2001 From: GitHawk Date: Thu, 12 May 2016 14:55:40 +0200 Subject: [PATCH 11/36] Some things Made params nicer, replaced some forEach and used params in XEH_respawn --- addons/rearm/XEH_respawn.sqf | 8 +++----- addons/rearm/functions/fnc_addMagazineToSupply.sqf | 6 +++++- addons/rearm/functions/fnc_addRearmActions.sqf | 13 +++++++++---- .../functions/fnc_addVehicleMagazinesToSupply.sqf | 13 +++++++++---- addons/rearm/functions/fnc_canReadSupplyCounter.sqf | 5 ++++- addons/rearm/functions/fnc_canRearm.sqf | 5 ++++- addons/rearm/functions/fnc_canRearmVehicle.sqf | 5 ++++- addons/rearm/functions/fnc_canStoreAmmo.sqf | 5 ++++- addons/rearm/functions/fnc_canTakeAmmo.sqf | 5 ++++- addons/rearm/functions/fnc_createDummy.sqf | 5 ++++- addons/rearm/functions/fnc_disable.sqf | 6 +++++- addons/rearm/functions/fnc_dropAmmo.sqf | 6 +++++- addons/rearm/functions/fnc_getCaliber.sqf | 4 +++- addons/rearm/functions/fnc_getConfigMagazines.sqf | 5 ++++- addons/rearm/functions/fnc_getMaxMagazines.sqf | 6 +++++- .../rearm/functions/fnc_getNeedRearmMagazines.sqf | 10 +++++++--- addons/rearm/functions/fnc_getSupplyCount.sqf | 4 +++- addons/rearm/functions/fnc_getVehicleMagazines.sqf | 5 ++++- addons/rearm/functions/fnc_grabAmmo.sqf | 8 +++++--- addons/rearm/functions/fnc_handleKilled.sqf | 4 +++- addons/rearm/functions/fnc_handleUnconscious.sqf | 5 ++++- addons/rearm/functions/fnc_hasEnoughSupply.sqf | 5 ++++- addons/rearm/functions/fnc_magazineInSupply.sqf | 5 ++++- addons/rearm/functions/fnc_makeDummy.sqf | 5 ++++- addons/rearm/functions/fnc_moduleRearmSettings.sqf | 6 +++++- addons/rearm/functions/fnc_pickUpAmmo.sqf | 5 ++++- addons/rearm/functions/fnc_readSupplyCounter.sqf | 8 ++++++-- addons/rearm/functions/fnc_rearm.sqf | 4 +++- addons/rearm/functions/fnc_rearmEntireVehicle.sqf | 6 +++++- .../functions/fnc_rearmEntireVehicleSuccess.sqf | 6 +++++- .../fnc_rearmEntireVehicleSuccessLocal.sqf | 9 +++++++-- addons/rearm/functions/fnc_rearmSuccess.sqf | 4 +++- addons/rearm/functions/fnc_rearmSuccessLocal.sqf | 4 +++- .../functions/fnc_removeMagazineFromSupply.sqf | 6 +++++- addons/rearm/functions/fnc_setSupplyCount.sqf | 5 ++++- addons/rearm/functions/fnc_storeAmmo.sqf | 5 ++++- addons/rearm/functions/fnc_takeAmmo.sqf | 6 +++++- addons/rearm/functions/fnc_takeSuccess.sqf | 4 +++- 38 files changed, 172 insertions(+), 54 deletions(-) diff --git a/addons/rearm/XEH_respawn.sqf b/addons/rearm/XEH_respawn.sqf index 7f0d175d1c..4968e66b43 100644 --- a/addons/rearm/XEH_respawn.sqf +++ b/addons/rearm/XEH_respawn.sqf @@ -1,16 +1,14 @@ #include "script_component.hpp" -private ["_unit"]; - -_unit = _this select 0; +params ["_unit"]; if !(local _unit) exitWith {}; _unit setVariable [QGVAR(selectedWeaponOnRearm), nil]; _unit setVariable [QGVAR(carriedMagazine), nil]; -_dummy = _unit getVariable [QGVAR(dummy), objNull]; +private _dummy = _unit getVariable [QGVAR(dummy), objNull]; if !(isNull _dummy) then { detach _dummy; deleteVehicle _dummy; }; -_unit setVariable [QGVAR(dummy), nil]; \ No newline at end of file +_unit setVariable [QGVAR(dummy), nil]; diff --git a/addons/rearm/functions/fnc_addMagazineToSupply.sqf b/addons/rearm/functions/fnc_addMagazineToSupply.sqf index 2f2879010c..f2ccae8653 100644 --- a/addons/rearm/functions/fnc_addMagazineToSupply.sqf +++ b/addons/rearm/functions/fnc_addMagazineToSupply.sqf @@ -17,7 +17,11 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]], ["_partial", false, [false]]]; +params [ + ["_truck", objNull, [objNull]], + ["_magazineClass", "", [""]], + ["_partial", false, [false]] +]; if (isNull _truck || {_magazineClass isEqualTo ""} || diff --git a/addons/rearm/functions/fnc_addRearmActions.sqf b/addons/rearm/functions/fnc_addRearmActions.sqf index d6e37b86b6..a7bf5d0171 100644 --- a/addons/rearm/functions/fnc_addRearmActions.sqf +++ b/addons/rearm/functions/fnc_addRearmActions.sqf @@ -15,7 +15,9 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]] +]; private _vehicles = nearestObjects [_truck, ["AllVehicles"], 20]; if (count _vehicles < 2) exitWith {false}; // Rearming needs at least 2 vehicles @@ -63,8 +65,10 @@ private _vehicleActions = []; }; }; }; - } forEach _magazines; - } forEach REARM_TURRET_PATHS; + false + } count _magazines; + false + } count REARM_TURRET_PATHS; }; if (_needToAdd && !(_vehicle getVariable [QGVAR(disabled), false])) then { private _icon = getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "Icon"); @@ -91,6 +95,7 @@ private _vehicleActions = []; _vehicleActions pushBack [_action, _actions, _truck]; }; }; -} forEach _vehicles; + false +} count _vehicles; _vehicleActions diff --git a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf index 5f7288cf51..3f38dcdc97 100644 --- a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf +++ b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf @@ -20,7 +20,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_vehicle", objNull, [objNull, ""]]]; +params [ + ["_truck", objNull, [objNull]], + ["_vehicle", objNull, [objNull, ""]] +]; if (isNull _truck || {typeName _vehicle == "OBJECT" && {isNull _vehicle}}) exitWith {}; @@ -32,11 +35,13 @@ if (typeName _vehicle == "OBJECT") then { if (typeName _vehicle == "STRING") then { _string = _vehicle; }; -if (_string == "") exitWith {[]}; +if (_string == "") exitWith {}; { private _turretPath = _x; private _magazines = [_string, _turretPath] call FUNC(getConfigMagazines); { [_truck, _x] call FUNC(addMagazineToSupply); - } forEach _magazines; -} forEach REARM_TURRET_PATHS; + false + } count _magazines; + false +} count REARM_TURRET_PATHS; diff --git a/addons/rearm/functions/fnc_canReadSupplyCounter.sqf b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf index f3b4fdba12..5b09b14304 100644 --- a/addons/rearm/functions/fnc_canReadSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || diff --git a/addons/rearm/functions/fnc_canRearm.sqf b/addons/rearm/functions/fnc_canRearm.sqf index 8ea0c69c50..90872871b0 100644 --- a/addons/rearm/functions/fnc_canRearm.sqf +++ b/addons/rearm/functions/fnc_canRearm.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_vehicle", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_vehicle", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; if (GVAR(level) == 0 || {isNull _unit} || {!(_unit isKindOf "CAManBase")} || {!local _unit} || {_vehicle distance _unit > REARM_ACTION_DISTANCE} || {_vehicle getVariable [QGVAR(disabled), false]}) exitWith {false}; diff --git a/addons/rearm/functions/fnc_canRearmVehicle.sqf b/addons/rearm/functions/fnc_canRearmVehicle.sqf index 5d953e8e08..3ab09a83f7 100644 --- a/addons/rearm/functions/fnc_canRearmVehicle.sqf +++ b/addons/rearm/functions/fnc_canRearmVehicle.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_vehicle", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_vehicle", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || diff --git a/addons/rearm/functions/fnc_canStoreAmmo.sqf b/addons/rearm/functions/fnc_canStoreAmmo.sqf index 6e6061c5ee..23d1bb0bc2 100644 --- a/addons/rearm/functions/fnc_canStoreAmmo.sqf +++ b/addons/rearm/functions/fnc_canStoreAmmo.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || diff --git a/addons/rearm/functions/fnc_canTakeAmmo.sqf b/addons/rearm/functions/fnc_canTakeAmmo.sqf index 2ae5b26b65..be213014ca 100644 --- a/addons/rearm/functions/fnc_canTakeAmmo.sqf +++ b/addons/rearm/functions/fnc_canTakeAmmo.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; !(isNull _unit || {!(_unit isKindOf "CAManBase")} || diff --git a/addons/rearm/functions/fnc_createDummy.sqf b/addons/rearm/functions/fnc_createDummy.sqf index 86d0d04223..08326ca889 100644 --- a/addons/rearm/functions/fnc_createDummy.sqf +++ b/addons/rearm/functions/fnc_createDummy.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_unit", objNull, [objNull]], ["_magazineClass", "", [""]]]; +params [ + ["_unit", objNull, [objNull]], + ["_magazineClass", "", [""]] +]; private _ammo = getText (configFile >> "CfgMagazines" >> _magazineClass >> "ammo"); private _dummyName = getText (configFile >> "CfgAmmo" >> _ammo >> QGVAR(dummy)); diff --git a/addons/rearm/functions/fnc_disable.sqf b/addons/rearm/functions/fnc_disable.sqf index 47d073efca..2398039595 100644 --- a/addons/rearm/functions/fnc_disable.sqf +++ b/addons/rearm/functions/fnc_disable.sqf @@ -17,5 +17,9 @@ */ #include "script_component.hpp" -params [["_vehicle", objNull, [objNull]], ["_disable", true, [true]]]; +params [ + ["_vehicle", objNull, [objNull]], + ["_disable", true, [true]] +]; + _vehicle setVariable [QGVAR(disabled), _disable, true]; diff --git a/addons/rearm/functions/fnc_dropAmmo.sqf b/addons/rearm/functions/fnc_dropAmmo.sqf index 4d87370e3c..861b5db31d 100644 --- a/addons/rearm/functions/fnc_dropAmmo.sqf +++ b/addons/rearm/functions/fnc_dropAmmo.sqf @@ -17,7 +17,11 @@ */ #include "script_component.hpp" -params [["_unit", objNull, [objNull]], ["_delete", false, [false]], ["_unholster", true, [true]]]; +params [ + ["_unit", objNull, [objNull]], + ["_delete", false, [false]], + ["_unholster", true, [true]] +]; private _dummy = _unit getVariable [QGVAR(dummy), objNull]; if !(isNull _dummy) then { diff --git a/addons/rearm/functions/fnc_getCaliber.sqf b/addons/rearm/functions/fnc_getCaliber.sqf index 28113a31ad..fdff5a9480 100644 --- a/addons/rearm/functions/fnc_getCaliber.sqf +++ b/addons/rearm/functions/fnc_getCaliber.sqf @@ -17,7 +17,9 @@ */ #include "script_component.hpp" -params [["_magazineClass", "", [""]]]; +params [ + ["_magazineClass", "", [""]] +]; if (_magazineClass isEqualTo "") exitWith {[8, 2]}; diff --git a/addons/rearm/functions/fnc_getConfigMagazines.sqf b/addons/rearm/functions/fnc_getConfigMagazines.sqf index 89113e2815..82dcf7936c 100644 --- a/addons/rearm/functions/fnc_getConfigMagazines.sqf +++ b/addons/rearm/functions/fnc_getConfigMagazines.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_cfgString", "", [""]], ["_turretPath", [], [[]]]]; +params [ + ["_cfgString", "", [""]], + ["_turretPath", [], [[]]] +]; if (_cfgString == "") exitWith {[]}; diff --git a/addons/rearm/functions/fnc_getMaxMagazines.sqf b/addons/rearm/functions/fnc_getMaxMagazines.sqf index 1b1bd9ef9f..c747714d86 100644 --- a/addons/rearm/functions/fnc_getMaxMagazines.sqf +++ b/addons/rearm/functions/fnc_getMaxMagazines.sqf @@ -17,7 +17,11 @@ */ #include "script_component.hpp" -params [["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]], ["_magazineClass", "", [""]]]; +params [ + ["_vehicle", objNull, [objNull]], + ["_turretPath", [], [[]]], + ["_magazineClass", "", [""]] +]; if (isNull _vehicle) exitWith {0}; diff --git a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf index 3bf6882e1f..2000b83818 100644 --- a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf +++ b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf @@ -13,13 +13,16 @@ * 2: Number of current magazines in turret path * * Example: - * [tank, "mag"] call ace_rearm_fnc_getNeedRearmMagazines + * [tank, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_getNeedRearmMagazines * * Public: No */ #include "script_component.hpp" -params ["_vehicle", "_magazineClass"]; +params [ + ["_vehicle", objNull, [objNull]], + ["_magazineClass", "", [""]] +]; private _return = [false, [], 0]; { @@ -38,6 +41,7 @@ private _return = [false, [], 0]; }; if (_return select 0) exitWith {}; -} forEach REARM_TURRET_PATHS; + false +} count REARM_TURRET_PATHS; _return diff --git a/addons/rearm/functions/fnc_getSupplyCount.sqf b/addons/rearm/functions/fnc_getSupplyCount.sqf index c3a8b1df3b..f53f447657 100644 --- a/addons/rearm/functions/fnc_getSupplyCount.sqf +++ b/addons/rearm/functions/fnc_getSupplyCount.sqf @@ -15,7 +15,9 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]] +]; private _supply = _truck getVariable QGVAR(currentSupply); diff --git a/addons/rearm/functions/fnc_getVehicleMagazines.sqf b/addons/rearm/functions/fnc_getVehicleMagazines.sqf index 94664e534d..26da24df0c 100644 --- a/addons/rearm/functions/fnc_getVehicleMagazines.sqf +++ b/addons/rearm/functions/fnc_getVehicleMagazines.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; +params [ + ["_vehicle", objNull, [objNull]], + ["_turretPath", [], [[]]] +]; if (isNull _vehicle) exitWith {[]}; diff --git a/addons/rearm/functions/fnc_grabAmmo.sqf b/addons/rearm/functions/fnc_grabAmmo.sqf index 161627da28..dabf62d535 100644 --- a/addons/rearm/functions/fnc_grabAmmo.sqf +++ b/addons/rearm/functions/fnc_grabAmmo.sqf @@ -16,10 +16,12 @@ */ #include "script_component.hpp" -params [["_dummy", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_dummy", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; REARM_HOLSTER_WEAPON -[_unit, "forceWalk", QGVAR(vehRearm), true] call EFUNC(common,statusEffect_set); [ 5, @@ -29,7 +31,7 @@ REARM_HOLSTER_WEAPON params ["_args"]; _args params ["_dummy", "_unit"]; [_dummy, _unit] call FUNC(pickUpAmmo); - + [_unit, "forceWalk", QGVAR(vehRearm), true] call EFUNC(common,statusEffect_set); _actionID = _unit getVariable [QGVAR(ReleaseActionID), -1]; if (_actionID != -1) then { _unit removeAction _actionID; diff --git a/addons/rearm/functions/fnc_handleKilled.sqf b/addons/rearm/functions/fnc_handleKilled.sqf index 5f80246f52..3e39dc727e 100644 --- a/addons/rearm/functions/fnc_handleKilled.sqf +++ b/addons/rearm/functions/fnc_handleKilled.sqf @@ -15,7 +15,9 @@ */ #include "script_component.hpp" -params [["_unit", objNull, [objNull]]]; +params [ + ["_unit", objNull, [objNull]] +]; if (!local _unit) exitWith {}; diff --git a/addons/rearm/functions/fnc_handleUnconscious.sqf b/addons/rearm/functions/fnc_handleUnconscious.sqf index eab25fcf64..0fbf1b8f06 100644 --- a/addons/rearm/functions/fnc_handleUnconscious.sqf +++ b/addons/rearm/functions/fnc_handleUnconscious.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_unit", objNull, [objNull]], ["_isUnconscious", false, [false]]]; +params [ + ["_unit", objNull, [objNull]], + ["_isUnconscious", false, [false]] +]; if (!local _unit || {!_isUnconscious}) exitWith {}; diff --git a/addons/rearm/functions/fnc_hasEnoughSupply.sqf b/addons/rearm/functions/fnc_hasEnoughSupply.sqf index ef7c906c54..db2814ca9e 100644 --- a/addons/rearm/functions/fnc_hasEnoughSupply.sqf +++ b/addons/rearm/functions/fnc_hasEnoughSupply.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]]]; +params [ + ["_truck", objNull, [objNull]], + ["_magazineClass", "", [""]] +]; if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; diff --git a/addons/rearm/functions/fnc_magazineInSupply.sqf b/addons/rearm/functions/fnc_magazineInSupply.sqf index ddb925d929..2cd6f3da67 100644 --- a/addons/rearm/functions/fnc_magazineInSupply.sqf +++ b/addons/rearm/functions/fnc_magazineInSupply.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]]]; +params [ + ["_truck", objNull, [objNull]], + ["_magazineClass", "", [""]] +]; if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; diff --git a/addons/rearm/functions/fnc_makeDummy.sqf b/addons/rearm/functions/fnc_makeDummy.sqf index 390ff658e0..368d2616c4 100644 --- a/addons/rearm/functions/fnc_makeDummy.sqf +++ b/addons/rearm/functions/fnc_makeDummy.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_obj", objNull, [objNull]], ["_dirAndUp", [[1,0,0],[0,0,1]], [[]]]]; +params [ + ["_obj", objNull, [objNull]], + ["_dirAndUp", [[1,0,0],[0,0,1]], [[]]] +]; _obj setVectorDirAndUp _dirAndUp; _obj allowDamage false; diff --git a/addons/rearm/functions/fnc_moduleRearmSettings.sqf b/addons/rearm/functions/fnc_moduleRearmSettings.sqf index ae4a56563c..8397eb5401 100644 --- a/addons/rearm/functions/fnc_moduleRearmSettings.sqf +++ b/addons/rearm/functions/fnc_moduleRearmSettings.sqf @@ -17,7 +17,11 @@ */ #include "script_component.hpp" -params ["_logic", "", ["_activated", false, [false]]]; +params [ + "_logic", + "", + ["_activated", false, [false]] +]; if (!_activated) exitWith {}; diff --git a/addons/rearm/functions/fnc_pickUpAmmo.sqf b/addons/rearm/functions/fnc_pickUpAmmo.sqf index 3b3bbb9034..e4ff4370ba 100644 --- a/addons/rearm/functions/fnc_pickUpAmmo.sqf +++ b/addons/rearm/functions/fnc_pickUpAmmo.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_dummy", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_dummy", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; if !(isNull _attachedDummy) exitWith {}; diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf index 48a0a73352..872a889814 100644 --- a/addons/rearm/functions/fnc_readSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; if (GVAR(supply) == 0) exitWith {}; @@ -57,7 +60,8 @@ if (GVAR(supply) == 1) then { _numChars = _numChars max (count _line); _text = format ["%1
%2", _text, _line]; _supply = _supply + 0.5; - } forEach _magazines; + false + } count _magazines; }; if (_supply > 1.5) then { ["displayTextStructured", [_unit], [[LSTRING(Hint_RemainingAmmo), _text], _supply, _unit, (_numChars/2.9)]] call EFUNC(common,targetEvent); diff --git a/addons/rearm/functions/fnc_rearm.sqf b/addons/rearm/functions/fnc_rearm.sqf index 20848b3c8b..65b80b6900 100644 --- a/addons/rearm/functions/fnc_rearm.sqf +++ b/addons/rearm/functions/fnc_rearm.sqf @@ -15,7 +15,9 @@ */ #include "script_component.hpp" -params [["_unit", objNull, [objNull]]]; +params [ + ["_unit", objNull, [objNull]] +]; private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; if (isNull _attachedDummy) exitwith {false}; diff --git a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf index 5453910530..4da9475511 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf @@ -17,7 +17,11 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], "", ["_vehicle", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]], + "", + ["_vehicle", objNull, [objNull]] +]; [ 10, diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf index 87145eccea..c0f0021cd7 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf @@ -18,7 +18,10 @@ #include "script_component.hpp" params ["_args"]; -_args params [["_truck", objNull, [objNull]], ["_vehicle", objNull, [objNull]]]; +_args params [ + ["_truck", objNull, [objNull]], + ["_vehicle", objNull, [objNull]] +]; if (isServer) then { { @@ -28,6 +31,7 @@ if (isServer) then { } else { [QGVAR(rearmEntireVehicleSuccessLocalEH), _turretOwnerID, [_truck, _vehicle, _x]] call EFUNC(common,targetEvent); }; + false } count REARM_TURRET_PATHS; } else { [QGVAR(rearmEntireVehicleSuccessLocalEH), _this] call EFUNC(common,serverEvent); diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf index fdd8ab9b78..2e8327d7d4 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf @@ -17,7 +17,11 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; +params [ + ["_truck", objNull, [objNull]], + ["_vehicle", objNull, [objNull]], + ["_turretPath", [], [[]]] +]; private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); if (isNil "_magazines") exitWith {}; @@ -58,4 +62,5 @@ if (isNil "_magazines") exitWith {}; _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; }; }; -} foreach _magazines; + false +} count _magazines; diff --git a/addons/rearm/functions/fnc_rearmSuccess.sqf b/addons/rearm/functions/fnc_rearmSuccess.sqf index 003689c00b..c5e47a5887 100644 --- a/addons/rearm/functions/fnc_rearmSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmSuccess.sqf @@ -21,7 +21,9 @@ */ #include "script_component.hpp" -params [["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]]]; +params [ + ["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]] +]; _args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; //hint format ["Vehicle: %1\nTurretPath: %2\nNumMagazines: %3\nMagazine: %4\nNumRounds: %5", _vehicle, _turretPath, _numMagazines, _magazineClass, _numRounds]; diff --git a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf index c840f43436..2b1809cfb5 100644 --- a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf @@ -21,7 +21,9 @@ */ #include "script_component.hpp" -params [["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]]]; +params [ + ["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]] +]; _args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; private _rounds = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); diff --git a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf index 4d7c18cd16..ed19bfb53f 100644 --- a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf +++ b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf @@ -17,7 +17,11 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]], ["_numRounds", -1, [0]]]; +params [ + ["_truck", objNull, [objNull]], + ["_magazineClass", "", [""]], + ["_numRounds", -1, [0]] +]; if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; diff --git a/addons/rearm/functions/fnc_setSupplyCount.sqf b/addons/rearm/functions/fnc_setSupplyCount.sqf index 8900480207..b4deea7a74 100644 --- a/addons/rearm/functions/fnc_setSupplyCount.sqf +++ b/addons/rearm/functions/fnc_setSupplyCount.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_supply", 0, [0]]]; +params [ + ["_truck", objNull, [objNull]], + ["_supply", 0, [0]] +]; if (isNull _truck) exitWith {}; diff --git a/addons/rearm/functions/fnc_storeAmmo.sqf b/addons/rearm/functions/fnc_storeAmmo.sqf index 4f4c2f956f..b59a75aaa9 100644 --- a/addons/rearm/functions/fnc_storeAmmo.sqf +++ b/addons/rearm/functions/fnc_storeAmmo.sqf @@ -16,7 +16,10 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]]]; +params [ + ["_truck", objNull, [objNull]], + ["_unit", objNull, [objNull]] +]; private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; if (isNull _attachedDummy) exitwith {}; diff --git a/addons/rearm/functions/fnc_takeAmmo.sqf b/addons/rearm/functions/fnc_takeAmmo.sqf index 07a7854ebf..9b0cfd3100 100644 --- a/addons/rearm/functions/fnc_takeAmmo.sqf +++ b/addons/rearm/functions/fnc_takeAmmo.sqf @@ -19,7 +19,11 @@ */ #include "script_component.hpp" -params [["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_args", ["", objNull], [[]]]]; +params [ + ["_truck", objNull, [objNull]], + ["_unit", objNull, [objNull]], + ["_args", ["", objNull], [[]]] +]; _args params ["_magazineClass", "_vehicle"]; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; diff --git a/addons/rearm/functions/fnc_takeSuccess.sqf b/addons/rearm/functions/fnc_takeSuccess.sqf index 34006117c8..831c2722bd 100644 --- a/addons/rearm/functions/fnc_takeSuccess.sqf +++ b/addons/rearm/functions/fnc_takeSuccess.sqf @@ -18,7 +18,9 @@ */ #include "script_component.hpp" -params [["_args", [objNull, "", objNull], [[]], 3]]; +params [ + ["_args", [objNull, "", objNull], [[]], 3] +]; _args params ["_unit", "_magazineClass", "_truck"]; private _success = true; From a2b9678b15056af2148e97f7e3b3e98023e8777c Mon Sep 17 00:00:00 2001 From: Githawk Date: Mon, 6 Jun 2016 19:50:54 +0200 Subject: [PATCH 12/36] Object event --- addons/rearm/functions/fnc_readSupplyCounter.sqf | 8 ++++---- addons/rearm/functions/fnc_rearmSuccessLocal.sqf | 16 ++++++++-------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf index 872a889814..8de95776cb 100644 --- a/addons/rearm/functions/fnc_readSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -31,9 +31,9 @@ if (GVAR(supply) == 1) then { params ["_args"]; _args params [["_unit", objNull, [objNull]], ["_truck", objNull, [objNull]], ["_supplyCount", 0, [0]]]; if (_supplyCount > 0 ) then { - ["displayTextStructured", [_unit], [[LSTRING(Hint_RemainingSupplyPoints), _supplyCount], 2, _unit]] call EFUNC(common,targetEvent); + ["displayTextStructured", _unit, [[LSTRING(Hint_RemainingSupplyPoints), _supplyCount], 2, _unit]] call EFUNC(common,objectEvent); } else { - ["displayTextStructured", [_unit], [LSTRING(Hint_EmptySupplyPoints), 2, _unit]] call EFUNC(common,targetEvent); + ["displayTextStructured", _unit, [LSTRING(Hint_EmptySupplyPoints), 2, _unit]] call EFUNC(common,objectEvent); }; true }, @@ -64,9 +64,9 @@ if (GVAR(supply) == 1) then { } count _magazines; }; if (_supply > 1.5) then { - ["displayTextStructured", [_unit], [[LSTRING(Hint_RemainingAmmo), _text], _supply, _unit, (_numChars/2.9)]] call EFUNC(common,targetEvent); + ["displayTextStructured", _unit, [[LSTRING(Hint_RemainingAmmo), _text], _supply, _unit, (_numChars/2.9)]] call EFUNC(common,objectEvent); } else { - ["displayTextStructured", [_unit], [LSTRING(Hint_Empty), 2, _unit]] call EFUNC(common,targetEvent); + ["displayTextStructured", _unit, [LSTRING(Hint_Empty), 2, _unit]] call EFUNC(common,objectEvent); }; true }, diff --git a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf index 2b1809cfb5..f04ab4b501 100644 --- a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf @@ -40,15 +40,15 @@ if (_maxMagazines == 1) then { if (GVAR(level) == 1) then { // Fill magazine completely _vehicle setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; - ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _rounds, + ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _rounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); } else { // Fill only at most _numRounds _vehicle setMagazineTurretAmmo [_magazineClass, ((_vehicle magazineTurretAmmo [_magazineClass, _turretPath]) + _numRounds) min _rounds, _turretPath]; - ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _numRounds, + ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _numRounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); }; } else { for "_idx" from 1 to (_maxMagazines+1) do { @@ -69,9 +69,9 @@ if (_maxMagazines == 1) then { } else { _vehicle setMagazineTurretAmmo [_magazineClass, _currentRounds + _numRounds, _turretPath]; }; - ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _numRounds, + ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _numRounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); } else { // Fill current magazine completely and fill next magazine partially _vehicle setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; @@ -79,9 +79,9 @@ if (_maxMagazines == 1) then { _vehicle addMagazineTurret [_magazineClass, _turretPath]; _vehicle setMagazineTurretAmmo [_magazineClass, _currentRounds, _turretPath]; }; - ["displayTextStructured", [_unit], [[LSTRING(Hint_RearmedTriple), _rounds, + ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _rounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,targetEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); }; }; _vehicle removeMagazineTurret [_magazineClass, _turretPath]; From 9cfa2f11d96e7d6e8c7e0f9f58f28015d41a231c Mon Sep 17 00:00:00 2001 From: Githawk Date: Mon, 6 Jun 2016 20:42:20 +0200 Subject: [PATCH 13/36] Stuff Arguments, Return Value, (optional) --- .../functions/fnc_displayProtractor.sqf | 4 ++-- .../functions/fnc_getChildrenAttachActions.sqf | 4 ++-- addons/captives/functions/fnc_canStopEscorting.sqf | 1 - addons/cargo/functions/fnc_canLoad.sqf | 2 +- addons/cargo/functions/fnc_canLoadItemIn.sqf | 2 +- addons/cargo/functions/fnc_canUnloadItem.sqf | 4 ++-- addons/cargo/functions/fnc_findNearestVehicle.sqf | 2 +- addons/cargo/functions/fnc_getCargoSpaceLeft.sqf | 2 +- addons/cargo/functions/fnc_getSizeItem.sqf | 2 +- addons/cargo/functions/fnc_handleDestroyed.sqf | 2 +- addons/cargo/functions/fnc_initObject.sqf | 2 +- addons/cargo/functions/fnc_loadItem.sqf | 2 +- addons/cargo/functions/fnc_makeLoadable.sqf | 2 +- addons/cargo/functions/fnc_onMenuOpen.sqf | 2 +- addons/cargo/functions/fnc_startLoadIn.sqf | 2 +- addons/cargo/functions/fnc_startUnload.sqf | 2 +- addons/cargo/functions/fnc_unloadItem.sqf | 2 +- addons/cargo/functions/fnc_validateCargoSpace.sqf | 2 +- addons/common/functions/fnc_codeToString.sqf | 2 +- .../common/functions/fnc_displayTextStructured.sqf | 2 +- addons/common/functions/fnc_dropBackpack.sqf | 2 +- addons/common/functions/fnc_dumpArray.sqf | 2 +- addons/common/functions/fnc_findUnloadPosition.sqf | 6 +++--- addons/common/functions/fnc_firedEH.sqf | 4 ++-- addons/common/functions/fnc_fixPosition.sqf | 2 +- addons/common/functions/fnc_getMGRSdata.sqf | 2 +- addons/common/functions/fnc_isInBuilding.sqf | 2 +- addons/common/functions/fnc_monitor.sqf | 2 +- .../common/functions/fnc_removeAllEventHandlers.sqf | 2 +- addons/common/functions/fnc_removeEventHandler.sqf | 2 +- addons/common/functions/fnc_runAfterSettingsInit.sqf | 4 ++-- addons/common/functions/fnc_serverEvent.sqf | 2 +- .../functions/fnc_setApproximateVariablePublic.sqf | 4 ++-- addons/common/functions/fnc_setVariablePublic.sqf | 4 ++-- addons/common/functions/fnc_showHud.sqf | 4 ++-- addons/common/functions/fnc_showUser.sqf | 2 +- addons/common/functions/fnc_unloadPersonLocal.sqf | 2 +- addons/common/functions/fnc_waitUntilAndExecute.sqf | 4 ++-- addons/disarming/functions/fnc_disarmDropItems.sqf | 2 +- addons/dragging/functions/fnc_initObject.sqf | 2 +- addons/dragging/functions/fnc_initPerson.sqf | 4 ++-- addons/dragging/functions/fnc_isObjectOnObject.sqf | 4 ++-- addons/dragging/functions/fnc_setCarryable.sqf | 2 +- addons/dragging/functions/fnc_setDraggable.sqf | 4 ++-- addons/dragging/functions/fnc_startDrag.sqf | 4 ++-- addons/explosives/functions/fnc_placeExplosive.sqf | 2 +- .../explosives/functions/fnc_scriptedExplosive.sqf | 2 +- addons/fcs/functions/fnc_calculateSolution.sqf | 2 +- addons/fcs/functions/fnc_canResetFCS.sqf | 2 +- addons/fcs/functions/fnc_getRange.sqf | 4 ++-- addons/fcs/functions/fnc_updateRangeHUD.sqf | 4 ++-- addons/gforces/functions/fnc_addPFEH.sqf | 4 ++-- addons/gforces/functions/fnc_pfhUpdateGForces.sqf | 4 ++-- addons/hearing/functions/fnc_updateVolume.sqf | 2 +- .../interact_menu/functions/fnc_addActionToClass.sqf | 4 ++-- .../functions/fnc_addActionToObject.sqf | 4 ++-- addons/interact_menu/functions/fnc_addMainAction.sqf | 4 ++-- .../functions/fnc_collectActiveActionTree.sqf | 4 ++-- addons/interact_menu/functions/fnc_compileMenu.sqf | 4 ++-- .../functions/fnc_compileMenuSelfAction.sqf | 4 ++-- .../interact_menu/functions/fnc_compileMenuZeus.sqf | 4 ++-- addons/interact_menu/functions/fnc_createAction.sqf | 4 ++-- .../functions/fnc_ctrlSetParsedTextCached.sqf | 4 ++-- .../interact_menu/functions/fnc_findActionNode.sqf | 4 ++-- .../functions/fnc_handlePlayerChanged.sqf | 4 ++-- addons/interact_menu/functions/fnc_isSubPath.sqf | 4 ++-- addons/interact_menu/functions/fnc_keyDown.sqf | 4 ++-- addons/interact_menu/functions/fnc_keyUp.sqf | 4 ++-- .../functions/fnc_removeActionFromClass.sqf | 4 ++-- .../functions/fnc_removeActionFromObject.sqf | 4 ++-- addons/interact_menu/functions/fnc_render.sqf | 4 ++-- .../functions/fnc_renderActionPoints.sqf | 4 ++-- .../interact_menu/functions/fnc_renderBaseMenu.sqf | 4 ++-- addons/interact_menu/functions/fnc_renderIcon.sqf | 4 ++-- addons/interact_menu/functions/fnc_renderMenu.sqf | 4 ++-- .../interact_menu/functions/fnc_renderSelector.sqf | 4 ++-- .../interact_menu/functions/fnc_setupTextColors.sqf | 4 ++-- addons/interact_menu/functions/fnc_splitPath.sqf | 4 ++-- addons/interaction/functions/fnc_canJoinTeam.sqf | 2 +- addons/interaction/functions/fnc_getWeaponPos.sqf | 2 +- addons/interaction/functions/fnc_hideMouseHint.sqf | 2 +- addons/interaction/functions/fnc_showMouseHint.sqf | 2 +- addons/interaction/functions/fnc_switchLamp.sqf | 2 +- addons/laser/functions/fnc_laserOff.sqf | 2 +- addons/laser/functions/fnc_laserOn.sqf | 2 +- addons/laser/functions/fnc_seekerFindLaserSpot.sqf | 2 +- .../laser/functions/fnc_unitTurretCanLockLaser.sqf | 4 ++-- .../functions/fnc_vanillaLaserSeekerHandler.sqf | 4 ++-- .../functions/fnc_findLaserSource.sqf | 2 +- .../functions/fnc_laserHudDesignateOff.sqf | 2 +- .../functions/fnc_getMagazineChildren.sqf | 4 ++-- addons/map/functions/fnc_compileFlashlightMenu.sqf | 2 +- addons/map/functions/fnc_flashlightGlow.sqf | 2 +- addons/map/functions/fnc_getUnitFlashlights.sqf | 2 +- addons/map/functions/fnc_switchFlashlight.sqf | 2 +- addons/maptools/functions/fnc_addLineMarker.sqf | 2 +- addons/maptools/functions/fnc_calculateMapScale.sqf | 2 +- addons/maptools/functions/fnc_canDraw.sqf | 2 +- addons/maptools/functions/fnc_canUseMapGPS.sqf | 2 +- addons/maptools/functions/fnc_canUseMapTools.sqf | 2 +- addons/maptools/functions/fnc_cancelDrawing.sqf | 2 +- .../maptools/functions/fnc_copyMapReceiveMarkers.sqf | 2 +- addons/maptools/functions/fnc_copyMapRemoteSend.sqf | 4 ++-- addons/maptools/functions/fnc_copyMapStart.sqf | 2 +- addons/maptools/functions/fnc_handleKeyDown.sqf | 2 +- addons/maptools/functions/fnc_handleMouseButton.sqf | 4 ++-- addons/maptools/functions/fnc_handleMouseMove.sqf | 4 ++-- .../maptools/functions/fnc_handleMouseZChanged.sqf | 4 ++-- addons/maptools/functions/fnc_isInsideMapTool.sqf | 2 +- addons/maptools/functions/fnc_openMapGps.sqf | 2 +- addons/maptools/functions/fnc_removeLineMarker.sqf | 2 +- addons/maptools/functions/fnc_updateLineMarker.sqf | 2 +- .../maptools/functions/fnc_updateMapToolMarkers.sqf | 2 +- .../functions/fnc_addUnloadPatientActions.sqf | 4 ++-- addons/microdagr/functions/fnc_openDisplay.sqf | 2 +- addons/missileguidance/functions/fnc_checkLos.sqf | 4 ++-- .../functions/fnc_checkSeekerAngle.sqf | 4 ++-- addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf | 2 +- addons/nametags/functions/fnc_drawNameTagIcon.sqf | 2 +- .../overheating/functions/fnc_calculateCooling.sqf | 4 ++-- addons/overheating/functions/fnc_firedEH.sqf | 4 ++-- addons/overheating/functions/fnc_getWeaponData.sqf | 4 ++-- addons/overheating/functions/fnc_handleTakeEH.sqf | 4 ++-- addons/overheating/functions/fnc_jamWeapon.sqf | 4 ++-- .../functions/fnc_loadCoolestSpareBarrel.sqf | 4 ++-- addons/overheating/functions/fnc_overheat.sqf | 4 ++-- .../fnc_sendSpareBarrelsTemperaturesHint.sqf | 4 ++-- addons/overheating/functions/fnc_swapBarrel.sqf | 4 ++-- .../functions/fnc_swapBarrelAssistant.sqf | 4 ++-- .../overheating/functions/fnc_swapBarrelCallback.sqf | 4 ++-- .../fnc_updateSpareBarrelsTemperaturesThread.sqf | 4 ++-- .../overheating/functions/fnc_updateTemperature.sqf | 4 ++-- .../functions/fnc_updateTemperatureThread.sqf | 4 ++-- .../functions/fnc_cacheOverPressureValues.sqf | 4 ++-- addons/overpressure/functions/fnc_firedEHBB.sqf | 2 +- addons/overpressure/functions/fnc_firedEHOP.sqf | 2 +- addons/overpressure/functions/fnc_getDistance.sqf | 2 +- .../functions/fnc_overpressureDamage.sqf | 4 ++-- addons/rearm/functions/fnc_addMagazineToSupply.sqf | 6 +++--- addons/rearm/functions/fnc_addRearmActions.sqf | 4 ++-- .../functions/fnc_addVehicleMagazinesToSupply.sqf | 4 ++-- addons/rearm/functions/fnc_disable.sqf | 2 +- addons/rearm/functions/fnc_dropAmmo.sqf | 4 ++-- addons/rearm/functions/fnc_getCaliber.sqf | 4 ++-- addons/rearm/functions/fnc_getSupplyCount.sqf | 4 ++-- addons/rearm/functions/fnc_hasEnoughSupply.sqf | 4 ++-- addons/rearm/functions/fnc_magazineInSupply.sqf | 6 +++--- .../rearm/functions/fnc_removeMagazineFromSupply.sqf | 6 +++--- addons/rearm/functions/fnc_setSupplyCount.sqf | 4 ++-- addons/reload/functions/fnc_canCheckAmmo.sqf | 4 ++-- addons/reload/functions/fnc_canLinkBelt.sqf | 4 ++-- addons/reload/functions/fnc_checkAmmo.sqf | 4 ++-- addons/reload/functions/fnc_displayAmmo.sqf | 4 ++-- addons/reload/functions/fnc_startLinkingBelt.sqf | 4 ++-- .../functions/fnc_addMissileReloadActions.sqf | 4 ++-- addons/reloadlaunchers/functions/fnc_canLoad.sqf | 4 ++-- .../functions/fnc_getLoadableMissiles.sqf | 4 ++-- addons/reloadlaunchers/functions/fnc_load.sqf | 4 ++-- .../reloadlaunchers/functions/fnc_reloadLauncher.sqf | 4 ++-- addons/scopes/functions/fnc_adjustScope.sqf | 4 ++-- addons/scopes/functions/fnc_adjustZero.sqf | 4 ++-- addons/scopes/functions/fnc_applyScopeAdjustment.sqf | 4 ++-- addons/scopes/functions/fnc_canAdjustZero.sqf | 4 ++-- addons/scopes/functions/fnc_firedEH.sqf | 4 ++-- addons/spectator/functions/fnc_toggleInterface.sqf | 12 ++++++------ addons/spottingscope/functions/fnc_pickup.sqf | 2 +- addons/spottingscope/functions/fnc_place.sqf | 2 +- addons/tripod/functions/fnc_adjust.sqf | 2 +- addons/tripod/functions/fnc_pickup.sqf | 2 +- addons/tripod/functions/fnc_place.sqf | 2 +- addons/weather/functions/fnc_displayWindInfo.sqf | 4 ++-- addons/weather/functions/fnc_getMapData.sqf | 4 ++-- addons/weather/functions/fnc_getWind.sqf | 4 ++-- addons/weather/functions/fnc_initWind.sqf | 4 ++-- addons/weather/functions/fnc_serverController.sqf | 4 ++-- addons/weather/functions/fnc_updateAceWeather.sqf | 4 ++-- addons/weather/functions/fnc_updateHumidity.sqf | 4 ++-- addons/weather/functions/fnc_updateRain.sqf | 4 ++-- addons/weather/functions/fnc_updateTemperature.sqf | 4 ++-- addons/weather/functions/fnc_updateWind.sqf | 4 ++-- 180 files changed, 291 insertions(+), 292 deletions(-) diff --git a/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf b/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf index 62663c843b..528b3e2e97 100644 --- a/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf +++ b/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf @@ -3,10 +3,10 @@ * * Displays a protractor in the top left corner of the screen * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/attach/functions/fnc_getChildrenAttachActions.sqf b/addons/attach/functions/fnc_getChildrenAttachActions.sqf index 9f811197e0..0b2e4e705c 100644 --- a/addons/attach/functions/fnc_getChildrenAttachActions.sqf +++ b/addons/attach/functions/fnc_getChildrenAttachActions.sqf @@ -3,11 +3,11 @@ * Show the ammo counts for a static weapon. * Called from "insertChildren" on interact_menu * - * Argument: + * Arguments: * 0: Target * 1: Player * - * Return value: + * Return Value: * ChildActiosn * * Example: diff --git a/addons/captives/functions/fnc_canStopEscorting.sqf b/addons/captives/functions/fnc_canStopEscorting.sqf index cfafb5a0e8..28b018491b 100644 --- a/addons/captives/functions/fnc_canStopEscorting.sqf +++ b/addons/captives/functions/fnc_canStopEscorting.sqf @@ -4,7 +4,6 @@ * * Arguments: * 0: caller (player) - * 1: target * * Return Value: * The return value diff --git a/addons/cargo/functions/fnc_canLoad.sqf b/addons/cargo/functions/fnc_canLoad.sqf index bf1098dbf1..f576ea3e79 100644 --- a/addons/cargo/functions/fnc_canLoad.sqf +++ b/addons/cargo/functions/fnc_canLoad.sqf @@ -6,7 +6,7 @@ * 0: Player * 1: Object to load * - * Return value: + * Return Value: * Can load * * Example: diff --git a/addons/cargo/functions/fnc_canLoadItemIn.sqf b/addons/cargo/functions/fnc_canLoadItemIn.sqf index d6092c2a2d..e2bb1ecc4d 100644 --- a/addons/cargo/functions/fnc_canLoadItemIn.sqf +++ b/addons/cargo/functions/fnc_canLoadItemIn.sqf @@ -6,7 +6,7 @@ * 0: Item * 1: Holder Object (Vehicle) * - * Return value: + * Return Value: * Can load in * * Example: diff --git a/addons/cargo/functions/fnc_canUnloadItem.sqf b/addons/cargo/functions/fnc_canUnloadItem.sqf index ea6cb7a6eb..be14f71a76 100644 --- a/addons/cargo/functions/fnc_canUnloadItem.sqf +++ b/addons/cargo/functions/fnc_canUnloadItem.sqf @@ -5,9 +5,9 @@ * Arguments: * 0: loaded Object * 1: Object - * 2: Unloader (player) + * 2: Unloader (player) (optional) * - * Return value: + * Return Value: * Can be unloaded * * Example: diff --git a/addons/cargo/functions/fnc_findNearestVehicle.sqf b/addons/cargo/functions/fnc_findNearestVehicle.sqf index b5b441df92..6d5b7ce1a8 100644 --- a/addons/cargo/functions/fnc_findNearestVehicle.sqf +++ b/addons/cargo/functions/fnc_findNearestVehicle.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Unit * - * Return value: + * Return Value: * Vehicle in Distance * * Example: diff --git a/addons/cargo/functions/fnc_getCargoSpaceLeft.sqf b/addons/cargo/functions/fnc_getCargoSpaceLeft.sqf index 7d94570749..7e8594ffe4 100644 --- a/addons/cargo/functions/fnc_getCargoSpaceLeft.sqf +++ b/addons/cargo/functions/fnc_getCargoSpaceLeft.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Object * - * Return value: + * Return Value: * Cargo space left * * Example: diff --git a/addons/cargo/functions/fnc_getSizeItem.sqf b/addons/cargo/functions/fnc_getSizeItem.sqf index 775bdefd10..c53c05ee28 100644 --- a/addons/cargo/functions/fnc_getSizeItem.sqf +++ b/addons/cargo/functions/fnc_getSizeItem.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Item * - * Return value: + * Return Value: * Cargo size (default: -1) * * Example: diff --git a/addons/cargo/functions/fnc_handleDestroyed.sqf b/addons/cargo/functions/fnc_handleDestroyed.sqf index d50ea488d6..88b3cb9351 100644 --- a/addons/cargo/functions/fnc_handleDestroyed.sqf +++ b/addons/cargo/functions/fnc_handleDestroyed.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Object * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/cargo/functions/fnc_initObject.sqf b/addons/cargo/functions/fnc_initObject.sqf index f740d0e371..92403b8dd9 100644 --- a/addons/cargo/functions/fnc_initObject.sqf +++ b/addons/cargo/functions/fnc_initObject.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Object * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/cargo/functions/fnc_loadItem.sqf b/addons/cargo/functions/fnc_loadItem.sqf index 443143ece0..8672604e35 100644 --- a/addons/cargo/functions/fnc_loadItem.sqf +++ b/addons/cargo/functions/fnc_loadItem.sqf @@ -7,7 +7,7 @@ * 0: Item * 1: Vehicle * - * Return value: + * Return Value: * Object loaded * * Example: diff --git a/addons/cargo/functions/fnc_makeLoadable.sqf b/addons/cargo/functions/fnc_makeLoadable.sqf index ceb1dc1acd..27513a1864 100644 --- a/addons/cargo/functions/fnc_makeLoadable.sqf +++ b/addons/cargo/functions/fnc_makeLoadable.sqf @@ -7,7 +7,7 @@ * 1: Set as loadable (default: true) * 2: Size. (default: 1) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/cargo/functions/fnc_onMenuOpen.sqf b/addons/cargo/functions/fnc_onMenuOpen.sqf index a045862e36..a9f558ac76 100644 --- a/addons/cargo/functions/fnc_onMenuOpen.sqf +++ b/addons/cargo/functions/fnc_onMenuOpen.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Display * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/cargo/functions/fnc_startLoadIn.sqf b/addons/cargo/functions/fnc_startLoadIn.sqf index 6fcd3cf62c..0d42de829a 100644 --- a/addons/cargo/functions/fnc_startLoadIn.sqf +++ b/addons/cargo/functions/fnc_startLoadIn.sqf @@ -6,7 +6,7 @@ * 0: Player * 1: Object * - * Return value: + * Return Value: * Load ProgressBar Started * * Example: diff --git a/addons/cargo/functions/fnc_startUnload.sqf b/addons/cargo/functions/fnc_startUnload.sqf index 46a69e737f..33c8118cdf 100644 --- a/addons/cargo/functions/fnc_startUnload.sqf +++ b/addons/cargo/functions/fnc_startUnload.sqf @@ -5,7 +5,7 @@ * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/cargo/functions/fnc_unloadItem.sqf b/addons/cargo/functions/fnc_unloadItem.sqf index 8bd18f989e..a2d9fb8845 100644 --- a/addons/cargo/functions/fnc_unloadItem.sqf +++ b/addons/cargo/functions/fnc_unloadItem.sqf @@ -6,7 +6,7 @@ * 0: Item * 1: Vehicle * - * Return value: + * Return Value: * Object unloaded * * Example: diff --git a/addons/cargo/functions/fnc_validateCargoSpace.sqf b/addons/cargo/functions/fnc_validateCargoSpace.sqf index ecb011aed3..6e3d79cf8d 100644 --- a/addons/cargo/functions/fnc_validateCargoSpace.sqf +++ b/addons/cargo/functions/fnc_validateCargoSpace.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Object * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/common/functions/fnc_codeToString.sqf b/addons/common/functions/fnc_codeToString.sqf index b4fe37db35..62e4cb5698 100644 --- a/addons/common/functions/fnc_codeToString.sqf +++ b/addons/common/functions/fnc_codeToString.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Code * - * Return value: + * Return Value: * Code * * Public: Yes diff --git a/addons/common/functions/fnc_displayTextStructured.sqf b/addons/common/functions/fnc_displayTextStructured.sqf index 59ca469cf1..5d42f00875 100644 --- a/addons/common/functions/fnc_displayTextStructured.sqf +++ b/addons/common/functions/fnc_displayTextStructured.sqf @@ -6,7 +6,7 @@ * 0: Text * 1: Size of the textbox (default: 1.5) * 2: Target Unit. Will only display if target is the player controlled object (default: ACE_player) - * 3: Custom Width + * 3: Custom Width (optional) * * Return Value: * None diff --git a/addons/common/functions/fnc_dropBackpack.sqf b/addons/common/functions/fnc_dropBackpack.sqf index 7b7ee5765e..b0d77af7d5 100644 --- a/addons/common/functions/fnc_dropBackpack.sqf +++ b/addons/common/functions/fnc_dropBackpack.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Unit that has a backpack * - * Return value: + * Return Value: * Ground wepaon holder with backpack * * Public: Yes diff --git a/addons/common/functions/fnc_dumpArray.sqf b/addons/common/functions/fnc_dumpArray.sqf index 026b08501e..b60cede087 100644 --- a/addons/common/functions/fnc_dumpArray.sqf +++ b/addons/common/functions/fnc_dumpArray.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Array to be dumped - * 1: Depth + * 1: Depth (optional) * * Return Value: * None diff --git a/addons/common/functions/fnc_findUnloadPosition.sqf b/addons/common/functions/fnc_findUnloadPosition.sqf index c3b0dc3f34..dbb554d6d3 100644 --- a/addons/common/functions/fnc_findUnloadPosition.sqf +++ b/addons/common/functions/fnc_findUnloadPosition.sqf @@ -6,9 +6,9 @@ * Arguments: * 0: Source Vehicle * 1: Cargo Classname - * 2: Unloader (player) - * 3: Max Distance (meters) - * 4: Check Vehicle is Stable + * 2: Unloader (player) (optional) + * 3: Max Distance (meters) (optional) + * 4: Check Vehicle is Stable (optional) * * Return Value: * Unload PositionAGL (Can Be [] if no valid pos found) diff --git a/addons/common/functions/fnc_firedEH.sqf b/addons/common/functions/fnc_firedEH.sqf index d70f0a8650..75657d6dfe 100644 --- a/addons/common/functions/fnc_firedEH.sqf +++ b/addons/common/functions/fnc_firedEH.sqf @@ -2,7 +2,7 @@ * Author: esteldunedain * Unfied handling of weapon fire * - * Argument: + * Arguments: * 0: unit - Object the event handler is assigned to * 1: weapon - Fired weapon * 2: muzzle - Muzzle that was used @@ -11,7 +11,7 @@ * 5: magazine - magazine name which was used * 6: projectile - Object of the projectile that was shot * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/common/functions/fnc_fixPosition.sqf b/addons/common/functions/fnc_fixPosition.sqf index 689512d925..883a502c4e 100644 --- a/addons/common/functions/fnc_fixPosition.sqf +++ b/addons/common/functions/fnc_fixPosition.sqf @@ -3,7 +3,7 @@ * * Fixes position of an object. E.g. moves object above ground and adjusts to terrain slope. Requires local object. * - * Argument: + * Arguments: * Object * * Return Value: diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index 44fc204638..259c5e267f 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -4,7 +4,7 @@ * Also gets longitude, latitude and altitude offset for the map. * Writes return values to GVAR(MGRS_data) if run on the current map. * - * Argument: + * Arguments: * 0: Map name (default: worldName) * * Return Value: diff --git a/addons/common/functions/fnc_isInBuilding.sqf b/addons/common/functions/fnc_isInBuilding.sqf index e5234b9200..d4a9307cd6 100644 --- a/addons/common/functions/fnc_isInBuilding.sqf +++ b/addons/common/functions/fnc_isInBuilding.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Unit * - * Return value: + * Return Value: * Is the unit in a building? * * Public: Yes diff --git a/addons/common/functions/fnc_monitor.sqf b/addons/common/functions/fnc_monitor.sqf index 4672d6eec0..8aef62895c 100644 --- a/addons/common/functions/fnc_monitor.sqf +++ b/addons/common/functions/fnc_monitor.sqf @@ -2,7 +2,7 @@ * Author: commy2 * hint retun value of given function every frame * - * Argument: + * Arguments: * * * Return Value: diff --git a/addons/common/functions/fnc_removeAllEventHandlers.sqf b/addons/common/functions/fnc_removeAllEventHandlers.sqf index ed1cce278c..d1c6989b99 100644 --- a/addons/common/functions/fnc_removeAllEventHandlers.sqf +++ b/addons/common/functions/fnc_removeAllEventHandlers.sqf @@ -2,7 +2,7 @@ * Author: Nou * Remove all events of a certain event type. * - * Argument: + * Arguments: * 0: Event name * * Return Value: diff --git a/addons/common/functions/fnc_removeEventHandler.sqf b/addons/common/functions/fnc_removeEventHandler.sqf index a0b5ed5333..846cb4eeee 100644 --- a/addons/common/functions/fnc_removeEventHandler.sqf +++ b/addons/common/functions/fnc_removeEventHandler.sqf @@ -2,7 +2,7 @@ * Author: Nou * Remove an event handler. * - * Argument: + * Arguments: * 0: Event name * 1: Event code * diff --git a/addons/common/functions/fnc_runAfterSettingsInit.sqf b/addons/common/functions/fnc_runAfterSettingsInit.sqf index cf3faa1d7e..15631a626a 100644 --- a/addons/common/functions/fnc_runAfterSettingsInit.sqf +++ b/addons/common/functions/fnc_runAfterSettingsInit.sqf @@ -2,11 +2,11 @@ * Author: PabstMirror * Executes code after setting are initilized. * - * Argument: + * Arguments: * 0: Code to execute * 1: Parameters to run the code with * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/common/functions/fnc_serverEvent.sqf b/addons/common/functions/fnc_serverEvent.sqf index 65ab0da2a7..d6820fbf2e 100644 --- a/addons/common/functions/fnc_serverEvent.sqf +++ b/addons/common/functions/fnc_serverEvent.sqf @@ -2,7 +2,7 @@ * Author: Nou * Execute a event only on the server. * - * Argument: + * Arguments: * 0: Event name * 1: Event args * diff --git a/addons/common/functions/fnc_setApproximateVariablePublic.sqf b/addons/common/functions/fnc_setApproximateVariablePublic.sqf index 5131f99058..549dea9eb4 100644 --- a/addons/common/functions/fnc_setApproximateVariablePublic.sqf +++ b/addons/common/functions/fnc_setApproximateVariablePublic.sqf @@ -2,13 +2,13 @@ * Author: esteldunedain * Publish a variable if it's different enough from the previously published value. * - * Argument: + * Arguments: * 0: Object the variable should be assigned to * 1: Name of the variable * 2: Value of the variable * 3: Absolute tolerance * - * Return value: + * Return Value: * Nothing. * * Example: diff --git a/addons/common/functions/fnc_setVariablePublic.sqf b/addons/common/functions/fnc_setVariablePublic.sqf index 1cfba0a422..5eeff87aee 100644 --- a/addons/common/functions/fnc_setVariablePublic.sqf +++ b/addons/common/functions/fnc_setVariablePublic.sqf @@ -2,13 +2,13 @@ * Author: commy2 and CAA-Picard and joko and PabstMirror * Publish a variable, but wait a certain amount of time before allowing it to be published it again. * - * Argument: + * Arguments: * 0: Object the variable should be assigned to * 1: Name of the variable * 2: Value of the variable * 3: Embargo delay (Optional. Default: 1) * - * Return value: + * Return Value: * Nothing. * * Example: diff --git a/addons/common/functions/fnc_showHud.sqf b/addons/common/functions/fnc_showHud.sqf index 723c2436ed..a79636ed16 100644 --- a/addons/common/functions/fnc_showHud.sqf +++ b/addons/common/functions/fnc_showHud.sqf @@ -4,8 +4,8 @@ * Bitwise AND Logic (a single false in a mask will make it false) * * Arguments: - * 0: Source ID - * 1: Show Hud Bool Array (8 to set, empty to remove) + * 0: Source ID (optional) + * 1: Show Hud Bool Array (8 to set, empty to remove) (optional) * - [hud, info, radar, compass, direction, menu, group, cursors] * - hud: Boolean - show scripted HUD (same as normal showHUD true/false) * - info: Boolean - show vehicle + soldier info (hides weapon info from the HUD as well) diff --git a/addons/common/functions/fnc_showUser.sqf b/addons/common/functions/fnc_showUser.sqf index b783fb4ec5..2e7af12a3f 100644 --- a/addons/common/functions/fnc_showUser.sqf +++ b/addons/common/functions/fnc_showUser.sqf @@ -2,7 +2,7 @@ * Author: commy2 * hint the Variable ACE_isUsedBy from the input Object every frame * - * Argument: + * Arguments: * * * Return Value: diff --git a/addons/common/functions/fnc_unloadPersonLocal.sqf b/addons/common/functions/fnc_unloadPersonLocal.sqf index 741accb689..280c9875d7 100644 --- a/addons/common/functions/fnc_unloadPersonLocal.sqf +++ b/addons/common/functions/fnc_unloadPersonLocal.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: unit to unload * 1: Vehicle - * 2: Unloader (player) + * 2: Unloader (player) (optional) * * Return Value: * Returns true if succesfully unloaded person diff --git a/addons/common/functions/fnc_waitUntilAndExecute.sqf b/addons/common/functions/fnc_waitUntilAndExecute.sqf index 76f3d22ce1..52c596c70a 100644 --- a/addons/common/functions/fnc_waitUntilAndExecute.sqf +++ b/addons/common/functions/fnc_waitUntilAndExecute.sqf @@ -2,12 +2,12 @@ * Author: joko // Jonas * Executes a code once with after the Condition is True, using a PFH * - * Argument: + * Arguments: * 0: Condition * 1: Code to execute * 2: Parameters to run the code with * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/disarming/functions/fnc_disarmDropItems.sqf b/addons/disarming/functions/fnc_disarmDropItems.sqf index c9eb920084..9e9829dd0f 100644 --- a/addons/disarming/functions/fnc_disarmDropItems.sqf +++ b/addons/disarming/functions/fnc_disarmDropItems.sqf @@ -7,7 +7,7 @@ * 0: caller (player) * 1: target * 2: classnamess - * 3: Do Not Drop Ammo + * 3: Do Not Drop Ammo (optional) * * Return Value: * Nothing diff --git a/addons/dragging/functions/fnc_initObject.sqf b/addons/dragging/functions/fnc_initObject.sqf index b9f623395e..d36ffe9339 100644 --- a/addons/dragging/functions/fnc_initObject.sqf +++ b/addons/dragging/functions/fnc_initObject.sqf @@ -2,7 +2,7 @@ * Author: commy2 * Initialize variables for drag or carryable objects. Called from init EH. * - * Argument: + * Arguments: * 0: Any object * * Return Value: diff --git a/addons/dragging/functions/fnc_initPerson.sqf b/addons/dragging/functions/fnc_initPerson.sqf index 9e4aefeead..c8c26a4f8c 100644 --- a/addons/dragging/functions/fnc_initPerson.sqf +++ b/addons/dragging/functions/fnc_initPerson.sqf @@ -2,10 +2,10 @@ * Author: commy2 * Initialize variables for drag or carryable persons. Called from init EH. * - * Argument: + * Arguments: * 0: Unit * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/dragging/functions/fnc_isObjectOnObject.sqf b/addons/dragging/functions/fnc_isObjectOnObject.sqf index c113688322..cec6ce764e 100644 --- a/addons/dragging/functions/fnc_isObjectOnObject.sqf +++ b/addons/dragging/functions/fnc_isObjectOnObject.sqf @@ -2,10 +2,10 @@ * Author: commy2 * Check if Object is Overlapping * - * Argument: + * Arguments: * 0: Object * - * Return value: + * Return Value: * * * Example; diff --git a/addons/dragging/functions/fnc_setCarryable.sqf b/addons/dragging/functions/fnc_setCarryable.sqf index 0253c6ed4b..4de52e7bd8 100644 --- a/addons/dragging/functions/fnc_setCarryable.sqf +++ b/addons/dragging/functions/fnc_setCarryable.sqf @@ -2,7 +2,7 @@ * Author: commy2 * Enable the object to be carried. * - * Argument: + * Arguments: * 0: Any object * 1: true to enable carrying, false to disable * 2: Position offset for attachTo command (default: [0,1,1]) diff --git a/addons/dragging/functions/fnc_setDraggable.sqf b/addons/dragging/functions/fnc_setDraggable.sqf index 4c4d11ecf6..1fbcb995dc 100644 --- a/addons/dragging/functions/fnc_setDraggable.sqf +++ b/addons/dragging/functions/fnc_setDraggable.sqf @@ -2,13 +2,13 @@ * Author: commy2 * Enable the object to be dragged. * - * Argument: + * Arguments: * 0: Any object * 1: true to enable dragging, false to disable * 2: Position offset for attachTo command (Array, optinal; default: [0,0,0]) * 3: Direction in degree to rotate the object after attachTo (Number, optional; default: 0) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/dragging/functions/fnc_startDrag.sqf b/addons/dragging/functions/fnc_startDrag.sqf index 8c46fbe122..5ddaa0ede4 100644 --- a/addons/dragging/functions/fnc_startDrag.sqf +++ b/addons/dragging/functions/fnc_startDrag.sqf @@ -2,11 +2,11 @@ * Author: commy2 * Start the dragging process. * - * Argument: + * Arguments: * 0: Unit that should do the dragging * 1: Object to drag * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/explosives/functions/fnc_placeExplosive.sqf b/addons/explosives/functions/fnc_placeExplosive.sqf index 83cdb2fef8..4e3f7304df 100644 --- a/addons/explosives/functions/fnc_placeExplosive.sqf +++ b/addons/explosives/functions/fnc_placeExplosive.sqf @@ -9,7 +9,7 @@ * 3: Magazine class * 4: Config of trigger * 5: Variables required for the trigger type - * 6: Explosive placeholder + * 6: Explosive placeholder (optional) * * Return Value: * Placed explosive diff --git a/addons/explosives/functions/fnc_scriptedExplosive.sqf b/addons/explosives/functions/fnc_scriptedExplosive.sqf index 6a554ac09c..b4813cec29 100644 --- a/addons/explosives/functions/fnc_scriptedExplosive.sqf +++ b/addons/explosives/functions/fnc_scriptedExplosive.sqf @@ -5,7 +5,7 @@ * * Arguments: * 0: Explosives objects to detonate - * 1: Fuze delay (for each explosive; use negative number for random time up to value) + * 1: Fuze delay (for each explosive; use negative number for random time up to value) (optional) * * Return Value: * None diff --git a/addons/fcs/functions/fnc_calculateSolution.sqf b/addons/fcs/functions/fnc_calculateSolution.sqf index 6d489de006..61bfbd8c58 100644 --- a/addons/fcs/functions/fnc_calculateSolution.sqf +++ b/addons/fcs/functions/fnc_calculateSolution.sqf @@ -8,7 +8,7 @@ * 2: Target distance * 3: Azimuth offset * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/fcs/functions/fnc_canResetFCS.sqf b/addons/fcs/functions/fnc_canResetFCS.sqf index b57435f388..cf0dcf2674 100644 --- a/addons/fcs/functions/fnc_canResetFCS.sqf +++ b/addons/fcs/functions/fnc_canResetFCS.sqf @@ -2,7 +2,7 @@ * Author: KoffeinFlummi * Called from config. Can player reset FCS? * - * Argument: + * Arguments: * Nothing * * Return Value: diff --git a/addons/fcs/functions/fnc_getRange.sqf b/addons/fcs/functions/fnc_getRange.sqf index 64619241c4..ba49621047 100644 --- a/addons/fcs/functions/fnc_getRange.sqf +++ b/addons/fcs/functions/fnc_getRange.sqf @@ -2,13 +2,13 @@ * Author: commy2 * Read laser distance measurement from engine. * - * Argument: + * Arguments: * 0: Measurement Accuracy (default: 1) * 1: Maximum measure distance (default: 5000) * 2: Minimum measure distance (default: 0) * 3: Blank display on range error (default: false) * - * Return value: + * Return Value: * Measured distance * * Public: No diff --git a/addons/fcs/functions/fnc_updateRangeHUD.sqf b/addons/fcs/functions/fnc_updateRangeHUD.sqf index 374254c620..0bb15b2507 100644 --- a/addons/fcs/functions/fnc_updateRangeHUD.sqf +++ b/addons/fcs/functions/fnc_updateRangeHUD.sqf @@ -2,10 +2,10 @@ * Author: commy2 * Update compatible info elements. * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/gforces/functions/fnc_addPFEH.sqf b/addons/gforces/functions/fnc_addPFEH.sqf index 50311c3a06..9bd4d7fa1a 100644 --- a/addons/gforces/functions/fnc_addPFEH.sqf +++ b/addons/gforces/functions/fnc_addPFEH.sqf @@ -2,10 +2,10 @@ * Author: KoffeinFlummi and esteldunedain * Adds the PFEH * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/gforces/functions/fnc_pfhUpdateGForces.sqf b/addons/gforces/functions/fnc_pfhUpdateGForces.sqf index 7909f3d0ee..48370c2431 100644 --- a/addons/gforces/functions/fnc_pfhUpdateGForces.sqf +++ b/addons/gforces/functions/fnc_pfhUpdateGForces.sqf @@ -2,11 +2,11 @@ * Author: KoffeinFlummi and esteldunedain * Calculates average g-forces and triggers g-effects * - * Argument: + * Arguments: * 0: Arguments * 1: pfh_id * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/hearing/functions/fnc_updateVolume.sqf b/addons/hearing/functions/fnc_updateVolume.sqf index 01ab58ef76..af0483ae9c 100644 --- a/addons/hearing/functions/fnc_updateVolume.sqf +++ b/addons/hearing/functions/fnc_updateVolume.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Args - * -----0: Just update volume (skip ringing/recovery) + * -----0: Just update volume (skip ringing/recovery) (optional) * * Return Value: * None diff --git a/addons/interact_menu/functions/fnc_addActionToClass.sqf b/addons/interact_menu/functions/fnc_addActionToClass.sqf index 56ae64e5f9..32c086f692 100644 --- a/addons/interact_menu/functions/fnc_addActionToClass.sqf +++ b/addons/interact_menu/functions/fnc_addActionToClass.sqf @@ -3,13 +3,13 @@ * Insert an ACE action to a class, under a certain path * Note: This function is NOT global. * - * Argument: + * Arguments: * 0: TypeOf of the class * 1: Type of action, 0 for actions, 1 for self-actions * 2: Parent path of the new action * 3: Action * - * Return value: + * Return Value: * The entry full path, which can be used to remove the entry, or add children entries . * * Example: diff --git a/addons/interact_menu/functions/fnc_addActionToObject.sqf b/addons/interact_menu/functions/fnc_addActionToObject.sqf index 31e15ae7aa..d307f8b9ad 100644 --- a/addons/interact_menu/functions/fnc_addActionToObject.sqf +++ b/addons/interact_menu/functions/fnc_addActionToObject.sqf @@ -3,13 +3,13 @@ * Insert an ACE action to an object, under a certain config path * Note: This function is NOT global. * - * Argument: + * Arguments: * 0: Object the action should be assigned to * 1: Type of action, 0 for actions, 1 for self-actions * 2: Parent path of the new action * 3: Action * - * Return value: + * Return Value: * The entry full path, which can be used to remove the entry, or add children entries . * * Example: diff --git a/addons/interact_menu/functions/fnc_addMainAction.sqf b/addons/interact_menu/functions/fnc_addMainAction.sqf index 4370f4d2ee..43273ef967 100644 --- a/addons/interact_menu/functions/fnc_addMainAction.sqf +++ b/addons/interact_menu/functions/fnc_addMainAction.sqf @@ -2,11 +2,11 @@ * Author: Jonpas, PabstMirror * Makes sure there is a ACE_MainActions on the object type * - * Argument: + * Arguments: * 0: Object classname * 1: Type of action, 0 for actions, 1 for self-actions * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf b/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf index 42fcf96cc7..ae066576f7 100644 --- a/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf +++ b/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf @@ -2,13 +2,13 @@ * Author: esteldunedain * Collect a entire tree of active actions * - * Argument: + * Arguments: * 0: Object * 1: Original action tree * 2: Parent path * 3: Distance to base point (will be 0 for self/zeus/in-vehicle) * - * Return value: + * Return Value: * Active children * * Public: No diff --git a/addons/interact_menu/functions/fnc_compileMenu.sqf b/addons/interact_menu/functions/fnc_compileMenu.sqf index 7f2ca38540..4cf657a3bc 100644 --- a/addons/interact_menu/functions/fnc_compileMenu.sqf +++ b/addons/interact_menu/functions/fnc_compileMenu.sqf @@ -2,10 +2,10 @@ * Author: NouberNou and esteldunedain * Compile the action menu from config for an object's class * - * Argument: + * Arguments: * 0: Object or class name or * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf b/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf index eb9727a072..0c5e236f0b 100644 --- a/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf +++ b/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf @@ -2,10 +2,10 @@ * Author: NouberNou and esteldunedain * Compile the self action menu from config for an object's class * - * Argument: + * Arguments: * 0: Object or class name or * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_compileMenuZeus.sqf b/addons/interact_menu/functions/fnc_compileMenuZeus.sqf index 6026735154..c0797269e6 100644 --- a/addons/interact_menu/functions/fnc_compileMenuZeus.sqf +++ b/addons/interact_menu/functions/fnc_compileMenuZeus.sqf @@ -2,10 +2,10 @@ * Author: SilentSpike * Compile the zeus action menu (only to be done once) * - * Argument: + * Arguments: * nil * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_createAction.sqf b/addons/interact_menu/functions/fnc_createAction.sqf index db31200c47..b7616b9718 100644 --- a/addons/interact_menu/functions/fnc_createAction.sqf +++ b/addons/interact_menu/functions/fnc_createAction.sqf @@ -3,7 +3,7 @@ * Creates an isolated ACE action * Note: This function is NOT global. * - * Argument: + * Arguments: * 0: Action name * 1: Name of the action shown in the menu * 2: Icon @@ -16,7 +16,7 @@ * 9: Other parameters [showDisabled,enableInside,canCollapse,runOnHover,doNotCheckLOS] (Optional) * 10: Modifier function (Optional) * - * Return value: + * Return Value: * Action * * Example: diff --git a/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf b/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf index 1c4e535d66..38e5a42460 100644 --- a/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf +++ b/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf @@ -2,12 +2,12 @@ * Author: commy2 * Sets the controls structured text if it isn't already set. * - * Argument: + * Arguments: * 0: Structured Text Ctrl * 1: Index * 2: Text * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_findActionNode.sqf b/addons/interact_menu/functions/fnc_findActionNode.sqf index edd0cace04..c328e03f39 100644 --- a/addons/interact_menu/functions/fnc_findActionNode.sqf +++ b/addons/interact_menu/functions/fnc_findActionNode.sqf @@ -3,11 +3,11 @@ * Return action point from path * Note: This function is NOT global. * - * Argument: + * Arguments: * 0: List of Action Tree * 1: Path * - * Return value: + * Return Value: * Action node or if not found * * Example: diff --git a/addons/interact_menu/functions/fnc_handlePlayerChanged.sqf b/addons/interact_menu/functions/fnc_handlePlayerChanged.sqf index d8ad91c434..f995ffa454 100644 --- a/addons/interact_menu/functions/fnc_handlePlayerChanged.sqf +++ b/addons/interact_menu/functions/fnc_handlePlayerChanged.sqf @@ -2,11 +2,11 @@ * Author: commy2 * Disables firing while the menu is opened. Called from playerChanged eh. * - * Argument: + * Arguments: * 0: New unit to add the addAction eh * 1: Old unit to remove the addAction eh * - * Return value: + * Return Value: * None */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_isSubPath.sqf b/addons/interact_menu/functions/fnc_isSubPath.sqf index 53d88eb9d1..5933e2c462 100644 --- a/addons/interact_menu/functions/fnc_isSubPath.sqf +++ b/addons/interact_menu/functions/fnc_isSubPath.sqf @@ -2,11 +2,11 @@ * Author: esteldunedain * Check if the first path is a subpath of the other * - * Argument: + * Arguments: * 0: LongPath * 1: ShortPath * - * Return value: + * Return Value: * Bool * * Example: diff --git a/addons/interact_menu/functions/fnc_keyDown.sqf b/addons/interact_menu/functions/fnc_keyDown.sqf index 4d9f0af4db..c1c7789a64 100644 --- a/addons/interact_menu/functions/fnc_keyDown.sqf +++ b/addons/interact_menu/functions/fnc_keyDown.sqf @@ -2,10 +2,10 @@ * Author: NouberNou and esteldunedain * Handle interactions key down * - * Argument: + * Arguments: * 0: Type of key: 0 interaction / 1 self interaction * - * Return value: + * Return Value: * true * * Public: No diff --git a/addons/interact_menu/functions/fnc_keyUp.sqf b/addons/interact_menu/functions/fnc_keyUp.sqf index b6eae6f527..6a43c8e559 100644 --- a/addons/interact_menu/functions/fnc_keyUp.sqf +++ b/addons/interact_menu/functions/fnc_keyUp.sqf @@ -2,10 +2,10 @@ * Author: NouberNou and esteldunedain * Handle interactions key up * - * Argument: + * Arguments: * 0: Type of key: 0 interaction / 1 self interaction * - * Return value: + * Return Value: * true * * Public: No diff --git a/addons/interact_menu/functions/fnc_removeActionFromClass.sqf b/addons/interact_menu/functions/fnc_removeActionFromClass.sqf index a01078ad3b..f3db5fc8c3 100644 --- a/addons/interact_menu/functions/fnc_removeActionFromClass.sqf +++ b/addons/interact_menu/functions/fnc_removeActionFromClass.sqf @@ -2,12 +2,12 @@ * Author: esteldunedain * Removes an action from a class * - * Argument: + * Arguments: * 0: TypeOf of the class * 1: Type of action, 0 for actions, 1 for self-actions * 2: Full path of the new action * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/interact_menu/functions/fnc_removeActionFromObject.sqf b/addons/interact_menu/functions/fnc_removeActionFromObject.sqf index e630bf4ad1..3b720d3c71 100644 --- a/addons/interact_menu/functions/fnc_removeActionFromObject.sqf +++ b/addons/interact_menu/functions/fnc_removeActionFromObject.sqf @@ -2,12 +2,12 @@ * Author: commy2, NouberNou and esteldunedain * Removes an action from an object * - * Argument: + * Arguments: * 0: Object the action is assigned to * 1: Type of action, 0 for actions, 1 for self-actions * 2: Full path of the action to remove * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/interact_menu/functions/fnc_render.sqf b/addons/interact_menu/functions/fnc_render.sqf index 00745a406f..221ddb7ba9 100644 --- a/addons/interact_menu/functions/fnc_render.sqf +++ b/addons/interact_menu/functions/fnc_render.sqf @@ -2,10 +2,10 @@ * Author: NouberNou and esteldunedain * Render all available nearby interactions * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/interact_menu/functions/fnc_renderActionPoints.sqf b/addons/interact_menu/functions/fnc_renderActionPoints.sqf index d3df02ca40..21aec3f24c 100644 --- a/addons/interact_menu/functions/fnc_renderActionPoints.sqf +++ b/addons/interact_menu/functions/fnc_renderActionPoints.sqf @@ -2,10 +2,10 @@ * Author: NouberNou and esteldunedain * Render all action points * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_renderBaseMenu.sqf b/addons/interact_menu/functions/fnc_renderBaseMenu.sqf index 57ded33be0..512779fe82 100644 --- a/addons/interact_menu/functions/fnc_renderBaseMenu.sqf +++ b/addons/interact_menu/functions/fnc_renderBaseMenu.sqf @@ -2,12 +2,12 @@ * Author: NouberNou and esteldunedain * Render the interaction menu for a base action * - * Argument: + * Arguments: * 0: Object * 1: Action node * 2: 3D position or 2D position (Optional) * - * Return value: + * Return Value: * Was the menu rendered * * Public: No diff --git a/addons/interact_menu/functions/fnc_renderIcon.sqf b/addons/interact_menu/functions/fnc_renderIcon.sqf index 9ead5c65cf..ceeeb9991d 100644 --- a/addons/interact_menu/functions/fnc_renderIcon.sqf +++ b/addons/interact_menu/functions/fnc_renderIcon.sqf @@ -2,13 +2,13 @@ * Author: NouberNou and esteldunedain * Render a single interaction icon * - * Argument: + * Arguments: * 0: Text * 1: Icon * 2: 2d position * 3: Text Settings * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_renderMenu.sqf b/addons/interact_menu/functions/fnc_renderMenu.sqf index f975db17f1..687c56d2c3 100644 --- a/addons/interact_menu/functions/fnc_renderMenu.sqf +++ b/addons/interact_menu/functions/fnc_renderMenu.sqf @@ -2,13 +2,13 @@ * Author: NouberNou and esteldunedain * Render an interaction menu and it's children recursively * - * Argument: + * Arguments: * 0: Parent path * 1: Action data * 2: 2D position * 3: Angle range available for rendering * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_renderSelector.sqf b/addons/interact_menu/functions/fnc_renderSelector.sqf index 69f8a81b95..ef10456b5a 100644 --- a/addons/interact_menu/functions/fnc_renderSelector.sqf +++ b/addons/interact_menu/functions/fnc_renderSelector.sqf @@ -2,11 +2,11 @@ * Author: esteldunedain * Render a single interaction icon * - * Argument: + * Arguments: * 0: 2d position * 1: Icon * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_setupTextColors.sqf b/addons/interact_menu/functions/fnc_setupTextColors.sqf index cbdd56fb07..120c5b18e3 100644 --- a/addons/interact_menu/functions/fnc_setupTextColors.sqf +++ b/addons/interact_menu/functions/fnc_setupTextColors.sqf @@ -2,10 +2,10 @@ * Author: PabstMirror * Builds color strings needed for displaying interaction text * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/interact_menu/functions/fnc_splitPath.sqf b/addons/interact_menu/functions/fnc_splitPath.sqf index ba07dc1d9e..eba203aa6f 100644 --- a/addons/interact_menu/functions/fnc_splitPath.sqf +++ b/addons/interact_menu/functions/fnc_splitPath.sqf @@ -2,10 +2,10 @@ * Author: esteldunedain * Take full path and split it between parent path and action name * - * Argument: + * Arguments: * Full path of the action to remove * - * Return value: + * Return Value: * 0: Parent path * 1: Action name * diff --git a/addons/interaction/functions/fnc_canJoinTeam.sqf b/addons/interaction/functions/fnc_canJoinTeam.sqf index b91a5abd5c..7732e164e7 100644 --- a/addons/interaction/functions/fnc_canJoinTeam.sqf +++ b/addons/interaction/functions/fnc_canJoinTeam.sqf @@ -6,7 +6,7 @@ * 0: Player * 1: Target * - * Return value: + * Return Value: * Able to join a team * * Example: diff --git a/addons/interaction/functions/fnc_getWeaponPos.sqf b/addons/interaction/functions/fnc_getWeaponPos.sqf index 58c8756076..d0db3cee77 100644 --- a/addons/interaction/functions/fnc_getWeaponPos.sqf +++ b/addons/interaction/functions/fnc_getWeaponPos.sqf @@ -5,7 +5,7 @@ * Arguments: * None (uses local variable _target) * - * Return value: + * Return Value: * Children actions * * Example: diff --git a/addons/interaction/functions/fnc_hideMouseHint.sqf b/addons/interaction/functions/fnc_hideMouseHint.sqf index 709b798fed..757fe952e5 100644 --- a/addons/interaction/functions/fnc_hideMouseHint.sqf +++ b/addons/interaction/functions/fnc_hideMouseHint.sqf @@ -5,7 +5,7 @@ * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/interaction/functions/fnc_showMouseHint.sqf b/addons/interaction/functions/fnc_showMouseHint.sqf index 57c8a7bf50..821abda14e 100644 --- a/addons/interaction/functions/fnc_showMouseHint.sqf +++ b/addons/interaction/functions/fnc_showMouseHint.sqf @@ -7,7 +7,7 @@ * 1: Right Click Text * 2: Scroll Text (Optional) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/interaction/functions/fnc_switchLamp.sqf b/addons/interaction/functions/fnc_switchLamp.sqf index 20a2d45dea..9b5a6ab6bb 100644 --- a/addons/interaction/functions/fnc_switchLamp.sqf +++ b/addons/interaction/functions/fnc_switchLamp.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Lamp * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/laser/functions/fnc_laserOff.sqf b/addons/laser/functions/fnc_laserOff.sqf index 7899ec1253..c310eb73c9 100644 --- a/addons/laser/functions/fnc_laserOff.sqf +++ b/addons/laser/functions/fnc_laserOff.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: UUID (from laserOn) * - * Return value: + * Return Value: * None */ diff --git a/addons/laser/functions/fnc_laserOn.sqf b/addons/laser/functions/fnc_laserOn.sqf index e44671e856..c34ef495c8 100644 --- a/addons/laser/functions/fnc_laserOn.sqf +++ b/addons/laser/functions/fnc_laserOn.sqf @@ -10,7 +10,7 @@ * 4: Laser code * 5: Beam divergence (in mils off beam center). * - * Return value: + * Return Value: * String, UUID for sending to laserOff function. */ diff --git a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf index 45b60a69c1..f43541b56f 100644 --- a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf +++ b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf @@ -9,7 +9,7 @@ * 3: Seeker wavelength sensitivity range, [1550,1550] is common eye safe. * 4: Seeker laser code. * - * Return value: + * Return Value: * Array, [Strongest compatible laser spot ASL pos, owner object] Nil array values if nothing found. */ diff --git a/addons/laser/functions/fnc_unitTurretCanLockLaser.sqf b/addons/laser/functions/fnc_unitTurretCanLockLaser.sqf index a82e42400a..9fe478f623 100644 --- a/addons/laser/functions/fnc_unitTurretCanLockLaser.sqf +++ b/addons/laser/functions/fnc_unitTurretCanLockLaser.sqf @@ -2,10 +2,10 @@ * Author: jaynus * Checks if the turret occupied by the given unit can lock a laser designator and select laser code. * - * Argument: + * Arguments: * 0: Unit * - * Return value: + * Return Value: * Has designator? */ #include "script_component.hpp" diff --git a/addons/laser/functions/fnc_vanillaLaserSeekerHandler.sqf b/addons/laser/functions/fnc_vanillaLaserSeekerHandler.sqf index 091c4f7acf..5357a99c37 100644 --- a/addons/laser/functions/fnc_vanillaLaserSeekerHandler.sqf +++ b/addons/laser/functions/fnc_vanillaLaserSeekerHandler.sqf @@ -2,11 +2,11 @@ * Author: jaynus * Handler function for laser network code. * - * Argument: + * Arguments: * 0: Emitter * 1: Owner * - * Return value: + * Return Value: * [position, direction] */ //#define DEBUG_MODE_FULL diff --git a/addons/laser_selfdesignate/functions/fnc_findLaserSource.sqf b/addons/laser_selfdesignate/functions/fnc_findLaserSource.sqf index 955f1ea51d..d3ba242b85 100644 --- a/addons/laser_selfdesignate/functions/fnc_findLaserSource.sqf +++ b/addons/laser_selfdesignate/functions/fnc_findLaserSource.sqf @@ -2,7 +2,7 @@ * Author: jaynus * Handler function for laser network code. * - * Argument: + * Arguments: * 0: Emitter * * Return Value: diff --git a/addons/laser_selfdesignate/functions/fnc_laserHudDesignateOff.sqf b/addons/laser_selfdesignate/functions/fnc_laserHudDesignateOff.sqf index 300811cba2..28624eafc8 100644 --- a/addons/laser_selfdesignate/functions/fnc_laserHudDesignateOff.sqf +++ b/addons/laser_selfdesignate/functions/fnc_laserHudDesignateOff.sqf @@ -2,7 +2,7 @@ * Author: jaynus * Turns off passed laser self designation. * - * Argument: + * Arguments: * 0: Shooter, player shooting the laser * 1: LaserUUID, the UUID of the laser returned by EFUNC(laser,laserOn) * 2: Local laser target, unused. diff --git a/addons/magazinerepack/functions/fnc_getMagazineChildren.sqf b/addons/magazinerepack/functions/fnc_getMagazineChildren.sqf index 88cd0ff275..f8a18438e9 100644 --- a/addons/magazinerepack/functions/fnc_getMagazineChildren.sqf +++ b/addons/magazinerepack/functions/fnc_getMagazineChildren.sqf @@ -2,11 +2,11 @@ * Author: PabstMirror, commy2, esteldunedain, Ruthberg * Gets magazine children for interaciton menu. * - * Argument: + * Arguments: * 0: Target * 1: Player * - * Return value: + * Return Value: * ChildActions * * Example: diff --git a/addons/map/functions/fnc_compileFlashlightMenu.sqf b/addons/map/functions/fnc_compileFlashlightMenu.sqf index 836b483a20..5b91f15ca4 100644 --- a/addons/map/functions/fnc_compileFlashlightMenu.sqf +++ b/addons/map/functions/fnc_compileFlashlightMenu.sqf @@ -7,7 +7,7 @@ * 1: Player * 3: Parameters * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/map/functions/fnc_flashlightGlow.sqf b/addons/map/functions/fnc_flashlightGlow.sqf index 799b99e3d2..07567b9079 100644 --- a/addons/map/functions/fnc_flashlightGlow.sqf +++ b/addons/map/functions/fnc_flashlightGlow.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Flashlight classname ("" for off) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/map/functions/fnc_getUnitFlashlights.sqf b/addons/map/functions/fnc_getUnitFlashlights.sqf index 41874cc0ca..eeaf504156 100644 --- a/addons/map/functions/fnc_getUnitFlashlights.sqf +++ b/addons/map/functions/fnc_getUnitFlashlights.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Unit to check * - * Return value: + * Return Value: * Flashlight classnames (empty for none) * * Example: diff --git a/addons/map/functions/fnc_switchFlashlight.sqf b/addons/map/functions/fnc_switchFlashlight.sqf index e177f886fa..e270ee0c11 100644 --- a/addons/map/functions/fnc_switchFlashlight.sqf +++ b/addons/map/functions/fnc_switchFlashlight.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Flashlight classname ("" for off) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/maptools/functions/fnc_addLineMarker.sqf b/addons/maptools/functions/fnc_addLineMarker.sqf index 017dc5b494..bc3e74b797 100644 --- a/addons/maptools/functions/fnc_addLineMarker.sqf +++ b/addons/maptools/functions/fnc_addLineMarker.sqf @@ -8,7 +8,7 @@ * 2: Marker end pos * 3: Color index * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/maptools/functions/fnc_calculateMapScale.sqf b/addons/maptools/functions/fnc_calculateMapScale.sqf index 018edf68d9..a3b925e014 100644 --- a/addons/maptools/functions/fnc_calculateMapScale.sqf +++ b/addons/maptools/functions/fnc_calculateMapScale.sqf @@ -5,7 +5,7 @@ * Arguments: * None * - * Return value: + * Return Value: * No * * Public: No diff --git a/addons/maptools/functions/fnc_canDraw.sqf b/addons/maptools/functions/fnc_canDraw.sqf index da55043d85..35bf4eb3f2 100644 --- a/addons/maptools/functions/fnc_canDraw.sqf +++ b/addons/maptools/functions/fnc_canDraw.sqf @@ -5,7 +5,7 @@ * Arguments: * None * - * Return value: + * Return Value: * * * Public: No diff --git a/addons/maptools/functions/fnc_canUseMapGPS.sqf b/addons/maptools/functions/fnc_canUseMapGPS.sqf index 381136a1cc..a327c2bc8d 100644 --- a/addons/maptools/functions/fnc_canUseMapGPS.sqf +++ b/addons/maptools/functions/fnc_canUseMapGPS.sqf @@ -5,7 +5,7 @@ * Arguments: * None * - * Return value: + * Return Value: * * * Public: No diff --git a/addons/maptools/functions/fnc_canUseMapTools.sqf b/addons/maptools/functions/fnc_canUseMapTools.sqf index 7658c2c1d2..8c16425082 100644 --- a/addons/maptools/functions/fnc_canUseMapTools.sqf +++ b/addons/maptools/functions/fnc_canUseMapTools.sqf @@ -5,7 +5,7 @@ * Arguments: * None * - * Return value: + * Return Value: * * * Public: No diff --git a/addons/maptools/functions/fnc_cancelDrawing.sqf b/addons/maptools/functions/fnc_cancelDrawing.sqf index bc80602cfc..203e0831b9 100644 --- a/addons/maptools/functions/fnc_cancelDrawing.sqf +++ b/addons/maptools/functions/fnc_cancelDrawing.sqf @@ -5,7 +5,7 @@ * Arguments: * None * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/maptools/functions/fnc_copyMapReceiveMarkers.sqf b/addons/maptools/functions/fnc_copyMapReceiveMarkers.sqf index 6c3c706208..644ad00ac8 100644 --- a/addons/maptools/functions/fnc_copyMapReceiveMarkers.sqf +++ b/addons/maptools/functions/fnc_copyMapReceiveMarkers.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Array of markers to copy * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/maptools/functions/fnc_copyMapRemoteSend.sqf b/addons/maptools/functions/fnc_copyMapRemoteSend.sqf index 551019f900..e909391715 100644 --- a/addons/maptools/functions/fnc_copyMapRemoteSend.sqf +++ b/addons/maptools/functions/fnc_copyMapRemoteSend.sqf @@ -3,10 +3,10 @@ * * Send Map markers to other player * - * Argument: + * Arguments: * 0: Target player (Unit) * - * Return value: + * Return Value: * Return */ diff --git a/addons/maptools/functions/fnc_copyMapStart.sqf b/addons/maptools/functions/fnc_copyMapStart.sqf index 7295f6f499..c0178b54db 100644 --- a/addons/maptools/functions/fnc_copyMapStart.sqf +++ b/addons/maptools/functions/fnc_copyMapStart.sqf @@ -11,7 +11,7 @@ * handeled by: copyMapRemoteSend: triggers event "drawing_sendbackMarkers" on origin * handeled by: copyMapReceiveMarkers * - * Return value: + * Return Value: * Return */ diff --git a/addons/maptools/functions/fnc_handleKeyDown.sqf b/addons/maptools/functions/fnc_handleKeyDown.sqf index a83522ac91..5102771dc2 100644 --- a/addons/maptools/functions/fnc_handleKeyDown.sqf +++ b/addons/maptools/functions/fnc_handleKeyDown.sqf @@ -9,7 +9,7 @@ * 3: Ctrl Key (boolean) * 4: Alt Key (boolean) * - * Return value: + * Return Value: * Boolean, true if event was handled */ diff --git a/addons/maptools/functions/fnc_handleMouseButton.sqf b/addons/maptools/functions/fnc_handleMouseButton.sqf index cb1a4598ad..d8f9eb5cca 100644 --- a/addons/maptools/functions/fnc_handleMouseButton.sqf +++ b/addons/maptools/functions/fnc_handleMouseButton.sqf @@ -2,11 +2,11 @@ * Author: esteldunedain * Handle mouse buttons. * - * Argument: + * Arguments: * 0: 1 if mouse down down, 0 if mouse button up (Number) * 1: Parameters of the mouse button event * - * Return value: + * Return Value: * Boolean, true if event was handled */ diff --git a/addons/maptools/functions/fnc_handleMouseMove.sqf b/addons/maptools/functions/fnc_handleMouseMove.sqf index b27087290b..2819ca0353 100644 --- a/addons/maptools/functions/fnc_handleMouseMove.sqf +++ b/addons/maptools/functions/fnc_handleMouseMove.sqf @@ -2,11 +2,11 @@ * Author: esteldunedain * Handle mouse movement over the map tool. * - * Argument: + * Arguments: * 0: Map Control * 1: Mouse position on screen coordinates * - * Return value: + * Return Value: * Boolean, true if event was handled */ diff --git a/addons/maptools/functions/fnc_handleMouseZChanged.sqf b/addons/maptools/functions/fnc_handleMouseZChanged.sqf index 0af86a81c5..2b9e969e47 100644 --- a/addons/maptools/functions/fnc_handleMouseZChanged.sqf +++ b/addons/maptools/functions/fnc_handleMouseZChanged.sqf @@ -3,11 +3,11 @@ * * Handle mouse wheel. * - * Argument: + * Arguments: * 0: Control * 1: Scroll Amount * - * Return value: + * Return Value: * Boolean, true if event was handled */ diff --git a/addons/maptools/functions/fnc_isInsideMapTool.sqf b/addons/maptools/functions/fnc_isInsideMapTool.sqf index eeaf8f346a..0eaa9c40ef 100644 --- a/addons/maptools/functions/fnc_isInsideMapTool.sqf +++ b/addons/maptools/functions/fnc_isInsideMapTool.sqf @@ -6,7 +6,7 @@ * 0: x Position (in meters) * 1: y Position (in meters) * - * Return value: + * Return Value: * Boolean */ #include "script_component.hpp" diff --git a/addons/maptools/functions/fnc_openMapGps.sqf b/addons/maptools/functions/fnc_openMapGps.sqf index dc2df07b57..56c96d4e4b 100644 --- a/addons/maptools/functions/fnc_openMapGps.sqf +++ b/addons/maptools/functions/fnc_openMapGps.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Open GPS? * - * Return value: + * Return Value: * Nothing * * Public: No diff --git a/addons/maptools/functions/fnc_removeLineMarker.sqf b/addons/maptools/functions/fnc_removeLineMarker.sqf index bd0a16adb1..f2be5436cc 100644 --- a/addons/maptools/functions/fnc_removeLineMarker.sqf +++ b/addons/maptools/functions/fnc_removeLineMarker.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Marker Name * - * Return value: + * Return Value: * Return */ diff --git a/addons/maptools/functions/fnc_updateLineMarker.sqf b/addons/maptools/functions/fnc_updateLineMarker.sqf index 12aee5b1df..de7ab6e87c 100644 --- a/addons/maptools/functions/fnc_updateLineMarker.sqf +++ b/addons/maptools/functions/fnc_updateLineMarker.sqf @@ -8,7 +8,7 @@ * 2: Marker end pos * 3: Color index * - * Return value: + * Return Value: * None */ #include "script_component.hpp" diff --git a/addons/maptools/functions/fnc_updateMapToolMarkers.sqf b/addons/maptools/functions/fnc_updateMapToolMarkers.sqf index 530d213773..99275f0721 100644 --- a/addons/maptools/functions/fnc_updateMapToolMarkers.sqf +++ b/addons/maptools/functions/fnc_updateMapToolMarkers.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: The Map * - * Return value: + * Return Value: * Nothing * * Public: No diff --git a/addons/medical/functions/fnc_addUnloadPatientActions.sqf b/addons/medical/functions/fnc_addUnloadPatientActions.sqf index f29b3923f1..9a8220f781 100644 --- a/addons/medical/functions/fnc_addUnloadPatientActions.sqf +++ b/addons/medical/functions/fnc_addUnloadPatientActions.sqf @@ -2,12 +2,12 @@ * Author: esteldunedain * Create one unload action per unconscious passenger * - * Argument: + * Arguments: * 0: Vehicle * 1: Player * 3: Parameters * - * Return value: + * Return Value: * Children actions * * Public: No diff --git a/addons/microdagr/functions/fnc_openDisplay.sqf b/addons/microdagr/functions/fnc_openDisplay.sqf index aa2db94827..21ddf884c6 100644 --- a/addons/microdagr/functions/fnc_openDisplay.sqf +++ b/addons/microdagr/functions/fnc_openDisplay.sqf @@ -3,7 +3,7 @@ * Changes the display mode of the microDAGR * * Arguments: - * 0: Display Mode to show the microDAGR in + * 0: Display Mode to show the microDAGR in (optional) * * Return Value: * None diff --git a/addons/missileguidance/functions/fnc_checkLos.sqf b/addons/missileguidance/functions/fnc_checkLos.sqf index f21a841367..7962409625 100644 --- a/addons/missileguidance/functions/fnc_checkLos.sqf +++ b/addons/missileguidance/functions/fnc_checkLos.sqf @@ -2,11 +2,11 @@ * Author: jaynus * Returns whether the seeker object can see the target position with lineIntersect * - * Argument: + * Arguments: * 0: Seeker [Object] * 1: Target [Object] * - * Return value: + * Return Value: * Boolean */ #include "script_component.hpp" diff --git a/addons/missileguidance/functions/fnc_checkSeekerAngle.sqf b/addons/missileguidance/functions/fnc_checkSeekerAngle.sqf index e8bc1a16f5..6327892fa1 100644 --- a/addons/missileguidance/functions/fnc_checkSeekerAngle.sqf +++ b/addons/missileguidance/functions/fnc_checkSeekerAngle.sqf @@ -3,12 +3,12 @@ * Returns whether the target position is within the maximum angle FOV of the provided seeker * objects current direction. * - * Argument: + * Arguments: * 0: Seeker [Object] * 1: Target [Position] * 2: Max Angle [Degrees] * - * Return value: + * Return Value: * Boolean */ diff --git a/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf b/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf index 16016f06e6..5116a44d71 100644 --- a/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf +++ b/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf @@ -6,7 +6,7 @@ * 0: static * 1: unit * 2: time to load - * 3: magazineClassOptional + * 3: magazineClassOptional (optional) * * Return Value: * None diff --git a/addons/nametags/functions/fnc_drawNameTagIcon.sqf b/addons/nametags/functions/fnc_drawNameTagIcon.sqf index f031882da7..0c313d572e 100644 --- a/addons/nametags/functions/fnc_drawNameTagIcon.sqf +++ b/addons/nametags/functions/fnc_drawNameTagIcon.sqf @@ -11,7 +11,7 @@ * 5: Draw rank * 6: Draw soundwave * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overheating/functions/fnc_calculateCooling.sqf b/addons/overheating/functions/fnc_calculateCooling.sqf index 955c41441e..ced682d6d7 100644 --- a/addons/overheating/functions/fnc_calculateCooling.sqf +++ b/addons/overheating/functions/fnc_calculateCooling.sqf @@ -2,12 +2,12 @@ * Author: esteldunedain * Calculate the cooling down of a weapon over a time interval. * - * Argument: + * Arguments: * 0: Initial temperature * 1: Barrel mass * 2: Time interval * - * Return value: + * Return Value: * Final temperature * * Example: diff --git a/addons/overheating/functions/fnc_firedEH.sqf b/addons/overheating/functions/fnc_firedEH.sqf index 5bd725b74d..e392190bb0 100644 --- a/addons/overheating/functions/fnc_firedEH.sqf +++ b/addons/overheating/functions/fnc_firedEH.sqf @@ -2,10 +2,10 @@ * Author: Commy2 and esteldunedain * Handle weapon fire. Called from the unified fired EH 1- always for the local player 2- and for non local players if dispersion is simulated. * - * Argument: + * Arguments: * None. Parameters inherited from EFUNC(common,firedEH) * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/overheating/functions/fnc_getWeaponData.sqf b/addons/overheating/functions/fnc_getWeaponData.sqf index e7da350e91..b1525f0f41 100644 --- a/addons/overheating/functions/fnc_getWeaponData.sqf +++ b/addons/overheating/functions/fnc_getWeaponData.sqf @@ -2,10 +2,10 @@ * Author: PabstMirror and esteldunedain * Get weapon data with caching * - * Argument: + * Arguments: * 0: weapon type * - * Return value: + * Return Value: * 0: dispresion * 1: slowdownFactor * 2: jamChance diff --git a/addons/overheating/functions/fnc_handleTakeEH.sqf b/addons/overheating/functions/fnc_handleTakeEH.sqf index ffcead342f..b4eecbf236 100644 --- a/addons/overheating/functions/fnc_handleTakeEH.sqf +++ b/addons/overheating/functions/fnc_handleTakeEH.sqf @@ -3,12 +3,12 @@ * Handle "take" event * I think it fixs jams when manually dragging a new magazine in from player's inventory * - * Argument: + * Arguments: * 0: unit - Object the event handler is assigned to * 1: container * 2: item * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/overheating/functions/fnc_jamWeapon.sqf b/addons/overheating/functions/fnc_jamWeapon.sqf index 4e42f769f7..ec860e5cf6 100644 --- a/addons/overheating/functions/fnc_jamWeapon.sqf +++ b/addons/overheating/functions/fnc_jamWeapon.sqf @@ -2,11 +2,11 @@ * Author: Commy2, based on KK_fnc_playerWeaponMulfunction from KillzoneKid * Jam the weapon * - * Argument: + * Arguments: * 0: Unit * 1: Weapon * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf index 7887a87ce6..a208c603e3 100644 --- a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -3,14 +3,14 @@ * Collect the temperature of all the spare barrels a unit has and load the * coolest on the unit weapon. Runs on the server. * - * Argument: + * Arguments: * 0: Unit that has the spare barrels * 1: Unit that has the weapon * 2: Weapon * 3: Weapon temp before switching * 4: Mass of the removed barrel * - * Return value: + * Return Value: * None * * diff --git a/addons/overheating/functions/fnc_overheat.sqf b/addons/overheating/functions/fnc_overheat.sqf index 57a4bd7cba..84ab7e152f 100644 --- a/addons/overheating/functions/fnc_overheat.sqf +++ b/addons/overheating/functions/fnc_overheat.sqf @@ -2,7 +2,7 @@ * Author: Commy2 and esteldunedain * Handle weapon fire, heat up the weapon * - * Argument: + * Arguments: * 0: Unit * 1: Weapon * 3: Muzzle @@ -10,7 +10,7 @@ * 5: Magazine * 6: Projectile * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf index 2ff248016d..6e229faaf5 100644 --- a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf +++ b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf @@ -3,11 +3,11 @@ * Collect the temperature of all the spare barrels a unit has and send a hint * to a client. Runs on the server. * - * Argument: + * Arguments: * 0: Target unit of the hint * 1: Unit that has the spare barrels * - * Return value: + * Return Value: * None * * diff --git a/addons/overheating/functions/fnc_swapBarrel.sqf b/addons/overheating/functions/fnc_swapBarrel.sqf index a63ef5a36a..b904936403 100644 --- a/addons/overheating/functions/fnc_swapBarrel.sqf +++ b/addons/overheating/functions/fnc_swapBarrel.sqf @@ -2,12 +2,12 @@ * Author: Commy2 * Make a unit start swapping it's barrel * - * Argument: + * Arguments: * 0: Unit initiating the action * 1: Unit that has the weapon * 2: Weapon * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overheating/functions/fnc_swapBarrelAssistant.sqf b/addons/overheating/functions/fnc_swapBarrelAssistant.sqf index 5e3c31fc5e..30d9a3d044 100644 --- a/addons/overheating/functions/fnc_swapBarrelAssistant.sqf +++ b/addons/overheating/functions/fnc_swapBarrelAssistant.sqf @@ -2,12 +2,12 @@ * Author: esteldunedain, Commy2 * Make a unit start swapping the barrel of another unit * - * Argument: + * Arguments: * 0: Unit initiating the action * 1: Unit that has the weapon * 2: Weapon * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overheating/functions/fnc_swapBarrelCallback.sqf b/addons/overheating/functions/fnc_swapBarrelCallback.sqf index 01a0bde8ce..21b8dbdc03 100644 --- a/addons/overheating/functions/fnc_swapBarrelCallback.sqf +++ b/addons/overheating/functions/fnc_swapBarrelCallback.sqf @@ -2,12 +2,12 @@ * Author: Commy2, esteldunedain * Swap barrel callback * - * Argument: + * Arguments: * 0: Unit initiating the action * 1: Unit that has the weapon * 2: Weapon * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf index 602de01c3b..0bb240533c 100644 --- a/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf +++ b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf @@ -2,10 +2,10 @@ * Author: esteldunedain * Calculate cooldown of all the stored spare barrels. * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overheating/functions/fnc_updateTemperature.sqf b/addons/overheating/functions/fnc_updateTemperature.sqf index d5e29a150b..51b4b13ae3 100644 --- a/addons/overheating/functions/fnc_updateTemperature.sqf +++ b/addons/overheating/functions/fnc_updateTemperature.sqf @@ -2,12 +2,12 @@ * Author: esteldunedain * Update temperature of a weapon. * - * Argument: + * Arguments: * 0: Unit * 1: Weapon * 2: Heat increment (J) * - * Return value: + * Return Value: * Current temperature * * Example: diff --git a/addons/overheating/functions/fnc_updateTemperatureThread.sqf b/addons/overheating/functions/fnc_updateTemperatureThread.sqf index 476ff3e352..1d1574b1ed 100644 --- a/addons/overheating/functions/fnc_updateTemperatureThread.sqf +++ b/addons/overheating/functions/fnc_updateTemperatureThread.sqf @@ -2,10 +2,10 @@ * Author: esteldunedain * Update cooldown calculation of all player weapons at regular intervals. * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overpressure/functions/fnc_cacheOverPressureValues.sqf b/addons/overpressure/functions/fnc_cacheOverPressureValues.sqf index 273843ce8f..4b447b5012 100644 --- a/addons/overpressure/functions/fnc_cacheOverPressureValues.sqf +++ b/addons/overpressure/functions/fnc_cacheOverPressureValues.sqf @@ -3,12 +3,12 @@ * Cache the shot data for a given weapon/mag/ammo combination. * Will use the config that has the highest priority. * - * Argument: + * Arguments: * 0: Weapon * 1: Magazine * 2: Ammo * - * Return value: + * Return Value: * Shot Config : * 0: Angle * 1: Range diff --git a/addons/overpressure/functions/fnc_firedEHBB.sqf b/addons/overpressure/functions/fnc_firedEHBB.sqf index 8dc15e0f0a..fe1005ebad 100644 --- a/addons/overpressure/functions/fnc_firedEHBB.sqf +++ b/addons/overpressure/functions/fnc_firedEHBB.sqf @@ -5,7 +5,7 @@ * Arguments: * None. Parameters inherited from EFUNC(common,firedEH) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overpressure/functions/fnc_firedEHOP.sqf b/addons/overpressure/functions/fnc_firedEHOP.sqf index dff9215a52..0669077782 100644 --- a/addons/overpressure/functions/fnc_firedEHOP.sqf +++ b/addons/overpressure/functions/fnc_firedEHOP.sqf @@ -5,7 +5,7 @@ * Arguments: * None. Parameters inherited from EFUNC(common,firedEH) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/overpressure/functions/fnc_getDistance.sqf b/addons/overpressure/functions/fnc_getDistance.sqf index 616feb8660..febb4ea747 100644 --- a/addons/overpressure/functions/fnc_getDistance.sqf +++ b/addons/overpressure/functions/fnc_getDistance.sqf @@ -8,7 +8,7 @@ * 2: Max distance to search * 3: Shooter * - * Return value: + * Return Value: * Distance to intersection (999 if distance is greater than max) * * Example: diff --git a/addons/overpressure/functions/fnc_overpressureDamage.sqf b/addons/overpressure/functions/fnc_overpressureDamage.sqf index 3b8d4ea6f2..5852cf3bfd 100644 --- a/addons/overpressure/functions/fnc_overpressureDamage.sqf +++ b/addons/overpressure/functions/fnc_overpressureDamage.sqf @@ -3,7 +3,7 @@ * Calculate and apply backblast damage to potentially affected local units * Handles the "overpressure" event. * - * Argument: + * Arguments: * 0: Unit that fired * 1: Pos ASL of the projectile * 2: Direction of the projectile (reversed for launcher backblast) @@ -11,7 +11,7 @@ * 4: Magazine * 5: Ammo * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/rearm/functions/fnc_addMagazineToSupply.sqf b/addons/rearm/functions/fnc_addMagazineToSupply.sqf index f2ccae8653..55188408d1 100644 --- a/addons/rearm/functions/fnc_addMagazineToSupply.sqf +++ b/addons/rearm/functions/fnc_addMagazineToSupply.sqf @@ -2,12 +2,12 @@ * Author: GitHawk * Adds magazines to the supply. * - * Argument: + * Arguments: * 0: Ammo Truck * 1: Magazine Classname - * 2: Only partial + * 2: Only partial (optional) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/rearm/functions/fnc_addRearmActions.sqf b/addons/rearm/functions/fnc_addRearmActions.sqf index a7bf5d0171..d69c2bfee7 100644 --- a/addons/rearm/functions/fnc_addRearmActions.sqf +++ b/addons/rearm/functions/fnc_addRearmActions.sqf @@ -2,10 +2,10 @@ * Author: GitHawk * Show the resupplyable ammunition of all surrounding vehicles. * - * Argument: + * Arguments: * 0: Target * - * Return value: + * Return Value: * ChildActions * * Example: diff --git a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf index 3f38dcdc97..f5496ca343 100644 --- a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf +++ b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf @@ -2,14 +2,14 @@ * Author: GitHawk * Adds all magazines of a vehicle to the supply. * - * Argument: + * Arguments: * 0: Ammo Truck * 1: Vehicle * or * 0: Ammo Truck * 1: Vehicle class * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/rearm/functions/fnc_disable.sqf b/addons/rearm/functions/fnc_disable.sqf index 2398039595..4f7a6e81ff 100644 --- a/addons/rearm/functions/fnc_disable.sqf +++ b/addons/rearm/functions/fnc_disable.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Vehicle - * 1: Disable + * 1: Disable (optional) * * Return Value: * None diff --git a/addons/rearm/functions/fnc_dropAmmo.sqf b/addons/rearm/functions/fnc_dropAmmo.sqf index 861b5db31d..8c1336476d 100644 --- a/addons/rearm/functions/fnc_dropAmmo.sqf +++ b/addons/rearm/functions/fnc_dropAmmo.sqf @@ -4,8 +4,8 @@ * * Arguments: * 0: Unit - * 1: Delete dummy object - * 2: Unholster Weapon + * 1: Delete dummy object (optional) + * 2: Unholster Weapon (optional) * * Return Value: * None diff --git a/addons/rearm/functions/fnc_getCaliber.sqf b/addons/rearm/functions/fnc_getCaliber.sqf index fdff5a9480..7a07b9a1db 100644 --- a/addons/rearm/functions/fnc_getCaliber.sqf +++ b/addons/rearm/functions/fnc_getCaliber.sqf @@ -2,10 +2,10 @@ * Author: GitHawk * Get the caliber of the ammo in a magazine and return its parameters. * - * Argument: + * Arguments: * 0: Magazine Classname * - * Return value: + * Return Value: * 0: Caliber information * 0: Rounded caliber * 1: Caliber index diff --git a/addons/rearm/functions/fnc_getSupplyCount.sqf b/addons/rearm/functions/fnc_getSupplyCount.sqf index f53f447657..4c4cb4f81d 100644 --- a/addons/rearm/functions/fnc_getSupplyCount.sqf +++ b/addons/rearm/functions/fnc_getSupplyCount.sqf @@ -2,10 +2,10 @@ * Author: GitHawk * Get the supply count. * - * Argument: + * Arguments: * 0: Ammo Truck * - * Return value: + * Return Value: * Supply count * * Example: diff --git a/addons/rearm/functions/fnc_hasEnoughSupply.sqf b/addons/rearm/functions/fnc_hasEnoughSupply.sqf index db2814ca9e..a4f5e04217 100644 --- a/addons/rearm/functions/fnc_hasEnoughSupply.sqf +++ b/addons/rearm/functions/fnc_hasEnoughSupply.sqf @@ -2,11 +2,11 @@ * Author: GitHawk * Check whether enough supply is left to take the magazine. * - * Argument: + * Arguments: * 0: Ammo Truck * 1: Magazine Classname * - * Return value: + * Return Value: * Enough supply * * Example: diff --git a/addons/rearm/functions/fnc_magazineInSupply.sqf b/addons/rearm/functions/fnc_magazineInSupply.sqf index 2cd6f3da67..627534219e 100644 --- a/addons/rearm/functions/fnc_magazineInSupply.sqf +++ b/addons/rearm/functions/fnc_magazineInSupply.sqf @@ -2,11 +2,11 @@ * Author: GitHawk * Returns true if the magazine is in the current supply * - * Argument: + * Arguments: * 0: Ammo Truck * 1: Magazine Classname * - * Return value: + * Return Value: * Magazine in supply * * Example: @@ -38,5 +38,5 @@ if (GVAR(supply) == 2) exitWith { _magazinePresent }; -// With infinite supply, the is always one left +// With infinite supply, there is always one left true diff --git a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf index ed19bfb53f..967f6000cf 100644 --- a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf +++ b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf @@ -2,12 +2,12 @@ * Author: GitHawk * Removes a magazine from the supply. * - * Argument: + * Arguments: * 0: Ammo Truck * 1: Magazine Classname - * 2: Number of Rounds to withdraw + * 2: Number of Rounds to withdraw (optional) * - * Return value: + * Return Value: * Magazine was removed * * Example: diff --git a/addons/rearm/functions/fnc_setSupplyCount.sqf b/addons/rearm/functions/fnc_setSupplyCount.sqf index b4deea7a74..c106d0ee5a 100644 --- a/addons/rearm/functions/fnc_setSupplyCount.sqf +++ b/addons/rearm/functions/fnc_setSupplyCount.sqf @@ -2,11 +2,11 @@ * Author: GitHawk * Sets the supply count. * - * Argument: + * Arguments: * 0: Ammo Truck * 1: Supply Count * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/reload/functions/fnc_canCheckAmmo.sqf b/addons/reload/functions/fnc_canCheckAmmo.sqf index 41a46ea465..7f38e3fbfa 100644 --- a/addons/reload/functions/fnc_canCheckAmmo.sqf +++ b/addons/reload/functions/fnc_canCheckAmmo.sqf @@ -2,11 +2,11 @@ * Author: CAA-Picard * Check if the player can check the ammo of the target. * - * Argument: + * Arguments: * 0: Unit * 1: Target * - * Return value: + * Return Value: * Can link belt * * Example: diff --git a/addons/reload/functions/fnc_canLinkBelt.sqf b/addons/reload/functions/fnc_canLinkBelt.sqf index 13fad4d460..7d25b5ea22 100644 --- a/addons/reload/functions/fnc_canLinkBelt.sqf +++ b/addons/reload/functions/fnc_canLinkBelt.sqf @@ -2,11 +2,11 @@ * Author: esteldunedain * Check if the target has an MG equiped with belt system that the player can link * - * Argument: + * Arguments: * 0: Player * 1: Target * - * Return value: + * Return Value: * Can link belt */ #include "script_component.hpp" diff --git a/addons/reload/functions/fnc_checkAmmo.sqf b/addons/reload/functions/fnc_checkAmmo.sqf index 8edfd172c0..49a1f0728d 100644 --- a/addons/reload/functions/fnc_checkAmmo.sqf +++ b/addons/reload/functions/fnc_checkAmmo.sqf @@ -2,11 +2,11 @@ * Author: commy2 and esteldunedain * Count the ammo of the currently loaded magazine or count rifle grenades. Play animation and display message. * - * Argument: + * Arguments: * 0: Player * 1: Target. Optional, if not suplied the player counts his personal or static weapon ammo * - * Return value: + * Return Value: * Nothing */ #include "script_component.hpp" diff --git a/addons/reload/functions/fnc_displayAmmo.sqf b/addons/reload/functions/fnc_displayAmmo.sqf index 7fff5564c0..6aa8f013d9 100644 --- a/addons/reload/functions/fnc_displayAmmo.sqf +++ b/addons/reload/functions/fnc_displayAmmo.sqf @@ -2,10 +2,10 @@ * Author: commy2 and esteldunedain * Display the ammo of the currently loaded magazine of the target or count rifle grenades. * - * Argument: + * Arguments: * 0: Target * - * Return value: + * Return Value: * Nothing */ #include "script_component.hpp" diff --git a/addons/reload/functions/fnc_startLinkingBelt.sqf b/addons/reload/functions/fnc_startLinkingBelt.sqf index 5924e1b4e1..c39d9ffb4b 100644 --- a/addons/reload/functions/fnc_startLinkingBelt.sqf +++ b/addons/reload/functions/fnc_startLinkingBelt.sqf @@ -2,11 +2,11 @@ * Author: esteldunedain * Start linking the belt * - * Argument: + * Arguments: * 0: Player * 1: Target * - * Return value: + * Return Value: * None */ #include "script_component.hpp" diff --git a/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf b/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf index f6cd923845..6a9d779d02 100644 --- a/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf +++ b/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf @@ -2,11 +2,11 @@ * Author: commy2 * Create one action per reloadable missile * - * Argument: + * Arguments: * 1: Target (Object) * 0: Player (Object) * - * Return value: + * Return Value: * Children actions (Array) * * Public: No diff --git a/addons/reloadlaunchers/functions/fnc_canLoad.sqf b/addons/reloadlaunchers/functions/fnc_canLoad.sqf index 116a900092..5072d44a48 100644 --- a/addons/reloadlaunchers/functions/fnc_canLoad.sqf +++ b/addons/reloadlaunchers/functions/fnc_canLoad.sqf @@ -2,13 +2,13 @@ * Author: commy2 * Check of the unit can reload the launcher of target unit. * - * Argument: + * Arguments: * 0: Unit to do the reloading (Object) * 1: Unit eqipped with launcher (Object) * 2: weapon name (String) * 3: missile name (String) * - * Return value: + * Return Value: * NONE * * Public: No diff --git a/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf b/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf index f466490b64..40766a5905 100644 --- a/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf +++ b/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf @@ -2,11 +2,11 @@ * Author: commy2 * Return all magazine types from reloaders inventory that are compatible with given weapon. * - * Argument: + * Arguments: * 0: Unit to to the reload (Object) * 1: A launcher (String) * - * Return value: + * Return Value: * Reloable magazines (Array) * * Public: No diff --git a/addons/reloadlaunchers/functions/fnc_load.sqf b/addons/reloadlaunchers/functions/fnc_load.sqf index db18e7edaa..4005871a3e 100644 --- a/addons/reloadlaunchers/functions/fnc_load.sqf +++ b/addons/reloadlaunchers/functions/fnc_load.sqf @@ -2,13 +2,13 @@ * Author: commy2 * Reload a launcher * - * Argument: + * Arguments: * 0: Unit with magazine (Object) * 1: Unit with launcher (Object) * 2: weapon name (String) * 3: missile name (String) * - * Return value: + * Return Value: * NONE * * Public: No diff --git a/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf b/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf index 2aec180d22..96db7cdca5 100644 --- a/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf +++ b/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf @@ -2,13 +2,13 @@ * Author: commy2 * Reload a launcher * - * Argument: + * Arguments: * 0: Unit to do the reloading (Object) * 1: Target to rload (Object) * 2: weapon name (String) * 3: missile name (String) * - * Return value: + * Return Value: * NONE * * Public: No diff --git a/addons/scopes/functions/fnc_adjustScope.sqf b/addons/scopes/functions/fnc_adjustScope.sqf index 5b0c6d11a6..9a38ef40cb 100644 --- a/addons/scopes/functions/fnc_adjustScope.sqf +++ b/addons/scopes/functions/fnc_adjustScope.sqf @@ -2,12 +2,12 @@ * Author: KoffeinFlummi, Ruthberg * Changes the adjustment for the current scope * - * Argument: + * Arguments: * 0: Unit * 1: Turret and Direction * 2: Major Step * - * Return value: + * Return Value: * Did we adjust anything? * * Example: diff --git a/addons/scopes/functions/fnc_adjustZero.sqf b/addons/scopes/functions/fnc_adjustZero.sqf index 363407e090..9e953d0523 100644 --- a/addons/scopes/functions/fnc_adjustZero.sqf +++ b/addons/scopes/functions/fnc_adjustZero.sqf @@ -2,10 +2,10 @@ * Author: KoffeinFlummi, Ruthberg * Updates the zero reference for the current scope * - * Argument: + * Arguments: * 0: Unit * - * Return value: + * Return Value: * true * * Example: diff --git a/addons/scopes/functions/fnc_applyScopeAdjustment.sqf b/addons/scopes/functions/fnc_applyScopeAdjustment.sqf index af2f018e11..7067b0442c 100644 --- a/addons/scopes/functions/fnc_applyScopeAdjustment.sqf +++ b/addons/scopes/functions/fnc_applyScopeAdjustment.sqf @@ -2,13 +2,13 @@ * Author: KoffeinFlummi, Ruthberg * Applies the adjustment for the current scope * - * Argument: + * Arguments: * 0: Unit * 1: Absolute elevation * 2: Absolute windage * 3: Absolute zero reference * - * Return value: + * Return Value: * True * * Example: diff --git a/addons/scopes/functions/fnc_canAdjustZero.sqf b/addons/scopes/functions/fnc_canAdjustZero.sqf index 36ea4ac793..477dc12635 100644 --- a/addons/scopes/functions/fnc_canAdjustZero.sqf +++ b/addons/scopes/functions/fnc_canAdjustZero.sqf @@ -2,10 +2,10 @@ * Author: KoffeinFlummi, Ruthberg * Changes the adjustment for the current scope * - * Argument: + * Arguments: * 0: Unit * - * Return value: + * Return Value: * Can we update the zero reference? * * Example: diff --git a/addons/scopes/functions/fnc_firedEH.sqf b/addons/scopes/functions/fnc_firedEH.sqf index 07eadb5620..444b768eb5 100644 --- a/addons/scopes/functions/fnc_firedEH.sqf +++ b/addons/scopes/functions/fnc_firedEH.sqf @@ -2,10 +2,10 @@ * Author: KoffeinFlummi, esteldunedain * Adjusts the flight path of the bullet according to the zeroing. Called from the unified fired EH only for local and non-local players on foot. * - * Argument: + * Arguments: * None. Parameters inherited from EFUNC(common,firedEH) * - * Return value: + * Return Value: * None * * Public: No diff --git a/addons/spectator/functions/fnc_toggleInterface.sqf b/addons/spectator/functions/fnc_toggleInterface.sqf index 31472702fc..cbc6091ae4 100644 --- a/addons/spectator/functions/fnc_toggleInterface.sqf +++ b/addons/spectator/functions/fnc_toggleInterface.sqf @@ -4,12 +4,12 @@ * * Arguments: * 0: Display - * 1: Toogle compass - * 2: Toogle help - * 3: Toogle interface - * 4: Toogle map - * 5: Toogle toolbar - * 6: Toogle unit list + * 1: Toogle compass (optional) + * 2: Toogle help (optional) + * 3: Toogle interface (optional) + * 4: Toogle map (optional) + * 5: Toogle toolbar (optional) + * 6: Toogle unit list (optional) * * Return Value: * None diff --git a/addons/spottingscope/functions/fnc_pickup.sqf b/addons/spottingscope/functions/fnc_pickup.sqf index cdcc78bea3..1a15bd7880 100644 --- a/addons/spottingscope/functions/fnc_pickup.sqf +++ b/addons/spottingscope/functions/fnc_pickup.sqf @@ -6,7 +6,7 @@ * 0: spotting scope * 1: unit * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/spottingscope/functions/fnc_place.sqf b/addons/spottingscope/functions/fnc_place.sqf index 21560f948f..07daa51e9a 100644 --- a/addons/spottingscope/functions/fnc_place.sqf +++ b/addons/spottingscope/functions/fnc_place.sqf @@ -6,7 +6,7 @@ * 0: unit * 1: scope class * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/tripod/functions/fnc_adjust.sqf b/addons/tripod/functions/fnc_adjust.sqf index 2b8659b2a4..b12f713ace 100644 --- a/addons/tripod/functions/fnc_adjust.sqf +++ b/addons/tripod/functions/fnc_adjust.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: tripod * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/tripod/functions/fnc_pickup.sqf b/addons/tripod/functions/fnc_pickup.sqf index 9a291480ad..dc8b990515 100644 --- a/addons/tripod/functions/fnc_pickup.sqf +++ b/addons/tripod/functions/fnc_pickup.sqf @@ -6,7 +6,7 @@ * 0: unit * 1: tripod * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/tripod/functions/fnc_place.sqf b/addons/tripod/functions/fnc_place.sqf index 64dc0786e8..b4b6790ef6 100644 --- a/addons/tripod/functions/fnc_place.sqf +++ b/addons/tripod/functions/fnc_place.sqf @@ -6,7 +6,7 @@ * 0: unit * 1: tripod class * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/weather/functions/fnc_displayWindInfo.sqf b/addons/weather/functions/fnc_displayWindInfo.sqf index 5ea69c59a0..10a1e45861 100644 --- a/addons/weather/functions/fnc_displayWindInfo.sqf +++ b/addons/weather/functions/fnc_displayWindInfo.sqf @@ -2,10 +2,10 @@ * Author: Ruthberg * Displays a wind info (colored arrow) in the top left corner of the screen * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/weather/functions/fnc_getMapData.sqf b/addons/weather/functions/fnc_getMapData.sqf index e1b56f2ed2..08a6f38568 100644 --- a/addons/weather/functions/fnc_getMapData.sqf +++ b/addons/weather/functions/fnc_getMapData.sqf @@ -2,10 +2,10 @@ * Author: Ruthberg, esteldunedain * Get the weather data for the current map * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/weather/functions/fnc_getWind.sqf b/addons/weather/functions/fnc_getWind.sqf index 7c08e813e1..2d29335026 100644 --- a/addons/weather/functions/fnc_getWind.sqf +++ b/addons/weather/functions/fnc_getWind.sqf @@ -2,10 +2,10 @@ * Author: ACE2 Team, Ruthberg * Calculate current wind locally from the data broadcasted by the server * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * Wind * * Example: diff --git a/addons/weather/functions/fnc_initWind.sqf b/addons/weather/functions/fnc_initWind.sqf index ddd314c0c6..634542c1e4 100644 --- a/addons/weather/functions/fnc_initWind.sqf +++ b/addons/weather/functions/fnc_initWind.sqf @@ -2,10 +2,10 @@ * Author: Ruthberg * Inits the wind variables on mission start * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/weather/functions/fnc_serverController.sqf b/addons/weather/functions/fnc_serverController.sqf index 9791049914..79d2aab93e 100644 --- a/addons/weather/functions/fnc_serverController.sqf +++ b/addons/weather/functions/fnc_serverController.sqf @@ -2,10 +2,10 @@ * Author: Ruthberg * Gather weather parameters and broadcast them to the clients * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/weather/functions/fnc_updateAceWeather.sqf b/addons/weather/functions/fnc_updateAceWeather.sqf index 3f2f9a356c..db8783cd83 100644 --- a/addons/weather/functions/fnc_updateAceWeather.sqf +++ b/addons/weather/functions/fnc_updateAceWeather.sqf @@ -2,10 +2,10 @@ * Author: ACE2 Team, esteldunedain, ruthberg * Updates the wind and rain evolution on the server. Broadcasts the current and next values to the clients * - * Argument: + * Arguments: * None * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/weather/functions/fnc_updateHumidity.sqf b/addons/weather/functions/fnc_updateHumidity.sqf index 66a351096c..acd103615b 100644 --- a/addons/weather/functions/fnc_updateHumidity.sqf +++ b/addons/weather/functions/fnc_updateHumidity.sqf @@ -2,10 +2,10 @@ * Author: ACE2 Team * Updates GVAR(currentHumidity) * - * Argument: + * Arguments: * Nothing * - * Return value: + * Return Value: * Nothing * * Example: diff --git a/addons/weather/functions/fnc_updateRain.sqf b/addons/weather/functions/fnc_updateRain.sqf index ccacb09955..b073a6a24c 100644 --- a/addons/weather/functions/fnc_updateRain.sqf +++ b/addons/weather/functions/fnc_updateRain.sqf @@ -2,10 +2,10 @@ * Author: ACE2 Team, Ruthberg * Updates rain based on ACE_RAIN_PARAMS * - * Argument: + * Arguments: * Nothing * - * Return value: + * Return Value: * Nothing * * Example: diff --git a/addons/weather/functions/fnc_updateTemperature.sqf b/addons/weather/functions/fnc_updateTemperature.sqf index 9ff11859f4..6f2d911c15 100644 --- a/addons/weather/functions/fnc_updateTemperature.sqf +++ b/addons/weather/functions/fnc_updateTemperature.sqf @@ -2,10 +2,10 @@ * Author: ACE2 Team * Updates GVAR(currentTemperature) based on the map data * - * Argument: + * Arguments: * Nothing * - * Return value: + * Return Value: * Nothing * * Example: diff --git a/addons/weather/functions/fnc_updateWind.sqf b/addons/weather/functions/fnc_updateWind.sqf index 75724e3674..72ae0470ba 100644 --- a/addons/weather/functions/fnc_updateWind.sqf +++ b/addons/weather/functions/fnc_updateWind.sqf @@ -2,10 +2,10 @@ * Author: ACE2 Team, Ruthberg * Updates wind, gusts and waves based on ACE_wind * - * Argument: + * Arguments: * Nothing * - * Return value: + * Return Value: * Nothing * * Example: From bc90a85bcd6a402921e83802ee1ca64f9ac6fdc6 Mon Sep 17 00:00:00 2001 From: GitHawk Date: Tue, 7 Jun 2016 10:26:22 +0200 Subject: [PATCH 14/36] Improvements --- .../fnc_addVehicleMagazinesToSupply.sqf | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf index f5496ca343..6d87c81823 100644 --- a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf +++ b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf @@ -4,10 +4,7 @@ * * Arguments: * 0: Ammo Truck - * 1: Vehicle - * or - * 0: Ammo Truck - * 1: Vehicle class + * 1: Vehicle or Vehicle class * * Return Value: * None @@ -26,16 +23,12 @@ params [ ]; if (isNull _truck || - {typeName _vehicle == "OBJECT" && {isNull _vehicle}}) exitWith {}; + {_vehicle isEqualType objNull}) exitWith {}; -private _string = ""; -if (typeName _vehicle == "OBJECT") then { - _string = typeOf _vehicle; +private _string = [_vehicle, typeOf _vehicle] select (_vehicle isEqualType objNull); +if (_string == "") exitWith { + ACE_ERRORFORMAT("_string is empty in ace_rearm_fnc_addVehicleMagazinesToSupply"); }; -if (typeName _vehicle == "STRING") then { - _string = _vehicle; -}; -if (_string == "") exitWith {}; { private _turretPath = _x; private _magazines = [_string, _turretPath] call FUNC(getConfigMagazines); From 8e004741b92ed4a0b92a15d76645485071a0a8e7 Mon Sep 17 00:00:00 2001 From: GitHawk Date: Tue, 7 Jun 2016 11:13:42 +0200 Subject: [PATCH 15/36] Cleanup --- README.md | 10 +- .../fnc_getChildrenAttachActions.sqf | 2 +- .../functions/fnc_canStopEscorting.sqf | 1 + addons/cargo/functions/fnc_canUnloadItem.sqf | 2 +- .../functions/fnc_displayTextStructured.sqf | 2 +- addons/common/functions/fnc_dumpArray.sqf | 2 +- .../functions/fnc_findUnloadPosition.sqf | 6 +- addons/common/functions/fnc_showHud.sqf | 4 +- .../functions/fnc_unloadPersonLocal.sqf | 2 +- .../functions/fnc_disarmDropItems.sqf | 2 +- addons/hearing/functions/fnc_updateVolume.sqf | 2 +- .../functions/fnc_createAction.sqf | 12 +- .../microdagr/functions/fnc_openDisplay.sqf | 2 +- .../functions/fnc_loadMagazineTimer.sqf | 2 +- addons/rearm/CfgVehicles.hpp | 4 +- optionals/compat_adr_97/$PBOPREFIX$ | 1 + optionals/compat_adr_97/CfgAmmo.hpp | 14 ++ optionals/compat_adr_97/CfgMagazines.hpp | 7 + optionals/compat_adr_97/CfgWeapons.hpp | 67 ++++++ optionals/compat_adr_97/config.cpp | 18 ++ optionals/compat_adr_97/script_component.hpp | 5 + optionals/compat_adr_97/stringtable.xml | 221 ++++++++++++++++++ optionals/compat_r3f/config.cpp | 4 +- optionals/compat_rh_acc/config.cpp | 4 +- optionals/compat_rh_de/config.cpp | 4 +- optionals/compat_rh_m4/config.cpp | 4 +- optionals/compat_rh_pdw/config.cpp | 4 +- optionals/compat_rhs_afrf3/CfgAmmo.hpp | 18 +- .../compat_rhs_afrf3/CfgEventHandlers.hpp | 11 + optionals/compat_rhs_afrf3/CfgVehicles.hpp | 56 ++++- optionals/compat_rhs_afrf3/XEH_PREP.hpp | 2 + optionals/compat_rhs_afrf3/XEH_preInit.sqf | 7 + optionals/compat_rhs_afrf3/XEH_preStart.sqf | 3 + optionals/compat_rhs_afrf3/config.cpp | 5 +- .../compat_rhs_afrf3/functions/fnc_onCut.sqf | 23 ++ .../functions/fnc_onPrepare.sqf | 23 ++ .../functions/script_component.hpp | 1 + .../compat_rhs_afrf3/script_component.hpp | 2 +- optionals/compat_rhs_usf3/CfgAmmo.hpp | 3 +- .../compat_rhs_usf3/CfgEventHandlers.hpp | 11 + optionals/compat_rhs_usf3/CfgVehicles.hpp | 115 ++++++++- optionals/compat_rhs_usf3/CfgWeapons.hpp | 4 +- optionals/compat_rhs_usf3/XEH_PREP.hpp | 3 + optionals/compat_rhs_usf3/XEH_preInit.sqf | 7 + optionals/compat_rhs_usf3/XEH_preStart.sqf | 3 + optionals/compat_rhs_usf3/config.cpp | 5 +- .../functions/fnc_canCloseDoor.sqf | 30 +++ .../compat_rhs_usf3/functions/fnc_onCut.sqf | 36 +++ .../functions/fnc_onPrepare.sqf | 38 +++ .../functions/script_component.hpp | 1 + .../compat_rhs_usf3/script_component.hpp | 2 +- optionals/compat_rksl_pm_ii/config.cpp | 4 +- optionals/compat_sma3_iansky/config.cpp | 4 +- optionals/noactionmenu/config.cpp | 5 +- optionals/server/config.cpp | 5 +- optionals/tracers/config.cpp | 5 +- tools/config_style_checker.py | 157 +++++++++++++ tools/setup.py | 18 +- tools/sqf_validator.py | 6 +- 59 files changed, 954 insertions(+), 67 deletions(-) create mode 100644 optionals/compat_adr_97/$PBOPREFIX$ create mode 100644 optionals/compat_adr_97/CfgAmmo.hpp create mode 100644 optionals/compat_adr_97/CfgMagazines.hpp create mode 100644 optionals/compat_adr_97/CfgWeapons.hpp create mode 100644 optionals/compat_adr_97/config.cpp create mode 100644 optionals/compat_adr_97/script_component.hpp create mode 100644 optionals/compat_adr_97/stringtable.xml create mode 100644 optionals/compat_rhs_afrf3/CfgEventHandlers.hpp create mode 100644 optionals/compat_rhs_afrf3/XEH_PREP.hpp create mode 100644 optionals/compat_rhs_afrf3/XEH_preInit.sqf create mode 100644 optionals/compat_rhs_afrf3/XEH_preStart.sqf create mode 100644 optionals/compat_rhs_afrf3/functions/fnc_onCut.sqf create mode 100644 optionals/compat_rhs_afrf3/functions/fnc_onPrepare.sqf create mode 100644 optionals/compat_rhs_afrf3/functions/script_component.hpp create mode 100644 optionals/compat_rhs_usf3/CfgEventHandlers.hpp create mode 100644 optionals/compat_rhs_usf3/XEH_PREP.hpp create mode 100644 optionals/compat_rhs_usf3/XEH_preInit.sqf create mode 100644 optionals/compat_rhs_usf3/XEH_preStart.sqf create mode 100644 optionals/compat_rhs_usf3/functions/fnc_canCloseDoor.sqf create mode 100644 optionals/compat_rhs_usf3/functions/fnc_onCut.sqf create mode 100644 optionals/compat_rhs_usf3/functions/fnc_onPrepare.sqf create mode 100644 optionals/compat_rhs_usf3/functions/script_component.hpp create mode 100644 tools/config_style_checker.py diff --git a/README.md b/README.md index f91634f6d4..37b5f2a626 100644 --- a/README.md +++ b/README.md @@ -3,15 +3,15 @@

- - ACE3 Version - - - ACE3 Download + + ACE3 Version ACE3 Issues + + ACE3 Downloads + BIF Thread diff --git a/addons/attach/functions/fnc_getChildrenAttachActions.sqf b/addons/attach/functions/fnc_getChildrenAttachActions.sqf index 0b2e4e705c..a903250b05 100644 --- a/addons/attach/functions/fnc_getChildrenAttachActions.sqf +++ b/addons/attach/functions/fnc_getChildrenAttachActions.sqf @@ -8,7 +8,7 @@ * 1: Player * * Return Value: - * ChildActiosn + * ChildActions * * Example: * [player, player] call ace_attach_fnc_getChildrenAttachActions diff --git a/addons/captives/functions/fnc_canStopEscorting.sqf b/addons/captives/functions/fnc_canStopEscorting.sqf index 28b018491b..3ecaffecab 100644 --- a/addons/captives/functions/fnc_canStopEscorting.sqf +++ b/addons/captives/functions/fnc_canStopEscorting.sqf @@ -4,6 +4,7 @@ * * Arguments: * 0: caller (player) + * 1: target (optional) * * Return Value: * The return value diff --git a/addons/cargo/functions/fnc_canUnloadItem.sqf b/addons/cargo/functions/fnc_canUnloadItem.sqf index be14f71a76..da8ced5557 100644 --- a/addons/cargo/functions/fnc_canUnloadItem.sqf +++ b/addons/cargo/functions/fnc_canUnloadItem.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: loaded Object * 1: Object - * 2: Unloader (player) (optional) + * 2: Unloader (player) (optional) * * Return Value: * Can be unloaded diff --git a/addons/common/functions/fnc_displayTextStructured.sqf b/addons/common/functions/fnc_displayTextStructured.sqf index 5d42f00875..3037a218cc 100644 --- a/addons/common/functions/fnc_displayTextStructured.sqf +++ b/addons/common/functions/fnc_displayTextStructured.sqf @@ -6,7 +6,7 @@ * 0: Text * 1: Size of the textbox (default: 1.5) * 2: Target Unit. Will only display if target is the player controlled object (default: ACE_player) - * 3: Custom Width (optional) + * 3: Custom Width (optional) * * Return Value: * None diff --git a/addons/common/functions/fnc_dumpArray.sqf b/addons/common/functions/fnc_dumpArray.sqf index b60cede087..4fd26ef099 100644 --- a/addons/common/functions/fnc_dumpArray.sqf +++ b/addons/common/functions/fnc_dumpArray.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Array to be dumped - * 1: Depth (optional) + * 1: Depth (optional) * * Return Value: * None diff --git a/addons/common/functions/fnc_findUnloadPosition.sqf b/addons/common/functions/fnc_findUnloadPosition.sqf index dbb554d6d3..7433873b0b 100644 --- a/addons/common/functions/fnc_findUnloadPosition.sqf +++ b/addons/common/functions/fnc_findUnloadPosition.sqf @@ -6,9 +6,9 @@ * Arguments: * 0: Source Vehicle * 1: Cargo Classname - * 2: Unloader (player) (optional) - * 3: Max Distance (meters) (optional) - * 4: Check Vehicle is Stable (optional) + * 2: Unloader (player) (optional) + * 3: Max Distance (meters) (optional) + * 4: Check Vehicle is Stable (optional) * * Return Value: * Unload PositionAGL (Can Be [] if no valid pos found) diff --git a/addons/common/functions/fnc_showHud.sqf b/addons/common/functions/fnc_showHud.sqf index a79636ed16..23d7e9638e 100644 --- a/addons/common/functions/fnc_showHud.sqf +++ b/addons/common/functions/fnc_showHud.sqf @@ -4,8 +4,8 @@ * Bitwise AND Logic (a single false in a mask will make it false) * * Arguments: - * 0: Source ID (optional) - * 1: Show Hud Bool Array (8 to set, empty to remove) (optional) + * 0: Source ID (optional) + * 1: Show Hud Bool Array (8 to set, empty to remove) (optional) * - [hud, info, radar, compass, direction, menu, group, cursors] * - hud: Boolean - show scripted HUD (same as normal showHUD true/false) * - info: Boolean - show vehicle + soldier info (hides weapon info from the HUD as well) diff --git a/addons/common/functions/fnc_unloadPersonLocal.sqf b/addons/common/functions/fnc_unloadPersonLocal.sqf index 280c9875d7..9c7d73c154 100644 --- a/addons/common/functions/fnc_unloadPersonLocal.sqf +++ b/addons/common/functions/fnc_unloadPersonLocal.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: unit to unload * 1: Vehicle - * 2: Unloader (player) (optional) + * 2: Unloader (player) (optional) * * Return Value: * Returns true if succesfully unloaded person diff --git a/addons/disarming/functions/fnc_disarmDropItems.sqf b/addons/disarming/functions/fnc_disarmDropItems.sqf index 9e9829dd0f..d063d4bcd3 100644 --- a/addons/disarming/functions/fnc_disarmDropItems.sqf +++ b/addons/disarming/functions/fnc_disarmDropItems.sqf @@ -7,7 +7,7 @@ * 0: caller (player) * 1: target * 2: classnamess - * 3: Do Not Drop Ammo (optional) + * 3: Do Not Drop Ammo (optional) * * Return Value: * Nothing diff --git a/addons/hearing/functions/fnc_updateVolume.sqf b/addons/hearing/functions/fnc_updateVolume.sqf index af0483ae9c..aa2181ade0 100644 --- a/addons/hearing/functions/fnc_updateVolume.sqf +++ b/addons/hearing/functions/fnc_updateVolume.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Args - * -----0: Just update volume (skip ringing/recovery) (optional) + * -----0: Just update volume (skip ringing/recovery) (optional) * * Return Value: * None diff --git a/addons/interact_menu/functions/fnc_createAction.sqf b/addons/interact_menu/functions/fnc_createAction.sqf index b7616b9718..9d86f81d16 100644 --- a/addons/interact_menu/functions/fnc_createAction.sqf +++ b/addons/interact_menu/functions/fnc_createAction.sqf @@ -9,12 +9,12 @@ * 2: Icon * 3: Statement * 4: Condition - * 5: Insert children code (Optional) - * 6: Action parameters (Optional) - * 7: Position (Position array, Position code or Selection Name) , or (Optional) - * 8: Distance (Optional) - * 9: Other parameters [showDisabled,enableInside,canCollapse,runOnHover,doNotCheckLOS] (Optional) - * 10: Modifier function (Optional) + * 5: Insert children code (optional) + * 6: Action parameters (optional) + * 7: Position (Position array, Position code or Selection Name) , or (optional) + * 8: Distance (optional) + * 9: Other parameters [showDisabled,enableInside,canCollapse,runOnHover,doNotCheckLOS] (optional) + * 10: Modifier function (optional) * * Return Value: * Action diff --git a/addons/microdagr/functions/fnc_openDisplay.sqf b/addons/microdagr/functions/fnc_openDisplay.sqf index 21ddf884c6..90aeabdb78 100644 --- a/addons/microdagr/functions/fnc_openDisplay.sqf +++ b/addons/microdagr/functions/fnc_openDisplay.sqf @@ -3,7 +3,7 @@ * Changes the display mode of the microDAGR * * Arguments: - * 0: Display Mode to show the microDAGR in (optional) + * 0: Display Mode to show the microDAGR in (optional) * * Return Value: * None diff --git a/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf b/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf index 5116a44d71..866aea6206 100644 --- a/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf +++ b/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf @@ -6,7 +6,7 @@ * 0: static * 1: unit * 2: time to load - * 3: magazineClassOptional (optional) + * 3: magazineClassOptional (optional) * * Return Value: * None diff --git a/addons/rearm/CfgVehicles.hpp b/addons/rearm/CfgVehicles.hpp index 2da86c27fc..b02d9a280f 100644 --- a/addons/rearm/CfgVehicles.hpp +++ b/addons/rearm/CfgVehicles.hpp @@ -14,8 +14,8 @@ }; #define MACRO_REARM_TRUCK_ACTIONS \ - class ACE_Actions : ACE_Actions { \ - class ACE_MainActions : ACE_MainActions { \ + class ACE_Actions: ACE_Actions { \ + class ACE_MainActions: ACE_MainActions { \ class GVAR(ReadSupplyCounter) { \ displayName = CSTRING(ReadSupplyCounter); \ distance = REARM_ACTION_DISTANCE; \ diff --git a/optionals/compat_adr_97/$PBOPREFIX$ b/optionals/compat_adr_97/$PBOPREFIX$ new file mode 100644 index 0000000000..55c01af3d5 --- /dev/null +++ b/optionals/compat_adr_97/$PBOPREFIX$ @@ -0,0 +1 @@ +z\ace\addons\compat_adr_90 \ No newline at end of file diff --git a/optionals/compat_adr_97/CfgAmmo.hpp b/optionals/compat_adr_97/CfgAmmo.hpp new file mode 100644 index 0000000000..32d4deb076 --- /dev/null +++ b/optionals/compat_adr_97/CfgAmmo.hpp @@ -0,0 +1,14 @@ +class CfgAmmo { + class BulletBase; + class B_570x28_Ball: BulletBase { + ACE_caliber = 5.7; + ACE_bulletLength = 21.6; // http://blog.thejustnation.org/2011/04/5-7x28mm-ammo-review/ + ACE_bulletMass = 2; // based on the SS190 + ACE_ballisticCoefficients[] = {0.177}; //http://m.delphiforums.com/autogun/messages/5267/7 + ACE_velocityBoundaries[] = {}; + ACE_standardAtmosphere = "ASM"; // 50/50 chance to get it right + ACE_dragModel = 7; + ACE_muzzleVelocities[] = {716,776}; + ACE_barrelLengths[] = {264,407}; + }; +}; diff --git a/optionals/compat_adr_97/CfgMagazines.hpp b/optionals/compat_adr_97/CfgMagazines.hpp new file mode 100644 index 0000000000..fe88f128fd --- /dev/null +++ b/optionals/compat_adr_97/CfgMagazines.hpp @@ -0,0 +1,7 @@ +class CfgMagazines { + class CA_Magazine; + class 50Rnd_570x28_SMG_03: CA_Magazine { + displayName = CSTRING(P90_Mag_Name); + descriptionShort = CSTRING(P90_Mag_DescriptionShort); + }; +}; \ No newline at end of file diff --git a/optionals/compat_adr_97/CfgWeapons.hpp b/optionals/compat_adr_97/CfgWeapons.hpp new file mode 100644 index 0000000000..d77dcf562e --- /dev/null +++ b/optionals/compat_adr_97/CfgWeapons.hpp @@ -0,0 +1,67 @@ +class CfgWeapons { + + class Rifle_Base_F; + class SMG_03_TR_BASE: Rifle_Base_F { + ACE_barrelTwist = 228.6; // 1:9 inch twist + ACE_barrelLenght = 407; + ACE_twistDirection = 1; + modes[]= { + "Single" + }; + }; + class SMG_03_TR_black: SMG_03_TR_BASE{ + displayName = CSTRING(PS90_TR_Black_Name); + }; + class SMG_03_TR_khaki: SMG_03_TR_black { + displayName = CSTRING(PS90_TR_Khaki_Name); + }; + class SMG_03_TR_camo: SMG_03_TR_black { + displayName = CSTRING(PS90_TR_Camo_Name); + }; + class SMG_03_TR_hex: SMG_03_TR_BASE { + displayName = CSTRING(PS90_TR_Hex_Name); + }; + class SMG_03_black: SMG_03_TR_BASE { + displayName = CSTRING(PS90_Black_Name); + }; + class SMG_03_khaki: SMG_03_black { + displayName = CSTRING(PS90_Khaki_Name); + }; + class SMG_03_camo: SMG_03_black { + displayName = CSTRING(PS90_Camo_Name); + }; + class SMG_03_hex: SMG_03_black { + displayName = CSTRING(PS90_Hex_Name); + }; + class SMG_03C_BASE: SMG_03_TR_BASE { + ACE_barrelLenght = 264; + modes[]= { + "Single", + "FullAuto" + }; + }; + class SMG_03C_TR_black: SMG_03C_BASE { + displayName = CSTRING(P90_TR_Black_Name); + }; + class SMG_03C_TR_khaki: SMG_03C_TR_black { + displayName = CSTRING(P90_TR_Khaki_Name); + }; + class SMG_03C_TR_camo: SMG_03C_TR_black { + displayName = CSTRING(P90_TR_Camo_Name); + }; + class SMG_03C_TR_hex: SMG_03C_TR_black { + displayName = CSTRING(P90_TR_Hex_Name); + }; + class SMG_03C_black: SMG_03C_Base { + displayName = CSTRING(P90_Black_Name); + }; + class SMG_03C_khaki: SMG_03C_black { + displayName = CSTRING(P90_Khaki_Name); + }; + class SMG_03C_camo: SMG_03C_black { + displayName = CSTRING(P90_Camo_Name); + }; + class SMG_03C_hex: SMG_03C_black { + displayName = CSTRING(P90_Hex_Name); + }; +}; diff --git a/optionals/compat_adr_97/config.cpp b/optionals/compat_adr_97/config.cpp new file mode 100644 index 0000000000..aca323c98c --- /dev/null +++ b/optionals/compat_adr_97/config.cpp @@ -0,0 +1,18 @@ +#include "script_component.hpp" + +class CfgPatches { + class ADDON { + units[] = {}; + weapons[] = {}; + requiredVersion = REQUIRED_VERSION; + requiredAddons[] = {"A3_Weapons_F_Mod"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Nic547"}; + url = ECSTRING(main,URL); + VERSION_CONFIG; + }; +}; + +#include "CfgWeapons.hpp" +#include "CfgAmmo.hpp" +#include "CfgMagazines.hpp" diff --git a/optionals/compat_adr_97/script_component.hpp b/optionals/compat_adr_97/script_component.hpp new file mode 100644 index 0000000000..4b2da4eadb --- /dev/null +++ b/optionals/compat_adr_97/script_component.hpp @@ -0,0 +1,5 @@ +#define COMPONENT compat_adr_97 + +#include "\z\ace\addons\main\script_mod.hpp" + +#include "\z\ace\addons\main\script_macros.hpp" diff --git a/optionals/compat_adr_97/stringtable.xml b/optionals/compat_adr_97/stringtable.xml new file mode 100644 index 0000000000..bd91b18fa3 --- /dev/null +++ b/optionals/compat_adr_97/stringtable.xml @@ -0,0 +1,221 @@ + + + + + P90 TR (Black) + P90 TR (Černá) + P90 TR (Noir) + P90 TR (Negro) + P90 TR (Чёрный) + P90 TR (czarny) + P90 TR (Schwarz) + P90 TR (Nero) + P90 TR (Fekete) + P90 TR (Preto) + + + P90 TR (Khaki) + P90 TR (Khaki) + P90 TR (Kaki) + P90 TR (Caqui) + P90 TR (Хаки) + P90 TR (khaki) + P90 TR (Khaki) + P90 TR (Khaki) + P90 TR (Khaki) + P90 TR (Caqui) + + + P90 TR (Camo) + P90 TR (Kamufláž) + P90 TR (Camo) + P90 TR (Camuflaje) + P90 TR (Камо) + P90 TR (kamuflaż) + P90 TR (Camo) + P90 TR (Camo) + P90 TR (Terepmintás) + P90 TR (Camuflagem) + + + P90 TR (Hex) + P90 TR (Hex) + P90 TR (Hex) + P90 TR (Hex) + P90 TR (Гекс) + P90 TR (Hex) + P90 TR (hex) + P90 TR (Hex) + P90 TR (Hex) + P90 TR (Hex) + + + P90 (Black) + P90 (Černá) + P90 (Noir) + P90 (Negro) + P90 (Чёрный) + P90 (czarny) + P90 (Schwarz) + P90 (Nero) + P90 (Fekete) + P90 (Preto) + + + P90 (Khaki) + P90 (Khaki) + P90 (Kaki) + P90 (Caqui) + P90 (Хаки) + P90 (khaki) + P90 (Khaki) + P90 (Khaki) + P90 (Khaki) + P90 (Caqui) + + + P90 (Camo) + P90 (Kamufláž) + P90 (Camo) + P90 (Camuflaje) + P90 (Камо) + P90 (kamuflaż) + P90 (Camo) + P90 (Camo) + P90 (Terepmintás) + P90 (Camuflagem) + + + P90 (Hex) + P90 (Hex) + P90 (Hex) + P90 (Hex) + P90 (Гекс) + P90 (Hex) + P90 (hex) + P90 (Hex) + P90 (Hex) + P90 (Hex) + + + PS90 TR (Black) + PS90 TR (Černá) + PS90 TR (Noir) + PS90 TR (Negro) + PS90 TR (Чёрный) + PS90 TR (czarny) + PS90 TR (Schwarz) + PS90 TR (Nero) + PS90 TR (Fekete) + PS90 TR (Preto) + + + PS90 TR (Khaki) + PS90 TR (Khaki) + PS90 TR (Kaki) + PS90 TR (Caqui) + PS90 TR (Хаки) + PS90 TR (khaki) + PS90 TR (Khaki) + PS90 TR (Khaki) + PS90 TR (Khaki) + PS90 TR (Caqui) + + + PS90 TR (Camo) + PS90 TR (Kamufláž) + PS90 TR (Camo) + PS90 TR (Camuflaje) + PS90 TR (Камо) + PS90 TR (kamuflaż) + PS90 TR (Camo) + PS90 TR (Camo) + PS90 TR (Terepmintás) + PS90 TR (Camuflagem) + + + PS90 TR (Hex) + PS90 TR (Hex) + PS90 TR (Hex) + PS90 TR (Hex) + PS90 TR (Гекс) + PS90 TR (Hex) + PS90 TR (hex) + PS90 TR (Hex) + PS90 TR (Hex) + PS90 TR (Hex) + + + PS90 (Black) + PS90 (Černá) + PS90 (Noir) + PS90 (Negro) + PS90 (Чёрный) + PS90 (czarny) + PS90 (Schwarz) + PS90 (Nero) + PS90 (Fekete) + PS90 (Preto) + + + PS90 (Khaki) + PS90 (Khaki) + PS90 (Kaki) + PS90 (Caqui) + PS90 (Хаки) + PS90 (khaki) + PS90 (Khaki) + PS90 (Khaki) + PS90 (Khaki) + PS90 (Caqui) + + + PS90 (Camo) + PS90 (Kamufláž) + PS90 (Camo) + PS90 (Camuflaje) + PS90 (Камо) + PS90 (kamuflaż) + PS90 (Camo) + PS90 (Camo) + PS90 (Terepmintás) + PS90 (Camuflagem) + + + PS90 (Hex) + PS90 (Hex) + PS90 (Hex) + PS90 (Hex) + PS90 (Гекс) + PS90 (Hex) + PS90 (hex) + PS90 (Hex) + PS90 (Hex) + PS90 (Hex) + + + 5.7mm 50Rnd Mag + 5,7mm 50-as Tár + 5,7mm 50-Patronen-Magazin + Cargador de 50 balas SD de 5,7mm + Ch. 5,7mm 50Cps + Magazynek 5,7mm 50rd + 5.7mm 50náb. Zásobník + Carregador de 50 projéteis de 5.7mm + Caricatore 5.7mm 50Rnd + Магазин из 50-ти 5,7 мм + + + Caliber: 5.7mm<br />Rounds: 50<br />Used in: P90 + Kaliber: 5,7mm<br />Patronen: 50<br />Eingesetzt von: P90 + Kaliber: 5,7mm<br />Pociski: 50<br />Używany w: P90 + Calibre: 5.7mm<br />Cartouches: 50<br />Utilisé avec: P90 + Calibre: 5.7mm<br />Balas: 50<br />Se usa en: P90 + Калибр: 5,7 мм<br />Патронов: 50<br />Используются с: P90 + Calibro: 5.7mm<br />Munizioni: 50<br />In uso su: P90 + Ráže: 5.7mm<br />Nábojů: 50<br />Použití u: P90 + Calibre: 5.7mm<br />Cartuchos: 50<br />Usado em: P90 + Kaliber: 5,7mm<br />Lövedékek: 50<br />Használható: P90 + + + diff --git a/optionals/compat_r3f/config.cpp b/optionals/compat_r3f/config.cpp index d5dbc8e68c..c7e42c35ad 100644 --- a/optionals/compat_r3f/config.cpp +++ b/optionals/compat_r3f/config.cpp @@ -6,7 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"R3F_Armes", "R3F_Acc"}; - author[]={"Ruthberg"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/compat_rh_acc/config.cpp b/optionals/compat_rh_acc/config.cpp index 9f563bd157..b66be68593 100644 --- a/optionals/compat_rh_acc/config.cpp +++ b/optionals/compat_rh_acc/config.cpp @@ -6,7 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"RH_acc"}; - author[]={"Ruthberg"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/compat_rh_de/config.cpp b/optionals/compat_rh_de/config.cpp index 3d82eab05a..77dc828105 100644 --- a/optionals/compat_rh_de/config.cpp +++ b/optionals/compat_rh_de/config.cpp @@ -6,7 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"RH_de_cfg"}; - author[]={"Ruthberg"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/compat_rh_m4/config.cpp b/optionals/compat_rh_m4/config.cpp index 9c28be4f89..4bacb9dedf 100644 --- a/optionals/compat_rh_m4/config.cpp +++ b/optionals/compat_rh_m4/config.cpp @@ -6,7 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"RH_m4_cfg"}; - author[]={"Ruthberg"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/compat_rh_pdw/config.cpp b/optionals/compat_rh_pdw/config.cpp index 4aed0e6241..e3c5d15a07 100644 --- a/optionals/compat_rh_pdw/config.cpp +++ b/optionals/compat_rh_pdw/config.cpp @@ -6,7 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"RH_PDW"}; - author[]={"Ruthberg"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/compat_rhs_afrf3/CfgAmmo.hpp b/optionals/compat_rhs_afrf3/CfgAmmo.hpp index ead78866c1..0ab559f96c 100644 --- a/optionals/compat_rhs_afrf3/CfgAmmo.hpp +++ b/optionals/compat_rhs_afrf3/CfgAmmo.hpp @@ -39,7 +39,7 @@ class CfgAmmo { ACE_muzzleVelocities[]={700, 800, 820, 833}; ACE_barrelLengths[]={406.4, 508.0, 609.6, 660.4}; }; - class rhs_B_762x54_Ball_Tracer_Green: B_762x51_Ball { + class rhs_B_762x54_Ball_Tracer_Green: rhs_B_762x54_Ball { ACE_caliber=7.925; ACE_bulletLength=28.956; ACE_bulletMass=9.6552; @@ -202,4 +202,20 @@ class CfgAmmo { ace_frag_skip = 1; ace_frag_force = 0; }; + + class G_40mm_HE; + class rhs_g_vog25: G_40mm_HE {}; + class rhs_g_vg40tb: rhs_g_vog25 { //Thermobaric + ace_frag_force = 0; + }; + class rhs_g_vg40sz: rhs_g_vog25 { //Flashbang + ace_frag_force = 0; + }; + class rhs_GDM40: rhs_g_vog25 { //Smoke + ace_frag_force = 0; + }; + class rhs_g_vg40md_white: rhs_g_vog25 { //Smoke + ace_frag_force = 0; + }; + }; diff --git a/optionals/compat_rhs_afrf3/CfgEventHandlers.hpp b/optionals/compat_rhs_afrf3/CfgEventHandlers.hpp new file mode 100644 index 0000000000..93e3311cf2 --- /dev/null +++ b/optionals/compat_rhs_afrf3/CfgEventHandlers.hpp @@ -0,0 +1,11 @@ +class Extended_PreStart_EventHandlers { + class ADDON { + init = QUOTE(call COMPILE_FILE(XEH_preStart)); + }; +}; + +class Extended_PreInit_EventHandlers { + class ADDON { + init = QUOTE(call COMPILE_FILE(XEH_preInit)); + }; +}; diff --git a/optionals/compat_rhs_afrf3/CfgVehicles.hpp b/optionals/compat_rhs_afrf3/CfgVehicles.hpp index d0486ecd0e..34effc0a58 100644 --- a/optionals/compat_rhs_afrf3/CfgVehicles.hpp +++ b/optionals/compat_rhs_afrf3/CfgVehicles.hpp @@ -1,4 +1,4 @@ -class cfgVehicles { +class CfgVehicles { class LandVehicle; class Tank: LandVehicle { class NewTurret; @@ -201,18 +201,70 @@ class cfgVehicles { EGVAR(refuel,fuelCapacity) = 3600; }; - class Heli_Light_02_base_F; + class Helicopter_Base_F; + class Helicopter_Base_H: Helicopter_Base_F { + class EventHandlers; + }; + class Heli_Light_02_base_F: Helicopter_Base_H {}; class RHS_Mi8_base : Heli_Light_02_base_F { EGVAR(refuel,fuelCapacity) = 3700; + EGVAR(fastroping,enabled) = 0; + class EventHandlers: EventHandlers { + class RHS_EventHandlers; + }; + }; + + class RHS_Mi8amt_base: RHS_Mi8_base { + EGVAR(fastroping,enabled) = 1; + EGVAR(fastroping,ropeOrigins)[] = {{-1.13, 4.67, -0.89}}; + EGVAR(fastroping,onCut) = QFUNC(onCut); + EGVAR(fastroping,onPrepare) = QFUNC(onPrepare); + + class UserActions { + class openDoor; + class closeDoor_L: openDoor { + condition = QUOTE((this doorPhase 'LeftDoor' > 0.5) && {alive this} && {!(this getVariable [ARR_2(QUOTE(QEGVAR(fastroping,doorsLocked)),false)])}); + }; + }; + + class EventHandlers: EventHandlers { + class RHS_EventHandlers: RHS_EventHandlers { + getOut = QUOTE(if !((_this select 0) getVariable [ARR_2(QUOTE(QEGVAR(fastroping,doorsLocked)),false)]) then {_this call rhs_fnc_mi8_doors}); + }; + }; + }; + + class RHS_Mi8_VVS_Base: RHS_Mi8_base {}; + class RHS_Mi8mt_vvs: RHS_Mi8_VVS_Base {}; + class RHS_Mi8mt_Cargo_vvs: RHS_Mi8mt_vvs { + EGVAR(fastroping,enabled) = 1; + EGVAR(fastroping,ropeOrigins)[] = {{-1.13, 4.67, -0.89}}; + EGVAR(fastroping,onCut) = QFUNC(onCut); + EGVAR(fastroping,onPrepare) = QFUNC(onPrepare); + + class UserActions { + class openDoor_L; + class closeDoor_L: openDoor_L { + condition = QUOTE((this doorPhase 'LeftDoor' > 0.5) && {alive this} && {!(this getVariable [ARR_2(QUOTE(QEGVAR(fastroping,doorsLocked)),false)])}); + }; + }; + + class EventHandlers: EventHandlers { + class RHS_EventHandlers: RHS_EventHandlers { + getOut = QUOTE(if !((_this select 0) getVariable [ARR_2(QUOTE(QEGVAR(fastroping,doorsLocked)),false)]) then {_this call rhs_fnc_mi8_doors}); + }; + }; }; class Heli_Attack_02_base_F; class RHS_Ka52_base : Heli_Attack_02_base_F { EGVAR(refuel,fuelCapacity) = 1870; + EGVAR(fastroping,enabled) = 0; }; class RHS_Mi24_base : Heli_Attack_02_base_F { EGVAR(refuel,fuelCapacity) = 1851; + EGVAR(fastroping,enabled) = 0; }; class rhs_t80b : rhs_tank_base { diff --git a/optionals/compat_rhs_afrf3/XEH_PREP.hpp b/optionals/compat_rhs_afrf3/XEH_PREP.hpp new file mode 100644 index 0000000000..cb5a1268d9 --- /dev/null +++ b/optionals/compat_rhs_afrf3/XEH_PREP.hpp @@ -0,0 +1,2 @@ +PREP(onCut); +PREP(onPrepare); diff --git a/optionals/compat_rhs_afrf3/XEH_preInit.sqf b/optionals/compat_rhs_afrf3/XEH_preInit.sqf new file mode 100644 index 0000000000..a7feade1c3 --- /dev/null +++ b/optionals/compat_rhs_afrf3/XEH_preInit.sqf @@ -0,0 +1,7 @@ +#include "script_component.hpp" + +ADDON = false; + +#include "XEH_PREP.hpp" + +ADDON = true; diff --git a/optionals/compat_rhs_afrf3/XEH_preStart.sqf b/optionals/compat_rhs_afrf3/XEH_preStart.sqf new file mode 100644 index 0000000000..022888575e --- /dev/null +++ b/optionals/compat_rhs_afrf3/XEH_preStart.sqf @@ -0,0 +1,3 @@ +#include "script_component.hpp" + +#include "XEH_PREP.hpp" diff --git a/optionals/compat_rhs_afrf3/config.cpp b/optionals/compat_rhs_afrf3/config.cpp index 4840f8da82..bf36181ce8 100644 --- a/optionals/compat_rhs_afrf3/config.cpp +++ b/optionals/compat_rhs_afrf3/config.cpp @@ -6,12 +6,15 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"rhs_c_weapons", "rhs_c_troops", "rhs_c_bmd", "rhs_c_bmp", "rhs_c_bmp3", "rhs_c_a2port_armor", "rhs_c_btr", "rhs_c_sprut", "rhs_c_t72", "rhs_c_tanks", "rhs_c_a2port_air", "rhs_c_a2port_car", "rhs_c_cars", "rhs_c_2s3", "rhs_c_rva"}; - author[]={"Ruthberg", "GitHawk"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg", "GitHawk", "BaerMitUmlaut"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; #include "CfgAmmo.hpp" +#include "CfgEventHandlers.hpp" #include "CfgMagazines.hpp" #include "CfgWeapons.hpp" #include "CfgVehicles.hpp" diff --git a/optionals/compat_rhs_afrf3/functions/fnc_onCut.sqf b/optionals/compat_rhs_afrf3/functions/fnc_onCut.sqf new file mode 100644 index 0000000000..6a249a55c4 --- /dev/null +++ b/optionals/compat_rhs_afrf3/functions/fnc_onCut.sqf @@ -0,0 +1,23 @@ +/* + * Author: BaerMitUmlaut + * Function for closing doors and retracting the hooks for RHS USF helos. + * + * Arguments: + * 0: Helicopter + * + * Return Value: + * Amount of time to wait before cutting ropes + * + * Example: + * [_vehicle] call ace_compat_rhs_afrf3_fnc_onCut + * + * Public: No + */ + +#include "script_component.hpp" +params ["_vehicle"]; + +_vehicle setVariable [QEGVAR(fastroping,doorsLocked), false, true]; +_vehicle animateDoor ["LeftDoor", 0]; + +2 diff --git a/optionals/compat_rhs_afrf3/functions/fnc_onPrepare.sqf b/optionals/compat_rhs_afrf3/functions/fnc_onPrepare.sqf new file mode 100644 index 0000000000..8a9dc9471e --- /dev/null +++ b/optionals/compat_rhs_afrf3/functions/fnc_onPrepare.sqf @@ -0,0 +1,23 @@ +/* + * Author: BaerMitUmlaut + * Function for opening doors and extending the hook for most vanilla helos. + * + * Arguments: + * 0: Helicopter + * + * Return Value: + * Amount of time to wait before deploying ropes + * + * Example: + * [_vehicle] call ace_compat_rhs_afrf3_fnc_onPrepare + * + * Public: No + */ + +#include "script_component.hpp" +params ["_vehicle"]; + +_vehicle setVariable [QEGVAR(fastroping,doorsLocked), true, true]; +_vehicle animateDoor ["LeftDoor", 1]; + +2 diff --git a/optionals/compat_rhs_afrf3/functions/script_component.hpp b/optionals/compat_rhs_afrf3/functions/script_component.hpp new file mode 100644 index 0000000000..afabd202be --- /dev/null +++ b/optionals/compat_rhs_afrf3/functions/script_component.hpp @@ -0,0 +1 @@ +#include "\z\ace\addons\compat_rhs_afrf3\script_component.hpp" diff --git a/optionals/compat_rhs_afrf3/script_component.hpp b/optionals/compat_rhs_afrf3/script_component.hpp index edf3963b1f..307b1f8de6 100644 --- a/optionals/compat_rhs_afrf3/script_component.hpp +++ b/optionals/compat_rhs_afrf3/script_component.hpp @@ -1,4 +1,4 @@ -#define COMPONENT rhs_c_weapons_comp +#define COMPONENT compat_rhs_afrf3 #include "\z\ace\addons\main\script_mod.hpp" diff --git a/optionals/compat_rhs_usf3/CfgAmmo.hpp b/optionals/compat_rhs_usf3/CfgAmmo.hpp index b830d5e564..930976bf33 100644 --- a/optionals/compat_rhs_usf3/CfgAmmo.hpp +++ b/optionals/compat_rhs_usf3/CfgAmmo.hpp @@ -2,7 +2,8 @@ class CfgAmmo { class BulletBase; - class rhsusf_B_300winmag: BulletBase { + class B_762x54_Ball; + class rhsusf_B_300winmag: B_762x54_Ball { ACE_caliber=7.823; ACE_bulletLength=37.821; ACE_bulletMass=14.256; diff --git a/optionals/compat_rhs_usf3/CfgEventHandlers.hpp b/optionals/compat_rhs_usf3/CfgEventHandlers.hpp new file mode 100644 index 0000000000..93e3311cf2 --- /dev/null +++ b/optionals/compat_rhs_usf3/CfgEventHandlers.hpp @@ -0,0 +1,11 @@ +class Extended_PreStart_EventHandlers { + class ADDON { + init = QUOTE(call COMPILE_FILE(XEH_preStart)); + }; +}; + +class Extended_PreInit_EventHandlers { + class ADDON { + init = QUOTE(call COMPILE_FILE(XEH_preInit)); + }; +}; diff --git a/optionals/compat_rhs_usf3/CfgVehicles.hpp b/optionals/compat_rhs_usf3/CfgVehicles.hpp index 87c66f7212..2d3b28fbae 100644 --- a/optionals/compat_rhs_usf3/CfgVehicles.hpp +++ b/optionals/compat_rhs_usf3/CfgVehicles.hpp @@ -1,4 +1,17 @@ -class cfgVehicles { +#define EQUIP_FRIES_ATTRIBUTE class Attributes { \ + class EGVAR(fastroping,equipFRIES) { \ + property = QEGVAR(fastroping,equipFRIES); \ + control = "Checkbox"; \ + displayName = ECSTRING(fastroping,Eden_equipFRIES); \ + tooltip = ECSTRING(fastroping,Eden_equipFRIES_Tooltip); \ + expression = QUOTE([_this] call EFUNC(fastroping,equipFRIES)); \ + typeName = "BOOL"; \ + condition = "objectVehicle"; \ + defaultValue = false; \ + }; \ +} + +class CfgVehicles { class LandVehicle; class Tank: LandVehicle { class NewTurret; @@ -44,21 +57,117 @@ class cfgVehicles { ace_repair_hitpointGroups[] = {{"era_1_hitpoint", {"era_2_hitpoint", "era_3_hitpoint", "era_4_hitpoint", "era_5_hitpoint", "era_6_hitpoint", "era_7_hitpoint", "era_8_hitpoint", "era_9_hitpoint", "era_10_hitpoint", "era_11_hitpoint", "era_12_hitpoint", "era_13_hitpoint", "era_14_hitpoint", "era_15_hitpoint", "era_16_hitpoint", "era_17_hitpoint", "era_18_hitpoint", "era_19_hitpoint", "era_20_hitpoint", "era_21_hitpoint", "era_22_hitpoint", "era_23_hitpoint", "era_24_hitpoint", "era_25_hitpoint", "era_26_hitpoint", "era_27_hitpoint", "era_28_hitpoint", "era_29_hitpoint", "era_30_hitpoint", "era_31_hitpoint", "era_32_hitpoint", "era_33_hitpoint", "era_34_hitpoint", "era_35_hitpoint", "era_36_hitpoint", "era_37_hitpoint", "era_38_hitpoint", "era_39_hitpoint", "era_40_hitpoint", "era_41_hitpoint", "era_42_hitpoint", "era_43_hitpoint", "era_44_hitpoint", "era_45_hitpoint", "era_46_hitpoint"}}}; }; - class Heli_light_03_base_F; + class Helicopter; + class Helicopter_Base_F: Helicopter { + class Eventhandlers; + }; + class Heli_Light_03_base_F: Helicopter_Base_F {}; class RHS_UH1_Base: Heli_light_03_base_F { EGVAR(refuel,fuelCapacity) = 1447; }; - class Heli_Transport_01_base_F; + class RHS_UH1Y_base: RHS_UH1_Base {}; + class RHS_UH1Y_US_base: RHS_UH1Y_base {}; + class RHS_UH1Y: RHS_UH1Y_US_base { + EGVAR(fastroping,enabled) = 2; + EGVAR(fastroping,friesType) = "ACE_friesAnchorBar"; + EGVAR(fastroping,friesAttachmentPoint)[] = {0, 2.38, -0.135}; + EGVAR(fastroping,onCut) = QFUNC(onCut); + EGVAR(fastroping,onPrepare) = QFUNC(onPrepare); + EGVAR(fastroping,ropeOrigins)[] = {"ropeOriginLeft", "ropeOriginRight"}; + + class UserActions; + class EventHandlers: EventHandlers { + class RHSUSF_EventHandlers; + }; + + EQUIP_FRIES_ATTRIBUTE; + }; + class RHS_UH1Y_FFAR: RHS_UH1Y { + class UserActions: UserActions { + class OpenCargoDoor; + class CloseCargoDoor: OpenCargoDoor { + condition = QUOTE([ARR_2(this,'doorRB')] call FUNC(canCloseDoor)); + }; + class CloseCargoLDoor: OpenCargoDoor { + condition = QUOTE([ARR_2(this,'doorLB')] call FUNC(canCloseDoor)); + }; + }; + + class EventHandlers: EventHandlers { + class RHSUSF_EventHandlers: RHSUSF_EventHandlers { + getOut = QUOTE(if !((_this select 0) getVariable [ARR_2(QUOTE(QEGVAR(fastroping,doorsLocked)),false)]) then {_this call rhs_fnc_uh60_doors}); + }; + }; + }; + + class Helicopter_Base_H: Helicopter_Base_F { + class Eventhandlers; + }; + class Heli_Transport_01_base_F: Helicopter_Base_H {}; class RHS_UH60_Base: Heli_Transport_01_base_F { EGVAR(refuel,fuelCapacity) = 1360; }; + class RHS_UH60M_base: RHS_UH60_Base {}; + class RHS_UH60M_US_base: RHS_UH60M_base {}; + class RHS_UH60M: RHS_UH60M_US_base { + EGVAR(fastroping,enabled) = 2; + EGVAR(fastroping,friesType) = "ACE_friesAnchorBar"; + EGVAR(fastroping,friesAttachmentPoint)[] = {0, 1.25, -0.65}; + EGVAR(fastroping,onCut) = QFUNC(onCut); + EGVAR(fastroping,onPrepare) = QFUNC(onPrepare); + EGVAR(fastroping,ropeOrigins)[] = {"ropeOriginLeft", "ropeOriginRight"}; + + class UserActions { + class OpenCargoDoor; + class CloseCargoDoor: OpenCargoDoor { + condition = QUOTE([ARR_2(this,'doorRB')] call FUNC(canCloseDoor)); + }; + class CloseCargoLDoor: OpenCargoDoor { + condition = QUOTE([ARR_2(this,'doorLB')] call FUNC(canCloseDoor)); + }; + }; + class EventHandlers: EventHandlers { + class RHSUSF_EventHandlers { + getOut = QUOTE(if !((_this select 0) getVariable [ARR_2(QUOTE(QEGVAR(fastroping,doorsLocked)),false)]) then {_this call rhs_fnc_uh60_doors}); + }; + }; + + EQUIP_FRIES_ATTRIBUTE; + }; + + class RHS_UH60M_MEV: RHS_UH60M { + EGVAR(fastroping,enabled) = 0; + class Attributes { + delete EGVAR(fastroping,equipFRIES); + }; + }; + + class RHS_UH60M_MEV2: RHS_UH60M_MEV { + EGVAR(fastroping,enabled) = 2; + EQUIP_FRIES_ATTRIBUTE; + }; + class Heli_Transport_02_base_F; class RHS_CH_47F_base: Heli_Transport_02_base_F { EGVAR(refuel,fuelCapacity) = 3914; }; + class RHS_CH_47F: RHS_CH_47F_base { + EGVAR(fastroping,enabled) = 1; + EGVAR(fastroping,ropeOrigins)[] = {{0.5, -7.15, -0.95}, {-0.5, -7.15, -0.95}}; + EGVAR(fastroping,onCut) = QFUNC(onCut); + EGVAR(fastroping,onPrepare) = QFUNC(onPrepare); + + class UserActions { + class OpenCargoDoor; + class CloseCargoDoor: OpenCargoDoor { + condition = QUOTE([ARR_2(this,'ramp_anim')] call FUNC(canCloseDoor)); + }; + }; + }; + class Heli_Attack_01_base_F; class RHS_AH1Z_base: Heli_Attack_01_base_F { EGVAR(refuel,fuelCapacity) = 1600; diff --git a/optionals/compat_rhs_usf3/CfgWeapons.hpp b/optionals/compat_rhs_usf3/CfgWeapons.hpp index c49b9bc5e4..8ef39bd666 100644 --- a/optionals/compat_rhs_usf3/CfgWeapons.hpp +++ b/optionals/compat_rhs_usf3/CfgWeapons.hpp @@ -111,8 +111,8 @@ class CfgWeapons }; }; }; - class rhs_weap_m4a1; - class rhs_weap_mk18: rhs_weap_m4a1 { + class rhs_weap_m4a1_blockII; + class rhs_weap_mk18: rhs_weap_m4a1_blockII { ACE_barrelTwist = 177.8; ACE_barrelLength = 261.62; ACE_Overheating_dispersion = 1; diff --git a/optionals/compat_rhs_usf3/XEH_PREP.hpp b/optionals/compat_rhs_usf3/XEH_PREP.hpp new file mode 100644 index 0000000000..821ee657be --- /dev/null +++ b/optionals/compat_rhs_usf3/XEH_PREP.hpp @@ -0,0 +1,3 @@ +PREP(canCloseDoor); +PREP(onCut); +PREP(onPrepare); diff --git a/optionals/compat_rhs_usf3/XEH_preInit.sqf b/optionals/compat_rhs_usf3/XEH_preInit.sqf new file mode 100644 index 0000000000..a7feade1c3 --- /dev/null +++ b/optionals/compat_rhs_usf3/XEH_preInit.sqf @@ -0,0 +1,7 @@ +#include "script_component.hpp" + +ADDON = false; + +#include "XEH_PREP.hpp" + +ADDON = true; diff --git a/optionals/compat_rhs_usf3/XEH_preStart.sqf b/optionals/compat_rhs_usf3/XEH_preStart.sqf new file mode 100644 index 0000000000..022888575e --- /dev/null +++ b/optionals/compat_rhs_usf3/XEH_preStart.sqf @@ -0,0 +1,3 @@ +#include "script_component.hpp" + +#include "XEH_PREP.hpp" diff --git a/optionals/compat_rhs_usf3/config.cpp b/optionals/compat_rhs_usf3/config.cpp index ce847e969e..e218f77d2e 100644 --- a/optionals/compat_rhs_usf3/config.cpp +++ b/optionals/compat_rhs_usf3/config.cpp @@ -6,12 +6,15 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"rhsusf_c_weapons", "rhsusf_c_troops", "rhsusf_c_m1a1", "rhsusf_c_m1a2", "RHS_US_A2_AirImport", "rhsusf_c_m109", "rhsusf_c_hmmwv", "rhsusf_c_rg33", "rhsusf_c_fmtv", "rhsusf_c_m113", "RHS_US_A2Port_Armor"}; - author[]={"Ruthberg", "GitHawk"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg", "GitHawk", "BaerMitUmlaut"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; #include "CfgAmmo.hpp" +#include "CfgEventHandlers.hpp" #include "CfgMagazines.hpp" #include "CfgWeapons.hpp" #include "CfgVehicles.hpp" diff --git a/optionals/compat_rhs_usf3/functions/fnc_canCloseDoor.sqf b/optionals/compat_rhs_usf3/functions/fnc_canCloseDoor.sqf new file mode 100644 index 0000000000..61269519ed --- /dev/null +++ b/optionals/compat_rhs_usf3/functions/fnc_canCloseDoor.sqf @@ -0,0 +1,30 @@ +/* + * Author: BaerMitUmlaut + * Checks if the door can be closed. + * + * Arguments: + * 0: Helicopter + * 1: Door + * + * Return Value: + * Door can be closed + * + * Example: + * [_vehicle, "DoorLB"] call ace_compat_rhs_usf3_fnc_canCloseDoor + * + * Public: No + */ + +#include "script_component.hpp" +params ["_vehicle", "_door"]; + +(_vehicle doorPhase _door > 0) && +{alive _vehicle} && +{!(_vehicle getVariable [QEGVAR(fastroping,doorsLocked),false])} && +{ + if (_vehicle isKindOf "RHS_CH_47F") then { + ACE_player in [driver _vehicle, _vehicle turretUnit [3], _vehicle turretUnit [4]] + } else { + ACE_player in _vehicle + } +} diff --git a/optionals/compat_rhs_usf3/functions/fnc_onCut.sqf b/optionals/compat_rhs_usf3/functions/fnc_onCut.sqf new file mode 100644 index 0000000000..3663a10bd5 --- /dev/null +++ b/optionals/compat_rhs_usf3/functions/fnc_onCut.sqf @@ -0,0 +1,36 @@ +/* + * Author: BaerMitUmlaut + * Function for closing doors and retracting the hooks for RHS USF helos. + * + * Arguments: + * 0: Helicopter + * + * Return Value: + * Amount of time to wait before cutting ropes + * + * Example: + * [_vehicle] call ace_compat_rhs_usf3_fnc_onCut + * + * Public: No + */ + +#include "script_component.hpp" +params ["_vehicle"]; + +_vehicle setVariable [QEGVAR(fastroping,doorsLocked), false, true]; + +private _fries = _vehicle getVariable [QEGVAR(fastroping,FRIES), objNull]; +if !(isNull _fries) then { + _fries animate ["extendHookRight", 0]; + _fries animate ["extendHookLeft", 0]; + [{ + _this animateDoor ["doorRB", 0]; + _this animateDoor ["doorLB", 0]; + }, _vehicle, 2] call EFUNC(common,waitAndExecute); + + 4 +} else { + _vehicle animateDoor ["ramp_anim", 0]; + + 2 +}; diff --git a/optionals/compat_rhs_usf3/functions/fnc_onPrepare.sqf b/optionals/compat_rhs_usf3/functions/fnc_onPrepare.sqf new file mode 100644 index 0000000000..3e655a0aca --- /dev/null +++ b/optionals/compat_rhs_usf3/functions/fnc_onPrepare.sqf @@ -0,0 +1,38 @@ +/* + * Author: BaerMitUmlaut + * Function for opening doors and extending the hook for most vanilla helos. + * + * Arguments: + * 0: Helicopter + * + * Return Value: + * Amount of time to wait before deploying ropes + * + * Example: + * [_vehicle] call ace_compat_rhs_usf3_fnc_onPrepare + * + * Public: No + */ + +#include "script_component.hpp" +params ["_vehicle"]; +private ["_fries", "_waitTime"]; + +_vehicle setVariable [QEGVAR(fastroping,doorsLocked), true, true]; + +_waitTime = 2; + +_vehicle animateDoor ["doorRB", 1]; +_vehicle animateDoor ["doorLB", 1]; +_vehicle animateDoor ["ramp_anim", 1]; + +_fries = _vehicle getVariable [QEGVAR(fastroping,FRIES), objNull]; +if !(isNull _fries) then { + [{ + _this animate ["extendHookRight", 1]; + _this animate ["extendHookLeft", 1]; + }, _fries, 2] call EFUNC(common,waitAndExecute); + _waitTime = 4; +}; + +_waitTime diff --git a/optionals/compat_rhs_usf3/functions/script_component.hpp b/optionals/compat_rhs_usf3/functions/script_component.hpp new file mode 100644 index 0000000000..c2cdf03c81 --- /dev/null +++ b/optionals/compat_rhs_usf3/functions/script_component.hpp @@ -0,0 +1 @@ +#include "\z\ace\addons\compat_rhs_usf3\script_component.hpp" diff --git a/optionals/compat_rhs_usf3/script_component.hpp b/optionals/compat_rhs_usf3/script_component.hpp index c0a5bbf1f4..32aecef74e 100644 --- a/optionals/compat_rhs_usf3/script_component.hpp +++ b/optionals/compat_rhs_usf3/script_component.hpp @@ -1,4 +1,4 @@ -#define COMPONENT rhsusf_c_weapons_comp +#define COMPONENT compat_rhs_usf3 #include "\z\ace\addons\main\script_mod.hpp" diff --git a/optionals/compat_rksl_pm_ii/config.cpp b/optionals/compat_rksl_pm_ii/config.cpp index c3ed720f8b..ca0a7189f2 100644 --- a/optionals/compat_rksl_pm_ii/config.cpp +++ b/optionals/compat_rksl_pm_ii/config.cpp @@ -6,7 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"RKSL_PMII"}; - author[]={"Ruthberg"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/compat_sma3_iansky/config.cpp b/optionals/compat_sma3_iansky/config.cpp index 4dfda50805..5611c2d4af 100644 --- a/optionals/compat_sma3_iansky/config.cpp +++ b/optionals/compat_sma3_iansky/config.cpp @@ -6,7 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"iansky_opt"}; - author[]={"Ruthberg"}; + author = ECSTRING(common,ACETeam); + authors[] = {"Ruthberg"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/noactionmenu/config.cpp b/optionals/noactionmenu/config.cpp index 763665660b..77e0457643 100644 --- a/optionals/noactionmenu/config.cpp +++ b/optionals/noactionmenu/config.cpp @@ -7,8 +7,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"ace_common"}; - author[] = {"commy2"}; - authorUrl = "https://github.com/commy2"; + author = ECSTRING(common,ACETeam); + authors[] = {"commy2"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/server/config.cpp b/optionals/server/config.cpp index 9cfcb35012..ab354fa4d8 100644 --- a/optionals/server/config.cpp +++ b/optionals/server/config.cpp @@ -6,8 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"ace_common"}; - author[] = {"Glowbal"}; - authorUrl = "https://github.com/Glowbal/"; + author = ECSTRING(common,ACETeam); + authors[] = {"Glowbal"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/optionals/tracers/config.cpp b/optionals/tracers/config.cpp index 7ea5992f14..b2f88ca8a9 100644 --- a/optionals/tracers/config.cpp +++ b/optionals/tracers/config.cpp @@ -6,8 +6,9 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"ace_ballistics"}; - author[] = {"ACE2 Team"}; - authorUrl = "https://www.ace3mod.com"; + author = ECSTRING(common,ACETeam); + authors[] = {"ACE2 Team"}; + url = ECSTRING(main,URL); VERSION_CONFIG; }; }; diff --git a/tools/config_style_checker.py b/tools/config_style_checker.py new file mode 100644 index 0000000000..03d8f222fe --- /dev/null +++ b/tools/config_style_checker.py @@ -0,0 +1,157 @@ +#!/usr/bin/env python3 + +import fnmatch +import os +import re +import ntpath +import sys +import argparse + +def check_config_style(filepath): + bad_count_file = 0 + def pushClosing(t): + closingStack.append(closing.expr) + closing << Literal( closingFor[t[0]] ) + + def popClosing(): + closing << closingStack.pop() + + with open(filepath, 'r', encoding='utf-8', errors='ignore') as file: + content = file.read() + + # Store all brackets we find in this file, so we can validate everything on the end + brackets_list = [] + + # To check if we are in a comment block + isInCommentBlock = False + checkIfInComment = False + # Used in case we are in a line comment (//) + ignoreTillEndOfLine = False + # Used in case we are in a comment block (/* */). This is true if we detect a * inside a comment block. + # If the next character is a /, it means we end our comment block. + checkIfNextIsClosingBlock = False + + # We ignore everything inside a string + isInString = False + # Used to store the starting type of a string, so we can match that to the end of a string + inStringType = ''; + + lastIsCurlyBrace = False + checkForSemiColumn = False + + # Extra information so we know what line we find errors at + lineNumber = 1 + + indexOfCharacter = 0 + # Parse all characters in the content of this file to search for potential errors + for c in content: + if (lastIsCurlyBrace): + lastIsCurlyBrace = False + if c == '\n': # Keeping track of our line numbers + lineNumber += 1 # so we can print accurate line number information when we detect a possible error + if (isInString): # while we are in a string, we can ignore everything else, except the end of the string + if (c == inStringType): + isInString = False + # if we are not in a comment block, we will check if we are at the start of one or count the () {} and [] + elif (isInCommentBlock == False): + + # This means we have encountered a /, so we are now checking if this is an inline comment or a comment block + if (checkIfInComment): + checkIfInComment = False + if c == '*': # if the next character after / is a *, we are at the start of a comment block + isInCommentBlock = True + elif (c == '/'): # Otherwise, will check if we are in an line comment + ignoreTillEndOfLine = True # and an line comment is a / followed by another / (//) We won't care about anything that comes after it + + if (isInCommentBlock == False): + if (ignoreTillEndOfLine): # we are in a line comment, just continue going through the characters until we find an end of line + if (c == '\n'): + ignoreTillEndOfLine = False + else: # validate brackets + if (c == '"' or c == "'"): + isInString = True + inStringType = c + elif (c == '/'): + checkIfInComment = True + elif (c == '('): + brackets_list.append('(') + elif (c == ')'): + if (len(brackets_list) > 0 and brackets_list[-1] in ['{', '[']): + print("ERROR: Possible missing round bracket ')' detected at {0} Line number: {1}".format(filepath,lineNumber)) + bad_count_file += 1 + brackets_list.append(')') + elif (c == '['): + brackets_list.append('[') + elif (c == ']'): + if (len(brackets_list) > 0 and brackets_list[-1] in ['{', '(']): + print("ERROR: Possible missing square bracket ']' detected at {0} Line number: {1}".format(filepath,lineNumber)) + bad_count_file += 1 + brackets_list.append(']') + elif (c == '{'): + brackets_list.append('{') + elif (c == '}'): + lastIsCurlyBrace = True + if (len(brackets_list) > 0 and brackets_list[-1] in ['(', '[']): + print("ERROR: Possible missing curly brace '}}' detected at {0} Line number: {1}".format(filepath,lineNumber)) + bad_count_file += 1 + brackets_list.append('}') + elif (c== '\t'): + print("ERROR: Tab detected at {0} Line number: {1}".format(filepath,lineNumber)) + bad_count_file += 1 + + else: # Look for the end of our comment block + if (c == '*'): + checkIfNextIsClosingBlock = True; + elif (checkIfNextIsClosingBlock): + if (c == '/'): + isInCommentBlock = False + elif (c != '*'): + checkIfNextIsClosingBlock = False + indexOfCharacter += 1 + + if brackets_list.count('[') != brackets_list.count(']'): + print("ERROR: A possible missing square bracket [ or ] in file {0} [ = {1} ] = {2}".format(filepath,brackets_list.count('['),brackets_list.count(']'))) + bad_count_file += 1 + if brackets_list.count('(') != brackets_list.count(')'): + print("ERROR: A possible missing round bracket ( or ) in file {0} ( = {1} ) = {2}".format(filepath,brackets_list.count('('),brackets_list.count(')'))) + bad_count_file += 1 + if brackets_list.count('{') != brackets_list.count('}'): + print("ERROR: A possible missing curly brace {{ or }} in file {0} {{ = {1} }} = {2}".format(filepath,brackets_list.count('{'),brackets_list.count('}'))) + bad_count_file += 1 + return bad_count_file + +def main(): + + print("Validating Config Style") + + sqf_list = [] + bad_count = 0 + + parser = argparse.ArgumentParser() + parser.add_argument('-m','--module', help='only search specified module addon folder', required=False, default="") + args = parser.parse_args() + + # Allow running from root directory as well as from inside the tools directory + rootDir = "../addons" + if (os.path.exists("addons")): + rootDir = "addons" + + for root, dirnames, filenames in os.walk(rootDir + '/' + args.module): + for filename in fnmatch.filter(filenames, '*.cpp'): + sqf_list.append(os.path.join(root, filename)) + for filename in fnmatch.filter(filenames, '*.hpp'): + sqf_list.append(os.path.join(root, filename)) + + for filename in sqf_list: + bad_count = bad_count + check_config_style(filename) + + print("------\nChecked {0} files\nErrors detected: {1}".format(len(sqf_list), bad_count)) + if (bad_count == 0): + print("Config validation PASSED") + else: + print("Config validation FAILED") + + return bad_count + +if __name__ == "__main__": + sys.exit(main()) diff --git a/tools/setup.py b/tools/setup.py index 62925a6066..af1b224cbb 100644 --- a/tools/setup.py +++ b/tools/setup.py @@ -25,19 +25,19 @@ def main(): ###################################### This script will create your ACE3 dev environment for you. - + Before you run this, you should already have: - The Arma 3 Tools installed properly via Steam - A properly set up P-drive - + If you have not done those things yet, please abort this script in the next step and do so first. - + This script will create two hard links on your system, both pointing to your ACE3 project folder: [Arma 3 installation directory]\\{} => ACE3 project folder P:\\{} => ACE3 project folder - + It will also copy the required CBA includes to {}, if you do not have the CBA source code already.""".format(FULLDIR,FULLDIR,CBA)) - print("\n") + print("\n") try: reg = winreg.ConnectRegistry(None, winreg.HKEY_LOCAL_MACHINE) @@ -79,12 +79,8 @@ def main(): if not os.path.exists(os.path.join(armapath, MAINDIR)): os.mkdir(os.path.join(armapath, MAINDIR)) - if platform.win32_ver()[0] == "7": - subprocess.call(["cmd", "/c", "mklink", "/D", "P:\\{}\\{}".format(MAINDIR,PROJECTDIR), projectpath]) - subprocess.call(["cmd", "/c", "mklink", "/D", os.path.join(armapath, MAINDIR, PROJECTDIR), projectpath]) - else: - subprocess.call(["cmd", "/c", "mklink", "/D", "/J", "P:\\{}\\{}".format(MAINDIR,PROJECTDIR), projectpath]) - subprocess.call(["cmd", "/c", "mklink", "/D", "/J", os.path.join(armapath, MAINDIR, PROJECTDIR), projectpath]) + subprocess.call(["cmd", "/c", "mklink", "/J", "P:\\{}\\{}".format(MAINDIR,PROJECTDIR), projectpath]) + subprocess.call(["cmd", "/c", "mklink", "/J", os.path.join(armapath, MAINDIR, PROJECTDIR), projectpath]) except: raise print("Something went wrong during the link creation. Please finish the setup manually.") diff --git a/tools/sqf_validator.py b/tools/sqf_validator.py index 7414d7d715..c824b35268 100644 --- a/tools/sqf_validator.py +++ b/tools/sqf_validator.py @@ -8,7 +8,7 @@ import sys import argparse def validKeyWordAfterCode(content, index): - keyWords = ["for", "do", "count", "each", "forEach", "else", "and", "not", "isEqualTo", "in", "call", "spawn", "execVM", "catch"]; + keyWords = ["for", "do", "count", "each", "forEach", "else", "and", "not", "isEqualTo", "in", "call", "spawn", "execVM", "catch", "param", "select", "apply"]; for word in keyWords: try: subWord = content.index(word, index, index+len(word)) @@ -50,7 +50,7 @@ def check_sqf_syntax(filepath): checkForSemiColumn = False # Extra information so we know what line we find errors at - lineNumber = 0 + lineNumber = 1 indexOfCharacter = 0 # Parse all characters in the content of this file to search for potential errors @@ -112,7 +112,7 @@ def check_sqf_syntax(filepath): elif (c== '\t'): print("ERROR: Tab detected at {0} Line number: {1}".format(filepath,lineNumber)) bad_count_file += 1 - + if (checkForSemiColumn): if (c not in [' ', '\t', '\n', '/']): # keep reading until no white space or comments checkForSemiColumn = False From b192be0b70283c8927b411368c8a5c987680198b Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 18 May 2017 11:13:31 -0500 Subject: [PATCH 16/36] Fix merge, cbaEvents, macros, cleanup --- .../functions/fnc_canStopEscorting.sqf | 2 +- addons/cargo/functions/fnc_canUnloadItem.sqf | 2 +- .../functions/fnc_displayTextStructured.sqf | 4 ++ addons/common/functions/fnc_dumpArray.sqf | 47 ------------------- .../functions/fnc_findUnloadPosition.sqf | 6 +-- addons/common/functions/fnc_showHud.sqf | 4 +- .../functions/fnc_unloadPersonLocal.sqf | 2 +- .../functions/fnc_disarmDropItems.sqf | 2 +- .../functions/fnc_placeExplosive.sqf | 2 +- addons/hearing/functions/fnc_updateVolume.sqf | 2 +- .../functions/fnc_createAction.sqf | 12 ++--- addons/laser/functions/fnc_laserOff.sqf | 2 +- .../microdagr/functions/fnc_openDisplay.sqf | 2 +- .../functions/fnc_loadMagazineTimer.sqf | 2 +- addons/rearm/CfgVehicles.hpp | 2 +- addons/rearm/XEH_postInit.sqf | 8 ++-- .../functions/fnc_addMagazineToSupply.sqf | 3 +- .../rearm/functions/fnc_addRearmActions.sqf | 2 +- .../fnc_addVehicleMagazinesToSupply.sqf | 2 +- addons/rearm/functions/fnc_canStoreAmmo.sqf | 2 +- addons/rearm/functions/fnc_canTakeAmmo.sqf | 2 +- addons/rearm/functions/fnc_grabAmmo.sqf | 2 +- .../functions/fnc_moduleRearmSettings.sqf | 3 +- addons/rearm/functions/fnc_pickUpAmmo.sqf | 8 ++-- .../rearm/functions/fnc_readSupplyCounter.sqf | 8 ++-- addons/rearm/functions/fnc_rearm.sqf | 6 ++- .../fnc_rearmEntireVehicleSuccess.sqf | 8 ++-- addons/rearm/functions/fnc_rearmSuccess.sqf | 7 ++- .../rearm/functions/fnc_rearmSuccessLocal.sqf | 19 ++++---- addons/rearm/functions/fnc_takeAmmo.sqf | 2 +- addons/rearm/script_component.hpp | 3 +- addons/repair/functions/fnc_useItem.sqf | 2 +- .../functions/fnc_toggleInterface.sqf | 12 ++--- 33 files changed, 77 insertions(+), 115 deletions(-) diff --git a/addons/captives/functions/fnc_canStopEscorting.sqf b/addons/captives/functions/fnc_canStopEscorting.sqf index 3ecaffecab..cfafb5a0e8 100644 --- a/addons/captives/functions/fnc_canStopEscorting.sqf +++ b/addons/captives/functions/fnc_canStopEscorting.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: caller (player) - * 1: target (optional) + * 1: target * * Return Value: * The return value diff --git a/addons/cargo/functions/fnc_canUnloadItem.sqf b/addons/cargo/functions/fnc_canUnloadItem.sqf index da8ced5557..1e8753cc27 100644 --- a/addons/cargo/functions/fnc_canUnloadItem.sqf +++ b/addons/cargo/functions/fnc_canUnloadItem.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: loaded Object * 1: Object - * 2: Unloader (player) (optional) + * 2: Unloader (player) * * Return Value: * Can be unloaded diff --git a/addons/common/functions/fnc_displayTextStructured.sqf b/addons/common/functions/fnc_displayTextStructured.sqf index 3037a218cc..97dab5773d 100644 --- a/addons/common/functions/fnc_displayTextStructured.sqf +++ b/addons/common/functions/fnc_displayTextStructured.sqf @@ -11,6 +11,10 @@ * Return Value: * None * + * Example: + * [["Test: %1", 123], 1.5] call ace_common_fnc_displayTextStructured + * ["wow", 1, ace_player, 3] call ace_common_fnc_displayTextStructured + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_dumpArray.sqf b/addons/common/functions/fnc_dumpArray.sqf index 992f27d99e..b274f1119e 100644 --- a/addons/common/functions/fnc_dumpArray.sqf +++ b/addons/common/functions/fnc_dumpArray.sqf @@ -1,4 +1,3 @@ -<<<<<<< HEAD /* * Author: ? * Dumps an array to the RPT, showing the depth of each element. @@ -43,49 +42,3 @@ if (IS_ARRAY(_var)) then { } else { diag_log text format ["%1%2", _pad, _var]; }; -======= -/* - * Author: ? - * Dumps an array to the RPT, showing the depth of each element. - * - * Arguments: - * 0: Array to be dumped - * 1: Depth (optional) - * - * Return Value: - * None - * - * Example: - * [[0, [1,2], [[3]]]] call ace_common_fnc_dumpArray - * - * Public: No - */ -#include "script_component.hpp" - -params ["_var", ["_depth", 0, [0]]]; - -private _pad = ""; - -for "_i" from 0 to _depth do { - _pad = _pad + toString [9]; -}; - -_depth = _depth + 1; - -if (IS_ARRAY(_var)) then { - if (_var isEqualTo []) then { - diag_log text format ["%1[],", _pad]; - } else { - diag_log text format ["%1[", _pad]; - - { - [_x, _depth] call FUNC(dumpArray); - false - } count _var; - - diag_log text format ["%1],", _pad]; - }; -} else { - diag_log text format ["%1%2", _pad, _var]; -}; ->>>>>>> 8e004741b92ed4a0b92a15d76645485071a0a8e7 diff --git a/addons/common/functions/fnc_findUnloadPosition.sqf b/addons/common/functions/fnc_findUnloadPosition.sqf index 7433873b0b..c3b0dc3f34 100644 --- a/addons/common/functions/fnc_findUnloadPosition.sqf +++ b/addons/common/functions/fnc_findUnloadPosition.sqf @@ -6,9 +6,9 @@ * Arguments: * 0: Source Vehicle * 1: Cargo Classname - * 2: Unloader (player) (optional) - * 3: Max Distance (meters) (optional) - * 4: Check Vehicle is Stable (optional) + * 2: Unloader (player) + * 3: Max Distance (meters) + * 4: Check Vehicle is Stable * * Return Value: * Unload PositionAGL (Can Be [] if no valid pos found) diff --git a/addons/common/functions/fnc_showHud.sqf b/addons/common/functions/fnc_showHud.sqf index df3b22394d..7c91ab3592 100644 --- a/addons/common/functions/fnc_showHud.sqf +++ b/addons/common/functions/fnc_showHud.sqf @@ -4,8 +4,8 @@ * Bitwise AND Logic (a single false in a mask will make it false) * * Arguments: - * 0: Source ID (optional) - * 1: Show Hud Bool Array (8 to set, empty to remove) (optional) + * 0: Source ID + * 1: Show Hud Bool Array (8 to set, empty to remove) * - [hud, info, radar, compass, direction, menu, group, cursors] * - hud: Boolean - show scripted HUD (same as normal showHUD true/false) * - info: Boolean - show vehicle + soldier info (hides weapon info from the HUD as well) diff --git a/addons/common/functions/fnc_unloadPersonLocal.sqf b/addons/common/functions/fnc_unloadPersonLocal.sqf index 6f1a4e3ecc..dbc28dc977 100644 --- a/addons/common/functions/fnc_unloadPersonLocal.sqf +++ b/addons/common/functions/fnc_unloadPersonLocal.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: unit to unload * 1: Vehicle - * 2: Unloader (player) (optional) + * 2: Unloader (player) * * Return Value: * Returns true if succesfully unloaded person diff --git a/addons/disarming/functions/fnc_disarmDropItems.sqf b/addons/disarming/functions/fnc_disarmDropItems.sqf index d063d4bcd3..c9eb920084 100644 --- a/addons/disarming/functions/fnc_disarmDropItems.sqf +++ b/addons/disarming/functions/fnc_disarmDropItems.sqf @@ -7,7 +7,7 @@ * 0: caller (player) * 1: target * 2: classnamess - * 3: Do Not Drop Ammo (optional) + * 3: Do Not Drop Ammo * * Return Value: * Nothing diff --git a/addons/explosives/functions/fnc_placeExplosive.sqf b/addons/explosives/functions/fnc_placeExplosive.sqf index 63a4d6e43c..5114f907ac 100644 --- a/addons/explosives/functions/fnc_placeExplosive.sqf +++ b/addons/explosives/functions/fnc_placeExplosive.sqf @@ -9,7 +9,7 @@ * 3: Magazine class * 4: Config of trigger * 5: Variables required for the trigger type - * 6: Explosive placeholder (optional) + * 6: Explosive placeholder * * Return Value: * Placed explosive diff --git a/addons/hearing/functions/fnc_updateVolume.sqf b/addons/hearing/functions/fnc_updateVolume.sqf index aa2181ade0..01ab58ef76 100644 --- a/addons/hearing/functions/fnc_updateVolume.sqf +++ b/addons/hearing/functions/fnc_updateVolume.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Args - * -----0: Just update volume (skip ringing/recovery) (optional) + * -----0: Just update volume (skip ringing/recovery) * * Return Value: * None diff --git a/addons/interact_menu/functions/fnc_createAction.sqf b/addons/interact_menu/functions/fnc_createAction.sqf index 160c6fdd24..27d6d5bc3d 100644 --- a/addons/interact_menu/functions/fnc_createAction.sqf +++ b/addons/interact_menu/functions/fnc_createAction.sqf @@ -9,12 +9,12 @@ * 2: Icon * 3: Statement * 4: Condition - * 5: Insert children code (optional) - * 6: Action parameters (optional) - * 7: Position (Position array, Position code or Selection Name) , or (optional) - * 8: Distance (optional) - * 9: Other parameters [showDisabled,enableInside,canCollapse,runOnHover,doNotCheckLOS] (optional) - * 10: Modifier function (optional) + * 5: Insert children code (Optional) + * 6: Action parameters (Optional) + * 7: Position (Position array, Position code or Selection Name) , or (Optional) + * 8: Distance (Optional) + * 9: Other parameters [showDisabled,enableInside,canCollapse,runOnHover,doNotCheckLOS] (Optional) + * 10: Modifier function (Optional) * * Return Value: * Action diff --git a/addons/laser/functions/fnc_laserOff.sqf b/addons/laser/functions/fnc_laserOff.sqf index 64188a62f1..fcfc669d45 100644 --- a/addons/laser/functions/fnc_laserOff.sqf +++ b/addons/laser/functions/fnc_laserOff.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: UUID (from laserOn) * - * Return Value: + * Return value: * None * * Example: diff --git a/addons/microdagr/functions/fnc_openDisplay.sqf b/addons/microdagr/functions/fnc_openDisplay.sqf index 90aeabdb78..aa2db94827 100644 --- a/addons/microdagr/functions/fnc_openDisplay.sqf +++ b/addons/microdagr/functions/fnc_openDisplay.sqf @@ -3,7 +3,7 @@ * Changes the display mode of the microDAGR * * Arguments: - * 0: Display Mode to show the microDAGR in (optional) + * 0: Display Mode to show the microDAGR in * * Return Value: * None diff --git a/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf b/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf index 866aea6206..16016f06e6 100644 --- a/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf +++ b/addons/mk6mortar/functions/fnc_loadMagazineTimer.sqf @@ -6,7 +6,7 @@ * 0: static * 1: unit * 2: time to load - * 3: magazineClassOptional (optional) + * 3: magazineClassOptional * * Return Value: * None diff --git a/addons/rearm/CfgVehicles.hpp b/addons/rearm/CfgVehicles.hpp index 7da9bb8136..ce12e4f48b 100644 --- a/addons/rearm/CfgVehicles.hpp +++ b/addons/rearm/CfgVehicles.hpp @@ -6,7 +6,7 @@ displayName = CSTRING(Rearm); \ distance = REARM_ACTION_DISTANCE; \ condition = QUOTE(_this call FUNC(canRearm)); \ - statement = QUOTE(_player call FUNC(rearm)); \ + statement = QUOTE(_this call FUNC(rearm)); \ exceptions[] = {"isNotInside"}; \ icon = QPATHTOF(ui\icon_rearm_interact.paa); \ }; \ diff --git a/addons/rearm/XEH_postInit.sqf b/addons/rearm/XEH_postInit.sqf index 296728807f..56cf067dba 100644 --- a/addons/rearm/XEH_postInit.sqf +++ b/addons/rearm/XEH_postInit.sqf @@ -1,6 +1,6 @@ #include "script_component.hpp" -["ace_unconscious", {_this call FUNC(handleUnconscious)}] call CBA_fnc_addEventHandler; +["ace_unconscious", LINKFUNC(handleUnconscious)] call CBA_fnc_addEventHandler; ["vehicle", { params ["_unit"]; [_unit] call FUNC(dropAmmo); @@ -10,9 +10,9 @@ if (isServer) then { addMissionEventHandler ["HandleDisconnect", {params ["_unit"]; [_unit] call FUNC(dropAmmo)}]; }; -[QGVAR(makeDummyEH), FUNC(makeDummy)] call CBA_fnc_addEventHandler; -[QGVAR(rearmEntireVehicleSuccessLocalEH), FUNC(rearmEntireVehicleSuccessLocal)] call CBA_fnc_addEventHandler; -[QGVAR(rearmSuccessLocalEH), FUNC(rearmSuccessLocal)] call CBA_fnc_addEventHandler; +[QGVAR(makeDummyEH), LINKFUNC(makeDummy)] call CBA_fnc_addEventHandler; +[QGVAR(rearmEntireVehicleSuccessLocalEH), LINKFUNC(rearmEntireVehicleSuccessLocal)] call CBA_fnc_addEventHandler; +[QGVAR(rearmSuccessLocalEH), LINKFUNC(rearmSuccessLocal)] call CBA_fnc_addEventHandler; #ifdef DEBUG_MODE_FULL diff --git a/addons/rearm/functions/fnc_addMagazineToSupply.sqf b/addons/rearm/functions/fnc_addMagazineToSupply.sqf index 55188408d1..e401c6e4f0 100644 --- a/addons/rearm/functions/fnc_addMagazineToSupply.sqf +++ b/addons/rearm/functions/fnc_addMagazineToSupply.sqf @@ -27,10 +27,11 @@ if (isNull _truck || {_magazineClass isEqualTo ""} || {GVAR(supply) == 0}) exitWith {}; +([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; + // With limited supply, we add the caliber to the supply count if (GVAR(supply) == 1) then { private _supply = [_truck] call FUNC(getSupplyCount); - ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; if (!_partial || {GVAR(level) == 1}) then { [_truck, _supply + _cal] call FUNC(setSupplyCount); } else { diff --git a/addons/rearm/functions/fnc_addRearmActions.sqf b/addons/rearm/functions/fnc_addRearmActions.sqf index d69c2bfee7..fea1414252 100644 --- a/addons/rearm/functions/fnc_addRearmActions.sqf +++ b/addons/rearm/functions/fnc_addRearmActions.sqf @@ -35,7 +35,7 @@ private _vehicleActions = []; private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); { private _magazine = _x; - _currentMagazines = { _x == _magazine } count (_vehicle magazinesTurret _turretPath); + private _currentMagazines = { _x == _magazine } count (_vehicle magazinesTurret _turretPath); if ((_currentMagazines < ([_vehicle, _turretPath, _magazine] call FUNC(getMaxMagazines))) && !(_magazine in _magazineHelper)) then { _action = [_magazine, getText(configFile >> "CfgMagazines" >> _magazine >> "displayName"), diff --git a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf index 6d87c81823..b7f695ce9d 100644 --- a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf +++ b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf @@ -27,7 +27,7 @@ if (isNull _truck || private _string = [_vehicle, typeOf _vehicle] select (_vehicle isEqualType objNull); if (_string == "") exitWith { - ACE_ERRORFORMAT("_string is empty in ace_rearm_fnc_addVehicleMagazinesToSupply"); + ERROR_1("_string [%1] is empty in ace_rearm_fnc_addVehicleMagazinesToSupply",_string); }; { private _turretPath = _x; diff --git a/addons/rearm/functions/fnc_canStoreAmmo.sqf b/addons/rearm/functions/fnc_canStoreAmmo.sqf index 2ff6b86874..a9e4fe981e 100644 --- a/addons/rearm/functions/fnc_canStoreAmmo.sqf +++ b/addons/rearm/functions/fnc_canStoreAmmo.sqf @@ -22,7 +22,7 @@ params [ ]; !(isNull _unit || - {!alive _target} || + {!alive _truck} || {!(_unit isKindOf "CAManBase")} || {!local _unit} || {(_truck distance _unit) > REARM_ACTION_DISTANCE} || diff --git a/addons/rearm/functions/fnc_canTakeAmmo.sqf b/addons/rearm/functions/fnc_canTakeAmmo.sqf index 67ddded444..83bf89bd92 100644 --- a/addons/rearm/functions/fnc_canTakeAmmo.sqf +++ b/addons/rearm/functions/fnc_canTakeAmmo.sqf @@ -22,7 +22,7 @@ params [ ]; !(isNull _unit || - {!alive _target} || + {!alive _truck} || {!(_unit isKindOf "CAManBase")} || {!local _unit} || {(_truck distance _unit) > REARM_ACTION_DISTANCE} || diff --git a/addons/rearm/functions/fnc_grabAmmo.sqf b/addons/rearm/functions/fnc_grabAmmo.sqf index 29295d4f35..707b5c7548 100644 --- a/addons/rearm/functions/fnc_grabAmmo.sqf +++ b/addons/rearm/functions/fnc_grabAmmo.sqf @@ -21,7 +21,7 @@ params [ ["_unit", objNull, [objNull]] ]; -REARM_HOLSTER_WEAPON +REARM_HOLSTER_WEAPON; [_unit, "forceWalk", QGVAR(vehRearm), true] call EFUNC(common,statusEffect_set); [ diff --git a/addons/rearm/functions/fnc_moduleRearmSettings.sqf b/addons/rearm/functions/fnc_moduleRearmSettings.sqf index 8397eb5401..ccbb24f9a3 100644 --- a/addons/rearm/functions/fnc_moduleRearmSettings.sqf +++ b/addons/rearm/functions/fnc_moduleRearmSettings.sqf @@ -28,5 +28,4 @@ if (!_activated) exitWith {}; [_logic, QGVAR(level), "level"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(supply), "supply"] call EFUNC(common,readSettingFromModule); -diag_log text format ["[ACE]: Rearm Module Initialized on level: %1", GVAR(level)]; -diag_log text format ["[ACE]: Rearm Module Initialized on supply: %1", GVAR(supply)]; +INFO_2("Module Initialized [level: %1][supply: %2]", GVAR(level), GVAR(supply)); diff --git a/addons/rearm/functions/fnc_pickUpAmmo.sqf b/addons/rearm/functions/fnc_pickUpAmmo.sqf index a4866c1115..ee2845336b 100644 --- a/addons/rearm/functions/fnc_pickUpAmmo.sqf +++ b/addons/rearm/functions/fnc_pickUpAmmo.sqf @@ -25,7 +25,9 @@ private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; if !(isNull _attachedDummy) exitWith {}; _dummy attachTo [_unit, [0,1,0], "pelvis"]; -{ - [QGVAR(makeDummyEH), _x, [_dummy, [[-1,0,0],[0,0,1]]]] call CBA_fnc_targetEvent; -} count (position _unit nearObjects ["CAManBase", 100]); + +private _nearUnits = _unit nearObjects ["CAManBase", 100]; +// disableCollisionWith damage with the nearby units: +[QGVAR(makeDummyEH), [_dummy, [[-1,0,0],[0,0,1]]], _nearUnits] call CBA_fnc_targetEvent; + _unit setVariable [QGVAR(dummy), _dummy]; diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf index 8de95776cb..214fe70a5e 100644 --- a/addons/rearm/functions/fnc_readSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -31,9 +31,9 @@ if (GVAR(supply) == 1) then { params ["_args"]; _args params [["_unit", objNull, [objNull]], ["_truck", objNull, [objNull]], ["_supplyCount", 0, [0]]]; if (_supplyCount > 0 ) then { - ["displayTextStructured", _unit, [[LSTRING(Hint_RemainingSupplyPoints), _supplyCount], 2, _unit]] call EFUNC(common,objectEvent); + [[LSTRING(Hint_RemainingSupplyPoints), _supplyCount], 2, _unit] call EFUNC(common,displayTextStructured); } else { - ["displayTextStructured", _unit, [LSTRING(Hint_EmptySupplyPoints), 2, _unit]] call EFUNC(common,objectEvent); + [LSTRING(Hint_EmptySupplyPoints), 2, _unit] call EFUNC(common,displayTextStructured); }; true }, @@ -64,9 +64,9 @@ if (GVAR(supply) == 1) then { } count _magazines; }; if (_supply > 1.5) then { - ["displayTextStructured", _unit, [[LSTRING(Hint_RemainingAmmo), _text], _supply, _unit, (_numChars/2.9)]] call EFUNC(common,objectEvent); + [[LSTRING(Hint_RemainingAmmo), _text], _supply, _unit, (_numChars/2.9)] call EFUNC(common,displayTextStructured); } else { - ["displayTextStructured", _unit, [LSTRING(Hint_Empty), 2, _unit]] call EFUNC(common,objectEvent); + [LSTRING(Hint_Empty), 2, _unit] call EFUNC(common,displayTextStructured); }; true }, diff --git a/addons/rearm/functions/fnc_rearm.sqf b/addons/rearm/functions/fnc_rearm.sqf index 65b80b6900..8b28192e41 100644 --- a/addons/rearm/functions/fnc_rearm.sqf +++ b/addons/rearm/functions/fnc_rearm.sqf @@ -3,19 +3,21 @@ * Starts progress bar for rearming a vehicle. * * Arguments: - * 0: Unit + * 0: Target Vehicle + * 1: Unit * * Return Value: * None * * Example: - * [player] call ace_rearm_fnc_rearm + * [tank, player] call ace_rearm_fnc_rearm * * Public: No */ #include "script_component.hpp" params [ + ["_target", objNull, [objNull]], ["_unit", objNull, [objNull]] ]; diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf index c0f0021cd7..a2a23d7357 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccess.sqf @@ -25,14 +25,14 @@ _args params [ if (isServer) then { { - _turretOwnerID = _vehicle turretOwner _x; + private _turretOwnerID = _vehicle turretOwner _x; if (_turretOwnerID == 0) then { - [QGVAR(rearmEntireVehicleSuccessLocalEH), _truck, [_truck, _vehicle, _x]] call EFUNC(common,objectEvent); + [QGVAR(rearmEntireVehicleSuccessLocalEH), [_truck, _vehicle, _x], _truck] call CBA_fnc_targetEvent; } else { - [QGVAR(rearmEntireVehicleSuccessLocalEH), _turretOwnerID, [_truck, _vehicle, _x]] call EFUNC(common,targetEvent); + [QGVAR(rearmEntireVehicleSuccessLocalEH), [_truck, _vehicle, _x], _turretOwnerID] call CBA_fnc_ownerEvent; }; false } count REARM_TURRET_PATHS; } else { - [QGVAR(rearmEntireVehicleSuccessLocalEH), _this] call EFUNC(common,serverEvent); + [QGVAR(rearmEntireVehicleSuccessLocalEH), _this] call CBA_fnc_serverEvent; }; diff --git a/addons/rearm/functions/fnc_rearmSuccess.sqf b/addons/rearm/functions/fnc_rearmSuccess.sqf index c5e47a5887..8fc006148a 100644 --- a/addons/rearm/functions/fnc_rearmSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmSuccess.sqf @@ -25,8 +25,7 @@ params [ ["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]] ]; _args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; - -//hint format ["Vehicle: %1\nTurretPath: %2\nNumMagazines: %3\nMagazine: %4\nNumRounds: %5", _vehicle, _turretPath, _numMagazines, _magazineClass, _numRounds]; +TRACE_6("rearmSuccess",_vehicle,_unit,_turretPath,_numMagazines,_magazineClass,_numRounds); if (local _unit) then { [_unit, true, true] call FUNC(dropAmmo); @@ -35,9 +34,9 @@ if (local _unit) then { if (isServer) then { private _turretOwnerID = _vehicle turretOwner _turretPath; if (_turretOwnerID == 0) then { - [QGVAR(rearmSuccessLocalEH), _vehicle, _this] call EFUNC(common,objectEvent); + [QGVAR(rearmSuccessLocalEH), _this, [_vehicle]] call CBA_fnc_targetEvent; } else { - [QGVAR(rearmSuccessLocalEH), _turretOwnerID, _this] call EFUNC(common,targetEvent); + [QGVAR(rearmSuccessLocalEH), _this, _turretOwnerID] call CBA_fnc_ownerEvent; }; } else { [QGVAR(rearmSuccessLocalEH), _this] call EFUNC(common,serverEvent); diff --git a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf index f04ab4b501..f922f06eee 100644 --- a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf @@ -15,7 +15,7 @@ * None * * Example: - * [[vehicle, player, [-1], 2, "5000Rnd_762x51_Belt", 500]] call ace_rearm_fnc_rearmSuccess + * [[vehicle, player, [-1], 2, "5000Rnd_762x51_Belt", 500]] call ace_rearm_fnc_rearmSuccessLocal * * Public: No */ @@ -25,6 +25,7 @@ params [ ["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]] ]; _args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; +TRACE_6("rearmSuccessLocal",_vehicle,_unit,_turretPath,_numMagazines,_magazineClass,_numRounds); private _rounds = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); private _currentRounds = 0; @@ -40,15 +41,15 @@ if (_maxMagazines == 1) then { if (GVAR(level) == 1) then { // Fill magazine completely _vehicle setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; - ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _rounds, + [QEGVAR(common,displayTextStructured), [[LSTRING(Hint_RearmedTriple), _rounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit], [_unit]] call CBA_fnc_targetEvent; } else { // Fill only at most _numRounds _vehicle setMagazineTurretAmmo [_magazineClass, ((_vehicle magazineTurretAmmo [_magazineClass, _turretPath]) + _numRounds) min _rounds, _turretPath]; - ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _numRounds, + [QEGVAR(common,displayTextStructured), [[LSTRING(Hint_RearmedTriple), _numRounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit], [_unit]] call CBA_fnc_targetEvent; }; } else { for "_idx" from 1 to (_maxMagazines+1) do { @@ -69,9 +70,9 @@ if (_maxMagazines == 1) then { } else { _vehicle setMagazineTurretAmmo [_magazineClass, _currentRounds + _numRounds, _turretPath]; }; - ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _numRounds, + [QEGVAR(common,displayTextStructured), [[LSTRING(Hint_RearmedTriple), _numRounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit], [_unit]] call CBA_fnc_targetEvent; } else { // Fill current magazine completely and fill next magazine partially _vehicle setMagazineTurretAmmo [_magazineClass, _rounds, _turretPath]; @@ -79,9 +80,9 @@ if (_maxMagazines == 1) then { _vehicle addMagazineTurret [_magazineClass, _turretPath]; _vehicle setMagazineTurretAmmo [_magazineClass, _currentRounds, _turretPath]; }; - ["displayTextStructured", _unit, [[LSTRING(Hint_RearmedTriple), _rounds, + [QEGVAR(common,displayTextStructured), [[LSTRING(Hint_RearmedTriple), _rounds, getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"), - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit]] call EFUNC(common,objectEvent); + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName")], 3, _unit], [_unit]] call CBA_fnc_targetEvent; }; }; _vehicle removeMagazineTurret [_magazineClass, _turretPath]; diff --git a/addons/rearm/functions/fnc_takeAmmo.sqf b/addons/rearm/functions/fnc_takeAmmo.sqf index 9b0cfd3100..915be5e8a8 100644 --- a/addons/rearm/functions/fnc_takeAmmo.sqf +++ b/addons/rearm/functions/fnc_takeAmmo.sqf @@ -28,7 +28,7 @@ _args params ["_magazineClass", "_vehicle"]; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; -REARM_HOLSTER_WEAPON +REARM_HOLSTER_WEAPON; [ (REARM_DURATION_TAKE select _idx), diff --git a/addons/rearm/script_component.hpp b/addons/rearm/script_component.hpp index 7659faef64..c9ded7836d 100644 --- a/addons/rearm/script_component.hpp +++ b/addons/rearm/script_component.hpp @@ -28,12 +28,13 @@ #define REARM_HOLSTER_WEAPON \ _unit setVariable [QGVAR(selectedWeaponOnRearm), currentWeapon _unit]; \ + TRACE_2("REARM_HOLSTER_WEAPON",_unit,currentWeapon _unit); \ _unit action ["SwitchWeapon", _unit, _unit, 299]; #define REARM_UNHOLSTER_WEAPON \ _weaponSelect = _unit getVariable QGVAR(selectedWeaponOnRearm); \ - TRACE_2("REARM_UNHOLSTER_WEAPON",_unit,_weaponSelect); \ if (!isNil "_weaponSelect") then { \ + TRACE_2("REARM_UNHOLSTER_WEAPON",_unit,_weaponSelect); \ _unit selectWeapon _weaponSelect; \ _unit setVariable [QGVAR(selectedWeaponOnRearm), nil]; \ }; diff --git a/addons/repair/functions/fnc_useItem.sqf b/addons/repair/functions/fnc_useItem.sqf index c486ed50a0..02daeed33e 100644 --- a/addons/repair/functions/fnc_useItem.sqf +++ b/addons/repair/functions/fnc_useItem.sqf @@ -20,7 +20,7 @@ params ["_unit", "_item"]; TRACE_2("params",_unit,_item); if ([_unit, _item] call EFUNC(common,hasItem)) exitWith { - [QGVAR(useItem), _unit, [_unit, _item]] call EFUNC(common,objectEvent); + ["ace_useItem", [_unit, _item], _unit] call CBA_fnc_targetEvent; [true, _unit]; }; diff --git a/addons/spectator/functions/fnc_toggleInterface.sqf b/addons/spectator/functions/fnc_toggleInterface.sqf index cbc6091ae4..31472702fc 100644 --- a/addons/spectator/functions/fnc_toggleInterface.sqf +++ b/addons/spectator/functions/fnc_toggleInterface.sqf @@ -4,12 +4,12 @@ * * Arguments: * 0: Display - * 1: Toogle compass (optional) - * 2: Toogle help (optional) - * 3: Toogle interface (optional) - * 4: Toogle map (optional) - * 5: Toogle toolbar (optional) - * 6: Toogle unit list (optional) + * 1: Toogle compass + * 2: Toogle help + * 3: Toogle interface + * 4: Toogle map + * 5: Toogle toolbar + * 6: Toogle unit list * * Return Value: * None From c9b26fa3e517b4da1a8b9a577f8ae3ad3c6bf3df Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 3 Jun 2017 21:39:52 -0500 Subject: [PATCH 17/36] Fix being unable to throw last mag (#5242) --- addons/advanced_throwing/functions/fnc_drawThrowable.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/advanced_throwing/functions/fnc_drawThrowable.sqf b/addons/advanced_throwing/functions/fnc_drawThrowable.sqf index b4155ecfcd..4f7a27ec65 100644 --- a/addons/advanced_throwing/functions/fnc_drawThrowable.sqf +++ b/addons/advanced_throwing/functions/fnc_drawThrowable.sqf @@ -37,7 +37,7 @@ if (_throwable isEqualTo [] && {!_primed}) exitWith { private _throwableMag = _throwable param [0, "#none"]; // If not primed, double check we actually have the magazine in inventory -if ((!_primed) && {!(_throwableMag in (magazines ACE_player))}) exitWith { +if ((!_primed) && {!((_throwableMag in (uniformItems ACE_player)) || {_throwableMag in (vestItems ACE_player)} || {_throwableMag in (backpackItems ACE_player)})}) exitWith { [ACE_player, "No valid throwable (glitched currentThrowable)"] call FUNC(exitThrowMode); }; From 0affa14a1bd8565accd0dba82a1b0507fd53e78a Mon Sep 17 00:00:00 2001 From: Andrea Verano Date: Sun, 4 Jun 2017 05:27:51 +0200 Subject: [PATCH 18/36] Italian Translation Update (#5243) Added Italian translation for: -cargo -hellfire -nlaw -quickmount -refuel -zeus --- addons/cargo/stringtable.xml | 6 +++++- addons/common/stringtable.xml | 6 +++--- addons/hellfire/stringtable.xml | 1 + addons/nlaw/stringtable.xml | 3 +++ addons/quickmount/stringtable.xml | 13 ++++++++++++- addons/refuel/stringtable.xml | 1 + addons/zeus/stringtable.xml | 4 +++- 7 files changed, 28 insertions(+), 6 deletions(-) diff --git a/addons/cargo/stringtable.xml b/addons/cargo/stringtable.xml index df5090db6e..f506f705e9 100644 --- a/addons/cargo/stringtable.xml +++ b/addons/cargo/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -239,15 +239,19 @@ Cargo Space + Spazio Cargo The cargo space available in this vehicle/container + Lo spazio disponibile in questo veicolo/container Cargo Size + Dimensioni Cargo The cargo space required to hold this object (-1 for unloadable) + Lo spazio del cargo necessita di mantenere questo oggetto (-1 per scaricabile) Airdrop diff --git a/addons/common/stringtable.xml b/addons/common/stringtable.xml index a1ac4a6604..462cafc1ba 100644 --- a/addons/common/stringtable.xml +++ b/addons/common/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -940,14 +940,14 @@ Sem espaço para descarregar Нет места для выгрузки 降ろすための空間がありません - + Toggle переключить переключить Basculer Cambiar - camb. + Cambia Umschalten pecek přep. diff --git a/addons/hellfire/stringtable.xml b/addons/hellfire/stringtable.xml index ee8c91a071..b9d793608d 100644 --- a/addons/hellfire/stringtable.xml +++ b/addons/hellfire/stringtable.xml @@ -16,6 +16,7 @@ Set Hellfire mode + Imposta modalità Hellfire RAH-66 Comanche [Hellfire] diff --git a/addons/nlaw/stringtable.xml b/addons/nlaw/stringtable.xml index 14432e4089..e46e1aafb0 100644 --- a/addons/nlaw/stringtable.xml +++ b/addons/nlaw/stringtable.xml @@ -3,12 +3,15 @@ NLAW Track Target (Hold) + NLAW Traccia Bersaglio (Mantieni) Direct Attack + Attacco Diretto Overfly Top Attack + Attacco dall'alto diff --git a/addons/quickmount/stringtable.xml b/addons/quickmount/stringtable.xml index 8669e36eb3..c97b5c2a6a 100644 --- a/addons/quickmount/stringtable.xml +++ b/addons/quickmount/stringtable.xml @@ -1,40 +1,51 @@ - + Quick Mount + Entrata Rapida Vehicle quick mount Fahrzeug schnell montieren Pojazd szybkie mocowanie + Entrata rapida veicolo Quickly enter the vehicle you are directly looking at. + Entra velocemente nel veicolo che stai guardando. Vehicle Full + Veicolo Pieno Distance + Distanza Maximum distance to check for vehicles. + Distanza massima per controllare i veicoli. Vehicle Locked + Veicolo Bloccato. Maximum Speed (km/h) + Velocità Massima (km/h) Maximum vehicle speed (km/h) allowed for player entry + Velocità massima del veicolo (km/h) consentita per far salire un giocatore Prioritize Seat + Priorità Sedile Seat priority on entry + Priorità del sedile in entrata diff --git a/addons/refuel/stringtable.xml b/addons/refuel/stringtable.xml index 4522ddd620..e467ffeb16 100644 --- a/addons/refuel/stringtable.xml +++ b/addons/refuel/stringtable.xml @@ -408,6 +408,7 @@ Refuel hose length Betankung Schlauchlänge Reabastecer longitud de manguera + Rifiuta lungezza tubo diff --git a/addons/zeus/stringtable.xml b/addons/zeus/stringtable.xml index 07c0ca97d2..7ef7305b33 100644 --- a/addons/zeus/stringtable.xml +++ b/addons/zeus/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -870,10 +870,12 @@ Add full arsenal to object Ajouter arsenal complet à l'objet + Aggiunge arsenale completo all'oggetto Remove arsenal from object Retirer arsenal de l'objet + Rimuove arsenale completo dall'oggetto From 48680d11233372381e76c26e6e0d589db4247828 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 3 Jun 2017 23:39:03 -0500 Subject: [PATCH 19/36] Cleanup unused hellfire vic stringtable (#5245) --- addons/hellfire/stringtable.xml | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/addons/hellfire/stringtable.xml b/addons/hellfire/stringtable.xml index b9d793608d..c75a548172 100644 --- a/addons/hellfire/stringtable.xml +++ b/addons/hellfire/stringtable.xml @@ -18,18 +18,5 @@ Set Hellfire mode Imposta modalità Hellfire - - RAH-66 Comanche [Hellfire] - RAH-66 Comanche [Hellfire] - RAH-66 Comanche [Hellfire] - RAH-66 Comanche [Hellfire] - RAH-66 Comanche [Hellfire] - RAH-66 Commanche [Hellfire] - RAH-66 Команч [Hellfire] - RAH-66 Comanche [Hellfire] - RAH-66 Comanche [Hellfire] - RAH-66 Comanche [Hellfire] - RAH-66 コマンチ [Hellfire] - From 8bb92cee6fec198b091ab86fa7c1b3887aff9119 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sun, 4 Jun 2017 10:07:35 -0500 Subject: [PATCH 20/36] Fix weapon select grenade count wehn using advThrow (#5244) --- addons/weaponselect/functions/fnc_throwGrenade.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/weaponselect/functions/fnc_throwGrenade.sqf b/addons/weaponselect/functions/fnc_throwGrenade.sqf index 3f55e02f51..10a730f504 100644 --- a/addons/weaponselect/functions/fnc_throwGrenade.sqf +++ b/addons/weaponselect/functions/fnc_throwGrenade.sqf @@ -20,7 +20,7 @@ TRACE_10("firedEH:",_unit, _weapon, _muzzle, _mode, _ammo, _magazine, _projectil if (_weapon != "Throw") exitWith {}; -private _count = {_x == _magazine} count magazines _unit; +private _count = ({_x == _magazine} count uniformItems _unit) + ({_x == _magazine} count vestItems _unit) + ({_x == _magazine} count backpackItems _unit); [_magazine, _count] call FUNC(displayGrenadeTypeAndNumber); From cec82be93bc3a3a7332d3545ee3b902e1337f77f Mon Sep 17 00:00:00 2001 From: Phyma Date: Sun, 4 Jun 2017 19:46:49 +0200 Subject: [PATCH 21/36] Raise lower carry object (#5234) * Fix to move items up and down * Fixed private * Fixed public bug * Inserted Pabst solution * Remove extra space * Fixed request + added author * Fixed to correct comment * Tweeked comment again --- AUTHORS.txt | 1 + addons/dragging/functions/fnc_handleScrollWheel.sqf | 8 ++++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/AUTHORS.txt b/AUTHORS.txt index 812324c34d..43e1eeb21e 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -104,6 +104,7 @@ nomisum OnkelDisMaster oscarmolinadev PaxJaromeMalues +Phyma pokertour Professor rakowozz diff --git a/addons/dragging/functions/fnc_handleScrollWheel.sqf b/addons/dragging/functions/fnc_handleScrollWheel.sqf index e3a30ea9e0..f82478d531 100644 --- a/addons/dragging/functions/fnc_handleScrollWheel.sqf +++ b/addons/dragging/functions/fnc_handleScrollWheel.sqf @@ -37,8 +37,12 @@ _position set [2, ((_position select 2) + _scrollAmount min (_maxHeight + 1.5)) // move up/down object and reattach at current position detach _carriedItem; -_carriedItem setPosATL _position; -_carriedItem attachTo [_unit]; + +// Uses this method of selecting position because setPosATL did not have immediate effect +private _positionChange = _position vectorDiff (getPosATL _carriedItem); +private _selectionPosition = _unit worldToModel (ASLtoAGL getPosWorld _carriedItem); +_selectionPosition = _selectionPosition vectorAdd _positionChange; +_carriedItem attachTo [_unit, _selectionPosition]; //reset the carry direction private _direction = _carriedItem getVariable [QGVAR(carryDirection), 0]; From 7141bbc4b4dafed6da944051dcf7e5ce40ad84b8 Mon Sep 17 00:00:00 2001 From: Phyma Date: Mon, 5 Jun 2017 12:44:10 +0200 Subject: [PATCH 22/36] Added more info about indentations, tabs and EditorConfig (#5249) * Added more info about indentations, tabs and EditorConfig * Fixed original misspelling "Every" --- docs/wiki/development/coding-guidelines.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/wiki/development/coding-guidelines.md b/docs/wiki/development/coding-guidelines.md index 81cf20eff4..79214e4ecd 100644 --- a/docs/wiki/development/coding-guidelines.md +++ b/docs/wiki/development/coding-guidelines.md @@ -204,7 +204,10 @@ Exceptions: ## 5. Code Style +To help with some of the coding style we recommend you get the plugin [EditorConfig](http://editorconfig.org/#download) for your editor. It will help with correct indentations and deleting trailing spaces. + ### 5.1 Braces placement + Braces `{ }` which enclose a code block will have the first bracket placed behind the statement in case of `if`, `switch` statements or `while`, `waitUntil` & `for` loops. The second brace will be placed on the same column as the statement but on a separate line. - Opening brace on the same line as keyword @@ -264,7 +267,7 @@ class Three {foo = 3;}; Putting the opening brace in its own line wastes a lot of space, and keeping the closing brace on the same level as the keyword makes it easier to recognize what exactly the brace closes. ### 5.2 Indents -Ever new scope should be on a new indent. This will make the code easier to understand and read. Indentations consist of 4 spaces. Tabs are not allowed. +Every new scope should be on a new indent. This will make the code easier to understand and read. Indentations consist of 4 spaces. Tabs are not allowed. Tabs or spaces are not allowed to trail on a line, last character needs to be non blank. Good: From 606c6d18a69f48324702c83889cf83f20d8121fc Mon Sep 17 00:00:00 2001 From: Phyma Date: Mon, 5 Jun 2017 18:15:55 +0200 Subject: [PATCH 23/36] Added Pylon weapon as a valid weapon (#5250) --- addons/vehicles/CfgWeapons.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/vehicles/CfgWeapons.hpp b/addons/vehicles/CfgWeapons.hpp index c4d28c3e31..78a82abccf 100644 --- a/addons/vehicles/CfgWeapons.hpp +++ b/addons/vehicles/CfgWeapons.hpp @@ -27,7 +27,7 @@ class CfgWeapons { }; class LMG_Minigun: LMG_RCWS { - magazines[] = {"1000Rnd_65x39_Belt","1000Rnd_65x39_Belt_Green","1000Rnd_65x39_Belt_Tracer_Green","1000Rnd_65x39_Belt_Tracer_Red","1000Rnd_65x39_Belt_Tracer_Yellow","1000Rnd_65x39_Belt_Yellow","2000Rnd_65x39_Belt","2000Rnd_65x39_Belt_Green","2000Rnd_65x39_Belt_Tracer_Green","2000Rnd_65x39_Belt_Tracer_Green_Splash","2000Rnd_65x39_Belt_Tracer_Red","2000Rnd_65x39_Belt_Tracer_Yellow","2000Rnd_65x39_Belt_Tracer_Yellow_Splash","2000Rnd_65x39_Belt_Yellow","2000Rnd_762x51_Belt_T_Green","2000Rnd_762x51_Belt_T_Red","2000Rnd_762x51_Belt_T_Yellow","200Rnd_65x39_Belt","200Rnd_65x39_Belt_Tracer_Green","200Rnd_65x39_Belt_Tracer_Red","200Rnd_65x39_Belt_Tracer_Yellow","5000Rnd_762x51_Belt","5000Rnd_762x51_Yellow_Belt","500Rnd_65x39_Belt","500Rnd_65x39_Belt_Tracer_Red_Splash","500Rnd_65x39_Belt_Tracer_Green_Splash","500Rnd_65x39_Belt_Tracer_Yellow_Splash"}; + magazines[] = {"PylonWeapon_2000Rnd_65x39_belt", "1000Rnd_65x39_Belt","1000Rnd_65x39_Belt_Green","1000Rnd_65x39_Belt_Tracer_Green","1000Rnd_65x39_Belt_Tracer_Red","1000Rnd_65x39_Belt_Tracer_Yellow","1000Rnd_65x39_Belt_Yellow","2000Rnd_65x39_Belt","2000Rnd_65x39_Belt_Green","2000Rnd_65x39_Belt_Tracer_Green","2000Rnd_65x39_Belt_Tracer_Green_Splash","2000Rnd_65x39_Belt_Tracer_Red","2000Rnd_65x39_Belt_Tracer_Yellow","2000Rnd_65x39_Belt_Tracer_Yellow_Splash","2000Rnd_65x39_Belt_Yellow","2000Rnd_762x51_Belt_T_Green","2000Rnd_762x51_Belt_T_Red","2000Rnd_762x51_Belt_T_Yellow","200Rnd_65x39_Belt","200Rnd_65x39_Belt_Tracer_Green","200Rnd_65x39_Belt_Tracer_Red","200Rnd_65x39_Belt_Tracer_Yellow","5000Rnd_762x51_Belt","5000Rnd_762x51_Yellow_Belt","500Rnd_65x39_Belt","500Rnd_65x39_Belt_Tracer_Red_Splash","500Rnd_65x39_Belt_Tracer_Green_Splash","500Rnd_65x39_Belt_Tracer_Yellow_Splash"}; }; class HMG_127: LMG_RCWS { From b3fa074c38f5aa36303a80f303533f9f8af5cb54 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 6 Jun 2017 01:39:49 -0500 Subject: [PATCH 24/36] Disable dragging on big AA Turrets (#5251) --- addons/dragging/CfgVehicles.hpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/addons/dragging/CfgVehicles.hpp b/addons/dragging/CfgVehicles.hpp index c8e3c7284a..c4c36cea84 100644 --- a/addons/dragging/CfgVehicles.hpp +++ b/addons/dragging/CfgVehicles.hpp @@ -30,6 +30,21 @@ class CfgVehicles { GVAR(dragDirection) = 0; }; + // Big 1.70 Autonomous AA Turrets + class StaticMGWeapon; + class AAA_System_01_base_F: StaticMGWeapon { // Praetorian 1C (aka Phalanx CIWS) + GVAR(canCarry) = 0; + GVAR(canDrag) = 0; + }; + class SAM_System_01_base_F: StaticMGWeapon { // Mk49 Spartan + GVAR(canCarry) = 0; + GVAR(canDrag) = 0; + }; + class SAM_System_02_base_F: StaticMGWeapon { // Mk21 Centurion + GVAR(canCarry) = 0; + GVAR(canDrag) = 0; + }; + // ammo boxes class ThingX; class Items_base_F; From 4f90d4da804b9c2ed650b4edbc6ba82a816b48df Mon Sep 17 00:00:00 2001 From: Moritz Schmidt Date: Wed, 7 Jun 2017 02:25:51 +0200 Subject: [PATCH 25/36] note required PboProject version (#5256) * note required PboProject version * Update setting-up-the-development-environment.md --- docs/wiki/development/setting-up-the-development-environment.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/wiki/development/setting-up-the-development-environment.md b/docs/wiki/development/setting-up-the-development-environment.md index 5c70365645..c845b3efa2 100644 --- a/docs/wiki/development/setting-up-the-development-environment.md +++ b/docs/wiki/development/setting-up-the-development-environment.md @@ -17,7 +17,7 @@ This page describes how you can setup your development environment for ACE3, all - A properly setup P-drive - Run Arma 3 and Arma 3 Tools directly from steam once to install registry entries (and again after every update) - [Python 3.x](https://www.python.org/) -- [Mikero Tools](https://dev.withsix.com/projects/mikero-pbodll/files): DePbo, DeRap, DeOgg, Rapify, MakePbo, PboProject +- [Mikero Tools](https://dev.withsix.com/projects/mikero-pbodll/files): DePbo, DeRap, DeOgg, Rapify, MakePbo, PboProject >=1.70 - `*.hpp` removed from PboProject's "Exclude From Pbo" list - Python, Mikero Tools and Git in PATH environment variable - [CBA](https://github.com/CBATeam/CBA_A3/releases/latest) mod (release or development version) From ffaa195fe576625f052eeee04b1af9f3f377434f Mon Sep 17 00:00:00 2001 From: Phyma Date: Thu, 8 Jun 2017 15:31:51 +0200 Subject: [PATCH 26/36] Conform function headers to coding guidelines (#5255) * Fixed headers to work with silentspike python script * Fixed rest of the files * Fixed ace-team --- ..._calculateAmmoTemperatureVelocityShift.sqf | 3 ++ .../fnc_calculateAtmosphericCorrection.sqf | 3 ++ ...fnc_calculateBarrelLengthVelocityShift.sqf | 5 +++- .../functions/fnc_calculateRetardation.sqf | 3 ++ .../fnc_calculateStabilityFactor.sqf | 3 ++ .../functions/fnc_diagnoseWeapons.sqf | 3 ++ .../functions/fnc_displayProtractor.sqf | 3 ++ .../functions/fnc_handleFirePFH.sqf | 3 ++ .../functions/fnc_handleFired.sqf | 3 ++ .../functions/fnc_initModuleSettings.sqf | 3 ++ .../fnc_initializeTerrainExtension.sqf | 3 ++ .../functions/fnc_readAmmoDataFromConfig.sqf | 27 +++++++++-------- .../fnc_readWeaponDataFromConfig.sqf | 9 ++++-- .../functions/fnc_addDutyFactor.sqf | 5 ++++ .../functions/fnc_createStaminaBar.sqf | 5 ++++ .../functions/fnc_handlePlayerChanged.sqf | 5 ++++ .../functions/fnc_handleStaminaBar.sqf | 5 ++++ .../functions/fnc_mainLoop.sqf | 5 ++++ .../functions/fnc_moduleSettings.sqf | 5 ++++ .../functions/fnc_removeDutyFactor.sqf | 5 ++++ .../functions/fnc_moduleInit.sqf | 3 +- .../functions/fnc_renderPickUpInteraction.sqf | 2 +- addons/atragmx/functions/fnc_add_new_gun.sqf | 2 +- .../fnc_calculate_distance_at_velocity.sqf | 4 +-- .../functions/fnc_calculate_range_card.sqf | 4 +-- .../fnc_calculate_target_range_assist.sqf | 8 ++--- .../fnc_calculate_target_solution.sqf | 4 +-- .../fnc_calculate_target_speed_assist.sqf | 4 +-- .../functions/fnc_calculate_truing_drop.sqf | 8 ++--- addons/atragmx/functions/fnc_can_show.sqf | 2 +- addons/atragmx/functions/fnc_change_gun.sqf | 2 +- .../functions/fnc_change_target_slot.sqf | 2 +- ...nc_clear_c1_ballistic_coefficient_data.sqf | 4 +-- .../fnc_clear_muzzle_velocity_data.sqf | 4 +-- .../atragmx/functions/fnc_clear_user_data.sqf | 6 ++-- .../atragmx/functions/fnc_create_dialog.sqf | 4 +-- .../atragmx/functions/fnc_cycle_gun_list.sqf | 2 +- .../functions/fnc_cycle_image_size_units.sqf | 2 +- .../functions/fnc_cycle_num_ticks_units.sqf | 2 +- .../fnc_cycle_range_card_columns.sqf | 4 +-- .../functions/fnc_cycle_scope_unit.sqf | 4 +-- .../functions/fnc_cycle_target_size_units.sqf | 2 +- .../fnc_cycle_target_speed_direction.sqf | 4 +-- addons/atragmx/functions/fnc_delete_gun.sqf | 4 +-- .../fnc_evaluate_option_menu_input.sqf | 2 +- addons/atragmx/functions/fnc_init.sqf | 4 +-- addons/atragmx/functions/fnc_initGunList.sqf | 4 +-- ...c_insert_c1_ballistic_coefficient_data.sqf | 2 +- .../fnc_insert_muzzle_velocity_data.sqf | 2 +- .../atragmx/functions/fnc_on_close_dialog.sqf | 18 ++++++++++- addons/atragmx/functions/fnc_parse_input.sqf | 4 +-- .../fnc_read_gun_list_entries_from_config.sqf | 8 ++--- ...c_recalculate_c1_ballistic_coefficient.sqf | 2 +- .../fnc_recalculate_muzzle_velocity.sqf | 2 +- .../fnc_reset_relative_click_memory.sqf | 4 +-- .../functions/fnc_restore_atmo_default.sqf | 4 +-- .../functions/fnc_restore_truing_drop.sqf | 2 +- .../functions/fnc_restore_user_data.sqf | 4 +-- addons/atragmx/functions/fnc_save_gun.sqf | 4 +-- ...nc_shift_c1_ballistic_coefficient_data.sqf | 2 +- .../fnc_shift_muzzle_velocity_data.sqf | 2 +- .../functions/fnc_show_add_new_gun.sqf | 4 +-- .../functions/fnc_show_atmo_env_data.sqf | 2 +- ...fnc_show_c1_ballistic_coefficient_data.sqf | 2 +- .../functions/fnc_show_gun_ammo_data.sqf | 2 +- .../atragmx/functions/fnc_show_gun_list.sqf | 4 +-- .../atragmx/functions/fnc_show_main_page.sqf | 4 +-- .../fnc_show_muzzle_velocity_data.sqf | 2 +- .../atragmx/functions/fnc_show_range_card.sqf | 4 +-- .../functions/fnc_show_range_card_setup.sqf | 4 +-- .../functions/fnc_show_solution_setup.sqf | 2 +- .../functions/fnc_show_target_data.sqf | 2 +- .../fnc_show_target_range_assist.sqf | 4 +-- .../fnc_show_target_speed_assist.sqf | 4 +-- .../fnc_show_target_speed_assist_timer.sqf | 4 +-- .../functions/fnc_show_truing_drop.sqf | 4 +-- addons/atragmx/functions/fnc_sord.sqf | 2 +- .../atragmx/functions/fnc_store_gun_list.sqf | 4 +-- .../atragmx/functions/fnc_store_user_data.sqf | 6 ++-- .../fnc_target_speed_assist_timer.sqf | 4 +-- .../functions/fnc_toggle_atmo_env_data.sqf | 2 +- ...c_toggle_c1_ballistic_coefficient_data.sqf | 2 +- .../atragmx/functions/fnc_toggle_coriolis.sqf | 4 +-- .../functions/fnc_toggle_gun_ammo_data.sqf | 2 +- .../atragmx/functions/fnc_toggle_gun_list.sqf | 2 +- .../fnc_toggle_muzzle_velocity_data.sqf | 2 +- .../functions/fnc_toggle_option_menu.sqf | 8 ++--- .../functions/fnc_toggle_range_card.sqf | 4 +-- .../functions/fnc_toggle_range_card_setup.sqf | 2 +- .../functions/fnc_toggle_solution_setup.sqf | 2 +- .../functions/fnc_toggle_target_data.sqf | 2 +- .../fnc_toggle_target_range_assist.sqf | 2 +- .../fnc_toggle_target_speed_assist.sqf | 2 +- .../functions/fnc_toggle_truing_drop.sqf | 2 +- .../atragmx/functions/fnc_trim_gun_name.sqf | 4 +-- .../fnc_true_c1_ballistic_coefficient.sqf | 4 +-- .../functions/fnc_true_muzzle_velocity.sqf | 4 +-- .../functions/fnc_update_atmo_env_data.sqf | 4 +-- .../functions/fnc_update_atmo_selection.sqf | 4 +-- .../functions/fnc_update_atmosphere.sqf | 4 +-- ...c_update_c1_ballistic_coefficient_data.sqf | 4 +-- addons/atragmx/functions/fnc_update_gun.sqf | 4 +-- .../functions/fnc_update_gun_ammo_data.sqf | 4 +-- .../fnc_update_inclination_angle.sqf | 2 +- .../fnc_update_muzzle_velocity_data.sqf | 4 +-- .../functions/fnc_update_range_card.sqf | 4 +-- .../fnc_update_relative_click_memory.sqf | 4 +-- .../atragmx/functions/fnc_update_result.sqf | 6 ++-- .../functions/fnc_update_scope_unit.sqf | 6 ++-- .../functions/fnc_update_solution_setup.sqf | 4 +-- .../atragmx/functions/fnc_update_target.sqf | 4 +-- .../functions/fnc_update_target_data.sqf | 4 +-- .../functions/fnc_update_target_selection.sqf | 4 +-- .../functions/fnc_update_truing_drop_data.sqf | 4 +-- .../fnc_update_truing_drop_selection.sqf | 4 +-- .../functions/fnc_update_unit_selection.sqf | 4 +-- .../functions/fnc_update_zero_range.sqf | 4 +-- addons/attach/functions/fnc_attach.sqf | 2 +- addons/attach/functions/fnc_detach.sqf | 4 +-- addons/attach/functions/fnc_placeApprove.sqf | 2 +- .../functions/fnc_backpackOpened.sqf | 9 ++++-- addons/backpacks/functions/fnc_isBackpack.sqf | 3 ++ .../functions/fnc_onOpenInventory.sqf | 5 +++- .../captives/functions/fnc_doFriskPerson.sqf | 2 +- .../captives/functions/fnc_doLoadCaptive.sqf | 2 +- .../functions/fnc_doUnloadCaptive.sqf | 2 +- .../fnc_handleAnimChangedHandcuffed.sqf | 5 +++- .../fnc_handleAnimChangedSurrendered.sqf | 5 +++- addons/captives/functions/fnc_handleLocal.sqf | 5 +++- .../functions/fnc_handleOnUnconscious.sqf | 2 +- .../captives/functions/fnc_handleRespawn.sqf | 2 +- .../fnc_handleZeusDisplayChanged.sqf | 2 +- .../functions/fnc_moduleHandcuffed.sqf | 2 +- .../captives/functions/fnc_moduleSettings.sqf | 3 ++ .../functions/fnc_moduleSurrender.sqf | 2 +- .../captives/functions/fnc_setHandcuffed.sqf | 2 +- .../captives/functions/fnc_setSurrendered.sqf | 2 +- .../functions/fnc_vehicleCaptiveMoveIn.sqf | 2 +- .../functions/fnc_vehicleCaptiveMoveOut.sqf | 2 +- addons/cargo/functions/fnc_paradropItem.sqf | 2 +- .../functions/fnc_compileChemlightMenu.sqf | 4 +-- .../functions/fnc_getShieldComponents.sqf | 2 +- .../chemlights/functions/fnc_prepShield.sqf | 2 +- addons/common/functions/fnc_ASLToPosition.sqf | 3 ++ .../fnc__handleRequestAllSyncedEvents.sqf | 3 ++ .../fnc__handleRequestSyncedEvent.sqf | 8 +++-- .../functions/fnc__handleSyncedEvent.sqf | 5 +++- .../functions/fnc_addActionEventHandler.sqf | 3 ++ .../fnc_addActionMenuEventHandler.sqf | 3 ++ .../fnc_addCanInteractWithCondition.sqf | 3 ++ .../functions/fnc_addLineToDebugDraw.sqf | 2 +- .../fnc_addMapMarkerCreatedEventHandler.sqf | 3 ++ addons/common/functions/fnc_addSetting.sqf | 3 ++ .../common/functions/fnc_addToInventory.sqf | 3 ++ .../functions/fnc_ambientBrightness.sqf | 3 ++ .../functions/fnc_arithmeticGetResult.sqf | 2 +- .../functions/fnc_arithmeticSetSource.sqf | 2 +- .../common/functions/fnc_assignedItemFix.sqf | 5 +++- .../common/functions/fnc_binarizeNumber.sqf | 3 ++ addons/common/functions/fnc_blurScreen.sqf | 2 +- addons/common/functions/fnc_cachedCall.sqf | 3 ++ .../common/functions/fnc_canGetInPosition.sqf | 6 ++-- .../common/functions/fnc_canInteractWith.sqf | 5 +++- .../fnc_changeProjectileDirection.sqf | 3 ++ addons/common/functions/fnc_checkFiles.sqf | 3 ++ addons/common/functions/fnc_checkPBOs.sqf | 3 ++ addons/common/functions/fnc_claim.sqf | 3 ++ addons/common/functions/fnc_codeToString.sqf | 3 ++ .../fnc_createOrthonormalReference.sqf | 5 +++- .../common/functions/fnc_currentChannel.sqf | 3 ++ addons/common/functions/fnc_debug.sqf | 3 ++ addons/common/functions/fnc_debugModule.sqf | 3 ++ .../common/functions/fnc_defineVariable.sqf | 3 ++ .../functions/fnc_deviceKeyFindValidIndex.sqf | 2 +- .../common/functions/fnc_disableUserInput.sqf | 3 ++ addons/common/functions/fnc_displayText.sqf | 3 ++ addons/common/functions/fnc_dropBackpack.sqf | 3 ++ .../functions/fnc_dumpPerformanceCounters.sqf | 3 ++ .../functions/fnc_endRadioTransmission.sqf | 3 ++ addons/common/functions/fnc_eraseCache.sqf | 3 ++ addons/common/functions/fnc_errorMessage.sqf | 3 ++ addons/common/functions/fnc_firedEH.sqf | 3 ++ addons/common/functions/fnc_fixCollision.sqf | 3 ++ addons/common/functions/fnc_fixFloating.sqf | 3 ++ .../fnc_fixLoweredRifleAnimation.sqf | 2 +- addons/common/functions/fnc_fixPosition.sqf | 3 ++ .../fnc_getAllDefinedSetVariables.sqf | 3 ++ addons/common/functions/fnc_getChildren.sqf | 3 ++ .../functions/fnc_getConfigCommander.sqf | 3 ++ .../common/functions/fnc_getConfigGunner.sqf | 3 ++ .../functions/fnc_getDefinedVariable.sqf | 3 ++ .../fnc_getDefinedVariableDefault.sqf | 3 ++ .../functions/fnc_getDefinedVariableInfo.sqf | 3 ++ .../functions/fnc_getDisplayConfigName.sqf | 3 ++ .../common/functions/fnc_getDoorTurrets.sqf | 3 ++ .../fnc_getFirstObjectIntersection.sqf | 3 ++ .../fnc_getFirstTerrainIntersection.sqf | 3 ++ addons/common/functions/fnc_getGunner.sqf | 3 ++ addons/common/functions/fnc_getInPosition.sqf | 11 ++++--- addons/common/functions/fnc_getItemType.sqf | 3 ++ .../functions/fnc_getLightProperties.sqf | 3 ++ .../fnc_getLightPropertiesWeapon.sqf | 3 ++ addons/common/functions/fnc_getMGRSdata.sqf | 3 ++ addons/common/functions/fnc_getMapData.sqf | 3 ++ .../functions/fnc_getMapPosFromGrid.sqf | 2 +- addons/common/functions/fnc_getMarkerType.sqf | 5 +++- .../functions/fnc_getNumberMagazinesIn.sqf | 3 ++ .../common/functions/fnc_getPitchBankYaw.sqf | 3 ++ .../fnc_getReflectorsWithSelections.sqf | 3 ++ .../fnc_getSelectionsWithoutHitPoints.sqf | 9 ++++-- .../common/functions/fnc_getSettingData.sqf | 5 +++- .../functions/fnc_getStaminaBarControl.sqf | 3 ++ .../fnc_getTargetAzimuthAndInclination.sqf | 3 ++ .../functions/fnc_getTargetDistance.sqf | 3 ++ .../common/functions/fnc_getTargetObject.sqf | 3 ++ .../functions/fnc_getTurnedOnLights.sqf | 3 ++ .../functions/fnc_getTurretCommander.sqf | 3 ++ .../functions/fnc_getTurretConfigPath.sqf | 3 ++ .../common/functions/fnc_getTurretCopilot.sqf | 3 ++ .../functions/fnc_getTurretDirection.sqf | 3 ++ .../common/functions/fnc_getTurretGunner.sqf | 3 ++ addons/common/functions/fnc_getTurretsFFV.sqf | 3 ++ .../common/functions/fnc_getTurretsOther.sqf | 3 ++ .../common/functions/fnc_getVehicleCargo.sqf | 3 ++ .../functions/fnc_getVehicleCodriver.sqf | 3 ++ .../common/functions/fnc_getVehicleCrew.sqf | 3 ++ .../functions/fnc_getVehicleUAVCrew.sqf | 3 ++ addons/common/functions/fnc_getVersion.sqf | 3 ++ .../fnc_getWeaponAzimuthAndInclination.sqf | 3 ++ .../common/functions/fnc_getWeaponIndex.sqf | 3 ++ .../common/functions/fnc_getWeaponModes.sqf | 3 ++ .../common/functions/fnc_getWeaponMuzzles.sqf | 3 ++ .../common/functions/fnc_getWeaponState.sqf | 5 +++- addons/common/functions/fnc_getWeaponType.sqf | 3 ++ .../common/functions/fnc_getWindDirection.sqf | 3 ++ addons/common/functions/fnc_getZoom.sqf | 5 +++- addons/common/functions/fnc_goKneeling.sqf | 3 ++ .../common/functions/fnc_hadamardProduct.sqf | 3 ++ addons/common/functions/fnc_handleEngine.sqf | 3 ++ .../functions/fnc_handleModifierKey.sqf | 5 +++- .../functions/fnc_handleModifierKeyUp.sqf | 5 +++- addons/common/functions/fnc_hasHatch.sqf | 3 ++ addons/common/functions/fnc_hasItem.sqf | 3 ++ addons/common/functions/fnc_hasMagazine.sqf | 3 ++ addons/common/functions/fnc_headBugFix.sqf | 3 ++ addons/common/functions/fnc_hideUnit.sqf | 2 +- .../common/functions/fnc_inTransitionAnim.sqf | 7 +++-- .../functions/fnc_interpolateFromArray.sqf | 3 ++ addons/common/functions/fnc_isAwake.sqf | 3 ++ addons/common/functions/fnc_isInBuilding.sqf | 3 ++ addons/common/functions/fnc_isModLoaded.sqf | 3 ++ addons/common/functions/fnc_isUnderwater.sqf | 3 ++ .../fnc_lightIntensityFromObject.sqf | 5 +++- addons/common/functions/fnc_loadPerson.sqf | 3 ++ .../common/functions/fnc_loadPersonLocal.sqf | 3 ++ .../functions/fnc_loadSettingsFromProfile.sqf | 3 ++ .../fnc_loadSettingsLocalizedText.sqf | 3 ++ .../functions/fnc_loadSettingsOnServer.sqf | 3 ++ .../common/functions/fnc_moduleCheckPBOs.sqf | 3 ++ .../functions/fnc_moduleLSDVehicles.sqf | 3 ++ addons/common/functions/fnc_monitor.sqf | 3 ++ addons/common/functions/fnc_muteUnit.sqf | 3 ++ .../functions/fnc_muteUnitHandleInitPost.sqf | 3 ++ .../functions/fnc_muteUnitHandleRespawn.sqf | 3 ++ .../common/functions/fnc_numberToDigits.sqf | 3 ++ .../functions/fnc_numberToDigitsString.sqf | 5 +++- .../common/functions/fnc_numberToString.sqf | 3 ++ .../common/functions/fnc_onAnswerRequest.sqf | 9 ++++-- addons/common/functions/fnc_owned.sqf | 5 +++- .../functions/fnc_playConfigSound3D.sqf | 3 ++ addons/common/functions/fnc_player.sqf | 3 ++ addons/common/functions/fnc_playerSide.sqf | 3 ++ addons/common/functions/fnc_positionToASL.sqf | 3 ++ addons/common/functions/fnc_progressBar.sqf | 16 +++++----- .../functions/fnc_readSettingFromModule.sqf | 3 ++ .../common/functions/fnc_receiveRequest.sqf | 9 +++++- .../fnc_removeActionEventHandler.sqf | 3 ++ .../fnc_removeActionMenuEventHandler.sqf | 3 ++ .../fnc_removeCanInteractWithCondition.sqf | 3 ++ ...fnc_removeMapMarkerCreatedEventHandler.sqf | 3 ++ .../functions/fnc_removeSpecificMagazine.sqf | 3 ++ .../fnc_removeSyncedEventHandler.sqf | 5 +++- .../common/functions/fnc_requestCallback.sqf | 7 +++-- .../functions/fnc_requestSyncedEvent.sqf | 5 +++- .../common/functions/fnc_resetAllDefaults.sqf | 7 +++-- .../functions/fnc_restoreVariablesJIP.sqf | 3 ++ addons/common/functions/fnc_sendRequest.sqf | 9 ++++-- .../fnc_setApproximateVariablePublic.sqf | 2 +- .../functions/fnc_setDefinedVariable.sqf | 3 ++ .../fnc_setDisableUserInputStatus.sqf | 3 ++ addons/common/functions/fnc_setName.sqf | 3 ++ addons/common/functions/fnc_setParameter.sqf | 5 +++- .../common/functions/fnc_setPitchBankYaw.sqf | 3 ++ addons/common/functions/fnc_setProne.sqf | 3 ++ .../functions/fnc_setSettingFromConfig.sqf | 3 ++ .../common/functions/fnc_setVariableJIP.sqf | 3 ++ .../functions/fnc_setVariablePublic.sqf | 2 +- addons/common/functions/fnc_setVolume.sqf | 3 ++ addons/common/functions/fnc_showUser.sqf | 3 ++ .../functions/fnc_statusEffect_addType.sqf | 2 +- .../functions/fnc_statusEffect_localEH.sqf | 5 ++-- .../fnc_statusEffect_resetVariables.sqf | 2 +- .../functions/fnc_statusEffect_respawnEH.sqf | 4 +-- .../fnc_statusEffect_sendEffects.sqf | 2 +- .../common/functions/fnc_statusEffect_set.sqf | 2 +- addons/common/functions/fnc_stringCompare.sqf | 5 +++- .../functions/fnc_stringToColoredText.sqf | 3 ++ .../functions/fnc_switchToGroupSide.sqf | 3 ++ addons/common/functions/fnc_syncedEvent.sqf | 3 ++ .../common/functions/fnc_syncedEventPFH.sqf | 9 ++++-- addons/common/functions/fnc_toBin.sqf | 3 ++ addons/common/functions/fnc_toBitmask.sqf | 3 ++ addons/common/functions/fnc_toHex.sqf | 3 ++ addons/common/functions/fnc_toNumber.sqf | 2 +- .../functions/fnc_translateToModelSpace.sqf | 11 ++++--- .../functions/fnc_translateToWeaponSpace.sqf | 11 ++++--- .../common/functions/fnc_uniqueElements.sqf | 3 ++ .../functions/fnc_unloadPersonLocal.sqf | 3 ++ addons/common/functions/fnc_unmuteUnit.sqf | 3 ++ addons/common/functions/fnc_useItem.sqf | 3 ++ addons/common/functions/fnc_useMagazine.sqf | 3 ++ addons/common/functions/fnc_watchVariable.sqf | 2 +- addons/common/functions/fnc_waveHeightAt.sqf | 6 ++-- .../functions/fnc_worldToScreenBounds.sqf | 3 ++ .../concertina_wire/functions/fnc_deploy.sqf | 3 ++ .../functions/fnc_dismount.sqf | 3 ++ .../functions/fnc_dismountSuccess.sqf | 3 ++ .../functions/fnc_handleDamage.sqf | 3 ++ .../functions/fnc_handleKilled.sqf | 3 ++ .../functions/fnc_vehicleDamage.sqf | 3 ++ addons/cookoff/functions/fnc_handleDamage.sqf | 4 +-- .../functions/fnc_handleRangeFinderData.sqf | 2 +- addons/dagr/functions/fnc_menuInit.sqf | 4 +-- addons/dagr/functions/fnc_outputData.sqf | 5 ++-- addons/dagr/functions/fnc_outputVector.sqf | 8 +++-- addons/dagr/functions/fnc_outputWP.sqf | 7 +++-- addons/dagr/functions/fnc_toggleOverlay.sqf | 5 ++-- .../functions/fnc_disarmDropItems.sqf | 2 +- .../functions/fnc_eventTargetFinish.sqf | 2 +- .../functions/fnc_eventTargetStart.sqf | 4 +-- .../functions/fnc_showItemsInListbox.sqf | 2 +- .../functions/fnc_replaceATWeapon.sqf | 2 +- .../functions/fnc_isObjectOnObject.sqf | 4 +-- .../dragging/functions/fnc_setDraggable.sqf | 4 +-- .../functions/fnc_addExplosiveActions.sqf | 5 +++- .../functions/fnc_addTransmitterActions.sqf | 2 +- .../explosives/functions/fnc_interactEH.sqf | 2 +- .../explosives/functions/fnc_startDefuse.sqf | 2 +- .../functions/fnc_deployAIWaypoint.sqf | 2 +- .../fastroping/functions/fnc_onRopeBreak.sqf | 3 ++ addons/fcs/functions/fnc_adjustRange.sqf | 3 ++ .../fcs/functions/fnc_calculateSolution.sqf | 11 ++++--- addons/fcs/functions/fnc_canResetFCS.sqf | 5 +++- .../fcs/functions/fnc_canUseRangefinder.sqf | 3 ++ addons/fcs/functions/fnc_firedEH.sqf | 3 ++ addons/fcs/functions/fnc_getAngle.sqf | 3 ++ addons/fcs/functions/fnc_getRange.sqf | 3 ++ .../fnc_handleAirBurstAmmunitionPFH.sqf | 3 ++ addons/fcs/functions/fnc_keyDown.sqf | 3 ++ addons/fcs/functions/fnc_keyUp.sqf | 3 ++ addons/fcs/functions/fnc_onForceUpdate.sqf | 16 ++++++++++ addons/fcs/functions/fnc_reset.sqf | 5 +++- addons/fcs/functions/fnc_updateRangeHUD.sqf | 3 ++ addons/fcs/functions/fnc_vehicleInit.sqf | 7 +++-- .../finger/functions/fnc_moduleSettings.sqf | 3 ++ addons/frag/functions/fnc_addBlackList.sqf | 2 +- addons/frag/functions/fnc_addPfhRound.sqf | 2 +- addons/frag/functions/fnc_dev_addTrack.sqf | 16 ++++++++++ addons/frag/functions/fnc_dev_debugAmmo.sqf | 16 ++++++++++ addons/frag/functions/fnc_dev_drawTraces.sqf | 16 ++++++++++ .../frag/functions/fnc_dev_startTracing.sqf | 16 ++++++++++ addons/frag/functions/fnc_dev_stopTracing.sqf | 15 ++++++++++ addons/frag/functions/fnc_dev_trackTrace.sqf | 16 ++++++++++ addons/frag/functions/fnc_doExplosions.sqf | 16 ++++++++++ addons/frag/functions/fnc_doReflections.sqf | 16 ++++++++++ addons/frag/functions/fnc_doSpall.sqf | 16 ++++++++++ addons/frag/functions/fnc_findReflections.sqf | 18 ++++++++++- addons/frag/functions/fnc_fired.sqf | 4 +-- addons/frag/functions/fnc_frago.sqf | 2 +- addons/frag/functions/fnc_masterPFH.sqf | 6 ++++ addons/frag/functions/fnc_pfhRound.sqf | 16 ++++++++++ addons/frag/functions/fnc_spallHP.sqf | 16 ++++++++++ addons/frag/functions/fnc_spallTrack.sqf | 16 ++++++++++ addons/gestures/functions/fnc_playSignal.sqf | 2 +- addons/gforces/functions/fnc_addPFEH.sqf | 3 ++ .../functions/fnc_pfhUpdateGForces.sqf | 3 ++ .../goggles/functions/fnc_handleExplosion.sqf | 3 ++ addons/goggles/functions/fnc_handleFired.sqf | 3 ++ addons/goggles/functions/fnc_handleKilled.sqf | 3 ++ .../goggles/functions/fnc_isInRotorWash.sqf | 2 +- addons/gunbag/functions/fnc_canInteract.sqf | 2 +- .../hearing/functions/fnc_handleRespawn.sqf | 2 +- .../hearing/functions/fnc_hasEarPlugsIn.sqf | 2 +- .../hearing/functions/fnc_moduleHearing.sqf | 7 ++++- .../hearing/functions/fnc_putInEarplugs.sqf | 2 +- .../hearing/functions/fnc_removeEarplugs.sqf | 2 +- .../hitreactions/functions/fnc_fallDown.sqf | 3 ++ .../functions/fnc_getRandomAnimation.sqf | 3 ++ addons/huntir/functions/fnc_cam.sqf | 3 ++ addons/huntir/functions/fnc_handleFired.sqf | 3 ++ addons/huntir/functions/fnc_huntir.sqf | 3 ++ addons/huntir/functions/fnc_huntirCompass.sqf | 3 ++ addons/huntir/functions/fnc_keyPressed.sqf | 2 +- .../functions/fnc_collectActiveActionTree.sqf | 3 ++ .../functions/fnc_compileMenu.sqf | 3 ++ .../functions/fnc_compileMenuSelfAction.sqf | 3 ++ .../functions/fnc_compileMenuZeus.sqf | 5 +++- .../functions/fnc_ctrlSetParsedTextCached.sqf | 3 ++ .../interact_menu/functions/fnc_isSubPath.sqf | 2 +- .../interact_menu/functions/fnc_keyDown.sqf | 3 ++ addons/interact_menu/functions/fnc_keyUp.sqf | 3 ++ .../functions/fnc_renderActionPoints.sqf | 3 ++ .../functions/fnc_renderBaseMenu.sqf | 3 ++ .../functions/fnc_renderIcon.sqf | 3 ++ .../functions/fnc_renderMenu.sqf | 3 ++ .../functions/fnc_renderSelector.sqf | 3 ++ .../functions/fnc_setupTextColors.sqf | 3 ++ .../interact_menu/functions/fnc_splitPath.sqf | 3 ++ .../fnc_userActions_addHouseActions.sqf | 2 +- .../fnc_userActions_getHouseActions.sqf | 2 +- .../interaction/functions/fnc_canPardon.sqf | 3 ++ .../functions/fnc_doBecomeLeader.sqf | 3 +- .../functions/fnc_getInteractionDistance.sqf | 2 +- .../functions/fnc_getVehiclePos.sqf | 2 +- .../functions/fnc_getVehiclePosComplex.sqf | 2 +- .../functions/fnc_handleScrollWheel.sqf | 3 ++ addons/interaction/functions/fnc_pardon.sqf | 3 ++ .../functions/fnc_addCustomFilter.sqf | 3 ++ .../functions/fnc_currentItemListBox.sqf | 3 ++ .../functions/fnc_filterBackpacks.sqf | 3 ++ .../functions/fnc_filterGrenades.sqf | 3 ++ .../functions/fnc_filterHeadgear.sqf | 3 ++ .../inventory/functions/fnc_filterItems.sqf | 3 ++ .../functions/fnc_filterMagazines.sqf | 3 ++ .../inventory/functions/fnc_filterMedical.sqf | 3 ++ .../functions/fnc_filterUniforms.sqf | 3 ++ .../inventory/functions/fnc_filterVests.sqf | 3 ++ .../inventory/functions/fnc_filterWeapons.sqf | 3 ++ .../functions/fnc_forceItemListUpdate.sqf | 3 ++ .../functions/fnc_inventoryDisplayLoad.sqf | 3 ++ .../functions/fnc_onLBSelChanged.sqf | 3 ++ addons/javelin/functions/fnc_getTarget.sqf | 12 ++++---- addons/laser/functions/fnc_addLaserTarget.sqf | 2 +- .../fnc_dev_drawVisibleLaserTargets.sqf | 17 +++++++++++ .../laser/functions/fnc_findLaserSource.sqf | 8 ++--- .../fnc_handleLaserTargetCreation.sqf | 5 +--- .../functions/fnc_keyLaserCodeChange.sqf | 2 +- addons/laser/functions/fnc_laserOff.sqf | 2 +- addons/laser/functions/fnc_laserOn.sqf | 2 +- addons/laser/functions/fnc_laserTargetPFH.sqf | 2 +- addons/laser/functions/fnc_rotateVectLine.sqf | 16 ++++++++++ .../functions/fnc_rotateVectLineGetMap.sqf | 16 ++++++++++ .../functions/fnc_seekerFindLaserSpot.sqf | 2 +- addons/laser/functions/fnc_shootCone.sqf | 6 ++-- addons/laser/functions/fnc_shootRay.sqf | 4 +-- .../functions/fnc_getNearUnits.sqf | 3 ++ addons/laserpointer/functions/fnc_onDraw.sqf | 3 ++ .../functions/fnc_refuelUAV.sqf | 2 +- .../functions/fnc_cutDownFence.sqf | 2 +- .../functions/fnc_interactEH.sqf | 2 +- .../functions/fnc_startRepackingMagazine.sqf | 2 +- .../functions/fnc_blueForceTrackingModule.sqf | 23 ++++++++------ .../functions/fnc_blueForceTrackingUpdate.sqf | 17 +++++++++++ .../map/functions/fnc_determineMapLight.sqf | 3 ++ addons/map/functions/fnc_determineZoom.sqf | 26 +++++++++------- addons/map/functions/fnc_moduleMap.sqf | 7 ++++- addons/map/functions/fnc_onDrawMap.sqf | 17 ++++++++++- addons/map/functions/fnc_simulateMapLight.sqf | 3 ++ addons/map/functions/fnc_updateMapEffects.sqf | 3 ++ .../functions/fnc_calculateMapScale.sqf | 5 +++- .../maptools/functions/fnc_canUseMapGPS.sqf | 5 +++- .../maptools/functions/fnc_canUseMapTools.sqf | 5 +++- .../functions/fnc_drawLinesOnRoamer.sqf | 2 +- .../functions/fnc_handleMouseButton.sqf | 22 +++++++++----- .../functions/fnc_handleMouseMove.sqf | 11 +++++-- .../functions/fnc_isInsideMapTool.sqf | 8 ++++- addons/maptools/functions/fnc_openMapGps.sqf | 5 +++- .../functions/fnc_openMapGpsUpdate.sqf | 17 +++++++++-- .../functions/fnc_updateMapToolMarkers.sqf | 5 +++- .../functions/fnc_getEnabledChannels.sqf | 3 ++ .../functions/fnc_onLBSelChangedChannel.sqf | 3 ++ .../fnc_actionCheckBloodPressure.sqf | 27 +++++++++-------- .../fnc_actionCheckBloodPressureLocal.sqf | 3 ++ .../functions/fnc_actionCheckPulse.sqf | 27 +++++++++-------- .../functions/fnc_actionCheckPulseLocal.sqf | 3 ++ .../functions/fnc_actionCheckResponse.sqf | 3 ++ .../medical/functions/fnc_actionDiagnose.sqf | 27 +++++++++-------- .../medical/functions/fnc_actionLoadUnit.sqf | 3 ++ .../functions/fnc_actionRemoveTourniquet.sqf | 3 ++ .../functions/fnc_actionUnloadUnit.sqf | 3 ++ .../functions/fnc_addHeartRateAdjustment.sqf | 3 ++ .../functions/fnc_addToInjuredCollection.sqf | 10 +++++-- addons/medical/functions/fnc_addToLog.sqf | 3 ++ .../medical/functions/fnc_addToTriageCard.sqf | 3 ++ .../functions/fnc_addUnconsciousCondition.sqf | 5 +++- .../functions/fnc_addUnloadPatientActions.sqf | 3 ++ addons/medical/functions/fnc_addVitalLoop.sqf | 5 +++- .../medical/functions/fnc_bodyCleanupLoop.sqf | 5 +++- .../fnc_canAccessMedicalEquipment.sqf | 5 +++- addons/medical/functions/fnc_canTreat.sqf | 2 +- .../medical/functions/fnc_canTreatCached.sqf | 5 +++- addons/medical/functions/fnc_copyDeadBody.sqf | 3 ++ addons/medical/functions/fnc_createLitter.sqf | 7 +++-- .../functions/fnc_determineIfFatal.sqf | 3 ++ .../fnc_displayPatientInformation.sqf | 5 +++- .../functions/fnc_displayTriageCard.sqf | 3 ++ .../functions/fnc_dropDownTriageCard.sqf | 3 ++ addons/medical/functions/fnc_getBloodLoss.sqf | 5 +++- .../functions/fnc_getBloodPressure.sqf | 5 +++- .../functions/fnc_getBloodVolumeChange.sqf | 5 +++- .../functions/fnc_getCardiacOutput.sqf | 5 +++- .../functions/fnc_getHeartRateChange.sqf | 5 +++- .../medical/functions/fnc_getTriageStatus.sqf | 3 ++ .../medical/functions/fnc_getTypeOfDamage.sqf | 5 +++- .../functions/fnc_getUnconsciousCondition.sqf | 5 +++- .../functions/fnc_handleBandageOpening.sqf | 3 ++ .../functions/fnc_handleCollisionDamage.sqf | 18 ++++++++++- .../functions/fnc_handleCreateLitter.sqf | 3 ++ addons/medical/functions/fnc_handleDamage.sqf | 7 +++-- .../functions/fnc_handleDamage_advanced.sqf | 7 +++-- .../fnc_handleDamage_advancedSetDamage.sqf | 3 ++ .../functions/fnc_handleDamage_airway.sqf | 3 ++ .../functions/fnc_handleDamage_caching.sqf | 5 +++- .../functions/fnc_handleDamage_fractures.sqf | 3 ++ .../fnc_handleDamage_internalInjuries.sqf | 3 ++ .../functions/fnc_handleDamage_wounds.sqf | 3 ++ .../functions/fnc_handleDamage_woundsOld.sqf | 3 ++ addons/medical/functions/fnc_handleKilled.sqf | 5 +++- addons/medical/functions/fnc_handleLocal.sqf | 5 +++- .../functions/fnc_handleUnitVitals.sqf | 7 +++-- addons/medical/functions/fnc_hasItem.sqf | 7 +++-- addons/medical/functions/fnc_hasItems.sqf | 5 +++- .../functions/fnc_hasMedicalEnabled.sqf | 2 +- .../functions/fnc_hasTourniquetAppliedTo.sqf | 5 +++- addons/medical/functions/fnc_init.sqf | 7 +++-- .../functions/fnc_isInMedicalFacility.sqf | 2 +- .../functions/fnc_isInStableCondition.sqf | 25 +++++++++------- addons/medical/functions/fnc_isMedic.sqf | 2 +- .../functions/fnc_isMedicalVehicle.sqf | 6 +++- addons/medical/functions/fnc_itemCheck.sqf | 5 +++- .../functions/fnc_litterCleanupLoop.sqf | 5 +++- .../functions/fnc_medicationEffectLoop.sqf | 5 +++- .../functions/fnc_modifyMedicalAction.sqf | 5 +++- .../fnc_moduleAdvancedMedicalSettings.sqf | 3 ++ .../functions/fnc_moduleAssignMedicRoles.sqf | 3 ++ .../fnc_moduleAssignMedicalFacility.sqf | 3 ++ .../fnc_moduleAssignMedicalVehicle.sqf | 3 ++ .../fnc_moduleBasicMedicalSettings.sqf | 3 ++ .../functions/fnc_moduleMedicalSettings.sqf | 3 ++ .../functions/fnc_moduleReviveSettings.sqf | 3 ++ .../functions/fnc_onMedicationUsage.sqf | 3 ++ .../functions/fnc_parseConfigForInjuries.sqf | 6 +++- .../functions/fnc_playInjuredSound.sqf | 5 +++- .../medical/functions/fnc_reviveStateLoop.sqf | 5 +++- .../functions/fnc_selectionNameToNumber.sqf | 5 +++- .../functions/fnc_serverRemoveBody.sqf | 2 +- .../functions/fnc_setCardiacArrest.sqf | 5 +++- addons/medical/functions/fnc_setDead.sqf | 9 ++++-- .../functions/fnc_setHitPointDamage.sqf | 3 ++ .../functions/fnc_setStructuralDamage.sqf | 7 +++-- .../medical/functions/fnc_setUnconscious.sqf | 4 +-- .../medical/functions/fnc_showBloodEffect.sqf | 3 ++ addons/medical/functions/fnc_treatment.sqf | 3 ++ .../functions/fnc_treatmentAdvanced_CPR.sqf | 3 ++ .../fnc_treatmentAdvanced_CPRLocal.sqf | 3 ++ .../fnc_treatmentAdvanced_bandage.sqf | 3 ++ .../fnc_treatmentAdvanced_bandageLocal.sqf | 3 ++ .../fnc_treatmentAdvanced_fullHeal.sqf | 24 ++++++++++----- .../fnc_treatmentAdvanced_fullHealLocal.sqf | 21 ++++++++----- .../fnc_treatmentAdvanced_medication.sqf | 3 ++ .../fnc_treatmentAdvanced_medicationLocal.sqf | 3 ++ ...eatmentAdvanced_surgicalKit_onProgress.sqf | 3 ++ .../functions/fnc_treatmentBasic_bloodbag.sqf | 3 ++ .../fnc_treatmentBasic_bloodbagLocal.sqf | 5 +++- .../functions/fnc_treatmentBasic_epipen.sqf | 3 ++ .../functions/fnc_treatmentBasic_morphine.sqf | 3 ++ .../fnc_treatmentBasic_morphineLocal.sqf | 3 ++ addons/medical/functions/fnc_treatmentIV.sqf | 3 ++ .../functions/fnc_treatmentIVLocal.sqf | 3 ++ .../functions/fnc_treatmentTourniquet.sqf | 3 ++ .../fnc_treatmentTourniquetLocal.sqf | 3 ++ .../functions/fnc_treatment_failure.sqf | 3 ++ .../functions/fnc_treatment_success.sqf | 3 ++ .../medical/functions/fnc_unconsciousPFH.sqf | 8 +++-- addons/medical/functions/fnc_useItem.sqf | 5 +++- addons/medical/functions/fnc_useItems.sqf | 5 +++- addons/medical/functions/fnc_vitalLoop.sqf | 5 +++- .../functions/fnc_canRequestMedic.sqf | 3 ++ addons/medical_ai/functions/fnc_healSelf.sqf | 5 +++- addons/medical_ai/functions/fnc_healUnit.sqf | 5 +++- addons/medical_ai/functions/fnc_isInjured.sqf | 3 ++ addons/medical_ai/functions/fnc_isSafe.sqf | 3 ++ .../functions/fnc_playTreatmentAnim.sqf | 5 +++- .../medical_ai/functions/fnc_requestMedic.sqf | 5 +++- .../medical_ai/functions/fnc_wasRequested.sqf | 3 ++ addons/medical_blood/functions/fnc_hit.sqf | 3 ++ .../functions/fnc_getTreatmentOptions.sqf | 2 +- addons/medical_menu/functions/fnc_module.sqf | 3 ++ .../functions/fnc_setTriageStatus.sqf | 3 ++ .../functions/fnc_updateInformationLists.sqf | 3 ++ .../functions/fnc_detectorLoop.sqf | 3 ++ .../fnc_cycleAttackProfileKeyDown.sqf | 1 + .../functions/fnc_doHandoff.sqf | 18 ++++++++++- .../functions/fnc_guidancePFH.sqf | 6 ++-- .../functions/fnc_handleHandoff.sqf | 18 ++++++++++- .../missileguidance/functions/fnc_onFired.sqf | 2 +- .../functions/fnc_moduleAmbianceSound.sqf | 4 +-- .../functions/fnc_dev_buildTable.sqf | 4 +-- .../functions/fnc_dev_formatNumber.sqf | 30 +++++++++---------- .../fnc_dev_simulateCalcRangeTableLine.sqf | 30 +++++++++---------- .../fnc_dev_simulateFindSolution.sqf | 8 ++--- .../mk6mortar/functions/fnc_handleFired.sqf | 2 +- .../fnc_handlePlayerVehicleChanged.sqf | 2 +- .../functions/fnc_rangeTableOpen.sqf | 4 +-- .../functions/fnc_rangeTablePageChange.sqf | 4 +-- .../fnc_rangeTablePreCalculatedValues.sqf | 4 +-- addons/mk6mortar/functions/fnc_toggleMils.sqf | 2 +- addons/modules/functions/fnc_moduleInit.sqf | 5 +++- .../functions/fnc_addLoadToUnitContainer.sqf | 3 ++ addons/movement/functions/fnc_climb.sqf | 2 +- addons/movement/functions/fnc_handleClimb.sqf | 2 +- .../functions/fnc_handleVirtualMass.sqf | 5 +++- .../nametags/functions/fnc_getCachedFlags.sqf | 2 +- .../nametags/functions/fnc_moduleNameTags.sqf | 5 ++++ addons/nightvision/functions/fnc_blending.sqf | 2 +- .../functions/fnc_changeNVGBrightness.sqf | 2 +- .../functions/fnc_updatePPEffects.sqf | 4 +-- addons/optics/functions/fnc_handleFired.sqf | 8 ++++- addons/optics/functions/fnc_onDrawScope.sqf | 17 ++++++++++- addons/optics/functions/fnc_onDrawScope2D.sqf | 2 +- .../functions/fnc_moduleAllowConfigExport.sqf | 5 +++- .../fnc_toggleIncludeClientSettings.sqf | 3 ++ .../fnc_canCheckSpareBarrelsTemperatures.sqf | 5 +++- .../functions/fnc_canSwapBarrel.sqf | 8 +++-- addons/overheating/functions/fnc_canUnjam.sqf | 5 +++- .../fnc_checkSpareBarrelsTemperatures.sqf | 3 ++ addons/overheating/functions/fnc_firedEH.sqf | 3 ++ .../functions/fnc_getWeaponData.sqf | 3 ++ .../functions/fnc_handleTakeEH.sqf | 3 ++ .../functions/fnc_loadCoolestSpareBarrel.sqf | 3 ++ addons/overheating/functions/fnc_overheat.sqf | 3 ++ .../fnc_sendSpareBarrelsTemperaturesHint.sqf | 3 ++ .../functions/fnc_getDistance.sqf | 4 +-- .../functions/fnc_checkCutParachute.sqf | 6 ++-- .../parachute/functions/fnc_cutParachute.sqf | 4 +-- .../fnc_handleInfoDisplayChanged.sqf | 5 +++- .../functions/fnc_storeParachute.sqf | 29 +++++++++--------- .../functions/fnc_calculateRangeCard.sqf | 6 ++-- addons/rangecard/functions/fnc_canCopy.sqf | 4 +-- addons/rangecard/functions/fnc_canShow.sqf | 2 +- .../rangecard/functions/fnc_canShowCopy.sqf | 2 +- .../rangecard/functions/fnc_onCloseDialog.sqf | 16 ++++++++++ .../rangecard/functions/fnc_openRangeCard.sqf | 4 +-- .../functions/fnc_updateRangeCard.sqf | 4 +-- .../functions/fnc_moduleRearmSettings.sqf | 2 +- addons/recoil/functions/fnc_camshake.sqf | 2 +- .../functions/fnc_moduleRefuelSettings.sqf | 3 ++ addons/refuel/functions/fnc_refuel.sqf | 3 ++ addons/reload/functions/fnc_checkAmmo.sqf | 7 ++++- addons/reload/functions/fnc_displayAmmo.sqf | 8 ++++- .../reload/functions/fnc_startLinkingBelt.sqf | 6 ++++ .../functions/fnc_addMissileReloadActions.sqf | 9 ++++-- .../reloadlaunchers/functions/fnc_canLoad.sqf | 13 ++++---- .../functions/fnc_getLoadableMissiles.sqf | 9 ++++-- addons/reloadlaunchers/functions/fnc_load.sqf | 13 ++++---- .../functions/fnc_reloadLauncher.sqf | 15 ++++++---- .../functions/fnc_getHitPointString.sqf | 4 +-- .../repair/functions/fnc_isRepairVehicle.sqf | 2 +- .../functions/fnc_modifyInteraction.sqf | 4 +-- addons/repair/functions/fnc_useItem.sqf | 2 +- addons/repair/functions/fnc_useItems.sqf | 2 +- .../fnc_handleInteractMenuOpened.sqf | 3 ++ addons/sandbag/functions/fnc_handleKilled.sqf | 3 ++ .../functions/fnc_handlePlayerChanged.sqf | 3 ++ .../fnc_handlePlayerInventoryChanged.sqf | 3 ++ .../functions/fnc_handleUnconscious.sqf | 3 ++ .../fnc_calculateZeroAngleCorrection.sqf | 5 +++- addons/scopes/functions/fnc_firedEH.sqf | 3 ++ .../functions/fnc_initModuleSettings.sqf | 5 +++- addons/slideshow/functions/fnc_moduleInit.sqf | 3 ++ .../functions/fnc_moduleSpectatorSettings.sqf | 3 ++ .../functions/fnc_respawnTemplate.sqf | 3 ++ .../functions/fnc_toggleInterface.sqf | 4 +-- .../functions/fnc_animateReticle.sqf | 5 +++- .../functions/fnc_handleMapClick.sqf | 2 +- .../fnc_handleInteractMenuOpened.sqf | 3 ++ .../functions/fnc_handleKilled.sqf | 3 ++ .../functions/fnc_handlePlayerChanged.sqf | 3 ++ .../functions/fnc_handleUnconscious.sqf | 3 ++ addons/tagging/functions/fnc_moduleInit.sqf | 3 ++ .../fnc_handleInteractMenuOpened.sqf | 3 ++ .../trenches/functions/fnc_handleKilled.sqf | 3 ++ .../functions/fnc_handlePlayerChanged.sqf | 3 ++ .../fnc_handlePlayerInventoryChanged.sqf | 3 ++ .../functions/fnc_handleUnconscious.sqf | 3 ++ .../fnc_handleInteractMenuOpened.sqf | 3 ++ addons/tripod/functions/fnc_handleKilled.sqf | 3 ++ .../functions/fnc_handlePlayerChanged.sqf | 3 ++ .../functions/fnc_handleUnconscious.sqf | 3 ++ addons/ui/functions/fnc_moduleInit.sqf | 5 ++++ .../vector/functions/fnc_adjustBrightness.sqf | 17 ++++++++++- addons/vector/functions/fnc_clearDisplay.sqf | 19 ++++++++---- .../functions/fnc_convertToTexturesDegree.sqf | 20 +++++++++---- .../fnc_convertToTexturesDistance.sqf | 19 +++++++++--- .../functions/fnc_convertToTexturesFOS.sqf | 21 +++++++++---- addons/vector/functions/fnc_dataTransfer.sqf | 4 +-- addons/vector/functions/fnc_getDirection.sqf | 16 ++++++++++ addons/vector/functions/fnc_getDistance.sqf | 17 ++++++++++- addons/vector/functions/fnc_getFallOfShot.sqf | 17 ++++++++++- .../functions/fnc_getHeightDistance.sqf | 17 ++++++++++- .../fnc_getRelativeAzimuthDistance.sqf | 17 ++++++++++- .../functions/fnc_getRelativeDistance.sqf | 17 ++++++++++- .../functions/fnc_getRelativeHeightLength.sqf | 17 ++++++++++- addons/vector/functions/fnc_illuminate.sqf | 17 ++++++++++- addons/vector/functions/fnc_nextMode.sqf | 17 ++++++++++- addons/vector/functions/fnc_onKeyDown.sqf | 19 ++++++++---- addons/vector/functions/fnc_onKeyHold.sqf | 20 +++++++++---- addons/vector/functions/fnc_onKeyUp.sqf | 19 ++++++++---- addons/vector/functions/fnc_showAzimuth.sqf | 17 ++++++++++- .../functions/fnc_showAzimuthInclination.sqf | 17 ++++++++++- addons/vector/functions/fnc_showCenter.sqf | 19 ++++++++---- addons/vector/functions/fnc_showDistance.sqf | 17 ++++++++++- .../vector/functions/fnc_showFallOfShot.sqf | 17 ++++++++++- .../functions/fnc_showHeightDistance.sqf | 17 ++++++++++- addons/vector/functions/fnc_showP1.sqf | 19 ++++++++---- .../fnc_showRelativeAzimuthDistance.sqf | 17 ++++++++++- .../functions/fnc_showRelativeDistance.sqf | 17 ++++++++++- .../fnc_showRelativeHeightLength.sqf | 17 ++++++++++- addons/vector/functions/fnc_showReticle.sqf | 19 ++++++++---- addons/vector/functions/fnc_showText.sqf | 17 ++++++++++- .../viewdistance/functions/fnc_initModule.sqf | 5 ++++ .../weather/functions/fnc_updateHumidity.sqf | 4 +-- addons/weather/functions/fnc_updateRain.sqf | 4 +-- .../functions/fnc_updateTemperature.sqf | 4 +-- addons/weather/functions/fnc_updateWind.sqf | 4 +-- .../functions/fnc_handleFired.sqf | 2 +- .../functions/fnc_initModuleSettings.sqf | 3 ++ .../functions/fnc_updateTrajectoryPFH.sqf | 3 +- .../functions/fnc_acquireTarget.sqf | 5 ++-- addons/yardage450/functions/fnc_turnOn.sqf | 5 ++-- .../zeus/functions/fnc_addObjectToCurator.sqf | 3 ++ .../zeus/functions/fnc_bi_moduleCurator.sqf | 3 ++ addons/zeus/functions/fnc_bi_moduleMine.sqf | 3 ++ .../functions/fnc_bi_moduleProjectile.sqf | 3 ++ .../functions/fnc_bi_moduleRemoteControl.sqf | 3 ++ .../functions/fnc_handleZeusUnitAssigned.sqf | 3 ++ .../functions/fnc_moduleAddOrRemoveFRIES.sqf | 3 ++ .../functions/fnc_moduleAddSpareTrack.sqf | 3 ++ .../functions/fnc_moduleAddSpareWheel.sqf | 3 ++ addons/zeus/functions/fnc_moduleCaptive.sqf | 3 ++ .../functions/fnc_moduleGlobalSetSkill.sqf | 3 ++ .../zeus/functions/fnc_moduleSearchNearby.sqf | 3 ++ addons/zeus/functions/fnc_moduleSetMedic.sqf | 3 ++ .../fnc_moduleSetMedicalFacility.sqf | 3 ++ .../functions/fnc_moduleSetMedicalVehicle.sqf | 3 ++ .../zeus/functions/fnc_moduleSimulation.sqf | 3 ++ .../functions/fnc_moduleSuppressiveFire.sqf | 3 ++ .../fnc_moduleSuppressiveFireLocal.sqf | 3 ++ addons/zeus/functions/fnc_moduleSurrender.sqf | 3 ++ .../zeus/functions/fnc_moduleUnconscious.sqf | 3 ++ .../zeus/functions/fnc_moduleZeusSettings.sqf | 3 ++ addons/zeus/functions/fnc_showMessage.sqf | 2 +- .../zeus/functions/fnc_ui_attributeCargo.sqf | 3 ++ .../functions/fnc_ui_attributePosition.sqf | 3 ++ .../zeus/functions/fnc_ui_attributeRadius.sqf | 3 ++ addons/zeus/functions/fnc_ui_defendArea.sqf | 3 ++ .../zeus/functions/fnc_ui_editableObjects.sqf | 3 ++ .../zeus/functions/fnc_ui_globalSetSkill.sqf | 3 ++ addons/zeus/functions/fnc_ui_groupSide.sqf | 3 ++ addons/zeus/functions/fnc_ui_patrolArea.sqf | 3 ++ addons/zeus/functions/fnc_ui_searchArea.sqf | 3 ++ .../zeus/functions/fnc_ui_teleportPlayers.sqf | 3 ++ 772 files changed, 3072 insertions(+), 779 deletions(-) diff --git a/addons/advanced_ballistics/functions/fnc_calculateAmmoTemperatureVelocityShift.sqf b/addons/advanced_ballistics/functions/fnc_calculateAmmoTemperatureVelocityShift.sqf index 19cd55c98e..fd086d65d1 100644 --- a/addons/advanced_ballistics/functions/fnc_calculateAmmoTemperatureVelocityShift.sqf +++ b/addons/advanced_ballistics/functions/fnc_calculateAmmoTemperatureVelocityShift.sqf @@ -10,6 +10,9 @@ * Return Value: * muzzle velocity shift - m/s * + * Example: + * [[], 5] call ace_advanced_ballistics_fnc_calcilateAmmoTemperatureVelocityShift + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_calculateAtmosphericCorrection.sqf b/addons/advanced_ballistics/functions/fnc_calculateAtmosphericCorrection.sqf index 2b90767a4f..326de5478e 100644 --- a/addons/advanced_ballistics/functions/fnc_calculateAtmosphericCorrection.sqf +++ b/addons/advanced_ballistics/functions/fnc_calculateAtmosphericCorrection.sqf @@ -13,6 +13,9 @@ * Return Value: * corrected ballistic coefficient * + * Example: + * [2, 5, 5, 0.5, "ASM"] call ace_advanced_ballistics_fnc_calculateAtmosphericCorrection + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_calculateBarrelLengthVelocityShift.sqf b/addons/advanced_ballistics/functions/fnc_calculateBarrelLengthVelocityShift.sqf index 1f8a7e6eb9..98912b96e7 100644 --- a/addons/advanced_ballistics/functions/fnc_calculateBarrelLengthVelocityShift.sqf +++ b/addons/advanced_ballistics/functions/fnc_calculateBarrelLengthVelocityShift.sqf @@ -4,7 +4,7 @@ * Calculates the muzzle velocity shift caused by different barrel lengths * * Arguments: - * 0: barrel length - mm + * 0: barrel length - mm * 1: muzzle velocity lookup table - m/s * 2: barrel length lookup table - mm * 3: muzzle velocity - m/s @@ -12,6 +12,9 @@ * Return Value: * muzzle velocity shift - m/s * + * Example: + * [5, [0,5], [0,5], 5] call ace_advanced_ballistics_fnc_calculateBarrelLengthVelocityShift + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_calculateRetardation.sqf b/addons/advanced_ballistics/functions/fnc_calculateRetardation.sqf index 0bd801c6b9..1c7cadd3f0 100644 --- a/addons/advanced_ballistics/functions/fnc_calculateRetardation.sqf +++ b/addons/advanced_ballistics/functions/fnc_calculateRetardation.sqf @@ -11,6 +11,9 @@ * Return Value: * retardation - m/(s^2) * + * Example: + * [5, 20, 10] call ace_advanced_ballistics_fnc_calculateRetardation + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_calculateStabilityFactor.sqf b/addons/advanced_ballistics/functions/fnc_calculateStabilityFactor.sqf index 07fc7c67c9..8af9f77930 100644 --- a/addons/advanced_ballistics/functions/fnc_calculateStabilityFactor.sqf +++ b/addons/advanced_ballistics/functions/fnc_calculateStabilityFactor.sqf @@ -15,6 +15,9 @@ * Return Value: * stability factor * + * Example: + * [1, 2, 3, 4, 5, 6, 7] call ace_advanced_ballistics_fnc_calculateStabilityFactor + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf b/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf index 4d344e8bfe..40d065198c 100644 --- a/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf +++ b/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [] call ace_advanced_ballistics_fnc_diagnoseWeapons + * * Public: No */ #define DEBUG_MODE_FULL diff --git a/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf b/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf index 528b3e2e97..f50dcc6887 100644 --- a/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf +++ b/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [] call ace_advanced_ballistics_fnc_displayProtractor + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf b/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf index 6a9c7ce243..db85efe137 100644 --- a/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf +++ b/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [] call ace_advanced_ballistics_fnc_handleFirePFH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_handleFired.sqf b/addons/advanced_ballistics/functions/fnc_handleFired.sqf index 28fe9c5680..a4f55adc3d 100644 --- a/addons/advanced_ballistics/functions/fnc_handleFired.sqf +++ b/addons/advanced_ballistics/functions/fnc_handleFired.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [] call ace_advanced_ballistics_fnc_handleFired + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_initModuleSettings.sqf b/addons/advanced_ballistics/functions/fnc_initModuleSettings.sqf index 4898c51c10..ced2ffbf4e 100644 --- a/addons/advanced_ballistics/functions/fnc_initModuleSettings.sqf +++ b/addons/advanced_ballistics/functions/fnc_initModuleSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_advanced_ballistics_fnc_initModuleSettings + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf b/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf index 9c226d4a44..04be6a77db 100644 --- a/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf +++ b/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [] call ace_advanced_ballistics_fnc_initializeTerrainExtension + * * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_ballistics/functions/fnc_readAmmoDataFromConfig.sqf b/addons/advanced_ballistics/functions/fnc_readAmmoDataFromConfig.sqf index bac37a22a0..9971c99d85 100644 --- a/addons/advanced_ballistics/functions/fnc_readAmmoDataFromConfig.sqf +++ b/addons/advanced_ballistics/functions/fnc_readAmmoDataFromConfig.sqf @@ -7,18 +7,21 @@ * ammo - classname * * Return Value: - * 0: _airFriction - * 1: _caliber - * 2: _bulletLength - * 3: _bulletMass - * 4: _transonicStabilityCoef - * 5: _dragModel - * 6: _ballisticCoefficients - * 7: _velocityBoundaries - * 8: _atmosphereModel - * 9: _ammoTempMuzzleVelocityShifts - * 10: _muzzleVelocityTable - * 11: _barrelLengthTable + * 0: _airFriction + * 1: _caliber + * 2: _bulletLength + * 3: _bulletMass + * 4: _transonicStabilityCoef + * 5: _dragModel + * 6: _ballisticCoefficients + * 7: _velocityBoundaries + * 8: _atmosphereModel + * 9: _ammoTempMuzzleVelocityShifts + * 10: _muzzleVelocityTable + * 11: _barrelLengthTable + * + * Example: + * ["ammo"] call ace_advanced_ballistics_fnc_readAmmoDataFromConfig * * Public: No */ diff --git a/addons/advanced_ballistics/functions/fnc_readWeaponDataFromConfig.sqf b/addons/advanced_ballistics/functions/fnc_readWeaponDataFromConfig.sqf index 882542f068..af31a67fca 100644 --- a/addons/advanced_ballistics/functions/fnc_readWeaponDataFromConfig.sqf +++ b/addons/advanced_ballistics/functions/fnc_readWeaponDataFromConfig.sqf @@ -7,9 +7,12 @@ * weapon - classname * * Return Value: - * 0: _barrelTwist - * 1: _twistDirection - * 2: _barrelLength + * 0: _barrelTwist + * 1: _twistDirection + * 2: _barrelLength + * + * Example: + * ["weapon"] call ace_advanced_ballistics_fnc_readWeaponDataFromConfig * * Public: No */ diff --git a/addons/advanced_fatigue/functions/fnc_addDutyFactor.sqf b/addons/advanced_fatigue/functions/fnc_addDutyFactor.sqf index 74a42d55cf..89801e902e 100644 --- a/addons/advanced_fatigue/functions/fnc_addDutyFactor.sqf +++ b/addons/advanced_fatigue/functions/fnc_addDutyFactor.sqf @@ -8,6 +8,11 @@ * * Return Value: * None + * + * Example: + * ["ID", 5] call ace_advanced_fatigue_fnc_addDutyFactor + * + * Public: No */ #include "script_component.hpp" params [["_id", "", [""]], ["_factor", 1, [0, {}]]]; diff --git a/addons/advanced_fatigue/functions/fnc_createStaminaBar.sqf b/addons/advanced_fatigue/functions/fnc_createStaminaBar.sqf index 773e240494..ce88c2b42e 100644 --- a/addons/advanced_fatigue/functions/fnc_createStaminaBar.sqf +++ b/addons/advanced_fatigue/functions/fnc_createStaminaBar.sqf @@ -7,6 +7,11 @@ * * Return Value: * None + * + * Example: + * [DISPLAY] call ace_advanced_fatigue_fnc_createStaminaBar + * + * Public: No */ #include "script_component.hpp" params ["_display"]; diff --git a/addons/advanced_fatigue/functions/fnc_handlePlayerChanged.sqf b/addons/advanced_fatigue/functions/fnc_handlePlayerChanged.sqf index bdcbb9b296..0e31e89645 100644 --- a/addons/advanced_fatigue/functions/fnc_handlePlayerChanged.sqf +++ b/addons/advanced_fatigue/functions/fnc_handlePlayerChanged.sqf @@ -8,6 +8,11 @@ * * Return Value: * None + * + * Example: + * [newbob, oldbob] call ace_advanced_fatigue_fnc_handlePlayerChanged + * + * Public: No */ #include "script_component.hpp" params ["_newUnit", "_oldUnit"]; diff --git a/addons/advanced_fatigue/functions/fnc_handleStaminaBar.sqf b/addons/advanced_fatigue/functions/fnc_handleStaminaBar.sqf index 2f865ac821..72772d16b1 100644 --- a/addons/advanced_fatigue/functions/fnc_handleStaminaBar.sqf +++ b/addons/advanced_fatigue/functions/fnc_handleStaminaBar.sqf @@ -7,6 +7,11 @@ * * Return Value: * None + * + * Example: + * [0.5] call ace_advanced_fatigue_fnc_handleStaminaBar + * + * Public: No */ #include "script_component.hpp" params ["_stamina"]; diff --git a/addons/advanced_fatigue/functions/fnc_mainLoop.sqf b/addons/advanced_fatigue/functions/fnc_mainLoop.sqf index d01eeefa78..4b23153dff 100644 --- a/addons/advanced_fatigue/functions/fnc_mainLoop.sqf +++ b/addons/advanced_fatigue/functions/fnc_mainLoop.sqf @@ -7,6 +7,11 @@ * * Return Value: * None + * + * Example: + * [] call ace_advanced_fatigue_fnc_mainLoop + * + * Public: No */ #include "script_component.hpp" if (!alive ACE_player) exitWith { // Dead people don't breath, Will also handle null (Map intros) diff --git a/addons/advanced_fatigue/functions/fnc_moduleSettings.sqf b/addons/advanced_fatigue/functions/fnc_moduleSettings.sqf index 275e4b7907..9d1a0a6ab6 100644 --- a/addons/advanced_fatigue/functions/fnc_moduleSettings.sqf +++ b/addons/advanced_fatigue/functions/fnc_moduleSettings.sqf @@ -7,6 +7,11 @@ * * Return Value: * None + * + * Example: + * [MODULE] call ace_advanced_fatigue_fnc_moduleSettings + * + * Public: No */ #include "script_component.hpp" params ["_logic"]; diff --git a/addons/advanced_fatigue/functions/fnc_removeDutyFactor.sqf b/addons/advanced_fatigue/functions/fnc_removeDutyFactor.sqf index 0a67f318ac..4ae07704a5 100644 --- a/addons/advanced_fatigue/functions/fnc_removeDutyFactor.sqf +++ b/addons/advanced_fatigue/functions/fnc_removeDutyFactor.sqf @@ -7,6 +7,11 @@ * * Return Value: * None + * + * Example: + * ["ID"] call ace_advanced_fatigue_fnc_removeDutyFactor + * + * Public: No */ #include "script_component.hpp" params [["_id", "", [""]]]; diff --git a/addons/advanced_throwing/functions/fnc_moduleInit.sqf b/addons/advanced_throwing/functions/fnc_moduleInit.sqf index 043f15b491..fe380d2bb5 100644 --- a/addons/advanced_throwing/functions/fnc_moduleInit.sqf +++ b/addons/advanced_throwing/functions/fnc_moduleInit.sqf @@ -13,8 +13,7 @@ * Example: * [logic, [unit1, unit2], true] call ace_advanced_throwing_fnc_moduleInit * - * Public: - * No + * Public: No */ #include "script_component.hpp" diff --git a/addons/advanced_throwing/functions/fnc_renderPickUpInteraction.sqf b/addons/advanced_throwing/functions/fnc_renderPickUpInteraction.sqf index 960bf8fec5..9f2743c600 100644 --- a/addons/advanced_throwing/functions/fnc_renderPickUpInteraction.sqf +++ b/addons/advanced_throwing/functions/fnc_renderPickUpInteraction.sqf @@ -7,7 +7,7 @@ * None * * Return Value: - * Nothing + * None * * Example: * call ace_advanced_throwing_fnc_renderPickUpInteraction diff --git a/addons/atragmx/functions/fnc_add_new_gun.sqf b/addons/atragmx/functions/fnc_add_new_gun.sqf index 3be23920bc..729649dc5d 100644 --- a/addons/atragmx/functions/fnc_add_new_gun.sqf +++ b/addons/atragmx/functions/fnc_add_new_gun.sqf @@ -6,7 +6,7 @@ * Nothing * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_add_new_gun diff --git a/addons/atragmx/functions/fnc_calculate_distance_at_velocity.sqf b/addons/atragmx/functions/fnc_calculate_distance_at_velocity.sqf index 9641804fbe..450ecc8ab3 100644 --- a/addons/atragmx/functions/fnc_calculate_distance_at_velocity.sqf +++ b/addons/atragmx/functions/fnc_calculate_distance_at_velocity.sqf @@ -3,10 +3,10 @@ * Calculates distance at which the bullet velocity drops below the threshold velocity * * Arguments: - * theshold velocity + * theshold velocity * * Return Value: - * distance * * Example: * 403 call ace_atragmx_fnc_calculate_distance_at_velocity diff --git a/addons/atragmx/functions/fnc_calculate_range_card.sqf b/addons/atragmx/functions/fnc_calculate_range_card.sqf index b72c38e756..837a46079f 100644 --- a/addons/atragmx/functions/fnc_calculate_range_card.sqf +++ b/addons/atragmx/functions/fnc_calculate_range_card.sqf @@ -3,10 +3,10 @@ * Calculates the range card output based on the current data set * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_calculate_range_card diff --git a/addons/atragmx/functions/fnc_calculate_target_range_assist.sqf b/addons/atragmx/functions/fnc_calculate_target_range_assist.sqf index be21a09927..3a1bd879f1 100644 --- a/addons/atragmx/functions/fnc_calculate_target_range_assist.sqf +++ b/addons/atragmx/functions/fnc_calculate_target_range_assist.sqf @@ -3,10 +3,10 @@ * Calculates the target range and updates the output fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_calculate_target_range_assist @@ -74,7 +74,7 @@ switch (_this) do { if (_estRange > 0) then { _imageSize = atan(_targetSize / _estRange); }; - + switch (GVAR(rangeAssistImageSizeUnit)) do { case 0: { _imageSize = _imageSize * 6400 / 360; @@ -93,7 +93,7 @@ switch (_this) do { if (tan(_imageSize) != 0) then { _estRange = _targetSize / tan(_imageSize); }; - + ctrlSetText [7013, Str(Round(_estRange))]; }; }; diff --git a/addons/atragmx/functions/fnc_calculate_target_solution.sqf b/addons/atragmx/functions/fnc_calculate_target_solution.sqf index 2cc3973c47..f7a4750223 100644 --- a/addons/atragmx/functions/fnc_calculate_target_solution.sqf +++ b/addons/atragmx/functions/fnc_calculate_target_solution.sqf @@ -3,10 +3,10 @@ * Calculates the fireing solution and updates the result input/output fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_calculate_target_solution diff --git a/addons/atragmx/functions/fnc_calculate_target_speed_assist.sqf b/addons/atragmx/functions/fnc_calculate_target_speed_assist.sqf index c3a4dac24f..7b18559b77 100644 --- a/addons/atragmx/functions/fnc_calculate_target_speed_assist.sqf +++ b/addons/atragmx/functions/fnc_calculate_target_speed_assist.sqf @@ -3,10 +3,10 @@ * Calculates the target speed and updates the output fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_calculate_target_speed_assist diff --git a/addons/atragmx/functions/fnc_calculate_truing_drop.sqf b/addons/atragmx/functions/fnc_calculate_truing_drop.sqf index 38d19456da..d60f5b50e3 100644 --- a/addons/atragmx/functions/fnc_calculate_truing_drop.sqf +++ b/addons/atragmx/functions/fnc_calculate_truing_drop.sqf @@ -6,7 +6,7 @@ * parse input * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_calculate_truing_drop @@ -33,7 +33,7 @@ if (_parseInput) then { _subsonicRange = Round(_subsonicRange); _subsonicRange = _transonicRange max _subsonicRange; - + _transonicDrop = -100 max parseNumber(ctrlText 18013) min 100; _subsonicDrop = -100 max parseNumber(ctrlText 18014) min 100; private _dropUnit = GVAR(currentScopeUnit); @@ -56,7 +56,7 @@ if (_parseInput) then { }; _transonicDrop = Round(_transonicDrop * 100) / 100; _subsonicDrop = Round(_subsonicDrop * 100) / 100; - + _subsonicDrop = _transonicDrop max _subsonicDrop; }; @@ -65,7 +65,7 @@ if ((GVAR(truingDropDropData) select 0) == 0 || {!([_transonicRange, _subsonicRa call FUNC(calculate_target_solution); }; private _solutionInput = +GVAR(targetSolutionInput); - + if (_transonicRange == 0) then { _transonicRange = Round(403 call FUNC(calculate_distance_at_velocity)); }; diff --git a/addons/atragmx/functions/fnc_can_show.sqf b/addons/atragmx/functions/fnc_can_show.sqf index 7054e85cf9..bf05edee98 100644 --- a/addons/atragmx/functions/fnc_can_show.sqf +++ b/addons/atragmx/functions/fnc_can_show.sqf @@ -3,7 +3,7 @@ * Tests if the ATragMX dialog can be shown * * Arguments: - * Nothing + * None * * Return Value: * can_show diff --git a/addons/atragmx/functions/fnc_change_gun.sqf b/addons/atragmx/functions/fnc_change_gun.sqf index b6e5e24658..53167f87b1 100644 --- a/addons/atragmx/functions/fnc_change_gun.sqf +++ b/addons/atragmx/functions/fnc_change_gun.sqf @@ -8,7 +8,7 @@ * update display * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_change_gun diff --git a/addons/atragmx/functions/fnc_change_target_slot.sqf b/addons/atragmx/functions/fnc_change_target_slot.sqf index 7c660ff7de..158e31ad87 100644 --- a/addons/atragmx/functions/fnc_change_target_slot.sqf +++ b/addons/atragmx/functions/fnc_change_target_slot.sqf @@ -6,7 +6,7 @@ * target * * Return Value: - * Nothing + * None * * Example: * 2 call ace_atragmx_fnc_change_target_slot diff --git a/addons/atragmx/functions/fnc_clear_c1_ballistic_coefficient_data.sqf b/addons/atragmx/functions/fnc_clear_c1_ballistic_coefficient_data.sqf index c6f2d47134..a795b74c70 100644 --- a/addons/atragmx/functions/fnc_clear_c1_ballistic_coefficient_data.sqf +++ b/addons/atragmx/functions/fnc_clear_c1_ballistic_coefficient_data.sqf @@ -3,10 +3,10 @@ * Clears the c1 ballistic coefficient data fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_clear_c1_ballistic_coefficient_data diff --git a/addons/atragmx/functions/fnc_clear_muzzle_velocity_data.sqf b/addons/atragmx/functions/fnc_clear_muzzle_velocity_data.sqf index d76fa5864b..6f4472c550 100644 --- a/addons/atragmx/functions/fnc_clear_muzzle_velocity_data.sqf +++ b/addons/atragmx/functions/fnc_clear_muzzle_velocity_data.sqf @@ -3,10 +3,10 @@ * Clears the muzzle velocity data fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_clear_muzzle_velocity_data diff --git a/addons/atragmx/functions/fnc_clear_user_data.sqf b/addons/atragmx/functions/fnc_clear_user_data.sqf index faa9af07f7..727c8da107 100644 --- a/addons/atragmx/functions/fnc_clear_user_data.sqf +++ b/addons/atragmx/functions/fnc_clear_user_data.sqf @@ -3,10 +3,10 @@ * Removes all user data from the profileNamespace * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_clear_user_data @@ -43,4 +43,4 @@ profileNamespace setVariable ["ACE_ATragMX_targetRange", nil]; profileNamespace setVariable ["ACE_ATragMX_rangeCardStartRange", nil]; profileNamespace setVariable ["ACE_ATragMX_rangeCardEndRange", nil]; profileNamespace setVariable ["ACE_ATragMX_rangeCardIncrement", nil]; -profileNamespace setVariable ["ACE_ATragMX_rangeCardCurrentColumn", nil]; \ No newline at end of file +profileNamespace setVariable ["ACE_ATragMX_rangeCardCurrentColumn", nil]; diff --git a/addons/atragmx/functions/fnc_create_dialog.sqf b/addons/atragmx/functions/fnc_create_dialog.sqf index 6bf57e620a..c342bb1eb0 100644 --- a/addons/atragmx/functions/fnc_create_dialog.sqf +++ b/addons/atragmx/functions/fnc_create_dialog.sqf @@ -3,10 +3,10 @@ * Creates the ATragMX dialog * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_create_dialog diff --git a/addons/atragmx/functions/fnc_cycle_gun_list.sqf b/addons/atragmx/functions/fnc_cycle_gun_list.sqf index 1cc22abb45..550bc624f2 100644 --- a/addons/atragmx/functions/fnc_cycle_gun_list.sqf +++ b/addons/atragmx/functions/fnc_cycle_gun_list.sqf @@ -6,7 +6,7 @@ * step * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_cycle_scope_unit diff --git a/addons/atragmx/functions/fnc_cycle_image_size_units.sqf b/addons/atragmx/functions/fnc_cycle_image_size_units.sqf index ce91f818c6..2981a9a73e 100644 --- a/addons/atragmx/functions/fnc_cycle_image_size_units.sqf +++ b/addons/atragmx/functions/fnc_cycle_image_size_units.sqf @@ -6,7 +6,7 @@ * step * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_cycle_image_size_units diff --git a/addons/atragmx/functions/fnc_cycle_num_ticks_units.sqf b/addons/atragmx/functions/fnc_cycle_num_ticks_units.sqf index 49b4ad0ffa..fc4746ee56 100644 --- a/addons/atragmx/functions/fnc_cycle_num_ticks_units.sqf +++ b/addons/atragmx/functions/fnc_cycle_num_ticks_units.sqf @@ -6,7 +6,7 @@ * step * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_cycle_num_ticks_units diff --git a/addons/atragmx/functions/fnc_cycle_range_card_columns.sqf b/addons/atragmx/functions/fnc_cycle_range_card_columns.sqf index dc572ede19..dfba1f0574 100644 --- a/addons/atragmx/functions/fnc_cycle_range_card_columns.sqf +++ b/addons/atragmx/functions/fnc_cycle_range_card_columns.sqf @@ -3,10 +3,10 @@ * Cycles through the range card columns * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_cycle_range_card_columns diff --git a/addons/atragmx/functions/fnc_cycle_scope_unit.sqf b/addons/atragmx/functions/fnc_cycle_scope_unit.sqf index f1cc9c2219..a2020f4147 100644 --- a/addons/atragmx/functions/fnc_cycle_scope_unit.sqf +++ b/addons/atragmx/functions/fnc_cycle_scope_unit.sqf @@ -3,10 +3,10 @@ * Cycles through the scope units * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_cycle_scope_unit diff --git a/addons/atragmx/functions/fnc_cycle_target_size_units.sqf b/addons/atragmx/functions/fnc_cycle_target_size_units.sqf index f44d2a5343..267d4d5772 100644 --- a/addons/atragmx/functions/fnc_cycle_target_size_units.sqf +++ b/addons/atragmx/functions/fnc_cycle_target_size_units.sqf @@ -6,7 +6,7 @@ * step * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_cycle_target_size_units diff --git a/addons/atragmx/functions/fnc_cycle_target_speed_direction.sqf b/addons/atragmx/functions/fnc_cycle_target_speed_direction.sqf index 568dbcec53..e1e8282440 100644 --- a/addons/atragmx/functions/fnc_cycle_target_speed_direction.sqf +++ b/addons/atragmx/functions/fnc_cycle_target_speed_direction.sqf @@ -3,10 +3,10 @@ * Cycles through the target directions left/right * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_cycle_target_direction diff --git a/addons/atragmx/functions/fnc_delete_gun.sqf b/addons/atragmx/functions/fnc_delete_gun.sqf index c94739035e..55548527f1 100644 --- a/addons/atragmx/functions/fnc_delete_gun.sqf +++ b/addons/atragmx/functions/fnc_delete_gun.sqf @@ -3,10 +3,10 @@ * Deletes the currently selected gun profile from the profileNamespace * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_delete_gun diff --git a/addons/atragmx/functions/fnc_evaluate_option_menu_input.sqf b/addons/atragmx/functions/fnc_evaluate_option_menu_input.sqf index f74f8678a4..2e4c9ef023 100644 --- a/addons/atragmx/functions/fnc_evaluate_option_menu_input.sqf +++ b/addons/atragmx/functions/fnc_evaluate_option_menu_input.sqf @@ -6,7 +6,7 @@ * option menu id * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_evaluate_option_menu_input diff --git a/addons/atragmx/functions/fnc_init.sqf b/addons/atragmx/functions/fnc_init.sqf index deff9d34cb..48401acb4c 100644 --- a/addons/atragmx/functions/fnc_init.sqf +++ b/addons/atragmx/functions/fnc_init.sqf @@ -3,10 +3,10 @@ * Inits all global variables with the default values * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_init diff --git a/addons/atragmx/functions/fnc_initGunList.sqf b/addons/atragmx/functions/fnc_initGunList.sqf index 21592278bd..69efdc68ef 100644 --- a/addons/atragmx/functions/fnc_initGunList.sqf +++ b/addons/atragmx/functions/fnc_initGunList.sqf @@ -3,10 +3,10 @@ * Inits the gun list from user profile * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_initGunList diff --git a/addons/atragmx/functions/fnc_insert_c1_ballistic_coefficient_data.sqf b/addons/atragmx/functions/fnc_insert_c1_ballistic_coefficient_data.sqf index 5b03c11475..ba5a781813 100644 --- a/addons/atragmx/functions/fnc_insert_c1_ballistic_coefficient_data.sqf +++ b/addons/atragmx/functions/fnc_insert_c1_ballistic_coefficient_data.sqf @@ -8,7 +8,7 @@ * c1 ballistic coefficient - * * Return Value: - * Nothing + * None * * Example: * [800, 0.485] call ace_atragmx_fnc_insert_c1_ballistic_coefficient_data diff --git a/addons/atragmx/functions/fnc_insert_muzzle_velocity_data.sqf b/addons/atragmx/functions/fnc_insert_muzzle_velocity_data.sqf index 1eb25b2f62..43cd936beb 100644 --- a/addons/atragmx/functions/fnc_insert_muzzle_velocity_data.sqf +++ b/addons/atragmx/functions/fnc_insert_muzzle_velocity_data.sqf @@ -7,7 +7,7 @@ * muzzle velocity - * * Return Value: - * Nothing + * None * * Example: * [10, 800] call ace_atragmx_fnc_insert_muzzle_velocity_data diff --git a/addons/atragmx/functions/fnc_on_close_dialog.sqf b/addons/atragmx/functions/fnc_on_close_dialog.sqf index fca60574a9..1c96828b1a 100644 --- a/addons/atragmx/functions/fnc_on_close_dialog.sqf +++ b/addons/atragmx/functions/fnc_on_close_dialog.sqf @@ -1,5 +1,21 @@ +/* + * Author: ACE-Team + * On close Dialog + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_atragmx_fnc_on_close_dialog + * + * Public: No + */ + #include "script_component.hpp" uiNamespace setVariable ['ATragMX_Display', nil]; GVAR(active) = false; -[GVAR(DialogPFH)] call CBA_fnc_removePerFrameHandler; \ No newline at end of file +[GVAR(DialogPFH)] call CBA_fnc_removePerFrameHandler; diff --git a/addons/atragmx/functions/fnc_parse_input.sqf b/addons/atragmx/functions/fnc_parse_input.sqf index 38310edfae..b2ca70f31f 100644 --- a/addons/atragmx/functions/fnc_parse_input.sqf +++ b/addons/atragmx/functions/fnc_parse_input.sqf @@ -3,10 +3,10 @@ * Parses all input fields in the gun-, atmosphere- and target column, the result input fields and the muzzle velocity data input fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_parse_input diff --git a/addons/atragmx/functions/fnc_read_gun_list_entries_from_config.sqf b/addons/atragmx/functions/fnc_read_gun_list_entries_from_config.sqf index 0408b0e497..4d99a5637f 100644 --- a/addons/atragmx/functions/fnc_read_gun_list_entries_from_config.sqf +++ b/addons/atragmx/functions/fnc_read_gun_list_entries_from_config.sqf @@ -3,10 +3,10 @@ * Reads gun list entries from the config and appends them to the gun list * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_read_gun_list_entries_from_config @@ -110,10 +110,10 @@ private _validate_preset = { { private _preset = _x >> "preset"; - + if (isArray(_preset)) then { private _gun = getArray _preset; - + if (_gun call _validate_preset) then { _gun set [0, (_gun select 0) select [0, 14]]; _gun set [20, false]; diff --git a/addons/atragmx/functions/fnc_recalculate_c1_ballistic_coefficient.sqf b/addons/atragmx/functions/fnc_recalculate_c1_ballistic_coefficient.sqf index 028a06fa4a..e7ec8bf5a2 100644 --- a/addons/atragmx/functions/fnc_recalculate_c1_ballistic_coefficient.sqf +++ b/addons/atragmx/functions/fnc_recalculate_c1_ballistic_coefficient.sqf @@ -7,7 +7,7 @@ * update display * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_recalculate_c1_ballistic_coefficient diff --git a/addons/atragmx/functions/fnc_recalculate_muzzle_velocity.sqf b/addons/atragmx/functions/fnc_recalculate_muzzle_velocity.sqf index 5830ba7683..248c039969 100644 --- a/addons/atragmx/functions/fnc_recalculate_muzzle_velocity.sqf +++ b/addons/atragmx/functions/fnc_recalculate_muzzle_velocity.sqf @@ -7,7 +7,7 @@ * update display * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_recalculate_muzzle_velocity diff --git a/addons/atragmx/functions/fnc_reset_relative_click_memory.sqf b/addons/atragmx/functions/fnc_reset_relative_click_memory.sqf index 489e832ea2..85d8ff6bc6 100644 --- a/addons/atragmx/functions/fnc_reset_relative_click_memory.sqf +++ b/addons/atragmx/functions/fnc_reset_relative_click_memory.sqf @@ -3,10 +3,10 @@ * Resets the relative click memory and updates the result input/output fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_reset_relative_click_memory diff --git a/addons/atragmx/functions/fnc_restore_atmo_default.sqf b/addons/atragmx/functions/fnc_restore_atmo_default.sqf index 08b7c56d86..560c0da875 100644 --- a/addons/atragmx/functions/fnc_restore_atmo_default.sqf +++ b/addons/atragmx/functions/fnc_restore_atmo_default.sqf @@ -3,10 +3,10 @@ * Restores the atmospheric data defaults * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_restore_atmo_default diff --git a/addons/atragmx/functions/fnc_restore_truing_drop.sqf b/addons/atragmx/functions/fnc_restore_truing_drop.sqf index b8541152a0..a3fb516f23 100644 --- a/addons/atragmx/functions/fnc_restore_truing_drop.sqf +++ b/addons/atragmx/functions/fnc_restore_truing_drop.sqf @@ -6,7 +6,7 @@ * update display * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_restore_truing_drop diff --git a/addons/atragmx/functions/fnc_restore_user_data.sqf b/addons/atragmx/functions/fnc_restore_user_data.sqf index de91a7cd0e..cf7f2e2bef 100644 --- a/addons/atragmx/functions/fnc_restore_user_data.sqf +++ b/addons/atragmx/functions/fnc_restore_user_data.sqf @@ -3,10 +3,10 @@ * Reads user data from profileNamespace * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_restore_user_data diff --git a/addons/atragmx/functions/fnc_save_gun.sqf b/addons/atragmx/functions/fnc_save_gun.sqf index 73e26ee5fd..e26187b231 100644 --- a/addons/atragmx/functions/fnc_save_gun.sqf +++ b/addons/atragmx/functions/fnc_save_gun.sqf @@ -3,10 +3,10 @@ * Saves the currently select gun profile into the profileNamespace * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_save_gun diff --git a/addons/atragmx/functions/fnc_shift_c1_ballistic_coefficient_data.sqf b/addons/atragmx/functions/fnc_shift_c1_ballistic_coefficient_data.sqf index 241d7fe7e0..89667e25b9 100644 --- a/addons/atragmx/functions/fnc_shift_c1_ballistic_coefficient_data.sqf +++ b/addons/atragmx/functions/fnc_shift_c1_ballistic_coefficient_data.sqf @@ -6,7 +6,7 @@ * ballistic coefficient - * * Return Value: - * Nothing + * None * * Example: * 10 call ace_atragmx_fnc_shift_c1_ballistic_coefficient_data diff --git a/addons/atragmx/functions/fnc_shift_muzzle_velocity_data.sqf b/addons/atragmx/functions/fnc_shift_muzzle_velocity_data.sqf index 4bbd9337fd..75fcc9c3a6 100644 --- a/addons/atragmx/functions/fnc_shift_muzzle_velocity_data.sqf +++ b/addons/atragmx/functions/fnc_shift_muzzle_velocity_data.sqf @@ -6,7 +6,7 @@ * velocity - * * Return Value: - * Nothing + * None * * Example: * 10 call ace_atragmx_fnc_shift_muzzle_velocity_data diff --git a/addons/atragmx/functions/fnc_show_add_new_gun.sqf b/addons/atragmx/functions/fnc_show_add_new_gun.sqf index b5b0f29a18..a5d4fd8b8b 100644 --- a/addons/atragmx/functions/fnc_show_add_new_gun.sqf +++ b/addons/atragmx/functions/fnc_show_add_new_gun.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_add_new_gun + * false call ace_atragmx_fnc_show_add_new_gun * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_atmo_env_data.sqf b/addons/atragmx/functions/fnc_show_atmo_env_data.sqf index 56f75f7844..75dcaad502 100644 --- a/addons/atragmx/functions/fnc_show_atmo_env_data.sqf +++ b/addons/atragmx/functions/fnc_show_atmo_env_data.sqf @@ -6,7 +6,7 @@ * visible - * * Return Value: - * Nothing + * None * * Example: * false call ace_atragmx_fnc_show_atmo_env_data diff --git a/addons/atragmx/functions/fnc_show_c1_ballistic_coefficient_data.sqf b/addons/atragmx/functions/fnc_show_c1_ballistic_coefficient_data.sqf index 9ac13aef86..797f0498fe 100644 --- a/addons/atragmx/functions/fnc_show_c1_ballistic_coefficient_data.sqf +++ b/addons/atragmx/functions/fnc_show_c1_ballistic_coefficient_data.sqf @@ -6,7 +6,7 @@ * visible - * * Return Value: - * Nothing + * None * * Example: * false call ace_atragmx_fnc_show_c1_ballistic_coefficient_data diff --git a/addons/atragmx/functions/fnc_show_gun_ammo_data.sqf b/addons/atragmx/functions/fnc_show_gun_ammo_data.sqf index dfab6da238..c6fb288acc 100644 --- a/addons/atragmx/functions/fnc_show_gun_ammo_data.sqf +++ b/addons/atragmx/functions/fnc_show_gun_ammo_data.sqf @@ -6,7 +6,7 @@ * visible - * * Return Value: - * Nothing + * None * * Example: * false call ace_atragmx_fnc_show_gun_ammo_data diff --git a/addons/atragmx/functions/fnc_show_gun_list.sqf b/addons/atragmx/functions/fnc_show_gun_list.sqf index ce3b3bae3a..e6c8156d26 100644 --- a/addons/atragmx/functions/fnc_show_gun_list.sqf +++ b/addons/atragmx/functions/fnc_show_gun_list.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_gun_list + * false call ace_atragmx_fnc_show_gun_list * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_main_page.sqf b/addons/atragmx/functions/fnc_show_main_page.sqf index 591554d632..6b2259c72a 100644 --- a/addons/atragmx/functions/fnc_show_main_page.sqf +++ b/addons/atragmx/functions/fnc_show_main_page.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_main_page + * false call ace_atragmx_fnc_show_main_page * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_muzzle_velocity_data.sqf b/addons/atragmx/functions/fnc_show_muzzle_velocity_data.sqf index 8a5d39f2b5..20c7bf1826 100644 --- a/addons/atragmx/functions/fnc_show_muzzle_velocity_data.sqf +++ b/addons/atragmx/functions/fnc_show_muzzle_velocity_data.sqf @@ -6,7 +6,7 @@ * visible - * * Return Value: - * Nothing + * None * * Example: * false call ace_atragmx_fnc_show_muzzle_velocity_data diff --git a/addons/atragmx/functions/fnc_show_range_card.sqf b/addons/atragmx/functions/fnc_show_range_card.sqf index 7709589beb..d2dc368bb4 100644 --- a/addons/atragmx/functions/fnc_show_range_card.sqf +++ b/addons/atragmx/functions/fnc_show_range_card.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_range_card + * false call ace_atragmx_fnc_show_range_card * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_range_card_setup.sqf b/addons/atragmx/functions/fnc_show_range_card_setup.sqf index f4d55f33d1..6597e4ee7e 100644 --- a/addons/atragmx/functions/fnc_show_range_card_setup.sqf +++ b/addons/atragmx/functions/fnc_show_range_card_setup.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_range_card_setup + * false call ace_atragmx_fnc_show_range_card_setup * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_solution_setup.sqf b/addons/atragmx/functions/fnc_show_solution_setup.sqf index 761df45e6f..83476228f4 100644 --- a/addons/atragmx/functions/fnc_show_solution_setup.sqf +++ b/addons/atragmx/functions/fnc_show_solution_setup.sqf @@ -6,7 +6,7 @@ * visible - * * Return Value: - * Nothing + * None * * Example: * false call ace_atragmx_fnc_show_solution_setup diff --git a/addons/atragmx/functions/fnc_show_target_data.sqf b/addons/atragmx/functions/fnc_show_target_data.sqf index f1b432edf8..7a0845f862 100644 --- a/addons/atragmx/functions/fnc_show_target_data.sqf +++ b/addons/atragmx/functions/fnc_show_target_data.sqf @@ -6,7 +6,7 @@ * visible - * * Return Value: - * Nothing + * None * * Example: * false call ace_atragmx_fnc_show_target_data diff --git a/addons/atragmx/functions/fnc_show_target_range_assist.sqf b/addons/atragmx/functions/fnc_show_target_range_assist.sqf index d910271aa4..0f6c7bad04 100644 --- a/addons/atragmx/functions/fnc_show_target_range_assist.sqf +++ b/addons/atragmx/functions/fnc_show_target_range_assist.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_target_range_assist + * false call ace_atragmx_fnc_show_target_range_assist * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_target_speed_assist.sqf b/addons/atragmx/functions/fnc_show_target_speed_assist.sqf index c5a23eb1b7..ac99a4e76e 100644 --- a/addons/atragmx/functions/fnc_show_target_speed_assist.sqf +++ b/addons/atragmx/functions/fnc_show_target_speed_assist.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_target_speed_assist + * false call ace_atragmx_fnc_show_target_speed_assist * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_target_speed_assist_timer.sqf b/addons/atragmx/functions/fnc_show_target_speed_assist_timer.sqf index a731dd194d..cb28390ff6 100644 --- a/addons/atragmx/functions/fnc_show_target_speed_assist_timer.sqf +++ b/addons/atragmx/functions/fnc_show_target_speed_assist_timer.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_target_speed_assist_timer + * false call ace_atragmx_fnc_show_target_speed_assist_timer * * Public: No */ diff --git a/addons/atragmx/functions/fnc_show_truing_drop.sqf b/addons/atragmx/functions/fnc_show_truing_drop.sqf index d4b7ce551f..644fe834b6 100644 --- a/addons/atragmx/functions/fnc_show_truing_drop.sqf +++ b/addons/atragmx/functions/fnc_show_truing_drop.sqf @@ -6,10 +6,10 @@ * visible - * * Return Value: - * Nothing + * None * * Example: - * call ace_atragmx_fnc_show_truing_drop + * false call ace_atragmx_fnc_show_truing_drop * * Public: No */ diff --git a/addons/atragmx/functions/fnc_sord.sqf b/addons/atragmx/functions/fnc_sord.sqf index eacd142c53..792d727c70 100644 --- a/addons/atragmx/functions/fnc_sord.sqf +++ b/addons/atragmx/functions/fnc_sord.sqf @@ -8,7 +8,7 @@ * 2: Inclination (Degrees) * * Return Value: - * Nothing + * None * * Example: * [1000, 45, 1] call ace_microdagr_fnc_recieveRangefinderData diff --git a/addons/atragmx/functions/fnc_store_gun_list.sqf b/addons/atragmx/functions/fnc_store_gun_list.sqf index 3e569f8a59..b3969837d2 100644 --- a/addons/atragmx/functions/fnc_store_gun_list.sqf +++ b/addons/atragmx/functions/fnc_store_gun_list.sqf @@ -3,10 +3,10 @@ * Saves the persistent gun list entries into profileNamespace * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_store_user_data diff --git a/addons/atragmx/functions/fnc_store_user_data.sqf b/addons/atragmx/functions/fnc_store_user_data.sqf index a0b3f9fe80..264ac07458 100644 --- a/addons/atragmx/functions/fnc_store_user_data.sqf +++ b/addons/atragmx/functions/fnc_store_user_data.sqf @@ -3,10 +3,10 @@ * Saves user data into profileNamespace * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_store_user_data @@ -42,4 +42,4 @@ profileNamespace setVariable ["ACE_ATragMX_targetRange", GVAR(targetRange)]; profileNamespace setVariable ["ACE_ATragMX_rangeCardStartRange", GVAR(rangeCardStartRange)]; profileNamespace setVariable ["ACE_ATragMX_rangeCardEndRange", GVAR(rangeCardEndRange)]; profileNamespace setVariable ["ACE_ATragMX_rangeCardIncrement", GVAR(rangeCardIncrement)]; -profileNamespace setVariable ["ACE_ATragMX_rangeCardCurrentColumn", GVAR(rangeCardCurrentColumn)]; \ No newline at end of file +profileNamespace setVariable ["ACE_ATragMX_rangeCardCurrentColumn", GVAR(rangeCardCurrentColumn)]; diff --git a/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf b/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf index d270dbf4c3..d9ae84e1ae 100644 --- a/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf +++ b/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf @@ -3,10 +3,10 @@ * Shows and starts the target speed assist timer * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_target_speed_assist_timer diff --git a/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf b/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf index bda24a48f4..5e420b41f8 100644 --- a/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf @@ -6,7 +6,7 @@ * Apply new data? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_atmo_env_data diff --git a/addons/atragmx/functions/fnc_toggle_c1_ballistic_coefficient_data.sqf b/addons/atragmx/functions/fnc_toggle_c1_ballistic_coefficient_data.sqf index e83f0d985c..c83e21a872 100644 --- a/addons/atragmx/functions/fnc_toggle_c1_ballistic_coefficient_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_c1_ballistic_coefficient_data.sqf @@ -6,7 +6,7 @@ * Apply new data? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_c1_ballistic_coefficient_data diff --git a/addons/atragmx/functions/fnc_toggle_coriolis.sqf b/addons/atragmx/functions/fnc_toggle_coriolis.sqf index 17b081131e..a711d2a55e 100644 --- a/addons/atragmx/functions/fnc_toggle_coriolis.sqf +++ b/addons/atragmx/functions/fnc_toggle_coriolis.sqf @@ -3,10 +3,10 @@ * Toggles the coriolis and spin drift output on/off * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_toggle_coriolis diff --git a/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf b/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf index c8cfe0f8f3..332c0f1aba 100644 --- a/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf @@ -6,7 +6,7 @@ * Apply new data? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_gun_ammo_data diff --git a/addons/atragmx/functions/fnc_toggle_gun_list.sqf b/addons/atragmx/functions/fnc_toggle_gun_list.sqf index e5dbf54bd5..6ff6e3b6f4 100644 --- a/addons/atragmx/functions/fnc_toggle_gun_list.sqf +++ b/addons/atragmx/functions/fnc_toggle_gun_list.sqf @@ -6,7 +6,7 @@ * change gun? * * Return Value: - * Nothing + * None * * Example: * false call ace_atragmx_fnc_toggle_gun_list diff --git a/addons/atragmx/functions/fnc_toggle_muzzle_velocity_data.sqf b/addons/atragmx/functions/fnc_toggle_muzzle_velocity_data.sqf index 9a334b35ca..d00992d856 100644 --- a/addons/atragmx/functions/fnc_toggle_muzzle_velocity_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_muzzle_velocity_data.sqf @@ -6,7 +6,7 @@ * Apply new data? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_muzzle_velocity_data diff --git a/addons/atragmx/functions/fnc_toggle_option_menu.sqf b/addons/atragmx/functions/fnc_toggle_option_menu.sqf index 99928e2cc8..f7d7f06a13 100644 --- a/addons/atragmx/functions/fnc_toggle_option_menu.sqf +++ b/addons/atragmx/functions/fnc_toggle_option_menu.sqf @@ -6,7 +6,7 @@ * open menu item * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_option_menu @@ -29,7 +29,7 @@ if (ctrlVisible 3001) then { }; } else { lbClear 3002; - + lbAdd [3002, "Accuracy 1st"]; lbAdd [3002, "Muz Vel Table"]; lbAdd [3002, "Drag Coef Table"]; @@ -43,9 +43,9 @@ if (ctrlVisible 3001) then { }; lbAdd [3002, "Set Clicks"]; lbAdd [3002, "Gun Note"]; - + lbSetCurSel [3002, 0]; - + ctrlShow [3001, true]; ctrlShow [3002, true]; diff --git a/addons/atragmx/functions/fnc_toggle_range_card.sqf b/addons/atragmx/functions/fnc_toggle_range_card.sqf index 7d8b7a0239..4e7ea4d511 100644 --- a/addons/atragmx/functions/fnc_toggle_range_card.sqf +++ b/addons/atragmx/functions/fnc_toggle_range_card.sqf @@ -3,10 +3,10 @@ * Toggles the range card screen on/off * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_toggle_range_card diff --git a/addons/atragmx/functions/fnc_toggle_range_card_setup.sqf b/addons/atragmx/functions/fnc_toggle_range_card_setup.sqf index 96c31459b2..e5d68c3933 100644 --- a/addons/atragmx/functions/fnc_toggle_range_card_setup.sqf +++ b/addons/atragmx/functions/fnc_toggle_range_card_setup.sqf @@ -6,7 +6,7 @@ * Apply new range card settings * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_range_card_setup diff --git a/addons/atragmx/functions/fnc_toggle_solution_setup.sqf b/addons/atragmx/functions/fnc_toggle_solution_setup.sqf index 5372b205d0..f548df689f 100644 --- a/addons/atragmx/functions/fnc_toggle_solution_setup.sqf +++ b/addons/atragmx/functions/fnc_toggle_solution_setup.sqf @@ -6,7 +6,7 @@ * Apply new data? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_solution_setup diff --git a/addons/atragmx/functions/fnc_toggle_target_data.sqf b/addons/atragmx/functions/fnc_toggle_target_data.sqf index 44892ca882..863af6511f 100644 --- a/addons/atragmx/functions/fnc_toggle_target_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_target_data.sqf @@ -6,7 +6,7 @@ * Apply new data? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_target_data diff --git a/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf b/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf index 83d2daa95f..ad593830f9 100644 --- a/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf +++ b/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf @@ -6,7 +6,7 @@ * update range? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_target_range_assist diff --git a/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf b/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf index 4d1680d195..cbeabc48ac 100644 --- a/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf +++ b/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf @@ -6,7 +6,7 @@ * update speed? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_target_speed_assist diff --git a/addons/atragmx/functions/fnc_toggle_truing_drop.sqf b/addons/atragmx/functions/fnc_toggle_truing_drop.sqf index 8c2e72587c..9865005c78 100644 --- a/addons/atragmx/functions/fnc_toggle_truing_drop.sqf +++ b/addons/atragmx/functions/fnc_toggle_truing_drop.sqf @@ -6,7 +6,7 @@ * Apply new data? * * Return Value: - * Nothing + * None * * Example: * 1 call ace_atragmx_fnc_toggle_truing_drop diff --git a/addons/atragmx/functions/fnc_trim_gun_name.sqf b/addons/atragmx/functions/fnc_trim_gun_name.sqf index 2ab603c804..36344d6dfa 100644 --- a/addons/atragmx/functions/fnc_trim_gun_name.sqf +++ b/addons/atragmx/functions/fnc_trim_gun_name.sqf @@ -3,10 +3,10 @@ * Trims the gun name input field * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_trim_gun_name diff --git a/addons/atragmx/functions/fnc_true_c1_ballistic_coefficient.sqf b/addons/atragmx/functions/fnc_true_c1_ballistic_coefficient.sqf index 6af3e179ac..dfa41ea0b4 100644 --- a/addons/atragmx/functions/fnc_true_c1_ballistic_coefficient.sqf +++ b/addons/atragmx/functions/fnc_true_c1_ballistic_coefficient.sqf @@ -3,10 +3,10 @@ * Trues the c1 ballistic coefficient * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_true_c1_ballistic_coefficient diff --git a/addons/atragmx/functions/fnc_true_muzzle_velocity.sqf b/addons/atragmx/functions/fnc_true_muzzle_velocity.sqf index d8aa478412..db907aa29d 100644 --- a/addons/atragmx/functions/fnc_true_muzzle_velocity.sqf +++ b/addons/atragmx/functions/fnc_true_muzzle_velocity.sqf @@ -3,10 +3,10 @@ * Trues the muzzle velocity * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_true_muzzle_velocity diff --git a/addons/atragmx/functions/fnc_update_atmo_env_data.sqf b/addons/atragmx/functions/fnc_update_atmo_env_data.sqf index 7cd34754da..e8e805c0ab 100644 --- a/addons/atragmx/functions/fnc_update_atmo_env_data.sqf +++ b/addons/atragmx/functions/fnc_update_atmo_env_data.sqf @@ -3,10 +3,10 @@ * Updates the atmospheric data fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_atmo_env_data diff --git a/addons/atragmx/functions/fnc_update_atmo_selection.sqf b/addons/atragmx/functions/fnc_update_atmo_selection.sqf index 18036178b4..cd808326f8 100644 --- a/addons/atragmx/functions/fnc_update_atmo_selection.sqf +++ b/addons/atragmx/functions/fnc_update_atmo_selection.sqf @@ -3,10 +3,10 @@ * Updates the atmospheric data input method * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_atmo_selection diff --git a/addons/atragmx/functions/fnc_update_atmosphere.sqf b/addons/atragmx/functions/fnc_update_atmosphere.sqf index be7565bda7..d54daed532 100644 --- a/addons/atragmx/functions/fnc_update_atmosphere.sqf +++ b/addons/atragmx/functions/fnc_update_atmosphere.sqf @@ -3,10 +3,10 @@ * Updates all atmosphere column input fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_atmosphere diff --git a/addons/atragmx/functions/fnc_update_c1_ballistic_coefficient_data.sqf b/addons/atragmx/functions/fnc_update_c1_ballistic_coefficient_data.sqf index d63d9768da..5095ee0d96 100644 --- a/addons/atragmx/functions/fnc_update_c1_ballistic_coefficient_data.sqf +++ b/addons/atragmx/functions/fnc_update_c1_ballistic_coefficient_data.sqf @@ -3,10 +3,10 @@ * Updates the c1 ballistic coefficient data fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_c1_ballistic_coefficient_data diff --git a/addons/atragmx/functions/fnc_update_gun.sqf b/addons/atragmx/functions/fnc_update_gun.sqf index aa1f8c44bf..ff7de54a1c 100644 --- a/addons/atragmx/functions/fnc_update_gun.sqf +++ b/addons/atragmx/functions/fnc_update_gun.sqf @@ -3,10 +3,10 @@ * Updates all gun column input fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_gun diff --git a/addons/atragmx/functions/fnc_update_gun_ammo_data.sqf b/addons/atragmx/functions/fnc_update_gun_ammo_data.sqf index abdb401454..7d29252b28 100644 --- a/addons/atragmx/functions/fnc_update_gun_ammo_data.sqf +++ b/addons/atragmx/functions/fnc_update_gun_ammo_data.sqf @@ -3,10 +3,10 @@ * Updates the gun ammo data fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_gun_ammo_data diff --git a/addons/atragmx/functions/fnc_update_inclination_angle.sqf b/addons/atragmx/functions/fnc_update_inclination_angle.sqf index ea5599bf2d..223a7ae4d4 100644 --- a/addons/atragmx/functions/fnc_update_inclination_angle.sqf +++ b/addons/atragmx/functions/fnc_update_inclination_angle.sqf @@ -6,7 +6,7 @@ * Reference input field ID * * Return Value: - * Nothing + * None * * Example: * 0 call ace_atragmx_fnc_update_inclination_angle diff --git a/addons/atragmx/functions/fnc_update_muzzle_velocity_data.sqf b/addons/atragmx/functions/fnc_update_muzzle_velocity_data.sqf index 989d3d113c..466d83cc4c 100644 --- a/addons/atragmx/functions/fnc_update_muzzle_velocity_data.sqf +++ b/addons/atragmx/functions/fnc_update_muzzle_velocity_data.sqf @@ -3,10 +3,10 @@ * Updates the muzzle velocity data fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_muzzle_velocity_data diff --git a/addons/atragmx/functions/fnc_update_range_card.sqf b/addons/atragmx/functions/fnc_update_range_card.sqf index e8c910ca74..5656a45fe5 100644 --- a/addons/atragmx/functions/fnc_update_range_card.sqf +++ b/addons/atragmx/functions/fnc_update_range_card.sqf @@ -3,10 +3,10 @@ * Updates the range card listbox content * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_range_card diff --git a/addons/atragmx/functions/fnc_update_relative_click_memory.sqf b/addons/atragmx/functions/fnc_update_relative_click_memory.sqf index 1dc534ce4b..fe09d46cf7 100644 --- a/addons/atragmx/functions/fnc_update_relative_click_memory.sqf +++ b/addons/atragmx/functions/fnc_update_relative_click_memory.sqf @@ -3,10 +3,10 @@ * Updates the relative click memory * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_relative_click_memory diff --git a/addons/atragmx/functions/fnc_update_result.sqf b/addons/atragmx/functions/fnc_update_result.sqf index 2541222583..98718e6955 100644 --- a/addons/atragmx/functions/fnc_update_result.sqf +++ b/addons/atragmx/functions/fnc_update_result.sqf @@ -3,10 +3,10 @@ * Updates the result input and output fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_result @@ -28,7 +28,7 @@ _wind2 = GVAR(windage2Output) select GVAR(currentTarget); if (GVAR(showCoriolis)) then { _elevationRel = GVAR(verticalCoriolisOutput) select GVAR(currentTarget); _windageRel = GVAR(horizontalCoriolisOutput) select GVAR(currentTarget); - + _windageCur = GVAR(spinDriftOutput) select GVAR(currentTarget); } else { _elevationCur = GVAR(workingMemory) select 10; diff --git a/addons/atragmx/functions/fnc_update_scope_unit.sqf b/addons/atragmx/functions/fnc_update_scope_unit.sqf index 46db8c40c4..b66d0885bb 100644 --- a/addons/atragmx/functions/fnc_update_scope_unit.sqf +++ b/addons/atragmx/functions/fnc_update_scope_unit.sqf @@ -3,10 +3,10 @@ * Updates the scope unit fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_scope_unit @@ -26,4 +26,4 @@ if (GVAR(currentScopeUnit) == 3) then { } else { ctrlSetText [5000, GVAR(scopeUnits) select GVAR(currentScopeUnit)]; ctrlShow [2001, false]; -}; \ No newline at end of file +}; diff --git a/addons/atragmx/functions/fnc_update_solution_setup.sqf b/addons/atragmx/functions/fnc_update_solution_setup.sqf index 204a844c9d..8850c937a5 100644 --- a/addons/atragmx/functions/fnc_update_solution_setup.sqf +++ b/addons/atragmx/functions/fnc_update_solution_setup.sqf @@ -3,10 +3,10 @@ * Updates all solution setup input fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_solution_setup diff --git a/addons/atragmx/functions/fnc_update_target.sqf b/addons/atragmx/functions/fnc_update_target.sqf index ef2ef1de5c..c457a5cc21 100644 --- a/addons/atragmx/functions/fnc_update_target.sqf +++ b/addons/atragmx/functions/fnc_update_target.sqf @@ -3,10 +3,10 @@ * Updates all target column input fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_target diff --git a/addons/atragmx/functions/fnc_update_target_data.sqf b/addons/atragmx/functions/fnc_update_target_data.sqf index 6fa9035a62..3cb6c24c9c 100644 --- a/addons/atragmx/functions/fnc_update_target_data.sqf +++ b/addons/atragmx/functions/fnc_update_target_data.sqf @@ -3,10 +3,10 @@ * Updates all target column input fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_target diff --git a/addons/atragmx/functions/fnc_update_target_selection.sqf b/addons/atragmx/functions/fnc_update_target_selection.sqf index d9fd6002c9..7ae6256f33 100644 --- a/addons/atragmx/functions/fnc_update_target_selection.sqf +++ b/addons/atragmx/functions/fnc_update_target_selection.sqf @@ -3,10 +3,10 @@ * Updates all input fields based on the currently selected target * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_target_selection diff --git a/addons/atragmx/functions/fnc_update_truing_drop_data.sqf b/addons/atragmx/functions/fnc_update_truing_drop_data.sqf index 5d97780d49..161e8877e1 100644 --- a/addons/atragmx/functions/fnc_update_truing_drop_data.sqf +++ b/addons/atragmx/functions/fnc_update_truing_drop_data.sqf @@ -3,10 +3,10 @@ * Updates the truing drop data fields * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_truing_drop_data diff --git a/addons/atragmx/functions/fnc_update_truing_drop_selection.sqf b/addons/atragmx/functions/fnc_update_truing_drop_selection.sqf index 98f7483276..e00876e4a1 100644 --- a/addons/atragmx/functions/fnc_update_truing_drop_selection.sqf +++ b/addons/atragmx/functions/fnc_update_truing_drop_selection.sqf @@ -3,10 +3,10 @@ * Updates the truing drop input method * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_truing_drop_selection diff --git a/addons/atragmx/functions/fnc_update_unit_selection.sqf b/addons/atragmx/functions/fnc_update_unit_selection.sqf index f054857078..2fc5400e27 100644 --- a/addons/atragmx/functions/fnc_update_unit_selection.sqf +++ b/addons/atragmx/functions/fnc_update_unit_selection.sqf @@ -3,10 +3,10 @@ * Updates all input fields based on the currently selected unit * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_unit_selection diff --git a/addons/atragmx/functions/fnc_update_zero_range.sqf b/addons/atragmx/functions/fnc_update_zero_range.sqf index e4b3d0da8c..f0f787d7cf 100644 --- a/addons/atragmx/functions/fnc_update_zero_range.sqf +++ b/addons/atragmx/functions/fnc_update_zero_range.sqf @@ -3,10 +3,10 @@ * Updates the scope base angle based on the zero range input * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * call ace_atragmx_fnc_update_zero_range diff --git a/addons/attach/functions/fnc_attach.sqf b/addons/attach/functions/fnc_attach.sqf index e48a850209..3bbf085ca4 100644 --- a/addons/attach/functions/fnc_attach.sqf +++ b/addons/attach/functions/fnc_attach.sqf @@ -8,7 +8,7 @@ * 2: Array containing a string of the attachable item * * Return Value: - * Nothing + * None * * Example: * [bob, bob, ["light"]] call ace_attach_fnc_attach; diff --git a/addons/attach/functions/fnc_detach.sqf b/addons/attach/functions/fnc_detach.sqf index 4ff4f9fbd6..945e399b74 100644 --- a/addons/attach/functions/fnc_detach.sqf +++ b/addons/attach/functions/fnc_detach.sqf @@ -7,7 +7,7 @@ * 1: unit doing the detaching (player) * * Return Value: - * Nothing + * None * * Example: * [car, bob] call ace_attach_fnc_detach @@ -69,7 +69,7 @@ if (toLower _itemName in ["b_ir_grenade", "o_ir_grenade", "i_ir_grenade"]) then detach _x; deleteVehicle _x; } forEach (attachedObjects _attachedObject); - + // Delete attached item detach _attachedObject; deleteVehicle _attachedObject; diff --git a/addons/attach/functions/fnc_placeApprove.sqf b/addons/attach/functions/fnc_placeApprove.sqf index 922136107e..895f91a7b6 100644 --- a/addons/attach/functions/fnc_placeApprove.sqf +++ b/addons/attach/functions/fnc_placeApprove.sqf @@ -16,7 +16,7 @@ * 5: Starting Pos of dummy item * * Return Value: - * Nothing + * None * * Example: * No diff --git a/addons/backpacks/functions/fnc_backpackOpened.sqf b/addons/backpacks/functions/fnc_backpackOpened.sqf index 8b4e05c20e..0b94b391f0 100644 --- a/addons/backpacks/functions/fnc_backpackOpened.sqf +++ b/addons/backpacks/functions/fnc_backpackOpened.sqf @@ -3,13 +3,16 @@ * Someone opened your backpack. Play sound and camshake. Execute locally. * * Arguments: - * 0: Who accessed your inventory? (Object) - * 1: Unit that wields the backpack (Object) - * 2: The backpack object (Object) + * 0: Who accessed your inventory? + * 1: Unit that wields the backpack + * 2: The backpack object * * Return Value: * None * + * Example: + * [bob, kevin, backpack] call ace_backpacks_fnc_backpackOpened + * * Public: No */ #include "script_component.hpp" diff --git a/addons/backpacks/functions/fnc_isBackpack.sqf b/addons/backpacks/functions/fnc_isBackpack.sqf index aa12b85ad9..80550290f2 100644 --- a/addons/backpacks/functions/fnc_isBackpack.sqf +++ b/addons/backpacks/functions/fnc_isBackpack.sqf @@ -8,6 +8,9 @@ * Return Value: * Boolean * + * Example: + * [bob] call ace_backpacks_fnc_isBackpack + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/backpacks/functions/fnc_onOpenInventory.sqf b/addons/backpacks/functions/fnc_onOpenInventory.sqf index 0857f6b7ab..b229bbb111 100644 --- a/addons/backpacks/functions/fnc_onOpenInventory.sqf +++ b/addons/backpacks/functions/fnc_onOpenInventory.sqf @@ -7,7 +7,10 @@ * 1: Backpack * * Return Value: - * false. Always open the inventory dialog. (Bool) + * false. Always open the inventory dialog. + * + * Example: + * [bob, backpack] call ace_backpacks_fnc_onOpenInventory * * Public: No */ diff --git a/addons/captives/functions/fnc_doFriskPerson.sqf b/addons/captives/functions/fnc_doFriskPerson.sqf index d3ddecfd13..700fba4ffb 100644 --- a/addons/captives/functions/fnc_doFriskPerson.sqf +++ b/addons/captives/functions/fnc_doFriskPerson.sqf @@ -7,7 +7,7 @@ * 1: unit * * Return Value: - * Nothing + * None * * Example: * [player, bob] call ACE_captives_fnc_doFristPerson; diff --git a/addons/captives/functions/fnc_doLoadCaptive.sqf b/addons/captives/functions/fnc_doLoadCaptive.sqf index a06a569e12..82e446b460 100644 --- a/addons/captives/functions/fnc_doLoadCaptive.sqf +++ b/addons/captives/functions/fnc_doLoadCaptive.sqf @@ -8,7 +8,7 @@ * 2: Vehicle to load the captive into. ObjNull for the nearest vehicle * * Return Value: - * Nothing + * None * * Example: * [bob, tom, car] call ACE_captives_fnc_doLoadCaptive diff --git a/addons/captives/functions/fnc_doUnloadCaptive.sqf b/addons/captives/functions/fnc_doUnloadCaptive.sqf index fd4375e4b7..93bdab114c 100644 --- a/addons/captives/functions/fnc_doUnloadCaptive.sqf +++ b/addons/captives/functions/fnc_doUnloadCaptive.sqf @@ -7,7 +7,7 @@ * 1: A captive loaded in a vehicle * * Return Value: - * Nothing + * None * * Example: * [bob, prisoner] call ACE_captives_fnc_doUnloadCaptive diff --git a/addons/captives/functions/fnc_handleAnimChangedHandcuffed.sqf b/addons/captives/functions/fnc_handleAnimChangedHandcuffed.sqf index c876a4f364..f71a3f04a3 100644 --- a/addons/captives/functions/fnc_handleAnimChangedHandcuffed.sqf +++ b/addons/captives/functions/fnc_handleAnimChangedHandcuffed.sqf @@ -6,9 +6,12 @@ * 0: The Unit * 1: New animation * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, "movearm"] call ACE_captives_fnc_handleAnimChangedHandcuffed + * * Public: No */ diff --git a/addons/captives/functions/fnc_handleAnimChangedSurrendered.sqf b/addons/captives/functions/fnc_handleAnimChangedSurrendered.sqf index cf17d8b873..304926600f 100644 --- a/addons/captives/functions/fnc_handleAnimChangedSurrendered.sqf +++ b/addons/captives/functions/fnc_handleAnimChangedSurrendered.sqf @@ -6,9 +6,12 @@ * 0: The Unit * 1: New animation * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, "movearm"] call ACE_captives_fnc_handleAnimChangedSurrendered + * * Public: No */ diff --git a/addons/captives/functions/fnc_handleLocal.sqf b/addons/captives/functions/fnc_handleLocal.sqf index 693eb844fd..ee11e74fcb 100644 --- a/addons/captives/functions/fnc_handleLocal.sqf +++ b/addons/captives/functions/fnc_handleLocal.sqf @@ -6,9 +6,12 @@ * 0: The Unit * 1: Is local * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, true] call ACE_captives_fnc_handleLocal + * * Public: No */ diff --git a/addons/captives/functions/fnc_handleOnUnconscious.sqf b/addons/captives/functions/fnc_handleOnUnconscious.sqf index 456161d9de..d89d18c506 100644 --- a/addons/captives/functions/fnc_handleOnUnconscious.sqf +++ b/addons/captives/functions/fnc_handleOnUnconscious.sqf @@ -7,7 +7,7 @@ * 0: Is Unconsisisiouses * * Return Value: - * Nothing + * None * * Example: * [bob, true] call ACE_captives_fnc_handleOnUnconscious diff --git a/addons/captives/functions/fnc_handleRespawn.sqf b/addons/captives/functions/fnc_handleRespawn.sqf index 0181640a28..98672798fd 100644 --- a/addons/captives/functions/fnc_handleRespawn.sqf +++ b/addons/captives/functions/fnc_handleRespawn.sqf @@ -7,7 +7,7 @@ * 1: Corpse * * Return Value: - * Nothing + * None * * Example: * [alive, body] call ACE_captives_fnc_handleRespawn; diff --git a/addons/captives/functions/fnc_handleZeusDisplayChanged.sqf b/addons/captives/functions/fnc_handleZeusDisplayChanged.sqf index 433c1fc259..bdb1450874 100644 --- a/addons/captives/functions/fnc_handleZeusDisplayChanged.sqf +++ b/addons/captives/functions/fnc_handleZeusDisplayChanged.sqf @@ -8,7 +8,7 @@ * 1: Display is now open * * Return Value: - * Nothing + * None * * Example: * [bob1, false] call ACE_captives_fnc_handleZeusDisplayChanged diff --git a/addons/captives/functions/fnc_moduleHandcuffed.sqf b/addons/captives/functions/fnc_moduleHandcuffed.sqf index b2e0b431b3..5b04696678 100644 --- a/addons/captives/functions/fnc_moduleHandcuffed.sqf +++ b/addons/captives/functions/fnc_moduleHandcuffed.sqf @@ -9,7 +9,7 @@ * 2: Activated * * Return Value: - * Nothing + * None * * Example: * [objNull, [player], true] call ace_captives_fnc_moduleHandcuffed diff --git a/addons/captives/functions/fnc_moduleSettings.sqf b/addons/captives/functions/fnc_moduleSettings.sqf index fc8c76721f..6be3fb8d56 100644 --- a/addons/captives/functions/fnc_moduleSettings.sqf +++ b/addons/captives/functions/fnc_moduleSettings.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [LOGIC] call ace_captives_fnc_moduleSettings + * * Public: No */ diff --git a/addons/captives/functions/fnc_moduleSurrender.sqf b/addons/captives/functions/fnc_moduleSurrender.sqf index c4482ce904..9f3bd8cdf9 100644 --- a/addons/captives/functions/fnc_moduleSurrender.sqf +++ b/addons/captives/functions/fnc_moduleSurrender.sqf @@ -9,7 +9,7 @@ * 2: Activated * * Return Value: - * Nothing + * None * * Example: * [objNull, [player], true] call ace_captives_fnc_moduleSurrender diff --git a/addons/captives/functions/fnc_setHandcuffed.sqf b/addons/captives/functions/fnc_setHandcuffed.sqf index d2011b5292..9a713af0b4 100644 --- a/addons/captives/functions/fnc_setHandcuffed.sqf +++ b/addons/captives/functions/fnc_setHandcuffed.sqf @@ -7,7 +7,7 @@ * 1: True to take captive, false to release captive * * Return Value: - * Nothing + * None * * Example: * [bob, true] call ACE_captives_fnc_setHandcuffed; diff --git a/addons/captives/functions/fnc_setSurrendered.sqf b/addons/captives/functions/fnc_setSurrendered.sqf index 53e709bab7..a0551d0219 100644 --- a/addons/captives/functions/fnc_setSurrendered.sqf +++ b/addons/captives/functions/fnc_setSurrendered.sqf @@ -7,7 +7,7 @@ * 1: True to surrender, false to un-surrender * * Return Value: - * Nothing + * None * * Example: * [Pierre, true] call ACE_captives_fnc_setSurrendered; diff --git a/addons/captives/functions/fnc_vehicleCaptiveMoveIn.sqf b/addons/captives/functions/fnc_vehicleCaptiveMoveIn.sqf index 503d80de2c..fa1d920a0d 100644 --- a/addons/captives/functions/fnc_vehicleCaptiveMoveIn.sqf +++ b/addons/captives/functions/fnc_vehicleCaptiveMoveIn.sqf @@ -7,7 +7,7 @@ * 1: The Vehicle * * Return Value: - * Nothing + * None * * Example: * [bob, car1] call ACE_captives_fnc_vehicleCaptiveMoveIn; diff --git a/addons/captives/functions/fnc_vehicleCaptiveMoveOut.sqf b/addons/captives/functions/fnc_vehicleCaptiveMoveOut.sqf index ce44b5926f..329adc1740 100644 --- a/addons/captives/functions/fnc_vehicleCaptiveMoveOut.sqf +++ b/addons/captives/functions/fnc_vehicleCaptiveMoveOut.sqf @@ -6,7 +6,7 @@ * 0: Captive Unit being unloaded * * Return Value: - * Nothing + * None * * Example: * [bob] call ACE_captives_fnc_vehicleCaptiveMoveOut; diff --git a/addons/cargo/functions/fnc_paradropItem.sqf b/addons/cargo/functions/fnc_paradropItem.sqf index e1c04799fb..0f74787723 100644 --- a/addons/cargo/functions/fnc_paradropItem.sqf +++ b/addons/cargo/functions/fnc_paradropItem.sqf @@ -6,7 +6,7 @@ * 0: Object * 1: Vehicle * - * Return value: + * Return Value: * Object unloaded * * Example: diff --git a/addons/chemlights/functions/fnc_compileChemlightMenu.sqf b/addons/chemlights/functions/fnc_compileChemlightMenu.sqf index 74b0a154c9..c87c4247ec 100644 --- a/addons/chemlights/functions/fnc_compileChemlightMenu.sqf +++ b/addons/chemlights/functions/fnc_compileChemlightMenu.sqf @@ -7,7 +7,7 @@ * 1: Player * 2: Parameters * - * Return value: + * Return Value: * None * * Example: @@ -29,7 +29,7 @@ private _chemlights = [_player] call FUNC(getShieldComponents); private _icon = getText (_config >> "picture"); private _shieldClass = getText (_config >> "ACE_Chemlight_Shield"); private _displayName = getText (configFile >> "CfgWeapons" >> _shieldClass >> "displayName"); - + _displayName = format [localize LSTRING(Action_Prepare), _displayName]; private _statement = {_this call FUNC(prepShield)}; diff --git a/addons/chemlights/functions/fnc_getShieldComponents.sqf b/addons/chemlights/functions/fnc_getShieldComponents.sqf index be089b261c..6055070351 100644 --- a/addons/chemlights/functions/fnc_getShieldComponents.sqf +++ b/addons/chemlights/functions/fnc_getShieldComponents.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Unit to check * - * Return value: + * Return Value: * List of carried chemlight classnames * * Example: diff --git a/addons/chemlights/functions/fnc_prepShield.sqf b/addons/chemlights/functions/fnc_prepShield.sqf index 52623d6488..b4861da080 100644 --- a/addons/chemlights/functions/fnc_prepShield.sqf +++ b/addons/chemlights/functions/fnc_prepShield.sqf @@ -7,7 +7,7 @@ * 1: Activator Unit (player) * 2: Chemlight class, chemlight shield class * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/common/functions/fnc_ASLToPosition.sqf b/addons/common/functions/fnc_ASLToPosition.sqf index a5afb1db75..0f745cd2bb 100644 --- a/addons/common/functions/fnc_ASLToPosition.sqf +++ b/addons/common/functions/fnc_ASLToPosition.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [1, 2, 3] call ace_common_fnc_ASLToPosition + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc__handleRequestAllSyncedEvents.sqf b/addons/common/functions/fnc__handleRequestAllSyncedEvents.sqf index 4aa2b8e675..e41436078c 100644 --- a/addons/common/functions/fnc__handleRequestAllSyncedEvents.sqf +++ b/addons/common/functions/fnc__handleRequestAllSyncedEvents.sqf @@ -8,6 +8,9 @@ * Return Value: * Event is successed * + * Example: + * [bob] call ace_common_fnc__handleRequestAllSyncedEvents + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc__handleRequestSyncedEvent.sqf b/addons/common/functions/fnc__handleRequestSyncedEvent.sqf index f3fd2e241d..61711eb0b0 100644 --- a/addons/common/functions/fnc__handleRequestSyncedEvent.sqf +++ b/addons/common/functions/fnc__handleRequestSyncedEvent.sqf @@ -2,17 +2,21 @@ * Author: jaynus * Receives either requests for synchronization from clients, or the synchronization data from the server. * - * Arguments [Client] : + * Arguments [Client]: * 0: eventName * 1: eventLog * - * Arguments [Server] : + * Arguments [Server]: * 0: eventName * 1: client * * Return Value: * Event is successed * + * Example: + * ["name", [LOG]] call ace_common_fnc__handleRequestSyncedEvent //Client + * ["name", bob] call ace_common_fnc__handleRequestSyncedEvent//Server + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc__handleSyncedEvent.sqf b/addons/common/functions/fnc__handleSyncedEvent.sqf index d773e424fd..f59c8a6535 100644 --- a/addons/common/functions/fnc__handleSyncedEvent.sqf +++ b/addons/common/functions/fnc__handleSyncedEvent.sqf @@ -2,7 +2,7 @@ * Author: jaynus * Handles synced events being received. Server will log them, and server/client will execute them. * - * Arguments [Client] : + * Arguments: [Client] * 0: eventName * 1: arguments * 2: ttl @@ -10,6 +10,9 @@ * Return Value: * Boolean of success * + * Example: + * [bob] call ace_common_fnc__handleSyncedEvent + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_addActionEventHandler.sqf b/addons/common/functions/fnc_addActionEventHandler.sqf index 56d2de16db..18d337225f 100644 --- a/addons/common/functions/fnc_addActionEventHandler.sqf +++ b/addons/common/functions/fnc_addActionEventHandler.sqf @@ -11,6 +11,9 @@ * Return Value: * ID of the action (used to remove it later) * + * Example: + * [bob, "DefaultAction", "condition", "execute"] call ace_common_fnc_addActionEventHandler + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_addActionMenuEventHandler.sqf b/addons/common/functions/fnc_addActionMenuEventHandler.sqf index c86cf45f17..94028b9aea 100644 --- a/addons/common/functions/fnc_addActionMenuEventHandler.sqf +++ b/addons/common/functions/fnc_addActionMenuEventHandler.sqf @@ -15,6 +15,9 @@ * Return Value: * ID of the action (used to remove it later) * + * Example: + * [bob, "Title", "DefaultAction", "condition", "execute", "conditionmenu", "executemenu", 5] call ace_common_fnc_addActionMenuEventHandler + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_addCanInteractWithCondition.sqf b/addons/common/functions/fnc_addCanInteractWithCondition.sqf index 294dac1c72..7c2bc3591b 100644 --- a/addons/common/functions/fnc_addCanInteractWithCondition.sqf +++ b/addons/common/functions/fnc_addCanInteractWithCondition.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * ["ID", {Condition}] call ace_common_fnc_addCanInteractWithCondition + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_addLineToDebugDraw.sqf b/addons/common/functions/fnc_addLineToDebugDraw.sqf index 5fd7f028ba..5fca9d68c1 100644 --- a/addons/common/functions/fnc_addLineToDebugDraw.sqf +++ b/addons/common/functions/fnc_addLineToDebugDraw.sqf @@ -8,7 +8,7 @@ * 2: Color * * Return Value: - * Nothing + * None * * Example: * [[0,0,0], [1,1,0], [1,0,0,1]]] call ace_common_fnc_addLineToDebugDraw; diff --git a/addons/common/functions/fnc_addMapMarkerCreatedEventHandler.sqf b/addons/common/functions/fnc_addMapMarkerCreatedEventHandler.sqf index 2201426e48..1b82b9fedf 100644 --- a/addons/common/functions/fnc_addMapMarkerCreatedEventHandler.sqf +++ b/addons/common/functions/fnc_addMapMarkerCreatedEventHandler.sqf @@ -8,6 +8,9 @@ * Return Value: * ID of the event script (used to remove it later). * + * Example: + * ["bob"] call ace_common_fnc_addMapMarkerCreatedEventHandler + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_addSetting.sqf b/addons/common/functions/fnc_addSetting.sqf index c4b97ddcce..0e5d391b1a 100644 --- a/addons/common/functions/fnc_addSetting.sqf +++ b/addons/common/functions/fnc_addSetting.sqf @@ -16,6 +16,9 @@ * Return Value: * None * + * Example: + * ["bob", "type", true, "bob", "person", [1,2,3], true, 5] call ace_common_fnc_addSettings + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_addToInventory.sqf b/addons/common/functions/fnc_addToInventory.sqf index 187a218382..19aea9bcdd 100644 --- a/addons/common/functions/fnc_addToInventory.sqf +++ b/addons/common/functions/fnc_addToInventory.sqf @@ -12,6 +12,9 @@ * 0: Added to player * 1: weaponholder * + * Example: + * [bob, "classname", "", 5] call ace_common_fnc_addToInventory + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_ambientBrightness.sqf b/addons/common/functions/fnc_ambientBrightness.sqf index 4ec2840e47..276d7aa5c3 100644 --- a/addons/common/functions/fnc_ambientBrightness.sqf +++ b/addons/common/functions/fnc_ambientBrightness.sqf @@ -8,6 +8,9 @@ * Return Value: * Ambient brightness * + * Example: + * [] call ace_common_fnc_ambientBrightness + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_arithmeticGetResult.sqf b/addons/common/functions/fnc_arithmeticGetResult.sqf index d3fb67b1af..3dae9b23a0 100644 --- a/addons/common/functions/fnc_arithmeticGetResult.sqf +++ b/addons/common/functions/fnc_arithmeticGetResult.sqf @@ -8,7 +8,7 @@ * 2: Operation (sum, product, min, max, avg) * * Return Value: - * + * Value * * Example: * [ace_player, "ace_aimCoefficents", "product"] call ace_common_fnc_arithmeticGetResult diff --git a/addons/common/functions/fnc_arithmeticSetSource.sqf b/addons/common/functions/fnc_arithmeticSetSource.sqf index 1cb156bcc3..a11cb29527 100644 --- a/addons/common/functions/fnc_arithmeticSetSource.sqf +++ b/addons/common/functions/fnc_arithmeticSetSource.sqf @@ -9,7 +9,7 @@ * 3: Code that returns a number (can access var _namespace) [use {} to remove] * * Return Value: - * Nothing + * None * * Example: * [missionNameSpace, "ace_hearing", "myMission", {0.5}] call ace_common_fnc_arithmeticSetSource diff --git a/addons/common/functions/fnc_assignedItemFix.sqf b/addons/common/functions/fnc_assignedItemFix.sqf index 9a4ac5bf47..f7fe02f30c 100644 --- a/addons/common/functions/fnc_assignedItemFix.sqf +++ b/addons/common/functions/fnc_assignedItemFix.sqf @@ -8,7 +8,10 @@ * Return Value: * None * - * Public : No + * Example: + * call ace_common_fnc_assignedItemFix + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_binarizeNumber.sqf b/addons/common/functions/fnc_binarizeNumber.sqf index 0945afa770..82494e39d6 100644 --- a/addons/common/functions/fnc_binarizeNumber.sqf +++ b/addons/common/functions/fnc_binarizeNumber.sqf @@ -9,6 +9,9 @@ * Return Value: * Booleans * + * Example: + * [5, 5] call ace_common_fnc_binarizeNumber + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_blurScreen.sqf b/addons/common/functions/fnc_blurScreen.sqf index 4a6c0d3cb4..0995c957d9 100644 --- a/addons/common/functions/fnc_blurScreen.sqf +++ b/addons/common/functions/fnc_blurScreen.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: ID - * 1: Show? + * 1: Show? * * Return Value: * None diff --git a/addons/common/functions/fnc_cachedCall.sqf b/addons/common/functions/fnc_cachedCall.sqf index 3463e1db55..8636ffff84 100644 --- a/addons/common/functions/fnc_cachedCall.sqf +++ b/addons/common/functions/fnc_cachedCall.sqf @@ -13,6 +13,9 @@ * Return Value: * Result of the function * + * Example: + * [[array]], {dothings}, NAMESPACE, "UID", 5, "clear"] call ace_common_fnc_cachedCall + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_canGetInPosition.sqf b/addons/common/functions/fnc_canGetInPosition.sqf index c470337d6a..c0379c861a 100644 --- a/addons/common/functions/fnc_canGetInPosition.sqf +++ b/addons/common/functions/fnc_canGetInPosition.sqf @@ -7,12 +7,14 @@ * 1: The vehicle to be entered * 2: Position. Can be "Driver", "Pilot", "Gunner", "Commander", "Copilot", "Turret", "FFV", "Codriver" or "Cargo" * 3: Check current distance to vehicles memory point? (default: false) - * 4: Index. "Turret", "FFV", "Codriver" and "Cargo" support this optional parameter. Which position should be taken. - * Note: This index is diffrent from Armas "cargoIndex". (default: next free index) + * 4: Index. "Turret", "FFV", "Codriver" and "Cargo" support this optional parameter. Which position should be taken. Note: This index is different from Armas "cargoIndex". (default: next free index) * * Return Value: * None * + * Example: + * [bob, car, "Pilot", true, "Turret"] call ace_common_fnc_canGetInPosition + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_canInteractWith.sqf b/addons/common/functions/fnc_canInteractWith.sqf index 7603452965..a94ba6d9d1 100644 --- a/addons/common/functions/fnc_canInteractWith.sqf +++ b/addons/common/functions/fnc_canInteractWith.sqf @@ -8,7 +8,10 @@ * 2: Exceptions. What general conditions are to skip? (default: []) * * Return Value: - * Unit can interact? + * Unit can interact? + * + * Example: + * [bob, target, []] call ace_common_fnc_canInteractWith * * Public: Yes */ diff --git a/addons/common/functions/fnc_changeProjectileDirection.sqf b/addons/common/functions/fnc_changeProjectileDirection.sqf index 89a8988306..6e42ee332a 100644 --- a/addons/common/functions/fnc_changeProjectileDirection.sqf +++ b/addons/common/functions/fnc_changeProjectileDirection.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bullet, 2, 5, 3] call ace_common_fnc_changeProjectileDirection + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_checkFiles.sqf b/addons/common/functions/fnc_checkFiles.sqf index f0821f3f4c..480cdab9a9 100644 --- a/addons/common/functions/fnc_checkFiles.sqf +++ b/addons/common/functions/fnc_checkFiles.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_checkFiles + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_checkPBOs.sqf b/addons/common/functions/fnc_checkPBOs.sqf index 886ae3b5ca..2504d73dc1 100644 --- a/addons/common/functions/fnc_checkPBOs.sqf +++ b/addons/common/functions/fnc_checkPBOs.sqf @@ -14,6 +14,9 @@ * Return Value: * None * + * Example: + * [0, false, ""] call ace_common_fnc_checkPBOs + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_claim.sqf b/addons/common/functions/fnc_claim.sqf index b3fe3d5544..79237d725b 100644 --- a/addons/common/functions/fnc_claim.sqf +++ b/addons/common/functions/fnc_claim.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, flag, true] call ace_common_fnc_claim + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_codeToString.sqf b/addons/common/functions/fnc_codeToString.sqf index 62e4cb5698..ff4597f7bb 100644 --- a/addons/common/functions/fnc_codeToString.sqf +++ b/addons/common/functions/fnc_codeToString.sqf @@ -8,6 +8,9 @@ * Return Value: * Code * + * Example: + * ["bob"] call ace_common_fnc_codeToString + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_createOrthonormalReference.sqf b/addons/common/functions/fnc_createOrthonormalReference.sqf index e45bf269aa..cb443de15b 100644 --- a/addons/common/functions/fnc_createOrthonormalReference.sqf +++ b/addons/common/functions/fnc_createOrthonormalReference.sqf @@ -2,7 +2,7 @@ * Author: esteldunedain * Returns a orthonormal system of reference aligned with the supplied vector * - * Arguments: + * Arguments: * Vector to align the coordinate system with * * Return Value: @@ -10,6 +10,9 @@ * 1: Normalized Cross Product Vector * 2: Vector Cross Product * + * Example: + * [[0,0,0]] call ace_common_fnc_createOrthonormalReference + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_currentChannel.sqf b/addons/common/functions/fnc_currentChannel.sqf index a78e2b0204..0844ebd881 100644 --- a/addons/common/functions/fnc_currentChannel.sqf +++ b/addons/common/functions/fnc_currentChannel.sqf @@ -8,6 +8,9 @@ * Return Value: * The current channel ("group", "side", "global", "command", "vehicle", "direct", "custom_X") * + * Example: + * [] call ace_common_fnc_currentChannel + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_debug.sqf b/addons/common/functions/fnc_debug.sqf index 019ce2abff..a825c82523 100644 --- a/addons/common/functions/fnc_debug.sqf +++ b/addons/common/functions/fnc_debug.sqf @@ -9,6 +9,9 @@ * Return Value: * Message is Printed * + * Example: + * [bob, 2] call ace_common_fnc_debug + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_debugModule.sqf b/addons/common/functions/fnc_debugModule.sqf index 125887183e..c4fa7b8547 100644 --- a/addons/common/functions/fnc_debugModule.sqf +++ b/addons/common/functions/fnc_debugModule.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_debugModule + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_defineVariable.sqf b/addons/common/functions/fnc_defineVariable.sqf index 35a1e96d31..7c1a694aeb 100644 --- a/addons/common/functions/fnc_defineVariable.sqf +++ b/addons/common/functions/fnc_defineVariable.sqf @@ -13,6 +13,9 @@ * Return Value: * None * + * Example: + * ["bob", 1, true, "category", 1, true] call ace_common_fnc_defineVariable + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_deviceKeyFindValidIndex.sqf b/addons/common/functions/fnc_deviceKeyFindValidIndex.sqf index 7b692ce300..aeacf940cc 100644 --- a/addons/common/functions/fnc_deviceKeyFindValidIndex.sqf +++ b/addons/common/functions/fnc_deviceKeyFindValidIndex.sqf @@ -3,7 +3,7 @@ * Finds next valid index for the device array. * * Arguments: - * 0: Offset from currentIndex (use 1 to find next valid after current) or a displayName string (default: 0) + * 0: Offset from currentIndex (use 1 to find next valid after current) or a displayName string (default: 0) * * Return Value: * The new index (-1 if no valid) diff --git a/addons/common/functions/fnc_disableUserInput.sqf b/addons/common/functions/fnc_disableUserInput.sqf index 8e28edc5f0..729da9b504 100644 --- a/addons/common/functions/fnc_disableUserInput.sqf +++ b/addons/common/functions/fnc_disableUserInput.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [true] call ace_common_fnc_disableUserInput + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_displayText.sqf b/addons/common/functions/fnc_displayText.sqf index ee22f6949a..fdd1f960d5 100644 --- a/addons/common/functions/fnc_displayText.sqf +++ b/addons/common/functions/fnc_displayText.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * ["Message", true, 5, 2] call ace_common_fnc_displayText + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_dropBackpack.sqf b/addons/common/functions/fnc_dropBackpack.sqf index b0d77af7d5..dcbb9a3f70 100644 --- a/addons/common/functions/fnc_dropBackpack.sqf +++ b/addons/common/functions/fnc_dropBackpack.sqf @@ -8,6 +8,9 @@ * Return Value: * Ground wepaon holder with backpack * + * Example: + * [unit] call ace_common_fnc_dropBackpack + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_dumpPerformanceCounters.sqf b/addons/common/functions/fnc_dumpPerformanceCounters.sqf index ec6f225ce4..a6bcc1d29c 100644 --- a/addons/common/functions/fnc_dumpPerformanceCounters.sqf +++ b/addons/common/functions/fnc_dumpPerformanceCounters.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_dumpPerformanceCounters + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_endRadioTransmission.sqf b/addons/common/functions/fnc_endRadioTransmission.sqf index 4597426d67..ead1ec29c6 100644 --- a/addons/common/functions/fnc_endRadioTransmission.sqf +++ b/addons/common/functions/fnc_endRadioTransmission.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_endRadioTransmission + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_eraseCache.sqf b/addons/common/functions/fnc_eraseCache.sqf index ae988ced28..0bcfab1dd4 100644 --- a/addons/common/functions/fnc_eraseCache.sqf +++ b/addons/common/functions/fnc_eraseCache.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [NAMESPACE, "UID"] call ace_common_fnc_eraseCache + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_errorMessage.sqf b/addons/common/functions/fnc_errorMessage.sqf index 88e0a3b90f..8ccd7c22fb 100644 --- a/addons/common/functions/fnc_errorMessage.sqf +++ b/addons/common/functions/fnc_errorMessage.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_errorMessage + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_firedEH.sqf b/addons/common/functions/fnc_firedEH.sqf index 29e58a4c6a..cbf49f626b 100644 --- a/addons/common/functions/fnc_firedEH.sqf +++ b/addons/common/functions/fnc_firedEH.sqf @@ -14,6 +14,9 @@ * Return Value: * None * + * Example: + * [bob, "gun", "muzzle", "single", "ammo", "magazine", "bullet"] call ace_common_fnc_firedEH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_fixCollision.sqf b/addons/common/functions/fnc_fixCollision.sqf index 3b3b16a9f9..569d7d1e87 100644 --- a/addons/common/functions/fnc_fixCollision.sqf +++ b/addons/common/functions/fnc_fixCollision.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_fixCollision + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_fixFloating.sqf b/addons/common/functions/fnc_fixFloating.sqf index 5a00aa3863..dc7608f9fe 100644 --- a/addons/common/functions/fnc_fixFloating.sqf +++ b/addons/common/functions/fnc_fixFloating.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [object] call ace_common_fnc_fixFloating + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_fixLoweredRifleAnimation.sqf b/addons/common/functions/fnc_fixLoweredRifleAnimation.sqf index 9e230b00ad..f804b087d2 100644 --- a/addons/common/functions/fnc_fixLoweredRifleAnimation.sqf +++ b/addons/common/functions/fnc_fixLoweredRifleAnimation.sqf @@ -6,7 +6,7 @@ * 0: Unit * * Return Value: - * Nothing + * None * * Example: * [ACE_player] call ace_common_fnc_fixLoweredRifleAnimation diff --git a/addons/common/functions/fnc_fixPosition.sqf b/addons/common/functions/fnc_fixPosition.sqf index 883a502c4e..fb14141fe2 100644 --- a/addons/common/functions/fnc_fixPosition.sqf +++ b/addons/common/functions/fnc_fixPosition.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_fixPosition + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getAllDefinedSetVariables.sqf b/addons/common/functions/fnc_getAllDefinedSetVariables.sqf index a5d973767f..fd94ae8024 100644 --- a/addons/common/functions/fnc_getAllDefinedSetVariables.sqf +++ b/addons/common/functions/fnc_getAllDefinedSetVariables.sqf @@ -14,6 +14,9 @@ * 3: publicFlag * 4: peristentFlag * + * Example: + * [bob, ""] call ace_common_fnc_getAllDefinedSetVariables + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getChildren.sqf b/addons/common/functions/fnc_getChildren.sqf index f2930b015d..56bc5d779c 100644 --- a/addons/common/functions/fnc_getChildren.sqf +++ b/addons/common/functions/fnc_getChildren.sqf @@ -7,6 +7,9 @@ * * Return Value: * Parent Entry Class Children + + * Example: + * [bob] call ace_common_fnc_getChildren * * Public: Yes */ diff --git a/addons/common/functions/fnc_getConfigCommander.sqf b/addons/common/functions/fnc_getConfigCommander.sqf index d4a53905b8..45d7d6389c 100644 --- a/addons/common/functions/fnc_getConfigCommander.sqf +++ b/addons/common/functions/fnc_getConfigCommander.sqf @@ -7,6 +7,9 @@ * * Return Value: * Commander config + + * Example: + * [car] call ace_common_fnc_getConfigCommander * * Public: Yes */ diff --git a/addons/common/functions/fnc_getConfigGunner.sqf b/addons/common/functions/fnc_getConfigGunner.sqf index abbbd5f014..c14eb85ed5 100644 --- a/addons/common/functions/fnc_getConfigGunner.sqf +++ b/addons/common/functions/fnc_getConfigGunner.sqf @@ -8,6 +8,9 @@ * Return Value: * Gunner config * + * Example: + * [car] call ace_common_fnc_getConfigGunner + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getDefinedVariable.sqf b/addons/common/functions/fnc_getDefinedVariable.sqf index 32a75edb5e..98267ab18f 100644 --- a/addons/common/functions/fnc_getDefinedVariable.sqf +++ b/addons/common/functions/fnc_getDefinedVariable.sqf @@ -9,6 +9,9 @@ * Return Value: * Value of variable or default value, if the variable is undefined * + * Example: + * [bob, "var"] call ace_common_fnc_getDefinedVariable + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getDefinedVariableDefault.sqf b/addons/common/functions/fnc_getDefinedVariableDefault.sqf index c6f4f7711c..88199f8ad3 100644 --- a/addons/common/functions/fnc_getDefinedVariableDefault.sqf +++ b/addons/common/functions/fnc_getDefinedVariableDefault.sqf @@ -8,6 +8,9 @@ * Return Value: * Default value of variable * + * Example: + * ["name"] call ace_common_fnc_getDefinedVariableDefault + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getDefinedVariableInfo.sqf b/addons/common/functions/fnc_getDefinedVariableInfo.sqf index adcb70c6ee..e22ba193f6 100644 --- a/addons/common/functions/fnc_getDefinedVariableInfo.sqf +++ b/addons/common/functions/fnc_getDefinedVariableInfo.sqf @@ -8,6 +8,9 @@ * Return Value: * Variable Metadata * + * Example: + * ["var"] call ace_common_fnc_getDefinedVariableInfo + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getDisplayConfigName.sqf b/addons/common/functions/fnc_getDisplayConfigName.sqf index 1660bbf804..d61800e5ce 100644 --- a/addons/common/functions/fnc_getDisplayConfigName.sqf +++ b/addons/common/functions/fnc_getDisplayConfigName.sqf @@ -8,6 +8,9 @@ * Return Value: * Display Classnames * + * Example: + * [5] call ace_common_fnc_getDisplayConfigName + * * Public: Yes * * Note: Really slow due to iteration through whole config. Meant for debugging. diff --git a/addons/common/functions/fnc_getDoorTurrets.sqf b/addons/common/functions/fnc_getDoorTurrets.sqf index 9ef2ad4704..cfb0369d63 100644 --- a/addons/common/functions/fnc_getDoorTurrets.sqf +++ b/addons/common/functions/fnc_getDoorTurrets.sqf @@ -8,6 +8,9 @@ * Return Value: * All turret indecies of the Vehicle * + * Example: + * [car] call ace_common_fnc_getDoorTurrets + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getFirstObjectIntersection.sqf b/addons/common/functions/fnc_getFirstObjectIntersection.sqf index c4cc46ab9b..951f48ad16 100644 --- a/addons/common/functions/fnc_getFirstObjectIntersection.sqf +++ b/addons/common/functions/fnc_getFirstObjectIntersection.sqf @@ -11,6 +11,9 @@ * 0: Intersects * 1: Intersection Position ASL * + * Example: + * [[1,2,3], [0,0,5], 5] call ace_common_fnc_getFirstObjectIntersection + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getFirstTerrainIntersection.sqf b/addons/common/functions/fnc_getFirstTerrainIntersection.sqf index 27a6f3c613..cfb2397c95 100644 --- a/addons/common/functions/fnc_getFirstTerrainIntersection.sqf +++ b/addons/common/functions/fnc_getFirstTerrainIntersection.sqf @@ -11,6 +11,9 @@ * 0: Intersects * 1: Intersection Position ASL * + * Example: + * [[1,2,3], [0,0,5], 5] call ace_common_fnc_getFirstTerrainIntersection + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getGunner.sqf b/addons/common/functions/fnc_getGunner.sqf index c11f2882ca..85f4cef199 100644 --- a/addons/common/functions/fnc_getGunner.sqf +++ b/addons/common/functions/fnc_getGunner.sqf @@ -9,6 +9,9 @@ * Return Value: * Gunner * + * Example: + * [car, "gun"] call ace_common_fnc_getGunner + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getInPosition.sqf b/addons/common/functions/fnc_getInPosition.sqf index 5d6e5d71b5..a19a150704 100644 --- a/addons/common/functions/fnc_getInPosition.sqf +++ b/addons/common/functions/fnc_getInPosition.sqf @@ -1,16 +1,19 @@ /* * Author: commy2 * Move unit into given vehicle position or switch to that position if the unit is already inside the vehicle. - * - * Arguments: + * + * Arguments: * 0: Unit * 1: Vehicle * 2: Position ("Driver", "Pilot", "Gunner", "Commander", "Copilot", "Turret", "FFV", "Codriver", "Cargo") * 3: Index (only applies to "Turret", "FFV", "Codriver", "Cargo") (default: next free index) - * - * Return Value: + * + * Return Value: * None * + * Example: + * [unit, vehicle, "Driver", 5] call ace_common_fnc_getInPosition + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getItemType.sqf b/addons/common/functions/fnc_getItemType.sqf index eb5015e20a..33d9d267e4 100644 --- a/addons/common/functions/fnc_getItemType.sqf +++ b/addons/common/functions/fnc_getItemType.sqf @@ -9,6 +9,9 @@ * 0: Type ("weapon", "item", "magazine", "") * 1: Item Description * + * Example: + * ["tire"] call ace_common_fnc_getItemType + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getLightProperties.sqf b/addons/common/functions/fnc_getLightProperties.sqf index a376dff841..ffaddfaf87 100644 --- a/addons/common/functions/fnc_getLightProperties.sqf +++ b/addons/common/functions/fnc_getLightProperties.sqf @@ -13,6 +13,9 @@ * 3: Light inner angle * 4: Light outer angle * + * Example: + * [car, "light"] call ace_common_fnc_getLightProperties + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getLightPropertiesWeapon.sqf b/addons/common/functions/fnc_getLightPropertiesWeapon.sqf index 44c866e67f..dfcd483304 100644 --- a/addons/common/functions/fnc_getLightPropertiesWeapon.sqf +++ b/addons/common/functions/fnc_getLightPropertiesWeapon.sqf @@ -12,6 +12,9 @@ * 3: Light inner angle * 4: Light outer angle * + * Example: + * ["flashlight"] call ace_common_fnc_getLightPropertiesWeapon + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index 7854380b18..4e0df618e1 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -12,6 +12,9 @@ * 1: 100km square * 2: GZD + 100km sq. as a single string * + * Example: + * ["worldName"] call ace_common_fnc_getMGRSdata + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getMapData.sqf b/addons/common/functions/fnc_getMapData.sqf index 5fd183a3a3..aaa878676c 100644 --- a/addons/common/functions/fnc_getMapData.sqf +++ b/addons/common/functions/fnc_getMapData.sqf @@ -9,6 +9,9 @@ * 0: Latitude * 1: Altitude * + * Example: + * ["altis"] call ace_common_fnc_getMapData + * * Public: No */ diff --git a/addons/common/functions/fnc_getMapPosFromGrid.sqf b/addons/common/functions/fnc_getMapPosFromGrid.sqf index a148679fa9..18599f4ef4 100644 --- a/addons/common/functions/fnc_getMapPosFromGrid.sqf +++ b/addons/common/functions/fnc_getMapPosFromGrid.sqf @@ -6,7 +6,7 @@ * 0: Grid Cords * 1: Grid center (true), Grid Bottom Right (false) (default: true) * - * Return values: + * Return Value: * Position * * Example: diff --git a/addons/common/functions/fnc_getMarkerType.sqf b/addons/common/functions/fnc_getMarkerType.sqf index 0da7f1a46e..3d5864cf08 100644 --- a/addons/common/functions/fnc_getMarkerType.sqf +++ b/addons/common/functions/fnc_getMarkerType.sqf @@ -3,11 +3,14 @@ * Get the apropriate marker for a group. * * Arguments: - * 0: Group + * 0: Group * * Return Value: * Marker Type * + * Example: + * ["GROUP"] call ace_common_fnc_getmarkerType + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getNumberMagazinesIn.sqf b/addons/common/functions/fnc_getNumberMagazinesIn.sqf index 90e6b7d352..dd02d055e0 100644 --- a/addons/common/functions/fnc_getNumberMagazinesIn.sqf +++ b/addons/common/functions/fnc_getNumberMagazinesIn.sqf @@ -9,6 +9,9 @@ * Return Value: * Magazine amount * + * Example: + * [bob, "magazine"] call ace_common_fnc_getNumberMagazinesIn + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getPitchBankYaw.sqf b/addons/common/functions/fnc_getPitchBankYaw.sqf index 89fab8d92b..2a7a5c43e8 100644 --- a/addons/common/functions/fnc_getPitchBankYaw.sqf +++ b/addons/common/functions/fnc_getPitchBankYaw.sqf @@ -10,6 +10,9 @@ * 1: bank * 2: yaw * + * Example: + * [plane] call ace_common_fnc_getPitchBankYaw + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getReflectorsWithSelections.sqf b/addons/common/functions/fnc_getReflectorsWithSelections.sqf index 248050486c..d166818494 100644 --- a/addons/common/functions/fnc_getReflectorsWithSelections.sqf +++ b/addons/common/functions/fnc_getReflectorsWithSelections.sqf @@ -12,6 +12,9 @@ * 0: Light Hitpoints * 1: Selections * + * Example: + * [car] call ace_common_fnc_getReflectorsWithSelections + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getSelectionsWithoutHitPoints.sqf b/addons/common/functions/fnc_getSelectionsWithoutHitPoints.sqf index b46ec308ec..028024a94e 100644 --- a/addons/common/functions/fnc_getSelectionsWithoutHitPoints.sqf +++ b/addons/common/functions/fnc_getSelectionsWithoutHitPoints.sqf @@ -4,10 +4,15 @@ * Returns all damageable selections without hitpoints of any vehicle. * * Arguments: - * 0: A vehicle, not the classname (Object) + * 0: A vehicle, not the classname * * Return Value: - * The selections without hitpoints, i.e. reflectors. (Array) + * The selections without hitpoints, i.e. reflectors. + * + * Example: + * [car] call ace_common_fnc_getSelectionsWithoutHitPoints + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getSettingData.sqf b/addons/common/functions/fnc_getSettingData.sqf index ae9dd5351e..0eb76d9b7b 100644 --- a/addons/common/functions/fnc_getSettingData.sqf +++ b/addons/common/functions/fnc_getSettingData.sqf @@ -6,7 +6,7 @@ * 0: Setting Name * * Return Value: - * Setting Data (Array) + * Setting Data * 0: Name * 1: Type Name * 2: Is Client Settable @@ -17,6 +17,9 @@ * 7: Default Value * 8: Localized Category * + * Example: + * ["setting"] call ace_common_fnc_getSettingData + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getStaminaBarControl.sqf b/addons/common/functions/fnc_getStaminaBarControl.sqf index 1fa747fef6..cfdef5bb35 100644 --- a/addons/common/functions/fnc_getStaminaBarControl.sqf +++ b/addons/common/functions/fnc_getStaminaBarControl.sqf @@ -8,6 +8,9 @@ * Return Value: * Stamina Bar control * + * Example: + * call ace_common_fnc_getStaminaBarControl + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTargetAzimuthAndInclination.sqf b/addons/common/functions/fnc_getTargetAzimuthAndInclination.sqf index 0d2343bec9..98e7a5e3b2 100644 --- a/addons/common/functions/fnc_getTargetAzimuthAndInclination.sqf +++ b/addons/common/functions/fnc_getTargetAzimuthAndInclination.sqf @@ -9,6 +9,9 @@ * 0: Azimuth * 1: Inclination * + * Example: + * [] call ace_common_fnc_getTargetAzimuthAndInclination + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTargetDistance.sqf b/addons/common/functions/fnc_getTargetDistance.sqf index 000f0ae31d..c93941eb12 100644 --- a/addons/common/functions/fnc_getTargetDistance.sqf +++ b/addons/common/functions/fnc_getTargetDistance.sqf @@ -10,6 +10,9 @@ * Return Value: * Distance in meters * + * Example: + * [5,20000,56] call ace_common_fnc_getTargetDistance + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTargetObject.sqf b/addons/common/functions/fnc_getTargetObject.sqf index ed757dedf4..9ee1d26ff3 100644 --- a/addons/common/functions/fnc_getTargetObject.sqf +++ b/addons/common/functions/fnc_getTargetObject.sqf @@ -8,6 +8,9 @@ * Return Value: * Nearest object in line of sight, objNull if none are found * + * Example: + * [56] call ace_common_fnc_getTargetObject + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurnedOnLights.sqf b/addons/common/functions/fnc_getTurnedOnLights.sqf index a996e146d2..f95a4bbf19 100644 --- a/addons/common/functions/fnc_getTurnedOnLights.sqf +++ b/addons/common/functions/fnc_getTurnedOnLights.sqf @@ -8,6 +8,9 @@ * Return Value: * All burning lights * + * Example: + * [car] call ace_common_fnc_getTurnedOnLights + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurretCommander.sqf b/addons/common/functions/fnc_getTurretCommander.sqf index 3e7f09215f..2f832438b5 100644 --- a/addons/common/functions/fnc_getTurretCommander.sqf +++ b/addons/common/functions/fnc_getTurretCommander.sqf @@ -8,6 +8,9 @@ * Return Value: * Vehicle commander turrent indecies * + * Example: + * [car] call ace_common_fnc_getTurretCommander + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurretConfigPath.sqf b/addons/common/functions/fnc_getTurretConfigPath.sqf index 95d0773fd3..6af9aa62e3 100644 --- a/addons/common/functions/fnc_getTurretConfigPath.sqf +++ b/addons/common/functions/fnc_getTurretConfigPath.sqf @@ -9,6 +9,9 @@ * Return Value: * Turret config * + * Example: + * [CfgVehicle, [Array]] call ace_common_fnc_getTurretConfigPath + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurretCopilot.sqf b/addons/common/functions/fnc_getTurretCopilot.sqf index 49002cc40e..ef52200f6e 100644 --- a/addons/common/functions/fnc_getTurretCopilot.sqf +++ b/addons/common/functions/fnc_getTurretCopilot.sqf @@ -8,6 +8,9 @@ * Return Value: * Vehicle Copilot Turret indecies * + * Example: + * [car] call ace_common_fnc_getTurretCopilot + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurretDirection.sqf b/addons/common/functions/fnc_getTurretDirection.sqf index 5861586402..7bec5cf3e6 100644 --- a/addons/common/functions/fnc_getTurretDirection.sqf +++ b/addons/common/functions/fnc_getTurretDirection.sqf @@ -10,6 +10,9 @@ * 0: Position ASL * 1: Direction * + * Example: + * [car, [5,6,5]] call ace_common_fnc_getTurretDirection + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurretGunner.sqf b/addons/common/functions/fnc_getTurretGunner.sqf index 4a26e2c03d..e1846f96de 100644 --- a/addons/common/functions/fnc_getTurretGunner.sqf +++ b/addons/common/functions/fnc_getTurretGunner.sqf @@ -8,6 +8,9 @@ * Return Value: * Vehicle Gunner Turret indecies * + * Example: + * [car] call ace_common_fnc_getTurretGunner + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurretsFFV.sqf b/addons/common/functions/fnc_getTurretsFFV.sqf index 5c36e20197..885396b2bf 100644 --- a/addons/common/functions/fnc_getTurretsFFV.sqf +++ b/addons/common/functions/fnc_getTurretsFFV.sqf @@ -8,6 +8,9 @@ * Return Value: * Vehicle FFV Turret indecies * + * Example: + * [car] call ace_common_fnc_getTurretsFFV + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getTurretsOther.sqf b/addons/common/functions/fnc_getTurretsOther.sqf index ef2a1278dc..04750e98fd 100644 --- a/addons/common/functions/fnc_getTurretsOther.sqf +++ b/addons/common/functions/fnc_getTurretsOther.sqf @@ -8,6 +8,9 @@ * Return Value: * Vehicle Other Turret indecies * + * Example: + * [car] call ace_common_fnc_getTurretsOther + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getVehicleCargo.sqf b/addons/common/functions/fnc_getVehicleCargo.sqf index 68599c919b..5279825008 100644 --- a/addons/common/functions/fnc_getVehicleCargo.sqf +++ b/addons/common/functions/fnc_getVehicleCargo.sqf @@ -8,6 +8,9 @@ * Return Value: * Vehicle cargo positions * + * Example: + * [car] call ace_common_fnc_getVehicleCargo + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getVehicleCodriver.sqf b/addons/common/functions/fnc_getVehicleCodriver.sqf index a1cc5814e1..8b0fd3be29 100644 --- a/addons/common/functions/fnc_getVehicleCodriver.sqf +++ b/addons/common/functions/fnc_getVehicleCodriver.sqf @@ -8,6 +8,9 @@ * Return Value: * Vehicle codriver positions * + * Example: + * ["car"] call ace_common_fnc_getVehicleCodriver + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getVehicleCrew.sqf b/addons/common/functions/fnc_getVehicleCrew.sqf index adb0e9701a..f0377671e9 100644 --- a/addons/common/functions/fnc_getVehicleCrew.sqf +++ b/addons/common/functions/fnc_getVehicleCrew.sqf @@ -9,6 +9,9 @@ * Return Value: * Crew * + * Example: + * [car, ["driver"]] call ace_common_fnc_getVehicleCrew + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getVehicleUAVCrew.sqf b/addons/common/functions/fnc_getVehicleUAVCrew.sqf index 2b2281ed10..9804a14b68 100644 --- a/addons/common/functions/fnc_getVehicleUAVCrew.sqf +++ b/addons/common/functions/fnc_getVehicleUAVCrew.sqf @@ -8,6 +8,9 @@ * Return Value: * UAV Dummy Crew * + * Example: + * [car] call ace_common_fnc_getVehicleUAVCrew + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getVersion.sqf b/addons/common/functions/fnc_getVersion.sqf index 24773240b7..e0f2ab9f6d 100644 --- a/addons/common/functions/fnc_getVersion.sqf +++ b/addons/common/functions/fnc_getVersion.sqf @@ -8,6 +8,9 @@ * Return Value: * ACE Version * + * Example: + * [] call ace_common_fnc_getVersion + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getWeaponAzimuthAndInclination.sqf b/addons/common/functions/fnc_getWeaponAzimuthAndInclination.sqf index f7c7909e01..604a89b9f8 100644 --- a/addons/common/functions/fnc_getWeaponAzimuthAndInclination.sqf +++ b/addons/common/functions/fnc_getWeaponAzimuthAndInclination.sqf @@ -9,6 +9,9 @@ * 0: Azimuth * 1: Inclination * + * Example: + * ["gun"] call ace_common_fnc_getWeaponAzimuthAndInclination + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getWeaponIndex.sqf b/addons/common/functions/fnc_getWeaponIndex.sqf index 0e24f190a5..a881233469 100644 --- a/addons/common/functions/fnc_getWeaponIndex.sqf +++ b/addons/common/functions/fnc_getWeaponIndex.sqf @@ -13,6 +13,9 @@ * 2 = handgun * -1 = other * + * Example: + * [bob, "gun"] call ace_common_fnc_getWeaponIndex + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getWeaponModes.sqf b/addons/common/functions/fnc_getWeaponModes.sqf index 48755d3a9b..ede86ac842 100644 --- a/addons/common/functions/fnc_getWeaponModes.sqf +++ b/addons/common/functions/fnc_getWeaponModes.sqf @@ -8,6 +8,9 @@ * Return Value: * Firing Modes * + * Example: + * ["gun"] call ace_common_fnc_getWeaponModes + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getWeaponMuzzles.sqf b/addons/common/functions/fnc_getWeaponMuzzles.sqf index e252d879f9..b0b0533721 100644 --- a/addons/common/functions/fnc_getWeaponMuzzles.sqf +++ b/addons/common/functions/fnc_getWeaponMuzzles.sqf @@ -8,6 +8,9 @@ * Return Value: * All weapon muzzles * + * Example: + * ["gun"] call ace_common_fnc_getWeaponMuzzles + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getWeaponState.sqf b/addons/common/functions/fnc_getWeaponState.sqf index 73e5897236..772a5058b9 100644 --- a/addons/common/functions/fnc_getWeaponState.sqf +++ b/addons/common/functions/fnc_getWeaponState.sqf @@ -12,6 +12,9 @@ * 2: Magazines * 3: Ammo * + * Example: + * [bob, "gun"] call ace_common_fnc_getWeaponState + * * Public: Yes */ #include "script_component.hpp" @@ -42,4 +45,4 @@ private _ammo = _muzzles apply {0}; false } count magazinesAmmoFull _unit; -[_attachments, _muzzles, _magazines, _ammo]; +[_attachments, _muzzles, _magazines, _ammo]; diff --git a/addons/common/functions/fnc_getWeaponType.sqf b/addons/common/functions/fnc_getWeaponType.sqf index 5666ea5bc0..b53f23d514 100644 --- a/addons/common/functions/fnc_getWeaponType.sqf +++ b/addons/common/functions/fnc_getWeaponType.sqf @@ -12,6 +12,9 @@ * 3 = handgun * -1 = other * + * Example: + * ["gun"] call ace_common_fnc_getWeaponType + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getWindDirection.sqf b/addons/common/functions/fnc_getWindDirection.sqf index 7341ea9c1d..f35047fc30 100644 --- a/addons/common/functions/fnc_getWindDirection.sqf +++ b/addons/common/functions/fnc_getWindDirection.sqf @@ -8,6 +8,9 @@ * Return Value: * Wind cardinal direction * + * Example: + * [] call ace_common_fnc_getWindDirection + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_getZoom.sqf b/addons/common/functions/fnc_getZoom.sqf index f4113198a7..9c3f7987a4 100644 --- a/addons/common/functions/fnc_getZoom.sqf +++ b/addons/common/functions/fnc_getZoom.sqf @@ -8,10 +8,13 @@ * Return Value: * Zoom * + * Example: + * [] call ace_common_fnc_getZoom + * * Public: Yes */ #include "script_component.hpp" if (!hasInterface) exitWith {0}; -(0.5 - ((worldToScreen positionCameraToWorld [0, 1, 1]) select 1)) * (getResolution select 5) +(0.5 - ((worldToScreen positionCameraToWorld [0, 1, 1]) select 1)) * (getResolution select 5) diff --git a/addons/common/functions/fnc_goKneeling.sqf b/addons/common/functions/fnc_goKneeling.sqf index 9e7aed708a..b838a4f047 100644 --- a/addons/common/functions/fnc_goKneeling.sqf +++ b/addons/common/functions/fnc_goKneeling.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_goKneeling + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_hadamardProduct.sqf b/addons/common/functions/fnc_hadamardProduct.sqf index cdaf707395..20173e7d0b 100644 --- a/addons/common/functions/fnc_hadamardProduct.sqf +++ b/addons/common/functions/fnc_hadamardProduct.sqf @@ -10,6 +10,9 @@ * Return Value: * Hadamard Product * + * Example: + * [[0,0,0], [1,1,1]] call ace_common_fnc_hadamardProduct + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_handleEngine.sqf b/addons/common/functions/fnc_handleEngine.sqf index 829ad5bb49..55696a679e 100644 --- a/addons/common/functions/fnc_handleEngine.sqf +++ b/addons/common/functions/fnc_handleEngine.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, "running"] call ace_common_fnc_handleEngine + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_handleModifierKey.sqf b/addons/common/functions/fnc_handleModifierKey.sqf index bfb7e84931..094ec278f4 100644 --- a/addons/common/functions/fnc_handleModifierKey.sqf +++ b/addons/common/functions/fnc_handleModifierKey.sqf @@ -8,7 +8,10 @@ * Return Value: * None * - * Public : No + * Example: + * call ace_common_fnc_handleModifierKey + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_handleModifierKeyUp.sqf b/addons/common/functions/fnc_handleModifierKeyUp.sqf index ffa5855115..97df636050 100644 --- a/addons/common/functions/fnc_handleModifierKeyUp.sqf +++ b/addons/common/functions/fnc_handleModifierKeyUp.sqf @@ -8,7 +8,10 @@ * Return Value: * None * - * Public : No + * Example: + * call ace_common_fnc_handleModifierKeyUp + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_hasHatch.sqf b/addons/common/functions/fnc_hasHatch.sqf index e39c52f897..b750d01b85 100644 --- a/addons/common/functions/fnc_hasHatch.sqf +++ b/addons/common/functions/fnc_hasHatch.sqf @@ -8,6 +8,9 @@ * Return Value: * Unit has a hatch? * + * Example: + * [bob] call ace_common_fnc_hasHatch + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_hasItem.sqf b/addons/common/functions/fnc_hasItem.sqf index 8ca785d78e..f77337a5dd 100644 --- a/addons/common/functions/fnc_hasItem.sqf +++ b/addons/common/functions/fnc_hasItem.sqf @@ -9,6 +9,9 @@ * Return Value: * has Item * + * Example: + * [[bob, "item"] call ace_common_fnc_hasItem + * * Public: yes * * Note: Case sensitive diff --git a/addons/common/functions/fnc_hasMagazine.sqf b/addons/common/functions/fnc_hasMagazine.sqf index eaa9bc0556..4ad40bf959 100644 --- a/addons/common/functions/fnc_hasMagazine.sqf +++ b/addons/common/functions/fnc_hasMagazine.sqf @@ -9,6 +9,9 @@ * Return Value: * has Magazine * + * Example: + * [bob, "magazine"] call ace_common_fnc_hasMagazine + * * Public: yes * * Note: Case sensitive diff --git a/addons/common/functions/fnc_headBugFix.sqf b/addons/common/functions/fnc_headBugFix.sqf index 07a1652b1b..fca04c234b 100644 --- a/addons/common/functions/fnc_headBugFix.sqf +++ b/addons/common/functions/fnc_headBugFix.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [] call ace_common_fnc_headBugFix + * * Public: Yes * * Note: Has to be spawned not called diff --git a/addons/common/functions/fnc_hideUnit.sqf b/addons/common/functions/fnc_hideUnit.sqf index e0adb201c3..838bd4246e 100644 --- a/addons/common/functions/fnc_hideUnit.sqf +++ b/addons/common/functions/fnc_hideUnit.sqf @@ -7,7 +7,7 @@ * 1: Reason to hide the unit * * Return Value: - * nil + * None * * Example: * [ACE_Player, "SpectatorMode"] call ace_common_fnc_hideUnit diff --git a/addons/common/functions/fnc_inTransitionAnim.sqf b/addons/common/functions/fnc_inTransitionAnim.sqf index fd90291d73..a127fad005 100644 --- a/addons/common/functions/fnc_inTransitionAnim.sqf +++ b/addons/common/functions/fnc_inTransitionAnim.sqf @@ -3,10 +3,13 @@ * Check if given unit is in a transitional animation * * Arguments: - * 0: A soldier + * 0: A soldier * * Return Value: - * + * Boolean + * + * Example: + * [bob] call ace_common_fnc_inTransitionAnim * * Public: Yes */ diff --git a/addons/common/functions/fnc_interpolateFromArray.sqf b/addons/common/functions/fnc_interpolateFromArray.sqf index aac21aab7a..9c63a9798c 100644 --- a/addons/common/functions/fnc_interpolateFromArray.sqf +++ b/addons/common/functions/fnc_interpolateFromArray.sqf @@ -9,6 +9,9 @@ * Return Value: * Interpolation result * + * Example: + * [[0,1], 5] call ace_common_fnc_interpolateFromArray + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_isAwake.sqf b/addons/common/functions/fnc_isAwake.sqf index 1179ced02f..d7f0b79149 100644 --- a/addons/common/functions/fnc_isAwake.sqf +++ b/addons/common/functions/fnc_isAwake.sqf @@ -8,6 +8,9 @@ * Return Value: * if unit is awake * + * Example: + * [bob] call ace_common_fnc_isAwake + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_isInBuilding.sqf b/addons/common/functions/fnc_isInBuilding.sqf index d4a9307cd6..98f092e762 100644 --- a/addons/common/functions/fnc_isInBuilding.sqf +++ b/addons/common/functions/fnc_isInBuilding.sqf @@ -8,6 +8,9 @@ * Return Value: * Is the unit in a building? * + * Example: + * [bob] call ace_common_fnc_isInBuilding + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_isModLoaded.sqf b/addons/common/functions/fnc_isModLoaded.sqf index 46e1bc03a8..f740f58b0b 100644 --- a/addons/common/functions/fnc_isModLoaded.sqf +++ b/addons/common/functions/fnc_isModLoaded.sqf @@ -8,6 +8,9 @@ * Return Value: * if modification is loaded * + * Example: + * ["class"] call ace_common_fnc_isModLoaded + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_isUnderwater.sqf b/addons/common/functions/fnc_isUnderwater.sqf index 637ed49f3d..f3f127d75f 100644 --- a/addons/common/functions/fnc_isUnderwater.sqf +++ b/addons/common/functions/fnc_isUnderwater.sqf @@ -8,6 +8,9 @@ * Return Value: * If unit's head is underwater * + * Example: + * [bob] call ace_common_fnc_isUnderwater + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_lightIntensityFromObject.sqf b/addons/common/functions/fnc_lightIntensityFromObject.sqf index a495897dea..6725a71580 100644 --- a/addons/common/functions/fnc_lightIntensityFromObject.sqf +++ b/addons/common/functions/fnc_lightIntensityFromObject.sqf @@ -7,7 +7,10 @@ * 1: Object that emits light * * Return Value: - * Brightest light level + * Brightest light level + * + * Example: + * [reciever, giver] call ace_common_fnc_lightIntensityFromObject * * Public: Yes */ diff --git a/addons/common/functions/fnc_loadPerson.sqf b/addons/common/functions/fnc_loadPerson.sqf index f8a4456b96..59c9af2c20 100644 --- a/addons/common/functions/fnc_loadPerson.sqf +++ b/addons/common/functions/fnc_loadPerson.sqf @@ -9,6 +9,9 @@ * Return Value: * the vehicle that the unitToBeloaded has been loaded in. Returns ObjNull if function failed * + * Example: + * [bob, kevin] call ace_common_fnc_loadPerson + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_loadPersonLocal.sqf b/addons/common/functions/fnc_loadPersonLocal.sqf index db0248a901..90cbd7da03 100644 --- a/addons/common/functions/fnc_loadPersonLocal.sqf +++ b/addons/common/functions/fnc_loadPersonLocal.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, car, kevin] call ace_common_fnc_loadPersonLocal + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_loadSettingsFromProfile.sqf b/addons/common/functions/fnc_loadSettingsFromProfile.sqf index 46b0134740..9151d79cce 100644 --- a/addons/common/functions/fnc_loadSettingsFromProfile.sqf +++ b/addons/common/functions/fnc_loadSettingsFromProfile.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_loadSettingsFromProfile + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_loadSettingsLocalizedText.sqf b/addons/common/functions/fnc_loadSettingsLocalizedText.sqf index 3fe182b7e3..7ceffa04e7 100644 --- a/addons/common/functions/fnc_loadSettingsLocalizedText.sqf +++ b/addons/common/functions/fnc_loadSettingsLocalizedText.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_loadSettingsLocalizedText + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_loadSettingsOnServer.sqf b/addons/common/functions/fnc_loadSettingsOnServer.sqf index 4498c9d058..eaeac7d51d 100644 --- a/addons/common/functions/fnc_loadSettingsOnServer.sqf +++ b/addons/common/functions/fnc_loadSettingsOnServer.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * call ace_common_fnc_loadSettingsOnServer + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_moduleCheckPBOs.sqf b/addons/common/functions/fnc_moduleCheckPBOs.sqf index 23c9b7ffd3..f3a8c0902c 100644 --- a/addons/common/functions/fnc_moduleCheckPBOs.sqf +++ b/addons/common/functions/fnc_moduleCheckPBOs.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_common_fnc_moduleCheckPBOs + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_moduleLSDVehicles.sqf b/addons/common/functions/fnc_moduleLSDVehicles.sqf index a8e7c8c055..cecc8983a1 100644 --- a/addons/common/functions/fnc_moduleLSDVehicles.sqf +++ b/addons/common/functions/fnc_moduleLSDVehicles.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob, target, []] call ace_common_fnc_moduleLSDVehicles + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_monitor.sqf b/addons/common/functions/fnc_monitor.sqf index 8aef62895c..591e923d1b 100644 --- a/addons/common/functions/fnc_monitor.sqf +++ b/addons/common/functions/fnc_monitor.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [{code}] call ace_common_fnc_monitor + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_muteUnit.sqf b/addons/common/functions/fnc_muteUnit.sqf index 11c18aedd7..25106c979f 100644 --- a/addons/common/functions/fnc_muteUnit.sqf +++ b/addons/common/functions/fnc_muteUnit.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, "because"] call ace_common_fnc_muteUnit + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_muteUnitHandleInitPost.sqf b/addons/common/functions/fnc_muteUnitHandleInitPost.sqf index 53e8d4d5b7..4e6ac7cbaf 100644 --- a/addons/common/functions/fnc_muteUnitHandleInitPost.sqf +++ b/addons/common/functions/fnc_muteUnitHandleInitPost.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_muteUnitHandleInitPost + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_muteUnitHandleRespawn.sqf b/addons/common/functions/fnc_muteUnitHandleRespawn.sqf index ceb0614116..6e93e40ef6 100644 --- a/addons/common/functions/fnc_muteUnitHandleRespawn.sqf +++ b/addons/common/functions/fnc_muteUnitHandleRespawn.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_muteUnitHandleRespawn + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_numberToDigits.sqf b/addons/common/functions/fnc_numberToDigits.sqf index b90f0eefd7..d9aceb2426 100644 --- a/addons/common/functions/fnc_numberToDigits.sqf +++ b/addons/common/functions/fnc_numberToDigits.sqf @@ -9,6 +9,9 @@ * Return Value: * Digits. The maximum count is six digits. * + * Example: + * [5, 5] call ace_common_fnc_numberToDigits + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_numberToDigitsString.sqf b/addons/common/functions/fnc_numberToDigitsString.sqf index 7e2c78f8b4..9f19cfe3dc 100644 --- a/addons/common/functions/fnc_numberToDigitsString.sqf +++ b/addons/common/functions/fnc_numberToDigitsString.sqf @@ -4,11 +4,14 @@ * * Arguments: * 0: Number to 'digitize' - * 1: Set the minimal length of the returned string. Useful for getting left hand zeroes. (Number, optional) + * 1: Set the minimal length of the returned string. Useful for getting left hand zeroes. (Optional) * * Return Value: * Digits. The maximum length is six digits. * + * Example: + * [5, 5] call ace_common_fnc_numberToDigitsString + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_numberToString.sqf b/addons/common/functions/fnc_numberToString.sqf index 1cb2f521f8..8ca22bca88 100644 --- a/addons/common/functions/fnc_numberToString.sqf +++ b/addons/common/functions/fnc_numberToString.sqf @@ -8,6 +8,9 @@ * Return Value: * The number as string * + * Example: + * [5] call ace_common_fnc_numberToString + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_onAnswerRequest.sqf b/addons/common/functions/fnc_onAnswerRequest.sqf index 8c77719256..38f35f1968 100644 --- a/addons/common/functions/fnc_onAnswerRequest.sqf +++ b/addons/common/functions/fnc_onAnswerRequest.sqf @@ -3,10 +3,15 @@ * N/A * * Arguments: - * ? + * 0: Unit + * 1: ID? + * 2: Accepted * * Return Value: - * ? + * None + * + * Example: + * [bob, "ID", true] call ace_common_fnc_onAnswerRequest * * Public: No */ diff --git a/addons/common/functions/fnc_owned.sqf b/addons/common/functions/fnc_owned.sqf index e352795c5e..a8c3f737e7 100644 --- a/addons/common/functions/fnc_owned.sqf +++ b/addons/common/functions/fnc_owned.sqf @@ -6,7 +6,10 @@ * 0: Any object. * * Return Value: - * Is this object claimed by someone? + * Is this object claimed by someone? + * + * Example: + * [bob] call ace_common_fnc_owned * * Public: No */ diff --git a/addons/common/functions/fnc_playConfigSound3D.sqf b/addons/common/functions/fnc_playConfigSound3D.sqf index 236802538e..2631c30d06 100644 --- a/addons/common/functions/fnc_playConfigSound3D.sqf +++ b/addons/common/functions/fnc_playConfigSound3D.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * ["sound", [0,0,0], 5, 5] call ace_common_fnc_playConfigSound3D + * * Public: Yes */ #define DEBUG_MODE_FULL diff --git a/addons/common/functions/fnc_player.sqf b/addons/common/functions/fnc_player.sqf index 1a268515a7..54510be05e 100644 --- a/addons/common/functions/fnc_player.sqf +++ b/addons/common/functions/fnc_player.sqf @@ -9,6 +9,9 @@ * Return Value: * Player controlled unit * + * Example: + * [] call ace_common_fnc_player + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_playerSide.sqf b/addons/common/functions/fnc_playerSide.sqf index 3a7ce5bba9..dd6b7e8b2f 100644 --- a/addons/common/functions/fnc_playerSide.sqf +++ b/addons/common/functions/fnc_playerSide.sqf @@ -8,6 +8,9 @@ * Return Value: * current local side * + * Example: + * [] call ace_common_fnc_playerSide + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_positionToASL.sqf b/addons/common/functions/fnc_positionToASL.sqf index 267bbf2353..297e89ee2b 100644 --- a/addons/common/functions/fnc_positionToASL.sqf +++ b/addons/common/functions/fnc_positionToASL.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [1, 1, 1] call ace_common_fnc_positionToASL + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_progressBar.sqf b/addons/common/functions/fnc_progressBar.sqf index 7103dd08e4..37fb17190a 100644 --- a/addons/common/functions/fnc_progressBar.sqf +++ b/addons/common/functions/fnc_progressBar.sqf @@ -4,16 +4,16 @@ * Finish/Failure/Conditional are all passed [_args, _elapsedTime, _totalTime, _errorCode] * * Arguments: - * 0: NUMBER - Total Time (in game "time" seconds) - * 1: ARRAY - Arguments, passed to condition, fail and finish - * 2: CODE or STRING - On Finish: Code called or STRING raised as event. - * 3: CODE or STRING - On Failure: Code called or STRING raised as event. - * 4: STRING - (Optional) Localized Title - * 5: CODE - (Optional) Code to check each frame - * 6: ARRAY - (Optional) Exceptions for checking EFUNC(common,canInteractWith) + * 0: Total Time (in game "time" seconds) + * 1: Arguments, passed to condition, fail and finish + * 2: On Finish: Code called or STRING raised as event. + * 3: On Failure: Code called or STRING raised as event. + * 4: (Optional) Localized Title + * 5: Code to check each frame (Optional) + * 6: Exceptions for checking EFUNC(common,canInteractWith) (Optional) * * Return Value: - * Nothing + * None * * Example: * [5, [], {Hint "Finished!"}, {hint "Failure!"}, "My Title"] call ace_common_fnc_progressBar diff --git a/addons/common/functions/fnc_readSettingFromModule.sqf b/addons/common/functions/fnc_readSettingFromModule.sqf index b08ceb1bcd..21e7dc7e4b 100644 --- a/addons/common/functions/fnc_readSettingFromModule.sqf +++ b/addons/common/functions/fnc_readSettingFromModule.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [MODULE, "Param", "paramname"] call ace_common_fnc_readSettingFromModule + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_receiveRequest.sqf b/addons/common/functions/fnc_receiveRequest.sqf index 1bb48428df..a3f10550af 100644 --- a/addons/common/functions/fnc_receiveRequest.sqf +++ b/addons/common/functions/fnc_receiveRequest.sqf @@ -3,11 +3,18 @@ * N/A * * Arguments: - * ? + * 0: caller + * 1: target + * 2: requestID + * 3: Message + * 4: callback (NOT USED) * * Return Value: * None * + * Example: + * [bob, kevin, "ID", "Message", {Callback}] call ace_common_fnc_recieveRequest + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_removeActionEventHandler.sqf b/addons/common/functions/fnc_removeActionEventHandler.sqf index 60e551590d..db711b77f4 100644 --- a/addons/common/functions/fnc_removeActionEventHandler.sqf +++ b/addons/common/functions/fnc_removeActionEventHandler.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, "DefaultAction", 5] call ace_common_fnc_removeActionEventHandler + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_removeActionMenuEventHandler.sqf b/addons/common/functions/fnc_removeActionMenuEventHandler.sqf index 943e3b4e22..9fb8ee6588 100644 --- a/addons/common/functions/fnc_removeActionMenuEventHandler.sqf +++ b/addons/common/functions/fnc_removeActionMenuEventHandler.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, "DefaultAction", 5] call ace_common_fnc_removeActionMenuEventHandler + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_removeCanInteractWithCondition.sqf b/addons/common/functions/fnc_removeCanInteractWithCondition.sqf index b267e84557..8c7c72d861 100644 --- a/addons/common/functions/fnc_removeCanInteractWithCondition.sqf +++ b/addons/common/functions/fnc_removeCanInteractWithCondition.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * ["ID"] call ace_common_fnc_removeCanInteractWithCondition + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_removeMapMarkerCreatedEventHandler.sqf b/addons/common/functions/fnc_removeMapMarkerCreatedEventHandler.sqf index 825281c3e0..bda7877a70 100644 --- a/addons/common/functions/fnc_removeMapMarkerCreatedEventHandler.sqf +++ b/addons/common/functions/fnc_removeMapMarkerCreatedEventHandler.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [5] call ace_common_fnc_removeMapMarkerCreatedEventHandler + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_removeSpecificMagazine.sqf b/addons/common/functions/fnc_removeSpecificMagazine.sqf index 4ca5eec6d7..73fe910673 100644 --- a/addons/common/functions/fnc_removeSpecificMagazine.sqf +++ b/addons/common/functions/fnc_removeSpecificMagazine.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, "magazine", 5] call ace_common_fnc_removeSpecificMagazine + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_removeSyncedEventHandler.sqf b/addons/common/functions/fnc_removeSyncedEventHandler.sqf index 090ecf4320..f256c21203 100644 --- a/addons/common/functions/fnc_removeSyncedEventHandler.sqf +++ b/addons/common/functions/fnc_removeSyncedEventHandler.sqf @@ -6,7 +6,10 @@ * 0: Name * * Return Value: - * Boolean of success + * Boolean of success + * + * Example: + * ["bob"] call ace_common_fnc_removeSyncedEventHandler * * Public: No */ diff --git a/addons/common/functions/fnc_requestCallback.sqf b/addons/common/functions/fnc_requestCallback.sqf index 399f50466d..e28ff9439f 100644 --- a/addons/common/functions/fnc_requestCallback.sqf +++ b/addons/common/functions/fnc_requestCallback.sqf @@ -3,10 +3,13 @@ * N/A * * Arguments: - * ? + * ? * * Return Value: - * ? + * ? + * + * Example: + * [bob] call ace_common_fnc_requestCallback * * Public: No */ diff --git a/addons/common/functions/fnc_requestSyncedEvent.sqf b/addons/common/functions/fnc_requestSyncedEvent.sqf index e35c1e3645..fd277c4b36 100644 --- a/addons/common/functions/fnc_requestSyncedEvent.sqf +++ b/addons/common/functions/fnc_requestSyncedEvent.sqf @@ -6,7 +6,10 @@ * 0: eventName * * Return Value: - * Boolean of success + * Boolean of success + * + * Example: + * ["event"] call ace_common_fnc_requestSyncedEvent * * Public: No */ diff --git a/addons/common/functions/fnc_resetAllDefaults.sqf b/addons/common/functions/fnc_resetAllDefaults.sqf index 6432f3759e..367c72d5e9 100644 --- a/addons/common/functions/fnc_resetAllDefaults.sqf +++ b/addons/common/functions/fnc_resetAllDefaults.sqf @@ -3,10 +3,13 @@ * reset all variables that have been defined * * Arguments: - * ? + * 0: Unit * * Return Value: - * ? + * ? + * + * Example: + * [bob] call ace_common_fnc_resetAllDefaults * * Public: No */ diff --git a/addons/common/functions/fnc_restoreVariablesJIP.sqf b/addons/common/functions/fnc_restoreVariablesJIP.sqf index 39626514bb..921be28165 100644 --- a/addons/common/functions/fnc_restoreVariablesJIP.sqf +++ b/addons/common/functions/fnc_restoreVariablesJIP.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_restoreVariablesJIP + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_sendRequest.sqf b/addons/common/functions/fnc_sendRequest.sqf index a0c505c575..55a3da9873 100644 --- a/addons/common/functions/fnc_sendRequest.sqf +++ b/addons/common/functions/fnc_sendRequest.sqf @@ -5,13 +5,16 @@ * Arguments: * 0: caller * 1: target - * 2: requestID (STRING) - * 3: requestMessage Will be localized for other target object. (STRING) - * 4: callback Code called upon accept or decline. (CODE) + * 2: requestID + * 3: requestMessage Will be localized for other target object. + * 4: callback Code called upon accept or decline. * * Return Value: * None * + * Example: + * [bob, kevin, "ID", "Message", {callback}] call ace_common_fnc_sendRequest + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setApproximateVariablePublic.sqf b/addons/common/functions/fnc_setApproximateVariablePublic.sqf index 549dea9eb4..e888efe3c2 100644 --- a/addons/common/functions/fnc_setApproximateVariablePublic.sqf +++ b/addons/common/functions/fnc_setApproximateVariablePublic.sqf @@ -9,7 +9,7 @@ * 3: Absolute tolerance * * Return Value: - * Nothing. + * None * * Example: * [player, "balls", 2, 0.1] call ace_common_fnc_setApproximateVariablePublic; diff --git a/addons/common/functions/fnc_setDefinedVariable.sqf b/addons/common/functions/fnc_setDefinedVariable.sqf index 6f1f0c2e58..70b8ef42e3 100644 --- a/addons/common/functions/fnc_setDefinedVariable.sqf +++ b/addons/common/functions/fnc_setDefinedVariable.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, "var", 5] call ace_common_fnc_setDefinedVariable + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setDisableUserInputStatus.sqf b/addons/common/functions/fnc_setDisableUserInputStatus.sqf index ec475f744f..b217570dac 100644 --- a/addons/common/functions/fnc_setDisableUserInputStatus.sqf +++ b/addons/common/functions/fnc_setDisableUserInputStatus.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * ["id", true] call ace_common_fnc_setDisableUserInputStatus + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setName.sqf b/addons/common/functions/fnc_setName.sqf index f4858b877b..e93e09c0f0 100644 --- a/addons/common/functions/fnc_setName.sqf +++ b/addons/common/functions/fnc_setName.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_setName + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setParameter.sqf b/addons/common/functions/fnc_setParameter.sqf index b24e2506b5..723d49ea0c 100644 --- a/addons/common/functions/fnc_setParameter.sqf +++ b/addons/common/functions/fnc_setParameter.sqf @@ -4,11 +4,14 @@ * * Arguments: * 0: Parameter name - * 1: Value + * 1: Value * * Return Value: * None * + * Example: + * ["Name", 5] call ace_common_fnc_setParameter + * * Public: Yes * * Deprecated diff --git a/addons/common/functions/fnc_setPitchBankYaw.sqf b/addons/common/functions/fnc_setPitchBankYaw.sqf index fecc16208c..1b986c6445 100644 --- a/addons/common/functions/fnc_setPitchBankYaw.sqf +++ b/addons/common/functions/fnc_setPitchBankYaw.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, 1, 2, 3] call ace_common_fnc_setPitchBankYaw + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setProne.sqf b/addons/common/functions/fnc_setProne.sqf index c40b0de254..8df8a4d900 100644 --- a/addons/common/functions/fnc_setProne.sqf +++ b/addons/common/functions/fnc_setProne.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_setProne + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setSettingFromConfig.sqf b/addons/common/functions/fnc_setSettingFromConfig.sqf index ac7a0f4875..6308438ac8 100644 --- a/addons/common/functions/fnc_setSettingFromConfig.sqf +++ b/addons/common/functions/fnc_setSettingFromConfig.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONFIG] call ace_common_fnc_setSettingFromConfig + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setVariableJIP.sqf b/addons/common/functions/fnc_setVariableJIP.sqf index 35e8c0d116..151d7b9925 100644 --- a/addons/common/functions/fnc_setVariableJIP.sqf +++ b/addons/common/functions/fnc_setVariableJIP.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, "varname", 5] call ace_common_fnc_setVariableJIP + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_setVariablePublic.sqf b/addons/common/functions/fnc_setVariablePublic.sqf index d1dcc4c922..2eac69f6ce 100644 --- a/addons/common/functions/fnc_setVariablePublic.sqf +++ b/addons/common/functions/fnc_setVariablePublic.sqf @@ -9,7 +9,7 @@ * 3: Embargo delay (Optional. Default: 1) * * Return Value: - * Nothing. + * None * * Example: * [player, "balls", 2, 1] call ace_common_fnc_setVariablePublic; diff --git a/addons/common/functions/fnc_setVolume.sqf b/addons/common/functions/fnc_setVolume.sqf index 37e1f04cfa..5d7f349ce1 100644 --- a/addons/common/functions/fnc_setVolume.sqf +++ b/addons/common/functions/fnc_setVolume.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [true] call ace_common_fnc_setVolume + * * Public: Yes * * Note: Uses player diff --git a/addons/common/functions/fnc_showUser.sqf b/addons/common/functions/fnc_showUser.sqf index 2e7af12a3f..6c78e03f97 100644 --- a/addons/common/functions/fnc_showUser.sqf +++ b/addons/common/functions/fnc_showUser.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_common_fnc_showUser + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_statusEffect_addType.sqf b/addons/common/functions/fnc_statusEffect_addType.sqf index 2934f4ae98..c423db2393 100644 --- a/addons/common/functions/fnc_statusEffect_addType.sqf +++ b/addons/common/functions/fnc_statusEffect_addType.sqf @@ -8,7 +8,7 @@ * 2: Common Effect Reaons to pre-seed durring init * * Return Value: - * Nothing + * None * * Example: * ["setCaptive", true, []] call ace_common_fnc_statusEffect_addType diff --git a/addons/common/functions/fnc_statusEffect_localEH.sqf b/addons/common/functions/fnc_statusEffect_localEH.sqf index 5490029a3b..84f3e0e9a2 100644 --- a/addons/common/functions/fnc_statusEffect_localEH.sqf +++ b/addons/common/functions/fnc_statusEffect_localEH.sqf @@ -4,9 +4,10 @@ * * Arguments: * 0: vehicle that it will be attached to (player or vehicle) + * 1: isLocal * * Return Value: - * Nothing + * None * * Example: * [player, true] call ace_common_fnc_statusEffect_localEH @@ -19,7 +20,7 @@ params ["_object", "_isLocal"]; TRACE_2("params",_object,_isLocal); -//Only run this after the settings are initialized +//Only run this after the settings are initialized //Need to wait for all EH to be installed (local event will happen between pre and post init) if !(GVAR(settingsInitFinished)) exitWith { TRACE_1("pushing to runAtSettingsInitialized", _this); diff --git a/addons/common/functions/fnc_statusEffect_resetVariables.sqf b/addons/common/functions/fnc_statusEffect_resetVariables.sqf index 2a307c84e5..7f638bcbef 100644 --- a/addons/common/functions/fnc_statusEffect_resetVariables.sqf +++ b/addons/common/functions/fnc_statusEffect_resetVariables.sqf @@ -6,7 +6,7 @@ * 0: vehicle that it will be attached to (player or vehicle) * * Return Value: - * Nothing + * None * * Example: * [player, true] call ace_common_fnc_statusEffect_resetVariables diff --git a/addons/common/functions/fnc_statusEffect_respawnEH.sqf b/addons/common/functions/fnc_statusEffect_respawnEH.sqf index 92717b68c7..ba3058be19 100644 --- a/addons/common/functions/fnc_statusEffect_respawnEH.sqf +++ b/addons/common/functions/fnc_statusEffect_respawnEH.sqf @@ -6,7 +6,7 @@ * 0: vehicle that it will be attached to (player or vehicle) * * Return Value: - * Nothing + * None * * Example: * [player, objNull] call ace_common_fnc_statusEffect_respawnEH @@ -19,7 +19,7 @@ params ["_object"]; TRACE_1("params",_object); -//Only run this after the settings are initialized +//Only run this after the settings are initialized //Need to wait for all EH to be installed (local event will happen between pre and post init) if !(GVAR(settingsInitFinished)) exitWith { TRACE_1("pushing to runAtSettingsInitialized", _this); diff --git a/addons/common/functions/fnc_statusEffect_sendEffects.sqf b/addons/common/functions/fnc_statusEffect_sendEffects.sqf index f82ab10427..0945fc3424 100644 --- a/addons/common/functions/fnc_statusEffect_sendEffects.sqf +++ b/addons/common/functions/fnc_statusEffect_sendEffects.sqf @@ -7,7 +7,7 @@ * 1: Effect name (or "" to send all) * * Return Value: - * Nothing + * None * * Example: * [player, ""] call ace_common_fnc_statusEffect_sendEffects diff --git a/addons/common/functions/fnc_statusEffect_set.sqf b/addons/common/functions/fnc_statusEffect_set.sqf index a0be8d8719..4908da5395 100644 --- a/addons/common/functions/fnc_statusEffect_set.sqf +++ b/addons/common/functions/fnc_statusEffect_set.sqf @@ -9,7 +9,7 @@ * 3: Is Set (true adds/false removes) * * Return Value: - * Nothing + * None * * Example: * [player, "setCaptive", "reason1", true] call ace_common_fnc_statusEffect_set diff --git a/addons/common/functions/fnc_stringCompare.sqf b/addons/common/functions/fnc_stringCompare.sqf index ad3073eb1e..b14eedb653 100644 --- a/addons/common/functions/fnc_stringCompare.sqf +++ b/addons/common/functions/fnc_stringCompare.sqf @@ -7,7 +7,10 @@ * 1: stringB * * Return Value: - * Number of matching characters >NUMBER> + * Number of matching characters + * + * Example: + * ["a", "b"] call ace_common_fnc_stringCompare * * Public: Yes */ diff --git a/addons/common/functions/fnc_stringToColoredText.sqf b/addons/common/functions/fnc_stringToColoredText.sqf index e6e19e4869..c072da9253 100644 --- a/addons/common/functions/fnc_stringToColoredText.sqf +++ b/addons/common/functions/fnc_stringToColoredText.sqf @@ -9,6 +9,9 @@ * Return Value: * Text * + * Example: + * ["text", [0, 1, 2]] call ace_common_fnc_stringToColoredText + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_switchToGroupSide.sqf b/addons/common/functions/fnc_switchToGroupSide.sqf index a375cfaf05..914c12034f 100644 --- a/addons/common/functions/fnc_switchToGroupSide.sqf +++ b/addons/common/functions/fnc_switchToGroupSide.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, true, "id", SIDE] call ace_common_fnc_switchToGroupSide + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_syncedEvent.sqf b/addons/common/functions/fnc_syncedEvent.sqf index 4a364bf730..a6a7fb30e3 100644 --- a/addons/common/functions/fnc_syncedEvent.sqf +++ b/addons/common/functions/fnc_syncedEvent.sqf @@ -10,6 +10,9 @@ * Return Value: * Boolean of success * + * Example: + * ["bob", [args], 5] call ace_common_fnc_syncedEvent + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_syncedEventPFH.sqf b/addons/common/functions/fnc_syncedEventPFH.sqf index 8fcd143536..c35be73d5c 100644 --- a/addons/common/functions/fnc_syncedEventPFH.sqf +++ b/addons/common/functions/fnc_syncedEventPFH.sqf @@ -1,5 +1,5 @@ /* - * Author: ? + * Author: ACE-Team * * ? * @@ -7,9 +7,12 @@ * ? * * Return Value: - * ? + * None * - * Public: ? + * Example: + * [?] call ace_common_fnc_syncedEventPFH + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_toBin.sqf b/addons/common/functions/fnc_toBin.sqf index f8ec0bac68..f3e08711a7 100644 --- a/addons/common/functions/fnc_toBin.sqf +++ b/addons/common/functions/fnc_toBin.sqf @@ -8,6 +8,9 @@ * Return Value: * A binary number as string * + * Example: + * [5] call ace_common_fnc_toBin + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_toBitmask.sqf b/addons/common/functions/fnc_toBitmask.sqf index 333e5c737b..ac5b7f056e 100644 --- a/addons/common/functions/fnc_toBitmask.sqf +++ b/addons/common/functions/fnc_toBitmask.sqf @@ -8,6 +8,9 @@ * Return Value: * Bitmask * + * Example: + * [[true, false]] call ace_common_fnc_toBitmask + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_toHex.sqf b/addons/common/functions/fnc_toHex.sqf index c558aab04b..2c82c1c4a3 100644 --- a/addons/common/functions/fnc_toHex.sqf +++ b/addons/common/functions/fnc_toHex.sqf @@ -8,6 +8,9 @@ * Return Value: * A hexadecimal number as string * + * Example: + * [154] call ace_common_fnc_toHex + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_toNumber.sqf b/addons/common/functions/fnc_toNumber.sqf index c375dfb02e..eeede0813b 100644 --- a/addons/common/functions/fnc_toNumber.sqf +++ b/addons/common/functions/fnc_toNumber.sqf @@ -6,7 +6,7 @@ * 0: Value to attempt to convert to number or if number simply return number. * * Return Value: - * + * Number * * Example: * number = ["102"] call ace_common_fnc_toNumber; diff --git a/addons/common/functions/fnc_translateToModelSpace.sqf b/addons/common/functions/fnc_translateToModelSpace.sqf index 309387086f..0d7a5551fc 100644 --- a/addons/common/functions/fnc_translateToModelSpace.sqf +++ b/addons/common/functions/fnc_translateToModelSpace.sqf @@ -1,14 +1,17 @@ /* - * Author: ? + * Author: ACE-Team * ? * * Arguments: - * ? + * * * Return Value: - * ? + * Something * - * Public: ? + * Example: + * [UNKNOWN] call ace_common_fnc_translateToModelSpace + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_translateToWeaponSpace.sqf b/addons/common/functions/fnc_translateToWeaponSpace.sqf index fab3fe6a3c..af3abddb74 100644 --- a/addons/common/functions/fnc_translateToWeaponSpace.sqf +++ b/addons/common/functions/fnc_translateToWeaponSpace.sqf @@ -1,14 +1,17 @@ /* - * Author: ? + * Author: ACE-Team * ? * * Arguments: - * ? + * * * Return Value: - * ? + * Unknown * - * Public: ? + * Example: + * [UNKOWN] call ace_common_fnc_translateToWeaponSpace + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_uniqueElements.sqf b/addons/common/functions/fnc_uniqueElements.sqf index 471ba47457..62a68a71ff 100644 --- a/addons/common/functions/fnc_uniqueElements.sqf +++ b/addons/common/functions/fnc_uniqueElements.sqf @@ -8,6 +8,9 @@ * Return Value: * Copy of original array * + * Example: + * [[array]] call ace_common_fnc_uniqueElements + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_unloadPersonLocal.sqf b/addons/common/functions/fnc_unloadPersonLocal.sqf index dbc28dc977..ed5b8dc020 100644 --- a/addons/common/functions/fnc_unloadPersonLocal.sqf +++ b/addons/common/functions/fnc_unloadPersonLocal.sqf @@ -10,6 +10,9 @@ * Return Value: * Returns true if succesfully unloaded person * + * Example: + * [bob, car, bob] call ace_common_fnc_unloadpersonLocal + * * Public: No */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_unmuteUnit.sqf b/addons/common/functions/fnc_unmuteUnit.sqf index b6d673cfd5..7d81ae7346 100644 --- a/addons/common/functions/fnc_unmuteUnit.sqf +++ b/addons/common/functions/fnc_unmuteUnit.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, "because"] call ace_common_fnc_unmuteUnit + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_useItem.sqf b/addons/common/functions/fnc_useItem.sqf index 2d2116b38f..3accecc429 100644 --- a/addons/common/functions/fnc_useItem.sqf +++ b/addons/common/functions/fnc_useItem.sqf @@ -9,6 +9,9 @@ * Return Value: * if item has been used. * + * Example: + * [bob, "gun"] call ace_common_fnc_useItem + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_useMagazine.sqf b/addons/common/functions/fnc_useMagazine.sqf index 4dc6136fa6..646d461d21 100644 --- a/addons/common/functions/fnc_useMagazine.sqf +++ b/addons/common/functions/fnc_useMagazine.sqf @@ -9,6 +9,9 @@ * Return Value: * if magazine has been used. * + * Example: + * [bob, "magazine"] call ace_common_fnc_useMagazine + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/common/functions/fnc_watchVariable.sqf b/addons/common/functions/fnc_watchVariable.sqf index 931450bd22..300a5ef195 100644 --- a/addons/common/functions/fnc_watchVariable.sqf +++ b/addons/common/functions/fnc_watchVariable.sqf @@ -14,7 +14,7 @@ * 0: Number of structured text lines (default: 1) * * Return Value: - * Nothing + * None * * Example: * ["CBA_missionTime"] call ace_common_fnc_watchVariable; // Uses title as code diff --git a/addons/common/functions/fnc_waveHeightAt.sqf b/addons/common/functions/fnc_waveHeightAt.sqf index c140b1ce94..1a9049b491 100644 --- a/addons/common/functions/fnc_waveHeightAt.sqf +++ b/addons/common/functions/fnc_waveHeightAt.sqf @@ -3,11 +3,13 @@ * Gets the wave height at a specific location. Uses a logic, so may be performance iffy * * Arguments: - * 0: Position ASL to get height at + * 0: Position ASL to get height at * * Return Value: - * Wave height in meters + * Wave height in meters * + * Example: + * [[5, 2, 5]]] call ace_common_fnc_waveHeightAt * * Public: No */ diff --git a/addons/common/functions/fnc_worldToScreenBounds.sqf b/addons/common/functions/fnc_worldToScreenBounds.sqf index 77df6e47bf..42ffa27317 100644 --- a/addons/common/functions/fnc_worldToScreenBounds.sqf +++ b/addons/common/functions/fnc_worldToScreenBounds.sqf @@ -19,6 +19,9 @@ * 2: Maximal X * 3: Maximal Y * + * Example: + * [bob, [5, 5, 5], [6, 6, 6]] call ace_common_fnc_worldToScreenBounds + * * Public: No */ #include "script_component.hpp" diff --git a/addons/concertina_wire/functions/fnc_deploy.sqf b/addons/concertina_wire/functions/fnc_deploy.sqf index 0e8bc07914..6dc05b365d 100644 --- a/addons/concertina_wire/functions/fnc_deploy.sqf +++ b/addons/concertina_wire/functions/fnc_deploy.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [coil, bob] call ace_concertina_wire_fnc_deploy + * * Public: No */ #include "script_component.hpp" diff --git a/addons/concertina_wire/functions/fnc_dismount.sqf b/addons/concertina_wire/functions/fnc_dismount.sqf index f2d3bc76c1..ef32431292 100644 --- a/addons/concertina_wire/functions/fnc_dismount.sqf +++ b/addons/concertina_wire/functions/fnc_dismount.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [wire, bob] call ace_concertina_wire_fnc_dismount + * * Public: No */ #include "script_component.hpp" diff --git a/addons/concertina_wire/functions/fnc_dismountSuccess.sqf b/addons/concertina_wire/functions/fnc_dismountSuccess.sqf index f8673b8829..d730fbb4b6 100644 --- a/addons/concertina_wire/functions/fnc_dismountSuccess.sqf +++ b/addons/concertina_wire/functions/fnc_dismountSuccess.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [wire] call ace_concertina_wire_fnc_dismountSuccess + * * Public: No */ #include "script_component.hpp" diff --git a/addons/concertina_wire/functions/fnc_handleDamage.sqf b/addons/concertina_wire/functions/fnc_handleDamage.sqf index 43a04641dd..d4f2555546 100644 --- a/addons/concertina_wire/functions/fnc_handleDamage.sqf +++ b/addons/concertina_wire/functions/fnc_handleDamage.sqf @@ -13,6 +13,9 @@ * Return Value: * None * + * Example: + * [wire, "selection", 5, source, "scrap"] call ace_concertina_wire_fnc_handleDamage + * * Public: No */ #include "script_component.hpp" diff --git a/addons/concertina_wire/functions/fnc_handleKilled.sqf b/addons/concertina_wire/functions/fnc_handleKilled.sqf index 7fb5ef6e1b..6649f5c3b6 100644 --- a/addons/concertina_wire/functions/fnc_handleKilled.sqf +++ b/addons/concertina_wire/functions/fnc_handleKilled.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [wire, car] call ace_concertina_wire_fnc_handleKilled + * * Public: No */ #include "script_component.hpp" diff --git a/addons/concertina_wire/functions/fnc_vehicleDamage.sqf b/addons/concertina_wire/functions/fnc_vehicleDamage.sqf index e5732f7000..7d84d4b244 100644 --- a/addons/concertina_wire/functions/fnc_vehicleDamage.sqf +++ b/addons/concertina_wire/functions/fnc_vehicleDamage.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [wire, car] call ace_concertina_wire_fnc_vehicleDamage + * * Public: No */ #include "script_component.hpp" diff --git a/addons/cookoff/functions/fnc_handleDamage.sqf b/addons/cookoff/functions/fnc_handleDamage.sqf index 331c1d177a..f462cbf56c 100644 --- a/addons/cookoff/functions/fnc_handleDamage.sqf +++ b/addons/cookoff/functions/fnc_handleDamage.sqf @@ -3,10 +3,10 @@ * Handles all incoming damage for tanks (including wheeled APCs). * * Arguments: - * HandleDamage EH + * HandleDamage EH * * Return Value: - * Damage to be inflicted. + * Damage to be inflicted. * * Example: * _this call ace_cookoff_fnc_handleDamage diff --git a/addons/dagr/functions/fnc_handleRangeFinderData.sqf b/addons/dagr/functions/fnc_handleRangeFinderData.sqf index 59e10a1711..61d8201552 100644 --- a/addons/dagr/functions/fnc_handleRangeFinderData.sqf +++ b/addons/dagr/functions/fnc_handleRangeFinderData.sqf @@ -8,7 +8,7 @@ * 2: Inclination (Degrees) * * Return Value: - * Nothing + * None * * Example: * [1000, 45, 1] call ace_dagr_fnc_handleRangeFinderData diff --git a/addons/dagr/functions/fnc_menuInit.sqf b/addons/dagr/functions/fnc_menuInit.sqf index c4aa989854..b061717c58 100644 --- a/addons/dagr/functions/fnc_menuInit.sqf +++ b/addons/dagr/functions/fnc_menuInit.sqf @@ -3,10 +3,10 @@ * Creates the DAGR menu dialog * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * diff --git a/addons/dagr/functions/fnc_outputData.sqf b/addons/dagr/functions/fnc_outputData.sqf index 0fcc3ccbda..2208587932 100644 --- a/addons/dagr/functions/fnc_outputData.sqf +++ b/addons/dagr/functions/fnc_outputData.sqf @@ -3,12 +3,13 @@ * DAGR data output loop * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: + * call ace_dagr_fnc_outputData * * Public: No */ diff --git a/addons/dagr/functions/fnc_outputVector.sqf b/addons/dagr/functions/fnc_outputVector.sqf index 23996c46b4..686dbcc407 100644 --- a/addons/dagr/functions/fnc_outputVector.sqf +++ b/addons/dagr/functions/fnc_outputVector.sqf @@ -1,17 +1,19 @@ -/* +/* * Author: Rosuto * DAGR vector output loop * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: + * call ace_dagr_fnc_outputVector * * Public: No */ + #include "script_component.hpp" private ["_xGrid", "_yGrid", "_dagrGrid", "_bearing", "_dagrDist", "_dagrElevation", "_dagrTime", "_elevation", "_xCoord", "_yCoord"]; diff --git a/addons/dagr/functions/fnc_outputWP.sqf b/addons/dagr/functions/fnc_outputWP.sqf index 2a877ba593..32e1c2eaa0 100644 --- a/addons/dagr/functions/fnc_outputWP.sqf +++ b/addons/dagr/functions/fnc_outputWP.sqf @@ -1,14 +1,15 @@ -/* +/* * Author: Rosuto * DAGR waypoint output loop * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: + * call ace_dagr_fnc_outputWP * * Public: No */ diff --git a/addons/dagr/functions/fnc_toggleOverlay.sqf b/addons/dagr/functions/fnc_toggleOverlay.sqf index d48a83ae51..af9909efda 100644 --- a/addons/dagr/functions/fnc_toggleOverlay.sqf +++ b/addons/dagr/functions/fnc_toggleOverlay.sqf @@ -3,12 +3,13 @@ * Toggles the DAGR overlay * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: + * call ace_dagr_fnc_toggleOverlay * * Public: No */ diff --git a/addons/disarming/functions/fnc_disarmDropItems.sqf b/addons/disarming/functions/fnc_disarmDropItems.sqf index c9eb920084..af799e25df 100644 --- a/addons/disarming/functions/fnc_disarmDropItems.sqf +++ b/addons/disarming/functions/fnc_disarmDropItems.sqf @@ -10,7 +10,7 @@ * 3: Do Not Drop Ammo * * Return Value: - * Nothing + * None * * Example: * [player, cursorTarget, ["ace_bandage"]] call ace_disarming_fnc_disarmDropItems diff --git a/addons/disarming/functions/fnc_eventTargetFinish.sqf b/addons/disarming/functions/fnc_eventTargetFinish.sqf index d71d93d254..f700cb6f79 100644 --- a/addons/disarming/functions/fnc_eventTargetFinish.sqf +++ b/addons/disarming/functions/fnc_eventTargetFinish.sqf @@ -10,7 +10,7 @@ * 2: errorMsg * * Return Value: - * Nothing + * None * * Example: * [player1, player2, "Someting fucked up"] call ace_disarming_fnc_eventTargetFinish diff --git a/addons/disarming/functions/fnc_eventTargetStart.sqf b/addons/disarming/functions/fnc_eventTargetStart.sqf index 77dfd9d271..8490c17be1 100644 --- a/addons/disarming/functions/fnc_eventTargetStart.sqf +++ b/addons/disarming/functions/fnc_eventTargetStart.sqf @@ -10,10 +10,10 @@ * 2: type of disarm * * Return Value: - * Nothing + * None * * Example: - * eventTargetStart + * [bob, kevin, "disarm"] call ace_disarming_fnc_eventTargetStart * * Public: No */ diff --git a/addons/disarming/functions/fnc_showItemsInListbox.sqf b/addons/disarming/functions/fnc_showItemsInListbox.sqf index 82b9645850..d43dd9b5ca 100644 --- a/addons/disarming/functions/fnc_showItemsInListbox.sqf +++ b/addons/disarming/functions/fnc_showItemsInListbox.sqf @@ -8,7 +8,7 @@ * 1: ItemArray [["itemClassnames"],[counts]] * * Return Value: - * Nothing + * None * * Example: * [theListBox, [["ace_bandage"],[2]]] call ace_disarming_fnc_showItemsInListbox diff --git a/addons/disposable/functions/fnc_replaceATWeapon.sqf b/addons/disposable/functions/fnc_replaceATWeapon.sqf index 58c58a6056..d94944bfde 100644 --- a/addons/disposable/functions/fnc_replaceATWeapon.sqf +++ b/addons/disposable/functions/fnc_replaceATWeapon.sqf @@ -6,7 +6,7 @@ * None. Parameters inherited from EFUNC(common,firedEH) * * Return Value: - * Nothing + * None * * Example: * [fromBisFiredEH] call ace_disposable_fnc_replaceATWeapon; diff --git a/addons/dragging/functions/fnc_isObjectOnObject.sqf b/addons/dragging/functions/fnc_isObjectOnObject.sqf index cec6ce764e..00c2823e4a 100644 --- a/addons/dragging/functions/fnc_isObjectOnObject.sqf +++ b/addons/dragging/functions/fnc_isObjectOnObject.sqf @@ -6,9 +6,9 @@ * 0: Object * * Return Value: - * + * Boolean * - * Example; + * Example: * [player] call ace_dragging_fnc_isObjectOnObject * * Public: No diff --git a/addons/dragging/functions/fnc_setDraggable.sqf b/addons/dragging/functions/fnc_setDraggable.sqf index 3636847d06..ce47f8a829 100644 --- a/addons/dragging/functions/fnc_setDraggable.sqf +++ b/addons/dragging/functions/fnc_setDraggable.sqf @@ -5,8 +5,8 @@ * Arguments: * 0: Any object * 1: true to enable dragging, false to disable - * 2: Position offset for attachTo command (Array, optinal; default: [0,0,0]) - * 3: Direction in degree to rotate the object after attachTo (Number, optional; default: 0) + * 2: Position offset for attachTo command (optinal; default: [0,0,0]) + * 3: Direction in degree to rotate the object after attachTo (optional; default: 0) * * Return Value: * None diff --git a/addons/explosives/functions/fnc_addExplosiveActions.sqf b/addons/explosives/functions/fnc_addExplosiveActions.sqf index 0ee3ca9f78..888583b60c 100644 --- a/addons/explosives/functions/fnc_addExplosiveActions.sqf +++ b/addons/explosives/functions/fnc_addExplosiveActions.sqf @@ -6,7 +6,10 @@ * 0: Unit * * Return Value: - * Actions + * Actions + * + * Example: + * [bob] call ace_explosives_fnc_addExplosiveActions * * Public: No */ diff --git a/addons/explosives/functions/fnc_addTransmitterActions.sqf b/addons/explosives/functions/fnc_addTransmitterActions.sqf index 4397e743a0..418d99a0df 100644 --- a/addons/explosives/functions/fnc_addTransmitterActions.sqf +++ b/addons/explosives/functions/fnc_addTransmitterActions.sqf @@ -6,7 +6,7 @@ * 0: Unit * * Return Value: - * Nothing + * None * * Example: * [player] call ACE_Explosives_fnc_addTransmitterActions; diff --git a/addons/explosives/functions/fnc_interactEH.sqf b/addons/explosives/functions/fnc_interactEH.sqf index c8486adc09..a2da62e6b9 100644 --- a/addons/explosives/functions/fnc_interactEH.sqf +++ b/addons/explosives/functions/fnc_interactEH.sqf @@ -7,7 +7,7 @@ * Interact Menu Type (0 - world, 1 - self) * * Return Value: - * Nothing + * None * * Example: * [0] call ace_explosives_fnc_interactEH diff --git a/addons/explosives/functions/fnc_startDefuse.sqf b/addons/explosives/functions/fnc_startDefuse.sqf index 95e258696c..375f1562e1 100644 --- a/addons/explosives/functions/fnc_startDefuse.sqf +++ b/addons/explosives/functions/fnc_startDefuse.sqf @@ -7,7 +7,7 @@ * 1: Target explosive * * Return Value: - * Nothing + * None * * Example: * [player, ACE_Interaction_Target] call ACE_Explosives_fnc_StartDefuse; diff --git a/addons/fastroping/functions/fnc_deployAIWaypoint.sqf b/addons/fastroping/functions/fnc_deployAIWaypoint.sqf index 9d8f4a03e2..df8cdef0c1 100644 --- a/addons/fastroping/functions/fnc_deployAIWaypoint.sqf +++ b/addons/fastroping/functions/fnc_deployAIWaypoint.sqf @@ -7,7 +7,7 @@ * 1: Waypoint position * * Return Value: - * true + * true * * Example: * [_group, [6560, 12390, 0]] call ace_fastroping_fnc_deployAIWayoint diff --git a/addons/fastroping/functions/fnc_onRopeBreak.sqf b/addons/fastroping/functions/fnc_onRopeBreak.sqf index ed5f8bf1c8..29da355481 100644 --- a/addons/fastroping/functions/fnc_onRopeBreak.sqf +++ b/addons/fastroping/functions/fnc_onRopeBreak.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [[array]], "top"] call ace_fastroping_fnc_onRopeBreak + * * Public: No */ diff --git a/addons/fcs/functions/fnc_adjustRange.sqf b/addons/fcs/functions/fnc_adjustRange.sqf index bed9389716..0f400a50fb 100644 --- a/addons/fcs/functions/fnc_adjustRange.sqf +++ b/addons/fcs/functions/fnc_adjustRange.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, [], 5] call ace_fcs_fnc_adjustRange + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_calculateSolution.sqf b/addons/fcs/functions/fnc_calculateSolution.sqf index 41cbfa5069..f28a1c7048 100644 --- a/addons/fcs/functions/fnc_calculateSolution.sqf +++ b/addons/fcs/functions/fnc_calculateSolution.sqf @@ -3,14 +3,17 @@ * Calculate FCS solution * * Arguments: - * 0: Vehicle - * 1: Turret - * 2: Target distance - * 3: Azimuth offset + * 0: Vehicle + * 1: Turret + * 2: Target distance + * 3: Azimuth offset * * Return Value: * None * + * Example: + * [car, [turret], 5, ?] call ace_fcs_fnc_calculateSolution + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_canResetFCS.sqf b/addons/fcs/functions/fnc_canResetFCS.sqf index cf0dcf2674..8713357f3d 100644 --- a/addons/fcs/functions/fnc_canResetFCS.sqf +++ b/addons/fcs/functions/fnc_canResetFCS.sqf @@ -3,11 +3,14 @@ * Called from config. Can player reset FCS? * * Arguments: - * Nothing + * None * * Return Value: * Boolean * + * Example: + * call ace_fcs_fnc_canResetFCS + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_canUseRangefinder.sqf b/addons/fcs/functions/fnc_canUseRangefinder.sqf index 7403c74ac1..a8b8239097 100644 --- a/addons/fcs/functions/fnc_canUseRangefinder.sqf +++ b/addons/fcs/functions/fnc_canUseRangefinder.sqf @@ -8,6 +8,9 @@ * Return Value: * Boolean * + * Example: + * call ace_fcs_fnc_canUseRangeFinder + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_firedEH.sqf b/addons/fcs/functions/fnc_firedEH.sqf index dbfebae025..097722c958 100644 --- a/addons/fcs/functions/fnc_firedEH.sqf +++ b/addons/fcs/functions/fnc_firedEH.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_fcs_fnc_firedEH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_getAngle.sqf b/addons/fcs/functions/fnc_getAngle.sqf index d2c51a9542..d9e14a343b 100644 --- a/addons/fcs/functions/fnc_getAngle.sqf +++ b/addons/fcs/functions/fnc_getAngle.sqf @@ -14,6 +14,9 @@ * Return Value: * offset from the current angle necessary to hit the target * + * Example: + * [1, 2, 3, 4, 5, 6, 7] call ace_fcs_fnc_getAngle + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_getRange.sqf b/addons/fcs/functions/fnc_getRange.sqf index ba49621047..829e4c9072 100644 --- a/addons/fcs/functions/fnc_getRange.sqf +++ b/addons/fcs/functions/fnc_getRange.sqf @@ -11,6 +11,9 @@ * Return Value: * Measured distance * + * Example: + * [5, 6, 7, true] call ace_fcs_fnc_getRange + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_handleAirBurstAmmunitionPFH.sqf b/addons/fcs/functions/fnc_handleAirBurstAmmunitionPFH.sqf index aa166ece12..4c1c210994 100644 --- a/addons/fcs/functions/fnc_handleAirBurstAmmunitionPFH.sqf +++ b/addons/fcs/functions/fnc_handleAirBurstAmmunitionPFH.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [[array]] call ace_fcs_fnc_handleAirBurstAummunitionPFH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_keyDown.sqf b/addons/fcs/functions/fnc_keyDown.sqf index 3c4943badf..01795ce280 100644 --- a/addons/fcs/functions/fnc_keyDown.sqf +++ b/addons/fcs/functions/fnc_keyDown.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [car, [turret]] call ace_fcs_fnc_keyDown + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_keyUp.sqf b/addons/fcs/functions/fnc_keyUp.sqf index a07f5d5d35..d35174a198 100644 --- a/addons/fcs/functions/fnc_keyUp.sqf +++ b/addons/fcs/functions/fnc_keyUp.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [car, [turret]] call ace_fcs_fnc_keyUp + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_onForceUpdate.sqf b/addons/fcs/functions/fnc_onForceUpdate.sqf index 2c6d136300..1bbaee5b58 100644 --- a/addons/fcs/functions/fnc_onForceUpdate.sqf +++ b/addons/fcs/functions/fnc_onForceUpdate.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * Nothing + * + * Return Value: + * None + * + * Example: + * call ace_fcs_fnc_onForceUpdate + * + * Public: No + */ + #include "script_component.hpp" params ["_unit"]; diff --git a/addons/fcs/functions/fnc_reset.sqf b/addons/fcs/functions/fnc_reset.sqf index dcb1718b3f..9d4a5f65a0 100644 --- a/addons/fcs/functions/fnc_reset.sqf +++ b/addons/fcs/functions/fnc_reset.sqf @@ -7,7 +7,10 @@ * 1: Turret * * Return Value: - * none + * None + * + * Example: + * [car, [turret]] call ace_fcs_fnc_reset * * Public: No */ diff --git a/addons/fcs/functions/fnc_updateRangeHUD.sqf b/addons/fcs/functions/fnc_updateRangeHUD.sqf index 0bb15b2507..2e415b3f49 100644 --- a/addons/fcs/functions/fnc_updateRangeHUD.sqf +++ b/addons/fcs/functions/fnc_updateRangeHUD.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_fcs_fnc_updateRangeHUD + * * Public: No */ #include "script_component.hpp" diff --git a/addons/fcs/functions/fnc_vehicleInit.sqf b/addons/fcs/functions/fnc_vehicleInit.sqf index 901e0477ab..47b8359b2b 100644 --- a/addons/fcs/functions/fnc_vehicleInit.sqf +++ b/addons/fcs/functions/fnc_vehicleInit.sqf @@ -3,10 +3,13 @@ * Checks if a vehicle is equipped with an FCS and if so, adds the fired event handler. Execute on server. * * Arguments: - * 0: Vehicle + * 0: Vehicle * * Return Value: - * none + * None + * + * Example: + * [car] call ace_fcs_fnc_vehicleInit * * Public: No */ diff --git a/addons/finger/functions/fnc_moduleSettings.sqf b/addons/finger/functions/fnc_moduleSettings.sqf index c5189f4562..4667e76c51 100644 --- a/addons/finger/functions/fnc_moduleSettings.sqf +++ b/addons/finger/functions/fnc_moduleSettings.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [logic] call ace_finger_fnc_moduleSettings + * * Public: No */ diff --git a/addons/frag/functions/fnc_addBlackList.sqf b/addons/frag/functions/fnc_addBlackList.sqf index 79cb41adab..cfa96c9784 100644 --- a/addons/frag/functions/fnc_addBlackList.sqf +++ b/addons/frag/functions/fnc_addBlackList.sqf @@ -6,7 +6,7 @@ * 0: Projectile * * Return Value: - * Nothing + * None * * Example: * [bullet] call ace_frag_fnc_addBlackList diff --git a/addons/frag/functions/fnc_addPfhRound.sqf b/addons/frag/functions/fnc_addPfhRound.sqf index 7c609f2146..f97d868b9d 100644 --- a/addons/frag/functions/fnc_addPfhRound.sqf +++ b/addons/frag/functions/fnc_addPfhRound.sqf @@ -9,7 +9,7 @@ * 2: Projectile * * Return Value: - * Nothing + * None * * Example: * [player, "handGrenade", bullet] call ace_frag_fnc_addPfhRound diff --git a/addons/frag/functions/fnc_dev_addTrack.sqf b/addons/frag/functions/fnc_dev_addTrack.sqf index 764627b60f..fd180eacfe 100644 --- a/addons/frag/functions/fnc_dev_addTrack.sqf +++ b/addons/frag/functions/fnc_dev_addTrack.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_addTack + * + * Public: No + */ + #include "script_component.hpp" params ["_origin", "_obj", ["_color", [1, 0, 0, 1]]]; diff --git a/addons/frag/functions/fnc_dev_debugAmmo.sqf b/addons/frag/functions/fnc_dev_debugAmmo.sqf index 894c532728..8eec5f04f5 100644 --- a/addons/frag/functions/fnc_dev_debugAmmo.sqf +++ b/addons/frag/functions/fnc_dev_debugAmmo.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_debugAmmo + * + * Public: No + */ + #define DEBUG_MODE_FULL #include "script_component.hpp" diff --git a/addons/frag/functions/fnc_dev_drawTraces.sqf b/addons/frag/functions/fnc_dev_drawTraces.sqf index c6ab838e84..f7d36b4f02 100644 --- a/addons/frag/functions/fnc_dev_drawTraces.sqf +++ b/addons/frag/functions/fnc_dev_drawTraces.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_drawTraces + * + * Public: No + */ + #include "script_component.hpp" { diff --git a/addons/frag/functions/fnc_dev_startTracing.sqf b/addons/frag/functions/fnc_dev_startTracing.sqf index b58a491896..e58445ec83 100644 --- a/addons/frag/functions/fnc_dev_startTracing.sqf +++ b/addons/frag/functions/fnc_dev_startTracing.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_dev_startTracing + * + * Public: No + */ + #include "script_component.hpp" if (GVAR(tracesStarted)) exitWith {}; diff --git a/addons/frag/functions/fnc_dev_stopTracing.sqf b/addons/frag/functions/fnc_dev_stopTracing.sqf index c25021bb4e..f3b8fa234b 100644 --- a/addons/frag/functions/fnc_dev_stopTracing.sqf +++ b/addons/frag/functions/fnc_dev_stopTracing.sqf @@ -1,3 +1,18 @@ +/* + * Author: ACE-Team + * Dev things + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * + * Public: No + */ + #include "script_component.hpp" if (!GVAR(tracesStarted)) exitWith {}; diff --git a/addons/frag/functions/fnc_dev_trackTrace.sqf b/addons/frag/functions/fnc_dev_trackTrace.sqf index 07867ba1ff..b71f1982ff 100644 --- a/addons/frag/functions/fnc_dev_trackTrace.sqf +++ b/addons/frag/functions/fnc_dev_trackTrace.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * Dev things + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_dev_trackTrace + * + * Public: No + */ + #include "script_component.hpp" params ["_args", "_pfhID"]; diff --git a/addons/frag/functions/fnc_doExplosions.sqf b/addons/frag/functions/fnc_doExplosions.sqf index 85074bdb13..25302cca7c 100644 --- a/addons/frag/functions/fnc_doExplosions.sqf +++ b/addons/frag/functions/fnc_doExplosions.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_doExplosions + * + * Public: No + */ + //fnc_doExplosions.sqf #include "script_component.hpp" diff --git a/addons/frag/functions/fnc_doReflections.sqf b/addons/frag/functions/fnc_doReflections.sqf index b4bec189f7..622c4c57f4 100644 --- a/addons/frag/functions/fnc_doReflections.sqf +++ b/addons/frag/functions/fnc_doReflections.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * Dev things + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_doReflections + * + * Public: No + */ + //fnc_doReflections.sqf #include "script_component.hpp" diff --git a/addons/frag/functions/fnc_doSpall.sqf b/addons/frag/functions/fnc_doSpall.sqf index ee1bc37384..dcc1759648 100644 --- a/addons/frag/functions/fnc_doSpall.sqf +++ b/addons/frag/functions/fnc_doSpall.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * Dev things + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_doSpall + * + * Public: No + */ + //fnc_doSpall.sqf #include "script_component.hpp" // ACE_player sideChat "WAAAAAAAAAAAAAAAAAAAAA"; diff --git a/addons/frag/functions/fnc_findReflections.sqf b/addons/frag/functions/fnc_findReflections.sqf index dbde4d7a98..774e1764ea 100644 --- a/addons/frag/functions/fnc_findReflections.sqf +++ b/addons/frag/functions/fnc_findReflections.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_findReflections + * + * Public: No + */ + //fnc_findReflections.sqf #include "script_component.hpp" @@ -78,7 +94,7 @@ if (_zIndex < 5) then { private _avg = [0, 0, 0]; { - _avg = _avg vectorAdd _x; + _avg = _avg vectorAdd _x; } forEach _blist; _c = count _blist; private _bpos = _avg vectorMultiply (1 / _c); diff --git a/addons/frag/functions/fnc_fired.sqf b/addons/frag/functions/fnc_fired.sqf index 42885d55b0..b1e29a79ca 100644 --- a/addons/frag/functions/fnc_fired.sqf +++ b/addons/frag/functions/fnc_fired.sqf @@ -7,7 +7,7 @@ * None. Parameters inherited from EFUNC(common,firedEH) * * Return Value: - * Nothing + * None * * Example: * [clientFiredBIS-XEH] call ace_frag_fnc_fired @@ -58,6 +58,6 @@ if (_shouldAdd) then { // Skip if less than 0.5 second from last shot if ((CBA_missionTime - (_unit getVariable [QGVAR(lastTrack), -1])) < 0.5) exitWith {}; _unit setVariable [QGVAR(lastTrack), CBA_missionTime]; - + [_unit, _ammo, _projectile] call FUNC(addPfhRound); }; diff --git a/addons/frag/functions/fnc_frago.sqf b/addons/frag/functions/fnc_frago.sqf index 49f1a62237..a21e92d4b3 100644 --- a/addons/frag/functions/fnc_frago.sqf +++ b/addons/frag/functions/fnc_frago.sqf @@ -8,7 +8,7 @@ * 2: Ammo Classname * * Return Value: - * Nothing + * None * * Example: * [[], [], "handGrenade"] call ace_frag_fnc_frago diff --git a/addons/frag/functions/fnc_masterPFH.sqf b/addons/frag/functions/fnc_masterPFH.sqf index 10b7743102..638a91ee63 100644 --- a/addons/frag/functions/fnc_masterPFH.sqf +++ b/addons/frag/functions/fnc_masterPFH.sqf @@ -7,7 +7,13 @@ * * Return Value: * None + * + * Example: + * call ace_frag_fnc_masterPFH + * + * Public: No */ + //#define DEBUG_MODE_FULL #include "script_component.hpp" diff --git a/addons/frag/functions/fnc_pfhRound.sqf b/addons/frag/functions/fnc_pfhRound.sqf index 3c72a525c9..9d63df3f2a 100644 --- a/addons/frag/functions/fnc_pfhRound.sqf +++ b/addons/frag/functions/fnc_pfhRound.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_pfhRound + * + * Public: No + */ + #include "script_component.hpp" params ["_round", "_lastPos", "_lastVel", "_shellType", "_firedFrame", "_gun", "_doSpall", "_spallTrack", "_foundObjectHPIds", "_skip", "_explosive", "_indirectRange", "_force", "_fragPower"]; diff --git a/addons/frag/functions/fnc_spallHP.sqf b/addons/frag/functions/fnc_spallHP.sqf index 085e037e70..643f5aefe4 100644 --- a/addons/frag/functions/fnc_spallHP.sqf +++ b/addons/frag/functions/fnc_spallHP.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_spallHP + * + * Public: No + */ + #include "script_component.hpp" //player sideChat format ["f: %1 c: %2", (_this select 0), (count GVAR(spallHPData))]; diff --git a/addons/frag/functions/fnc_spallTrack.sqf b/addons/frag/functions/fnc_spallTrack.sqf index aedcf56cf8..ee928b35c0 100644 --- a/addons/frag/functions/fnc_spallTrack.sqf +++ b/addons/frag/functions/fnc_spallTrack.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_frag_fnc_spallTrack + * + * Public: No + */ + //fnc_spallTrack.sqf #include "script_component.hpp" diff --git a/addons/gestures/functions/fnc_playSignal.sqf b/addons/gestures/functions/fnc_playSignal.sqf index 273db82da1..9dc1ecce4b 100644 --- a/addons/gestures/functions/fnc_playSignal.sqf +++ b/addons/gestures/functions/fnc_playSignal.sqf @@ -6,7 +6,7 @@ * Animation * * Return Value: - * + * Boolean * * Example: * "GeniusAnimation" call ace_gestures_fnc_playSignal diff --git a/addons/gforces/functions/fnc_addPFEH.sqf b/addons/gforces/functions/fnc_addPFEH.sqf index bf320e0fe5..2464575fdc 100644 --- a/addons/gforces/functions/fnc_addPFEH.sqf +++ b/addons/gforces/functions/fnc_addPFEH.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_gforces_fnc_addPFEH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/gforces/functions/fnc_pfhUpdateGForces.sqf b/addons/gforces/functions/fnc_pfhUpdateGForces.sqf index f4f7c4becd..98e633f500 100644 --- a/addons/gforces/functions/fnc_pfhUpdateGForces.sqf +++ b/addons/gforces/functions/fnc_pfhUpdateGForces.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [[args], 5] call ace_gforces_fnc_pfhUpdateGForces + * * Public: No */ #include "script_component.hpp" diff --git a/addons/goggles/functions/fnc_handleExplosion.sqf b/addons/goggles/functions/fnc_handleExplosion.sqf index 44be6ab6c1..fcda2a3e49 100644 --- a/addons/goggles/functions/fnc_handleExplosion.sqf +++ b/addons/goggles/functions/fnc_handleExplosion.sqf @@ -8,6 +8,9 @@ * Return Value: * Function is handled? * + * Example: + * [bob] call ace_goggles_fnc_handleExplosion + * * Public: No */ #include "script_component.hpp" diff --git a/addons/goggles/functions/fnc_handleFired.sqf b/addons/goggles/functions/fnc_handleFired.sqf index 066bc040f7..e231a4562b 100644 --- a/addons/goggles/functions/fnc_handleFired.sqf +++ b/addons/goggles/functions/fnc_handleFired.sqf @@ -8,6 +8,9 @@ * Return Value: * Function is handled? * + * Example: + * call ace_goggles_fnc_handleFired + * * Public: No */ #include "script_component.hpp" diff --git a/addons/goggles/functions/fnc_handleKilled.sqf b/addons/goggles/functions/fnc_handleKilled.sqf index b9af2e075b..001a4041b8 100644 --- a/addons/goggles/functions/fnc_handleKilled.sqf +++ b/addons/goggles/functions/fnc_handleKilled.sqf @@ -8,6 +8,9 @@ * Return Value: * Function is handled? * + * Example: + * [bob] call ace_goggles_fnc_handleKilled + * * Public: No */ #include "script_component.hpp" diff --git a/addons/goggles/functions/fnc_isInRotorWash.sqf b/addons/goggles/functions/fnc_isInRotorWash.sqf index 319da3a875..80e1bdd8e8 100644 --- a/addons/goggles/functions/fnc_isInRotorWash.sqf +++ b/addons/goggles/functions/fnc_isInRotorWash.sqf @@ -7,7 +7,7 @@ * 1: Radius to check for helicopter (default: 15) * * Return Value: - * : + * Array : * 0: In rotorwash * 1: Amount of rotor wash. * diff --git a/addons/gunbag/functions/fnc_canInteract.sqf b/addons/gunbag/functions/fnc_canInteract.sqf index 1ec9e38583..556ea1f700 100644 --- a/addons/gunbag/functions/fnc_canInteract.sqf +++ b/addons/gunbag/functions/fnc_canInteract.sqf @@ -7,7 +7,7 @@ * 1: Target * * Return Value: - * -1: can't interact 0: empty gunbag 1: full gunbag + * -1: can't interact 0: empty gunbag 1: full gunbag * * Example: * _canInteract = [player, target] call ace_gunbag_fnc_canInteract diff --git a/addons/hearing/functions/fnc_handleRespawn.sqf b/addons/hearing/functions/fnc_handleRespawn.sqf index 5bad68761c..58500f1c3d 100644 --- a/addons/hearing/functions/fnc_handleRespawn.sqf +++ b/addons/hearing/functions/fnc_handleRespawn.sqf @@ -6,7 +6,7 @@ * 0: Unit * * Return Value: - * Nothing + * None * * Example: * [player] call ACE_hearing_fnc_handleRespawn; diff --git a/addons/hearing/functions/fnc_hasEarPlugsIn.sqf b/addons/hearing/functions/fnc_hasEarPlugsIn.sqf index 67a76685f4..ce697ab295 100644 --- a/addons/hearing/functions/fnc_hasEarPlugsIn.sqf +++ b/addons/hearing/functions/fnc_hasEarPlugsIn.sqf @@ -3,7 +3,7 @@ * Check if the unit has earplugs put in. * * Arguments: - * 0:Unit (player) + * 0: Unit (player) * * Return Value: * Have Earplugs in diff --git a/addons/hearing/functions/fnc_moduleHearing.sqf b/addons/hearing/functions/fnc_moduleHearing.sqf index 35276c60f8..8c04d9b8a4 100644 --- a/addons/hearing/functions/fnc_moduleHearing.sqf +++ b/addons/hearing/functions/fnc_moduleHearing.sqf @@ -3,10 +3,15 @@ * Initializes the Hearing module. * * Arguments: - * Whatever the module provides. (I dunno.) + * Whatever the module provides. (I dunno.) * * Return Value: * None + * + * Example: + * [player] call ACE_hearing_fnc_moduleHearing + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/hearing/functions/fnc_putInEarplugs.sqf b/addons/hearing/functions/fnc_putInEarplugs.sqf index 4075a982db..4471ec1aba 100644 --- a/addons/hearing/functions/fnc_putInEarplugs.sqf +++ b/addons/hearing/functions/fnc_putInEarplugs.sqf @@ -3,7 +3,7 @@ * Puts in earplugs. * * Arguments: - * 0:Unit (player) + * 0: Unit (player) * * Return Value: * None diff --git a/addons/hearing/functions/fnc_removeEarplugs.sqf b/addons/hearing/functions/fnc_removeEarplugs.sqf index 20bc7b8dcc..a46febefb2 100644 --- a/addons/hearing/functions/fnc_removeEarplugs.sqf +++ b/addons/hearing/functions/fnc_removeEarplugs.sqf @@ -3,7 +3,7 @@ * Takes out earplugs. * * Arguments: - * 0:Unit (player) + * 0: Unit (player) * * Return Value: * None diff --git a/addons/hitreactions/functions/fnc_fallDown.sqf b/addons/hitreactions/functions/fnc_fallDown.sqf index 915e442b37..a7814b914e 100644 --- a/addons/hitreactions/functions/fnc_fallDown.sqf +++ b/addons/hitreactions/functions/fnc_fallDown.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [player, kevin, 5] call ACE_hitreactions_fnc_fallDown + * * Public: No */ #include "script_component.hpp" diff --git a/addons/hitreactions/functions/fnc_getRandomAnimation.sqf b/addons/hitreactions/functions/fnc_getRandomAnimation.sqf index 996901a31e..10b64b5eae 100644 --- a/addons/hitreactions/functions/fnc_getRandomAnimation.sqf +++ b/addons/hitreactions/functions/fnc_getRandomAnimation.sqf @@ -8,6 +8,9 @@ * Return Value: * Fall animation * + * Example: + * [bob] call ACE_hitreactions_fnc_getRandomAnimation + * * Public: No */ #include "script_component.hpp" diff --git a/addons/huntir/functions/fnc_cam.sqf b/addons/huntir/functions/fnc_cam.sqf index 41a9561e60..4c9ba71745 100644 --- a/addons/huntir/functions/fnc_cam.sqf +++ b/addons/huntir/functions/fnc_cam.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [cam] call ACE_huntir_fnc_cam + * * Public: No */ #include "script_component.hpp" diff --git a/addons/huntir/functions/fnc_handleFired.sqf b/addons/huntir/functions/fnc_handleFired.sqf index b7e8c2a010..50ed4713aa 100644 --- a/addons/huntir/functions/fnc_handleFired.sqf +++ b/addons/huntir/functions/fnc_handleFired.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * call ACE_huntir_fnc_handleFired + * * Public: No */ #include "script_component.hpp" diff --git a/addons/huntir/functions/fnc_huntir.sqf b/addons/huntir/functions/fnc_huntir.sqf index 844ca302e7..f692da749b 100644 --- a/addons/huntir/functions/fnc_huntir.sqf +++ b/addons/huntir/functions/fnc_huntir.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * call ACE_huntir_fnc_huntir + * * Public: No */ #include "script_component.hpp" diff --git a/addons/huntir/functions/fnc_huntirCompass.sqf b/addons/huntir/functions/fnc_huntirCompass.sqf index f383a23a24..662dd621a3 100644 --- a/addons/huntir/functions/fnc_huntirCompass.sqf +++ b/addons/huntir/functions/fnc_huntirCompass.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * call ACE_huntir_fnc_huntirCompass + * * Public: No */ #include "script_component.hpp" diff --git a/addons/huntir/functions/fnc_keyPressed.sqf b/addons/huntir/functions/fnc_keyPressed.sqf index 509dcb9de5..82764ffd05 100644 --- a/addons/huntir/functions/fnc_keyPressed.sqf +++ b/addons/huntir/functions/fnc_keyPressed.sqf @@ -3,7 +3,7 @@ * Handles the HuntIR monitor key interaction * * Arguments: - * 0: ? + * 0: ? * 1: keycode * * Return Value: diff --git a/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf b/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf index ae066576f7..08e1608990 100644 --- a/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf +++ b/addons/interact_menu/functions/fnc_collectActiveActionTree.sqf @@ -11,6 +11,9 @@ * Return Value: * Active children * + * Example: + * [bob, [array], [array], 5] call ACE_interact_menu_fnc_collectActoveActionTree + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_compileMenu.sqf b/addons/interact_menu/functions/fnc_compileMenu.sqf index 0df6ac5965..58e13ee481 100644 --- a/addons/interact_menu/functions/fnc_compileMenu.sqf +++ b/addons/interact_menu/functions/fnc_compileMenu.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ACE_interact_menu_fnc_compileMenu + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf b/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf index cd7aabf2e1..9209447630 100644 --- a/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf +++ b/addons/interact_menu/functions/fnc_compileMenuSelfAction.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ACE_interact_menu_fnc_compileMenuSelfAction + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_compileMenuZeus.sqf b/addons/interact_menu/functions/fnc_compileMenuZeus.sqf index 442afdb26c..a5987d411f 100644 --- a/addons/interact_menu/functions/fnc_compileMenuZeus.sqf +++ b/addons/interact_menu/functions/fnc_compileMenuZeus.sqf @@ -3,11 +3,14 @@ * Compile the zeus action menu (only to be done once) * * Arguments: - * nil + * None * * Return Value: * None * + * Example: + * call ACE_interact_menu_fnc_compileMenuZeus + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf b/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf index 38e5a42460..98408f58f9 100644 --- a/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf +++ b/addons/interact_menu/functions/fnc_ctrlSetParsedTextCached.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [CONTROL, 5, "text"] call ACE_interact_menu_fnc_ctrlSetParsedTextCached + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_isSubPath.sqf b/addons/interact_menu/functions/fnc_isSubPath.sqf index cd49e6d01e..2c8244b081 100644 --- a/addons/interact_menu/functions/fnc_isSubPath.sqf +++ b/addons/interact_menu/functions/fnc_isSubPath.sqf @@ -7,7 +7,7 @@ * 1: ShortPath * * Return Value: - * Bool + * Bool * * Example: * [[["ACE_SelfActions", player],["ace_Gestures", player]], [["ACE_SelfActions", player]]] call ace_interact_menu_fnc_isSubPath diff --git a/addons/interact_menu/functions/fnc_keyDown.sqf b/addons/interact_menu/functions/fnc_keyDown.sqf index fb1a377f70..52388ffe89 100644 --- a/addons/interact_menu/functions/fnc_keyDown.sqf +++ b/addons/interact_menu/functions/fnc_keyDown.sqf @@ -8,6 +8,9 @@ * Return Value: * true * + * Example: + * [0] call ACE_interact_menu_fnc_keyDown + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_keyUp.sqf b/addons/interact_menu/functions/fnc_keyUp.sqf index aae9a370c1..dc1fcf3fe6 100644 --- a/addons/interact_menu/functions/fnc_keyUp.sqf +++ b/addons/interact_menu/functions/fnc_keyUp.sqf @@ -8,6 +8,9 @@ * Return Value: * true * + * Example: + * [1] call ACE_interact_menu_fnc_keyUp + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_renderActionPoints.sqf b/addons/interact_menu/functions/fnc_renderActionPoints.sqf index 017d3e539b..0572f15fa6 100644 --- a/addons/interact_menu/functions/fnc_renderActionPoints.sqf +++ b/addons/interact_menu/functions/fnc_renderActionPoints.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ACE_interact_menu_fnc_renderActionPoints + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_renderBaseMenu.sqf b/addons/interact_menu/functions/fnc_renderBaseMenu.sqf index 51e3ae6a5d..4b88212d59 100644 --- a/addons/interact_menu/functions/fnc_renderBaseMenu.sqf +++ b/addons/interact_menu/functions/fnc_renderBaseMenu.sqf @@ -10,6 +10,9 @@ * Return Value: * Was the menu rendered * + * Example: + * [bob, [node], [0, 0, 0]] call ACE_interact_menu_fnc_renderBaseMenu + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_renderIcon.sqf b/addons/interact_menu/functions/fnc_renderIcon.sqf index ec26635f02..4d9892ed2c 100644 --- a/addons/interact_menu/functions/fnc_renderIcon.sqf +++ b/addons/interact_menu/functions/fnc_renderIcon.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * ["text", "icon", [5, 6], "text"] call ACE_interact_menu_fnc_renderIcon + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_renderMenu.sqf b/addons/interact_menu/functions/fnc_renderMenu.sqf index 687c56d2c3..70bf02fe9a 100644 --- a/addons/interact_menu/functions/fnc_renderMenu.sqf +++ b/addons/interact_menu/functions/fnc_renderMenu.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [[], [], [5, 2], []] call ACE_interact_menu_fnc_renderMenu + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_renderSelector.sqf b/addons/interact_menu/functions/fnc_renderSelector.sqf index ef10456b5a..c2fe5f932c 100644 --- a/addons/interact_menu/functions/fnc_renderSelector.sqf +++ b/addons/interact_menu/functions/fnc_renderSelector.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [[2, 5], "icon"] call ACE_interact_menu_fnc_renderSelector + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_setupTextColors.sqf b/addons/interact_menu/functions/fnc_setupTextColors.sqf index 120c5b18e3..e51d39e533 100644 --- a/addons/interact_menu/functions/fnc_setupTextColors.sqf +++ b/addons/interact_menu/functions/fnc_setupTextColors.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ACE_interact_menu_fnc_setupTextColor + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_splitPath.sqf b/addons/interact_menu/functions/fnc_splitPath.sqf index eba203aa6f..93dea35d7c 100644 --- a/addons/interact_menu/functions/fnc_splitPath.sqf +++ b/addons/interact_menu/functions/fnc_splitPath.sqf @@ -9,6 +9,9 @@ * 0: Parent path * 1: Action name * + * Example: + * [[path]] call ACE_interact_menu_fnc_splitPath + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interact_menu/functions/fnc_userActions_addHouseActions.sqf b/addons/interact_menu/functions/fnc_userActions_addHouseActions.sqf index 2940bc2936..7fa9ffdac5 100644 --- a/addons/interact_menu/functions/fnc_userActions_addHouseActions.sqf +++ b/addons/interact_menu/functions/fnc_userActions_addHouseActions.sqf @@ -7,7 +7,7 @@ * 0: Interact Menu Type (0 - world, 1 - self) * * Return Value: - * Nothing + * None * * Example: * [0] call ace_interact_menu_fnc_userActions_addHouseActions diff --git a/addons/interact_menu/functions/fnc_userActions_getHouseActions.sqf b/addons/interact_menu/functions/fnc_userActions_getHouseActions.sqf index c513805d10..99eafc0392 100644 --- a/addons/interact_menu/functions/fnc_userActions_getHouseActions.sqf +++ b/addons/interact_menu/functions/fnc_userActions_getHouseActions.sqf @@ -6,7 +6,7 @@ * 0: Building Classname * * Return Value: - * [[Array of MemPoints], [Array Of Actions]] + * [[Array of MemPoints], [Array Of Actions]] * * Example: * ["Land_i_House_Big_01_V1_F"] call ace_interact_menu_fnc_userActions_getHouseActions diff --git a/addons/interaction/functions/fnc_canPardon.sqf b/addons/interaction/functions/fnc_canPardon.sqf index a377533018..892647640e 100644 --- a/addons/interaction/functions/fnc_canPardon.sqf +++ b/addons/interaction/functions/fnc_canPardon.sqf @@ -9,6 +9,9 @@ * Return Value: * Unit can pardon target * + * Example: + * [bob, kevin] call ACE_interaction_fnc_canPardon + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interaction/functions/fnc_doBecomeLeader.sqf b/addons/interaction/functions/fnc_doBecomeLeader.sqf index 8c8663b03b..cc96de5611 100644 --- a/addons/interaction/functions/fnc_doBecomeLeader.sqf +++ b/addons/interaction/functions/fnc_doBecomeLeader.sqf @@ -1,4 +1,4 @@ - /* +/* * Author: PabstMirror * Become Leader of group. * @@ -13,6 +13,7 @@ * * Public: No */ + #include "script_component.hpp" params ["_unit"]; diff --git a/addons/interaction/functions/fnc_getInteractionDistance.sqf b/addons/interaction/functions/fnc_getInteractionDistance.sqf index 12c9bbd7e9..c731c6e7d1 100644 --- a/addons/interaction/functions/fnc_getInteractionDistance.sqf +++ b/addons/interaction/functions/fnc_getInteractionDistance.sqf @@ -6,7 +6,7 @@ * 0: Player * 0: Target Vehicle * - * Return value: + * Return Value: * Distance to interaction point * * Example: diff --git a/addons/interaction/functions/fnc_getVehiclePos.sqf b/addons/interaction/functions/fnc_getVehiclePos.sqf index 1544aea939..f66b071ecd 100644 --- a/addons/interaction/functions/fnc_getVehiclePos.sqf +++ b/addons/interaction/functions/fnc_getVehiclePos.sqf @@ -5,7 +5,7 @@ * Arguments: * None (uses local variable _target) * - * Return value: + * Return Value: * Children actions * * Example: diff --git a/addons/interaction/functions/fnc_getVehiclePosComplex.sqf b/addons/interaction/functions/fnc_getVehiclePosComplex.sqf index 886f7052c4..6907721aba 100644 --- a/addons/interaction/functions/fnc_getVehiclePosComplex.sqf +++ b/addons/interaction/functions/fnc_getVehiclePosComplex.sqf @@ -6,7 +6,7 @@ * 0: Target * 1: Player's Position ASL * - * Return value: + * Return Value: * Interaction point in model cords * * Example: diff --git a/addons/interaction/functions/fnc_handleScrollWheel.sqf b/addons/interaction/functions/fnc_handleScrollWheel.sqf index 793e78c1b3..48716a05c3 100644 --- a/addons/interaction/functions/fnc_handleScrollWheel.sqf +++ b/addons/interaction/functions/fnc_handleScrollWheel.sqf @@ -8,6 +8,9 @@ * Return Value: * handled * + * Example: + * [5] call ACE_interaction_fnc_handleScrollWheel + * * Public: No */ #include "script_component.hpp" diff --git a/addons/interaction/functions/fnc_pardon.sqf b/addons/interaction/functions/fnc_pardon.sqf index e11a92e7db..7b6085bcf4 100644 --- a/addons/interaction/functions/fnc_pardon.sqf +++ b/addons/interaction/functions/fnc_pardon.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ACE_interaction_fnc_pardon + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_addCustomFilter.sqf b/addons/inventory/functions/fnc_addCustomFilter.sqf index 44e43bdbf0..0dd80c2e74 100644 --- a/addons/inventory/functions/fnc_addCustomFilter.sqf +++ b/addons/inventory/functions/fnc_addCustomFilter.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * ["displayname", "filter"] call ACE_inventory_fnc_addCustomFilter + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_currentItemListBox.sqf b/addons/inventory/functions/fnc_currentItemListBox.sqf index 1f1b528e93..670efeb044 100644 --- a/addons/inventory/functions/fnc_currentItemListBox.sqf +++ b/addons/inventory/functions/fnc_currentItemListBox.sqf @@ -10,6 +10,9 @@ * Return Value: * Currently selected item list box * + * Example: + * [DISPLAY] call ACE_inventory_fnc_currentItemListBox + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterBackpacks.sqf b/addons/inventory/functions/fnc_filterBackpacks.sqf index 9b629de66f..082dbd6501 100644 --- a/addons/inventory/functions/fnc_filterBackpacks.sqf +++ b/addons/inventory/functions/fnc_filterBackpacks.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterBackpacks + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterGrenades.sqf b/addons/inventory/functions/fnc_filterGrenades.sqf index 0acfbcaa2c..6a869849fc 100644 --- a/addons/inventory/functions/fnc_filterGrenades.sqf +++ b/addons/inventory/functions/fnc_filterGrenades.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterGrenades + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterHeadgear.sqf b/addons/inventory/functions/fnc_filterHeadgear.sqf index 056406a3d1..ac787fc35a 100644 --- a/addons/inventory/functions/fnc_filterHeadgear.sqf +++ b/addons/inventory/functions/fnc_filterHeadgear.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterHeadgear + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterItems.sqf b/addons/inventory/functions/fnc_filterItems.sqf index b9bf9baeea..1aaba46497 100644 --- a/addons/inventory/functions/fnc_filterItems.sqf +++ b/addons/inventory/functions/fnc_filterItems.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterItems + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterMagazines.sqf b/addons/inventory/functions/fnc_filterMagazines.sqf index dfd357f61d..e0d67e3c7e 100644 --- a/addons/inventory/functions/fnc_filterMagazines.sqf +++ b/addons/inventory/functions/fnc_filterMagazines.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterMagazines + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterMedical.sqf b/addons/inventory/functions/fnc_filterMedical.sqf index 397be50f06..567aa528a3 100644 --- a/addons/inventory/functions/fnc_filterMedical.sqf +++ b/addons/inventory/functions/fnc_filterMedical.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterMedical + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterUniforms.sqf b/addons/inventory/functions/fnc_filterUniforms.sqf index 4c135dfa88..74773c3ad0 100644 --- a/addons/inventory/functions/fnc_filterUniforms.sqf +++ b/addons/inventory/functions/fnc_filterUniforms.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterUniforms + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterVests.sqf b/addons/inventory/functions/fnc_filterVests.sqf index 646e23d04d..a0ce281bda 100644 --- a/addons/inventory/functions/fnc_filterVests.sqf +++ b/addons/inventory/functions/fnc_filterVests.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterVests + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_filterWeapons.sqf b/addons/inventory/functions/fnc_filterWeapons.sqf index 94a92814ae..65b3d7cdea 100644 --- a/addons/inventory/functions/fnc_filterWeapons.sqf +++ b/addons/inventory/functions/fnc_filterWeapons.sqf @@ -8,6 +8,9 @@ * Return Value: * Item should appear in this list? * + * Example: + * [CONFIG] call ACE_inventory_fnc_filterWeapons + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_forceItemListUpdate.sqf b/addons/inventory/functions/fnc_forceItemListUpdate.sqf index e5358212bb..03bf667504 100644 --- a/addons/inventory/functions/fnc_forceItemListUpdate.sqf +++ b/addons/inventory/functions/fnc_forceItemListUpdate.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [DISPLAY] call ACE_inventory_fnc_forceitemListUpdate + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf b/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf index 0e1daa4a52..09d2b6fb9b 100644 --- a/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf +++ b/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [DISPLAY] call ACE_inventory_fnc_inventoryDisplayLoad + * * Public: No */ #include "script_component.hpp" diff --git a/addons/inventory/functions/fnc_onLBSelChanged.sqf b/addons/inventory/functions/fnc_onLBSelChanged.sqf index 5ae49049fe..86ecfa0087 100644 --- a/addons/inventory/functions/fnc_onLBSelChanged.sqf +++ b/addons/inventory/functions/fnc_onLBSelChanged.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [CONTROL, 5] call ACE_inventory_fnc_onLBSelChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/javelin/functions/fnc_getTarget.sqf b/addons/javelin/functions/fnc_getTarget.sqf index 04d9c76ef0..49748e2883 100644 --- a/addons/javelin/functions/fnc_getTarget.sqf +++ b/addons/javelin/functions/fnc_getTarget.sqf @@ -4,13 +4,13 @@ * * Arguments: * 0: Last Target (seeds the scan) - * 1: Max Range (meters) * * Return Value: * Target * * Example: - * [] call ace_javelin_fnc_getTarget + * [bob, 5] call ace_javelin_fnc_getTarget * * Public: No */ @@ -27,12 +27,12 @@ private _viewDir = _viewASL vectorFromTo (AGLtoASL positionCameraToWorld [0,0,1] // Attempt to lock onto current target if it is still valid if (!isNull _lastTarget) then { private _aimASL = aimPos _lastTarget; - + if ((_viewASL vectorDistance _aimASL) > _maxRange) exitWith {}; - if ((acos ((_viewASL vectorFromTo _aimASL) vectorDotProduct _viewDir)) > 0.6) exitWith {}; - + if ((acos ((_viewASL vectorFromTo _aimASL) vectorDotProduct _viewDir)) > 0.6) exitWith {}; + private _relAngle = (_lastTarget getRelDir _viewASL); - + for "_xOffset" from -2.5 to 2.5 step 0.5 do { for "_yOffset" from -2 to 1 step 0.5 do { // Find test points in the model based on the angle that we are viewing it from (not true 3d projection, but not bad) diff --git a/addons/laser/functions/fnc_addLaserTarget.sqf b/addons/laser/functions/fnc_addLaserTarget.sqf index 1635b4e37f..9addb8ed93 100644 --- a/addons/laser/functions/fnc_addLaserTarget.sqf +++ b/addons/laser/functions/fnc_addLaserTarget.sqf @@ -6,7 +6,7 @@ * 0: TargetObject (vanilla laser) * 1: Vehicle * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/laser/functions/fnc_dev_drawVisibleLaserTargets.sqf b/addons/laser/functions/fnc_dev_drawVisibleLaserTargets.sqf index cecda2d21a..42931db29d 100644 --- a/addons/laser/functions/fnc_dev_drawVisibleLaserTargets.sqf +++ b/addons/laser/functions/fnc_dev_drawVisibleLaserTargets.sqf @@ -1,3 +1,20 @@ +/* + * Author: ACE-Team + * + * + * Argument: + * None + * + * Return Value: + * None + * + * Example: + * call ace_laser_fnc_dev_drawVisibleLaserTargets + * + * Public: No + */ + + // Dev Debug Function // Displays lasers and attempts to lock on to codes 1111 and 1112 from a target vehicle's view // On Screen Debug: diff --git a/addons/laser/functions/fnc_findLaserSource.sqf b/addons/laser/functions/fnc_findLaserSource.sqf index 3577bc1c32..585faf3023 100644 --- a/addons/laser/functions/fnc_findLaserSource.sqf +++ b/addons/laser/functions/fnc_findLaserSource.sqf @@ -2,13 +2,13 @@ * Author: esteldunedain * Handler function for finding position and direction of a vanilla laser. * - * Argument: + * Arguments: * 0: Vehicle (shooter of laser) * 6: Method Args - * 0: Laser Source selection on Vehicle + * 0: Laser Source selection on Vehicle * - * Return value: - * [position, direction] + * Return Value: + * [position, direction] * * Example: * [player, x,x,x,x,x, ["pilot"]] call ace_laser_fnc_findLaserSource; diff --git a/addons/laser/functions/fnc_handleLaserTargetCreation.sqf b/addons/laser/functions/fnc_handleLaserTargetCreation.sqf index 24a2502169..482a733b41 100644 --- a/addons/laser/functions/fnc_handleLaserTargetCreation.sqf +++ b/addons/laser/functions/fnc_handleLaserTargetCreation.sqf @@ -5,10 +5,7 @@ * Argument: * 0: Vanilla Laser (base type LaserTarget) * - * Return value: - * None - * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/laser/functions/fnc_keyLaserCodeChange.sqf b/addons/laser/functions/fnc_keyLaserCodeChange.sqf index d43dc52fe5..c5140709e0 100644 --- a/addons/laser/functions/fnc_keyLaserCodeChange.sqf +++ b/addons/laser/functions/fnc_keyLaserCodeChange.sqf @@ -5,7 +5,7 @@ * Argument: * 0: Change in code * - * Return value: + * Return Value: * Key Handled * Example: diff --git a/addons/laser/functions/fnc_laserOff.sqf b/addons/laser/functions/fnc_laserOff.sqf index fcfc669d45..64188a62f1 100644 --- a/addons/laser/functions/fnc_laserOff.sqf +++ b/addons/laser/functions/fnc_laserOff.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: UUID (from laserOn) * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/laser/functions/fnc_laserOn.sqf b/addons/laser/functions/fnc_laserOn.sqf index a80f69b945..cd300af083 100644 --- a/addons/laser/functions/fnc_laserOn.sqf +++ b/addons/laser/functions/fnc_laserOn.sqf @@ -12,7 +12,7 @@ * 6: Method Args * * Return Value: - * UUID for sending to laserOff function. + * UUID for sending to laserOff function. * * Example: * [hmg, hmg, [[0,0,1], "HMG_static"], 1550, 1111, 1] call ace_laser_fnc_laserOn; diff --git a/addons/laser/functions/fnc_laserTargetPFH.sqf b/addons/laser/functions/fnc_laserTargetPFH.sqf index fb81d9da60..8ee3396d94 100644 --- a/addons/laser/functions/fnc_laserTargetPFH.sqf +++ b/addons/laser/functions/fnc_laserTargetPFH.sqf @@ -5,7 +5,7 @@ * Argument: * PFEH Args * - * Return value: + * Return Value: * None * * Example: diff --git a/addons/laser/functions/fnc_rotateVectLine.sqf b/addons/laser/functions/fnc_rotateVectLine.sqf index dde211c7c4..17b771debe 100644 --- a/addons/laser/functions/fnc_rotateVectLine.sqf +++ b/addons/laser/functions/fnc_rotateVectLine.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Argument: + * None + * + * Return Value: + * None + * + * Example: + * call ace_laser_fnc_rotateVectline + * + * Public: No + */ + #include "script_component.hpp" params ["_map", "_theta"]; diff --git a/addons/laser/functions/fnc_rotateVectLineGetMap.sqf b/addons/laser/functions/fnc_rotateVectLineGetMap.sqf index e6ab81c7f4..8d7f0a7f2e 100644 --- a/addons/laser/functions/fnc_rotateVectLineGetMap.sqf +++ b/addons/laser/functions/fnc_rotateVectLineGetMap.sqf @@ -1,3 +1,19 @@ +/* + * Author: ACE-Team + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_laser_fnc_rotateVectLineGetMap + * + * Public: No + */ + #include "script_component.hpp" params ["_p", "_p1", "_p2"]; diff --git a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf index 6fa2f9c54d..460add1c74 100644 --- a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf +++ b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf @@ -13,7 +13,7 @@ * 6: Ignore 1 (e.g. Player's vehicle) * * Return Value: - * Array, [Strongest compatible laser spot ASL pos, owner object] Nil array values if nothing found. + * [Strongest compatible laser spot ASL pos, owner object] Nil array values if nothing found. * * Example: * [getPosASL player, [0,1,0], 90, [1500, 1500], 1111, player] call ace_laser_fnc_seekerFindLaserSpot; diff --git a/addons/laser/functions/fnc_shootCone.sqf b/addons/laser/functions/fnc_shootCone.sqf index e249d4d6e9..ceb45ba24b 100644 --- a/addons/laser/functions/fnc_shootCone.sqf +++ b/addons/laser/functions/fnc_shootCone.sqf @@ -9,8 +9,8 @@ * 3: Count at each divergence level * 4: Ignore vehicle 1 (e.g. Player's vehicle) * - * Return value: - * [_longestReturn, _shortestReturn, _resultPositions] + * Return Value: + * [_longestReturn, _shortestReturn, _resultPositions] * * Example: * [getPosASL player, [0,1,0]] call ace_laser_fnc_shootCone; @@ -53,7 +53,7 @@ private _pos2 = _pos vectorAdd (_vec vectorMultiply 1000); for "_i" from 1 to ceil(_count*_x) do { // Will always do at least 1 private _offset = [_vecRotateMap, (((360/_count)*_i)+_radOffset) mod 360] call FUNC(rotateVectLine); private _offsetPos = _pos2 vectorAdd (_offset vectorMultiply (_divergence*_x)); - + private _offsetVector = _pos vectorFromTo _offsetPos; _result = [_pos, _offsetVector, _ignoreObj1] call FUNC(shootRay); _resultPos = _result select 0; diff --git a/addons/laser/functions/fnc_shootRay.sqf b/addons/laser/functions/fnc_shootRay.sqf index e379026779..ceae27fe77 100644 --- a/addons/laser/functions/fnc_shootRay.sqf +++ b/addons/laser/functions/fnc_shootRay.sqf @@ -8,8 +8,8 @@ * 2: Ignore 1 (e.g. Player's vehicle) * 2: Ignore 2 (e.g. Player's vehicle) * - * Return value: - * [posASL, distance] - pos will be nil if no intersection + * Return Value: + * [posASL, distance] - pos will be nil if no intersection * * Example: * [getPosASL player, [0,1,0], player] call ace_laser_fnc_shootRay; diff --git a/addons/laserpointer/functions/fnc_getNearUnits.sqf b/addons/laserpointer/functions/fnc_getNearUnits.sqf index eb505c3795..baeb07c86e 100644 --- a/addons/laserpointer/functions/fnc_getNearUnits.sqf +++ b/addons/laserpointer/functions/fnc_getNearUnits.sqf @@ -8,6 +8,9 @@ * Return Value: * Near Units * + * Example: + * call ACE_laserpointer_fnc_getNearUnits + * * Public: No */ #include "script_component.hpp" diff --git a/addons/laserpointer/functions/fnc_onDraw.sqf b/addons/laserpointer/functions/fnc_onDraw.sqf index 0559386827..06c601869c 100644 --- a/addons/laserpointer/functions/fnc_onDraw.sqf +++ b/addons/laserpointer/functions/fnc_onDraw.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ACE_laserpointer_fnc_onDraw + * * Public: No */ #include "script_component.hpp" diff --git a/addons/logistics_uavbattery/functions/fnc_refuelUAV.sqf b/addons/logistics_uavbattery/functions/fnc_refuelUAV.sqf index 2bf617478d..2e83043d00 100644 --- a/addons/logistics_uavbattery/functions/fnc_refuelUAV.sqf +++ b/addons/logistics_uavbattery/functions/fnc_refuelUAV.sqf @@ -7,7 +7,7 @@ * 1: UAV * * Return Value: - * Nothing + * None * * Example: * [player, theUAV] call ace_logistics_uavbattery_fnc_refuelUAV diff --git a/addons/logistics_wirecutter/functions/fnc_cutDownFence.sqf b/addons/logistics_wirecutter/functions/fnc_cutDownFence.sqf index 2bf807975f..61d8a254c5 100644 --- a/addons/logistics_wirecutter/functions/fnc_cutDownFence.sqf +++ b/addons/logistics_wirecutter/functions/fnc_cutDownFence.sqf @@ -7,7 +7,7 @@ * 1: Fence * * Return Value: - * Nothing + * None * * Example: * [player, berlinWall] call ace_logistics_wirecutter_fnc_cutDownFence diff --git a/addons/logistics_wirecutter/functions/fnc_interactEH.sqf b/addons/logistics_wirecutter/functions/fnc_interactEH.sqf index bf0f5d3bc9..302e4b0975 100644 --- a/addons/logistics_wirecutter/functions/fnc_interactEH.sqf +++ b/addons/logistics_wirecutter/functions/fnc_interactEH.sqf @@ -6,7 +6,7 @@ * Interact Menu Type (0 - world, 1 - self) * * Return Value: - * Nothing + * None * * Example: * [0] call ace_logistics_wirecutter_fnc_interactEH diff --git a/addons/magazinerepack/functions/fnc_startRepackingMagazine.sqf b/addons/magazinerepack/functions/fnc_startRepackingMagazine.sqf index 32ce65d188..d3cd621305 100644 --- a/addons/magazinerepack/functions/fnc_startRepackingMagazine.sqf +++ b/addons/magazinerepack/functions/fnc_startRepackingMagazine.sqf @@ -10,7 +10,7 @@ * 2: Magazine Classname * * Return Value: - * Nothing + * None * * Example: * [player, player, "30Rnd_65x39_caseless_mag"] call ace_magazinerepack_fnc_startRepackingMagazine diff --git a/addons/map/functions/fnc_blueForceTrackingModule.sqf b/addons/map/functions/fnc_blueForceTrackingModule.sqf index f31386b204..a892bf72cd 100644 --- a/addons/map/functions/fnc_blueForceTrackingModule.sqf +++ b/addons/map/functions/fnc_blueForceTrackingModule.sqf @@ -1,13 +1,18 @@ /* -* Author: KoffeinFlummi -* Initializes the blue force tracking module. -* -* Arguments: -* Whatever the module provides. (I dunno.) -* -* Return Value: -* None -*/ + * Author: KoffeinFlummi + * Initializes the blue force tracking module. + * + * Arguments: + * Whatever the module provides. (I dunno.) + * + * Return Value: + * None + * + * Example: + * call ACE_map_fnc_blueForceTrackingModule + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/map/functions/fnc_blueForceTrackingUpdate.sqf b/addons/map/functions/fnc_blueForceTrackingUpdate.sqf index 9f37252331..46e7833cc1 100644 --- a/addons/map/functions/fnc_blueForceTrackingUpdate.sqf +++ b/addons/map/functions/fnc_blueForceTrackingUpdate.sqf @@ -1,3 +1,20 @@ +/* + * Author: ACE-Team + * Update the blue force tracking. + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ACE_map_fnc_blueForceTrackingUpdate + * + * Public: No + */ + + // #define ENABLE_PERFORMANCE_COUNTERS #include "script_component.hpp" // BEGIN_COUNTER(blueForceTrackingUpdate); diff --git a/addons/map/functions/fnc_determineMapLight.sqf b/addons/map/functions/fnc_determineMapLight.sqf index 3269c5a056..89a2f6f606 100644 --- a/addons/map/functions/fnc_determineMapLight.sqf +++ b/addons/map/functions/fnc_determineMapLight.sqf @@ -9,6 +9,9 @@ * 0: Does the map needs shading? * 1: Color of the overlay * + * Example: + * call ACE_map_fnc_determineMapLight + * * Public: No */ diff --git a/addons/map/functions/fnc_determineZoom.sqf b/addons/map/functions/fnc_determineZoom.sqf index efe20a0e52..fd9cc24264 100644 --- a/addons/map/functions/fnc_determineZoom.sqf +++ b/addons/map/functions/fnc_determineZoom.sqf @@ -1,15 +1,19 @@ /* -* Author: Rocko -* Calculate the maximum zoom level allowed for the current map -* -* Arguments: -* None -* -* Return Value: -* None -* -* Public: No -*/ + * Author: Rocko + * Calculate the maximum zoom level allowed for the current map + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ACE_map_fnc_determineZoom + * + * Public: No + */ + #include "script_component.hpp" private _grids = (configFile >> "CfgWorlds" >> worldName >> "Grid"); diff --git a/addons/map/functions/fnc_moduleMap.sqf b/addons/map/functions/fnc_moduleMap.sqf index fa64cacb82..3dead784ca 100644 --- a/addons/map/functions/fnc_moduleMap.sqf +++ b/addons/map/functions/fnc_moduleMap.sqf @@ -3,10 +3,15 @@ * Initializes the Map module. * * Arguments: - * Whatever the module provides. (I dunno.) + * Whatever the module provides. (I dunno.) * * Return Value: * None + * + * Example: + * call ACE_map_fnc_moduleMap + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/map/functions/fnc_onDrawMap.sqf b/addons/map/functions/fnc_onDrawMap.sqf index 37ec5a7000..dff79d694a 100644 --- a/addons/map/functions/fnc_onDrawMap.sqf +++ b/addons/map/functions/fnc_onDrawMap.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * Something + * + * Return Value: + * None + * + * Example: + * call ACE_map_fnc_onDrawMap + * + * Public: No + */ + #include "script_component.hpp" ((_this select 0) displayCtrl 1016) ctrlShow GVAR(mapShowCursorCoordinates); diff --git a/addons/map/functions/fnc_simulateMapLight.sqf b/addons/map/functions/fnc_simulateMapLight.sqf index ba03c421a7..94c0853b23 100644 --- a/addons/map/functions/fnc_simulateMapLight.sqf +++ b/addons/map/functions/fnc_simulateMapLight.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [CONTROL, 5, [5, 4, 6], []] call ACE_map_fnc_simulateMapLights + * * Public: No */ diff --git a/addons/map/functions/fnc_updateMapEffects.sqf b/addons/map/functions/fnc_updateMapEffects.sqf index 23e97114a8..e8ebcbd884 100644 --- a/addons/map/functions/fnc_updateMapEffects.sqf +++ b/addons/map/functions/fnc_updateMapEffects.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ACE_map_fnc_updateMapEffects + * * Public: No */ diff --git a/addons/maptools/functions/fnc_calculateMapScale.sqf b/addons/maptools/functions/fnc_calculateMapScale.sqf index 926ed558fe..d5148893d5 100644 --- a/addons/maptools/functions/fnc_calculateMapScale.sqf +++ b/addons/maptools/functions/fnc_calculateMapScale.sqf @@ -6,7 +6,10 @@ * None * * Return Value: - * No + * None + * + * Example: + * call ACE_maptools_fnc_calculateMapScale * * Public: No */ diff --git a/addons/maptools/functions/fnc_canUseMapGPS.sqf b/addons/maptools/functions/fnc_canUseMapGPS.sqf index a327c2bc8d..7333c1f9e0 100644 --- a/addons/maptools/functions/fnc_canUseMapGPS.sqf +++ b/addons/maptools/functions/fnc_canUseMapGPS.sqf @@ -6,7 +6,10 @@ * None * * Return Value: - * + * Boolean + * + * Example: + * call ACE_map_fnc_canUseMapGPS * * Public: No */ diff --git a/addons/maptools/functions/fnc_canUseMapTools.sqf b/addons/maptools/functions/fnc_canUseMapTools.sqf index 8c16425082..bc3c7fbb8a 100644 --- a/addons/maptools/functions/fnc_canUseMapTools.sqf +++ b/addons/maptools/functions/fnc_canUseMapTools.sqf @@ -6,7 +6,10 @@ * None * * Return Value: - * + * Boolean + * + * Example: + * call ACE_maptools_fnc_canUseMapTools * * Public: No */ diff --git a/addons/maptools/functions/fnc_drawLinesOnRoamer.sqf b/addons/maptools/functions/fnc_drawLinesOnRoamer.sqf index 6a900c335b..ba9363c68f 100644 --- a/addons/maptools/functions/fnc_drawLinesOnRoamer.sqf +++ b/addons/maptools/functions/fnc_drawLinesOnRoamer.sqf @@ -7,7 +7,7 @@ * 1: Roamer Width * * Return Value: - * Nothing + * None * * Example: * [map, 300] call ace_maptools_fnc_drawLinesOnRoamer diff --git a/addons/maptools/functions/fnc_handleMouseButton.sqf b/addons/maptools/functions/fnc_handleMouseButton.sqf index 7750ef0965..143289447e 100644 --- a/addons/maptools/functions/fnc_handleMouseButton.sqf +++ b/addons/maptools/functions/fnc_handleMouseButton.sqf @@ -3,12 +3,18 @@ * Handle mouse buttons. * * Arguments: - * 0: 1 if mouse down down, 0 if mouse button up (Number) - * 1: Parameters of the mouse button event + * 0: 1 if mouse down down, 0 if mouse button up + * 1: Parameters of the mouse button event * * Return Value: - * Boolean, true if event was handled + * true if event was handled + * + * Example: + * [0, [array]] call ACE_maptools_fnc_handleMouseButton + * + * Public: No */ + #include "script_component.hpp" params ["_dir", "_params"]; @@ -26,16 +32,16 @@ if ((_button == 0) && {GVAR(freedrawing) || _ctrlKey}) exitWith { private _markerName = allMapMarkers select (count allMapMarkers - 1); private _markerPos = getMarkerPos _markerName; private _distanceCheck = _markerPos distance2d GVAR(drawPosStart); - + TRACE_3("Line Drawn",_markerName,_markerPos,_distanceCheck); - + if (_distanceCheck > 1) exitWith {WARNING("Wrong Marker!");}; if ((count GVAR(freeDrawingData)) != 3) exitWith {TRACE_1("never touched roamer",GVAR(freeDrawingData));}; - + GVAR(freeDrawingData) params ["", "_startStraightPos", "_endStraightPos"]; _startStraightPos set [2, 0]; - _endStraightPos set [2, 0]; - + _endStraightPos set [2, 0]; + // Convert marker to rectangle and change it's pos/size/dir _markerName setMarkerShape "RECTANGLE"; diff --git a/addons/maptools/functions/fnc_handleMouseMove.sqf b/addons/maptools/functions/fnc_handleMouseMove.sqf index a52163ba32..a7c48cfed4 100644 --- a/addons/maptools/functions/fnc_handleMouseMove.sqf +++ b/addons/maptools/functions/fnc_handleMouseMove.sqf @@ -3,11 +3,16 @@ * Handle mouse movement over the map tool. * * Arguments: - * 0: Map Control - * 1: Mouse position on screen coordinates + * 0: Map Control + * 1: Mouse position on screen coordinates * * Return Value: - * Boolean, true if event was handled + * true if event was handled + * + * Example: + * [CONTROL, [0, 5, 1]] call ACE_maptools_fnc_handleMouseMove + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/maptools/functions/fnc_isInsideMapTool.sqf b/addons/maptools/functions/fnc_isInsideMapTool.sqf index 216a2a675a..c54f831e8f 100644 --- a/addons/maptools/functions/fnc_isInsideMapTool.sqf +++ b/addons/maptools/functions/fnc_isInsideMapTool.sqf @@ -7,8 +7,14 @@ * 1: y Position (in meters) * * Return Value: - * Boolean + * Boolean + * + * Example: + * [0, 5] call ACE_maptools_fnc_isInsideMapTool + * + * Public: No */ + #include "script_component.hpp" if (GVAR(mapTool_Shown) == 0) exitWith {false}; diff --git a/addons/maptools/functions/fnc_openMapGps.sqf b/addons/maptools/functions/fnc_openMapGps.sqf index c3e2a8bfee..7e8d923661 100644 --- a/addons/maptools/functions/fnc_openMapGps.sqf +++ b/addons/maptools/functions/fnc_openMapGps.sqf @@ -6,7 +6,10 @@ * 0: Open GPS? * * Return Value: - * Nothing + * None + * + * Example: + * [true] call ACE_maptools_fnc_openMapGps * * Public: No */ diff --git a/addons/maptools/functions/fnc_openMapGpsUpdate.sqf b/addons/maptools/functions/fnc_openMapGpsUpdate.sqf index 719bf37763..63ecae81ec 100644 --- a/addons/maptools/functions/fnc_openMapGpsUpdate.sqf +++ b/addons/maptools/functions/fnc_openMapGpsUpdate.sqf @@ -1,5 +1,18 @@ -//esteldunedain -//update gps display +/* + * Author: esteldunedain + * update gps display + * + * Arguments: + * Something + * + * Return Value: + * None + * + * Example: + * call ACE_maptools_fnc_openMapGpsUpdate + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/maptools/functions/fnc_updateMapToolMarkers.sqf b/addons/maptools/functions/fnc_updateMapToolMarkers.sqf index 864ef33844..026a4037d1 100644 --- a/addons/maptools/functions/fnc_updateMapToolMarkers.sqf +++ b/addons/maptools/functions/fnc_updateMapToolMarkers.sqf @@ -6,7 +6,10 @@ * 0: The Map * * Return Value: - * Nothing + * None + * + * Example: + * [CONTROL] call ACE_maptools_fnc_updateMapToolMarkers * * Public: No */ diff --git a/addons/markers/functions/fnc_getEnabledChannels.sqf b/addons/markers/functions/fnc_getEnabledChannels.sqf index 9a64ff06d4..eb4bcfd5ce 100644 --- a/addons/markers/functions/fnc_getEnabledChannels.sqf +++ b/addons/markers/functions/fnc_getEnabledChannels.sqf @@ -8,6 +8,9 @@ * Return Value: * Enabled Channels * + * Example: + * [false] call ACE_markers_fnc_getEnabledChannels + * * Public: No */ #include "script_component.hpp" diff --git a/addons/markers/functions/fnc_onLBSelChangedChannel.sqf b/addons/markers/functions/fnc_onLBSelChangedChannel.sqf index f63c4e5cf4..8c7ac11046 100644 --- a/addons/markers/functions/fnc_onLBSelChangedChannel.sqf +++ b/addons/markers/functions/fnc_onLBSelChangedChannel.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [CONTROL, 5] call ACE_markers_fnc_onLBSelChangedChannel + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_actionCheckBloodPressure.sqf b/addons/medical/functions/fnc_actionCheckBloodPressure.sqf index 9e66eda263..207e2bb90d 100644 --- a/addons/medical/functions/fnc_actionCheckBloodPressure.sqf +++ b/addons/medical/functions/fnc_actionCheckBloodPressure.sqf @@ -1,16 +1,19 @@ /* -* Author: Glowbal -* Action for checking the blood pressure of the patient -* -* Arguments: -* 0: The medic -* 1: The patient -* -* Return Value: -* None -* -* Public: No -*/ + * Author: Glowbal + * Action for checking the blood pressure of the patient + * + * Arguments: + * 0: The medic + * 1: The patient + * + * Return Value: + * None + * + * Example: + * [bob, kevin] call ACE_medical_fnc_actionCheckBloodPressure + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_actionCheckBloodPressureLocal.sqf b/addons/medical/functions/fnc_actionCheckBloodPressureLocal.sqf index 184110265a..0497b559b8 100644 --- a/addons/medical/functions/fnc_actionCheckBloodPressureLocal.sqf +++ b/addons/medical/functions/fnc_actionCheckBloodPressureLocal.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ACE_medical_fnc_actionCheckBloodPressureLocal + * * Public: No */ diff --git a/addons/medical/functions/fnc_actionCheckPulse.sqf b/addons/medical/functions/fnc_actionCheckPulse.sqf index 39f196a0a5..7654f24d78 100644 --- a/addons/medical/functions/fnc_actionCheckPulse.sqf +++ b/addons/medical/functions/fnc_actionCheckPulse.sqf @@ -1,16 +1,19 @@ /* -* Author: Glowbal -* Action for checking the pulse or heart rate of the patient -* -* Arguments: -* 0: The medic -* 1: The patient -* -* Return Value: -* None -* -* Public: No -*/ + * Author: Glowbal + * Action for checking the pulse or heart rate of the patient + * + * Arguments: + * 0: The medic + * 1: The patient + * + * Return Value: + * None + * + * Example: + * [bob, kevin] call ACE_medical_fnc_actionCheckPulse + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_actionCheckPulseLocal.sqf b/addons/medical/functions/fnc_actionCheckPulseLocal.sqf index cf84df075e..7f4fe176da 100644 --- a/addons/medical/functions/fnc_actionCheckPulseLocal.sqf +++ b/addons/medical/functions/fnc_actionCheckPulseLocal.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ACE_medical_fnc_actionCheckPulseLocal + * * Public: No */ diff --git a/addons/medical/functions/fnc_actionCheckResponse.sqf b/addons/medical/functions/fnc_actionCheckResponse.sqf index c47dc5dd64..a56c8191c6 100644 --- a/addons/medical/functions/fnc_actionCheckResponse.sqf +++ b/addons/medical/functions/fnc_actionCheckResponse.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ACE_medical_fnc_actionCheckResponse + * * Public: No */ diff --git a/addons/medical/functions/fnc_actionDiagnose.sqf b/addons/medical/functions/fnc_actionDiagnose.sqf index d86d90db7d..81e73699a8 100644 --- a/addons/medical/functions/fnc_actionDiagnose.sqf +++ b/addons/medical/functions/fnc_actionDiagnose.sqf @@ -1,16 +1,19 @@ /* -* Author: Glowbal -* Action for diagnosing in basic medical -* -* Arguments: -* 0: The medic -* 1: The patient -* -* Return Value: -* None -* -* Public: No -*/ + * Author: Glowbal + * Action for diagnosing in basic medical + * + * Arguments: + * 0: The medic + * 1: The patient + * + * Return Value: + * None + * + * Example: + * [bob, kevin] call ACE_medical_fnc_actionDiagnose + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_actionLoadUnit.sqf b/addons/medical/functions/fnc_actionLoadUnit.sqf index 55a7a9ba51..11a875bf2f 100644 --- a/addons/medical/functions/fnc_actionLoadUnit.sqf +++ b/addons/medical/functions/fnc_actionLoadUnit.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ACE_medical_fnc_actionLoadUnit + * * Public: No */ diff --git a/addons/medical/functions/fnc_actionRemoveTourniquet.sqf b/addons/medical/functions/fnc_actionRemoveTourniquet.sqf index bf0a3e5ae4..e32fd09f69 100644 --- a/addons/medical/functions/fnc_actionRemoveTourniquet.sqf +++ b/addons/medical/functions/fnc_actionRemoveTourniquet.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, "selection"] call ace_medical_fnc_actionRemoveTourniquet + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_actionUnloadUnit.sqf b/addons/medical/functions/fnc_actionUnloadUnit.sqf index 75fe76bce9..061355fdc8 100644 --- a/addons/medical/functions/fnc_actionUnloadUnit.sqf +++ b/addons/medical/functions/fnc_actionUnloadUnit.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, false] call ACE_medical_fnc_actionUnloadUnit + * * Public: No */ diff --git a/addons/medical/functions/fnc_addHeartRateAdjustment.sqf b/addons/medical/functions/fnc_addHeartRateAdjustment.sqf index a23ea45023..de3d2c4204 100644 --- a/addons/medical/functions/fnc_addHeartRateAdjustment.sqf +++ b/addons/medical/functions/fnc_addHeartRateAdjustment.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, 1, 5, {callback}] call ace_medical_fnc_addHeartRateAdjustment + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_addToInjuredCollection.sqf b/addons/medical/functions/fnc_addToInjuredCollection.sqf index 77d2378d0d..2da3ca34a1 100644 --- a/addons/medical/functions/fnc_addToInjuredCollection.sqf +++ b/addons/medical/functions/fnc_addToInjuredCollection.sqf @@ -1,15 +1,19 @@ /* * Author: Glowbal - * Enabled the vitals loop for a unit. + * Enabled the vitals loop for a unit. Deprecated! * * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * None * - * Deprecated + * Example: + * [bob] call ACE_medical_fnc_addToInjuredCollection + * + * Public: No */ + #include "script_component.hpp" ACE_DEPRECATED("ace_medical_fnc_addToInjuredCollection","3.7.0","ace_medical_fnc_addVitalLoop"); diff --git a/addons/medical/functions/fnc_addToLog.sqf b/addons/medical/functions/fnc_addToLog.sqf index f0c6b9c622..2a5e77fd1b 100644 --- a/addons/medical/functions/fnc_addToLog.sqf +++ b/addons/medical/functions/fnc_addToLog.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, "type", "message", [_args]] call ace_medical_fnc_addToLog + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_addToTriageCard.sqf b/addons/medical/functions/fnc_addToTriageCard.sqf index 0e11f38f77..720a435d68 100644 --- a/addons/medical/functions/fnc_addToTriageCard.sqf +++ b/addons/medical/functions/fnc_addToTriageCard.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, "bandage"] call ace_medical_fnc_addToTriageCard + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_addUnconsciousCondition.sqf b/addons/medical/functions/fnc_addUnconsciousCondition.sqf index 195cd557d7..b3b7f7747b 100644 --- a/addons/medical/functions/fnc_addUnconsciousCondition.sqf +++ b/addons/medical/functions/fnc_addUnconsciousCondition.sqf @@ -5,9 +5,12 @@ * Arguments: * 0-N: Code, should return a boolean * - * ReturnValue: + * Return Value: * None * + * Example: + * [[{bob}]] call ace_medical_fnc_addUnconsciousCondition + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_addUnloadPatientActions.sqf b/addons/medical/functions/fnc_addUnloadPatientActions.sqf index 596a536de6..20399c67c1 100644 --- a/addons/medical/functions/fnc_addUnloadPatientActions.sqf +++ b/addons/medical/functions/fnc_addUnloadPatientActions.sqf @@ -10,6 +10,9 @@ * Return Value: * Children actions * + * Example: + * [car, kevin, [params]] call ACE_medical_fnc_addUnloadPatientActions + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_addVitalLoop.sqf b/addons/medical/functions/fnc_addVitalLoop.sqf index aa3d6608d0..4045c188f5 100644 --- a/addons/medical/functions/fnc_addVitalLoop.sqf +++ b/addons/medical/functions/fnc_addVitalLoop.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob] call ace_medical_fnc_addVitalLoop + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_bodyCleanupLoop.sqf b/addons/medical/functions/fnc_bodyCleanupLoop.sqf index af17ffcd34..9f59f32a25 100644 --- a/addons/medical/functions/fnc_bodyCleanupLoop.sqf +++ b/addons/medical/functions/fnc_bodyCleanupLoop.sqf @@ -5,9 +5,12 @@ * Arguments: * None * - * ReturnValue: + * Return Value: * None * + * Example: + * call ACE_medical_fnc_bodyCleanupLoop + * * Public: No */ diff --git a/addons/medical/functions/fnc_canAccessMedicalEquipment.sqf b/addons/medical/functions/fnc_canAccessMedicalEquipment.sqf index 53707ae65c..d31c03db1d 100644 --- a/addons/medical/functions/fnc_canAccessMedicalEquipment.sqf +++ b/addons/medical/functions/fnc_canAccessMedicalEquipment.sqf @@ -6,9 +6,12 @@ * 0: The caller * 1: The target * - * ReturnValue: + * Return Value: * Can Treat * + * Example: + * [bob, target] call ace_medical_fnc_canAccessMedicalEquipment + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_canTreat.sqf b/addons/medical/functions/fnc_canTreat.sqf index 1c78eb1e43..765df301c7 100644 --- a/addons/medical/functions/fnc_canTreat.sqf +++ b/addons/medical/functions/fnc_canTreat.sqf @@ -8,7 +8,7 @@ * 2: Selection name * 3: ACE_Medical_Treatments Classname * - * ReturnValue: + * Return Value: * Can Treat * * Example: diff --git a/addons/medical/functions/fnc_canTreatCached.sqf b/addons/medical/functions/fnc_canTreatCached.sqf index 76d4897b74..dd7711936f 100644 --- a/addons/medical/functions/fnc_canTreatCached.sqf +++ b/addons/medical/functions/fnc_canTreatCached.sqf @@ -8,9 +8,12 @@ * 2: Selection name * 3: ACE_Medical_Treatments Classname * - * ReturnValue: + * Return Value: * Can Treat * + * Example: + * [bob, kevin, "selection", "classname"] call ACE_medical_fnc_canTreatCached + * * Public: No */ diff --git a/addons/medical/functions/fnc_copyDeadBody.sqf b/addons/medical/functions/fnc_copyDeadBody.sqf index af601d9f33..da7fb16cff 100644 --- a/addons/medical/functions/fnc_copyDeadBody.sqf +++ b/addons/medical/functions/fnc_copyDeadBody.sqf @@ -9,6 +9,9 @@ * Return Value: * Returns the copy of the unit. If no copy could be made, returns the oldBody * + * Example: + * [bob, kevin] call ACE_medical_fnc_copyDeadBody + * * Public: No */ diff --git a/addons/medical/functions/fnc_createLitter.sqf b/addons/medical/functions/fnc_createLitter.sqf index 2780642056..85e852d927 100644 --- a/addons/medical/functions/fnc_createLitter.sqf +++ b/addons/medical/functions/fnc_createLitter.sqf @@ -7,13 +7,16 @@ * 1: The target * 2: The treatment Selection Name * 3: The treatment classname - * 4: ? - * 5: Users of Items + * 4: ? + * 5: Users of Items * 6: Blood Loss on selection (previously called _previousDamage) * * Return Value: * None * + * Example: + * [bob, kevin, "selection", "classname", , , 5] call ACE_medical_fnc_createLitter + * * Public: No */ diff --git a/addons/medical/functions/fnc_determineIfFatal.sqf b/addons/medical/functions/fnc_determineIfFatal.sqf index 6a4353ca81..9d1940a80a 100644 --- a/addons/medical/functions/fnc_determineIfFatal.sqf +++ b/addons/medical/functions/fnc_determineIfFatal.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, 2, 5] call ACE_medical_fnc_determineIfFatal + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_displayPatientInformation.sqf b/addons/medical/functions/fnc_displayPatientInformation.sqf index 72357166b5..334db62613 100644 --- a/addons/medical/functions/fnc_displayPatientInformation.sqf +++ b/addons/medical/functions/fnc_displayPatientInformation.sqf @@ -7,9 +7,12 @@ * 1: Show (default: true) * 2: Selection (default: 0) * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, true, 2] call ACE_medical_fnc_displayPatientInformation + * * Public: No */ diff --git a/addons/medical/functions/fnc_displayTriageCard.sqf b/addons/medical/functions/fnc_displayTriageCard.sqf index 1633853214..c273b1d0f0 100644 --- a/addons/medical/functions/fnc_displayTriageCard.sqf +++ b/addons/medical/functions/fnc_displayTriageCard.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, true] call ace_medical_fnc_displayTriageCard + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_dropDownTriageCard.sqf b/addons/medical/functions/fnc_dropDownTriageCard.sqf index c499283446..3e52d3efc5 100644 --- a/addons/medical/functions/fnc_dropDownTriageCard.sqf +++ b/addons/medical/functions/fnc_dropDownTriageCard.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [true] call ace_medical_fnc_dropDownTriageCard + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_getBloodLoss.sqf b/addons/medical/functions/fnc_getBloodLoss.sqf index 8f2f968e99..e584b4cd0d 100644 --- a/addons/medical/functions/fnc_getBloodLoss.sqf +++ b/addons/medical/functions/fnc_getBloodLoss.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * Total blood loss of unit * + * Example: + * [bob] call ACE_medical_fnc_getBloodLoss + * * Public: No */ diff --git a/addons/medical/functions/fnc_getBloodPressure.sqf b/addons/medical/functions/fnc_getBloodPressure.sqf index 63908eecc7..076d42c286 100644 --- a/addons/medical/functions/fnc_getBloodPressure.sqf +++ b/addons/medical/functions/fnc_getBloodPressure.sqf @@ -5,10 +5,13 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * 0: BloodPressure Low * 1: BloodPressure High * + * Example: + * [bob, kevin] call ACE_medical_fnc_getBloodPressure + * * Public: No */ diff --git a/addons/medical/functions/fnc_getBloodVolumeChange.sqf b/addons/medical/functions/fnc_getBloodVolumeChange.sqf index 396d058140..fcabcd53cf 100644 --- a/addons/medical/functions/fnc_getBloodVolumeChange.sqf +++ b/addons/medical/functions/fnc_getBloodVolumeChange.sqf @@ -6,9 +6,12 @@ * 0: The Unit * 1: Global Sync Values (bloodbags) * - * ReturnValue: + * Return Value: * Blood volume change (in % total) * + * Example: + * [bob, true] call ACE_medical_fnc_getBloodVolumeChange + * * Public: No */ diff --git a/addons/medical/functions/fnc_getCardiacOutput.sqf b/addons/medical/functions/fnc_getCardiacOutput.sqf index 74da98012b..ef6e75cde4 100644 --- a/addons/medical/functions/fnc_getCardiacOutput.sqf +++ b/addons/medical/functions/fnc_getCardiacOutput.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * Current cardiac output * + * Example: + * [bob] call ACE_medical_fnc_getCardiacOutput + * * Public: No */ diff --git a/addons/medical/functions/fnc_getHeartRateChange.sqf b/addons/medical/functions/fnc_getHeartRateChange.sqf index 4f0b19f80c..ac659622b8 100644 --- a/addons/medical/functions/fnc_getHeartRateChange.sqf +++ b/addons/medical/functions/fnc_getHeartRateChange.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * Change in heart Rate * + * Example: + * [bob] call ACE_medical_fnc_getHeartRateChange + * * Public: No */ diff --git a/addons/medical/functions/fnc_getTriageStatus.sqf b/addons/medical/functions/fnc_getTriageStatus.sqf index 79af660407..5174b92139 100644 --- a/addons/medical/functions/fnc_getTriageStatus.sqf +++ b/addons/medical/functions/fnc_getTriageStatus.sqf @@ -10,6 +10,9 @@ * 1: Status ID * 2: Color > * + * Example: + * [bob] call ace_medical_fnc_getTriageStatus + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_getTypeOfDamage.sqf b/addons/medical/functions/fnc_getTypeOfDamage.sqf index 56cb8f75ef..b026f41ded 100644 --- a/addons/medical/functions/fnc_getTypeOfDamage.sqf +++ b/addons/medical/functions/fnc_getTypeOfDamage.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The projectile classname or object * - * ReturnValue: + * Return Value: * Type of damage * + * Example: + * ["bullet"] call ACE_medical_fnc_getTypeOfDamage + * * Public: No */ diff --git a/addons/medical/functions/fnc_getUnconsciousCondition.sqf b/addons/medical/functions/fnc_getUnconsciousCondition.sqf index ad366b5ab2..f5cb4444bc 100644 --- a/addons/medical/functions/fnc_getUnconsciousCondition.sqf +++ b/addons/medical/functions/fnc_getUnconsciousCondition.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * Should the unit stay unconscious? * + * Example: + * [bob] call ace_medical_fnc_getUnconsciousCondition + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_handleBandageOpening.sqf b/addons/medical/functions/fnc_handleBandageOpening.sqf index ed589e3fd6..6f8f0c05fe 100644 --- a/addons/medical/functions/fnc_handleBandageOpening.sqf +++ b/addons/medical/functions/fnc_handleBandageOpening.sqf @@ -13,6 +13,9 @@ * Return Value: * None * + * Example: + * [bob, 5, 5, 1, [injury], "bandage"] call ACE_medical_fnc_handleBandageOpening + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleCollisionDamage.sqf b/addons/medical/functions/fnc_handleCollisionDamage.sqf index 191a91cb6a..a101f9b1f9 100644 --- a/addons/medical/functions/fnc_handleCollisionDamage.sqf +++ b/addons/medical/functions/fnc_handleCollisionDamage.sqf @@ -1,4 +1,20 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * 0: Unit + * 1: New Damage + * + * Return Value: + * None + * + * Example: + * [bob, 2] call ACE_medical_fnc_handleCollisionDamage + * + * Public: No + */ + #include "script_component.hpp" params ["_unit", "_newDamage"]; diff --git a/addons/medical/functions/fnc_handleCreateLitter.sqf b/addons/medical/functions/fnc_handleCreateLitter.sqf index 2c701a2917..45ea452782 100644 --- a/addons/medical/functions/fnc_handleCreateLitter.sqf +++ b/addons/medical/functions/fnc_handleCreateLitter.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * ["litter", [2, 5, 6], bob] call ACE_medical_fnc_handleCreateLitter + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_handleDamage.sqf b/addons/medical/functions/fnc_handleDamage.sqf index 4d3dc01e31..242b9a7997 100644 --- a/addons/medical/functions/fnc_handleDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage.sqf @@ -1,4 +1,4 @@ - /* +/* * Author: KoffeinFlummi, Glowbal, commy2 * Main HandleDamage EH function. * @@ -7,13 +7,16 @@ * 1: Name Of Hit Selection * 2: Amount Of Damage * 3: Shooter - * 4: Projectile + * 4: Projectile * 5: HitPointIndex (-1 for structural) * 6: Shooter * * Return Value: * Damage To Be Inflicted * + * Example: + * [bob, "leg", 2, kevin, "bullet", -1, kevin] call ACE_medical_fnc_handleDamage + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_handleDamage_advanced.sqf b/addons/medical/functions/fnc_handleDamage_advanced.sqf index 724958dfbc..77d78b94dd 100644 --- a/addons/medical/functions/fnc_handleDamage_advanced.sqf +++ b/addons/medical/functions/fnc_handleDamage_advanced.sqf @@ -15,6 +15,9 @@ * Return Value: * None * + * Example: + * [bob, "leg", 2, kevin, "bullet", 2, kevin, 2] call ACE_medical_fnc_handleDamage_advanced + * * Public: No */ @@ -27,10 +30,10 @@ params ["_unit", "_selectionName", "_amountOfDamage", "_sourceOfDamage", "_typeO if ((_typeOfProjectile == "") && {_newDamage < 0.15} && { _newDamage = _newDamage + (_unit getVariable [QGVAR(trivialDamage), 0]); - if (_newDamage > 0.15) then { + if (_newDamage > 0.15) then { // if the new sum is large enough, reset variable and continue with it added in _unit setVariable [QGVAR(trivialDamage), 0]; - false + false } else { // otherwise just save the new sum into the variable and exit _unit setVariable [QGVAR(trivialDamage), _newDamage]; diff --git a/addons/medical/functions/fnc_handleDamage_advancedSetDamage.sqf b/addons/medical/functions/fnc_handleDamage_advancedSetDamage.sqf index b18604f133..561a929133 100644 --- a/addons/medical/functions/fnc_handleDamage_advancedSetDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage_advancedSetDamage.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ACE_medical_fnc_handleDamage_advancedSetDamage + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleDamage_airway.sqf b/addons/medical/functions/fnc_handleDamage_airway.sqf index fb4c9fe83c..7ff2610de3 100644 --- a/addons/medical/functions/fnc_handleDamage_airway.sqf +++ b/addons/medical/functions/fnc_handleDamage_airway.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [bob, "leg", 2, kevin, "shot"] call ACE_medical_fnc_airway + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleDamage_caching.sqf b/addons/medical/functions/fnc_handleDamage_caching.sqf index 792f09e75d..c9499361a4 100644 --- a/addons/medical/functions/fnc_handleDamage_caching.sqf +++ b/addons/medical/functions/fnc_handleDamage_caching.sqf @@ -11,7 +11,10 @@ * 5: HitPointIndex (-1 for structural) * * Return Value: - * + * None + * + * Example: + * [bob, "leg", 2, kevin, "bullet", -1] call ACE_medical_fnc_handleDamage_caching * * Public: No */ diff --git a/addons/medical/functions/fnc_handleDamage_fractures.sqf b/addons/medical/functions/fnc_handleDamage_fractures.sqf index 5292781420..1681acbe6d 100644 --- a/addons/medical/functions/fnc_handleDamage_fractures.sqf +++ b/addons/medical/functions/fnc_handleDamage_fractures.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [bob, "leg", 2, kevin, "shot"] call ACE_medical_fnc_handleDamage_fractures + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleDamage_internalInjuries.sqf b/addons/medical/functions/fnc_handleDamage_internalInjuries.sqf index 8e249eee8f..97499c53c6 100644 --- a/addons/medical/functions/fnc_handleDamage_internalInjuries.sqf +++ b/addons/medical/functions/fnc_handleDamage_internalInjuries.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [bob, "leg", 2, kevin, "shot"] call ACE_medical_fnc_handleDamage_internalInjuries + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleDamage_wounds.sqf b/addons/medical/functions/fnc_handleDamage_wounds.sqf index 804c933b0e..1ab223d14a 100644 --- a/addons/medical/functions/fnc_handleDamage_wounds.sqf +++ b/addons/medical/functions/fnc_handleDamage_wounds.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [bob, "leg", 2, kevin, "shot"] call ACE_medical_fnc_handleDamage_wounds + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleDamage_woundsOld.sqf b/addons/medical/functions/fnc_handleDamage_woundsOld.sqf index c6ccd1c2b5..18c4d76d19 100644 --- a/addons/medical/functions/fnc_handleDamage_woundsOld.sqf +++ b/addons/medical/functions/fnc_handleDamage_woundsOld.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [bob, "leg", 1, kevin, "shot"] call ACE_medical_fnc_handleDamage_woundsOld + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleKilled.sqf b/addons/medical/functions/fnc_handleKilled.sqf index 6ca05a4228..52b79f8760 100644 --- a/addons/medical/functions/fnc_handleKilled.sqf +++ b/addons/medical/functions/fnc_handleKilled.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob] call ACE_medical_fnc_handleKilled + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleLocal.sqf b/addons/medical/functions/fnc_handleLocal.sqf index 8bf3cd5e69..b9282ef9ee 100644 --- a/addons/medical/functions/fnc_handleLocal.sqf +++ b/addons/medical/functions/fnc_handleLocal.sqf @@ -6,9 +6,12 @@ * 0: The Unit * 1: Is local * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, true] call ACE_medical_fnc_handleLocal + * * Public: No */ diff --git a/addons/medical/functions/fnc_handleUnitVitals.sqf b/addons/medical/functions/fnc_handleUnitVitals.sqf index 78c1cc9dfe..3bb40dd134 100644 --- a/addons/medical/functions/fnc_handleUnitVitals.sqf +++ b/addons/medical/functions/fnc_handleUnitVitals.sqf @@ -5,8 +5,11 @@ * Arguments: * 0: The Unit * - * ReturnValue: - * + * Return Value: + * None + * + * Example: + * [bob] call ACE_medical_fnc_handleUnitVitals * * Public: No */ diff --git a/addons/medical/functions/fnc_hasItem.sqf b/addons/medical/functions/fnc_hasItem.sqf index cebe02e6c6..c1b84a940a 100644 --- a/addons/medical/functions/fnc_hasItem.sqf +++ b/addons/medical/functions/fnc_hasItem.sqf @@ -7,8 +7,11 @@ * 1: Patient * 2: Item * - * ReturnValue: - * + * Return Value: + * None + * + * Example: + * [bob, patient, "bandage"] call ace_medical_fnc_hasItem * * Public: Yes */ diff --git a/addons/medical/functions/fnc_hasItems.sqf b/addons/medical/functions/fnc_hasItems.sqf index d3e79c0a54..e251f22174 100644 --- a/addons/medical/functions/fnc_hasItems.sqf +++ b/addons/medical/functions/fnc_hasItems.sqf @@ -7,9 +7,12 @@ * 1: Patient * 2: Items > * - * ReturnValue: + * Return Value: * Has the items * + * Example: + * [bob, patient, ["bandage", "morphine"]] call ace_medical_fnc_hasItems + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_hasMedicalEnabled.sqf b/addons/medical/functions/fnc_hasMedicalEnabled.sqf index 5cc5b60aa3..d6150e13a1 100644 --- a/addons/medical/functions/fnc_hasMedicalEnabled.sqf +++ b/addons/medical/functions/fnc_hasMedicalEnabled.sqf @@ -1,4 +1,3 @@ - /* * Author: Glowbal * Check if unit has CMS enabled @@ -14,6 +13,7 @@ * * Public: No */ + #include "script_component.hpp" params ["_unit"]; diff --git a/addons/medical/functions/fnc_hasTourniquetAppliedTo.sqf b/addons/medical/functions/fnc_hasTourniquetAppliedTo.sqf index abbe512d74..ba4aecefa3 100644 --- a/addons/medical/functions/fnc_hasTourniquetAppliedTo.sqf +++ b/addons/medical/functions/fnc_hasTourniquetAppliedTo.sqf @@ -6,9 +6,12 @@ * 0: The Unit * 1: SelectionName * - * ReturnValue: + * Return Value: * Has tourniquet applied * + * Example: + * [bob, "leg"] call ace_medical_fnc_hasTourniquetAppliedTo + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_init.sqf b/addons/medical/functions/fnc_init.sqf index d6db3db392..82b6b435e6 100644 --- a/addons/medical/functions/fnc_init.sqf +++ b/addons/medical/functions/fnc_init.sqf @@ -5,8 +5,11 @@ * Arguments: * 0: The Unit * - * ReturnValue: - * nil + * Return Value: + * None + * + * Example: + * [bob] call ACE_medical_fnc_init * * Public: No */ diff --git a/addons/medical/functions/fnc_isInMedicalFacility.sqf b/addons/medical/functions/fnc_isInMedicalFacility.sqf index 313ee8eca4..12e52ada19 100644 --- a/addons/medical/functions/fnc_isInMedicalFacility.sqf +++ b/addons/medical/functions/fnc_isInMedicalFacility.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: The Unit * - * ReturnValue: + * Return Value: * Is in medical facility * * Example: diff --git a/addons/medical/functions/fnc_isInStableCondition.sqf b/addons/medical/functions/fnc_isInStableCondition.sqf index a11e40dd31..078079e46e 100644 --- a/addons/medical/functions/fnc_isInStableCondition.sqf +++ b/addons/medical/functions/fnc_isInStableCondition.sqf @@ -1,15 +1,18 @@ /* -* Author: Glowbal -* Check if a unit is in a stable condition -* -* Arguments: -* 0: The patient -* -* Return Value: -* Is in stable condition -* -* Public: No -*/ + * Author: Glowbal + * Check if a unit is in a stable condition + * + * Arguments: + * 0: The patient + * + * Return Value: + * Is in stable condition + * + * Example: + * [bob] call ACE_medical_fnc_isInStableCondition + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_isMedic.sqf b/addons/medical/functions/fnc_isMedic.sqf index ff5a1b24a9..9d93f50c74 100644 --- a/addons/medical/functions/fnc_isMedic.sqf +++ b/addons/medical/functions/fnc_isMedic.sqf @@ -6,7 +6,7 @@ * 0: The Unit * 1: Class (default: 1) * - * ReturnValue: + * Return Value: * Is in of medic class * * Example: diff --git a/addons/medical/functions/fnc_isMedicalVehicle.sqf b/addons/medical/functions/fnc_isMedicalVehicle.sqf index 14499cb241..66ecf84a07 100644 --- a/addons/medical/functions/fnc_isMedicalVehicle.sqf +++ b/addons/medical/functions/fnc_isMedicalVehicle.sqf @@ -5,11 +5,15 @@ * Arguments: * 0: The Vehicle * - * ReturnValue: + * Return Value: * Is in of medic class * + * Example: + * [car] call ace_medical_fnc_isMedicalVehicle + * * Public: Yes */ + #include "script_component.hpp" params ["_vehicle"]; diff --git a/addons/medical/functions/fnc_itemCheck.sqf b/addons/medical/functions/fnc_itemCheck.sqf index d49e04e774..6ab1e490c3 100644 --- a/addons/medical/functions/fnc_itemCheck.sqf +++ b/addons/medical/functions/fnc_itemCheck.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The unit * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob] call ace_medical_fnc_itemCheck + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_litterCleanupLoop.sqf b/addons/medical/functions/fnc_litterCleanupLoop.sqf index 417144dd64..6f546b47ed 100644 --- a/addons/medical/functions/fnc_litterCleanupLoop.sqf +++ b/addons/medical/functions/fnc_litterCleanupLoop.sqf @@ -5,9 +5,12 @@ * Arguments: * None * - * ReturnValue: + * Return Value: * None * + * Example: + * call ACE_medical_fnc_litterCleanupLoop + * * Public: No */ diff --git a/addons/medical/functions/fnc_medicationEffectLoop.sqf b/addons/medical/functions/fnc_medicationEffectLoop.sqf index 00ef00a82c..c1690806fe 100644 --- a/addons/medical/functions/fnc_medicationEffectLoop.sqf +++ b/addons/medical/functions/fnc_medicationEffectLoop.sqf @@ -10,9 +10,12 @@ * 4: Viscosity adjustment rate * 5: Pain reduction rate * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, "leg", 1, 2, 3, 4] call ACE_medical_fnc_medicationEffectLoop + * * Public: No */ diff --git a/addons/medical/functions/fnc_modifyMedicalAction.sqf b/addons/medical/functions/fnc_modifyMedicalAction.sqf index 4d0db7af34..1da4ed20c0 100644 --- a/addons/medical/functions/fnc_modifyMedicalAction.sqf +++ b/addons/medical/functions/fnc_modifyMedicalAction.sqf @@ -9,9 +9,12 @@ * 2: Selection Number * 3: The action to modify * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, kevin, 2, "action"] call ACE_medical_fnc_modifyMedicalAction + * * Public: No */ diff --git a/addons/medical/functions/fnc_moduleAdvancedMedicalSettings.sqf b/addons/medical/functions/fnc_moduleAdvancedMedicalSettings.sqf index b54196d75f..b884e8b82d 100644 --- a/addons/medical/functions/fnc_moduleAdvancedMedicalSettings.sqf +++ b/addons/medical/functions/fnc_moduleAdvancedMedicalSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ACE_medical_fnc_moduleAdvancedMedicalSettings + * * Public: No */ diff --git a/addons/medical/functions/fnc_moduleAssignMedicRoles.sqf b/addons/medical/functions/fnc_moduleAssignMedicRoles.sqf index 5bdaccff93..51a4be7461 100644 --- a/addons/medical/functions/fnc_moduleAssignMedicRoles.sqf +++ b/addons/medical/functions/fnc_moduleAssignMedicRoles.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ACE_medical_fnc_moduleAssignMedicRoles + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_moduleAssignMedicalFacility.sqf b/addons/medical/functions/fnc_moduleAssignMedicalFacility.sqf index 368b065908..97dcc35a6b 100644 --- a/addons/medical/functions/fnc_moduleAssignMedicalFacility.sqf +++ b/addons/medical/functions/fnc_moduleAssignMedicalFacility.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [kevin, bob], true] call ACE_medical_fnc_moduleAssignMedicalFacility + * * Public: No */ diff --git a/addons/medical/functions/fnc_moduleAssignMedicalVehicle.sqf b/addons/medical/functions/fnc_moduleAssignMedicalVehicle.sqf index 60a46f8420..4d7576f2c2 100644 --- a/addons/medical/functions/fnc_moduleAssignMedicalVehicle.sqf +++ b/addons/medical/functions/fnc_moduleAssignMedicalVehicle.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ACE_medical_fnc_moduleAssignMedicalVehicle + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_moduleBasicMedicalSettings.sqf b/addons/medical/functions/fnc_moduleBasicMedicalSettings.sqf index 08076878f2..c73d49458b 100644 --- a/addons/medical/functions/fnc_moduleBasicMedicalSettings.sqf +++ b/addons/medical/functions/fnc_moduleBasicMedicalSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [Logic, [bob, kevin], true] call ACE_medical_fnc_moduleBasicMedicalSettings + * * Public: No */ diff --git a/addons/medical/functions/fnc_moduleMedicalSettings.sqf b/addons/medical/functions/fnc_moduleMedicalSettings.sqf index 29398bbc35..148183ea22 100644 --- a/addons/medical/functions/fnc_moduleMedicalSettings.sqf +++ b/addons/medical/functions/fnc_moduleMedicalSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ACE_medical_fnc_moduleMedicalSettings + * * Public: No */ diff --git a/addons/medical/functions/fnc_moduleReviveSettings.sqf b/addons/medical/functions/fnc_moduleReviveSettings.sqf index 19aa9579dd..de9e53820c 100644 --- a/addons/medical/functions/fnc_moduleReviveSettings.sqf +++ b/addons/medical/functions/fnc_moduleReviveSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ACE_medical_fnc_moduleReviveSettings + * * Public: No */ diff --git a/addons/medical/functions/fnc_onMedicationUsage.sqf b/addons/medical/functions/fnc_onMedicationUsage.sqf index 019abd094c..95e7d0bf5e 100644 --- a/addons/medical/functions/fnc_onMedicationUsage.sqf +++ b/addons/medical/functions/fnc_onMedicationUsage.sqf @@ -13,6 +13,9 @@ * Return Value: * None * + * Example: + * [bob, "classname", "varname", 5, 6, ["stuff"]] call ACE_medical_fnc_onMedicationUsage + * * Public: No */ diff --git a/addons/medical/functions/fnc_parseConfigForInjuries.sqf b/addons/medical/functions/fnc_parseConfigForInjuries.sqf index 42dd98dc1f..c3ef815e74 100644 --- a/addons/medical/functions/fnc_parseConfigForInjuries.sqf +++ b/addons/medical/functions/fnc_parseConfigForInjuries.sqf @@ -4,9 +4,13 @@ * * Arguments: * None - * ReturnValue: + * + * Return Value: * None * + * Example: + * call ACE_medical_fnc_parseConfigForInjuries + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_playInjuredSound.sqf b/addons/medical/functions/fnc_playInjuredSound.sqf index 2e5ec2ab5f..629b600d49 100644 --- a/addons/medical/functions/fnc_playInjuredSound.sqf +++ b/addons/medical/functions/fnc_playInjuredSound.sqf @@ -8,9 +8,12 @@ * 0: The Unit * 1: Amount of Pain * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, 5] call ACE_medical_fnc_playInjuredSound + * * Public: No */ diff --git a/addons/medical/functions/fnc_reviveStateLoop.sqf b/addons/medical/functions/fnc_reviveStateLoop.sqf index 5dcaad09c4..0ec5f78c85 100644 --- a/addons/medical/functions/fnc_reviveStateLoop.sqf +++ b/addons/medical/functions/fnc_reviveStateLoop.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: Unit * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob] call ACE_medical_fnc_reviveStateLoop + * * Public: No */ diff --git a/addons/medical/functions/fnc_selectionNameToNumber.sqf b/addons/medical/functions/fnc_selectionNameToNumber.sqf index 1e8d79183f..441f4bb31e 100644 --- a/addons/medical/functions/fnc_selectionNameToNumber.sqf +++ b/addons/medical/functions/fnc_selectionNameToNumber.sqf @@ -5,9 +5,12 @@ * Arguments: * 0: The selection name of a unit * - * ReturnValue: + * Return Value: * Number representation. -1 if invalid. * + * Example: + * ["head"] call ace_medical_fnc_selectionNameToNumber + * * Public: yes */ diff --git a/addons/medical/functions/fnc_serverRemoveBody.sqf b/addons/medical/functions/fnc_serverRemoveBody.sqf index f68ffd95cd..3c1bfe90a1 100644 --- a/addons/medical/functions/fnc_serverRemoveBody.sqf +++ b/addons/medical/functions/fnc_serverRemoveBody.sqf @@ -7,7 +7,7 @@ * 0: Mr Body * * Return Value: - * Nothing + * None * * Example: * [cursorTarget] call ace_medical_fnc_serverRemoveBody diff --git a/addons/medical/functions/fnc_setCardiacArrest.sqf b/addons/medical/functions/fnc_setCardiacArrest.sqf index 69bda192dd..5b97b3d50b 100644 --- a/addons/medical/functions/fnc_setCardiacArrest.sqf +++ b/addons/medical/functions/fnc_setCardiacArrest.sqf @@ -6,9 +6,12 @@ * Arguments: * 0: The unit that will be put in cardiac arrest state * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob] call ace_medical_fnc_setCardiacArrest + * * Public: yes */ diff --git a/addons/medical/functions/fnc_setDead.sqf b/addons/medical/functions/fnc_setDead.sqf index 0e5fd884f4..fcc8b42235 100644 --- a/addons/medical/functions/fnc_setDead.sqf +++ b/addons/medical/functions/fnc_setDead.sqf @@ -4,12 +4,15 @@ * * Arguments: * 0: The unit that will be killed - * 1: Force Dead (ignore revive setting) - * 1: Delay setDamage for a frame + * 1: Force Dead (ignore revive setting) (default: false) + * 1: Delay setDamage for a frame (default: false) * - * ReturnValue: + * Return Value: * Did he died? * + * Example: + * [bob, false, false] call ace_medical_fnc_setDead + * * Public: yes */ diff --git a/addons/medical/functions/fnc_setHitPointDamage.sqf b/addons/medical/functions/fnc_setHitPointDamage.sqf index b1dfe59d29..16daee5e5d 100644 --- a/addons/medical/functions/fnc_setHitPointDamage.sqf +++ b/addons/medical/functions/fnc_setHitPointDamage.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [medic, "Leg", 2, false] call ace_medical_fnc_setHitPointDamage + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_setStructuralDamage.sqf b/addons/medical/functions/fnc_setStructuralDamage.sqf index ba30b08153..4f8c6e2613 100644 --- a/addons/medical/functions/fnc_setStructuralDamage.sqf +++ b/addons/medical/functions/fnc_setStructuralDamage.sqf @@ -5,8 +5,11 @@ * Arguments: * 0: The unit * - * ReturnValue: - * + * Return Value: + * None + * + * Example: + * [bob] call ACE_medical_fnc_setStructuralDamage * * Public: no? */ diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index 5bee0967ba..c2d503ceee 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -8,8 +8,8 @@ * 2: Minimum unconscious time (default: (round(random(10)+5))) * 3: Force AI Unconscious (skip random death chance) (default: false) * - * ReturnValue: - * nil + * Return Value: + * None * * Example: * [bob, true] call ace_medical_fnc_setUnconscious; diff --git a/addons/medical/functions/fnc_showBloodEffect.sqf b/addons/medical/functions/fnc_showBloodEffect.sqf index 8ed77714cb..2e2a282884 100644 --- a/addons/medical/functions/fnc_showBloodEffect.sqf +++ b/addons/medical/functions/fnc_showBloodEffect.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [2] call ace_medical_fnc_showBloodEffect + * * Public: Yes */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_treatment.sqf b/addons/medical/functions/fnc_treatment.sqf index 453d074f98..f5c0d6a1bb 100644 --- a/addons/medical/functions/fnc_treatment.sqf +++ b/addons/medical/functions/fnc_treatment.sqf @@ -11,6 +11,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [medic, patient, "SelectionName","bandage"] call ace_medical_fnc_treatment + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentAdvanced_CPR.sqf b/addons/medical/functions/fnc_treatmentAdvanced_CPR.sqf index 0ce1f7d4d9..aedcffdb49 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_CPR.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_CPR.sqf @@ -11,6 +11,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [medic, patient, "selectionName", "bandage"] call ace_medical_fnc_treatmentAdvanced_CPR + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentAdvanced_CPRLocal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_CPRLocal.sqf index fbc7aac601..a893feedef 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_CPRLocal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_CPRLocal.sqf @@ -9,6 +9,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [medic, patient] call ace_medical_fnc_treatmentAdvanced_CPRLocal + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentAdvanced_bandage.sqf b/addons/medical/functions/fnc_treatmentAdvanced_bandage.sqf index 0db3e641b3..0dd9742c08 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_bandage.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_bandage.sqf @@ -13,6 +13,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [medic, patient, "Selectionname", "bandage", "bandage", -1] call ace_medical_fnc_treatmentAdvanced_bandage + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf index a9f26ca2fd..c581d4ddbe 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf @@ -10,6 +10,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [bob, "classname"] call ACE_medical_fnc_treatmentAdvanced_bandageLocal + * * Public: No */ diff --git a/addons/medical/functions/fnc_treatmentAdvanced_fullHeal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_fullHeal.sqf index 18bd0468d2..5b20863338 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_fullHeal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_fullHeal.sqf @@ -1,11 +1,21 @@ -/** - * fn_heal.sqf - * @Descr: N/A - * @Author: Glowbal +/* + * Author: Glowbal * - * @Arguments: [] - * @Return: - * @PublicAPI: false + * + * Arguments: + * 0: Caller + * 1: Target + * 2: SelectionName + * 3: ClassName + * 4: Item + * + * Return Value: + * Boolean + * + * Example: + * [bob, kevin, "selection", "classname", ] call ACE_medical_fnc_treatmentAdvanced_fullHeal + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_treatmentAdvanced_fullHealLocal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_fullHealLocal.sqf index 67cbcad1d3..bd31e58ba9 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_fullHealLocal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_fullHealLocal.sqf @@ -1,11 +1,18 @@ -/** - * fn_healLocal.sqf - * @Descr: N/A - * @Author: Glowbal +/* + * Author: Glowbal * - * @Arguments: [] - * @Return: - * @PublicAPI: false + * + * Arguments: + * 0: Caller + * 1: Target + * + * Return Value: + * Boolean + * + * Example: + * [bob, kevin] call ACE_medical_fnc_treatmentAdvanced_fullHealLocal + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_treatmentAdvanced_medication.sqf b/addons/medical/functions/fnc_treatmentAdvanced_medication.sqf index ceb788f571..a58ded3de3 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_medication.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_medication.sqf @@ -12,6 +12,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [medic, patient, "selectionName", "bandage", 2] call ace_medical_fnc_treatmentAdvanced_medication + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentAdvanced_medicationLocal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_medicationLocal.sqf index 46a8b9c2a8..32b7e9d2c1 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_medicationLocal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_medicationLocal.sqf @@ -10,6 +10,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [medic, "bandage", 2] call ace_medical_fnc_treatmentAdvanced_medicationLocal + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentAdvanced_surgicalKit_onProgress.sqf b/addons/medical/functions/fnc_treatmentAdvanced_surgicalKit_onProgress.sqf index 0a1e48288f..a73661ac77 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_surgicalKit_onProgress.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_surgicalKit_onProgress.sqf @@ -12,6 +12,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [[bob, kevin], 5, 5] call ACE_medical_fnc_treatmentAdvanced_surgicalKit_onProgress + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_treatmentBasic_bloodbag.sqf b/addons/medical/functions/fnc_treatmentBasic_bloodbag.sqf index 6989ac14b8..5ef368922d 100644 --- a/addons/medical/functions/fnc_treatmentBasic_bloodbag.sqf +++ b/addons/medical/functions/fnc_treatmentBasic_bloodbag.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, "selection", "classname"] call ACE_medical_fnc_treatmentBasic_bloodbag + * * Public: No */ diff --git a/addons/medical/functions/fnc_treatmentBasic_bloodbagLocal.sqf b/addons/medical/functions/fnc_treatmentBasic_bloodbagLocal.sqf index cb4dcf032c..1e56eb3d88 100644 --- a/addons/medical/functions/fnc_treatmentBasic_bloodbagLocal.sqf +++ b/addons/medical/functions/fnc_treatmentBasic_bloodbagLocal.sqf @@ -7,7 +7,10 @@ * 1: Treatment Classname * * Return Value: - * nil + * None + * + * Example: + * [bob, "classname"] call ACE_medical_fnc_treatmentBasic_bloodbagLocal * * Public: No */ diff --git a/addons/medical/functions/fnc_treatmentBasic_epipen.sqf b/addons/medical/functions/fnc_treatmentBasic_epipen.sqf index 1abee1cd58..161626bb41 100644 --- a/addons/medical/functions/fnc_treatmentBasic_epipen.sqf +++ b/addons/medical/functions/fnc_treatmentBasic_epipen.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, "selection", "classname"] call ACE_medical_fnc_treatmentBasic_epipen + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_treatmentBasic_morphine.sqf b/addons/medical/functions/fnc_treatmentBasic_morphine.sqf index f704a67042..f011ab41a2 100644 --- a/addons/medical/functions/fnc_treatmentBasic_morphine.sqf +++ b/addons/medical/functions/fnc_treatmentBasic_morphine.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, "selection", "classname"] call ACE_medical_fnc_treatmentBasic_morphine + * * Public: No */ diff --git a/addons/medical/functions/fnc_treatmentBasic_morphineLocal.sqf b/addons/medical/functions/fnc_treatmentBasic_morphineLocal.sqf index bb670c75bd..f24719d352 100644 --- a/addons/medical/functions/fnc_treatmentBasic_morphineLocal.sqf +++ b/addons/medical/functions/fnc_treatmentBasic_morphineLocal.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ACE_medical_fnc_treatmentBasic_morphineLocal + * * Public: No */ diff --git a/addons/medical/functions/fnc_treatmentIV.sqf b/addons/medical/functions/fnc_treatmentIV.sqf index 7b16fad650..a393acbb13 100644 --- a/addons/medical/functions/fnc_treatmentIV.sqf +++ b/addons/medical/functions/fnc_treatmentIV.sqf @@ -11,6 +11,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [medic, patient, "SelectionName", "bandage"] call ace_medical_fnc_treatmentIV + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentIVLocal.sqf b/addons/medical/functions/fnc_treatmentIVLocal.sqf index 1324d5aac2..63d8292b0f 100644 --- a/addons/medical/functions/fnc_treatmentIVLocal.sqf +++ b/addons/medical/functions/fnc_treatmentIVLocal.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [medic, "Classname"] call ace_medical_fnc_treatmentIVLocal + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_treatmentTourniquet.sqf b/addons/medical/functions/fnc_treatmentTourniquet.sqf index 3fa34a58aa..cb7e6d21d0 100644 --- a/addons/medical/functions/fnc_treatmentTourniquet.sqf +++ b/addons/medical/functions/fnc_treatmentTourniquet.sqf @@ -12,6 +12,9 @@ * Return Value: * Succesful treatment started * + * Example: + * [bob, kevin, "selection", "classname"] call ACE_medical_fnc_treatmentTourniquet + * * Public: No */ diff --git a/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf b/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf index ab24a94a23..e7e9ff7ca1 100644 --- a/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf +++ b/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, "classname"] call ACE_medical_fnc_treatmentTourniquetLocal + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_treatment_failure.sqf b/addons/medical/functions/fnc_treatment_failure.sqf index bef7d04a02..8ddd8c5cf2 100644 --- a/addons/medical/functions/fnc_treatment_failure.sqf +++ b/addons/medical/functions/fnc_treatment_failure.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, "selectionname", "classname", ["bandage"]] call ACE_medical_fnc_treatment_failure + * * Public: No */ diff --git a/addons/medical/functions/fnc_treatment_success.sqf b/addons/medical/functions/fnc_treatment_success.sqf index 1e0d6c7a4a..3984606e5f 100644 --- a/addons/medical/functions/fnc_treatment_success.sqf +++ b/addons/medical/functions/fnc_treatment_success.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, "selectionname", "classname", ["bandage"]] call ACE_medical_fnc_treatment_success + * * Public: No */ diff --git a/addons/medical/functions/fnc_unconsciousPFH.sqf b/addons/medical/functions/fnc_unconsciousPFH.sqf index 37d54a2ad6..3c5609d85a 100644 --- a/addons/medical/functions/fnc_unconsciousPFH.sqf +++ b/addons/medical/functions/fnc_unconsciousPFH.sqf @@ -3,7 +3,7 @@ * PFH logic for unconscious state * * Arguments: - * 0: PFEH - Args + * 0: PFEH - * 0: The unit that will be put in an unconscious state * 1: unitPos (stance) * 2: Starting Time @@ -12,11 +12,15 @@ * 5: Parachute Check * 1: PFEH ID * - * ReturnValue: + * Return Value: * None * + * Example: + * [[unit,"pos", 5, 5, true, false], 5], "classname"] call ace_medical_fnc_unconsciousPFH + * * Public: yes */ + #include "script_component.hpp" private ["_unit", "_minWaitingTime", "_slotInfo", "_hasMovedOut", "_parachuteCheck", "_args", "_originalPos", "_startingTime", "_awakeInVehicleAnimation", "_oldVehicleAnimation", "_vehicle"]; diff --git a/addons/medical/functions/fnc_useItem.sqf b/addons/medical/functions/fnc_useItem.sqf index 63b3f2a696..ec032a279f 100644 --- a/addons/medical/functions/fnc_useItem.sqf +++ b/addons/medical/functions/fnc_useItem.sqf @@ -7,10 +7,13 @@ * 1: Patient * 2: Item * - * ReturnValue: + * Return Value: * 0: success * 1: Unit * + * Example: + * [unit, patient, "bandage"] call ace_repair_fnc_useItem + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_useItems.sqf b/addons/medical/functions/fnc_useItems.sqf index aac7b0623a..f898ea72f5 100644 --- a/addons/medical/functions/fnc_useItems.sqf +++ b/addons/medical/functions/fnc_useItems.sqf @@ -7,9 +7,12 @@ * 1: Patient * 2: Items > * - * ReturnValue: + * Return Value: * None * + * Example: + * [unit, patient, ["bandage"]] call ace_medical_fnc_useItems + * * Public: Yes */ diff --git a/addons/medical/functions/fnc_vitalLoop.sqf b/addons/medical/functions/fnc_vitalLoop.sqf index 6e5bb7fb2b..a9efa81719 100644 --- a/addons/medical/functions/fnc_vitalLoop.sqf +++ b/addons/medical/functions/fnc_vitalLoop.sqf @@ -6,9 +6,12 @@ * 0: The Unit * 1: Time of last computation * - * ReturnValue: + * Return Value: * None * + * Example: + * [bob, 5] call ACE_medical_fnc_vitalLoop + * * Public: No */ diff --git a/addons/medical_ai/functions/fnc_canRequestMedic.sqf b/addons/medical_ai/functions/fnc_canRequestMedic.sqf index 75a4a0fb32..39a5063f24 100644 --- a/addons/medical_ai/functions/fnc_canRequestMedic.sqf +++ b/addons/medical_ai/functions/fnc_canRequestMedic.sqf @@ -8,6 +8,9 @@ * Return Value: * Can request medic * + * Example: + * call ACE_medical_ai_fnc_canRequestMedic + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical_ai/functions/fnc_healSelf.sqf b/addons/medical_ai/functions/fnc_healSelf.sqf index 3cf8ad75e9..253dcd2a45 100644 --- a/addons/medical_ai/functions/fnc_healSelf.sqf +++ b/addons/medical_ai/functions/fnc_healSelf.sqf @@ -6,7 +6,10 @@ * None * * Return Value: - * Nothing + * None + * + * Example: + * call ACE_medical_ai_fnc_healSelf * * Public: No */ diff --git a/addons/medical_ai/functions/fnc_healUnit.sqf b/addons/medical_ai/functions/fnc_healUnit.sqf index 6ebb0b2e4a..569d62f890 100644 --- a/addons/medical_ai/functions/fnc_healUnit.sqf +++ b/addons/medical_ai/functions/fnc_healUnit.sqf @@ -6,7 +6,10 @@ * None * * Return Value: - * Nothing + * None + * + * Example: + * call ACE_medical_ai_fnc_healUnit * * Public: No */ diff --git a/addons/medical_ai/functions/fnc_isInjured.sqf b/addons/medical_ai/functions/fnc_isInjured.sqf index 6852fc1c58..4c25ba72a1 100644 --- a/addons/medical_ai/functions/fnc_isInjured.sqf +++ b/addons/medical_ai/functions/fnc_isInjured.sqf @@ -8,6 +8,9 @@ * Return Value: * Does unit need treatment * + * Example: + * call ACE_medical_ai_fnc_isInjured + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical_ai/functions/fnc_isSafe.sqf b/addons/medical_ai/functions/fnc_isSafe.sqf index 92bbc60587..de7d9667cc 100644 --- a/addons/medical_ai/functions/fnc_isSafe.sqf +++ b/addons/medical_ai/functions/fnc_isSafe.sqf @@ -8,6 +8,9 @@ * Return Value: * Is unit safe enough * + * Example: + * call ACE_medical_ai_fnc_isSafe + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical_ai/functions/fnc_playTreatmentAnim.sqf b/addons/medical_ai/functions/fnc_playTreatmentAnim.sqf index f013486cc1..de2c0ee30e 100644 --- a/addons/medical_ai/functions/fnc_playTreatmentAnim.sqf +++ b/addons/medical_ai/functions/fnc_playTreatmentAnim.sqf @@ -8,7 +8,10 @@ * 2: Is self treatment * * Return Value: - * Nothing + * None + * + * Example: + * [bob, true, true] call ACE_medical_ai_fnc_playTreatmentAnim * * Public: No */ diff --git a/addons/medical_ai/functions/fnc_requestMedic.sqf b/addons/medical_ai/functions/fnc_requestMedic.sqf index f669b06975..6bb3229e9a 100644 --- a/addons/medical_ai/functions/fnc_requestMedic.sqf +++ b/addons/medical_ai/functions/fnc_requestMedic.sqf @@ -6,7 +6,10 @@ * None * * Return Value: - * Nothing + * None + * + * Example: + * call ACE_medical_ai_fnc_requestMedic * * Public: No */ diff --git a/addons/medical_ai/functions/fnc_wasRequested.sqf b/addons/medical_ai/functions/fnc_wasRequested.sqf index 2b86423be8..c340ff7b9e 100644 --- a/addons/medical_ai/functions/fnc_wasRequested.sqf +++ b/addons/medical_ai/functions/fnc_wasRequested.sqf @@ -8,6 +8,9 @@ * Return Value: * Was requested * + * Example: + * call ACE_medical_ai_fnc_wasRequested + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical_blood/functions/fnc_hit.sqf b/addons/medical_blood/functions/fnc_hit.sqf index 1572b2e5a1..3c0251a437 100644 --- a/addons/medical_blood/functions/fnc_hit.sqf +++ b/addons/medical_blood/functions/fnc_hit.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, 5] call ACE_medical_blood_fnc_hit + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical_menu/functions/fnc_getTreatmentOptions.sqf b/addons/medical_menu/functions/fnc_getTreatmentOptions.sqf index 6fed994671..80b43bae3c 100644 --- a/addons/medical_menu/functions/fnc_getTreatmentOptions.sqf +++ b/addons/medical_menu/functions/fnc_getTreatmentOptions.sqf @@ -10,7 +10,7 @@ * Return Value: * Available actions * - * Exmaple: + * Example: * [ACE_player, poor_dude, "some category"] call ace_medical_menu_fnc_getTreatmentOptions * * Public: No diff --git a/addons/medical_menu/functions/fnc_module.sqf b/addons/medical_menu/functions/fnc_module.sqf index 666440e208..f056082743 100644 --- a/addons/medical_menu/functions/fnc_module.sqf +++ b/addons/medical_menu/functions/fnc_module.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ACE_medical_menu_fnc_module + * * Public: No */ diff --git a/addons/medical_menu/functions/fnc_setTriageStatus.sqf b/addons/medical_menu/functions/fnc_setTriageStatus.sqf index 8a85eeb950..66efd6ac0c 100644 --- a/addons/medical_menu/functions/fnc_setTriageStatus.sqf +++ b/addons/medical_menu/functions/fnc_setTriageStatus.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, 2] call ACE_medical_menu_fnc_setTriageStatus + * * Public: No */ #include "script_component.hpp" diff --git a/addons/medical_menu/functions/fnc_updateInformationLists.sqf b/addons/medical_menu/functions/fnc_updateInformationLists.sqf index 28818465bc..d6ff631df8 100644 --- a/addons/medical_menu/functions/fnc_updateInformationLists.sqf +++ b/addons/medical_menu/functions/fnc_updateInformationLists.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [DISPLAY, [messagecollection], [injurycollection]] call ACE_medical_menu_fnc_updateInformationLists + * * Public: No */ #include "script_component.hpp" diff --git a/addons/minedetector/functions/fnc_detectorLoop.sqf b/addons/minedetector/functions/fnc_detectorLoop.sqf index e5fd4d5bd3..ef05046881 100644 --- a/addons/minedetector/functions/fnc_detectorLoop.sqf +++ b/addons/minedetector/functions/fnc_detectorLoop.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [[args], 2] call ACE_minedetector_fnc_detectorLoop + * * Public: No */ diff --git a/addons/missileguidance/functions/fnc_cycleAttackProfileKeyDown.sqf b/addons/missileguidance/functions/fnc_cycleAttackProfileKeyDown.sqf index dcc9d7c607..a878924ed5 100644 --- a/addons/missileguidance/functions/fnc_cycleAttackProfileKeyDown.sqf +++ b/addons/missileguidance/functions/fnc_cycleAttackProfileKeyDown.sqf @@ -13,6 +13,7 @@ * * Public: No */ + // #define DEBUG_MODE_FULL #include "script_component.hpp" diff --git a/addons/missileguidance/functions/fnc_doHandoff.sqf b/addons/missileguidance/functions/fnc_doHandoff.sqf index db722713e1..2145b4e585 100644 --- a/addons/missileguidance/functions/fnc_doHandoff.sqf +++ b/addons/missileguidance/functions/fnc_doHandoff.sqf @@ -1,4 +1,20 @@ -// Not currently used +/* + * Author: ACE + * Not currently used + * + * Arguments: + * 0: Target + * 1: Args + * + * Return Value: + * None + * + * Example: + * [target, [args]] call ace_missileguidance_fnc_doHandoff + * + * Public: No + */ + #include "script_component.hpp" PARAMS_2(_target,_args); diff --git a/addons/missileguidance/functions/fnc_guidancePFH.sqf b/addons/missileguidance/functions/fnc_guidancePFH.sqf index 45db7c536b..5ecb9c6dfe 100644 --- a/addons/missileguidance/functions/fnc_guidancePFH.sqf +++ b/addons/missileguidance/functions/fnc_guidancePFH.sqf @@ -7,7 +7,7 @@ * 1: PFID * * Return Value: - * Nothing + * None * * Example: * [[], 0] call ace_missileguidance_fnc_guidancePFH; @@ -54,7 +54,7 @@ private _seekerTargetPos = [[0,0,0], _args, _seekerStateParams, _lastKnownPosSta // Run attack profile function: private _profileAdjustedTargetPos = [_seekerTargetPos, _args, _attackProfileStateParams] call FUNC(doAttackProfile); - + // If we have no seeker target, then do not change anything if (!(_profileAdjustedTargetPos isEqualTo [0,0,0])) then { @@ -111,4 +111,4 @@ _PS setDropInterval 3.0; _stateParams set [0, diag_tickTime]; END_COUNTER(guidancePFH); - + diff --git a/addons/missileguidance/functions/fnc_handleHandoff.sqf b/addons/missileguidance/functions/fnc_handleHandoff.sqf index 25c01694eb..63af6d6901 100644 --- a/addons/missileguidance/functions/fnc_handleHandoff.sqf +++ b/addons/missileguidance/functions/fnc_handleHandoff.sqf @@ -1,4 +1,20 @@ -// Not currently used +/* + * Author: ACE-Team + * Not currently used + * + * Arguments: + * 0: TARGET + * 1: ARGS + * + * Return Value: + * Boolean + * + * Example: + * [bob, kevin] call ACE_missileguidance_fnc_handleHandoff + * + * Public: No + */ + #include "script_component.hpp" PARAMS_2(_target,_args); diff --git a/addons/missileguidance/functions/fnc_onFired.sqf b/addons/missileguidance/functions/fnc_onFired.sqf index bf7d81331e..bf256cbba0 100644 --- a/addons/missileguidance/functions/fnc_onFired.sqf +++ b/addons/missileguidance/functions/fnc_onFired.sqf @@ -8,7 +8,7 @@ * 6: Projectile * * Return Value: - * Nothing + * None * * Example: * [player, "", "", "", "ACE_Javelin_FGM148", "", theMissile] call ace_missileguidance_fnc_onFired; diff --git a/addons/missionmodules/functions/fnc_moduleAmbianceSound.sqf b/addons/missionmodules/functions/fnc_moduleAmbianceSound.sqf index 300def5dc7..dc6ca4c7b1 100644 --- a/addons/missionmodules/functions/fnc_moduleAmbianceSound.sqf +++ b/addons/missionmodules/functions/fnc_moduleAmbianceSound.sqf @@ -8,10 +8,10 @@ * 2: Activated * * Return Value: - * Nothing + * None * * Example: - * N/A + * [LOGIC, [bob, kevin], true] call ace_missionmodules_fnc_moduleAmbianceSound * * Public: No */ diff --git a/addons/mk6mortar/functions/fnc_dev_buildTable.sqf b/addons/mk6mortar/functions/fnc_dev_buildTable.sqf index 84184fcb51..1f648ead4a 100644 --- a/addons/mk6mortar/functions/fnc_dev_buildTable.sqf +++ b/addons/mk6mortar/functions/fnc_dev_buildTable.sqf @@ -7,7 +7,7 @@ * 1: Air Friction * * Return Value: - * + * None * * Example: * [100, -0.0001] spawn ace_mk6mortar_fnc_dev_buildTable; //spawn (scheduled) is slower @@ -84,4 +84,4 @@ _outputString = format ["case ((abs(_muzzleVelocity - %1) < 0.00001) && {(abs(_a copyToClipboard _outputString; rangeTableOutput = _outputString; -hint "done"; \ No newline at end of file +hint "done"; diff --git a/addons/mk6mortar/functions/fnc_dev_formatNumber.sqf b/addons/mk6mortar/functions/fnc_dev_formatNumber.sqf index f89c3a1b8f..3e70e0f917 100644 --- a/addons/mk6mortar/functions/fnc_dev_formatNumber.sqf +++ b/addons/mk6mortar/functions/fnc_dev_formatNumber.sqf @@ -1,19 +1,19 @@ /* -Author: Pabst Mirror - -Description: -Converts numbers into nicely formated strings. - -Parameters: -0: NUMBER - Input number -1: STRING - Output type (see case statement) -2: BOOL - If output type is mil, convert input type from deg->mil - -Returns: -STRING - Formatted number - -Example: -[45, "mil4", true] call ace_mk6mortar_fnc_dev_formatNumber = "0800" + * Author: Pabst Mirror + * Converts numbers into nicely formated strings. + * + * Arguments: + * 0: Input number + * 1: Output type (see case statement) + * 2: If output type is mil, convert input type from deg->mil + * + * Return Value: + * Formatted number + * + * Example: + * [45, "mil4", true] call ace_mk6mortar_fnc_dev_formatNumber = "0800" + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/mk6mortar/functions/fnc_dev_simulateCalcRangeTableLine.sqf b/addons/mk6mortar/functions/fnc_dev_simulateCalcRangeTableLine.sqf index d1e0a8dd05..8a9c6d1a98 100644 --- a/addons/mk6mortar/functions/fnc_dev_simulateCalcRangeTableLine.sqf +++ b/addons/mk6mortar/functions/fnc_dev_simulateCalcRangeTableLine.sqf @@ -1,19 +1,19 @@ /* -Author: Pabst Mirror - -Description: -Builds a rangeTable line for a certian range, given muzzle velocity and air friction, returns [] if out of range. - -Parameters: -0: NUMBER - Muzzle Velocity -1: NUMBER - Air Friction -2: NUMBER - Range To Hit - -Returns: -ARRAY - Range Table Line Data (see return line) - -Example: -[300, -0.0001, 3000] call ace_mk6mortar_fnc_simulateCalcRangeTableLine + * Author: Pabst Mirror + * Builds a rangeTable line for a certian range, given muzzle velocity and air friction, returns [] if out of range. + * + * Arguments: + * 0: Muzzle Velocity + * 1: Air Friction + * 2: Range To Hit + * + * Return Value: + * Range Table Line Data (see return line) + * + * Example: + * [300, -0.0001, 3000] call ace_mk6mortar_fnc_simulateCalcRangeTableLine + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/mk6mortar/functions/fnc_dev_simulateFindSolution.sqf b/addons/mk6mortar/functions/fnc_dev_simulateFindSolution.sqf index d302a40f40..29ac0c010a 100644 --- a/addons/mk6mortar/functions/fnc_dev_simulateFindSolution.sqf +++ b/addons/mk6mortar/functions/fnc_dev_simulateFindSolution.sqf @@ -3,14 +3,14 @@ * DEV to find a firing solution for a given range * * Arguments: - * 0: Range to Hit (Meters) - * 1: Height To Hit (Meters) - * 2: Muzzle Velocity (M/S) + * 0: Range to Hit (Meters) + * 1: Height To Hit (Meters) + * 2: Muzzle Velocity (M/S) * 3: Air Friction * 4: Time Step (seconds) (eg 1/50 will simulate 50 cycles per second) * * Return Value: - * ARRAY - [NUMBER - Elevation In Degrees, NUMBER - Shot Durration] + * [NUMBER - Elevation In Degrees, NUMBER - Shot Durration] * * Example: * [_rangeToHit, _heightToHit, _muzzleVelocity, _airFriction, TIME_STEP] call ace_mk6mortar_fnc_dev_simulateFindSolution; diff --git a/addons/mk6mortar/functions/fnc_handleFired.sqf b/addons/mk6mortar/functions/fnc_handleFired.sqf index 483a69d42b..98fa8eebdf 100644 --- a/addons/mk6mortar/functions/fnc_handleFired.sqf +++ b/addons/mk6mortar/functions/fnc_handleFired.sqf @@ -12,7 +12,7 @@ * 6: projectile - Object of the projectile that was shot * * Return Value: - * Nothing + * None * * Example: * [clientFiredBIS-XEH] call ace_mk6mortar_fnc_handleFired diff --git a/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf b/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf index 3f2a8c1f0d..db56f71691 100644 --- a/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf +++ b/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf @@ -7,7 +7,7 @@ * 1: New Vehicle * * Return Value: - * No + * None * * Example: * [bob, mortar] call ace_mk6mortar_fnc_handlePlayerVehicleChanged; diff --git a/addons/mk6mortar/functions/fnc_rangeTableOpen.sqf b/addons/mk6mortar/functions/fnc_rangeTableOpen.sqf index 07e0536d24..0f237e1a37 100644 --- a/addons/mk6mortar/functions/fnc_rangeTableOpen.sqf +++ b/addons/mk6mortar/functions/fnc_rangeTableOpen.sqf @@ -3,10 +3,10 @@ * Opens the rangetable and fills the charge listbox. * * Arguments: - * No + * None * * Return Value: - * No + * None * * Example: * [] call ace_mk6mortar_fnc_rangeTableOpen diff --git a/addons/mk6mortar/functions/fnc_rangeTablePageChange.sqf b/addons/mk6mortar/functions/fnc_rangeTablePageChange.sqf index c0cc40ccdc..1090967e5a 100644 --- a/addons/mk6mortar/functions/fnc_rangeTablePageChange.sqf +++ b/addons/mk6mortar/functions/fnc_rangeTablePageChange.sqf @@ -3,10 +3,10 @@ * Called when listbox selection changes. Updates the rangetable with new values. * * Arguments: - * No + * None * * Return Value: - * No + * None * * Example: * [] call ace_mk6mortar_fnc_rangeTablePageChange diff --git a/addons/mk6mortar/functions/fnc_rangeTablePreCalculatedValues.sqf b/addons/mk6mortar/functions/fnc_rangeTablePreCalculatedValues.sqf index db87cb6000..d035959da4 100644 --- a/addons/mk6mortar/functions/fnc_rangeTablePreCalculatedValues.sqf +++ b/addons/mk6mortar/functions/fnc_rangeTablePreCalculatedValues.sqf @@ -8,7 +8,7 @@ * 1: Air Friction * * Return Value: - * + * Array * * Example: * [200, 0] call ace_mk6mortar_fnc_rangeTablePreCalculatedValues @@ -268,4 +268,4 @@ case ((abs(_muzzleVelocity - 200) < 0.00001) && {(abs(_airFriction - 0) < 0.0000 ERROR("MuzzleVelocity not found in LUT"); [] }; -}; \ No newline at end of file +}; diff --git a/addons/mk6mortar/functions/fnc_toggleMils.sqf b/addons/mk6mortar/functions/fnc_toggleMils.sqf index 5c27bf64e4..075c7c3143 100644 --- a/addons/mk6mortar/functions/fnc_toggleMils.sqf +++ b/addons/mk6mortar/functions/fnc_toggleMils.sqf @@ -7,7 +7,7 @@ * 1: Player * * Return Value: - * No + * None * * Example: * [mortar,bob] call ace_mk6mortar_fnc_toggleMils; diff --git a/addons/modules/functions/fnc_moduleInit.sqf b/addons/modules/functions/fnc_moduleInit.sqf index 5d42b4fa87..e4ab737db3 100644 --- a/addons/modules/functions/fnc_moduleInit.sqf +++ b/addons/modules/functions/fnc_moduleInit.sqf @@ -7,7 +7,10 @@ * * * Return Value: - * nil + * None + * + * Example: + * [LOGIC] call ace_modules_fnc_moduleInit * * Public: No */ diff --git a/addons/movement/functions/fnc_addLoadToUnitContainer.sqf b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf index a79b2ab917..fa788c92a2 100644 --- a/addons/movement/functions/fnc_addLoadToUnitContainer.sqf +++ b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf @@ -10,6 +10,9 @@ * Return Value: * Success? * + * Example: + * [bob, box, 5] call ace_movement_fnc_addLoadToUnitContainer + * * Public: No */ #include "script_component.hpp" diff --git a/addons/movement/functions/fnc_climb.sqf b/addons/movement/functions/fnc_climb.sqf index 57df4e5991..1f2ecf72f4 100644 --- a/addons/movement/functions/fnc_climb.sqf +++ b/addons/movement/functions/fnc_climb.sqf @@ -6,7 +6,7 @@ * 0: The Unit (usually the player) * * Return Value: - * Nothing + * None * * Example: * [player] call ace_movement_fnc_climb diff --git a/addons/movement/functions/fnc_handleClimb.sqf b/addons/movement/functions/fnc_handleClimb.sqf index e6d8fed12c..ed3ff93d7e 100644 --- a/addons/movement/functions/fnc_handleClimb.sqf +++ b/addons/movement/functions/fnc_handleClimb.sqf @@ -7,7 +7,7 @@ * 1: The finisehd animation * * Return Value: - * Nothing + * None * * Example: * [player, "ACE_climb"] call ace_movement_fnc_handleClimb diff --git a/addons/movement/functions/fnc_handleVirtualMass.sqf b/addons/movement/functions/fnc_handleVirtualMass.sqf index 8dc1412c4a..814a0eeecb 100644 --- a/addons/movement/functions/fnc_handleVirtualMass.sqf +++ b/addons/movement/functions/fnc_handleVirtualMass.sqf @@ -6,7 +6,10 @@ * 0: The Unit (usually the player) * * Return Value: - * Nothing + * None + * + * Example: + * [bob] call ace_movement_fnc_handleVirtualMass * * Public: No */ diff --git a/addons/nametags/functions/fnc_getCachedFlags.sqf b/addons/nametags/functions/fnc_getCachedFlags.sqf index 27aaa7af7c..6e1223c8be 100644 --- a/addons/nametags/functions/fnc_getCachedFlags.sqf +++ b/addons/nametags/functions/fnc_getCachedFlags.sqf @@ -6,7 +6,7 @@ * None * * Return Value: - * [_drawName,_drawRank,_enabledTagsNearby,_enabledTagsCursor,_maxDistance] + * [_drawName,_drawRank,_enabledTagsNearby,_enabledTagsCursor,_maxDistance] * * Example: * call ace_nametags_fnc_getCachedFlags diff --git a/addons/nametags/functions/fnc_moduleNameTags.sqf b/addons/nametags/functions/fnc_moduleNameTags.sqf index ca513d0c1f..e1fa1a5dc7 100644 --- a/addons/nametags/functions/fnc_moduleNameTags.sqf +++ b/addons/nametags/functions/fnc_moduleNameTags.sqf @@ -7,6 +7,11 @@ * * Return Value: * None + * + * Example: + * [] call ace_nametags_fnc_moduleNameTags + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/nightvision/functions/fnc_blending.sqf b/addons/nightvision/functions/fnc_blending.sqf index 2616cb83f5..4a858838d3 100644 --- a/addons/nightvision/functions/fnc_blending.sqf +++ b/addons/nightvision/functions/fnc_blending.sqf @@ -6,7 +6,7 @@ * None. Parameters inherited from EFUNC(common,firedEH) * * Return Value: - * Nothing + * Noneg * * Example: * [clientFiredBIS-XEH] call ace_nightvision_fnc_blending diff --git a/addons/nightvision/functions/fnc_changeNVGBrightness.sqf b/addons/nightvision/functions/fnc_changeNVGBrightness.sqf index 04cea0f214..5bb5d52721 100644 --- a/addons/nightvision/functions/fnc_changeNVGBrightness.sqf +++ b/addons/nightvision/functions/fnc_changeNVGBrightness.sqf @@ -7,7 +7,7 @@ * 1: Change in brightness (1 or -1) * * Return Value: - * Nothing + * None * * Example: * [player, 1] call ace_nightvision_fnc_changeNVGBrightness diff --git a/addons/nightvision/functions/fnc_updatePPEffects.sqf b/addons/nightvision/functions/fnc_updatePPEffects.sqf index 9bf8321353..7f4f660bd7 100644 --- a/addons/nightvision/functions/fnc_updatePPEffects.sqf +++ b/addons/nightvision/functions/fnc_updatePPEffects.sqf @@ -3,10 +3,10 @@ * Update the ppEffects everytime something changes * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * [someEvent] call ace_nightvision_fnc_updatePPEffects diff --git a/addons/optics/functions/fnc_handleFired.sqf b/addons/optics/functions/fnc_handleFired.sqf index f1216fb15d..10b21b5042 100644 --- a/addons/optics/functions/fnc_handleFired.sqf +++ b/addons/optics/functions/fnc_handleFired.sqf @@ -1,5 +1,5 @@ /* - * Original Author: Taosenai + * Author: Taosenai * Adapted By: KoffeinFlummi, commy2 * * Animates the scope when firing. Called from the unified fired EH only for the local player. @@ -9,7 +9,13 @@ * * Return Value: * None + * + * Example: + * call ace_optics_fnc_handleFired + * + * Public: No */ + #include "script_component.hpp" //IGNORE_PRIVATE_WARNING ["_unit", "_weapon", "_muzzle", "_mode", "_ammo", "_magazine", "_projectile", "_vehicle", "_gunner", "_turret"]; diff --git a/addons/optics/functions/fnc_onDrawScope.sqf b/addons/optics/functions/fnc_onDrawScope.sqf index fd899b5a02..e3114c8c84 100644 --- a/addons/optics/functions/fnc_onDrawScope.sqf +++ b/addons/optics/functions/fnc_onDrawScope.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * 0: Display + * + * Return Value: + * None + * + * Example: + * [DISPLAY] call ace_optics_fnc_onDrawScope + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/optics/functions/fnc_onDrawScope2D.sqf b/addons/optics/functions/fnc_onDrawScope2D.sqf index e8b26dca65..c429740de0 100644 --- a/addons/optics/functions/fnc_onDrawScope2D.sqf +++ b/addons/optics/functions/fnc_onDrawScope2D.sqf @@ -7,7 +7,7 @@ * 0: Display (RscInGameUI for a weapon) * * Return Value: - * Nothing + * None * * Example: * [ACE_RscWeapon_Arco's Display] call ace_optics_fnc_onDrawScope2D diff --git a/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf b/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf index 633a9aa162..2426bb2f26 100644 --- a/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf +++ b/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf @@ -3,11 +3,14 @@ * * * Arguments: - * none + * None * * Return Value: * None * + * Example: + * call ace_optionsmenu_fnc_moduleAllowConfigExport + * * Public: No */ diff --git a/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf b/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf index 8fd52d8d72..2256620cf6 100644 --- a/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf +++ b/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_optionsmenu_fnc_toggleIncludeClientSettings + * * Public: No */ diff --git a/addons/overheating/functions/fnc_canCheckSpareBarrelsTemperatures.sqf b/addons/overheating/functions/fnc_canCheckSpareBarrelsTemperatures.sqf index 1ac1e04492..ae0dc760d3 100644 --- a/addons/overheating/functions/fnc_canCheckSpareBarrelsTemperatures.sqf +++ b/addons/overheating/functions/fnc_canCheckSpareBarrelsTemperatures.sqf @@ -6,7 +6,10 @@ * 0: Player * * Return Value: - * Bool + * Bool + * + * Example: + * [bob] call ace_overheating_fnc_canCheckSpareBarrelsTemperatures * * Public: No */ diff --git a/addons/overheating/functions/fnc_canSwapBarrel.sqf b/addons/overheating/functions/fnc_canSwapBarrel.sqf index e183490439..560183e382 100644 --- a/addons/overheating/functions/fnc_canSwapBarrel.sqf +++ b/addons/overheating/functions/fnc_canSwapBarrel.sqf @@ -5,8 +5,12 @@ * Arguments: * 0: Player * 1: Weapon + * * Return Value: - * Bool + * Bool + * + * Example: + * [bob, "weapon"] call ace_overheating_fnc_canSwapBarrel * * Public: No */ @@ -23,4 +27,4 @@ if(_weaponBarrelClass == "") then { _weaponBarrelClass = "ACE_SpareBarrel"; }; //If the player has the spare barrel then it can be swapped -(_weaponBarrelClass in magazines _unit) \ No newline at end of file +(_weaponBarrelClass in magazines _unit) diff --git a/addons/overheating/functions/fnc_canUnjam.sqf b/addons/overheating/functions/fnc_canUnjam.sqf index 610fa9ca22..f2ab7e8cc6 100644 --- a/addons/overheating/functions/fnc_canUnjam.sqf +++ b/addons/overheating/functions/fnc_canUnjam.sqf @@ -6,7 +6,10 @@ * 0: Player * * Return Value: - * Bool + * Bool + * + * Example: + * [bob] call ace_overheating_fnc_canUnjam * * Public: No */ diff --git a/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf b/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf index 8a634409ee..a0c0ba12de 100644 --- a/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf +++ b/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_overheating_fnc_checkSpareBarrelsTemperature + * * * Public: No */ diff --git a/addons/overheating/functions/fnc_firedEH.sqf b/addons/overheating/functions/fnc_firedEH.sqf index f46af66358..d690b85aa7 100644 --- a/addons/overheating/functions/fnc_firedEH.sqf +++ b/addons/overheating/functions/fnc_firedEH.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_overheating_fnc_firedEH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/overheating/functions/fnc_getWeaponData.sqf b/addons/overheating/functions/fnc_getWeaponData.sqf index d1a9bdc8bb..21f6f156b8 100644 --- a/addons/overheating/functions/fnc_getWeaponData.sqf +++ b/addons/overheating/functions/fnc_getWeaponData.sqf @@ -10,6 +10,9 @@ * 1: slowdownFactor * 2: jamChance * + * Example: + * ["gun"] call ace_overheating_fnc_getWeaponData + * * Public: No */ #include "script_component.hpp" diff --git a/addons/overheating/functions/fnc_handleTakeEH.sqf b/addons/overheating/functions/fnc_handleTakeEH.sqf index b4eecbf236..0196629a45 100644 --- a/addons/overheating/functions/fnc_handleTakeEH.sqf +++ b/addons/overheating/functions/fnc_handleTakeEH.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, thing, "thing"] call ace_overheating_fnc_handleTakeEH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf index fa5cdd1c43..6a155a29b7 100644 --- a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -13,6 +13,9 @@ * Return Value: * None * + * Example: + * [bob, bob, "weapon",5, 2] call ace_overheating_fnc_loadCoolestSpareBarrel + * * * Public: No */ diff --git a/addons/overheating/functions/fnc_overheat.sqf b/addons/overheating/functions/fnc_overheat.sqf index 84ab7e152f..c29f2d5dd1 100644 --- a/addons/overheating/functions/fnc_overheat.sqf +++ b/addons/overheating/functions/fnc_overheat.sqf @@ -13,6 +13,9 @@ * Return Value: * None * + * Example: + * [bob, "weapon", "muzzle", "ammo", "magazine", bullet] call ace_overheating_fnc_overheat + * * Public: No */ #include "script_component.hpp" diff --git a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf index 3855f96d3f..0486dd5208 100644 --- a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf +++ b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, "bob"] call ace_overheating_fnc_sendSpareBarrelsIsTemperaturesHint + * * * Public: No */ diff --git a/addons/overpressure/functions/fnc_getDistance.sqf b/addons/overpressure/functions/fnc_getDistance.sqf index 29105c2e7c..5f76c12d1a 100644 --- a/addons/overpressure/functions/fnc_getDistance.sqf +++ b/addons/overpressure/functions/fnc_getDistance.sqf @@ -3,9 +3,9 @@ * Calculate the distance to the first intersection of a line * * Arguments: - * 0: Pos ASL of origin (ARRAY> + * 0: Pos ASL of origin * 1: Direction - * 2: Max distance to search + * 2: Max distance to search * 3: Shooter * * Return Value: diff --git a/addons/parachute/functions/fnc_checkCutParachute.sqf b/addons/parachute/functions/fnc_checkCutParachute.sqf index 94137ed67c..67fd842f92 100644 --- a/addons/parachute/functions/fnc_checkCutParachute.sqf +++ b/addons/parachute/functions/fnc_checkCutParachute.sqf @@ -3,10 +3,10 @@ * Reset the parachute system. * * Arguments: - * 0: Object + * 0: Object * * Return Value: - * Boolean + * Boolean * * Example: * [player] call FUNC(checkCutParachute); @@ -15,4 +15,4 @@ */ #include "script_component.hpp" params ["_unit"]; -(vehicle _unit isKindOf 'ParachuteBase' && !(_unit getVariable [QGVAR(chuteIsCut),false]) && (_unit getVariable [QGVAR(hasReserve),false])) \ No newline at end of file +(vehicle _unit isKindOf 'ParachuteBase' && !(_unit getVariable [QGVAR(chuteIsCut),false]) && (_unit getVariable [QGVAR(hasReserve),false])) diff --git a/addons/parachute/functions/fnc_cutParachute.sqf b/addons/parachute/functions/fnc_cutParachute.sqf index f7aa86991b..34b808d9d8 100644 --- a/addons/parachute/functions/fnc_cutParachute.sqf +++ b/addons/parachute/functions/fnc_cutParachute.sqf @@ -3,10 +3,10 @@ * Cut Parachute and delete Old * * Arguments: - * 0: Object + * 0: Object * * Return Value: - * Nothing + * None * * Example: * [player] call FUNC(cutParachute); diff --git a/addons/parachute/functions/fnc_handleInfoDisplayChanged.sqf b/addons/parachute/functions/fnc_handleInfoDisplayChanged.sqf index b27849a0c8..7bb500912e 100644 --- a/addons/parachute/functions/fnc_handleInfoDisplayChanged.sqf +++ b/addons/parachute/functions/fnc_handleInfoDisplayChanged.sqf @@ -3,11 +3,14 @@ * Hides the height and velocity display while freefalling or parachuting on higher difficulties. * * Arguments: - * Stuff from infoDisplayChanged eventhandler. + * Stuff from infoDisplayChanged eventhandler. * * Return Value: * None * + * Example: + * [?] call ACE_parachute_fnc_handleInfoDisplayChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/parachute/functions/fnc_storeParachute.sqf b/addons/parachute/functions/fnc_storeParachute.sqf index 8980a8ff82..adc513fbf9 100644 --- a/addons/parachute/functions/fnc_storeParachute.sqf +++ b/addons/parachute/functions/fnc_storeParachute.sqf @@ -1,18 +1,19 @@ /* - * Author: joko // Jonas - * Add the Reserve Parachute to Units or Save Backpack if is a Parachute in Unit - * - * Arguments: - * None - * - * Return Value: - * 0: Unit - * - * Example: - * None - * - * Public: No - */ + * Author: joko // Jonas + * Add the Reserve Parachute to Units or Save Backpack if is a Parachute in Unit + * + * Arguments: + * None + * + * Return Value: + * 0: Unit + * + * Example: + * call ace_parachute_fnc_storeParachute + * + * Public: No + */ + #include "script_component.hpp" params ["_unit"]; diff --git a/addons/rangecard/functions/fnc_calculateRangeCard.sqf b/addons/rangecard/functions/fnc_calculateRangeCard.sqf index 2cdcb391f5..67952f27f4 100644 --- a/addons/rangecard/functions/fnc_calculateRangeCard.sqf +++ b/addons/rangecard/functions/fnc_calculateRangeCard.sqf @@ -22,10 +22,10 @@ * 16: Use advanced ballistics config? * * Return Value: - * Nothing + * None * * Example: - * call ace_rangecard_fnc_calculateRangeCard + * [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13 ,14, 15, 16, true] call ace_rangecard_fnc_calculateRangeCard * * Public: No */ @@ -115,7 +115,7 @@ while {_TOF < 6 && (_bulletPos select 1) < _targetRange} do { _bulletPos = _bulletPos vectorAdd (_bulletVelocity vectorMultiply (_deltaT * 0.5)); _bulletVelocity = _bulletVelocity vectorAdd (_bulletAccel vectorMultiply _deltaT); _bulletPos = _bulletPos vectorAdd (_bulletVelocity vectorMultiply (_deltaT * 0.5)); - + if (atan((_bulletPos select 2) / (abs(_bulletPos select 1) + 1)) < -2.254) exitWith {}; _TOF = _TOF + _deltaT; diff --git a/addons/rangecard/functions/fnc_canCopy.sqf b/addons/rangecard/functions/fnc_canCopy.sqf index c9e0a05d0e..8984192669 100644 --- a/addons/rangecard/functions/fnc_canCopy.sqf +++ b/addons/rangecard/functions/fnc_canCopy.sqf @@ -6,10 +6,10 @@ * unit * * Return Value: - * canShow (bool) + * canShow * * Example: - * [] call ace_rangecard_fnc_canCopy + * [bob] call ace_rangecard_fnc_canCopy * * Public: No */ diff --git a/addons/rangecard/functions/fnc_canShow.sqf b/addons/rangecard/functions/fnc_canShow.sqf index 330788ee7c..d81bba9485 100644 --- a/addons/rangecard/functions/fnc_canShow.sqf +++ b/addons/rangecard/functions/fnc_canShow.sqf @@ -6,7 +6,7 @@ * Nothing * * Return Value: - * canShow (bool) + * canShow * * Example: * [] call ace_rangecard_fnc_canShow diff --git a/addons/rangecard/functions/fnc_canShowCopy.sqf b/addons/rangecard/functions/fnc_canShowCopy.sqf index e78c64cc89..b6e2d8d68d 100644 --- a/addons/rangecard/functions/fnc_canShowCopy.sqf +++ b/addons/rangecard/functions/fnc_canShowCopy.sqf @@ -6,7 +6,7 @@ * Nothing * * Return Value: - * canShow (bool) + * canShow * * Example: * [] call ace_rangecard_fnc_canShowCopy diff --git a/addons/rangecard/functions/fnc_onCloseDialog.sqf b/addons/rangecard/functions/fnc_onCloseDialog.sqf index f5d971f22f..68d12c8c84 100644 --- a/addons/rangecard/functions/fnc_onCloseDialog.sqf +++ b/addons/rangecard/functions/fnc_onCloseDialog.sqf @@ -1,3 +1,19 @@ +/* + * Author: joko // Jonas + * Add the Reserve Parachute to Units or Save Backpack if is a Parachute in Unit + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * None + * + * Public: No + */ + #include "script_component.hpp" uiNamespace setVariable ['RangleCard_Display', nil]; diff --git a/addons/rangecard/functions/fnc_openRangeCard.sqf b/addons/rangecard/functions/fnc_openRangeCard.sqf index 4a9945e513..5801b594be 100644 --- a/addons/rangecard/functions/fnc_openRangeCard.sqf +++ b/addons/rangecard/functions/fnc_openRangeCard.sqf @@ -6,10 +6,10 @@ * Open copy? * * Return Value: - * Nothing + * None * * Example: - * call ace_rangecard_fnc_openRangeCard + * [true] call ace_rangecard_fnc_openRangeCard * * Public: No */ diff --git a/addons/rangecard/functions/fnc_updateRangeCard.sqf b/addons/rangecard/functions/fnc_updateRangeCard.sqf index 42863e2911..3328600dc3 100644 --- a/addons/rangecard/functions/fnc_updateRangeCard.sqf +++ b/addons/rangecard/functions/fnc_updateRangeCard.sqf @@ -10,10 +10,10 @@ * 4: weapon class * * Return Value: - * Nothing + * None * * Example: - * [mode] call ace_rangecard_fnc_openRangeCard + * [1, 2, "ammo", "magazine", "weapon"] call ace_rangecard_fnc_openRangeCard * * Public: No */ diff --git a/addons/rearm/functions/fnc_moduleRearmSettings.sqf b/addons/rearm/functions/fnc_moduleRearmSettings.sqf index af627862da..e2a38b366e 100644 --- a/addons/rearm/functions/fnc_moduleRearmSettings.sqf +++ b/addons/rearm/functions/fnc_moduleRearmSettings.sqf @@ -10,7 +10,7 @@ * Return Value: * None * - * Example; + * Example: * function = "ace_rearm_fnc_moduleRearmSettings" * * Public: No diff --git a/addons/recoil/functions/fnc_camshake.sqf b/addons/recoil/functions/fnc_camshake.sqf index deb454df71..8b600f41ae 100644 --- a/addons/recoil/functions/fnc_camshake.sqf +++ b/addons/recoil/functions/fnc_camshake.sqf @@ -7,7 +7,7 @@ * None. Parameters inherited from EFUNC(common,firedEH) * * Return Value: - * Nothing + * None * * Example: * [player, (currentWeapon player), (currentMuzzle player)] call ace_recoil_fnc_camShake; diff --git a/addons/refuel/functions/fnc_moduleRefuelSettings.sqf b/addons/refuel/functions/fnc_moduleRefuelSettings.sqf index 8322118a90..9e3e953160 100644 --- a/addons/refuel/functions/fnc_moduleRefuelSettings.sqf +++ b/addons/refuel/functions/fnc_moduleRefuelSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_refuel_fnc_moduleRefuelSettings + * * Public: No */ diff --git a/addons/refuel/functions/fnc_refuel.sqf b/addons/refuel/functions/fnc_refuel.sqf index 2c8f6c1a8c..15fef426d2 100644 --- a/addons/refuel/functions/fnc_refuel.sqf +++ b/addons/refuel/functions/fnc_refuel.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, nozzle, [2, 1, 5]] call ace_refuel_fnc_refuel + * * Public: No */ diff --git a/addons/reload/functions/fnc_checkAmmo.sqf b/addons/reload/functions/fnc_checkAmmo.sqf index baa0754f80..90500b867f 100644 --- a/addons/reload/functions/fnc_checkAmmo.sqf +++ b/addons/reload/functions/fnc_checkAmmo.sqf @@ -7,7 +7,12 @@ * 1: Target. Optional, if not suplied the player counts his personal or static weapon ammo * * Return Value: - * Nothing + * None + * + * Example: + * [bob, kevin] call ace_reload_fnc_checkAmmo + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/reload/functions/fnc_displayAmmo.sqf b/addons/reload/functions/fnc_displayAmmo.sqf index 6aa8f013d9..f48bbb1e0a 100644 --- a/addons/reload/functions/fnc_displayAmmo.sqf +++ b/addons/reload/functions/fnc_displayAmmo.sqf @@ -6,8 +6,14 @@ * 0: Target * * Return Value: - * Nothing + * None + * + * Example: + * [bob] call ace_reload_fnc_displayAmmo + * + * Public: No */ + #include "script_component.hpp" #define COUNT_BARS 12 diff --git a/addons/reload/functions/fnc_startLinkingBelt.sqf b/addons/reload/functions/fnc_startLinkingBelt.sqf index aabfadaf66..4e64bfc154 100644 --- a/addons/reload/functions/fnc_startLinkingBelt.sqf +++ b/addons/reload/functions/fnc_startLinkingBelt.sqf @@ -8,7 +8,13 @@ * * Return Value: * None + * + * Example: + * [bob, kevin] call ace_reload_fnc_startLinkingBelt + * + * Public: No */ + #include "script_component.hpp" params ["_player", "_target"]; diff --git a/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf b/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf index 6a9d779d02..1597654847 100644 --- a/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf +++ b/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf @@ -3,11 +3,14 @@ * Create one action per reloadable missile * * Arguments: - * 1: Target (Object) - * 0: Player (Object) + * 1: Target + * 0: Player * * Return Value: - * Children actions (Array) + * Children actions + * + * Example: + * [bob, kevin] call ace_reloadlaunchers_fnc_addMissileReloadActions * * Public: No * diff --git a/addons/reloadlaunchers/functions/fnc_canLoad.sqf b/addons/reloadlaunchers/functions/fnc_canLoad.sqf index 5072d44a48..9f76cab49a 100644 --- a/addons/reloadlaunchers/functions/fnc_canLoad.sqf +++ b/addons/reloadlaunchers/functions/fnc_canLoad.sqf @@ -3,13 +3,16 @@ * Check of the unit can reload the launcher of target unit. * * Arguments: - * 0: Unit to do the reloading (Object) - * 1: Unit eqipped with launcher (Object) - * 2: weapon name (String) - * 3: missile name (String) + * 0: Unit to do the reloading + * 1: Unit eqipped with launcher + * 2: weapon name + * 3: missile name * * Return Value: - * NONE + * None + * + * Example: + * [bob, kevin, "weapon", "missile"] call ace_reloadlaunchers_fnc_canLoad * * Public: No */ diff --git a/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf b/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf index 40766a5905..2dc8cf5925 100644 --- a/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf +++ b/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf @@ -3,11 +3,14 @@ * Return all magazine types from reloaders inventory that are compatible with given weapon. * * Arguments: - * 0: Unit to to the reload (Object) - * 1: A launcher (String) + * 0: Unit to to the reload + * 1: A launcher * * Return Value: - * Reloable magazines (Array) + * Reloable magazines + * + * Example: + * [bob, launcher] call ace_reloadlaunchers_fnc_getLoadableMissiles * * Public: No */ diff --git a/addons/reloadlaunchers/functions/fnc_load.sqf b/addons/reloadlaunchers/functions/fnc_load.sqf index 2f822bb6d7..8330b111b7 100644 --- a/addons/reloadlaunchers/functions/fnc_load.sqf +++ b/addons/reloadlaunchers/functions/fnc_load.sqf @@ -3,13 +3,16 @@ * Reload a launcher * * Arguments: - * 0: Unit with magazine (Object) - * 1: Unit with launcher (Object) - * 2: weapon name (String) - * 3: missile name (String) + * 0: Unit with magazine + * 1: Unit with launcher + * 2: weapon name + * 3: missile name * * Return Value: - * NONE + * None + * + * Example: + * [bob, kevin, "weapon", "missile"] call ace_reloadlaunchers_fnc_load * * Public: No */ diff --git a/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf b/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf index 96db7cdca5..cd2295d7d0 100644 --- a/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf +++ b/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf @@ -3,13 +3,16 @@ * Reload a launcher * * Arguments: - * 0: Unit to do the reloading (Object) - * 1: Target to rload (Object) - * 2: weapon name (String) - * 3: missile name (String) + * 0: Unit to do the reloading + * 1: Target to rload + * 2: weapon name + * 3: missile name * * Return Value: - * NONE + * None + * + * Example: + * [bob, kevin, "weapon", "missile"] call ace_reloadlaunchers_fnc_realoadLauncher * * Public: No */ @@ -24,4 +27,4 @@ if (currentWeapon _target != _weapon) exitWith {}; if (currentMagazine _target != "") exitWith {}; // command is wip, reload time for launchers is not intended. -_target addWeaponItem [_weapon, _magazine]; +_target addWeaponItem [_weapon, _magazine]; diff --git a/addons/repair/functions/fnc_getHitPointString.sqf b/addons/repair/functions/fnc_getHitPointString.sqf index 6214b00df7..31e4ed400f 100644 --- a/addons/repair/functions/fnc_getHitPointString.sqf +++ b/addons/repair/functions/fnc_getHitPointString.sqf @@ -9,8 +9,8 @@ * 3: Track Added Hitpoints (default: false) * * Return Value: - * 0: Text - * 1: Added Hitpoint (default: []) + * 0: Text + * 1: Added Hitpoint (default: []) * * Example: * ["HitFuel", "Repairing %1 ...", "Repairing HitFuel"] call ace_repair_fnc_getHitPointString diff --git a/addons/repair/functions/fnc_isRepairVehicle.sqf b/addons/repair/functions/fnc_isRepairVehicle.sqf index 2c0b5a1e21..f18ff0cd3e 100644 --- a/addons/repair/functions/fnc_isRepairVehicle.sqf +++ b/addons/repair/functions/fnc_isRepairVehicle.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Vehicle * - * ReturnValue: + * Return Value: * Is engineering vehicle * * Example: diff --git a/addons/repair/functions/fnc_modifyInteraction.sqf b/addons/repair/functions/fnc_modifyInteraction.sqf index cff0fbe6e8..f1956ee384 100644 --- a/addons/repair/functions/fnc_modifyInteraction.sqf +++ b/addons/repair/functions/fnc_modifyInteraction.sqf @@ -9,7 +9,7 @@ * 3: Action Data * * Return Value: - * Nothing + * None * * Example: * [cursorObject, player, [], []] call ace_repair_fnc_modifyInteraction; @@ -21,7 +21,7 @@ params ["_target", "_player", "_args", "_actionData"]; TRACE_4("params",_target,_player,_args,_actionData); -// Interaction dots numbered 0..8, white to red. +// Interaction dots numbered 0..8, white to red. // Convert damage to number (rounding up), so that even slight damage can bee seen private _fileName = format [QPATHTOF(ui\damage_%1_ca.paa), ceil (linearConversion [0, 1, damage _target, 0, 8, true])]; diff --git a/addons/repair/functions/fnc_useItem.sqf b/addons/repair/functions/fnc_useItem.sqf index 02daeed33e..de3950fa22 100644 --- a/addons/repair/functions/fnc_useItem.sqf +++ b/addons/repair/functions/fnc_useItem.sqf @@ -6,7 +6,7 @@ * 0: Unit * 1: Item classname * - * ReturnValue: + * Return Value: * [Had Item to Use , Unit ] * * Example: diff --git a/addons/repair/functions/fnc_useItems.sqf b/addons/repair/functions/fnc_useItems.sqf index 14dcb6223c..859115b68c 100644 --- a/addons/repair/functions/fnc_useItems.sqf +++ b/addons/repair/functions/fnc_useItems.sqf @@ -6,7 +6,7 @@ * 0: Unit * 1: Item classnames * - * ReturnValue: + * Return Value: * [Had Item to Use , Array of units that used the items ] * * Example: diff --git a/addons/sandbag/functions/fnc_handleInteractMenuOpened.sqf b/addons/sandbag/functions/fnc_handleInteractMenuOpened.sqf index f4ea5891c7..4aef8f7ec8 100644 --- a/addons/sandbag/functions/fnc_handleInteractMenuOpened.sqf +++ b/addons/sandbag/functions/fnc_handleInteractMenuOpened.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_sandbag_fnc_handleInteractMenuOpened + * * Public: No */ #include "script_component.hpp" diff --git a/addons/sandbag/functions/fnc_handleKilled.sqf b/addons/sandbag/functions/fnc_handleKilled.sqf index 63babd3f52..b991af1e4b 100644 --- a/addons/sandbag/functions/fnc_handleKilled.sqf +++ b/addons/sandbag/functions/fnc_handleKilled.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_sandbag_fnc_handleKilled + * * Public: No */ #include "script_component.hpp" diff --git a/addons/sandbag/functions/fnc_handlePlayerChanged.sqf b/addons/sandbag/functions/fnc_handlePlayerChanged.sqf index f27a295903..2828979bc1 100644 --- a/addons/sandbag/functions/fnc_handlePlayerChanged.sqf +++ b/addons/sandbag/functions/fnc_handlePlayerChanged.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ace_sandbag_fnc_handlePlayerChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/sandbag/functions/fnc_handlePlayerInventoryChanged.sqf b/addons/sandbag/functions/fnc_handlePlayerInventoryChanged.sqf index 9f5920edd1..50d2fdede0 100644 --- a/addons/sandbag/functions/fnc_handlePlayerInventoryChanged.sqf +++ b/addons/sandbag/functions/fnc_handlePlayerInventoryChanged.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, "weapon"] call ace_sandbag_fnc_handlePlayerInventoryChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/sandbag/functions/fnc_handleUnconscious.sqf b/addons/sandbag/functions/fnc_handleUnconscious.sqf index 7e0e257158..709e633377 100644 --- a/addons/sandbag/functions/fnc_handleUnconscious.sqf +++ b/addons/sandbag/functions/fnc_handleUnconscious.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_sandbag_fnc_handleUnconscious + * * Public: No */ #include "script_component.hpp" diff --git a/addons/scopes/functions/fnc_calculateZeroAngleCorrection.sqf b/addons/scopes/functions/fnc_calculateZeroAngleCorrection.sqf index bcf1779f84..5197a94e70 100644 --- a/addons/scopes/functions/fnc_calculateZeroAngleCorrection.sqf +++ b/addons/scopes/functions/fnc_calculateZeroAngleCorrection.sqf @@ -11,7 +11,10 @@ * 5: Advanced Ballistics enabled? * * Return Value: - * zeroAngleCorrection + * zeroAngleCorrection + * + * Example: + * [5, 6, gun, ammo, magazine, true] call ace_scopes_fnc_calculateZeroAngleCorrection * * Public: No */ diff --git a/addons/scopes/functions/fnc_firedEH.sqf b/addons/scopes/functions/fnc_firedEH.sqf index ebadb2f715..f83371ec13 100644 --- a/addons/scopes/functions/fnc_firedEH.sqf +++ b/addons/scopes/functions/fnc_firedEH.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * call ace_scopes_fnc_firedEH + * * Public: No */ #include "script_component.hpp" diff --git a/addons/scopes/functions/fnc_initModuleSettings.sqf b/addons/scopes/functions/fnc_initModuleSettings.sqf index a04433f11e..92742afd14 100644 --- a/addons/scopes/functions/fnc_initModuleSettings.sqf +++ b/addons/scopes/functions/fnc_initModuleSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_scopes_fnc_initModuleSettings + * * Public: No */ #include "script_component.hpp" @@ -17,7 +20,7 @@ params ["_logic","_units", "_activated"]; if !(_activated) exitWith {}; - + [_logic, QGVAR(enabled), "enabled"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(forceUseOfAdjustmentTurrets), "forceUseOfAdjustmentTurrets"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(correctZeroing), "correctZeroing"] call EFUNC(common,readSettingFromModule); diff --git a/addons/slideshow/functions/fnc_moduleInit.sqf b/addons/slideshow/functions/fnc_moduleInit.sqf index c54aec7d2f..caef4cb2d8 100644 --- a/addons/slideshow/functions/fnc_moduleInit.sqf +++ b/addons/slideshow/functions/fnc_moduleInit.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_slideshow_fnc_moduleInit + * * Public: No */ #include "script_component.hpp" diff --git a/addons/spectator/functions/fnc_moduleSpectatorSettings.sqf b/addons/spectator/functions/fnc_moduleSpectatorSettings.sqf index 52b6e5d8fa..8224c77e57 100644 --- a/addons/spectator/functions/fnc_moduleSpectatorSettings.sqf +++ b/addons/spectator/functions/fnc_moduleSpectatorSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_spectator_fnc_moduleSpectatorSettings + * * Public: No */ diff --git a/addons/spectator/functions/fnc_respawnTemplate.sqf b/addons/spectator/functions/fnc_respawnTemplate.sqf index 1a36170202..59759d1371 100644 --- a/addons/spectator/functions/fnc_respawnTemplate.sqf +++ b/addons/spectator/functions/fnc_respawnTemplate.sqf @@ -13,6 +13,9 @@ * Return Value: * None * + * Example: + * [bob, kevin, 3, 6] call ace_spectator_fnc_respawnTemplate + * * Public: No */ diff --git a/addons/spectator/functions/fnc_toggleInterface.sqf b/addons/spectator/functions/fnc_toggleInterface.sqf index 31472702fc..4bf10fdbfe 100644 --- a/addons/spectator/functions/fnc_toggleInterface.sqf +++ b/addons/spectator/functions/fnc_toggleInterface.sqf @@ -3,7 +3,7 @@ * Correctly handles toggling of spectator interface elements for clean UX * * Arguments: - * 0: Display + * 0: Display * 1: Toogle compass * 2: Toogle help * 3: Toogle interface @@ -15,7 +15,7 @@ * None * * Example: - * [_dsiplay, nil, true] call ace_spectator_fnc_toggleInterface + * [_display, nil, true] call ace_spectator_fnc_toggleInterface * * Public: No */ diff --git a/addons/spottingscope/functions/fnc_animateReticle.sqf b/addons/spottingscope/functions/fnc_animateReticle.sqf index 10bbf9b564..7fbf71fe23 100644 --- a/addons/spottingscope/functions/fnc_animateReticle.sqf +++ b/addons/spottingscope/functions/fnc_animateReticle.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [DISPLAY] call ace_spottingscope_fnc_animateReticle + * * Public: No */ #include "script_component.hpp" @@ -15,7 +18,7 @@ disableSerialization; params ["_display"]; -uinamespace setVariable [QGVAR(dlgSpottingScope), _display]; +uinamespace setVariable [QGVAR(dlgSpottingScope), _display]; private _ctrlReticle = _display displayCtrl IDC_RETICLE; private _ctrlBody = _display displayCtrl IDC_BODY; diff --git a/addons/switchunits/functions/fnc_handleMapClick.sqf b/addons/switchunits/functions/fnc_handleMapClick.sqf index b0984631d7..db016ac8f3 100644 --- a/addons/switchunits/functions/fnc_handleMapClick.sqf +++ b/addons/switchunits/functions/fnc_handleMapClick.sqf @@ -3,7 +3,7 @@ * Switches to a unit close to a clicked map position * * Arguments: - * 0: Faction + * 0: Faction * 0: unit * 1: sides * 1: Map Position diff --git a/addons/tacticalladder/functions/fnc_handleInteractMenuOpened.sqf b/addons/tacticalladder/functions/fnc_handleInteractMenuOpened.sqf index c7187acd55..4c46ea46c2 100644 --- a/addons/tacticalladder/functions/fnc_handleInteractMenuOpened.sqf +++ b/addons/tacticalladder/functions/fnc_handleInteractMenuOpened.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_tacticalladder_fnc_handleInteractMenuOpened + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tacticalladder/functions/fnc_handleKilled.sqf b/addons/tacticalladder/functions/fnc_handleKilled.sqf index c5d6aa1314..742231900c 100644 --- a/addons/tacticalladder/functions/fnc_handleKilled.sqf +++ b/addons/tacticalladder/functions/fnc_handleKilled.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_tacticalladder_fnc_handleKilled + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tacticalladder/functions/fnc_handlePlayerChanged.sqf b/addons/tacticalladder/functions/fnc_handlePlayerChanged.sqf index 07118acbaf..713c75df7f 100644 --- a/addons/tacticalladder/functions/fnc_handlePlayerChanged.sqf +++ b/addons/tacticalladder/functions/fnc_handlePlayerChanged.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ace_tacticalladder_fnc_handlePlayerChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tacticalladder/functions/fnc_handleUnconscious.sqf b/addons/tacticalladder/functions/fnc_handleUnconscious.sqf index e9ce28d524..152f014602 100644 --- a/addons/tacticalladder/functions/fnc_handleUnconscious.sqf +++ b/addons/tacticalladder/functions/fnc_handleUnconscious.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_tacticalladder_fnc_handleUnconscious + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tagging/functions/fnc_moduleInit.sqf b/addons/tagging/functions/fnc_moduleInit.sqf index 235bd3a046..8b2d42a010 100644 --- a/addons/tagging/functions/fnc_moduleInit.sqf +++ b/addons/tagging/functions/fnc_moduleInit.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_tagging_fnc_moduleInit + * * Public: No */ #include "script_component.hpp" diff --git a/addons/trenches/functions/fnc_handleInteractMenuOpened.sqf b/addons/trenches/functions/fnc_handleInteractMenuOpened.sqf index 91d6b0140b..5e68b6f60f 100644 --- a/addons/trenches/functions/fnc_handleInteractMenuOpened.sqf +++ b/addons/trenches/functions/fnc_handleInteractMenuOpened.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_trenches_fnc_handleInteractMenuOpened + * * Public: No */ #include "script_component.hpp" diff --git a/addons/trenches/functions/fnc_handleKilled.sqf b/addons/trenches/functions/fnc_handleKilled.sqf index e9f0353cb1..6b57e20c91 100644 --- a/addons/trenches/functions/fnc_handleKilled.sqf +++ b/addons/trenches/functions/fnc_handleKilled.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_trenches_fnc_handleKilled + * * Public: No */ #include "script_component.hpp" diff --git a/addons/trenches/functions/fnc_handlePlayerChanged.sqf b/addons/trenches/functions/fnc_handlePlayerChanged.sqf index 684ccc22ce..f4ebb8e2d5 100644 --- a/addons/trenches/functions/fnc_handlePlayerChanged.sqf +++ b/addons/trenches/functions/fnc_handlePlayerChanged.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, kevin] call ace_trenches_fnc_handlePlayerChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/trenches/functions/fnc_handlePlayerInventoryChanged.sqf b/addons/trenches/functions/fnc_handlePlayerInventoryChanged.sqf index cbae02d07a..11bdef6072 100644 --- a/addons/trenches/functions/fnc_handlePlayerInventoryChanged.sqf +++ b/addons/trenches/functions/fnc_handlePlayerInventoryChanged.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob, "weapon"] call ace_trenches_fnc_handlePlayerInverntoryChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/trenches/functions/fnc_handleUnconscious.sqf b/addons/trenches/functions/fnc_handleUnconscious.sqf index e4fc2814b2..3407a5a029 100644 --- a/addons/trenches/functions/fnc_handleUnconscious.sqf +++ b/addons/trenches/functions/fnc_handleUnconscious.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_trenches_fnc_handleUnconscious + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tripod/functions/fnc_handleInteractMenuOpened.sqf b/addons/tripod/functions/fnc_handleInteractMenuOpened.sqf index 8c49359d96..014eed55d4 100644 --- a/addons/tripod/functions/fnc_handleInteractMenuOpened.sqf +++ b/addons/tripod/functions/fnc_handleInteractMenuOpened.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_tripod_fnc_handleInteractMenuOpened + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tripod/functions/fnc_handleKilled.sqf b/addons/tripod/functions/fnc_handleKilled.sqf index ee28fc1f45..90dd388617 100644 --- a/addons/tripod/functions/fnc_handleKilled.sqf +++ b/addons/tripod/functions/fnc_handleKilled.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_tripod_fnc_handleKilled + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tripod/functions/fnc_handlePlayerChanged.sqf b/addons/tripod/functions/fnc_handlePlayerChanged.sqf index dd0cad6533..3d37b7949f 100644 --- a/addons/tripod/functions/fnc_handlePlayerChanged.sqf +++ b/addons/tripod/functions/fnc_handlePlayerChanged.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_tripod_fnc_handlePlayerChanged + * * Public: No */ #include "script_component.hpp" diff --git a/addons/tripod/functions/fnc_handleUnconscious.sqf b/addons/tripod/functions/fnc_handleUnconscious.sqf index f81cecea58..0b43bd4b6b 100644 --- a/addons/tripod/functions/fnc_handleUnconscious.sqf +++ b/addons/tripod/functions/fnc_handleUnconscious.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [bob] call ace_tripod_fnc_handleUnconscious + * * Public: No */ #include "script_component.hpp" diff --git a/addons/ui/functions/fnc_moduleInit.sqf b/addons/ui/functions/fnc_moduleInit.sqf index 79a9ef2d93..6a3e74aa67 100644 --- a/addons/ui/functions/fnc_moduleInit.sqf +++ b/addons/ui/functions/fnc_moduleInit.sqf @@ -9,6 +9,11 @@ * * Return Value: * None + * + * Example: + * [LOGIC, [bob, kevin], true] call ace_ui_fnc_moduleInit + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/vector/functions/fnc_adjustBrightness.sqf b/addons/vector/functions/fnc_adjustBrightness.sqf index da951322af..b31cc5361c 100644 --- a/addons/vector/functions/fnc_adjustBrightness.sqf +++ b/addons/vector/functions/fnc_adjustBrightness.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * 0: Number + * + * Return Value: + * None + * + * Example: + * [5] call ace_vector_fnc_adjustBrigthness + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_clearDisplay.sqf b/addons/vector/functions/fnc_clearDisplay.sqf index 73ef7dfcc6..3ec3ef7eb6 100644 --- a/addons/vector/functions/fnc_clearDisplay.sqf +++ b/addons/vector/functions/fnc_clearDisplay.sqf @@ -1,10 +1,19 @@ /* + * Author: commy2 + * Clears the vectors control items. + * + * Arguments: + * 0: String + * + * Return Value: + * None + * + * Example: + * [5] call ace_vector_fnc_clearDisplay + * + * Public: No + */ -by commy2 - -Clears the vectors control items. - -*/ #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_convertToTexturesDegree.sqf b/addons/vector/functions/fnc_convertToTexturesDegree.sqf index 7e04cfccd2..a7c81fe669 100644 --- a/addons/vector/functions/fnc_convertToTexturesDegree.sqf +++ b/addons/vector/functions/fnc_convertToTexturesDegree.sqf @@ -1,8 +1,18 @@ -/* by commy2 - -converts azimuth into array of textures for the vectors scripted info control - -*/ +/* + * Author: commy2 + * converts azimuth into array of textures for the vectors scripted info control + * + * Arguments: + * 0: Number + * + * Return Value: + * None + * + * Example: + * [5] call ace_vector_fnc_convertToTexturesDegree + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/vector/functions/fnc_convertToTexturesDistance.sqf b/addons/vector/functions/fnc_convertToTexturesDistance.sqf index eb39febfe8..5bad048022 100644 --- a/addons/vector/functions/fnc_convertToTexturesDistance.sqf +++ b/addons/vector/functions/fnc_convertToTexturesDistance.sqf @@ -1,8 +1,19 @@ -/* by commy2 +/* + * Author: commy2 + * converts rangefinder distance into array of textures for the vectors scripted info control + * + * Arguments: + * 0: Number + * + * Return Value: + * Array + * + * Example: + * [5] call ace_vector_fnc_convertToTexturesDistance + * + * Public: No + */ -converts rangefinder distance into array of textures for the vectors scripted info control - -*/ #include "script_component.hpp" diff --git a/addons/vector/functions/fnc_convertToTexturesFOS.sqf b/addons/vector/functions/fnc_convertToTexturesFOS.sqf index 7a77a3aab8..3f5dd9a8da 100644 --- a/addons/vector/functions/fnc_convertToTexturesFOS.sqf +++ b/addons/vector/functions/fnc_convertToTexturesFOS.sqf @@ -1,8 +1,19 @@ -/* by commy2 - -converts rangefinder distance into array of textures for the vectors scripted info control - -*/ +/* + * Author: commy2 + * converts rangefinder distance into array of textures for the vectors scripted info control + * + * Arguments: + * 0: Number + * 1: Number + * + * Return Value: + * Array + * + * Example: + * [5, 6] call ace_vector_fnc_convertToTexturesFOS + * + * Public: No + */ #include "script_component.hpp" diff --git a/addons/vector/functions/fnc_dataTransfer.sqf b/addons/vector/functions/fnc_dataTransfer.sqf index f99490f04c..06eab8803a 100644 --- a/addons/vector/functions/fnc_dataTransfer.sqf +++ b/addons/vector/functions/fnc_dataTransfer.sqf @@ -3,10 +3,10 @@ * Data transfer over a connected cable. Based on page 14 of pdf. * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * [] call ace_vector_fnc_dataTransfer diff --git a/addons/vector/functions/fnc_getDirection.sqf b/addons/vector/functions/fnc_getDirection.sqf index c34826e218..4b67cfed28 100644 --- a/addons/vector/functions/fnc_getDirection.sqf +++ b/addons/vector/functions/fnc_getDirection.sqf @@ -1,3 +1,19 @@ +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * Array + * + * Example: + * call ace_vector_fnc_getDirection + * + * Public: No + */ + // by commy2 #include "script_component.hpp" diff --git a/addons/vector/functions/fnc_getDistance.sqf b/addons/vector/functions/fnc_getDistance.sqf index f1312be511..d8e5d441df 100644 --- a/addons/vector/functions/fnc_getDistance.sqf +++ b/addons/vector/functions/fnc_getDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * Array + * + * Example: + * call ace_vector_fnc_getDistance + * + * Public: No + */ + #include "script_component.hpp" #define MIN_DISTANCE 10 diff --git a/addons/vector/functions/fnc_getFallOfShot.sqf b/addons/vector/functions/fnc_getFallOfShot.sqf index 365a41518e..5a0af98a77 100644 --- a/addons/vector/functions/fnc_getFallOfShot.sqf +++ b/addons/vector/functions/fnc_getFallOfShot.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * Array + * + * Example: + * call ace_vector_fnc_getFallOfShot + * + * Public: No + */ + #include "script_component.hpp" private ["_distanceP1", "_directionP1", "_azimuthP1", "_inclinationP1", "_distanceP2", "_directionP2", "_azimuthP2", "_inclinationP2"]; diff --git a/addons/vector/functions/fnc_getHeightDistance.sqf b/addons/vector/functions/fnc_getHeightDistance.sqf index 9ec0919917..acae881928 100644 --- a/addons/vector/functions/fnc_getHeightDistance.sqf +++ b/addons/vector/functions/fnc_getHeightDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * Array + * + * Example: + * call ace_vector_fnc_getHeightDistance + * + * Public: No + */ + #include "script_component.hpp" private ["_distance", "_direction", "_azimuth", "_inclination"]; diff --git a/addons/vector/functions/fnc_getRelativeAzimuthDistance.sqf b/addons/vector/functions/fnc_getRelativeAzimuthDistance.sqf index 765d3d6ec4..a613e2e3ad 100644 --- a/addons/vector/functions/fnc_getRelativeAzimuthDistance.sqf +++ b/addons/vector/functions/fnc_getRelativeAzimuthDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * Array + * + * Example: + * call ace_vector_fnc_getRelativeAzimuthDistance + * + * Public: No + */ + #include "script_component.hpp" private ["_distanceP1", "_directionP1", "_azimuthP1", "_inclinationP1", "_distanceP2", "_directionP2", "_azimuthP2", "_inclinationP2"]; diff --git a/addons/vector/functions/fnc_getRelativeDistance.sqf b/addons/vector/functions/fnc_getRelativeDistance.sqf index 9c6dc38943..802a325848 100644 --- a/addons/vector/functions/fnc_getRelativeDistance.sqf +++ b/addons/vector/functions/fnc_getRelativeDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * Number + * + * Example: + * call ace_vector_fnc_getRelativeDistance + * + * Public: No + */ + #include "script_component.hpp" private ["_distanceP1", "_directionP1", "_azimuthP1", "_inclinationP1", "_distanceP2", "_directionP2", "_azimuthP2", "_inclinationP2"]; diff --git a/addons/vector/functions/fnc_getRelativeHeightLength.sqf b/addons/vector/functions/fnc_getRelativeHeightLength.sqf index 319b11b6a6..3471fce2ca 100644 --- a/addons/vector/functions/fnc_getRelativeHeightLength.sqf +++ b/addons/vector/functions/fnc_getRelativeHeightLength.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * Array + * + * Example: + * call ace_vector_fnc_getRelativeHeightLength + * + * Public: No + */ + #include "script_component.hpp" private ["_distanceP1", "_directionP1", "_azimuthP1", "_inclinationP1", "_distanceP2", "_directionP2", "_azimuthP2", "_inclinationP2"]; diff --git a/addons/vector/functions/fnc_illuminate.sqf b/addons/vector/functions/fnc_illuminate.sqf index 03508aae9e..8ecc10690f 100644 --- a/addons/vector/functions/fnc_illuminate.sqf +++ b/addons/vector/functions/fnc_illuminate.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * 0: String + * + * Return Value: + * None + * + * Example: + * ["5"] call ace_vector_fnc_illuminate + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_nextMode.sqf b/addons/vector/functions/fnc_nextMode.sqf index 53054e85e6..8e6d596f58 100644 --- a/addons/vector/functions/fnc_nextMode.sqf +++ b/addons/vector/functions/fnc_nextMode.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * 0: String + * + * Return Value: + * Array + * + * Example: + * ["5"] call ace_vector_fnc_nextMode + * + * Public: No + */ + #include "script_component.hpp" switch (_this select 0) do { diff --git a/addons/vector/functions/fnc_onKeyDown.sqf b/addons/vector/functions/fnc_onKeyDown.sqf index 830fb3c3c5..194a3b74af 100644 --- a/addons/vector/functions/fnc_onKeyDown.sqf +++ b/addons/vector/functions/fnc_onKeyDown.sqf @@ -1,10 +1,19 @@ /* + * Author: commy2 + * Handles pressing the special vector keys. + * + * Arguments: + * 0: String + * + * Return Value: + * None + * + * Example: + * ["5"] call ace_vector_fnc_onKeyDown + * + * Public: No + */ -by commy2 - -Handles pressing the special vector keys. - -*/ #include "script_component.hpp" // set vector config settings diff --git a/addons/vector/functions/fnc_onKeyHold.sqf b/addons/vector/functions/fnc_onKeyHold.sqf index 3fdd637b61..fdfa22d2b5 100644 --- a/addons/vector/functions/fnc_onKeyHold.sqf +++ b/addons/vector/functions/fnc_onKeyHold.sqf @@ -1,10 +1,20 @@ /* + * Author: commy2 + * PFH executed while holding a vector key down. + * + * Arguments: + * 0: String + * 1: Number + * + * Return Value: + * None + * + * Example: + * ["5", 5] call ace_vector_fnc_onKeyHold + * + * Public: No + */ -by commy2 - -PFH executed while holding a vector key down. - -*/ #include "script_component.hpp" if (!((currentWeapon ACE_player) isKindOf ["ACE_Vector", configFile >> "CfgWeapons"])) exitWith { diff --git a/addons/vector/functions/fnc_onKeyUp.sqf b/addons/vector/functions/fnc_onKeyUp.sqf index fc3d17700e..6896026b50 100644 --- a/addons/vector/functions/fnc_onKeyUp.sqf +++ b/addons/vector/functions/fnc_onKeyUp.sqf @@ -1,10 +1,19 @@ /* + * Author: commy2 + * Handles releasing the special vector keys. + * + * Arguments: + * 0: String + * + * Return Value: + * None + * + * Example: + * ["5"] call ace_vector_fnc_onKeyUp + * + * Public: No + */ -by commy2 - -Handles releasing the special vector keys. - -*/ #include "script_component.hpp" private _fnc_setPFH = { diff --git a/addons/vector/functions/fnc_showAzimuth.sqf b/addons/vector/functions/fnc_showAzimuth.sqf index 2bedd4bf52..59166e1f4c 100644 --- a/addons/vector/functions/fnc_showAzimuth.sqf +++ b/addons/vector/functions/fnc_showAzimuth.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showAzimuth + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showAzimuthInclination.sqf b/addons/vector/functions/fnc_showAzimuthInclination.sqf index b00c035890..d6b8740e2a 100644 --- a/addons/vector/functions/fnc_showAzimuthInclination.sqf +++ b/addons/vector/functions/fnc_showAzimuthInclination.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showAzimuthInclination + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showCenter.sqf b/addons/vector/functions/fnc_showCenter.sqf index 4870b10a69..8142a2c3be 100644 --- a/addons/vector/functions/fnc_showCenter.sqf +++ b/addons/vector/functions/fnc_showCenter.sqf @@ -1,10 +1,19 @@ /* + * Author: commy2 + * Shows or hides the vectors center square thingy. + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showCenter + * + * Public: No + */ -by commy2 - -Shows or hides the vectors center square thingy. - -*/ #include "script_component.hpp" ((GETUVAR(ACE_dlgVector,displayNull)) displayCtrl 1301) ctrlSetText (["", QPATHTOF(rsc\vector_center.paa)] select (_this select 0)); diff --git a/addons/vector/functions/fnc_showDistance.sqf b/addons/vector/functions/fnc_showDistance.sqf index 380f784bbc..ffabeb9824 100644 --- a/addons/vector/functions/fnc_showDistance.sqf +++ b/addons/vector/functions/fnc_showDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showDistance + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showFallOfShot.sqf b/addons/vector/functions/fnc_showFallOfShot.sqf index b7bed77a0b..459f1dcaed 100644 --- a/addons/vector/functions/fnc_showFallOfShot.sqf +++ b/addons/vector/functions/fnc_showFallOfShot.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * 0: Unknown + * + * Return Value: + * None + * + * Example: + * [?] call ace_vector_fnc_showFallOfShot + * + * Public: No + */ + #include "script_component.hpp" GVAR(FOSState) = _this select 0; diff --git a/addons/vector/functions/fnc_showHeightDistance.sqf b/addons/vector/functions/fnc_showHeightDistance.sqf index b34e8111bc..cbe0b7b86d 100644 --- a/addons/vector/functions/fnc_showHeightDistance.sqf +++ b/addons/vector/functions/fnc_showHeightDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showHeightDistance + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showP1.sqf b/addons/vector/functions/fnc_showP1.sqf index 8d509d575f..3975399bcb 100644 --- a/addons/vector/functions/fnc_showP1.sqf +++ b/addons/vector/functions/fnc_showP1.sqf @@ -1,10 +1,19 @@ /* + * Author: commy2 + * Shows or hides the 1-P text line. + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showP1 + * + * Public: No + */ -by commy2 - -Shows or hides the 1-P text line. - -*/ #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showRelativeAzimuthDistance.sqf b/addons/vector/functions/fnc_showRelativeAzimuthDistance.sqf index 95797b9d6c..a9426be05c 100644 --- a/addons/vector/functions/fnc_showRelativeAzimuthDistance.sqf +++ b/addons/vector/functions/fnc_showRelativeAzimuthDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showRelativeAzimuthDistance + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showRelativeDistance.sqf b/addons/vector/functions/fnc_showRelativeDistance.sqf index 74b778d8bf..e0853efa03 100644 --- a/addons/vector/functions/fnc_showRelativeDistance.sqf +++ b/addons/vector/functions/fnc_showRelativeDistance.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showRelativeDistance + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showRelativeHeightLength.sqf b/addons/vector/functions/fnc_showRelativeHeightLength.sqf index 0b9f5c1928..13bd8061e1 100644 --- a/addons/vector/functions/fnc_showRelativeHeightLength.sqf +++ b/addons/vector/functions/fnc_showRelativeHeightLength.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showRelativeHeightLength + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/vector/functions/fnc_showReticle.sqf b/addons/vector/functions/fnc_showReticle.sqf index bcd565774f..aeecfc5ef3 100644 --- a/addons/vector/functions/fnc_showReticle.sqf +++ b/addons/vector/functions/fnc_showReticle.sqf @@ -1,10 +1,19 @@ /* + * Author: commy2 + * Shows or hides the electronic reticle. + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_vector_fnc_showReticle + * + * Public: No + */ -by commy2 - -Shows or hides the electronic reticle. - -*/ #include "script_component.hpp" ((GETUVAR(ACE_dlgVector,displayNull)) displayCtrl 1302) ctrlSetText (["", QPATHTOF(rsc\vector_crosshair.paa)] select (_this select 0)); diff --git a/addons/vector/functions/fnc_showText.sqf b/addons/vector/functions/fnc_showText.sqf index b578269115..66628d8d44 100644 --- a/addons/vector/functions/fnc_showText.sqf +++ b/addons/vector/functions/fnc_showText.sqf @@ -1,4 +1,19 @@ -// by commy2 +/* + * Author: commy2 + * + * + * Arguments: + * 0: String + * + * Return Value: + * None + * + * Example: + * ["5"] call ace_vector_fnc_showText + * + * Public: No + */ + #include "script_component.hpp" disableSerialization; diff --git a/addons/viewdistance/functions/fnc_initModule.sqf b/addons/viewdistance/functions/fnc_initModule.sqf index cc73e71395..3afd3ccd6a 100644 --- a/addons/viewdistance/functions/fnc_initModule.sqf +++ b/addons/viewdistance/functions/fnc_initModule.sqf @@ -9,6 +9,11 @@ * * Return Value: * None + * + * Example: + * [LOGIC; [bob, kevin], true] call ace_viewdistance_fnc_initModule + * + * Public: No */ #include "script_component.hpp" diff --git a/addons/weather/functions/fnc_updateHumidity.sqf b/addons/weather/functions/fnc_updateHumidity.sqf index acd103615b..79569e7367 100644 --- a/addons/weather/functions/fnc_updateHumidity.sqf +++ b/addons/weather/functions/fnc_updateHumidity.sqf @@ -3,10 +3,10 @@ * Updates GVAR(currentHumidity) * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * [] call ace_weather_fnc_updateHumidity diff --git a/addons/weather/functions/fnc_updateRain.sqf b/addons/weather/functions/fnc_updateRain.sqf index b073a6a24c..eefa72cd99 100644 --- a/addons/weather/functions/fnc_updateRain.sqf +++ b/addons/weather/functions/fnc_updateRain.sqf @@ -3,10 +3,10 @@ * Updates rain based on ACE_RAIN_PARAMS * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * [] call ace_weather_fnc_updateRain diff --git a/addons/weather/functions/fnc_updateTemperature.sqf b/addons/weather/functions/fnc_updateTemperature.sqf index 6f2d911c15..879e061574 100644 --- a/addons/weather/functions/fnc_updateTemperature.sqf +++ b/addons/weather/functions/fnc_updateTemperature.sqf @@ -3,10 +3,10 @@ * Updates GVAR(currentTemperature) based on the map data * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * [] call ace_weather_fnc_updateTemperature diff --git a/addons/weather/functions/fnc_updateWind.sqf b/addons/weather/functions/fnc_updateWind.sqf index 72ae0470ba..a179c98dda 100644 --- a/addons/weather/functions/fnc_updateWind.sqf +++ b/addons/weather/functions/fnc_updateWind.sqf @@ -3,10 +3,10 @@ * Updates wind, gusts and waves based on ACE_wind * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: * [] call ace_weather_fnc_updateWind diff --git a/addons/winddeflection/functions/fnc_handleFired.sqf b/addons/winddeflection/functions/fnc_handleFired.sqf index e78620471d..2411c608d4 100644 --- a/addons/winddeflection/functions/fnc_handleFired.sqf +++ b/addons/winddeflection/functions/fnc_handleFired.sqf @@ -6,7 +6,7 @@ * None. Parameters inherited from EFUNC(common,firedEH) * * Return Value: - * Nothing + * None * * Example: * [clientFiredBIS-XEH] call ace_advanced_ballistics_fnc_handleFired diff --git a/addons/winddeflection/functions/fnc_initModuleSettings.sqf b/addons/winddeflection/functions/fnc_initModuleSettings.sqf index 037ce15c47..52847d15ee 100644 --- a/addons/winddeflection/functions/fnc_initModuleSettings.sqf +++ b/addons/winddeflection/functions/fnc_initModuleSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_winddeflection_fnc_initModuelSettings + * * Public: No */ diff --git a/addons/winddeflection/functions/fnc_updateTrajectoryPFH.sqf b/addons/winddeflection/functions/fnc_updateTrajectoryPFH.sqf index 358a434dfa..5920bbb3e4 100644 --- a/addons/winddeflection/functions/fnc_updateTrajectoryPFH.sqf +++ b/addons/winddeflection/functions/fnc_updateTrajectoryPFH.sqf @@ -7,9 +7,10 @@ * 1: airFriction - air friction of the bullet * * Return Value: - * Nothing + * None * * Example: + * [bullet, 2] call ace_winddeflection_fnc_updateTrajectoryPFH * * Public: No */ diff --git a/addons/yardage450/functions/fnc_acquireTarget.sqf b/addons/yardage450/functions/fnc_acquireTarget.sqf index 2b04900171..d3709186c9 100644 --- a/addons/yardage450/functions/fnc_acquireTarget.sqf +++ b/addons/yardage450/functions/fnc_acquireTarget.sqf @@ -3,12 +3,13 @@ * Fires the laser to acquire the target * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: + * call ace_yardage450_fnc_acquireTarget * * Public: No */ diff --git a/addons/yardage450/functions/fnc_turnOn.sqf b/addons/yardage450/functions/fnc_turnOn.sqf index a56bddb016..28e9c1da2d 100644 --- a/addons/yardage450/functions/fnc_turnOn.sqf +++ b/addons/yardage450/functions/fnc_turnOn.sqf @@ -3,12 +3,13 @@ * Shows the Yardage 450 screen elements * * Arguments: - * Nothing + * None * * Return Value: - * Nothing + * None * * Example: + * call ace_yardage450_fnc_acquireTarget * * Public: No */ diff --git a/addons/zeus/functions/fnc_addObjectToCurator.sqf b/addons/zeus/functions/fnc_addObjectToCurator.sqf index cab5b3da6f..230f035eb3 100644 --- a/addons/zeus/functions/fnc_addObjectToCurator.sqf +++ b/addons/zeus/functions/fnc_addObjectToCurator.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [object] call ace_zeus_fnc_addObjectToCurator + * * Public: No */ diff --git a/addons/zeus/functions/fnc_bi_moduleCurator.sqf b/addons/zeus/functions/fnc_bi_moduleCurator.sqf index 66395fbb0c..b556b08197 100644 --- a/addons/zeus/functions/fnc_bi_moduleCurator.sqf +++ b/addons/zeus/functions/fnc_bi_moduleCurator.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_bi_moduleCurator + * * Public: No */ diff --git a/addons/zeus/functions/fnc_bi_moduleMine.sqf b/addons/zeus/functions/fnc_bi_moduleMine.sqf index 940dd94f38..434130ffe6 100644 --- a/addons/zeus/functions/fnc_bi_moduleMine.sqf +++ b/addons/zeus/functions/fnc_bi_moduleMine.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_bi_moduleMine + * * Public: No */ diff --git a/addons/zeus/functions/fnc_bi_moduleProjectile.sqf b/addons/zeus/functions/fnc_bi_moduleProjectile.sqf index 70002cc215..eaad90c6d6 100644 --- a/addons/zeus/functions/fnc_bi_moduleProjectile.sqf +++ b/addons/zeus/functions/fnc_bi_moduleProjectile.sqf @@ -12,6 +12,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_bi_moduleProjectile + * * Public: No */ diff --git a/addons/zeus/functions/fnc_bi_moduleRemoteControl.sqf b/addons/zeus/functions/fnc_bi_moduleRemoteControl.sqf index 79cd35477f..6d2d3fd950 100644 --- a/addons/zeus/functions/fnc_bi_moduleRemoteControl.sqf +++ b/addons/zeus/functions/fnc_bi_moduleRemoteControl.sqf @@ -11,6 +11,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_bi_moduleRemoteControl + * * Public: No */ diff --git a/addons/zeus/functions/fnc_handleZeusUnitAssigned.sqf b/addons/zeus/functions/fnc_handleZeusUnitAssigned.sqf index fada3f1e32..8c0c4370d2 100644 --- a/addons/zeus/functions/fnc_handleZeusUnitAssigned.sqf +++ b/addons/zeus/functions/fnc_handleZeusUnitAssigned.sqf @@ -14,6 +14,9 @@ * Return Value: * None * + * Example: + * [LOGIC, bob] call ace_zeus_fnc_handleZeusUnitAssigned + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleAddOrRemoveFRIES.sqf b/addons/zeus/functions/fnc_moduleAddOrRemoveFRIES.sqf index d75c0173fe..5b05d256f4 100644 --- a/addons/zeus/functions/fnc_moduleAddOrRemoveFRIES.sqf +++ b/addons/zeus/functions/fnc_moduleAddOrRemoveFRIES.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleAddOrRemoveFRIES + * * Public: No */ #include "script_component.hpp" diff --git a/addons/zeus/functions/fnc_moduleAddSpareTrack.sqf b/addons/zeus/functions/fnc_moduleAddSpareTrack.sqf index 3a291ac5b3..56d3dca9d9 100644 --- a/addons/zeus/functions/fnc_moduleAddSpareTrack.sqf +++ b/addons/zeus/functions/fnc_moduleAddSpareTrack.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleAddSpareTrack + * * Public: No */ #include "script_component.hpp" diff --git a/addons/zeus/functions/fnc_moduleAddSpareWheel.sqf b/addons/zeus/functions/fnc_moduleAddSpareWheel.sqf index 50dc25d62c..da9327af7a 100644 --- a/addons/zeus/functions/fnc_moduleAddSpareWheel.sqf +++ b/addons/zeus/functions/fnc_moduleAddSpareWheel.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleAddSpareWheel + * * Public: No */ #include "script_component.hpp" diff --git a/addons/zeus/functions/fnc_moduleCaptive.sqf b/addons/zeus/functions/fnc_moduleCaptive.sqf index 4db34231c0..dc216e6289 100644 --- a/addons/zeus/functions/fnc_moduleCaptive.sqf +++ b/addons/zeus/functions/fnc_moduleCaptive.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleCaptive + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleGlobalSetSkill.sqf b/addons/zeus/functions/fnc_moduleGlobalSetSkill.sqf index 58e7ad19c5..ce864e85b0 100644 --- a/addons/zeus/functions/fnc_moduleGlobalSetSkill.sqf +++ b/addons/zeus/functions/fnc_moduleGlobalSetSkill.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleGlobalSetSkill + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleSearchNearby.sqf b/addons/zeus/functions/fnc_moduleSearchNearby.sqf index 47b423fadd..30d545e6d9 100644 --- a/addons/zeus/functions/fnc_moduleSearchNearby.sqf +++ b/addons/zeus/functions/fnc_moduleSearchNearby.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleSearchNearby + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleSetMedic.sqf b/addons/zeus/functions/fnc_moduleSetMedic.sqf index 55b1f2687b..c9dba36e40 100644 --- a/addons/zeus/functions/fnc_moduleSetMedic.sqf +++ b/addons/zeus/functions/fnc_moduleSetMedic.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleSetMedic + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleSetMedicalFacility.sqf b/addons/zeus/functions/fnc_moduleSetMedicalFacility.sqf index e0a3131f44..479cfad803 100644 --- a/addons/zeus/functions/fnc_moduleSetMedicalFacility.sqf +++ b/addons/zeus/functions/fnc_moduleSetMedicalFacility.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleSetMedicalFacility + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleSetMedicalVehicle.sqf b/addons/zeus/functions/fnc_moduleSetMedicalVehicle.sqf index 49070dbfb9..c295b609d2 100644 --- a/addons/zeus/functions/fnc_moduleSetMedicalVehicle.sqf +++ b/addons/zeus/functions/fnc_moduleSetMedicalVehicle.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleSetMedicalVehicle + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleSimulation.sqf b/addons/zeus/functions/fnc_moduleSimulation.sqf index fe7f3564e0..fc6d6e4a06 100644 --- a/addons/zeus/functions/fnc_moduleSimulation.sqf +++ b/addons/zeus/functions/fnc_moduleSimulation.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [LOGIC] call ace_zeus_fnc_moduleSimulation + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleSuppressiveFire.sqf b/addons/zeus/functions/fnc_moduleSuppressiveFire.sqf index 4d18c3f6e4..1d510fec55 100644 --- a/addons/zeus/functions/fnc_moduleSuppressiveFire.sqf +++ b/addons/zeus/functions/fnc_moduleSuppressiveFire.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleSuppressiveFire + * * Public: No */ // #define DRAW_ZEUS_INFO diff --git a/addons/zeus/functions/fnc_moduleSuppressiveFireLocal.sqf b/addons/zeus/functions/fnc_moduleSuppressiveFireLocal.sqf index 7ab7365c3b..7b11b7e18f 100644 --- a/addons/zeus/functions/fnc_moduleSuppressiveFireLocal.sqf +++ b/addons/zeus/functions/fnc_moduleSuppressiveFireLocal.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [bob, [5, 6, 7], "bigmagazine"] call ace_zeus_fnc_moduleSuppressiveFireLocal + * * Public: No */ #include "script_component.hpp" diff --git a/addons/zeus/functions/fnc_moduleSurrender.sqf b/addons/zeus/functions/fnc_moduleSurrender.sqf index 5e4890ae75..b97d2715ff 100644 --- a/addons/zeus/functions/fnc_moduleSurrender.sqf +++ b/addons/zeus/functions/fnc_moduleSurrender.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleSurrender + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleUnconscious.sqf b/addons/zeus/functions/fnc_moduleUnconscious.sqf index 0cf0fffda6..d99ef6cd27 100644 --- a/addons/zeus/functions/fnc_moduleUnconscious.sqf +++ b/addons/zeus/functions/fnc_moduleUnconscious.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleUnconscious + * * Public: No */ diff --git a/addons/zeus/functions/fnc_moduleZeusSettings.sqf b/addons/zeus/functions/fnc_moduleZeusSettings.sqf index 0b4e3b4027..b52c597c2c 100644 --- a/addons/zeus/functions/fnc_moduleZeusSettings.sqf +++ b/addons/zeus/functions/fnc_moduleZeusSettings.sqf @@ -10,6 +10,9 @@ * Return Value: * None * + * Example: + * [LOGIC, [bob, kevin], true] call ace_zeus_fnc_moduleZeusSettings + * * Public: No */ diff --git a/addons/zeus/functions/fnc_showMessage.sqf b/addons/zeus/functions/fnc_showMessage.sqf index 9ce8ced9c3..c91c90093a 100644 --- a/addons/zeus/functions/fnc_showMessage.sqf +++ b/addons/zeus/functions/fnc_showMessage.sqf @@ -8,7 +8,7 @@ * N: Anything * * Return Value: - * Nothing + * None * * Example: * ["something"] call ace_zeus_fnc_showMessage diff --git a/addons/zeus/functions/fnc_ui_attributeCargo.sqf b/addons/zeus/functions/fnc_ui_attributeCargo.sqf index 49e5c6b2ea..fb57362fa1 100644 --- a/addons/zeus/functions/fnc_ui_attributeCargo.sqf +++ b/addons/zeus/functions/fnc_ui_attributeCargo.sqf @@ -9,6 +9,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_attributeCargo + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_attributePosition.sqf b/addons/zeus/functions/fnc_ui_attributePosition.sqf index d6ae581ae4..e0396e2c03 100644 --- a/addons/zeus/functions/fnc_ui_attributePosition.sqf +++ b/addons/zeus/functions/fnc_ui_attributePosition.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_attributePosition + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_attributeRadius.sqf b/addons/zeus/functions/fnc_ui_attributeRadius.sqf index 7330d1b170..3c4d296f91 100644 --- a/addons/zeus/functions/fnc_ui_attributeRadius.sqf +++ b/addons/zeus/functions/fnc_ui_attributeRadius.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_attributeRadius + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_defendArea.sqf b/addons/zeus/functions/fnc_ui_defendArea.sqf index 5d4f652950..13de25c2fa 100644 --- a/addons/zeus/functions/fnc_ui_defendArea.sqf +++ b/addons/zeus/functions/fnc_ui_defendArea.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_defendArea + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_editableObjects.sqf b/addons/zeus/functions/fnc_ui_editableObjects.sqf index 040bd2630f..8cb243849e 100644 --- a/addons/zeus/functions/fnc_ui_editableObjects.sqf +++ b/addons/zeus/functions/fnc_ui_editableObjects.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_editableObjects + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_globalSetSkill.sqf b/addons/zeus/functions/fnc_ui_globalSetSkill.sqf index 68ffc95033..edca781152 100644 --- a/addons/zeus/functions/fnc_ui_globalSetSkill.sqf +++ b/addons/zeus/functions/fnc_ui_globalSetSkill.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_globalSetSkill + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_groupSide.sqf b/addons/zeus/functions/fnc_ui_groupSide.sqf index e983d49ea1..90de9d06ca 100644 --- a/addons/zeus/functions/fnc_ui_groupSide.sqf +++ b/addons/zeus/functions/fnc_ui_groupSide.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_groupSide + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_patrolArea.sqf b/addons/zeus/functions/fnc_ui_patrolArea.sqf index c94e2b3dd2..c026bbce6a 100644 --- a/addons/zeus/functions/fnc_ui_patrolArea.sqf +++ b/addons/zeus/functions/fnc_ui_patrolArea.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_patrolArea + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_searchArea.sqf b/addons/zeus/functions/fnc_ui_searchArea.sqf index 30e012e29b..06393ca578 100644 --- a/addons/zeus/functions/fnc_ui_searchArea.sqf +++ b/addons/zeus/functions/fnc_ui_searchArea.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_searchArea + * * Public: No */ diff --git a/addons/zeus/functions/fnc_ui_teleportPlayers.sqf b/addons/zeus/functions/fnc_ui_teleportPlayers.sqf index 94a734ab4e..d323a9a467 100644 --- a/addons/zeus/functions/fnc_ui_teleportPlayers.sqf +++ b/addons/zeus/functions/fnc_ui_teleportPlayers.sqf @@ -8,6 +8,9 @@ * Return Value: * None * + * Example: + * [CONTROL] call ace_zeus_fnc_ui_teleportPlayers + * * Public: No */ From f35f80ee828adb4c9dbbcd8f285f9a9a0cb02d59 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 8 Jun 2017 11:47:52 -0500 Subject: [PATCH 27/36] Rearm - Pylon Support and Dynamically Add Supply Actions (#5183) * Dynamic Add * Support 1.70 Pylon Loadouts * Properly handle old compat pbos - Update RHS Compat * Re-add documentation * cleanup headers (note from other pr) * Cleanup * Fix var spelling --- .../functions/fnc_displayTextStructured.sqf | 2 +- addons/common/script_component.hpp | 2 +- addons/rearm/CfgVehicles.hpp | 135 ++++------------ addons/rearm/XEH_PREP.hpp | 5 +- addons/rearm/XEH_postInit.sqf | 8 + .../functions/fnc_addMagazineToSupply.sqf | 33 ++-- .../rearm/functions/fnc_addRearmActions.sqf | 123 ++++++++------- .../fnc_addVehicleMagazinesToSupply.sqf | 31 ++-- .../functions/fnc_canReadSupplyCounter.sqf | 16 +- .../rearm/functions/fnc_canRearmVehicle.sqf | 29 ---- addons/rearm/functions/fnc_canStoreAmmo.sqf | 15 +- addons/rearm/functions/fnc_canTakeAmmo.sqf | 14 +- addons/rearm/functions/fnc_createDummy.sqf | 2 + addons/rearm/functions/fnc_disable.sqf | 2 +- .../functions/fnc_getConfigMagazines.sqf | 58 ------- .../functions/fnc_getHardpointMagazines.sqf | 39 +++++ .../functions/fnc_getNeedRearmMagazines.sqf | 45 +++++- addons/rearm/functions/fnc_getSupplyCount.sqf | 19 ++- .../functions/fnc_getVehicleMagazines.sqf | 11 +- addons/rearm/functions/fnc_grabAmmo.sqf | 2 +- .../rearm/functions/fnc_hasEnoughSupply.sqf | 72 +++++---- .../rearm/functions/fnc_initSupplyVehicle.sqf | 76 +++++++++ .../rearm/functions/fnc_magazineInSupply.sqf | 42 ----- .../rearm/functions/fnc_readSupplyCounter.sqf | 12 +- addons/rearm/functions/fnc_rearm.sqf | 24 ++- .../functions/fnc_rearmEntireVehicle.sqf | 2 +- .../fnc_rearmEntireVehicleSuccessLocal.sqf | 48 +++--- addons/rearm/functions/fnc_rearmSuccess.sqf | 27 ++-- .../rearm/functions/fnc_rearmSuccessLocal.sqf | 33 ++-- .../fnc_removeMagazineFromSupply.sqf | 18 ++- addons/rearm/functions/fnc_setSupplyCount.sqf | 14 +- addons/rearm/functions/fnc_storeAmmo.sqf | 2 +- addons/rearm/functions/fnc_takeAmmo.sqf | 3 +- addons/rearm/functions/fnc_takeSuccess.sqf | 9 +- addons/rearm/script_component.hpp | 7 + docs/wiki/feature/rearm.md | 32 +++- docs/wiki/framework/rearm-framework.md | 149 ++++++++++++++++++ optionals/compat_rhs_afrf3/CfgVehicles.hpp | 26 +-- optionals/compat_rhs_usf3/CfgVehicles.hpp | 32 +--- 39 files changed, 678 insertions(+), 541 deletions(-) delete mode 100644 addons/rearm/functions/fnc_canRearmVehicle.sqf delete mode 100644 addons/rearm/functions/fnc_getConfigMagazines.sqf create mode 100644 addons/rearm/functions/fnc_getHardpointMagazines.sqf create mode 100644 addons/rearm/functions/fnc_initSupplyVehicle.sqf delete mode 100644 addons/rearm/functions/fnc_magazineInSupply.sqf diff --git a/addons/common/functions/fnc_displayTextStructured.sqf b/addons/common/functions/fnc_displayTextStructured.sqf index 97dab5773d..ee2c6a9f3f 100644 --- a/addons/common/functions/fnc_displayTextStructured.sqf +++ b/addons/common/functions/fnc_displayTextStructured.sqf @@ -6,7 +6,7 @@ * 0: Text * 1: Size of the textbox (default: 1.5) * 2: Target Unit. Will only display if target is the player controlled object (default: ACE_player) - * 3: Custom Width (optional) + * 3: Custom Width (default: 10) * * Return Value: * None diff --git a/addons/common/script_component.hpp b/addons/common/script_component.hpp index 66f7ac63bf..4504cd9653 100644 --- a/addons/common/script_component.hpp +++ b/addons/common/script_component.hpp @@ -3,7 +3,7 @@ #include "\z\ace\addons\main\script_mod.hpp" // #define DEBUG_MODE_FULL -// #define DISABLE_COMPILE_CACHE +#define DISABLE_COMPILE_CACHE // #define ENABLE_PERFORMANCE_COUNTERS #ifdef DEBUG_ENABLED_COMMON diff --git a/addons/rearm/CfgVehicles.hpp b/addons/rearm/CfgVehicles.hpp index ce12e4f48b..de141c2837 100644 --- a/addons/rearm/CfgVehicles.hpp +++ b/addons/rearm/CfgVehicles.hpp @@ -1,64 +1,16 @@ - #define MACRO_REARM_ACTIONS \ - class ACE_Actions { \ - class ACE_MainActions { \ - class GVAR(Rearm) { \ - displayName = CSTRING(Rearm); \ - distance = REARM_ACTION_DISTANCE; \ - condition = QUOTE(_this call FUNC(canRearm)); \ - statement = QUOTE(_this call FUNC(rearm)); \ - exceptions[] = {"isNotInside"}; \ - icon = QPATHTOF(ui\icon_rearm_interact.paa); \ - }; \ + class ACE_Actions { \ + class ACE_MainActions { \ + class GVAR(Rearm) { \ + displayName = CSTRING(Rearm); \ + distance = REARM_ACTION_DISTANCE; \ + condition = QUOTE(_this call FUNC(canRearm)); \ + statement = QUOTE(_this call FUNC(rearm)); \ + exceptions[] = {"isNotInside"}; \ + icon = QPATHTOF(ui\icon_rearm_interact.paa); \ }; \ - }; - -#define MACRO_REARM_TRUCK_ACTIONS \ - class ACE_Actions: ACE_Actions { \ - class ACE_MainActions: ACE_MainActions { \ - class GVAR(ReadSupplyCounter) { \ - displayName = CSTRING(ReadSupplyCounter); \ - distance = REARM_ACTION_DISTANCE; \ - condition = QUOTE(_this call FUNC(canReadSupplyCounter)); \ - statement = QUOTE(_this call FUNC(readSupplyCounter)); \ - exceptions[] = {"isNotInside"}; \ - showDisabled = 0; \ - priority = 2; \ - icon = PATHTOF(ui\icon_rearm_interact.paa); \ - }; \ - class GVAR(Rearm) { \ - displayName = CSTRING(Rearm); \ - distance = REARM_ACTION_DISTANCE; \ - condition = QUOTE(_this call FUNC(canRearmVehicle)); \ - insertChildren = QUOTE(_target call FUNC(addRearmActions)); \ - exceptions[] = {"isNotInside"}; \ - showDisabled = 0; \ - priority = 2; \ - icon = PATHTOF(ui\icon_rearm_interact.paa); \ - }; \ - class GVAR(TakeAmmo) { \ - displayName = CSTRING(TakeAmmo); \ - distance = REARM_ACTION_DISTANCE; \ - condition = QUOTE(_this call FUNC(canTakeAmmo)); \ - insertChildren = QUOTE(_target call FUNC(addRearmActions)); \ - exceptions[] = {"isNotInside"}; \ - showDisabled = 0; \ - priority = 2; \ - icon = QPATHTOF(ui\icon_rearm_interact.paa); \ - }; \ - class GVAR(StoreAmmo) { \ - displayName = CSTRING(StoreAmmo); \ - distance = REARM_ACTION_DISTANCE; \ - condition = QUOTE(_this call FUNC(canStoreAmmo)); \ - statement = QUOTE(_this call FUNC(storeAmmo)); \ - exceptions[] = {"isNotInside"}; \ - icon = QPATHTOF(ui\icon_rearm_interact.paa); \ - }; \ - }; \ - }; - -#define MACRO_REARM_DEFAULT_SUPPLY \ - GVAR(defaultSupply) = 1200; + }; \ + }; class CBA_Extended_EventHandlers; @@ -148,96 +100,71 @@ class CfgVehicles { MACRO_REARM_ACTIONS }; - - // Ammo Vehicles (with full inheritance for granted ACE_Actions) - class Car_F: Car {}; - class Truck_F: Car_F {}; - class Tank_F: Tank {}; - - class Truck_03_base_F: Truck_F {}; + class Truck_03_base_F; class O_Truck_03_ammo_F: Truck_03_base_F { transportAmmo = 0; - MACRO_REARM_DEFAULT_SUPPLY - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; - class Truck_02_base_F: Truck_F {}; - class Truck_02_Ammo_base_F: Truck_02_base_F {}; + class Truck_02_Ammo_base_F; class I_Truck_02_ammo_F: Truck_02_Ammo_base_F { transportAmmo = 0; - MACRO_REARM_DEFAULT_SUPPLY - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; class O_Truck_02_Ammo_F: Truck_02_Ammo_base_F { transportAmmo = 0; - MACRO_REARM_DEFAULT_SUPPLY - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; - class Truck_01_base_F: Truck_F {}; - class B_Truck_01_transport_F: Truck_01_base_F {}; - class B_Truck_01_mover_F: B_Truck_01_transport_F {}; + class B_Truck_01_mover_F; class B_Truck_01_ammo_F: B_Truck_01_mover_F { transportAmmo = 0; - MACRO_REARM_DEFAULT_SUPPLY - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; - class APC_Tracked_01_base_F: Tank_F {}; - class B_APC_Tracked_01_base_F: APC_Tracked_01_base_F {}; + class B_APC_Tracked_01_base_F; class B_APC_Tracked_01_CRV_F: B_APC_Tracked_01_base_F { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; - class Helicopter_Base_F: Helicopter {}; - class Helicopter_Base_H: Helicopter_Base_F {}; - class Heli_Transport_04_base_F: Helicopter_Base_H {}; + class Heli_Transport_04_base_F; class O_Heli_Transport_04_ammo_F: Heli_Transport_04_base_F { transportAmmo = 0; - MACRO_REARM_DEFAULT_SUPPLY - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; - class ThingX; - class ReammoBox_F: ThingX { - class ACE_Actions { - class ACE_MainActions {}; - }; - }; - class Slingload_base_F: ReammoBox_F {}; - class Slingload_01_Base_F: Slingload_base_F {}; - - class Pod_Heli_Transport_04_base_F: Slingload_base_F {}; + class Pod_Heli_Transport_04_base_F; class Land_Pod_Heli_Transport_04_ammo_F: Pod_Heli_Transport_04_base_F { transportAmmo = 0; - MACRO_REARM_DEFAULT_SUPPLY - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; + class Slingload_01_Base_F; class B_Slingload_01_Ammo_F: Slingload_01_Base_F { transportAmmo = 0; - MACRO_REARM_DEFAULT_SUPPLY - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; + class ReammoBox_F; class NATO_Box_Base: ReammoBox_F{}; class Box_NATO_AmmoVeh_F: NATO_Box_Base { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; class EAST_Box_Base: ReammoBox_F{}; class Box_East_AmmoVeh_F: EAST_Box_Base { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; class IND_Box_Base: ReammoBox_F{}; class Box_IND_AmmoVeh_F: IND_Box_Base { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + GVAR(defaultSupply) = 1200; }; // Dummy Vehicles + class ThingX; class GVAR(defaultCarriedObject): ThingX { class EventHandlers { class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; diff --git a/addons/rearm/XEH_PREP.hpp b/addons/rearm/XEH_PREP.hpp index 03e08fd4b0..59a43b4b29 100644 --- a/addons/rearm/XEH_PREP.hpp +++ b/addons/rearm/XEH_PREP.hpp @@ -4,14 +4,13 @@ PREP(addRearmActions); PREP(addVehicleMagazinesToSupply); PREP(canReadSupplyCounter); PREP(canRearm); -PREP(canRearmVehicle); PREP(canStoreAmmo); PREP(canTakeAmmo); PREP(createDummy); PREP(disable); PREP(dropAmmo); PREP(getCaliber); -PREP(getConfigMagazines); +PREP(getHardpointMagazines); PREP(getMaxMagazines); PREP(getNeedRearmMagazines); PREP(getSupplyCount); @@ -20,7 +19,7 @@ PREP(grabAmmo); PREP(handleKilled); PREP(handleUnconscious); PREP(hasEnoughSupply); -PREP(magazineInSupply); +PREP(initSupplyVehicle); PREP(makeDummy); PREP(moduleRearmSettings); PREP(pickUpAmmo); diff --git a/addons/rearm/XEH_postInit.sqf b/addons/rearm/XEH_postInit.sqf index 56cf067dba..50ab97cb07 100644 --- a/addons/rearm/XEH_postInit.sqf +++ b/addons/rearm/XEH_postInit.sqf @@ -1,5 +1,13 @@ #include "script_component.hpp" +GVAR(hardpointGroupsCache) = [] call CBA_fnc_createNamespace; +GVAR(configTypesAdded) = []; +["ace_settingsInitialized", { + TRACE_2("settingsInit",GVAR(level),GVAR(supply)); + ["LandVehicle", "Init", {_this call FUNC(initSupplyVehicle)}, true, ["StaticWeapon"], true] call CBA_fnc_addClassEventHandler; + ["ReammoBox_F", "Init", {_this call FUNC(initSupplyVehicle)}, true, [], true] call CBA_fnc_addClassEventHandler; +}] call CBA_fnc_addEventHandler; + ["ace_unconscious", LINKFUNC(handleUnconscious)] call CBA_fnc_addEventHandler; ["vehicle", { params ["_unit"]; diff --git a/addons/rearm/functions/fnc_addMagazineToSupply.sqf b/addons/rearm/functions/fnc_addMagazineToSupply.sqf index e401c6e4f0..0a3be574f8 100644 --- a/addons/rearm/functions/fnc_addMagazineToSupply.sqf +++ b/addons/rearm/functions/fnc_addMagazineToSupply.sqf @@ -1,11 +1,11 @@ /* * Author: GitHawk - * Adds magazines to the supply. + * Adds magazines to the supply. [Global Effects] * * Arguments: * 0: Ammo Truck * 1: Magazine Classname - * 2: Only partial (optional) + * 2: Only partial (default: false) * * Return Value: * None @@ -17,27 +17,30 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]], - ["_magazineClass", "", [""]], - ["_partial", false, [false]] -]; +if !(EGVAR(common,settingsInitFinished)) exitWith { // only run this after the settings are initialized + EGVAR(common,runAtSettingsInitialized) pushBack [FUNC(addMagazineToSupply), _this]; +}; -if (isNull _truck || - {_magazineClass isEqualTo ""} || - {GVAR(supply) == 0}) exitWith {}; +params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]], ["_partial", false, [false]]]; +TRACE_3("addMagazineToSupply",_truck,_magazineClass,_partial); + +if (GVAR(supply) == 0) exitWith {WARNING("supply setting is set to unlimited");}; + +if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {}; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; - + // With limited supply, we add the caliber to the supply count if (GVAR(supply) == 1) then { private _supply = [_truck] call FUNC(getSupplyCount); - if (!_partial || {GVAR(level) == 1}) then { - [_truck, _supply + _cal] call FUNC(setSupplyCount); + private _amountToAdd = if (!_partial || {GVAR(level) == 1}) then { + _cal } else { private _magazinePart = ((REARM_COUNT select _idx) / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; - [_truck, (_supply + (_cal * _magazinePart))] call FUNC(setSupplyCount); + _cal * _magazinePart }; + TRACE_1("Adding",_amountToAdd); + [_truck, (_supply + _amountToAdd)] call FUNC(setSupplyCount); }; // With magazine specific supply, we add or update the magazineSupply array @@ -56,7 +59,7 @@ if (GVAR(supply) == 2) then { _roundsPerTransaction = _roundsPerTransaction min (REARM_COUNT select _idx); }; if (_magazineIdx == -1) then { - if (count _magazineSupply == 0) then { + if (_magazineSupply isEqualTo []) then { _magazineSupply = [[_magazineClass, _roundsPerTransaction]]; } else { _magazineSupply append [[_magazineClass, _roundsPerTransaction]]; diff --git a/addons/rearm/functions/fnc_addRearmActions.sqf b/addons/rearm/functions/fnc_addRearmActions.sqf index fea1414252..c017c93509 100644 --- a/addons/rearm/functions/fnc_addRearmActions.sqf +++ b/addons/rearm/functions/fnc_addRearmActions.sqf @@ -15,77 +15,92 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]] -]; +params [["_truck", objNull, [objNull]]]; private _vehicles = nearestObjects [_truck, ["AllVehicles"], 20]; -if (count _vehicles < 2) exitWith {false}; // Rearming needs at least 2 vehicles +_vehicles = _vehicles select {(_x != _truck) && {!(_x isKindOf "CAManBase")} && {!(_x getVariable [QGVAR(disabled), false])}}; private _vehicleActions = []; { - private _actions = []; private _vehicle = _x; - private _needToAdd = false; - private _action = []; - if !((_vehicle == _truck) || (_vehicle isKindOf "CAManBase")) then { - private _magazineHelper = []; + private _magazineHelper = []; + { + private _turretPath = _x; + private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); { - private _turretPath = _x; - private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); - { - private _magazine = _x; + private _magazine = _x; + if (!(_magazine in _magazineHelper)) then { private _currentMagazines = { _x == _magazine } count (_vehicle magazinesTurret _turretPath); - if ((_currentMagazines < ([_vehicle, _turretPath, _magazine] call FUNC(getMaxMagazines))) && !(_magazine in _magazineHelper)) then { - _action = [_magazine, - getText(configFile >> "CfgMagazines" >> _magazine >> "displayName"), - getText(configFile >> "CfgMagazines" >> _magazine >> "picture"), - {_this call FUNC(takeAmmo)}, - {true}, - {}, - [_magazine, _vehicle]] call EFUNC(interact_menu,createAction); - if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_truck, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_truck, _magazine] call FUNC(magazineInSupply))}) then { - _actions pushBack [_action, [], _truck]; - _magazineHelper pushBack _magazine; - _needToAdd = true; - }; - } else { - if (((_vehicle magazineTurretAmmo [_magazine, _turretPath]) < getNumber (configFile >> "CfgMagazines" >> _magazine >> "count")) && !(_magazine in _magazineHelper)) then { - _action = [_magazine, - getText(configFile >> "CfgMagazines" >> _magazine >> "displayName"), - getText(configFile >> "CfgMagazines" >> _magazine >> "picture"), - {_this call FUNC(takeAmmo)}, - {true}, - {}, - [_magazine, _vehicle]] call EFUNC(interact_menu,createAction); - if (GVAR(supply) == 0 || {(GVAR(supply) == 1) && ([_truck, _magazine] call FUNC(hasEnoughSupply))} || {(GVAR(supply) == 2) && ([_truck, _magazine] call FUNC(magazineInSupply))}) then { - _actions pushBack [_action, [], _truck]; - _magazineHelper pushBack _magazine; - _needToAdd = true; - }; - }; + private _maxMagazines = [_vehicle, _turretPath, _magazine] call FUNC(getMaxMagazines); + + if ((_currentMagazines < _maxMagazines) || {(_vehicle magazineTurretAmmo [_magazine, _turretPath]) < getNumber (configFile >> "CfgMagazines" >> _magazine >> "count")}) then { + _magazineHelper pushBack _magazine; }; - false - } count _magazines; + }; false - } count REARM_TURRET_PATHS; - }; - if (_needToAdd && !(_vehicle getVariable [QGVAR(disabled), false])) then { + } count _magazines; + false + } count REARM_TURRET_PATHS; + + // 1.70 pylons + private _pylonConfigs = configProperties [configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "Components" >> "TransportPylonsComponent" >> "Pylons", "isClass _x"]; + { + private _pylonName = configName _x; + private _pylonAmmo = _vehicle ammoOnPylon _pylonName; + private _pylonMagazine = (getPylonMagazines _vehicle) select _forEachIndex; + TRACE_3("",_pylonName,_pylonAmmo,_pylonMagazine); + + if (_pylonAmmo > 0) then { + // Try to refill current pylon: + private _magAmmo = getNumber (configFile >> "CfgMagazines" >> _pylonMagazine >> "count"); + if ((!(_pylonMagazine in _magazineHelper)) && {_pylonAmmo < _magAmmo}) then { + _magazineHelper pushBack _pylonMagazine; + }; + } else { + // See what we magazines can add to the empty pylon: + private _hardpointMags = [_x] call FUNC(getHardpointMagazines); + { + if (!(_x in _magazineHelper)) then { + _magazineHelper pushBack _x; + }; + } forEach _hardpointMags; + }; + } forEach _pylonConfigs; + + _magazineHelper = _magazineHelper select {[_truck, _x] call FUNC(hasEnoughSupply)}; + TRACE_2("can add",_x,_magazineHelper); + + if (!(_magazineHelper isEqualTo [])) then { private _icon = getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "Icon"); if !((_icon select [0, 1]) == "\") then { _icon = ""; }; if (GVAR(level) == 0) then { - _action = [_vehicle, - getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName"), - _icon, - {_this call FUNC(rearmEntireVehicle)}, - {true}, - {}, - _vehicle] call EFUNC(interact_menu,createAction); + // [Level 0] adds a single action to rearm the entire vic + private _action = [_vehicle, + getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName"), + _icon, + {_this call FUNC(rearmEntireVehicle)}, + {true}, + {}, + _vehicle] call EFUNC(interact_menu,createAction); _vehicleActions pushBack [_action, [], _truck]; } else { - _action = [_vehicle, + // [Level 1,2] - Add actions for each magazine + private _actions = []; + { + private _action = [_x, + getText(configFile >> "CfgMagazines" >> _x >> "displayName"), + getText(configFile >> "CfgMagazines" >> _x >> "picture"), + {_this call FUNC(takeAmmo)}, + {true}, + {}, + [_x, _vehicle]] call EFUNC(interact_menu,createAction); + + _actions pushBack [_action, [], _truck]; + } forEach _magazineHelper; + + private _action = [_vehicle, getText(configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "displayName"), _icon, {}, diff --git a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf index b7f695ce9d..087ea7fddd 100644 --- a/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf +++ b/addons/rearm/functions/fnc_addVehicleMagazinesToSupply.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Ammo Truck - * 1: Vehicle or Vehicle class + * 1: Vehicle object or Vehicle class * * Return Value: * None @@ -17,24 +17,33 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]], - ["_vehicle", objNull, [objNull, ""]] -]; +if !(EGVAR(common,settingsInitFinished)) exitWith { // only run this after the settings are initialized + EGVAR(common,runAtSettingsInitialized) pushBack [FUNC(addVehicleMagazinesToSupply), _this]; +}; -if (isNull _truck || - {_vehicle isEqualType objNull}) exitWith {}; +params [["_truck", objNull, [objNull]], ["_vehicle", objNull, [objNull, ""]]]; +TRACE_2("addVehicleMagazinesToSupply",_truck,_vehicle); -private _string = [_vehicle, typeOf _vehicle] select (_vehicle isEqualType objNull); -if (_string == "") exitWith { - ERROR_1("_string [%1] is empty in ace_rearm_fnc_addVehicleMagazinesToSupply",_string); +if (isNull _truck) exitWith {}; +if (_vehicle isEqualType objNull) then {_vehicle = typeOf _vehicle}; +if (_vehicle == "") exitWith { + ERROR_1("VehicleType [%1] is empty in ace_rearm_fnc_addVehicleMagazinesToSupply",_string); }; { private _turretPath = _x; - private _magazines = [_string, _turretPath] call FUNC(getConfigMagazines); + private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); + TRACE_2("",_turretPath,_magazines); { [_truck, _x] call FUNC(addMagazineToSupply); false } count _magazines; false } count REARM_TURRET_PATHS; + +// 1.70 pylons +private _pylonConfigs = configProperties [configFile >> "CfgVehicles" >> _vehicle >> "Components" >> "TransportPylonsComponent" >> "Pylons", "isClass _x"]; +{ + private _defaultMag = getText (_x >> "attachment"); + TRACE_3("",_defaultMag,configName _x,_forEachIndex); + [_truck, _defaultMag] call FUNC(addMagazineToSupply); +} forEach _pylonConfigs; diff --git a/addons/rearm/functions/fnc_canReadSupplyCounter.sqf b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf index 5b09b14304..80b5d35cd7 100644 --- a/addons/rearm/functions/fnc_canReadSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_canReadSupplyCounter.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk - * Checks if unit can read supply counter. + * Checks if unit can read supply counter. [Only for GVAR(supply) > 0] * * Arguments: * 0: Ammo Truck @@ -21,9 +21,11 @@ params [ ["_unit", objNull, [objNull]] ]; -!(isNull _unit || - {!(_unit isKindOf "CAManBase")} || - {!local _unit} || - {!alive _truck} || - {(_truck distance _unit) > REARM_ACTION_DISTANCE} || - {GVAR(supply) == 0}) +(alive _unit) +&& {_unit isKindOf "CAManBase"} +&& {local _unit} +&& {alive _truck} +&& {(_truck distance _unit) < REARM_ACTION_DISTANCE} +&& {GVAR(supply) > 0} +&& {[_unit, _truck, ["IsNotInside"]] call EFUNC(common,canInteractWith)} // manually added actions need this + diff --git a/addons/rearm/functions/fnc_canRearmVehicle.sqf b/addons/rearm/functions/fnc_canRearmVehicle.sqf deleted file mode 100644 index 3ab09a83f7..0000000000 --- a/addons/rearm/functions/fnc_canRearmVehicle.sqf +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Author: GitHawk - * Check if a unit can rearm a vehicle. - * - * Arguments: - * 0: Vehicle - * 1: Unit - * - * Return Value: - * Can Pick Up Ammo - * - * Example: - * [tank, player] call ace_rearm_fnc_canRearmVehicle - * - * Public: No - */ -#include "script_component.hpp" - -params [ - ["_vehicle", objNull, [objNull]], - ["_unit", objNull, [objNull]] -]; - -!(isNull _unit || - {!(_unit isKindOf "CAManBase")} || - {!local _unit} || - {(_vehicle distance _unit) > REARM_ACTION_DISTANCE} || - {!isNull (_unit getVariable [QGVAR(dummy), objNull])} || - {GVAR(level) > 0}) diff --git a/addons/rearm/functions/fnc_canStoreAmmo.sqf b/addons/rearm/functions/fnc_canStoreAmmo.sqf index a9e4fe981e..b303af372c 100644 --- a/addons/rearm/functions/fnc_canStoreAmmo.sqf +++ b/addons/rearm/functions/fnc_canStoreAmmo.sqf @@ -20,10 +20,11 @@ params [ ["_truck", objNull, [objNull]], ["_unit", objNull, [objNull]] ]; - -!(isNull _unit || - {!alive _truck} || - {!(_unit isKindOf "CAManBase")} || - {!local _unit} || - {(_truck distance _unit) > REARM_ACTION_DISTANCE} || - {isNull (_unit getVariable [QGVAR(dummy), objNull])}) + +(alive _unit) +&& {_unit isKindOf "CAManBase"} +&& {local _unit} +&& {!isNull (_unit getVariable [QGVAR(dummy), objNull])} +&& {alive _truck} +&& {(_truck distance _unit) < REARM_ACTION_DISTANCE} +&& {[_unit, _truck, ["IsNotInside"]] call EFUNC(common,canInteractWith)} // manually added actions need this diff --git a/addons/rearm/functions/fnc_canTakeAmmo.sqf b/addons/rearm/functions/fnc_canTakeAmmo.sqf index 83bf89bd92..6f15f46eb0 100644 --- a/addons/rearm/functions/fnc_canTakeAmmo.sqf +++ b/addons/rearm/functions/fnc_canTakeAmmo.sqf @@ -21,10 +21,10 @@ params [ ["_unit", objNull, [objNull]] ]; -!(isNull _unit || - {!alive _truck} || - {!(_unit isKindOf "CAManBase")} || - {!local _unit} || - {(_truck distance _unit) > REARM_ACTION_DISTANCE} || - {!isNull (_unit getVariable [QGVAR(dummy), objNull])} || - {GVAR(level) == 0}) +(alive _unit) +&& {_unit isKindOf "CAManBase"} +&& {local _unit} +&& {alive _truck} +&& {(_truck distance _unit) < REARM_ACTION_DISTANCE} +&& {isNull (_unit getVariable [QGVAR(dummy), objNull])} +&& {[_unit, _truck, ["IsNotInside"]] call EFUNC(common,canInteractWith)} // manually added actions need this diff --git a/addons/rearm/functions/fnc_createDummy.sqf b/addons/rearm/functions/fnc_createDummy.sqf index 08326ca889..ecdaf9ff55 100644 --- a/addons/rearm/functions/fnc_createDummy.sqf +++ b/addons/rearm/functions/fnc_createDummy.sqf @@ -32,4 +32,6 @@ if !(_dummyName == "") then { _dummy allowDamage false; _dummy setVariable [QGVAR(magazineClass), _magazineClass, true]; +TRACE_4("createdDummy",_unit,_magazineClass,_dummyName,_dummy); + _dummy diff --git a/addons/rearm/functions/fnc_disable.sqf b/addons/rearm/functions/fnc_disable.sqf index 4f7a6e81ff..0bfe9f2b3d 100644 --- a/addons/rearm/functions/fnc_disable.sqf +++ b/addons/rearm/functions/fnc_disable.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk - * Disables rearm for a vehicle. + * Disables being able to rearm a vehicle's turrets. [Global Effects] * * Arguments: * 0: Vehicle diff --git a/addons/rearm/functions/fnc_getConfigMagazines.sqf b/addons/rearm/functions/fnc_getConfigMagazines.sqf deleted file mode 100644 index 82dcf7936c..0000000000 --- a/addons/rearm/functions/fnc_getConfigMagazines.sqf +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Author: GitHawk, Jonpas - * Returns all magazines a turret of a vehicle class can hold according to config. - * - * Arguments: - * 0: Vehicle class - * 1: Turret Path - * - * Return Value: - * Magazine classes in TurretPath - * - * Example: - * ["B_MBT_01_arty_F", [0]] call ace_rearm_fnc_getConfigMagazines - * - * Public: No - */ -#include "script_component.hpp" - -params [ - ["_cfgString", "", [""]], - ["_turretPath", [], [[]]] -]; - -if (_cfgString == "") exitWith {[]}; - -private _cfg = configFile >> "CfgVehicles" >> _cfgString >> "Turrets"; - -if !(isClass _cfg) exitWith {[]}; - -if (count _turretPath == 1) then { - _turretPath params ["_subPath"]; - - if (_subPath == -1) exitWith { - _cfg = configFile >> "CfgVehicles" >> _cfgString; - }; - - if (count _cfg > _subPath) then { - _cfg = _cfg select _subPath; - } else { - _cfg = nil; - }; -} else { - _turretPath params ["", "_subPath"]; - if (count _cfg > 0) then { - _cfg = (_cfg select 0) >> "Turrets"; - if (count _cfg > _subPath) then { - _cfg = _cfg select _subPath; - } else { - _cfg = nil; - }; - } else { - _cfg = nil; - }; -}; - -if !(isClass _cfg) exitWith {[]}; - -getArray (_cfg >> "magazines") diff --git a/addons/rearm/functions/fnc_getHardpointMagazines.sqf b/addons/rearm/functions/fnc_getHardpointMagazines.sqf new file mode 100644 index 0000000000..2a00fa8eb6 --- /dev/null +++ b/addons/rearm/functions/fnc_getHardpointMagazines.sqf @@ -0,0 +1,39 @@ +/* + * Author: PabstMirror + * Gets possible magazines that can be added to a pylon. + * + * Arguments: + * 0: Pylon config + * + * Return Value: + * Magazines + * + * Example: + * [config] call ace_rearm_fnc_getHardpointMagazines + * + * Public: No + */ +#include "script_component.hpp" + +params ["_pylonConfig"]; + +private _return = GVAR(hardpointGroupsCache) getVariable (str _pylonConfig); +if (isNil "_return") then { + _return = []; + private _hardpoints = (getArray (_pylonConfig >> "hardpoints")) apply {toLower _x}; + private _maxWeight = if (isNumber (_pylonConfig >> "maxWeight")) then {getNumber (_pylonConfig >> "maxWeight")} else {1e5}; + private _mags = configProperties [configFile >> "CfgMagazines", "(isClass _x) && {isArray (_x >> 'hardpoints')}"]; + { + if ((getNumber (_x >> "mass")) < _maxWeight) then { + private _magHardpoints = (getArray (_x >> "hardpoints")) apply {toLower _x}; + if (!((_hardpoints arrayIntersect _magHardpoints) isEqualTo [])) then { + _return pushBack configName _x; + }; + }; + } forEach _mags; + if ((str _pylonConfig) != "") then { + GVAR(hardpointGroupsCache) setVariable [(str _pylonConfig), _return]; + }; +}; + +_return; diff --git a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf index 2000b83818..6b2620a99a 100644 --- a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf +++ b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf @@ -11,6 +11,7 @@ * 0: Can Rearm * 1: TurretPath * 2: Number of current magazines in turret path + * 3: Pylon Index (-1 if not a pylon) * * Example: * [tank, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_getNeedRearmMagazines @@ -19,12 +20,9 @@ */ #include "script_component.hpp" -params [ - ["_vehicle", objNull, [objNull]], - ["_magazineClass", "", [""]] -]; +params [["_vehicle", objNull, [objNull]], ["_magazineClass", "", [""]]]; -private _return = [false, [], 0]; +private _return = [false, [], 0, -1]; { private _magazines = [_vehicle, _x] call FUNC(getVehicleMagazines); @@ -32,11 +30,11 @@ private _return = [false, [], 0]; private _currentMagazines = {_x == _magazineClass} count (_vehicle magazinesTurret _x); if ((_vehicle magazineTurretAmmo [_magazineClass, _x]) < getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count")) exitWith { - _return = [true, _x, _currentMagazines]; + _return = [true, _x, _currentMagazines, -1]; }; if (_currentMagazines < ([_vehicle, _x, _magazineClass] call FUNC(getMaxMagazines))) exitWith { - _return = [true, _x, _currentMagazines]; + _return = [true, _x, _currentMagazines, -1]; }; }; @@ -44,4 +42,37 @@ private _return = [false, [], 0]; false } count REARM_TURRET_PATHS; +if (!(_return select 0)) then { + // 1.70 pylons + private _pylonConfigs = configProperties [configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "Components" >> "TransportPylonsComponent" >> "Pylons", "isClass _x"]; + { + private _pylonName = configName _x; + private _pylonIndex = _forEachIndex + 1; // WTF BIS + private _pylonAmmo = _vehicle ammoOnPylon _pylonName; + private _pylonMagazine = (getPylonMagazines _vehicle) select _forEachIndex; + private _pylonTurret = getArray (_x >> "turret"); + if (_pylonTurret isEqualTo []) then {_pylonTurret = [-1];}; // convert to expected array for driver + TRACE_4("",_pylonName,_pylonAmmo,_pylonMagazine,_pylonTurret); + + if (_pylonAmmo > 0) then { + if (_magazineClass == _pylonMagazine) then { // Try to refill current pylon: + private _magAmmo = getNumber (configFile >> "CfgMagazines" >> _pylonMagazine >> "count"); + if (_pylonAmmo < _magAmmo) then { + _return = [true, _pylonTurret, 0, _pylonIndex]; + }; + }; + } else { + // See what we magazines can add to the empty pylon: + private _hardpointMags = [_x] call FUNC(getHardpointMagazines); + { + if (_x == _magazineClass) then { + _return = [true, _pylonTurret, 0, _pylonIndex]; + }; + } forEach _hardpointMags; + }; + if (_return select 0) exitWith {}; + } forEach _pylonConfigs; +}; + +TRACE_3("getNeedRearmMagazines",_vehicle,_magazineClass,_return); _return diff --git a/addons/rearm/functions/fnc_getSupplyCount.sqf b/addons/rearm/functions/fnc_getSupplyCount.sqf index 4c4cb4f81d..082ad7ab5c 100644 --- a/addons/rearm/functions/fnc_getSupplyCount.sqf +++ b/addons/rearm/functions/fnc_getSupplyCount.sqf @@ -15,15 +15,24 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]] -]; +params [["_truck", objNull, [objNull]]]; + +if (GVAR(supply) != 1) exitWith { + WARNING("supply setting is not set to limited"); // func shouldn't have been called + -1 +}; private _supply = _truck getVariable QGVAR(currentSupply); if (isNil "_supply") then { - _supply = getNumber (configFile >> "CfgVehicles" >> typeOf _truck >> QGVAR(defaultSupply)); - _truck setVariable [QGVAR(currentSupply), _supply, true]; + if (isNumber (configFile >> "CfgVehicles" >> typeOf _truck >> QGVAR(defaultSupply))) then { + _supply = getNumber (configFile >> "CfgVehicles" >> typeOf _truck >> QGVAR(defaultSupply)); + } else { + _supply = 1200; + }; + if (_supply > 0) then { + _truck setVariable [QGVAR(currentSupply), _supply, true]; + }; }; _supply diff --git a/addons/rearm/functions/fnc_getVehicleMagazines.sqf b/addons/rearm/functions/fnc_getVehicleMagazines.sqf index 26da24df0c..6a0932d908 100644 --- a/addons/rearm/functions/fnc_getVehicleMagazines.sqf +++ b/addons/rearm/functions/fnc_getVehicleMagazines.sqf @@ -3,7 +3,7 @@ * Returns all magazines a turret of a vehicle object can hold according to config. * * Arguments: - * 0: Vehicle + * 0: Vehicle object or typeOf * 1: Turret Path * * Return Value: @@ -16,11 +16,4 @@ */ #include "script_component.hpp" -params [ - ["_vehicle", objNull, [objNull]], - ["_turretPath", [], [[]]] -]; - -if (isNull _vehicle) exitWith {[]}; - -([typeOf _vehicle, _turretPath] call FUNC(getConfigMagazines)) +getArray ((_this call CBA_fnc_getTurret) >> "magazines") diff --git a/addons/rearm/functions/fnc_grabAmmo.sqf b/addons/rearm/functions/fnc_grabAmmo.sqf index 707b5c7548..a77a17284b 100644 --- a/addons/rearm/functions/fnc_grabAmmo.sqf +++ b/addons/rearm/functions/fnc_grabAmmo.sqf @@ -25,7 +25,7 @@ REARM_HOLSTER_WEAPON; [_unit, "forceWalk", QGVAR(vehRearm), true] call EFUNC(common,statusEffect_set); [ - 5, + TIME_PROGRESSBAR(5), [_dummy, _unit], { private ["_actionID"]; diff --git a/addons/rearm/functions/fnc_hasEnoughSupply.sqf b/addons/rearm/functions/fnc_hasEnoughSupply.sqf index a4f5e04217..a2944db014 100644 --- a/addons/rearm/functions/fnc_hasEnoughSupply.sqf +++ b/addons/rearm/functions/fnc_hasEnoughSupply.sqf @@ -1,42 +1,52 @@ /* - * Author: GitHawk - * Check whether enough supply is left to take the magazine. - * - * Arguments: - * 0: Ammo Truck - * 1: Magazine Classname - * - * Return Value: - * Enough supply - * - * Example: - * [ammo_truck, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_hasEnoughSupply - * - * Public: No - */ +* Author: GitHawk +* Check whether enough supply is left to take the magazine. +* +* Arguments: +* 0: Ammo Truck +* 1: Magazine Classname +* +* Return Value: +* Enough supply +* +* Example: +* [ammo_truck, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_hasEnoughSupply +* +* Public: No +*/ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]], - ["_magazineClass", "", [""]] -]; +params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]]]; -if (isNull _truck || - {_magazineClass isEqualTo ""}) exitWith {false}; +if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; // With infinite supply, there is always enough if (GVAR(supply) == 0) exitWith {true}; -// With magazine specific supply, we need to check stored magazines -if (GVAR(supply) == 2) exitWith {_this call FUNC(magazineInSupply)}; -private _supply = [_truck] call FUNC(getSupplyCount); -([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; -// With caliber based rearming, we only need partial supply -if (GVAR(level) == 2) exitWith { - // If REARM_COUNT is bigger than the magazine size, we might get a bigger number than 1 - private _magazinePart = ((REARM_COUNT select _idx) / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; - (_cal * _magazinePart <= _supply) +// With limited supply, we need to check supply +if (GVAR(supply) == 1) exitWith { + private _supply = [_truck] call FUNC(getSupplyCount); + ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; + + // With caliber based rearming, we only need partial supply + if (GVAR(level) == 2) exitWith { + // If REARM_COUNT is bigger than the magazine size, we might get a bigger number than 1 + private _magazinePart = ((REARM_COUNT select _idx) / (getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"))) min 1; + (_cal * _magazinePart <= _supply) + }; + (_cal <= _supply) }; -(_cal <= _supply) + +// With magazine specific supply, we need to check stored magazines +if (GVAR(supply) == 2) exitWith { + private _magazineSupply = _truck getVariable [QGVAR(magazineSupply), []]; + private _magazinePresent = false; + { + _x params ["_magazine", "_rounds"]; + if ((_magazine isEqualTo _magazineClass) && (_rounds > 0)) exitWith {_magazinePresent = true; }; + false + } count _magazineSupply; + _magazinePresent +}; diff --git a/addons/rearm/functions/fnc_initSupplyVehicle.sqf b/addons/rearm/functions/fnc_initSupplyVehicle.sqf new file mode 100644 index 0000000000..ad1b914328 --- /dev/null +++ b/addons/rearm/functions/fnc_initSupplyVehicle.sqf @@ -0,0 +1,76 @@ +/* + * Author: Githawk, PabstMirror + * Adds rearm supply actions to a vehicle or ammo container. + * + * Arguments: + * 0: Object + * + * Return Value: + * None + * + * Example: + * [ammoTruck] call ace_rearm_fnc_initSupplyVehicle; + * + * Public: No + */ +#include "script_component.hpp" + +if (!hasInterface) exitWith {}; // For now we just add actions, so no need non-clients + +params ["_vehicle"]; +private _typeOf = typeOf _vehicle; +TRACE_2("initSupplyVehicle",_vehicle,_typeOf); + +if (!alive _vehicle) exitWith {}; + +private _configSupply = getNumber (configFile >> "CfgVehicles" >> _typeOf >> QGVAR(defaultSupply)); +private _isSupplyVehicle = _vehicle getVariable [QGVAR(isSupplyVehicle), false]; +private _oldRearmConfig = isClass (configFile >> "CfgVehicles" >> _typeOf >> "ACE_Actions" >> "ACE_MainActions" >> QGVAR(takeAmmo)); +TRACE_3("",_configSupply,_isSupplyVehicle,_oldRearmConfig); + +if ((_configSupply <= 0) && {!_isSupplyVehicle} && {!_oldRearmConfig}) exitWith {}; // Ignore if not enabled +if ((_oldRearmConfig || {_configSupply > 0}) && {_typeOf in GVAR(configTypesAdded)}) exitWith {}; // Only add class actions once +if (_oldRearmConfig || {_configSupply > 0}) then {GVAR(configTypesAdded) pushBack _typeOf}; + + +private _actionReadSupplyCounter = [ // GVAR(supply) > 0 + QGVAR(ReadSupplyCounter), + localize LSTRING(ReadSupplyCounter), // Check remaining ammunition + QPATHTOF(ui\icon_rearm_interact.paa), + {_this call FUNC(readSupplyCounter)}, + {_this call FUNC(canReadSupplyCounter)} +] call EFUNC(interact_menu,createAction); + +private _actionTakeAmmo = [ + QGVAR(takeAmmo), + localize ([LSTRING(Rearm), LSTRING(TakeAmmo)] select (GVAR(level) > 0)), + QPATHTOF(ui\icon_rearm_interact.paa), + {}, + {_this call FUNC(canTakeAmmo)}, + {_this call FUNC(addRearmActions)} +] call EFUNC(interact_menu,createAction); + +private _actionStoreAmmo = [ + QGVAR(StoreAmmo), + localize LSTRING(StoreAmmo), // "Store ammo" + QPATHTOF(ui\icon_rearm_interact.paa), + {_this call FUNC(storeAmmo)}, + {_this call FUNC(canStoreAmmo)} +] call EFUNC(interact_menu,createAction); + +if (_oldRearmConfig || {_configSupply > 0}) then { + TRACE_1("Adding Class Actions",_typeOf); + [_typeOf, 0, ["ACE_MainActions"], _actionReadSupplyCounter] call EFUNC(interact_menu,addActionToClass); + if (!_oldRearmConfig) then { + [_typeOf, 0, ["ACE_MainActions"], _actionTakeAmmo] call EFUNC(interact_menu,addActionToClass); + [_typeOf, 0, ["ACE_MainActions"], _actionStoreAmmo] call EFUNC(interact_menu,addActionToClass); + } else { + WARNING_1("Actions already present on [%1]. Old Compat PBO?",_typeOf); + }; +} else { + TRACE_1("Adding Object Actions",_typeOf); + [_vehicle, 0, ["ACE_MainActions"], _actionReadSupplyCounter] call EFUNC(interact_menu,addActionToObject); + [_vehicle, 0, ["ACE_MainActions"], _actionTakeAmmo] call EFUNC(interact_menu,addActionToObject); + [_vehicle, 0, ["ACE_MainActions"], _actionStoreAmmo] call EFUNC(interact_menu,addActionToObject); +}; + diff --git a/addons/rearm/functions/fnc_magazineInSupply.sqf b/addons/rearm/functions/fnc_magazineInSupply.sqf deleted file mode 100644 index 627534219e..0000000000 --- a/addons/rearm/functions/fnc_magazineInSupply.sqf +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Author: GitHawk - * Returns true if the magazine is in the current supply - * - * Arguments: - * 0: Ammo Truck - * 1: Magazine Classname - * - * Return Value: - * Magazine in supply - * - * Example: - * [ammo_truck, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_magazineInSupply - * - * Public: No - */ -#include "script_component.hpp" - -params [ - ["_truck", objNull, [objNull]], - ["_magazineClass", "", [""]] -]; - -if (isNull _truck || - {_magazineClass isEqualTo ""}) exitWith {false}; - -// With limited supply, we need to check supply -if (GVAR(supply) == 1) exitWith {_this call FUNC(hasEnoughSupply)}; -// With magazine specific supply, we need to check them -if (GVAR(supply) == 2) exitWith { - private _magazineSupply = _truck getVariable [QGVAR(magazineSupply), []]; - private _magazinePresent = false; - { - _x params ["_magazine", "_rounds"]; - if ((_magazine isEqualTo _magazineClass) && (_rounds > 0)) exitWith {_magazinePresent = true; }; - false - } count _magazineSupply; - _magazinePresent -}; - -// With infinite supply, there is always one left -true diff --git a/addons/rearm/functions/fnc_readSupplyCounter.sqf b/addons/rearm/functions/fnc_readSupplyCounter.sqf index 214fe70a5e..cfcdb1b865 100644 --- a/addons/rearm/functions/fnc_readSupplyCounter.sqf +++ b/addons/rearm/functions/fnc_readSupplyCounter.sqf @@ -16,16 +16,14 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]], - ["_unit", objNull, [objNull]] -]; +params [["_truck", objNull, [objNull]],["_unit", objNull, [objNull]]]; +TRACE_2("readSupplyCounter",_truck,_unit); -if (GVAR(supply) == 0) exitWith {}; +if (GVAR(supply) == 0) exitWith {WARNING("Supply is unlimited");}; if (GVAR(supply) == 1) then { [ - 5, + TIME_PROGRESSBAR(5), [_unit, _truck, [_truck] call FUNC(getSupplyCount)], { params ["_args"]; @@ -44,7 +42,7 @@ if (GVAR(supply) == 1) then { ] call EFUNC(common,progressBar); } else { [ - 5, + TIME_PROGRESSBAR(5), [_unit, _truck], { params ["_args"]; diff --git a/addons/rearm/functions/fnc_rearm.sqf b/addons/rearm/functions/fnc_rearm.sqf index 8b28192e41..363a4905c7 100644 --- a/addons/rearm/functions/fnc_rearm.sqf +++ b/addons/rearm/functions/fnc_rearm.sqf @@ -16,37 +16,33 @@ */ #include "script_component.hpp" -params [ - ["_target", objNull, [objNull]], - ["_unit", objNull, [objNull]] -]; +params [["_target", objNull, [objNull]],["_unit", objNull, [objNull]]]; +TRACE_2("rearm",_target,_unit); private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; -if (isNull _attachedDummy) exitwith {false}; +if (isNull _attachedDummy) exitwith {ERROR_1("attachedDummy null",_attachedDummy);}; private _magazineClass = _attachedDummy getVariable QGVAR(magazineClass); -if (isNil "_magazineClass") exitWith {false}; +if (isNil "_magazineClass") exitWith {ERROR_1("magazineClass nil",_attachedDummy);}; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; // Get magazines that can be rearmed private _needRearmMags = [_target, _magazineClass] call FUNC(getNeedRearmMagazines); -_needRearmMags params ["_needRearm", "_turretPath", "_cnt"]; +_needRearmMags params ["_needRearm", "_turretPath", "_cnt", "_pylon"]; // Exit if no magazines need rearming -if (!_needRearm) exitWith { - diag_log format ["[ACE] ERROR: Could not find turret for %1 in %2", _magazineClass, typeOf _target]; -}; +if (!_needRearm) exitWith {ERROR_2("Could not find turret for %1 in %2", _magazineClass, typeOf _target);}; private _magazineDisplayName = getText(configFile >> "CfgMagazines" >> _magazineClass >> "displayName"); if (_magazineDisplayName == "") then { _magazineDisplayName = _magazineClass; - diag_log format ["[ACE] ERROR: Magazine is missing display name [%1]", _magazineClass]; + ERROR_1("Magazine is missing display name [%1]", _magazineClass); }; [ - (REARM_DURATION_REARM select _idx), - [_target, _unit, _turretPath, _cnt, _magazineClass, (REARM_COUNT select _idx)], - FUNC(rearmSuccess), + TIME_PROGRESSBAR(REARM_DURATION_REARM select _idx), + [_target, _unit, _turretPath, _cnt, _magazineClass, (REARM_COUNT select _idx), _pylon], + {(_this select 0) call FUNC(rearmSuccess)}, "", format [localize LSTRING(RearmAction), getText(configFile >> "CfgVehicles" >> (typeOf _target) >> "displayName"), _magazineDisplayName], {true}, diff --git a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf index 4da9475511..8fddb4ab85 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicle.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicle.sqf @@ -24,7 +24,7 @@ params [ ]; [ - 10, + TIME_PROGRESSBAR(10), [_truck, _vehicle], FUNC(rearmEntireVehicleSuccess), "", diff --git a/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf index 2e8327d7d4..01901fdf87 100644 --- a/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmEntireVehicleSuccessLocal.sqf @@ -17,11 +17,28 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]], - ["_vehicle", objNull, [objNull]], - ["_turretPath", [], [[]]] -]; +params [["_truck", objNull, [objNull]], ["_vehicle", objNull, [objNull]], ["_turretPath", [], [[]]]]; +TRACE_3("rearmEntireVehicleSuccessLocal",_truck,_vehicle,_turretPath); + +// 1.70 pylons +private _pylonConfigs = configProperties [configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "Components" >> "TransportPylonsComponent" >> "Pylons", "isClass _x"]; +{ + private _pylonTurret = getArray (_x >> "turret"); + if (_pylonTurret isEqualTo []) then {_pylonTurret = [-1];}; // convert to expected array for driver + if (_pylonTurret isEqualTo _turretPath) then { + private _pylonIndex = _forEachIndex + 1; // GJ BIS + private _pylonAmmo = _vehicle ammoOnPylon _pylonIndex; + private _pylonMagazine = (getPylonMagazines _vehicle) select _forEachIndex; + private _maxRounds = getNumber (configFile >> "CfgMagazines" >> _pylonMagazine >> "count"); + TRACE_4("",_pylonIndex,_pylonAmmo,_maxRounds,_pylonMagazine); + if (_pylonAmmo < _maxRounds) then { + if ((GVAR(supply) == 0) || {[_truck, _pylonMagazine, (_maxRounds - _pylonAmmo)] call FUNC(removeMagazineFromSupply)}) then { + TRACE_3("Adding Rounds",_vehicle,_pylonIndex,_maxRounds); + _vehicle setAmmoOnPylon [_pylonIndex, _maxRounds]; + }; + }; + }; +} forEach _pylonConfigs; private _magazines = [_vehicle, _turretPath] call FUNC(getVehicleMagazines); if (isNil "_magazines") exitWith {}; @@ -40,27 +57,20 @@ if (isNil "_magazines") exitWith {}; }; if (_currentMagazines < _maxMagazines) then { private _success = true; - if (GVAR(supply) > 0) then { - _success = [_truck, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); - }; - if (_success) then { + if ((GVAR(supply) == 0) || {[_truck, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply)}) then { _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; - for "_idx" from 1 to (_maxMagazines - _currentMagazines) do { - _success = true; - if (GVAR(supply) > 0) then { - _success = [_truck, _magazine, _maxRounds] call FUNC(removeMagazineFromSupply); - }; + }; + + for "_idx" from 1 to (_maxMagazines - _currentMagazines) do { + if ((GVAR(supply) == 0) || {[_truck, _magazine, _maxRounds] call FUNC(removeMagazineFromSupply)}) then { _vehicle addMagazineTurret [_magazine, _turretPath]; }; }; } else { - private _success = true; - if (GVAR(supply) > 0) then { - _success = [_truck, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply); - }; - if (_success) then { + if ((GVAR(supply) == 0) || {[_truck, _magazine, (_maxRounds - _currentRounds)] call FUNC(removeMagazineFromSupply)}) then { _vehicle setMagazineTurretAmmo [_magazine, _maxRounds, _turretPath]; }; }; false } count _magazines; + diff --git a/addons/rearm/functions/fnc_rearmSuccess.sqf b/addons/rearm/functions/fnc_rearmSuccess.sqf index 8fc006148a..e49a236ea2 100644 --- a/addons/rearm/functions/fnc_rearmSuccess.sqf +++ b/addons/rearm/functions/fnc_rearmSuccess.sqf @@ -1,36 +1,35 @@ /* * Author: GitHawk - * Rearms a vehicle. + * Rearms a vehicle, after progress bar finishes, pass args to machine where turret is local. * * Arguments: - * 0: Params - * 0: Vehicle - * 1: Unit - * 2: Turret Path - * 3: Number of magazines - * 4: Magazine Classname - * 5: Number of rounds + * 0: Vehicle + * 1: Unit + * 2: Turret Path + * 3: Number of magazines + * 4: Magazine Classname + * 5: Number of rounds + * 6: Pylon Index * * Return Value: * None * * Example: - * [[vehicle, player, [-1], 2, "5000Rnd_762x51_Belt", 500]] call ace_rearm_fnc_rearmSuccess + * [vehicle, player, [-1], 2, "5000Rnd_762x51_Belt", 500, -1] call ace_rearm_fnc_rearmSuccess * * Public: No */ #include "script_component.hpp" -params [ - ["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]] -]; -_args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; -TRACE_6("rearmSuccess",_vehicle,_unit,_turretPath,_numMagazines,_magazineClass,_numRounds); +params [["_vehicle", objNull, [objNull]], ["_unit", objNull, [objNull]], "_turretPath", "_numMagazines", "_magazineClass", "_numRounds", "_pylon"]; +TRACE_7("rearmSuccess",_vehicle,_unit,_turretPath,_numMagazines,_magazineClass,_numRounds,_pylon); if (local _unit) then { [_unit, true, true] call FUNC(dropAmmo); }; +if (!alive _vehicle) exitWith {WARNING("vehicle dead/null");}; + if (isServer) then { private _turretOwnerID = _vehicle turretOwner _turretPath; if (_turretOwnerID == 0) then { diff --git a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf index f922f06eee..5ba5492ad4 100644 --- a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf @@ -3,31 +3,38 @@ * Rearms a vehicle on the turret owner. * * Arguments: - * 0: Params - * 0: Vehicle - * 1: Unit - * 2: Turret Path - * 3: Number of magazines - * 4: Magazine Classname - * 5: Number of rounds + * 0: Vehicle + * 1: Unit + * 2: Turret Path + * 3: Number of magazines + * 4: Magazine Classname + * 5: Number of rounds + * 6: Pylon Index * * Return Value: * None * * Example: - * [[vehicle, player, [-1], 2, "5000Rnd_762x51_Belt", 500]] call ace_rearm_fnc_rearmSuccessLocal + * [vehicle, player, [-1], 2, "5000Rnd_762x51_Belt", 500, ""] call ace_rearm_fnc_rearmSuccessLocal * * Public: No */ #include "script_component.hpp" -params [ - ["_args", [objNull, objNull, [], 0, "", 0], [[]], [6]] -]; -_args params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds"]; -TRACE_6("rearmSuccessLocal",_vehicle,_unit,_turretPath,_numMagazines,_magazineClass,_numRounds); +params ["_vehicle", "_unit", "_turretPath", "_numMagazines", "_magazineClass", "_numRounds", "_pylon"]; +TRACE_7("rearmSuccessLocal",_vehicle,_unit,_turretPath,_numMagazines,_magazineClass,_numRounds,_pylon); private _rounds = getNumber (configFile >> "CfgMagazines" >> _magazineClass >> "count"); + +if (_pylon > 0) exitWith { + if (_turretPath isEqualTo [-1]) then {_turretPath = [];}; // Convert back to pylon turret format + private _currentCount = _vehicle ammoOnPylon _pylon; + private _newCount = ((_currentCount max 0) + _numRounds) min _rounds; + TRACE_2("",_pylon,_magazineClass,_newCount); + _vehicle setPylonLoadOut [_pylon, _magazineClass, false, _turretPath]; + _vehicle setAmmoOnPylon [_pylon, _newCount]; +}; + private _currentRounds = 0; private _maxMagazines = [_vehicle, _turretPath, _magazineClass] call FUNC(getMaxMagazines); diff --git a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf index 967f6000cf..056ed26f48 100644 --- a/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf +++ b/addons/rearm/functions/fnc_removeMagazineFromSupply.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Ammo Truck * 1: Magazine Classname - * 2: Number of Rounds to withdraw (optional) + * 2: Number of Rounds to withdraw (default: -1) * * Return Value: * Magazine was removed @@ -17,18 +17,19 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]], - ["_magazineClass", "", [""]], - ["_numRounds", -1, [0]] -]; +params [["_truck", objNull, [objNull]], ["_magazineClass", "", [""]], ["_numRounds", -1, [0]]]; +TRACE_3("removeMagazineFromSupply",_truck,_magazineClass,_numRounds); -if (isNull _truck || - {_magazineClass isEqualTo ""}) exitWith {false}; +if (isNull _truck || {_magazineClass isEqualTo ""}) exitWith {false}; private _return = false; ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; +if (GVAR(supply) == 0) then { + WARNING("supply setting is set to unlimited"); // func shouldn't have been called + _return = true; +}; + if (GVAR(supply) == 1) then { private _supply = [_truck] call FUNC(getSupplyCount); if (GVAR(level) == 2) then { @@ -50,6 +51,7 @@ if (GVAR(supply) == 1) then { }; }; }; + if (GVAR(supply) == 2) then { private _magazineSupply = _truck getVariable [QGVAR(magazineSupply), []]; private _magazineIdx = -1; diff --git a/addons/rearm/functions/fnc_setSupplyCount.sqf b/addons/rearm/functions/fnc_setSupplyCount.sqf index c106d0ee5a..d9d5194550 100644 --- a/addons/rearm/functions/fnc_setSupplyCount.sqf +++ b/addons/rearm/functions/fnc_setSupplyCount.sqf @@ -1,6 +1,6 @@ /* * Author: GitHawk - * Sets the supply count. + * Sets the supply count. [Global Effects] * * Arguments: * 0: Ammo Truck @@ -16,11 +16,13 @@ */ #include "script_component.hpp" -params [ - ["_truck", objNull, [objNull]], - ["_supply", 0, [0]] -]; +if !(EGVAR(common,settingsInitFinished)) exitWith { // only run this after the settings are initialized + EGVAR(common,runAtSettingsInitialized) pushBack [FUNC(setSupplyCount), _this]; +}; -if (isNull _truck) exitWith {}; +params [["_truck", objNull, [objNull]], ["_supply", 0, [0]]]; + +if (GVAR(supply) != 1) exitWith {WARNING("supply setting is not set to limited");}; +if (isNull _truck) exitWith {WARNING_1("Truck is null [%1]", _truck);}; _truck setVariable [QGVAR(currentSupply), (_supply max 0), true]; diff --git a/addons/rearm/functions/fnc_storeAmmo.sqf b/addons/rearm/functions/fnc_storeAmmo.sqf index b59a75aaa9..c056421bba 100644 --- a/addons/rearm/functions/fnc_storeAmmo.sqf +++ b/addons/rearm/functions/fnc_storeAmmo.sqf @@ -25,7 +25,7 @@ private _attachedDummy = _unit getVariable [QGVAR(dummy), objNull]; if (isNull _attachedDummy) exitwith {}; [ - 5, + TIME_PROGRESSBAR(5), [_unit, _truck, _attachedDummy], { params ["_args"]; diff --git a/addons/rearm/functions/fnc_takeAmmo.sqf b/addons/rearm/functions/fnc_takeAmmo.sqf index 915be5e8a8..23f19fedf4 100644 --- a/addons/rearm/functions/fnc_takeAmmo.sqf +++ b/addons/rearm/functions/fnc_takeAmmo.sqf @@ -25,13 +25,14 @@ params [ ["_args", ["", objNull], [[]]] ]; _args params ["_magazineClass", "_vehicle"]; +TRACE_5("takeAmmo",_truck,_unit,_args,_magazineClass,_vehicle); ([_magazineClass] call FUNC(getCaliber)) params ["_cal", "_idx"]; REARM_HOLSTER_WEAPON; [ - (REARM_DURATION_TAKE select _idx), + TIME_PROGRESSBAR(REARM_DURATION_TAKE select _idx), [_unit, _magazineClass, _truck], FUNC(takeSuccess), "", diff --git a/addons/rearm/functions/fnc_takeSuccess.sqf b/addons/rearm/functions/fnc_takeSuccess.sqf index 831c2722bd..e458036176 100644 --- a/addons/rearm/functions/fnc_takeSuccess.sqf +++ b/addons/rearm/functions/fnc_takeSuccess.sqf @@ -18,16 +18,15 @@ */ #include "script_component.hpp" -params [ - ["_args", [objNull, "", objNull], [[]], 3] -]; +params [["_args", [objNull, "", objNull], [[]], 3]]; _args params ["_unit", "_magazineClass", "_truck"]; +TRACE_3("takeSuccess",_unit,_magazineClass,_truck); private _success = true; if (GVAR(supply) > 0) then { _success = [_truck, _magazineClass] call FUNC(removeMagazineFromSupply); }; -if !(_success) exitWith {}; +if !(_success) exitWith {WARNING_2("takeSuccess failed to take [%1] from [%2]",_magazineClass,_truck);}; [_unit, "forceWalk", QGVAR(vehRearm), true] call EFUNC(common,statusEffect_set); private _dummy = [_unit, _magazineClass] call FUNC(createDummy); @@ -41,6 +40,6 @@ private _actionID = _unit addAction [ false, true, "", - '!isNull (_truck getVariable [QGVAR(dummy), objNull])' + '!isNull (_target getVariable [QGVAR(dummy), objNull])' ]; _unit setVariable [QGVAR(ReleaseActionID), _actionID]; diff --git a/addons/rearm/script_component.hpp b/addons/rearm/script_component.hpp index c9ded7836d..3edfeda3f1 100644 --- a/addons/rearm/script_component.hpp +++ b/addons/rearm/script_component.hpp @@ -5,6 +5,7 @@ // #define DEBUG_MODE_FULL // #define DISABLE_COMPILE_CACHE // #define ENABLE_PERFORMANCE_COUNTERS +// #define FAST_PROGRESSBARS #ifdef DEBUG_ENABLED_REARM #define DEBUG_MODE_FULL @@ -38,3 +39,9 @@ _unit selectWeapon _weaponSelect; \ _unit setVariable [QGVAR(selectedWeaponOnRearm), nil]; \ }; + +#ifdef FAST_PROGRESSBARS + #define TIME_PROGRESSBAR(X) ((X) * 0.075) +#else + #define TIME_PROGRESSBAR(X) (X) +#endif diff --git a/docs/wiki/feature/rearm.md b/docs/wiki/feature/rearm.md index 3248ee4477..ae7fcb1612 100644 --- a/docs/wiki/feature/rearm.md +++ b/docs/wiki/feature/rearm.md @@ -17,14 +17,16 @@ version: This adds the option to rearm vehicles. The module settings allow you to configure ACE3 Rearm for both casual gaming and simulation game modes. Both the rearm speed and the availability of ammunition supply can be configured. -## 2. Rearming +## 2. Rearm Settings -### 2.1 Rearming a vehicle with setting `Entire vehicle` +## 2.1 Rearm Amount (`ace_rearm_level`) + +### 2.1.1 Rearming a vehicle with setting `Entire vehicle` - Interact with the ammo truck ⊞ Win (ACE3 default key bind `Interact Key`). - Move over `Rearm` and a list of vehicles within 20 meters that can be rearmed will be shown. - Select the vehicle from the list. It takes a few seconds to rearm the vehicle. -### 2.2 Rearming a vehicle with setting `Entire Magazine` +### 2.1.2 Rearming a vehicle with setting `Entire Magazine` - Interact with the ammo truck ⊞ Win (ACE3 default key bind `Interact Key`). - Move over `Take ammo` and a list of vehicles within 20 meters that can be rearmed will be shown. - Select the vehicle and the magazine from the list. You will pick up an ammo box. @@ -33,7 +35,7 @@ This adds the option to rearm vehicles. The module settings allow you to configu If a weapon carries multiple magazines of the same type, you have to repeat the procedure for every (partially) spent magazine. -### 2.3 Rearming a vehicle with setting `Amount based on caliber` +### 2.1.3 Rearming a vehicle with setting `Amount based on caliber` It's the same process as with setting `Entire Magazine`, but most magazines will require several ammo boxes. | Caliber in mm | 6 | 7 | 8 | 13 | 19 | 20 | 25 | 30 | 35 | 39 | 40 | 60 | 70 | 80 | 82 | 100 | 105 | 120 | 122 | 125 | 155 | 230 | 250 | @@ -43,6 +45,23 @@ It's the same process as with setting `Entire Magazine`, but most magazines will The caliber of the weapon will be rounded to the nearest number and the number of rounds is calculated using the table above. To fully rearm 2000 rounds of 7.62mm machine gun, you need five ammo boxes. +## 2.2 Ammunition supply (`ace_rearm_supply`) + +### 2.2.1 Unlimited +- Rearm vehicle has unlimited supply + +### 2.2.2 Limited ammo supply based on caliber +- Supply vehicle starts with a certian number of "points" (default is 1200) +- Resupplying vehicle will use up points based on number of rounds and caliber +- Can check number of points left on supply vehicle +- With 1000 points worth of ammunition supply, you can rearm four magazines of 250mm caliber (i.e. bombs) or eight magazines of 120mm caliber (i.e. tank rounds) or 125 magazines of 7.62mm caliber. + +### 2.2.3 Specific Magazines +- Supply vehicles start **empty** +- Magazines must be added via `ace_rearm_fnc_addMagazineToSupply` / `ace_rearm_fnc_addVehicleMagazinesToSupply` +- Can only resupply vehicles with specific magazines that have been loaded +- Can check what magazines are loaded on supply vehicle + ## 3. FAQ @@ -61,12 +80,13 @@ Mod developers can use the framework to use their custom models as ammo box repl ### Does rearm work with vehicles from mods? Yes, if the vehicle has the correct config entries or uses inheritance from vanilla ammo. Otherwise there is a compatibility mode. +Any vehicle can be turned into a supply vehicle by adding `this setVariable ["ace_rearm_isSupplyVehicle", true]` to it's init box. ### How do I replenish the ammunition supply on an ammo truck? -Please check the framework description for more details. +Please check the framework description for more details. ### The limited supply option `Only specific Magazines` doesn't work. What's wrong? -The mission creator has to use the framework to add specific magazines to the ammo truck(s). On this setting all ammo trucks are empty by default. For more information, please check the framework description. +The mission creator has to use the framework to add specific magazines to the ammo truck(s). On this setting all ammo trucks are empty by default. For more information, please check the framework description. ## 5. Dependencies diff --git a/docs/wiki/framework/rearm-framework.md b/docs/wiki/framework/rearm-framework.md index 630a5026be..1985fdf685 100644 --- a/docs/wiki/framework/rearm-framework.md +++ b/docs/wiki/framework/rearm-framework.md @@ -14,6 +14,8 @@ version: ## 1. Config Values +### 1.1 Ammo Configs + ```cpp class CfgAmmo { class MyLaserGuidedRocket { @@ -36,9 +38,80 @@ class CfgVehicles {

ace_rearm_dummy is only needed if you have a custom ammunition model. For each model you should create a dummy vehicle extending ace_rearm_defaultCarriedObject.

+### 1.2 Setting vehicle as a supply +A vehicle will be set as a supply vehicle based on the config `ace_rearm_defaultSupply` +```cpp +class MyTruck: Car_F { + ace_rearm_defaultSupply = 1200; +}; +``` +
+
Note:
+

Mission makers can also use `this setVariable ["ace_rearm_isSupplyVehicle", true]`

+
## 2. Functions +### 2.1 Adding specific magazines + +`ace_rearm_fnc_addMagazineToSupply` + + | Arguments | Type | Optional (default value) +---| --------- | ---- | ------------------------ +0 | Ammo Truck | Object | Required +1 | Magazine Classname | String | Required +2 | Only add content of one ammo box | Boolean | Optional (default: `false`) +**R** | None | None | Return value + +This function is most useful with the module setting `Only specific Magazines`. Note that this function only adds one magazine of a specific class. Other magazines of the same size are not available on this module setting. It has to be used to replenish the ammo truck on `Only specific Magazines` setting. + +This function can also be used to increase the supply count on setting `Limited ammo supply based on caliber` by a certain caliber value. + +#### 2.1.1 Example + +`[ammo_truck, "32Rnd_155mm_Mo_shells"] call ace_rearm_fnc_addMagazineToSupply;` + + | Arguments | Explanation +---| --------- | ----------- +0 | `ammo_truck` | My ammo truck object +1 | `"32Rnd_155mm_Mo_shells"` | Some magazine class + +The 32 artillery shells are added to the supply count or the magazine storage of the specified ammo truck. + +### 2.2 Adding all magazines of a specific vehicle + +`ace_rearm_fnc_addVehicleMagazinesToSupply` + + | Arguments | Type | Optional (default value) +---| --------- | ---- | ------------------------ +0 | Ammo Truck | Object | Required +1 | Any vehicle object or class name | Object or String | Required +**R** | None | None | Return value + +This functions wraps `ace_rearm_fnc_addMagazineToSupply` and uses it to add all default magazines of all supported turrets of the vehicle to the ammo truck. + +#### 2.2.1 Example 1 + +`[ammo_truck, tank] call ace_rearm_fnc_addVehicleMagazinesToSupply;` + + | Arguments | Explanation +---| --------- | ----------- +0 | `ammo_truck` | My ammo truck object +1 | `tank`| A vehicle object + +All magazines found in the class config of the object `tank` are made available. + +#### 2.2.2 Example 2 + +`[ammo_truck, "B_MBT_01_arty_F"] call ace_rearm_fnc_addVehicleMagazinesToSupply;` + + | Arguments | Explanation +---| --------- | ----------- +0 | `ammo_truck` | My ammo truck object +1 | `"B_MBT_01_arty_F"`| Vehicle class name + +All magazines found in the config of the vehicle class `B_MBT_01_arty_F` are made available. + ### 2.3 Enabling / disabling rearming `ace_rearm_fnc_disable` @@ -71,3 +144,79 @@ Disables rearming on the object `tank`. 1 | `false`| Rearming is enabled Enables rearming on the object `tank`. + +### 2.4 Getting the supply count + +`ace_rearm_fnc_getSupplyCount` + + | Arguments | Type | Optional (default value) +---| --------- | ---- | ------------------------ +0 | Ammo Truck | Object | Required +**R** | Supply count | Number | Return value + +This functions returns the current supply count of the ammo truck. + +#### 2.4.1 Example + +`[ammo_truck] call ace_rearm_fnc_getSupplyCount;` + + | Arguments | Explanation +---| --------- | ----------- +0 | `ammo_truck` | My object + +The remaining supply count of `ammo_truck` will be returned. + +### 2.5 Removing magazines from supply + +`ace_rearm_fnc_removeMagazineFromSupply` + + | Arguments | Type | Optional (default value) +---| --------- | ---- | ------------------------ +0 | Ammo Truck | Object | Required +1 | Magazine Classname | String | Required +2 | Number of Rounds to withdraw | Number | Optional (default: `-1`) +**R** | Magazine could be removed successfully | Boolean | Return value + +#### 2.5.1 Example 1 + +`[ammo_truck, "500Rnd_127x99_mag_Tracer_Red"] call ace_rearm_fnc_removeMagazineFromSupply;` + + | Arguments | Explanation +---| --------- | ----------- +0 | `ammo_truck` | My ammo truck object +1 | `"500Rnd_127x99_mag_Tracer_Red"`| Carrying is enabled + +Removes one ammo box worth of 500Rnd_127x99_mag_Tracer_Red from the supply. Depending on the module setting the ammo box does hold an entire magazine or only the caliber based amount of rounds. + +#### 2.5.2 Example 2 + +`[ammo_truck, "500Rnd_127x99_mag_Tracer_Red", 50] call ace_rearm_fnc_removeMagazineFromSupply;` + + | Arguments | Explanation +---| --------- | ----------- +0 | `ammo_truck` | My ammo truck object +1 | `"500Rnd_127x99_mag_Tracer_Red"`| Carrying is enabled +2 | `50` | Number of rounds + +Removes one ammo box with 50 rounds of 500Rnd_127x99_mag_Tracer_Red from the supply. This is 10% of the supply of an entire magazine. + +### 2.6 Setting the supply count + +`ace_rearm_fnc_setSupplyCount` + + | Arguments | Type | Optional (default value) +---| --------- | ---- | ------------------------ +0 | Ammo Truck | Object | Required +1 | Supply Count | Boolean | Required +**R** | None | None | Return value + +This function sets the current supply count of the ammo truck. It can be used to replenish the ammo truck on `Limited ammo supply based on caliber` setting. + +#### 2.6.1 Example + +`[ammo_truck, 1000] call ace_rearm_fnc_setSupplyCount;` + + | Arguments | Explanation +---| --------- | ----------- +0 | `ammo_truck` | My ammo truck object +1 | `1000`| Supply Count diff --git a/optionals/compat_rhs_afrf3/CfgVehicles.hpp b/optionals/compat_rhs_afrf3/CfgVehicles.hpp index 5771ea3e16..20ee84eea5 100644 --- a/optionals/compat_rhs_afrf3/CfgVehicles.hpp +++ b/optionals/compat_rhs_afrf3/CfgVehicles.hpp @@ -1,27 +1,3 @@ -#define MACRO_REARM_TRUCK_ACTIONS \ - class ACE_Actions: ACE_Actions { \ - class ACE_MainActions: ACE_MainActions { \ - class EGVAR(rearm,TakeAmmo) { \ - displayName = ECSTRING(rearm,TakeAmmo); \ - distance = 7; \ - condition = QUOTE(_this call EFUNC(rearm,canTakeAmmo)); \ - insertChildren = QUOTE(_target call EFUNC(rearm,addRearmActions)); \ - exceptions[] = {"isNotInside"}; \ - showDisabled = 0; \ - priority = 2; \ - icon = QPATHTOEF(rearm,ui\icon_rearm_interact.paa); \ - }; \ - class EGVAR(rearm,StoreAmmo) { \ - displayName = ECSTRING(rearm,StoreAmmo); \ - distance = 7; \ - condition = QUOTE(_this call EFUNC(rearm,canStoreAmmo)); \ - statement = QUOTE(_this call EFUNC(rearm,storeAmmo)); \ - exceptions[] = {"isNotInside"}; \ - icon = QPATHTOEF(rearm,ui\icon_rearm_interact.paa); \ - }; \ - }; \ - }; - #define MACRO_REFUEL_ACTIONS \ class ACE_Actions: ACE_Actions { \ class ACE_MainActions: ACE_MainActions { \ @@ -408,7 +384,7 @@ class CfgVehicles { class rhs_gaz66_ammo_base: rhs_gaz66_vmf { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + ace_rearm_supply = 1200; }; class MRAP_02_base_F; diff --git a/optionals/compat_rhs_usf3/CfgVehicles.hpp b/optionals/compat_rhs_usf3/CfgVehicles.hpp index 25ac08dfa0..e72a1a111f 100644 --- a/optionals/compat_rhs_usf3/CfgVehicles.hpp +++ b/optionals/compat_rhs_usf3/CfgVehicles.hpp @@ -11,30 +11,6 @@ }; \ } -#define MACRO_REARM_TRUCK_ACTIONS \ - class ACE_Actions: ACE_Actions { \ - class ACE_MainActions: ACE_MainActions { \ - class EGVAR(rearm,TakeAmmo) { \ - displayName = ECSTRING(rearm,TakeAmmo); \ - distance = 7; \ - condition = QUOTE(_this call EFUNC(rearm,canTakeAmmo)); \ - insertChildren = QUOTE(_target call EFUNC(rearm,addRearmActions)); \ - exceptions[] = {"isNotInside"}; \ - showDisabled = 0; \ - priority = 2; \ - icon = QPATHTOEF(rearm,ui\icon_rearm_interact.paa); \ - }; \ - class EGVAR(rearm,StoreAmmo) { \ - displayName = ECSTRING(rearm,StoreAmmo); \ - distance = 7; \ - condition = QUOTE(_this call EFUNC(rearm,canStoreAmmo)); \ - statement = QUOTE(_this call EFUNC(rearm,storeAmmo)); \ - exceptions[] = {"isNotInside"}; \ - icon = QPATHTOEF(rearm,ui\icon_rearm_interact.paa); \ - }; \ - }; \ - }; - #define MACRO_REFUEL_ACTIONS \ class ACE_Actions: ACE_Actions { \ class ACE_MainActions: ACE_MainActions { \ @@ -316,19 +292,19 @@ class CfgVehicles { class rhsusf_M977A4_usarmy_wd: rhsusf_HEMTT_A4_base {}; class rhsusf_M977A4_AMMO_usarmy_wd: rhsusf_M977A4_usarmy_wd { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + ace_rearm_supply = 1200; }; class rhsusf_M977A4_BKIT_usarmy_wd: rhsusf_M977A4_usarmy_wd {}; class rhsusf_M977A4_AMMO_BKIT_usarmy_wd: rhsusf_M977A4_BKIT_usarmy_wd { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + ace_rearm_supply = 1200; }; class rhsusf_M977A4_BKIT_M2_usarmy_wd: rhsusf_M977A4_usarmy_wd {}; class rhsusf_M977A4_AMMO_BKIT_M2_usarmy_wd: rhsusf_M977A4_BKIT_M2_usarmy_wd { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + ace_rearm_supply = 1200; }; class rhsusf_M978A4_usarmy_wd: rhsusf_M977A4_usarmy_wd { @@ -373,7 +349,7 @@ class CfgVehicles { class rhsusf_m113_usarmy: rhsusf_m113tank_base {}; class rhsusf_m113_usarmy_supply: rhsusf_m113_usarmy { transportAmmo = 0; - MACRO_REARM_TRUCK_ACTIONS + ace_rearm_supply = 1200; }; class APC_Tracked_03_base_F; From d1f4b90714062c0fcd9293e104d9b9fa8aeacbf3 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 8 Jun 2017 11:55:19 -0500 Subject: [PATCH 28/36] Fix minor debug that got left in (#5260) --- addons/common/script_component.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/common/script_component.hpp b/addons/common/script_component.hpp index 4504cd9653..66f7ac63bf 100644 --- a/addons/common/script_component.hpp +++ b/addons/common/script_component.hpp @@ -3,7 +3,7 @@ #include "\z\ace\addons\main\script_mod.hpp" // #define DEBUG_MODE_FULL -#define DISABLE_COMPILE_CACHE +// #define DISABLE_COMPILE_CACHE // #define ENABLE_PERFORMANCE_COUNTERS #ifdef DEBUG_ENABLED_COMMON From 55df8bca533310caf4602be830704c082d226c9c Mon Sep 17 00:00:00 2001 From: Phyma Date: Thu, 8 Jun 2017 19:10:35 +0200 Subject: [PATCH 29/36] Repair specialist rename, fixes #3186 (#5248) * Changed name * Fixed Enginner only german and removed big letters * Added docs + PR fixes #3186 * Removed other languages * Fixed request and added comment * Replace all usage of term "Specialist" --- addons/repair/ACE_Settings.hpp | 6 ++-- addons/repair/CfgEden.hpp | 2 +- addons/repair/CfgVehicles.hpp | 8 ++--- .../functions/fnc_getPostRepairDamage.sqf | 2 +- addons/repair/stringtable.xml | 31 ++++--------------- docs/team.md | 1 + 6 files changed, 16 insertions(+), 34 deletions(-) diff --git a/addons/repair/ACE_Settings.hpp b/addons/repair/ACE_Settings.hpp index 46228e2e44..0c05bc8459 100644 --- a/addons/repair/ACE_Settings.hpp +++ b/addons/repair/ACE_Settings.hpp @@ -12,7 +12,7 @@ class ACE_Settings { description = CSTRING(enginerSetting_Repair_description); typeName = "SCALAR"; value = 1; - values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)}; + values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_AdvancedOnly)}; category = ECSTRING(OptionsMenu,CategoryLogistics); }; class GVAR(engineerSetting_wheel) { @@ -20,7 +20,7 @@ class ACE_Settings { description = CSTRING(enginerSetting_Wheel_description); typeName = "SCALAR"; value = 0; - values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)}; + values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_AdvancedOnly)}; category = ECSTRING(OptionsMenu,CategoryLogistics); }; class GVAR(repairDamageThreshold) { @@ -58,7 +58,7 @@ class ACE_Settings { description = CSTRING(engineerSetting_fullRepair_description); typeName = "SCALAR"; value = 2; - values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)}; + values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_AdvancedOnly)}; category = ECSTRING(OptionsMenu,CategoryLogistics); }; class GVAR(addSpareParts) { diff --git a/addons/repair/CfgEden.hpp b/addons/repair/CfgEden.hpp index c11f0b96b8..1c1263755b 100644 --- a/addons/repair/CfgEden.hpp +++ b/addons/repair/CfgEden.hpp @@ -21,7 +21,7 @@ class Cfg3DEN { h = "5 * (pixelH * pixelGrid * 0.50)"; rows = 1; columns = 4; - strings[] = {"$STR_3DEN_Attributes_Lock_Default_text", CSTRING(AssignEngineerRole_role_none), CSTRING(AssignEngineerRole_role_engineer), CSTRING(AssignEngineerRole_role_specialist)}; + strings[] = {"$STR_3DEN_Attributes_Lock_Default_text", CSTRING(AssignEngineerRole_role_none), CSTRING(AssignEngineerRole_role_engineer), CSTRING(AssignEngineerRole_role_advanced)}; }; }; }; diff --git a/addons/repair/CfgVehicles.hpp b/addons/repair/CfgVehicles.hpp index 178e8ecb12..e06c18115b 100644 --- a/addons/repair/CfgVehicles.hpp +++ b/addons/repair/CfgVehicles.hpp @@ -38,7 +38,7 @@ class CfgVehicles { class values { class anyone { name = CSTRING(engineerSetting_anyone); value = 0; }; class Engineer { name = CSTRING(engineerSetting_EngineerOnly); value = 1; default = 1; }; - class Special { name = CSTRING(engineerSetting_RepairSpecialistOnly); value = 2; }; + class Advanced { name = CSTRING(engineerSetting_AdvancedOnly); value = 2; }; }; }; class engineerSetting_Wheel { @@ -48,7 +48,7 @@ class CfgVehicles { class values { class anyone { name = CSTRING(engineerSetting_anyone); value = 0; default = 1; }; class Engineer { name = CSTRING(engineerSetting_EngineerOnly); value = 1; }; - class Special { name = CSTRING(engineerSetting_RepairSpecialistOnly); value = 2; }; + class Advanced { name = CSTRING(engineerSetting_AdvancedOnly); value = 2; }; }; }; class repairDamageThreshold { @@ -91,7 +91,7 @@ class CfgVehicles { class values { class anyone { name = CSTRING(engineerSetting_anyone); value = 0; }; class Engineer { name = CSTRING(engineerSetting_EngineerOnly); value = 1; }; - class Special { name = CSTRING(engineerSetting_RepairSpecialistOnly); value = 2; default = 1;}; + class Advanced { name = CSTRING(engineerSetting_AdvancedOnly); value = 2; default = 1;}; }; }; class addSpareParts { @@ -150,7 +150,7 @@ class CfgVehicles { default = 1; }; class doctor { - name = CSTRING(AssignEngineerRole_role_specialist); + name = CSTRING(AssignEngineerRole_role_advanced); value = 2; }; }; diff --git a/addons/repair/functions/fnc_getPostRepairDamage.sqf b/addons/repair/functions/fnc_getPostRepairDamage.sqf index 9388f4474d..22eaf7a5f9 100644 --- a/addons/repair/functions/fnc_getPostRepairDamage.sqf +++ b/addons/repair/functions/fnc_getPostRepairDamage.sqf @@ -22,7 +22,7 @@ TRACE_1("params",_unit); if (([_unit] call FUNC(isInRepairFacility) || {[_unit] call FUNC(isNearRepairVehicle)})) exitWith {0}; private _class = _unit getVariable ["ACE_IsEngineer", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "engineer")]; -//If specialist or more qualified than min, then use engineer threshold: +//If advanced or more qualified than min, then use engineer threshold: if ((_class isEqualTo 2) || {[_unit, GVAR(engineerSetting_Repair) + 1] call FUNC(isEngineer)}) exitWith { (GVAR(repairDamageThreshold_Engineer) min GVAR(repairDamageThreshold)) }; diff --git a/addons/repair/stringtable.xml b/addons/repair/stringtable.xml index d1926a47eb..4e54ab39d0 100644 --- a/addons/repair/stringtable.xml +++ b/addons/repair/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -954,18 +954,8 @@ 工兵のみ 오직 정비공만 - - Repair Specialist only - Nur Reparaturspezialist - Tylko inżynierowie - Somente especialista em reparos - Только ремонтные специалисты - Pouze specialista na opravování - Solo especialista en reparación - Solo Specialista Riparazioni - Spécialistes de réparation seulement - 専門兵のみ - 오직 정비 특기만 + + Advanced Engineer only Allow Wheel @@ -1240,18 +1230,9 @@ 専門兵 정비공 - - Specialist - Reparaturspezialist - Inżynier - Especialista - Специалист - Specialista - Especialista - Specialista Riparazioni - Spécialiste - 工兵として単体、複数ユニットを割り当てます。 - 정비 특기 + + + Adv. Engineer Assign one or multiple units as an engineer diff --git a/docs/team.md b/docs/team.md index 4f1a8d5150..9a8f058cf3 100644 --- a/docs/team.md +++ b/docs/team.md @@ -110,6 +110,7 @@ tpM | ACSE Dev Lead - Sounds, SME * OnkelDisMaster * oscarmolinadev * PaxJaromeMalues +* Phyma * pokertour * Professor * rakowozz From 225d15dcca2062a197ec37e9e462c96d154fe724 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ozan=20E=C4=9Fitmen?= Date: Thu, 8 Jun 2017 22:31:25 +0400 Subject: [PATCH 30/36] Add Ability to Change Repair Times of Vehicles (#5205) * Add ability to change repair time based on vehicle * Much better * Unary command not function * Allow changing of track or wheel object per vehicle * Lot more complicated than I thought --- addons/repair/functions/fnc_repair.sqf | 38 ++++++++++++++++---------- 1 file changed, 23 insertions(+), 15 deletions(-) diff --git a/addons/repair/functions/fnc_repair.sqf b/addons/repair/functions/fnc_repair.sqf index d4f5412e6f..3ee6d4097f 100644 --- a/addons/repair/functions/fnc_repair.sqf +++ b/addons/repair/functions/fnc_repair.sqf @@ -177,23 +177,31 @@ if (vehicle _caller == _caller && {_callerAnim != ""}) then { [_caller, _callerAnim] call EFUNC(common,doAnimation); }; -//Get repair time -_repairTime = if (isNumber (_config >> "repairingTime")) then { - getNumber (_config >> "repairingTime"); -} else { - if (isText (_config >> "repairingTime")) exitWith { - _repairTimeConfig = getText(_config >> "repairingTime"); - if (isNil _repairTimeConfig) then { - _repairTimeConfig = compile _repairTimeConfig; - } else { - _repairTimeConfig = missionNamespace getVariable _repairTimeConfig; +// Get repair time +_repairTime = [ + configFile >> "CfgVehicles" >> typeOf _target >> QGVAR(repairTimes) >> configName _config, + "number", + -1 +] call CBA_fnc_getConfigEntry; + +if (_repairTime < 0) then { + _repairTime = if (isNumber (_config >> "repairingTime")) then { + getNumber (_config >> "repairingTime"); + } else { + if (isText (_config >> "repairingTime")) exitWith { + _repairTimeConfig = getText (_config >> "repairingTime"); + if (isNil _repairTimeConfig) then { + _repairTimeConfig = compile _repairTimeConfig; + } else { + _repairTimeConfig = missionNamespace getVariable _repairTimeConfig; + }; + if (_repairTimeConfig isEqualType 0) exitWith { + _repairTimeConfig; + }; + [_caller, _target, _hitPoint, _className] call _repairTimeConfig; }; - if (_repairTimeConfig isEqualType 0) exitWith { - _repairTimeConfig; - }; - [_caller, _target, _hitPoint, _className] call _repairTimeConfig; + 0; }; - 0; }; // Find localized string From 847832c11885287ad45ea817a6acdad32cd0a7b9 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 8 Jun 2017 14:31:27 -0500 Subject: [PATCH 31/36] Fix some event names on wiki (#5254) * Fix some event names on wiki * Switch callable events to functions --- addons/cargo/functions/fnc_loadItem.sqf | 2 +- addons/cargo/functions/fnc_unloadItem.sqf | 5 +- docs/wiki/framework/cargo-framework.md | 50 ++++++++++++++----- docs/wiki/framework/goggles-framework.md | 4 +- docs/wiki/framework/overpressure-framework.md | 2 +- .../framework/reloadlaunchers-framework.md | 2 +- 6 files changed, 45 insertions(+), 20 deletions(-) diff --git a/addons/cargo/functions/fnc_loadItem.sqf b/addons/cargo/functions/fnc_loadItem.sqf index 1d59cc1e64..bb608ff926 100644 --- a/addons/cargo/functions/fnc_loadItem.sqf +++ b/addons/cargo/functions/fnc_loadItem.sqf @@ -13,7 +13,7 @@ * Example: * [object, vehicle] call ace_cargo_fnc_loadItem * - * Public: No + * Public: Yes */ #include "script_component.hpp" diff --git a/addons/cargo/functions/fnc_unloadItem.sqf b/addons/cargo/functions/fnc_unloadItem.sqf index 47ff3ba36e..20fde5d631 100644 --- a/addons/cargo/functions/fnc_unloadItem.sqf +++ b/addons/cargo/functions/fnc_unloadItem.sqf @@ -5,14 +5,15 @@ * Arguments: * 0: Item * 1: Vehicle + * 2: Unloader (default: objNull) * * Return Value: - * Object unloaded + * Object was unloaded * * Example: * [object, vehicle] call ace_cargo_fnc_unloadItem * - * Public: No + * Public: Yes */ #include "script_component.hpp" diff --git a/docs/wiki/framework/cargo-framework.md b/docs/wiki/framework/cargo-framework.md index 03ddf4e757..091969b91f 100644 --- a/docs/wiki/framework/cargo-framework.md +++ b/docs/wiki/framework/cargo-framework.md @@ -46,20 +46,10 @@ class staticBananaLauncher { ### 2.1 Listenable -Event Name | Description | Passed Parameter(s) | Locality +Event Name | Passed Parameter(s) | Locality | Description ---------- | ----------- | ------------------- | -------- -`cargoLoaded` | Cargo has been loaded | ` [_item, _vehicle]` | Global -`cargoUnloaded` | Cargo has been unloaded | `[_item, _vehicle]` | Global -`cargoAddedByClass` | Cargo items have been added | `[_itemClass, _vehicle, _amount]` | Global - -### 2.2 Callable - -Event Name | Description | Passed Parameter(s) | Locality ----------- | ----------- | ------------------- | -------- -`LoadCargo` | Load object into vehicle. | `[_object, _vehicle, _showHint]` | Local -`UnloadCargo` | Unload object from vehicle. | `[_object, _vehicle]` | Local -`AddCargoByClass` | Adds a cargo item to the vehicle. | `[_itemClass, _vehicle, _amount, _showHint]` | Local - +`ace_cargoLoaded` | [_item, _vehicle] | Global | Cargo has been Loaded into vehicle +`ace_cargoUnloaded` | [_item, _vehicle] | Global | Cargo has been Unloaded from vehicle ## 3. Scripting @@ -70,3 +60,37 @@ To disable cargo for a mission object use: ```cpp this setVariable ["ace_cargo_size", -1]; ``` + +### 3.2 Add cargo to vehicle + +`ace_cargo_fnc_loadItem` (Also callable from cba event `ace_loadCargo`) +Note first arg can be a in-game object or a classname of an object type. + +```cpp + * Arguments: + * 0: Item + * 1: Vehicle + * + * Return Value: + * Object loaded + * + * Example: + * [object, vehicle] call ace_cargo_fnc_loadItem +``` + +### 3.3 Unload cargo from vehicle + +`ace_cargo_fnc_unloadItem` (Also callable from cba event `ace_unloadCargo`) + +```cpp + * Arguments: + * 0: Item + * 1: Vehicle + * 2: Unloader (default: objNull) + * + * Return Value: + * Object was unloaded + * + * Example: + * [object, vehicle] call ace_cargo_fnc_unloadItem +``` diff --git a/docs/wiki/framework/goggles-framework.md b/docs/wiki/framework/goggles-framework.md index 4261f0a5ab..1b9b27588b 100644 --- a/docs/wiki/framework/goggles-framework.md +++ b/docs/wiki/framework/goggles-framework.md @@ -36,5 +36,5 @@ class CfgGlasses { Event Name | Description | Passed Parameter(s) | Locality ---------- | ----------- | ------------------- | -------- -`GlassesChanged` | Glasses Changed | `[_glassesClass]` | Local -`GlassesCracked` | Glasses Cracked | `[_unit]` | Local +`ace_glassesChanged` | Glasses Changed | `[_unit, _glassesClass]` | Local +`ace_glassesCracked` | Glasses Cracked | `[_unit]` | Local diff --git a/docs/wiki/framework/overpressure-framework.md b/docs/wiki/framework/overpressure-framework.md index 79fe46104f..23d2080514 100644 --- a/docs/wiki/framework/overpressure-framework.md +++ b/docs/wiki/framework/overpressure-framework.md @@ -47,4 +47,4 @@ class CfgWeapons { Event Name | Description | Passed Parameter(s) | Locality ---------- | ----------- | ------------------- | -------- -`overpressure` | Overpressure damage inflicted | `[_firer, _position, _direction, _weapon]` | Target +`ace_overpressure` | Overpressure damage inflicted | `[_firer, _posASL, _direction, _weapon, _magazine, _ammo]` | Target diff --git a/docs/wiki/framework/reloadlaunchers-framework.md b/docs/wiki/framework/reloadlaunchers-framework.md index f175b60639..d055cc533c 100644 --- a/docs/wiki/framework/reloadlaunchers-framework.md +++ b/docs/wiki/framework/reloadlaunchers-framework.md @@ -28,4 +28,4 @@ class CfgWeapons { Event Name | Description | Passed Parameter(s) | Locality ---------- | ----------- | ------------------- | -------- -`reloadLauncher` | Launcher reloaded | `[_unit, _target, _weapon, _magazine]` | Target +`ace_reloadlaunchers_reloadLauncher` | Launcher reloaded | `[_unit, _target, _weapon, _magazine]` | Target From 33e4e6cd115fdab189d4803b6e24cf1e91972463 Mon Sep 17 00:00:00 2001 From: jonpas Date: Fri, 9 Jun 2017 14:54:58 +0200 Subject: [PATCH 32/36] Remove maximum distance of attach to vehicle action (#5262) * Remove maximum distance of attachi to vehicle action * Readd max distance, 10 meters to allow usage with big vehicles but also end placement system if too far --- addons/attach/CfgVehicles.hpp | 2 -- addons/attach/functions/fnc_canAttach.sqf | 6 +++--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/addons/attach/CfgVehicles.hpp b/addons/attach/CfgVehicles.hpp index 1e0c0f3e71..5fa75105e7 100644 --- a/addons/attach/CfgVehicles.hpp +++ b/addons/attach/CfgVehicles.hpp @@ -10,7 +10,6 @@ showDisabled = 0; \ priority = 0; \ icon = QPATHTOF(UI\attach_ca.paa); \ - distance = 4.5; \ }; \ class GVAR(DetachVehicle) { \ displayName = CSTRING(Detach); \ @@ -20,7 +19,6 @@ showDisabled = 0; \ priority = 0.1; \ icon = QPATHTOF(UI\detach_ca.paa); \ - distance = 4.5; \ }; \ }; \ }; diff --git a/addons/attach/functions/fnc_canAttach.sqf b/addons/attach/functions/fnc_canAttach.sqf index 37d92e8908..36264ed628 100644 --- a/addons/attach/functions/fnc_canAttach.sqf +++ b/addons/attach/functions/fnc_canAttach.sqf @@ -27,7 +27,7 @@ _attachLimit = [6, 1] select (_player == _attachToVehicle); _attachedObjects = _attachToVehicle getVariable [QGVAR(attached), []]; ((_player == _attachToVehicle) || {canStand _player}) && -{(_attachToVehicle distance _player) < 7} && -{alive _attachToVehicle} && -{(count _attachedObjects) < _attachLimit} && +{(_attachToVehicle distance _player) < 10} && +{alive _attachToVehicle} && +{(count _attachedObjects) < _attachLimit} && {_itemClassname in ((itemsWithMagazines _player) + [""])}; From 6facb9008b8ee59dab9b0957819fbf2751d041ad Mon Sep 17 00:00:00 2001 From: Laid3acK Date: Fri, 9 Jun 2017 15:23:30 +0200 Subject: [PATCH 33/36] Update kestrel4500.md (#5228) --- docs/wiki/feature/kestrel4500.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/wiki/feature/kestrel4500.md b/docs/wiki/feature/kestrel4500.md index 518ec77e68..782d8d26df 100644 --- a/docs/wiki/feature/kestrel4500.md +++ b/docs/wiki/feature/kestrel4500.md @@ -36,18 +36,28 @@ The Kestrel 4500 Pocket Weather Tracker is Kestrel's environmental meter. This i ### 2.1 Opening the Kestrel #### 2.1.1 Interaction Menu + - Open the self interaction menu Ctrl + ⊞ Win - Select `Equipment` - Select `Open Kestrel 4500` #### 2.1.2 Custom key + - `OPTIONS` / `CONTROLS` / `CONFIGURE ADDONS` / `ACE3 Equipment` #### 2.1.3 Inventory + Inventory management +### 2.2 `CROSSWIND` / `HEADWIND` Feature + +- https://www.youtube.com/watch?v=4Q_qgXwlRqk + +- *[Wind info]({{ site.baseurl }}/wiki/feature/weather.html) is toggled on/off using SHIFT + K.* + ## 3. Official Manual + - [Official Manual]({{ site.ace.githubUrl }}/blob/master/extras/K4500_Instruction_Manual_English.pdf) From 9c3cca3c56d1a6ab46b0fbd80f41f37ecc862aa2 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 9 Jun 2017 09:11:00 -0500 Subject: [PATCH 34/36] Add repair feature to wiki (#5247) * Add repair feature to wiki * Add blank lines, use adv engineer * Add repair framework page --- docs/wiki/feature/repair.md | 47 +++++++++++++++++++++++++ docs/wiki/framework/repair-framework.md | 40 +++++++++++++++++++++ 2 files changed, 87 insertions(+) create mode 100644 docs/wiki/feature/repair.md create mode 100644 docs/wiki/framework/repair-framework.md diff --git a/docs/wiki/feature/repair.md b/docs/wiki/feature/repair.md new file mode 100644 index 0000000000..f27639b5e9 --- /dev/null +++ b/docs/wiki/feature/repair.md @@ -0,0 +1,47 @@ +--- +layout: wiki +title: Repair +description: Adds custom repair system. +group: feature +category: interaction +parent: wiki +mod: ace +version: + major: 3 + minor: 3 + patch: 0 +--- + +
+
For information on configuration see [Repair Framework]({{ site.baseurl }}/wiki/framework/repair-framework.html)
+
+ +## 1. Overview + +Adds a more realistic repair system. +- Replacing damaged wheels and tracks requires replacement items (using [Cargo System]({{ site.baseurl }}/wiki/framework/cargo-framework.html). +- By default vehicles will start with spare parts (1 wheel or 1 track). +- Can repair specific hitpoints on vehicles. +- Can designate buildings and/or vehicles as repair zones allowing the ability to do a full repair. + +## 2. Repairing + +- Vehicle's engine should be off +- A `ToolKit` item may be required based on settings (default: not required for wheels, required for tracks or hitpoint repair) + +### 2.1 Replacing Wheels or Tracks + +- Unload a spare wheel or track (using cargo interaction) +- Drag the spare next to the wheel/track that needs replacing +- Remove the damaged wheel (not needed for track repair) +- Install new wheel or track + +### 2.2 Repairing hitpoints + +- Amount repaired is based on settings and training level +- Using the interaction system select the hitpoint to repair + +## 3. Dependencies + +{% include dependencies_list.md component="repair" %} + diff --git a/docs/wiki/framework/repair-framework.md b/docs/wiki/framework/repair-framework.md new file mode 100644 index 0000000000..16d8a76d7c --- /dev/null +++ b/docs/wiki/framework/repair-framework.md @@ -0,0 +1,40 @@ +--- +layout: wiki +title: Repair Framework +description: Explains how to set-up repair system. +group: framework +order: 5 +parent: wiki +mod: ace +version: + major: 3 + minor: 3 + patch: 0 +--- + +## 1. Object Variables / Configs + +### 1.1 Unit's Repair Training + +- Determines if a unit can repair damaged hitpoints and if so, how much can be restored. +- Can easily be set via 3den attribute. + +SetVar: `"ACE_IsEngineer"` - number 0 - 2 (can also be true/false) +- 0 / false: Untrained (by default settings will only be able to replace wheels) +- 1 / true: Engineer +- 2: Advanced Engineer (allowing a higher level of repairs, based on settings) (by default settings is the only one with access to full repair) + +### 1.2 Repair Vehicles + +- Allows full repair based on setting `fullRepairLocation` (not enabled by default) +- Can easily be set via 3den attribute. + +SetVar: `"ACE_isRepairVehicle"` - true or false + +Config: `ace_repair_canRepair` - 0 or 1 + +### 1.3 Repair Facilities + +- Allows full repair based on setting `fullRepairLocation` (on by default) + +SetVar: `"ACE_isRepairFacility"` - true or false From 48b9a61497c4718bce7aa0e027ec58433d38a75e Mon Sep 17 00:00:00 2001 From: Phyma Date: Fri, 9 Jun 2017 19:52:55 +0200 Subject: [PATCH 35/36] Fix Large IED defuse distance (#5261) * Fix for large-ied bug because underwater thing have changed * Added size of IED in config and determine defuse range * Added typo * Added help text to wiki about defusing * Better English * Increased the defusal range on large bombs make it similar to small ieds * Add wiki doc --- addons/explosives/CfgAmmo.hpp | 14 +++++++++++++- addons/explosives/CfgVehicles.hpp | 4 ++-- addons/explosives/functions/fnc_interactEH.sqf | 14 ++++++++------ docs/wiki/feature/explosives.md | 2 ++ docs/wiki/framework/explosives-framework.md | 1 + 5 files changed, 26 insertions(+), 9 deletions(-) diff --git a/addons/explosives/CfgAmmo.hpp b/addons/explosives/CfgAmmo.hpp index 05780b706a..355377102a 100644 --- a/addons/explosives/CfgAmmo.hpp +++ b/addons/explosives/CfgAmmo.hpp @@ -27,10 +27,13 @@ class CfgAmmo { class PipeBombCore: TimeBombCore; class PipeBombBase: PipeBombCore; */ + // GVAR(size) = 0; is small size + // GVAR(size) = 1; is large size class DirectionalBombBase; class ClaymoreDirectionalMine_Remote_Ammo: DirectionalBombBase { GVAR(magazine) = "ClaymoreDirectionalMine_Remote_Mag"; GVAR(Explosive) = "ClaymoreDirectionalMine_Remote_Ammo_Scripted"; + GVAR(size) = 0; GVAR(defuseObjectPosition)[] = {0, 0, 0.038}; soundActivation[] = {"", 0, 0, 0}; soundDeactivation[] = {"", 0, 0, 0}; @@ -39,6 +42,7 @@ class CfgAmmo { class APERSTripMine_Wire_Ammo: DirectionalBombBase { GVAR(defuseObjectPosition)[] = {-1.415, 0, 0.12}; + GVAR(size) = 0; }; class ACE_FlareTripMine_Wire_Ammo: APERSTripMine_Wire_Ammo { @@ -58,16 +62,18 @@ class CfgAmmo { distance = 0; }; }; - + class F_20mm_Red; class ACE_TripFlare_FlareEffect: F_20mm_Red { triggerTime = 0.1; + GVAR(size) = 0; }; class SLAMDirectionalMine_Wire_Ammo: DirectionalBombBase { indirectHitRange = 20; GVAR(explodeOnDefuseChance) = 1; GVAR(magazine) = "SLAMDirectionalMine_Wire_Mag"; + GVAR(size) = 0; }; class ACE_SLAMDirectionalMine_Command_Ammo: SLAMDirectionalMine_Wire_Ammo { mineTrigger = "RemoteTrigger"; @@ -89,6 +95,7 @@ class CfgAmmo { class DemoCharge_Remote_Ammo: PipeBombBase { GVAR(magazine) = "DemoCharge_Remote_Mag"; GVAR(Explosive) = "DemoCharge_Remote_Ammo_Scripted"; + GVAR(size) = 0; GVAR(defuseObjectPosition)[] = {0.07, 0, 0.055}; soundActivation[] = {"", 0, 0, 0}; soundDeactivation[] = {"", 0, 0, 0}; @@ -99,6 +106,7 @@ class CfgAmmo { class SatchelCharge_Remote_Ammo: PipeBombBase { GVAR(magazine) = "SatchelCharge_Remote_Mag"; GVAR(Explosive) = "SatchelCharge_Remote_Ammo_Scripted"; + GVAR(size) = 0; GVAR(defuseObjectPosition)[] = {0.1, 0.1, 0.05}; soundActivation[] = {"", 0, 0, 0}; soundDeactivation[] = {"", 0, 0, 0}; @@ -110,6 +118,7 @@ class CfgAmmo { triggerWhenDestroyed = 1; GVAR(explodeOnDefuseChance) = 0.02; GVAR(magazine) = "IEDUrbanBig_Remote_Mag"; + GVAR(size) = 1; soundTrigger[] = {"A3\Sounds_F\weapons\mines\mech_trigger_1", 0.8, 1, 40}; }; class ACE_IEDUrbanBig_Command_Ammo: IEDUrbanBig_Remote_Ammo { @@ -123,6 +132,7 @@ class CfgAmmo { triggerWhenDestroyed = 1; GVAR(explodeOnDefuseChance) = 0.02; GVAR(magazine) = "IEDUrbanSmall_Remote_Mag"; + GVAR(size) = 0; soundTrigger[] = {"A3\Sounds_F\weapons\mines\mech_trigger_1", 0.8, 1, 40}; }; class ACE_IEDUrbanSmall_Command_Ammo: IEDUrbanSmall_Remote_Ammo { @@ -136,6 +146,7 @@ class CfgAmmo { triggerWhenDestroyed = 1; GVAR(explodeOnDefuseChance) = 0.02; GVAR(magazine) = "IEDLandBig_Remote_Mag"; + GVAR(size) = 1; soundTrigger[] = {"A3\Sounds_F\weapons\mines\mech_trigger_1", 0.8, 1, 40}; }; class ACE_IEDLandBig_Command_Ammo: IEDLandBig_Remote_Ammo { @@ -149,6 +160,7 @@ class CfgAmmo { triggerWhenDestroyed = 1; GVAR(explodeOnDefuseChance) = 0.02; GVAR(magazine) = "IEDLandSmall_Remote_Mag"; + GVAR(size) = 0; soundTrigger[] = {"A3\Sounds_F\weapons\mines\mech_trigger_1", 0.8, 1, 40}; }; class ACE_IEDLandSmall_Command_Ammo: IEDLandSmall_Remote_Ammo { diff --git a/addons/explosives/CfgVehicles.hpp b/addons/explosives/CfgVehicles.hpp index f2b6ece8db..70499ba809 100644 --- a/addons/explosives/CfgVehicles.hpp +++ b/addons/explosives/CfgVehicles.hpp @@ -60,11 +60,11 @@ class CfgVehicles { icon = QPATHTOF(UI\Defuse_ca.paa); }; }; - }; + }; class ACE_DefuseObject_Large: ACE_DefuseObject { class ACE_Actions: ACE_Actions { class ACE_Defuse: ACE_Defuse { - distance = 1.5; + distance = 2; }; }; }; diff --git a/addons/explosives/functions/fnc_interactEH.sqf b/addons/explosives/functions/fnc_interactEH.sqf index a2da62e6b9..eac82bcddb 100644 --- a/addons/explosives/functions/fnc_interactEH.sqf +++ b/addons/explosives/functions/fnc_interactEH.sqf @@ -42,14 +42,16 @@ if (!("ACE_DefusalKit" in (items ACE_player))) exitWith {}; if (((getPosASL ace_player) distance _setPosition) > 5) then { { if (((_x distance ACE_player) < 15) && {!(_x in _minesHelped)}) then { - TRACE_3("Making Defuse Helper",(_x),(typeOf _x),(_x isKindOf "UnderwaterMine_Range_Ammo")); - private _defuseHelper = if (_x isKindOf "UnderwaterMine_Range_Ammo") then { - "ACE_DefuseObject_Large" createVehicleLocal (getPos _x); - } else { - "ACE_DefuseObject" createVehicleLocal (getPos _x); - }; private _config = configFile >> "CfgAmmo" >> typeOf _x; + private _size = getNumber (_config >> QGVAR(size)); + TRACE_3("Making Defuse Helper",(_x),(typeOf _x),(_size == 1)); + private ["_defuseHelper"]; + if (_size == 1) then { + _defuseHelper = "ACE_DefuseObject_Large" createVehicleLocal (getPos _x); + } else { + _defuseHelper = "ACE_DefuseObject" createVehicleLocal (getPos _x); + }; private _defuseObjectPosition = getArray (_config >> QGVAR(defuseObjectPosition)); if (_defuseObjectPosition isEqualTo []) then { diff --git a/docs/wiki/feature/explosives.md b/docs/wiki/feature/explosives.md index 7548c5f13c..d44d088251 100644 --- a/docs/wiki/feature/explosives.md +++ b/docs/wiki/feature/explosives.md @@ -41,6 +41,8 @@ Enables attaching explosives to vehicles. - Select `Disarm`. - You are safe to pick it up after the action has completed. +**Tip:** To increase the success rate when defusing, make sure you crawl up to the IED. + ## 3. Dependencies {% include dependencies_list.md component="explosives" %} diff --git a/docs/wiki/framework/explosives-framework.md b/docs/wiki/framework/explosives-framework.md index 2d5edebb5e..9c9c6513d6 100644 --- a/docs/wiki/framework/explosives-framework.md +++ b/docs/wiki/framework/explosives-framework.md @@ -54,6 +54,7 @@ class CfgAmmo { triggerWhenDestroyed = 1; // (Optional) Explode when the object is shot and destroyed (after being placed) (0-disabled, 1-enabled). ACE_explodeOnDefuse = 0.02; // (Optional) Add a chance for the explosive to detonate after being disarmed (in percent) ACE_explosives_defuseObjectPosition[] = {-1.415, 0, 0.12}; // (Optional) The position relative to the model where the defuse helper object will be attached and thus the interaction point will be rendered + ACE_explosives_size = 0; // (Optional) Setting to 1 will use a defusal action with a larger radius (useful for large mines or mines with a wide pressure plane trigger area) }; }; ``` From a53f68a34748beb92b19aab1853b82ceb4f53770 Mon Sep 17 00:00:00 2001 From: SilentSpike Date: Sat, 10 Jun 2017 11:41:01 +0100 Subject: [PATCH 36/36] Use getUnitTrait for medics, engineers and EOD (#5246) --- addons/common/functions/fnc_isEOD.sqf | 2 +- addons/common/functions/fnc_isEngineer.sqf | 2 +- addons/medical/functions/fnc_isMedic.sqf | 2 +- addons/repair/functions/fnc_isEngineer.sqf | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/common/functions/fnc_isEOD.sqf b/addons/common/functions/fnc_isEOD.sqf index ee82cf2068..2a6e04247c 100644 --- a/addons/common/functions/fnc_isEOD.sqf +++ b/addons/common/functions/fnc_isEOD.sqf @@ -20,4 +20,4 @@ params ["_unit"]; -_unit getVariable ["ACE_isEOD", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "canDeactivateMines") == 1] // return +_unit getVariable ["ACE_isEOD", _unit getUnitTrait "explosiveSpecialist"] // return diff --git a/addons/common/functions/fnc_isEngineer.sqf b/addons/common/functions/fnc_isEngineer.sqf index 01eabfc0b3..96a00970f6 100644 --- a/addons/common/functions/fnc_isEngineer.sqf +++ b/addons/common/functions/fnc_isEngineer.sqf @@ -17,7 +17,7 @@ params ["_unit"]; -private _isEngineer = _unit getVariable ["ACE_isEngineer", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "engineer") == 1]; +private _isEngineer = _unit getVariable ["ACE_isEngineer", _unit getUnitTrait "engineer"]; //Handle ace_repair modules setting this to a number if (_isEngineer isEqualType 0) then {_isEngineer = _isEngineer > 0}; diff --git a/addons/medical/functions/fnc_isMedic.sqf b/addons/medical/functions/fnc_isMedic.sqf index 9d93f50c74..f09fe88dbb 100644 --- a/addons/medical/functions/fnc_isMedic.sqf +++ b/addons/medical/functions/fnc_isMedic.sqf @@ -19,7 +19,7 @@ params ["_unit", ["_medicN", 1]]; -private _class = _unit getVariable [QGVAR(medicClass), getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "attendant")]; +private _class = _unit getVariable [QGVAR(medicClass), [0, 1] select (_unit getUnitTrait "medic")]; if (_class >= _medicN min GVAR(medicSetting)) exitWith {true}; if (!GVAR(increaseTrainingInLocations)) exitWith {false}; diff --git a/addons/repair/functions/fnc_isEngineer.sqf b/addons/repair/functions/fnc_isEngineer.sqf index d07c12af64..d2ee71b913 100644 --- a/addons/repair/functions/fnc_isEngineer.sqf +++ b/addons/repair/functions/fnc_isEngineer.sqf @@ -20,7 +20,7 @@ params ["_unit", ["_engineerN", 1]]; TRACE_2("params",_unit,_engineerN); private ["_class"]; -_class = _unit getVariable ["ACE_IsEngineer", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "engineer")]; +_class = _unit getVariable ["ACE_IsEngineer", _unit getUnitTrait "engineer"]; // This if statement is here for copmatability with the common variant of isEngineer, which requires a bool. // We cannot move this function to common because we require the GVAR(engineerSetting_Repair), which only makes sense to include in the repair module.