From dfca7b2f4426ecf049fb6eeac60a44d1ab9a8dfa Mon Sep 17 00:00:00 2001 From: jonpas Date: Wed, 15 Jul 2015 05:51:13 +0200 Subject: [PATCH 001/215] Split UI configs, Removed Vignette, Initial work on selective UI --- addons/ui/$PBOPREFIX$ | 2 +- addons/ui/ACE_Settings.hpp | 37 +++++++++++++++ addons/ui/CfgEventHandlers.hpp | 11 +++++ addons/ui/CfgVehicles.hpp | 58 ++++++++++++++++++++++++ addons/ui/README.md | 3 +- addons/ui/RscChat.hpp | 15 ++++++ addons/ui/RscVignette.hpp | 4 ++ addons/ui/XEH_clientInit.sqf | 63 ++++++++++++++++++++++++++ addons/ui/XEH_preInit.sqf | 7 +++ addons/ui/config.cpp | 24 +++------- addons/ui/functions/fnc_moduleInit.sqf | 29 ++++++++++++ addons/ui/stringtable.xml | 50 ++++++++++++++++++++ 12 files changed, 284 insertions(+), 19 deletions(-) create mode 100644 addons/ui/ACE_Settings.hpp create mode 100644 addons/ui/CfgEventHandlers.hpp create mode 100644 addons/ui/CfgVehicles.hpp create mode 100644 addons/ui/RscChat.hpp create mode 100644 addons/ui/RscVignette.hpp create mode 100644 addons/ui/XEH_clientInit.sqf create mode 100644 addons/ui/XEH_preInit.sqf create mode 100644 addons/ui/functions/fnc_moduleInit.sqf create mode 100644 addons/ui/stringtable.xml diff --git a/addons/ui/$PBOPREFIX$ b/addons/ui/$PBOPREFIX$ index 601bbd5f60..9b6ac48f4f 100644 --- a/addons/ui/$PBOPREFIX$ +++ b/addons/ui/$PBOPREFIX$ @@ -1 +1 @@ -z\ace\Addons\ui \ No newline at end of file +z\ace\addons\ui \ No newline at end of file diff --git a/addons/ui/ACE_Settings.hpp b/addons/ui/ACE_Settings.hpp new file mode 100644 index 0000000000..09bdb47634 --- /dev/null +++ b/addons/ui/ACE_Settings.hpp @@ -0,0 +1,37 @@ +class ACE_Settings { + class GVAR(weaponInfo) { + value = 1; + typeName = "BOOL"; + displayName = CSTRING(WeaponInfo); + }; + class GVAR(weaponName) { + value = 1; + typeName = "BOOL"; + displayName = CSTRING(WeaponName); + }; + /*class GVAR(ammoCount) { // Disabled in config by ace_reload + value = 1; + typeName = "BOOL"; + displayName = CSTRING(AmmoCount); + };*/ + class GVAR(magCount) { + value = 1; + typeName = "BOOL"; + displayName = CSTRING(MagCount); + }; + class GVAR(grenadeName) { + value = 1; + typeName = "BOOL"; + displayName = CSTRING(GrenadeName); + }; + class GVAR(grenadeCount) { + value = 1; + typeName = "BOOL"; + displayName = CSTRING(GrenadeCount); + }; + class GVAR(zeroing) { + value = 1; + typeName = "BOOL"; + displayName = CSTRING(Zeroing); + }; +}; diff --git a/addons/ui/CfgEventHandlers.hpp b/addons/ui/CfgEventHandlers.hpp new file mode 100644 index 0000000000..423993f757 --- /dev/null +++ b/addons/ui/CfgEventHandlers.hpp @@ -0,0 +1,11 @@ +class Extended_PreInit_EventHandlers { + class ADDON { + init = QUOTE(call COMPILE_FILE(XEH_preInit)); + }; +}; + +class Extended_PostInit_EventHandlers { + class ADDON { + clientInit = QUOTE(call COMPILE_FILE(XEH_clientInit)); + }; +}; diff --git a/addons/ui/CfgVehicles.hpp b/addons/ui/CfgVehicles.hpp new file mode 100644 index 0000000000..f918360518 --- /dev/null +++ b/addons/ui/CfgVehicles.hpp @@ -0,0 +1,58 @@ +class CfgVehicles { + class ACE_Module; + class ACE_ModuleUI: ACE_Module { + author = ECSTRING(common,ACETeam); + category = "ACE"; + displayName = CSTRING(ModuleDisplayName); + function = QFUNC(moduleInit); + scope = 2; + isGlobal = 1; + //icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); + class Arguments { + class weaponInfo { + displayName = CSTRING(WeaponInfo); + description = CSTRING(WeaponInfoDesc); + typeName = "BOOL"; + defaultValue = 1; + }; + class weaponName { + displayName = CSTRING(WeaponName); + description = CSTRING(WeaponNameDesc); + typeName = "BOOL"; + defaultValue = 1; + }; + /*class ammoCount { // Disabled in config by ace_reload + displayName = CSTRING(AmmoCount); + description = CSTRING(AmmoCountDesc); + typeName = "BOOL"; + defaultValue = 1; + };*/ + class magCount { + displayName = CSTRING(MagCount); + description = CSTRING(MagCountDesc); + typeName = "BOOL"; + defaultValue = 1; + }; + class grenadeName { + displayName = CSTRING(GrenadeName); + description = CSTRING(GrenadeNameDesc); + typeName = "BOOL"; + defaultValue = 1; + }; + class grenadeCount { + displayName = CSTRING(GrenadeCount); + description = CSTRING(GrenadeCountDesc); + typeName = "BOOL"; + defaultValue = 1; + }; + class zeroing { + displayName = CSTRING(Zeroing); + typeName = "BOOL"; + defaultValue = 1; + }; + }; + class ModuleDescription { + description = CSTRING(ModuleDescription); + }; + }; +}; diff --git a/addons/ui/README.md b/addons/ui/README.md index f11027038f..b3c2b3acb7 100644 --- a/addons/ui/README.md +++ b/addons/ui/README.md @@ -1,9 +1,10 @@ ace_ui ======= -Changes the chat contrast on the map to allow easier reading +Changes the chat contrast on the map to allow easier reading, removes vignette and provides settings to toggle different UI elements unavailable in Vanilla. ## Maintainers The people responsible for merging changes to this component or answering potential questions. +- [Jonpas] (https://github.com/jonpas) diff --git a/addons/ui/RscChat.hpp b/addons/ui/RscChat.hpp new file mode 100644 index 0000000000..6b091d73bc --- /dev/null +++ b/addons/ui/RscChat.hpp @@ -0,0 +1,15 @@ +class RscText; +class RscDisplayChat { + class controls { + delete Line; + delete Background; + class CA_Background: RscText { + colorBackground[] = {0.5,0.5,0.5,0.33}; // Make the chat entry field slightly darker + }; + }; +}; + +class RscChatListDefault { + colorBackground[] = {0,0,0,0.5}; // Make the chat background darker + colorMessageProtocol[] = {0.85,0.85,0.85,1}; // And the chat text brighter +}; diff --git a/addons/ui/RscVignette.hpp b/addons/ui/RscVignette.hpp new file mode 100644 index 0000000000..118fad96e6 --- /dev/null +++ b/addons/ui/RscVignette.hpp @@ -0,0 +1,4 @@ +class RscPicture; +class RscVignette: RscPicture { + colorText[] = {0, 0, 0, 0}; // Hide Vignette +}; diff --git a/addons/ui/XEH_clientInit.sqf b/addons/ui/XEH_clientInit.sqf new file mode 100644 index 0000000000..fec845d49a --- /dev/null +++ b/addons/ui/XEH_clientInit.sqf @@ -0,0 +1,63 @@ +#define DEBUG_MODE_FULL +#include "script_component.hpp" + +// Exit on Headless +if !(hasInterface) exitWith {}; + +["SettingsInitialized", { + // On load and entering/exiting a vehicle + ["infoDisplayChanged", { + LOG("UI infoDisplayChanged"); + + private ["_elements", "_display"]; + + // All elements with their show/hide, IDD and IDC + _elements = [ + [GVAR(weaponInfo), 300, 2302], + [GVAR(weaponName), 300, 118], + //[GVAR(ammoCount), 300, 184], // Disabled in config by ace_reload + [GVAR(magCount), 300, 185], + [GVAR(grenadeName), 300, 152], + [GVAR(grenadeCount), 300, 151], + [GVAR(zeroing), 300, 168] + ]; + + disableSerialization; + { + _display = _x; + { + EXPLODE_3_PVT(_x,_show,_idd,_idc); + + //_idd = 300; //debug + //_idc = 122; //debug + if (_idd == ctrlIDD _display) then { + _show = if (_show) then {0} else {1}; + + (_display displayCtrl _idc) ctrlSetFade _show; + (_display displayCtrl _idc) ctrlCommit 0; + }; + } forEach _elements; + } forEach (uiNamespace getVariable "IGUI_displays"); // Those displays can be present several times for some reason + }] call EFUNC(common,addEventHandler); +}] call EFUNC(common,addEventHandler); + + +/* +RscUnitInfo = 300 +-------- +Alt = 122 (UNKNOWN) +Ammo = 119 (UNKNOWN) +AmmoCount = 184 (Ammo Count) +MagCount = 185 (Magazine Count) +CA_TextFlares = 151 (Grenade Count) +CA_TextFlaresMode = 152 (Grenade Name) +CA_Zeroing = 168 (Zeroing) +Weapon = 118 (Weapon Name) +WeaponInfoControlsGroupLeft = 2302 (entire Weapon Info without Zeroing and Stance) +WeaponInfoControlsGroupRight = 2303 (UNKNOWN) + + +RscStanceInfo = 303 +------- +StanceIndicator = 188 (UNKNOWN) +*/ diff --git a/addons/ui/XEH_preInit.sqf b/addons/ui/XEH_preInit.sqf new file mode 100644 index 0000000000..7e1c3ec9ed --- /dev/null +++ b/addons/ui/XEH_preInit.sqf @@ -0,0 +1,7 @@ +#include "script_component.hpp" + +ADDON = false; + +PREP(moduleInit); + +ADDON = true; diff --git a/addons/ui/config.cpp b/addons/ui/config.cpp index e7ea4b32eb..fa10420277 100644 --- a/addons/ui/config.cpp +++ b/addons/ui/config.cpp @@ -6,25 +6,15 @@ class CfgPatches { weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"ace_common"}; - author[] = {"VKing"}; - authorUrl = "https://github.com/ACEMod/"; + author[] = {"VKing", "Jonpas"}; + authorUrl = "https://github.com/acemod/ACE3"; VERSION_CONFIG; }; }; -class RscText; +#include "CfgEventHandlers.hpp" +#include "CfgVehicles.hpp" +#include "ACE_Settings.hpp" -class RscDisplayChat { - class controls { - delete Line; - delete Background; - class CA_Background: RscText { - colorBackground[] = {0.5,0.5,0.5,0.33}; // Make the chat entry field slightly darker - }; - }; -}; - -class RscChatListDefault { - colorBackground[] = {0,0,0,0.5}; // Make the chat background darker - colorMessageProtocol[] = {0.85,0.85,0.85,1}; // And the chat text brighter -}; +#include "RscChat.hpp" +#include "RscVignette.hpp" diff --git a/addons/ui/functions/fnc_moduleInit.sqf b/addons/ui/functions/fnc_moduleInit.sqf new file mode 100644 index 0000000000..02d9c2ecbf --- /dev/null +++ b/addons/ui/functions/fnc_moduleInit.sqf @@ -0,0 +1,29 @@ +/* + * Author: Jonpas + * Initializes the UI module. + * + * Arguments: + * 0: Module Logic + * 1: Units + * 2: Activated + * + * Return Value: + * None + */ +#include "script_component.hpp" + +if !(isServer) exitWith {}; + +PARAMS_3(_logic,_units,_activated); + +if !(_activated) exitWith {}; + +[_logic, QGVAR(weaponInfo), "weaponInfo"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(weaponName), "weaponName"] call EFUNC(common,readSettingFromModule); +//[_logic, QGVAR(ammoCount), "ammoCount"] call EFUNC(common,readSettingFromModule); // Disabled in config by ace_reload +[_logic, QGVAR(magCount), "magCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(grenadeName), "grenadeName"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(grenadeCount), "grenadeCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(zeroing), "zeroing"] call EFUNC(common,readSettingFromModule); + +diag_log text "[ACE]: UI Module Initialized."; diff --git a/addons/ui/stringtable.xml b/addons/ui/stringtable.xml new file mode 100644 index 0000000000..b33c28292d --- /dev/null +++ b/addons/ui/stringtable.xml @@ -0,0 +1,50 @@ + + + + + Weapon Info + + + Entire weapon info interface (weapon name, firing mode, magazine info, ammo count, magazine count, grenade count) except zeroing. + + + Weapon Name + + + Requires enabled Weapon Info + + + Ammo Count + + + Requires enabled Weapon Info + + + Magazine Count + + + Requires enabled Weapon Info + + + Grenade Name + + + Requires enabled Weapon Info + + + Grenade Count + + + Requires enabled Weapon Info + + + Zeroing + + + User Interface + + + This module allows hiding of specific user interface parts. + + + \ No newline at end of file From 7d792f9d1471ba99e25e125be7573524b5c5355d Mon Sep 17 00:00:00 2001 From: jonpas Date: Mon, 20 Jul 2015 04:50:25 +0200 Subject: [PATCH 002/215] Proper Vignette removal, Fixed stringtable typo --- addons/ui/RscVignette.hpp | 2 +- addons/ui/XEH_clientInit.sqf | 2 +- addons/ui/stringtable.xml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/ui/RscVignette.hpp b/addons/ui/RscVignette.hpp index 118fad96e6..1da39c2118 100644 --- a/addons/ui/RscVignette.hpp +++ b/addons/ui/RscVignette.hpp @@ -1,4 +1,4 @@ class RscPicture; class RscVignette: RscPicture { - colorText[] = {0, 0, 0, 0}; // Hide Vignette + text = ""; // Remove Vignette Texture }; diff --git a/addons/ui/XEH_clientInit.sqf b/addons/ui/XEH_clientInit.sqf index fec845d49a..d6b0883d4d 100644 --- a/addons/ui/XEH_clientInit.sqf +++ b/addons/ui/XEH_clientInit.sqf @@ -53,7 +53,7 @@ CA_TextFlares = 151 (Grenade Count) CA_TextFlaresMode = 152 (Grenade Name) CA_Zeroing = 168 (Zeroing) Weapon = 118 (Weapon Name) -WeaponInfoControlsGroupLeft = 2302 (entire Weapon Info without Zeroing and Stance) +WeaponInfoControlsGroupLeft = 2302 (entire RscUnitInfo without Zeroing) WeaponInfoControlsGroupRight = 2303 (UNKNOWN) diff --git a/addons/ui/stringtable.xml b/addons/ui/stringtable.xml index b33c28292d..daabe80453 100644 --- a/addons/ui/stringtable.xml +++ b/addons/ui/stringtable.xml @@ -10,7 +10,7 @@ Weapon Name - + Requires enabled Weapon Info From 02faf0a10453b78fcbc9c074ee767cfce337a3d0 Mon Sep 17 00:00:00 2001 From: alganthe Date: Wed, 16 Sep 2015 06:20:05 +0200 Subject: [PATCH 003/215] fixed zeus addobjects The module part in CfgVehicles.hpp was missing. Signed-off-by: alganthe --- addons/zeus/ACE_Settings.hpp | 4 +--- addons/zeus/CfgVehicles.hpp | 6 ++++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/addons/zeus/ACE_Settings.hpp b/addons/zeus/ACE_Settings.hpp index 6488a23e4e..73d92b95cb 100644 --- a/addons/zeus/ACE_Settings.hpp +++ b/addons/zeus/ACE_Settings.hpp @@ -21,9 +21,7 @@ class ACE_Settings { values[] = {"$STR_A3_OPTIONS_DISABLED", CSTRING(revealMines_partial), CSTRING(revealMines_full)}; }; class GVAR(autoAddObjects) { - displayName = CSTRING(AddObjectsToCurator); - description = CSTRING(AddObjectsToCurator_desc); - value = 0; typeName = "BOOL"; + value = 0; }; }; diff --git a/addons/zeus/CfgVehicles.hpp b/addons/zeus/CfgVehicles.hpp index e110970ae3..f8ca85511b 100644 --- a/addons/zeus/CfgVehicles.hpp +++ b/addons/zeus/CfgVehicles.hpp @@ -70,6 +70,12 @@ class CfgVehicles { }; }; }; + class GVAR(autoAddObjects) { + displayName = CSTRING(AddObjectsToCurator); + description = CSTRING(AddObjectsToCurator_desc); + typeName = "BOOL"; + defaultValue = 0; + }; }; class ModuleDescription { description = CSTRING(Settings_Description); From 38fe56472e46db4454ea67b776f68ff9c78b77ae Mon Sep 17 00:00:00 2001 From: alganthe Date: Sun, 27 Sep 2015 15:35:32 +0200 Subject: [PATCH 004/215] ace setting string added for ace_zeus_autoAddObjects --- addons/zeus/ACE_Settings.hpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/zeus/ACE_Settings.hpp b/addons/zeus/ACE_Settings.hpp index 73d92b95cb..708e37d85b 100644 --- a/addons/zeus/ACE_Settings.hpp +++ b/addons/zeus/ACE_Settings.hpp @@ -23,5 +23,7 @@ class ACE_Settings { class GVAR(autoAddObjects) { typeName = "BOOL"; value = 0; + displayName = CSTRING(AddObjectsToCurator); + description = CSTRING(AddObjectsToCurator_desc); }; }; From 94ce49fedc8e37e3f408be0cd43a9d6a152729ca Mon Sep 17 00:00:00 2001 From: jonpas Date: Wed, 28 Oct 2015 23:23:02 +0100 Subject: [PATCH 005/215] Add selective UI --- addons/ui/ACE_Settings.hpp | 161 +++++++++++++++++- addons/ui/CfgVehicles.hpp | 160 ++++++++++++++--- addons/ui/XEH_clientInit.sqf | 84 ++++----- addons/ui/XEH_preInit.sqf | 3 + addons/ui/functions/fnc_moduleInit.sqf | 25 +-- .../ui/functions/fnc_moduleInitAdvanced.sqf | 42 +++++ .../ui/functions/fnc_setAdvancedElement.sqf | 43 +++++ addons/ui/functions/fnc_setElements.sqf | 44 +++++ addons/ui/functions/script_component.hpp | 1 + addons/ui/script_component.hpp | 72 ++++++++ addons/ui/stringtable.xml | 103 ++++++++--- 11 files changed, 613 insertions(+), 125 deletions(-) create mode 100644 addons/ui/functions/fnc_moduleInitAdvanced.sqf create mode 100644 addons/ui/functions/fnc_setAdvancedElement.sqf create mode 100644 addons/ui/functions/fnc_setElements.sqf create mode 100644 addons/ui/functions/script_component.hpp diff --git a/addons/ui/ACE_Settings.hpp b/addons/ui/ACE_Settings.hpp index 09bdb47634..53e1496b38 100644 --- a/addons/ui/ACE_Settings.hpp +++ b/addons/ui/ACE_Settings.hpp @@ -1,37 +1,182 @@ class ACE_Settings { - class GVAR(weaponInfo) { +// BASIC + class GVAR(soldierVehicleWeaponInfo) { value = 1; typeName = "BOOL"; - displayName = CSTRING(WeaponInfo); + isClientSettable = 1; + displayName = CSTRING(SoldierVehicleWeaponInfo); + category = CSTRING(Category); }; + class GVAR(vehicleRadar) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleRadar); + category = CSTRING(Category); + }; + class GVAR(vehicleCompass) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleCompass); + category = CSTRING(Category); + }; + class GVAR(commandMenu) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(CommandMenu); + category = CSTRING(Category); + }; + class GVAR(groupBar) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(GroupBar); + category = CSTRING(Category); + }; + +// ADVANCED + // Upper Weapon Info class GVAR(weaponName) { value = 1; typeName = "BOOL"; + isClientSettable = 1; displayName = CSTRING(WeaponName); + category = CSTRING(Category); }; - /*class GVAR(ammoCount) { // Disabled in config by ace_reload + class GVAR(weaponNameBackground) { value = 1; typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(WeaponNameBackground); + category = CSTRING(Category); + }; + class GVAR(firingMode) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(FiringMode); + category = CSTRING(Category); + }; + + // Lower Weapon Info + class GVAR(ammoType) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(AmmoType); + category = CSTRING(Category); + }; + class GVAR(ammoCount) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; displayName = CSTRING(AmmoCount); - };*/ + description = CSTRING(AmmoCountDesc); + category = CSTRING(Category); + }; class GVAR(magCount) { value = 1; typeName = "BOOL"; + isClientSettable = 1; displayName = CSTRING(MagCount); + category = CSTRING(Category); }; - class GVAR(grenadeName) { + class GVAR(grenadeFlareType) { value = 1; typeName = "BOOL"; - displayName = CSTRING(GrenadeName); + isClientSettable = 1; + displayName = CSTRING(GrenadeFlareType); + category = CSTRING(Category); }; - class GVAR(grenadeCount) { + class GVAR(grenadeFlareCount) { value = 1; typeName = "BOOL"; - displayName = CSTRING(GrenadeCount); + isClientSettable = 1; + displayName = CSTRING(GrenadeFlareCount); + category = CSTRING(Category); }; class GVAR(zeroing) { value = 1; typeName = "BOOL"; + isClientSettable = 1; displayName = CSTRING(Zeroing); + category = CSTRING(Category); + }; + class GVAR(weaponLowerInfoBackground) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(WeaponLowerInfoBackground); //todo + category = CSTRING(Category); + }; + + // Stance + class GVAR(stance) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(Stance); + category = CSTRING(Category); + }; + + + // Vehicle + class GVAR(vehicleName) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleName); + category = CSTRING(Category); + }; + class GVAR(vehicleNameBackground) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleNameBackground); + category = CSTRING(Category); + }; + class GVAR(vehicleFuelBar) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleFuelBar); + category = CSTRING(Category); + }; + class GVAR(vehicleSpeed) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleSpeed); + category = CSTRING(Category); + }; + class GVAR(vehicleAltitude) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleAltitude); + category = CSTRING(Category); + }; + class GVAR(vehicleDamage) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleDamage); + category = CSTRING(Category); + }; + class GVAR(vehicleInfoBackground) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleInfoBackground); + category = CSTRING(Category); + }; + class GVAR(vehicleGunnerWeapon) { + value = 1; + typeName = "BOOL"; + isClientSettable = 1; + displayName = CSTRING(VehicleGunnerWeapon); + category = CSTRING(Category); }; }; diff --git a/addons/ui/CfgVehicles.hpp b/addons/ui/CfgVehicles.hpp index f918360518..69f28f955e 100644 --- a/addons/ui/CfgVehicles.hpp +++ b/addons/ui/CfgVehicles.hpp @@ -1,52 +1,38 @@ class CfgVehicles { class ACE_Module; + + // Basic class ACE_ModuleUI: ACE_Module { author = ECSTRING(common,ACETeam); category = "ACE"; - displayName = CSTRING(ModuleDisplayName); + displayName = CSTRING(ModuleName); function = QFUNC(moduleInit); scope = 2; isGlobal = 1; //icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); class Arguments { - class weaponInfo { - displayName = CSTRING(WeaponInfo); - description = CSTRING(WeaponInfoDesc); + class soldierVehicleWeaponInfo { + displayName = CSTRING(SoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; - class weaponName { - displayName = CSTRING(WeaponName); - description = CSTRING(WeaponNameDesc); + class vehicleRadar { + displayName = CSTRING(VehicleRadar); typeName = "BOOL"; defaultValue = 1; }; - /*class ammoCount { // Disabled in config by ace_reload - displayName = CSTRING(AmmoCount); - description = CSTRING(AmmoCountDesc); - typeName = "BOOL"; - defaultValue = 1; - };*/ - class magCount { - displayName = CSTRING(MagCount); - description = CSTRING(MagCountDesc); + class vehicleCompass { + displayName = CSTRING(VehicleCompass); typeName = "BOOL"; defaultValue = 1; }; - class grenadeName { - displayName = CSTRING(GrenadeName); - description = CSTRING(GrenadeNameDesc); + class commandMenu { + displayName = CSTRING(CommandMenu); typeName = "BOOL"; defaultValue = 1; }; - class grenadeCount { - displayName = CSTRING(GrenadeCount); - description = CSTRING(GrenadeCountDesc); - typeName = "BOOL"; - defaultValue = 1; - }; - class zeroing { - displayName = CSTRING(Zeroing); + class groupBar { + displayName = CSTRING(GroupBar); typeName = "BOOL"; defaultValue = 1; }; @@ -55,4 +41,124 @@ class CfgVehicles { description = CSTRING(ModuleDescription); }; }; + + // Advanced + class ACE_ModuleUI_Advanced: ACE_Module { + author = ECSTRING(common,ACETeam); + category = "ACE"; + displayName = CSTRING(ModuleName_Advanced); + function = QFUNC(moduleInitAdvanced); + scope = 2; + isGlobal = 1; + //icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); + class Arguments { + // Upper Weapon Info + class weaponName { + displayName = CSTRING(WeaponName); + typeName = "BOOL"; + defaultValue = 1; + }; + class weaponNameBackground { + displayName = CSTRING(WeaponNameBackground); + typeName = "BOOL"; + defaultValue = 1; + }; + class firingMode { + displayName = CSTRING(FiringMode); + typeName = "BOOL"; + defaultValue = 1; + }; + + // Lower Weapon Info + class ammoType { + displayName = CSTRING(AmmoType); + typeName = "BOOL"; + defaultValue = 1; + }; + class ammoCount { + displayName = CSTRING(AmmoCount); + description = CSTRING(AmmoCountDesc); + typeName = "BOOL"; + defaultValue = 1; + }; + class magCount { + displayName = CSTRING(MagCount); + typeName = "BOOL"; + defaultValue = 1; + }; + class grenadeFlareType { + displayName = CSTRING(GrenadeFlareType); + typeName = "BOOL"; + defaultValue = 1; + }; + class grenadeFlareCount { + displayName = CSTRING(GrenadeFlareCount); + typeName = "BOOL"; + defaultValue = 1; + }; + class zeroing { + displayName = CSTRING(Zeroing); + typeName = "BOOL"; + defaultValue = 1; + }; + class weaponLowerInfoBackground { + displayName = CSTRING(WeaponLowerInfoBackground); + typeName = "BOOL"; + defaultValue = 1; + }; + + // Stance + class stance { + displayName = CSTRING(Stance); + typeName = "BOOL"; + defaultValue = 1; + }; + + + // Vehicle + class vehicleName { + displayName = CSTRING(VehicleName); + typeName = "BOOL"; + defaultValue = 1; + }; + class vehicleNameBackground { + displayName = CSTRING(VehicleNameBackground); + typeName = "BOOL"; + defaultValue = 1; + }; + class vehicleFuelBar { + displayName = CSTRING(VehicleFuelBar); + typeName = "BOOL"; + defaultValue = 1; + }; + class vehicleSpeed { + displayName = CSTRING(VehicleSpeed); + typeName = "BOOL"; + defaultValue = 1; + }; + class vehicleAltitude { + displayName = CSTRING(VehicleAltitude); + typeName = "BOOL"; + defaultValue = 1; + }; + class vehicleDamage { + displayName = CSTRING(VehicleDamage); + typeName = "BOOL"; + defaultValue = 1; + }; + class vehicleInfoBackground { + displayName = CSTRING(VehicleInfoBackground); + typeName = "BOOL"; + defaultValue = 1; + }; + class vehicleGunnerWeapon { + displayName = CSTRING(VehicleGunnerWeapon); + typeName = "BOOL"; + defaultValue = 1; + }; + }; + class ModuleDescription { + description = CSTRING(ModuleDescription_Advanced); + }; + }; }; diff --git a/addons/ui/XEH_clientInit.sqf b/addons/ui/XEH_clientInit.sqf index d6b0883d4d..d778fb2746 100644 --- a/addons/ui/XEH_clientInit.sqf +++ b/addons/ui/XEH_clientInit.sqf @@ -1,63 +1,41 @@ -#define DEBUG_MODE_FULL +//#define DEBUG_MODE_FULL #include "script_component.hpp" // Exit on Headless -if !(hasInterface) exitWith {}; +if (!hasInterface) exitWith {}; ["SettingsInitialized", { + // Selective UI Basic + call FUNC(setElements); + + // On load and entering/exiting a vehicle ["infoDisplayChanged", { - LOG("UI infoDisplayChanged"); - - private ["_elements", "_display"]; - - // All elements with their show/hide, IDD and IDC - _elements = [ - [GVAR(weaponInfo), 300, 2302], - [GVAR(weaponName), 300, 118], - //[GVAR(ammoCount), 300, 184], // Disabled in config by ace_reload - [GVAR(magCount), 300, 185], - [GVAR(grenadeName), 300, 152], - [GVAR(grenadeCount), 300, 151], - [GVAR(zeroing), 300, 168] - ]; - - disableSerialization; + // Selective UI Advanced { - _display = _x; - { - EXPLODE_3_PVT(_x,_show,_idd,_idc); - - //_idd = 300; //debug - //_idc = 122; //debug - if (_idd == ctrlIDD _display) then { - _show = if (_show) then {0} else {1}; - - (_display displayCtrl _idc) ctrlSetFade _show; - (_display displayCtrl _idc) ctrlCommit 0; - }; - } forEach _elements; - } forEach (uiNamespace getVariable "IGUI_displays"); // Those displays can be present several times for some reason + _x call FUNC(setAdvancedElement); + } forEach ELEMENTS_ADVANCED; }] call EFUNC(common,addEventHandler); + + + ["SettingChanged", { + params ["_name"]; + + // Selective UI Basic + if (_name in ELEMENTS_BASIC) then { + call FUNC(setElements); + }; + + // Selective UI Advanced + { + _x params ["_element"]; + + if (_name == _element) then { + _x call FUNC(setAdvancedElement); + TRACE_2("Setting Changed",_name,_element); + }; + } forEach ELEMENTS_ADVANCED; + + }] call EFUNC(common,addEventHandler); + }] call EFUNC(common,addEventHandler); - - -/* -RscUnitInfo = 300 --------- -Alt = 122 (UNKNOWN) -Ammo = 119 (UNKNOWN) -AmmoCount = 184 (Ammo Count) -MagCount = 185 (Magazine Count) -CA_TextFlares = 151 (Grenade Count) -CA_TextFlaresMode = 152 (Grenade Name) -CA_Zeroing = 168 (Zeroing) -Weapon = 118 (Weapon Name) -WeaponInfoControlsGroupLeft = 2302 (entire RscUnitInfo without Zeroing) -WeaponInfoControlsGroupRight = 2303 (UNKNOWN) - - -RscStanceInfo = 303 -------- -StanceIndicator = 188 (UNKNOWN) -*/ diff --git a/addons/ui/XEH_preInit.sqf b/addons/ui/XEH_preInit.sqf index 7e1c3ec9ed..8a86e3ec32 100644 --- a/addons/ui/XEH_preInit.sqf +++ b/addons/ui/XEH_preInit.sqf @@ -3,5 +3,8 @@ ADDON = false; PREP(moduleInit); +PREP(moduleInitAdvanced); +PREP(setAdvancedElement); +PREP(setElements); ADDON = true; diff --git a/addons/ui/functions/fnc_moduleInit.sqf b/addons/ui/functions/fnc_moduleInit.sqf index 02d9c2ecbf..f4a57831c8 100644 --- a/addons/ui/functions/fnc_moduleInit.sqf +++ b/addons/ui/functions/fnc_moduleInit.sqf @@ -12,18 +12,21 @@ */ #include "script_component.hpp" -if !(isServer) exitWith {}; +if (!isServer) exitWith {}; -PARAMS_3(_logic,_units,_activated); +params ["_logic", "_units", "_activated"]; -if !(_activated) exitWith {}; +if (!_activated) exitWith {}; -[_logic, QGVAR(weaponInfo), "weaponInfo"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(weaponName), "weaponName"] call EFUNC(common,readSettingFromModule); -//[_logic, QGVAR(ammoCount), "ammoCount"] call EFUNC(common,readSettingFromModule); // Disabled in config by ace_reload -[_logic, QGVAR(magCount), "magCount"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(grenadeName), "grenadeName"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(grenadeCount), "grenadeCount"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(zeroing), "zeroing"] call EFUNC(common,readSettingFromModule); +// Exit if HUD visibility is hardcoded in mission config and showHUD command is overriden +if (isArray (missionConfigFile >> "showHUD")) exitWith { + ACE_LOGINFO("User Interface (Basic) Module Failed to Initialize - showHUD overriden in mission config!"); +}; -diag_log text "[ACE]: UI Module Initialized."; +[_logic, QGVAR(soldierVehicleWeaponInfo), "soldierVehicleWeaponInfo"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleRadar), "vehicleRadar"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleCompass), "vehicleCompass"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(commandMenu), "commandMenu"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(groupBar), "groupBar"] call EFUNC(common,readSettingFromModule); + +ACE_LOGINFO("User Interface (Basic) Module Initialized."); diff --git a/addons/ui/functions/fnc_moduleInitAdvanced.sqf b/addons/ui/functions/fnc_moduleInitAdvanced.sqf new file mode 100644 index 0000000000..ab5666af69 --- /dev/null +++ b/addons/ui/functions/fnc_moduleInitAdvanced.sqf @@ -0,0 +1,42 @@ +/* + * Author: Jonpas + * Initializes the UI module. + * + * Arguments: + * 0: Module Logic + * 1: Units + * 2: Activated + * + * Return Value: + * None + */ +#include "script_component.hpp" + +if (!isServer) exitWith {}; + +params ["_logic", "_units", "_activated"]; + +if (!_activated) exitWith {}; + +[_logic, QGVAR(weaponName), "weaponName"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(weaponNameBackground), "weaponNameBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(firingMode), "firingMode"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(ammoType), "ammoType"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(ammoCount), "ammoCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(magCount), "magCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(grenadeFlareType), "grenadeFlareType"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(grenadeFlareCount), "grenadeFlareCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(zeroing), "zeroing"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(weaponLowerInfoBackground), "weaponLowerInfoBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(stance), "stance"] call EFUNC(common,readSettingFromModule); + +[_logic, QGVAR(vehicleName), "vehicleName"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleNameBackground), "vehicleNameBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleFuelBar), "vehicleFuelBar"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleSpeed), "vehicleSpeed"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleAltitude), "vehicleAltitude"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleDamage), "vehicleDamage"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleInfoBackground), "vehicleInfoBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleGunnerWeapon), "vehicleGunnerWeapon"] call EFUNC(common,readSettingFromModule); + +ACE_LOGINFO("User Interface (Advanced) Module Initialized."); diff --git a/addons/ui/functions/fnc_setAdvancedElement.sqf b/addons/ui/functions/fnc_setAdvancedElement.sqf new file mode 100644 index 0000000000..c87a79ffae --- /dev/null +++ b/addons/ui/functions/fnc_setAdvancedElement.sqf @@ -0,0 +1,43 @@ +/* + * Author: Jonpas + * Sets advanced visible element of the UI using displays and controls. + * + * Arguments: + * 0: Show/Hide Element OR Element Variable + * 1: Element IDD + * 2: Element IDCs + * + * Return Value: + * None + * + * Example: + * [show, 303, [188] ] call ace_ui_fnc_setAdvancedElement + * + * Public: No + */ +#include "script_component.hpp" + +params ["_show", "_idd", "_elements"]; + + +// Get show/hide boolean from mission namespace if it's a string +if (typeName _show == "STRING") then { + _show = missionNamespace getVariable _show; +}; +_show = [1, 0] select _show; + + +// Disable/Enable elements +{ + local _idc = _x; + + // Loop through IGUI displays as they can be present several times for some reason + { + if (_idd == ctrlIDD _x) then { + TRACE_3("Setting Element Visibility",_show,_idd,_idc); + + (_x displayCtrl _idc) ctrlSetFade _show; + (_x displayCtrl _idc) ctrlCommit 0; + }; + } forEach (uiNamespace getVariable "IGUI_displays"); +} forEach _elements; diff --git a/addons/ui/functions/fnc_setElements.sqf b/addons/ui/functions/fnc_setElements.sqf new file mode 100644 index 0000000000..3952d8e337 --- /dev/null +++ b/addons/ui/functions/fnc_setElements.sqf @@ -0,0 +1,44 @@ +/* + * Author: Jonpas + * Sets basic visible elements of the UI using showHUD setter. + * + * Arguments: + * None + * + * Return Value: + * None + * + * Example: + * call ace_ui_fnc_setBasicElements + * + * Public: No + */ +#include "script_component.hpp" + +//@todo - change to EFUNC(common,showHud) setter + +local _shownHUD = shownHUD; // [hud, info, radar, compass, direction, menu, group, cursors] + +showHUD [ + _shownHUD select 0, + GVAR(soldierVehicleWeaponInfo), + GVAR(vehicleRadar), + GVAR(vehicleCompass), + _shownHUD select 4, + GVAR(commandMenu), + GVAR(groupBar), + _shownHUD select 7 +]; + +/* +["UIselective", [ + _shownHUD select 0, + _shownHUD select 1, + _shownHUD select 2, + _shownHUD select 3, + _shownHUD select 4, + GVAR(commandMenu), + _shownHUD select 6, + _shownHUD select 7 +]] call EFUNC(common,showHud); +*/ diff --git a/addons/ui/functions/script_component.hpp b/addons/ui/functions/script_component.hpp new file mode 100644 index 0000000000..656228f742 --- /dev/null +++ b/addons/ui/functions/script_component.hpp @@ -0,0 +1 @@ +#include "\z\ace\addons\ui\script_component.hpp" diff --git a/addons/ui/script_component.hpp b/addons/ui/script_component.hpp index a0fa713f9f..2a9e582306 100644 --- a/addons/ui/script_component.hpp +++ b/addons/ui/script_component.hpp @@ -10,3 +10,75 @@ #endif #include "\z\ace\addons\main\script_macros.hpp" + + +// Elements +#define ELEMENTS_BASIC [QGVAR(soldierVehicleWeaponInfo), QGVAR(vehicleRadar), QGVAR(vehicleCompass), QGVAR(commandMenu), QGVAR(groupBar)] + +// Element, IDD, IDC +#define ELEMENTS_ADVANCED [ \ + [QGVAR(weaponName), 300, [118] ], \ + [QGVAR(weaponNameBackground), 300, [1001, 1008] ], \ + [QGVAR(firingMode), 300, [187, 1203] ], \ + [QGVAR(ammoType), 300, [155] ], \ + [QGVAR(ammoCount), 300, [184] ], \ + [QGVAR(magCount), 300, [185] ], \ + [QGVAR(grenadeName), 300, [152] ], \ + [QGVAR(grenadeCount), 300, [151] ], \ + [QGVAR(weaponLowerInfoBackground), 300, [1202] ], \ + [QGVAR(zeroing), 300, [168] ], \ + [QGVAR(stance), 303, [188, 1201] ], \ + [QGVAR(vehicleName), 300, [120] ], \ + [QGVAR(vehicleNameBackground), 300, [1000, 1013] ], \ + [QGVAR(vehicleFuelBar), 300, [113, 1202] ], \ + [QGVAR(vehicleSpeed), 300, [121, 1004, 1006] ], \ + [QGVAR(vehicleAltitude), 300, [122, 1005, 1014] ], \ + [QGVAR(vehicleDamage), 300, [111] ], \ + [QGVAR(vehicleInfoBackground), 300, [1200] ], \ + [QGVAR(vehicleGunnerWeapon), 300, [150] ] \ +] + + +/* +RscUnitInfo = 300 +-------------------- +118 (Weapon Name) ++ 1001 (Weapon Name Background 1/2) ++ 1008 (Weapon Name Background 2/2) + +187 (Firing Mode) ++ 1203 (Firing Mode Background) + +155 (Ammo Type) +184 (Ammo Count) - disabled in config by ace_reload +185 (Magazine Count) +152 (Grenade/Flare Type) +151 (Grenade/Flare Count) +1202 (Lower Weapon Info Background) +168 (Zeroing) + + +120 (Vehicle Name) +1000 (Vehicle Name Background 1/2) ++ 1013 (Vehicle Name Background 2/2) + +113 (Vehicle Fuel Bar) ++ 1202 (Vehicle Fuel Bar Background) + +121 (Vehicle Speed Number) ++ 1004 (Vehicle Speed Unit) ++ 1006 (Vehicle Speed Background) +122 (Vehicle Altitude Number) ++ 1005 (Vehicle Altitude Units) ++ 1014 (Vehicle Altitude Background) +111 (Vehicle Damage) +1200 (Vehicle Info Background) + +150 (Vehicle Gunner Weapon) + + +RscStanceInfo = 303 +-------------------- +188 (Stance) ++ 1201 (Stance Background) +*/ diff --git a/addons/ui/stringtable.xml b/addons/ui/stringtable.xml index daabe80453..e320d3ce39 100644 --- a/addons/ui/stringtable.xml +++ b/addons/ui/stringtable.xml @@ -1,50 +1,101 @@ - + - - Weapon Info + + User Interface - - Entire weapon info interface (weapon name, firing mode, magazine info, ammo count, magazine count, grenade count) except zeroing. + + + User Interface (Basic) + + This module allows hiding of basic user interface parts. Makes some User Interface (Advanced) settings inoperable. + + + + Soldier/Vehicle/Weapon Information + + + Vehicle Radar + + + Vehicle Compass + + + Command Menu + + + Group Bar + + + + + User Interface (Advanced) + + + This module allows hiding of specific user interface parts, more detailed than basic. User Interface (Basic) settings will make some of the settings inoperable. + + Weapon Name - - Requires enabled Weapon Info + + Weapon Name Background + + + Firing Mode + + + Ammo Type Ammo Count - Requires enabled Weapon Info + Always disabled on foot by ace_reload. Magazine Count - - Requires enabled Weapon Info + + Grenade/Flare Type - - Grenade Name - - - Requires enabled Weapon Info - - - Grenade Count - - - Requires enabled Weapon Info + + Grenade/Flare Count Zeroing - - User Interface + + Weapon Lower Info Background - - This module allows hiding of specific user interface parts. + + Stance + + + + Vehicle Name + + + Vehicle Name Background + + + Vehicle Fuel Bar + + + Vehicle Speed + + + Vehicle Altitude + + + Vehicle Damage + + + Vehicle Info Background + + + Vehicle Gunner Weapon - \ No newline at end of file + From e9505523451810d3edd100d5d473a2f4e2cd8bfa Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 27 Feb 2016 00:29:30 -0300 Subject: [PATCH 006/215] Track temperatures of spare barrels --- addons/overheating/CfgMagazines.hpp | 11 ++++ addons/overheating/CfgVehicles.hpp | 5 +- addons/overheating/CfgWeapons.hpp | 11 ---- addons/overheating/XEH_PREP.hpp | 2 + addons/overheating/XEH_postInit.sqf | 40 +++++++++++++ addons/overheating/config.cpp | 2 + .../functions/fnc_calculateCooling.sqf | 58 +++++++++++++++++++ .../functions/fnc_swapBarrelCallback.sqf | 12 +++- ...c_updateSpareBarrelsTemperaturesThread.sqf | 40 +++++++++++++ .../functions/fnc_updateTemperature.sqf | 44 +------------- 10 files changed, 167 insertions(+), 58 deletions(-) create mode 100644 addons/overheating/CfgMagazines.hpp create mode 100644 addons/overheating/functions/fnc_calculateCooling.sqf create mode 100644 addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf diff --git a/addons/overheating/CfgMagazines.hpp b/addons/overheating/CfgMagazines.hpp new file mode 100644 index 0000000000..ad381ff30e --- /dev/null +++ b/addons/overheating/CfgMagazines.hpp @@ -0,0 +1,11 @@ +class CfgMagazines { + class CA_Magazine; + class ACE_SpareBarrel: CA_Magazine { + descriptionshort = CSTRING(SpareBarrelDescription); + picture = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); + displayName = "ACE Spare Barrel"; //!!!CANNOT be localized!!!: because it is used as part of the magazineDetail string + count = 1; + mass = 40; + ACE_isUnique = 1; + }; +}; diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index c7d9c6790a..4911fcb7f6 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -15,7 +15,7 @@ class CfgVehicles { }; class ACE_SwapBarrel { displayName = CSTRING(SwapBarrel); - condition = QUOTE( 'ACE_SpareBarrel' in items _player && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _player >> 'ACE_Overheating_allowSwapBarrel') == 1} ); + condition = QUOTE( 'ACE_SpareBarrel' in magazines _player && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _player >> 'ACE_Overheating_allowSwapBarrel') == 1} ); statement = QUOTE( [ARR_2(_player, currentWeapon _player)] call FUNC(swapBarrel); ); showDisabled = 0; priority = 3; @@ -99,7 +99,7 @@ class CfgVehicles { MACRO_ADDITEM(ACE_SpareBarrel,6); }; }; - +/* // Add ACE_SpareBarrel to every machine gunner. #define MACRO_ADDSPAREBARREL \ items[] = {"FirstAidKit", "ACE_SpareBarrel"}; \ @@ -124,4 +124,5 @@ class CfgVehicles { // Czech class I_Soldier_02_F; class I_Soldier_AR_F:I_Soldier_02_F {MACRO_ADDSPAREBARREL}; class I_Soldier_support_base_F; class I_Soldier_AAR_F:I_Soldier_support_base_F {MACRO_ADDSPAREBARREL}; +*/ }; diff --git a/addons/overheating/CfgWeapons.hpp b/addons/overheating/CfgWeapons.hpp index f59c4d7911..c7a83eec6e 100644 --- a/addons/overheating/CfgWeapons.hpp +++ b/addons/overheating/CfgWeapons.hpp @@ -2,17 +2,6 @@ class CfgWeapons { class ACE_ItemCore; class InventoryItem_Base_F; - class ACE_SpareBarrel: ACE_ItemCore { - displayname = CSTRING(SpareBarrelName); - descriptionshort = CSTRING(SpareBarrelDescription); - //model = ""; - picture = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); - scope = 2; - class ItemInfo: InventoryItem_Base_F { - mass = 30; - }; - }; - class RifleCore; class Rifle: RifleCore { //Mean Rounds Between Stoppages (this will be scaled based on the barrel temp) diff --git a/addons/overheating/XEH_PREP.hpp b/addons/overheating/XEH_PREP.hpp index 312b8bb0c5..26366b9896 100644 --- a/addons/overheating/XEH_PREP.hpp +++ b/addons/overheating/XEH_PREP.hpp @@ -1,4 +1,5 @@ +PREP(calculateCooling); PREP(canUnjam); PREP(checkTemperature); PREP(clearJam); @@ -10,5 +11,6 @@ PREP(jamWeapon); PREP(overheat); PREP(swapBarrel); PREP(swapBarrelCallback); +PREP(updateSpareBarrelsTemperaturesThread); PREP(updateTemperature); PREP(updateTemperatureThread); diff --git a/addons/overheating/XEH_postInit.sqf b/addons/overheating/XEH_postInit.sqf index 0bb2da22ca..b19b96272d 100644 --- a/addons/overheating/XEH_postInit.sqf +++ b/addons/overheating/XEH_postInit.sqf @@ -8,6 +8,46 @@ if (isServer) then { GVAR(pseudoRandomList) pushBack [-1 + random 2, -1 + random 2]; }; publicVariable QGVAR(pseudoRandomList); + + // Keep track of the temperature of stored spare barrels + GVAR(storedSpareBarrels) = [] call CBA_fnc_hashCreate; + ["spareBarrelLoadedCoolest", { + params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; + TRACE_4("spareBarrelLoadedCoolest1",_unit,_weapon,_weaponTemp,_barrelMass); + + // Find all spare barrel the player has + private _allMags = magazinesDetail _unit; + TRACE_1("spareBarrelLoadedCoolest2",_allMags); + _allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; + TRACE_1("spareBarrelLoadedCoolest3",_allMags); + if ((count _allMags) < 1) exitWith {}; + + // Determine which on is coolest + private _coolestTemp = 10000; + private _coolestMag = _allMags select 0; + { + private _temp = 0; + if ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashHasKey) then { + _temp = ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashGet) select 0; + }; + TRACE_2("spareBarrelLoadedCoolest4",_x,_temp); + if (_temp < _coolestTemp) then { + _coolestTemp = _temp; + _coolestMag = _x; + }; + } forEach _allMags; + TRACE_3("spareBarrelLoadedCoolest5",_coolestTemp,_coolestMag,_weaponTemp); + + // The new weapon temperature is similar to the coolest barrel + // Publish the new temperature value + _unit setVariable [format [QGVAR(%1_temp), _weapon], _coolestTemp, true]; + + // Heat up the coolest barrel to the former weapon temperature + [GVAR(storedSpareBarrels), _coolestMag, [_weaponTemp, ACE_Time, _barrelMass]] call CBA_fnc_hashSet; + }] call EFUNC(common,addEventHandler); + + // Schedule cool down calculation of stored spare barrels + [] call FUNC(updateSpareBarrelsTemperaturesThread); }; diff --git a/addons/overheating/config.cpp b/addons/overheating/config.cpp index c57e55913d..673edcf77f 100644 --- a/addons/overheating/config.cpp +++ b/addons/overheating/config.cpp @@ -18,6 +18,8 @@ class CfgPatches { #include "CfgVehicles.hpp" +#include "CfgMagazines.hpp" + #include "CfgWeapons.hpp" #include "ACE_Settings.hpp" diff --git a/addons/overheating/functions/fnc_calculateCooling.sqf b/addons/overheating/functions/fnc_calculateCooling.sqf new file mode 100644 index 0000000000..955c41441e --- /dev/null +++ b/addons/overheating/functions/fnc_calculateCooling.sqf @@ -0,0 +1,58 @@ +/* + * Author: esteldunedain + * Calculate the cooling down of a weapon over a time interval. + * + * Argument: + * 0: Initial temperature + * 1: Barrel mass + * 2: Time interval + * + * Return value: + * Final temperature + * + * Example: + * [_temperature, _barrelMass, _totalTime] call ace_overheating_fnc_calculateCooling + * + * Public: No + */ +#include "script_component.hpp" + +params ["_temperature", "_barrelMass", "_totalTime"]; + +// If a long time passed since the last shot, there's no need to calculate anything; the weapon should be cool +if (_totalTime > 1800) exitWith {0}; + +//AR-15 (0.00570m bullet diameter) (barrel diameter usually 0.75" or 0.008255m radius) +//Steel Denisty = 7850 m^3 / kg +//Area of a cylinder (2/r)*(Pi * r^3 + V) - for a 0.008255m radius barrel -> Area = 210(1/meters) * Volume +//Adjusted volume for being hollowed out is ~1.1x +//So Area = 210 * 1.1 * (mass / 7850) = mass * 0.029427 (for steel near that diameter) + +private _barrelSurface = _barrelMass * 0.029427; + +TRACE_4("cooling",_temperature,_totalTime,_barrelMass,_barrelSurface); + +private _time = 0; +while {true} do { + private _deltaTime = (_totalTime - _time) min 20; + + _temperature = _temperature - ( + // Convective cooling + 25 * _barrelSurface * _temperature + // Radiative cooling + + 0.4 * 5.67e-8 * _barrelSurface * + ( (_temperature + 273.15)*(_temperature + 273.15) + * (_temperature + 273.15)*(_temperature + 273.15) + - 273.15 * 273.15 * 273.15 *273.15 ) + ) * _deltaTime / (_barrelMass * 466); + + if (_temperature < 1) exitWith {0}; + + if (isNil "_temperature") exitWith { + diag_log text format ["[ACE] ERROR: _totalTime = %1; _time = %2; _deltaTime = %3;", _totalTime, _time, _deltaTime]; + 0 + }; + + _time = _time + _deltaTime; + if (_time >= _totalTime) exitWith { _temperature max 0 }; +}; diff --git a/addons/overheating/functions/fnc_swapBarrelCallback.sqf b/addons/overheating/functions/fnc_swapBarrelCallback.sqf index 9c62e77f21..8bd63e4874 100644 --- a/addons/overheating/functions/fnc_swapBarrelCallback.sqf +++ b/addons/overheating/functions/fnc_swapBarrelCallback.sqf @@ -14,6 +14,7 @@ * * Public: No */ +#define DEBUG_MODE_FULL #include "script_component.hpp" params ["_player", "_weapon"]; @@ -26,7 +27,14 @@ playSound "ACE_BarrelSwap"; // don't consume the barrel, but rotate through them. [localize LSTRING(SwappedBarrel), QUOTE(PATHTOF(UI\spare_barrel_ca.paa))] call EFUNC(common,displayTextPicture); -// Publish the temperature variable -_player setVariable [format [QGVAR(%1_temp), _weapon], 0, true]; +private _temp = _player getVariable [format [QGVAR(%1_temp), _weapon], 0]; +private _barrelMass = 0.50 * (getNumber (configFile >> "CfgWeapons" >> _weapon >> "WeaponSlotsInfo" >> "mass") / 22.0) max 1.0; + +// Instruct the server to load the coolest spare barrel into the weapon and +// store the removed barrel with the former weapon temperature. The server +// also updates the current weapon temperature to match that of the new +// loaded barrel. +["spareBarrelLoadedCoolest", [_player, _weapon, _temp, _barrelMass]] call EFUNC(common,serverEvent); + // Store the update time _player setVariable [format [QGVAR(%1_time), _weapon], ACE_time]; diff --git a/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf new file mode 100644 index 0000000000..852cb1c580 --- /dev/null +++ b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf @@ -0,0 +1,40 @@ +/* + * Author: esteldunedain + * Calculate cooldown of all the stored spare barrels. + * + * Argument: + * None + * + * Return value: + * None + * + * Example: + * [] call ace_overheating_fnc_updateSpareBarrelsTemperaturesThread + * + * Public: No + */ +#define DEBUG_MODE_FULL +#include "script_component.hpp" + +private _pairs = []; +TRACE_1("updateSpareBarrelsTemperaturesThread1",GVAR(storedSpareBarrels)); +[GVAR(storedSpareBarrels), {_pairs pushBack [_key, _value];}] call CBA_fnc_hashEachPair; +TRACE_1("updateSpareBarrelsTemperaturesThread2",_pairs); +{ + _x params ["_barrelMagazineID","_value"]; + _value params ["_initialTemp","_initialTime", "_barrelMass"]; + + // Calculate cooling + private _finalTemp = [_initialTemp, _barrelMass, ACE_time - _initialTime] call FUNC(calculateCooling); + TRACE_4("updateSpareBarrelsTemperaturesThread3",_barrelMagazineID,_initialTemp,_finalTemp,_barrelMass); + if (_finalTemp < 5) then { + // The barrel is cool enough to keep calculating. Remove it from the hash + [GVAR(storedSpareBarrels), _barrelMagazineID] call CBA_fnc_hashRem; + } else { + // Store the new temp + [GVAR(storedSpareBarrels), _barrelMagazineID, [_finalTemp, ACE_time, _barrelMass]] call CBA_fnc_hashSet; + }; +} forEach _pairs; + +// Schedule for execution again after 10 seconds +[DFUNC(updateSpareBarrelsTemperaturesThread), [], 10] call EFUNC(common,waitAndExecute); diff --git a/addons/overheating/functions/fnc_updateTemperature.sqf b/addons/overheating/functions/fnc_updateTemperature.sqf index 89d5975024..1643fe55b4 100644 --- a/addons/overheating/functions/fnc_updateTemperature.sqf +++ b/addons/overheating/functions/fnc_updateTemperature.sqf @@ -29,50 +29,8 @@ private _lastTime = _unit getVariable [_timeVarName, 0]; private _barrelMass = 0.50 * (getNumber (configFile >> "CfgWeapons" >> _weapon >> "WeaponSlotsInfo" >> "mass") / 22.0) max 1.0; -_fnc_cooling = { - params ["_temperature", "_barrelMass", "_totalTime"]; - - // If a long time passed since the last shot, there's no need to calculate anything; the weapon should be cool - if (_totalTime > 1800) exitWith {0}; - - //AR-15 (0.00570m bullet diameter) (barrel diameter usually 0.75" or 0.008255m radius) - //Steel Denisty = 7850 m^3 / kg - //Area of a cylinder (2/r)*(Pi * r^3 + V) - for a 0.008255m radius barrel -> Area = 210(1/meters) * Volume - //Adjusted volume for being hollowed out is ~1.1x - //So Area = 210 * 1.1 * (mass / 7850) = mass * 0.029427 (for steel near that diameter) - - private _barrelSurface = _barrelMass * 0.029427; - - TRACE_4("cooling",_temperature,_totalTime,_barrelMass,_barrelSurface); - - private _time = 0; - while {true} do { - private _deltaTime = (_totalTime - _time) min 20; - - _temperature = _temperature - ( - // Convective cooling - 25 * _barrelSurface * _temperature - // Radiative cooling - + 0.4 * 5.67e-8 * _barrelSurface * - ( (_temperature + 273.15)*(_temperature + 273.15) - * (_temperature + 273.15)*(_temperature + 273.15) - - 273.15 * 273.15 * 273.15 *273.15 ) - ) * _deltaTime / (_barrelMass * 466); - - if (_temperature < 1) exitWith {0}; - - if (isNil "_temperature") exitWith { - diag_log text format ["[ACE] ERROR: _totalTime = %1; _time = %2; _deltaTime = %3;", _totalTime, _time, _deltaTime]; - 0 - }; - - _time = _time + _deltaTime; - if (_time >= _totalTime) exitWith { _temperature max 0 }; - }; -}; - // Calculate cooling -_temperature = [_temperature, _barrelMass, ACE_time - _lastTime] call _fnc_cooling; +_temperature = [_temperature, _barrelMass, ACE_time - _lastTime] call FUNC(calculateCooling); TRACE_1("cooledTo",_temperature); // Calculate heating // Steel Heat Capacity = 466 J/(Kg.K) From b8f955468cc4b255eba4d922c03d8d2e972dc66b Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 27 Feb 2016 01:46:27 -0300 Subject: [PATCH 007/215] First version of "Check spare barrel temperatures" action --- addons/overheating/CfgVehicles.hpp | 9 +++++ addons/overheating/XEH_postInit.sqf | 61 +++++++++++++++++++++++++++++ addons/overheating/stringtable.xml | 18 +++++++++ 3 files changed, 88 insertions(+) diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index 4911fcb7f6..61b619a79b 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -30,6 +30,15 @@ class CfgVehicles { priority = 2.9; icon = QUOTE(PATHTOF(UI\temp_ca.paa)); }; + class ACE_CheckTemperatureSpareBarrels { + displayName = CSTRING(CheckTemperatureSpareBarrelsShort); + condition = QUOTE( 'ACE_SpareBarrel' in magazines _player); + exceptions[] = {"isNotInside", "isNotSitting"}; + statement = QUOTE([ARR_2('spareBarrelsCheckTemperatures',[ARR_2(_player,_player)])] call EFUNC(common,serverEvent);); + showDisabled = 0; + priority = 2.8; + icon = QUOTE(PATHTOF(UI\temp_ca.paa)); + }; }; }; }; diff --git a/addons/overheating/XEH_postInit.sqf b/addons/overheating/XEH_postInit.sqf index b19b96272d..f29a1c624c 100644 --- a/addons/overheating/XEH_postInit.sqf +++ b/addons/overheating/XEH_postInit.sqf @@ -11,6 +11,67 @@ if (isServer) then { // Keep track of the temperature of stored spare barrels GVAR(storedSpareBarrels) = [] call CBA_fnc_hashCreate; + + ["spareBarrelsCheckTemperatures", { + params ["_player","_unit"]; + // Find all spare barrel the player has + private _allMags = magazinesDetail _unit; + _allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; + if ((count _allMags) < 1) exitWith {}; + + // Determine the temp of each barrel + private _temps = []; + { + private _temp = 0; + if ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashHasKey) then { + _temp = ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashGet) select 0; + }; + _temps pushBack _temp; + } forEach _allMags; + TRACE_1("_temps",_temps); + + // Count cool + private _countCool = {_x < 20} count _temps; + private _countWarm = {(_x >= 20) && (_x < 100)} count _temps; + private _countHot = {(_x >= 100) && (_x < 200)} count _temps; + private _countVeryHot = {(_x >= 200) && (_x < 600)} count _temps; + private _countExtremelyHot = {_x >= 600} count _temps; + private _output = ["%1 %2%3%4 %5%6%7 %8%9%10 %11%12%13 %14"]; + private _size = 1.0; + if (_countCool > 0) then { + _output pushBack _countCool; + _output pushBack LSTRING(BarrelCool); + _output pushBack "
"; + _size = _size + 0.5; + }; + if (_countWarm > 0) then { + _output pushBack _countWarm; + _output pushBack LSTRING(BarrelWarm); + _output pushBack "
"; + _size = _size + 0.5; + }; + if (_countHot > 0) then { + _output pushBack _countHot; + _output pushBack LSTRING(BarrelHot); + _output pushBack "
"; + _size = _size + 0.5; + }; + if (_countVeryHot > 0) then { + _output pushBack _countVeryHot; + _output pushBack LSTRING(BarrelVeryHot); + _output pushBack "
"; + _size = _size + 0.5; + }; + if (_countExtremelyHot > 0) then { + _output pushBack _countExtremelyHot; + _output pushBack LSTRING(BarrelExtremelyHot); + _size = _size + 0.5; + }; + + TRACE_1("_output",_output); + ["displayTextStructured", [_player], [_output, _size, _player]] call EFUNC(common,targetEvent); + }] call EFUNC(common,addEventHandler); + ["spareBarrelLoadedCoolest", { params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; TRACE_4("spareBarrelLoadedCoolest1",_unit,_weapon,_weaponTemp,_barrelMass); diff --git a/addons/overheating/stringtable.xml b/addons/overheating/stringtable.xml index 57a9fee566..1e2490ea52 100644 --- a/addons/overheating/stringtable.xml +++ b/addons/overheating/stringtable.xml @@ -224,6 +224,9 @@ Sto controllando la temperatura... Проверка температуры...
+ + Check spare barrel temperatures + Temperature Temperatur @@ -236,5 +239,20 @@ Temperatura Температура + + Cool Spare Barrel/s + + + Warm Spare Barrel/s + + + Hot Spare Barrel/s + + + Very Hot Spare Barrel/s + + + Extremele Hot Spare Barrel/s + \ No newline at end of file From 3bbabac2d71c918b7b36cbdfa70f20d3b801f111 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 20:12:56 -0300 Subject: [PATCH 008/215] Rename and add comments to the function that tracks the units vital loop. Use waitAndExecute instead of a pfh for better performance. --- addons/medical/XEH_PREP.hpp | 3 +- .../functions/fnc_addToInjuredCollection.sqf | 59 ------------------- addons/medical/functions/fnc_addVitalLoop.sqf | 30 ++++++++++ .../medical/functions/fnc_adjustPainLevel.sqf | 2 +- addons/medical/functions/fnc_handleDamage.sqf | 4 +- addons/medical/functions/fnc_handleLocal.sqf | 3 +- .../fnc_treatmentTourniquetLocal.sqf | 3 +- .../functions/fnc_treatment_success.sqf | 2 +- addons/medical/functions/fnc_vitalLoop.sqf | 48 +++++++++++++++ 9 files changed, 88 insertions(+), 66 deletions(-) delete mode 100644 addons/medical/functions/fnc_addToInjuredCollection.sqf create mode 100644 addons/medical/functions/fnc_addVitalLoop.sqf create mode 100644 addons/medical/functions/fnc_vitalLoop.sqf diff --git a/addons/medical/XEH_PREP.hpp b/addons/medical/XEH_PREP.hpp index 4184f096f7..6cbce0df78 100644 --- a/addons/medical/XEH_PREP.hpp +++ b/addons/medical/XEH_PREP.hpp @@ -11,11 +11,11 @@ PREP(actionLoadUnit); PREP(actionUnloadUnit); PREP(addDamageToUnit); PREP(addHeartRateAdjustment); -PREP(addToInjuredCollection); PREP(addToLog); PREP(addToTriageCard); PREP(addUnconsciousCondition); PREP(addUnloadPatientActions); +PREP(addVitalLoop); PREP(adjustPainLevel); PREP(canAccessMedicalEquipment); PREP(canTreat); @@ -96,6 +96,7 @@ PREP(treatmentTourniquet); PREP(treatmentTourniquetLocal); PREP(useItem); PREP(useItems); +PREP(vitalLoop); PREP(displayPatientInformation); PREP(displayTriageCard); PREP(dropDownTriageCard); diff --git a/addons/medical/functions/fnc_addToInjuredCollection.sqf b/addons/medical/functions/fnc_addToInjuredCollection.sqf deleted file mode 100644 index aa545f491e..0000000000 --- a/addons/medical/functions/fnc_addToInjuredCollection.sqf +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Author: Glowbal - * Enabled the vitals loop for a unit. - * - * Arguments: - * 0: The Unit - * - * ReturnValue: - * None - * - * Public: Yes - */ - -#include "script_component.hpp" - -params ["_unit", ["_force", false]]; - -if ([_unit] call FUNC(hasMedicalEnabled) || _force) then { - - if !(local _unit) exitWith { - ["addToInjuredCollection", _unit, [_unit, _force]] call EFUNC(common,targetEvent); - }; - - if ((_unit getVariable[QGVAR(addedToUnitLoop),false] || !alive _unit) && !_force) exitWith{}; - _unit setVariable [QGVAR(addedToUnitLoop), true, true]; - - [{ - params ["_args", "_idPFH"]; - _args params ["_unit", "_interval"]; - _interval = ACE_time - _interval; - (_this select 0) set [1, ACE_time]; - - if (!alive _unit || !local _unit) then { - [_idPFH] call CBA_fnc_removePerFrameHandler; - if (!local _unit) then { - if (GVAR(level) >= 2) then { - _unit setVariable [QGVAR(heartRate), _unit getVariable [QGVAR(heartRate), 80], true]; - _unit setVariable [QGVAR(bloodPressure), _unit getVariable [QGVAR(bloodPressure), [80, 120]], true]; - }; - _unit setVariable [QGVAR(bloodVolume), _unit getVariable [QGVAR(bloodVolume), 100], true]; - }; - } else { - [_unit, _interval] call FUNC(handleUnitVitals); - - private "_pain"; - _pain = _unit getVariable [QGVAR(pain), 0]; - if (_pain > (_unit getVariable [QGVAR(painSuppress), 0])) then { - // This introduces wierd unconscious behaviour for basic medical and possibly also advanced. - // TODO This is disabled as it's considered non critical code. - // We will need to decide if we want unconscious triggered on high pain levels or if we can get rid of this entirely. - /*if (_pain > 0.7 && {random(1) > 0.6}) then { - [_unit] call FUNC(setUnconscious); - };*/ - - [_unit, _pain] call FUNC(playInjuredSound); - }; - }; - }, 1, [_unit, ACE_time]] call CBA_fnc_addPerFrameHandler; -}; diff --git a/addons/medical/functions/fnc_addVitalLoop.sqf b/addons/medical/functions/fnc_addVitalLoop.sqf new file mode 100644 index 0000000000..f3c8c380bb --- /dev/null +++ b/addons/medical/functions/fnc_addVitalLoop.sqf @@ -0,0 +1,30 @@ +/* + * Author: Glowbal + * Enabled the vitals loop for a unit. + * + * Arguments: + * 0: The Unit + * + * ReturnValue: + * None + * + * Public: Yes + */ + +#include "script_component.hpp" + +params ["_unit", ["_force", false]]; + +if !([_unit] call FUNC(hasMedicalEnabled) || _force) exitWith {}; + +if !(local _unit) exitWith { + ["addVitalLoop", _unit, [_unit, _force]] call EFUNC(common,targetEvent); +}; + +// Quit if the unit already has a vital loop, or is dead, unless it's forced +if ((_unit getVariable[QGVAR(addedToUnitLoop),false] || !alive _unit) && !_force) exitWith{}; + +// Schedule the loop to be executed again later +// @todo: should the loop be started righ away instead? +_unit setVariable [QGVAR(addedToUnitLoop), true, true]; +[DFUNC(vitalLoop), 1, [_unit, ACE_time]] call EFUNC(common,waitAndExecute); diff --git a/addons/medical/functions/fnc_adjustPainLevel.sqf b/addons/medical/functions/fnc_adjustPainLevel.sqf index df82e06823..7b97cdc48f 100644 --- a/addons/medical/functions/fnc_adjustPainLevel.sqf +++ b/addons/medical/functions/fnc_adjustPainLevel.sqf @@ -35,6 +35,6 @@ _pain = _pain max 0; _unit setVariable [QGVAR(pain), _pain]; //Start up the vital watching (if not already running) -[_unit] call FUNC(addToInjuredCollection); +[_unit] call FUNC(addVitalLoop); _pain diff --git a/addons/medical/functions/fnc_handleDamage.sqf b/addons/medical/functions/fnc_handleDamage.sqf index cd0b4b1b27..b46ffcf1ad 100644 --- a/addons/medical/functions/fnc_handleDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage.sqf @@ -102,8 +102,8 @@ if ((_minLethalDamage <= _newDamage) && {[_unit, [_effectiveSelectionName] call _damageReturn = _damageReturn min 0.89; }; - -[_unit] call FUNC(addToInjuredCollection); +// Start the loop that tracks the unit vitals +[_unit] call FUNC(addVitalLoop); if (_unit getVariable [QGVAR(preventInstaDeath), GVAR(preventInstaDeath)]) exitWith { private _delayedUnconsicous = false; diff --git a/addons/medical/functions/fnc_handleLocal.sqf b/addons/medical/functions/fnc_handleLocal.sqf index 91689f311f..270a993b43 100644 --- a/addons/medical/functions/fnc_handleLocal.sqf +++ b/addons/medical/functions/fnc_handleLocal.sqf @@ -17,8 +17,9 @@ params ["_unit", "_local"]; if (_local) then { + // If the unit had a loop tracking its vitals, restart it locally if (_unit getVariable[QGVAR(addedToUnitLoop),false]) then { - [_unit, true] call FUNC(addToInjuredCollection); + [_unit, true] call FUNC(addVitalLoop); }; if ((_unit getVariable ["ACE_isUnconscious",false]) && {count (_unit getVariable [QGVAR(unconsciousArguments), []]) >= 6}) then { diff --git a/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf b/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf index be9b03c9f1..3b181b2387 100644 --- a/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf +++ b/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf @@ -16,7 +16,8 @@ private ["_tourniquets", "_part", "_applyingTo"]; params ["_target", "_tourniquetItem", "_selectionName"]; -[_target] call FUNC(addToInjuredCollection); +//If we're not already tracking vitals, start: +[_target] call FUNC(addVitalLoop); _part = [_selectionName] call FUNC(selectionNameToNumber); diff --git a/addons/medical/functions/fnc_treatment_success.sqf b/addons/medical/functions/fnc_treatment_success.sqf index d8a4d3b336..a9ef534346 100644 --- a/addons/medical/functions/fnc_treatment_success.sqf +++ b/addons/medical/functions/fnc_treatment_success.sqf @@ -92,7 +92,7 @@ _args call FUNC(createLitter); //If we're not already tracking vitals, start: if (!(_target getVariable [QGVAR(addedToUnitLoop),false])) then { - [_target] call FUNC(addToInjuredCollection); + [_target] call FUNC(addVitalLoop); }; ["medical_treatmentSuccess", [_caller, _target, _selectionName, _className]] call EFUNC(common,localEvent); diff --git a/addons/medical/functions/fnc_vitalLoop.sqf b/addons/medical/functions/fnc_vitalLoop.sqf new file mode 100644 index 0000000000..fcfb638143 --- /dev/null +++ b/addons/medical/functions/fnc_vitalLoop.sqf @@ -0,0 +1,48 @@ +/* + * Author: Glowbal, esteldunedain + * Vital loop for a unit. + * + * Arguments: + * 0: The Unit + * 1: Time of last computation + * + * ReturnValue: + * None + * + * Public: Yes + */ + +#include "script_component.hpp" + +params ["_unit", "_lastTime"]; + +// If the unit died the loop is finished +if (!alive _unit) exitWith {}; + +// If locality changed, broadcast the last medical state and finish the local loop +if (!local _unit) exitWith { + if (GVAR(level) >= 2) then { + _unit setVariable [QGVAR(heartRate), _unit getVariable [QGVAR(heartRate), 80], true]; + _unit setVariable [QGVAR(bloodPressure), _unit getVariable [QGVAR(bloodPressure), [80, 120]], true]; + }; + _unit setVariable [QGVAR(bloodVolume), _unit getVariable [QGVAR(bloodVolume), 100], true]; +}; + +// Handle unit vitals +[_unit, ACE_time - _lastTime] call FUNC(handleUnitVitals); + +// Play injured sounds +private _pain = _unit getVariable [QGVAR(pain), 0]; +if (_pain > (_unit getVariable [QGVAR(painSuppress), 0])) then { + // This introduces wierd unconscious behaviour for basic medical and possibly also advanced. + // TODO This is disabled as it's considered non critical code. + // We will need to decide if we want unconscious triggered on high pain levels or if we can get rid of this entirely. + /*if (_pain > 0.7 && {random(1) > 0.6}) then { + [_unit] call FUNC(setUnconscious); + };*/ + + [_unit, _pain] call FUNC(playInjuredSound); +}; + +// Schedule the loop to be executed again later +[DFUNC(vitalLoop), 1, [_unit, ACE_time]] call EFUNC(common,waitAndExecute); From bed51ac8a4c9a121f3cdff554e8be9adf43af220 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 20:26:05 -0300 Subject: [PATCH 009/215] Fix waitAndExecute syntax --- addons/medical/functions/fnc_addVitalLoop.sqf | 4 ++-- addons/medical/functions/fnc_vitalLoop.sqf | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/medical/functions/fnc_addVitalLoop.sqf b/addons/medical/functions/fnc_addVitalLoop.sqf index f3c8c380bb..52b2cc11f9 100644 --- a/addons/medical/functions/fnc_addVitalLoop.sqf +++ b/addons/medical/functions/fnc_addVitalLoop.sqf @@ -24,7 +24,7 @@ if !(local _unit) exitWith { // Quit if the unit already has a vital loop, or is dead, unless it's forced if ((_unit getVariable[QGVAR(addedToUnitLoop),false] || !alive _unit) && !_force) exitWith{}; -// Schedule the loop to be executed again later +// Schedule the loop to be executed again 1 sec later // @todo: should the loop be started righ away instead? _unit setVariable [QGVAR(addedToUnitLoop), true, true]; -[DFUNC(vitalLoop), 1, [_unit, ACE_time]] call EFUNC(common,waitAndExecute); +[DFUNC(vitalLoop), [_unit, ACE_time], 1] call EFUNC(common,waitAndExecute); diff --git a/addons/medical/functions/fnc_vitalLoop.sqf b/addons/medical/functions/fnc_vitalLoop.sqf index fcfb638143..d555f00a75 100644 --- a/addons/medical/functions/fnc_vitalLoop.sqf +++ b/addons/medical/functions/fnc_vitalLoop.sqf @@ -44,5 +44,5 @@ if (_pain > (_unit getVariable [QGVAR(painSuppress), 0])) then { [_unit, _pain] call FUNC(playInjuredSound); }; -// Schedule the loop to be executed again later -[DFUNC(vitalLoop), 1, [_unit, ACE_time]] call EFUNC(common,waitAndExecute); +// Schedule the loop to be executed again 1 sec later +[DFUNC(vitalLoop), [_unit, ACE_time], 1] call EFUNC(common,waitAndExecute); From 085860c7709c2e99bf4d6a25a21fd08e95e1f914 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 20:32:02 -0300 Subject: [PATCH 010/215] Restore addToInjuredCollection as a deprecated function --- addons/medical/XEH_PREP.hpp | 1 + .../functions/fnc_addToInjuredCollection.sqf | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 addons/medical/functions/fnc_addToInjuredCollection.sqf diff --git a/addons/medical/XEH_PREP.hpp b/addons/medical/XEH_PREP.hpp index 6cbce0df78..8383b7ad8a 100644 --- a/addons/medical/XEH_PREP.hpp +++ b/addons/medical/XEH_PREP.hpp @@ -11,6 +11,7 @@ PREP(actionLoadUnit); PREP(actionUnloadUnit); PREP(addDamageToUnit); PREP(addHeartRateAdjustment); +PREP(addToInjuredCollection); PREP(addToLog); PREP(addToTriageCard); PREP(addUnconsciousCondition); diff --git a/addons/medical/functions/fnc_addToInjuredCollection.sqf b/addons/medical/functions/fnc_addToInjuredCollection.sqf new file mode 100644 index 0000000000..77d2378d0d --- /dev/null +++ b/addons/medical/functions/fnc_addToInjuredCollection.sqf @@ -0,0 +1,17 @@ +/* + * Author: Glowbal + * Enabled the vitals loop for a unit. + * + * Arguments: + * 0: The Unit + * + * ReturnValue: + * None + * + * Deprecated + */ +#include "script_component.hpp" + +ACE_DEPRECATED("ace_medical_fnc_addToInjuredCollection","3.7.0","ace_medical_fnc_addVitalLoop"); + +_this call FUNC(addVitalLoop); From bbb84ec7d14d27536be99408fcea22e51d2534b8 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 20:50:28 -0300 Subject: [PATCH 011/215] Move the tourniquet loop to handleUnitVitals. Makes the tourniquet pain compatible with swapping localities --- .../functions/fnc_handleUnitVitals.sqf | 13 +++++++++++ .../fnc_treatmentTourniquetLocal.sqf | 23 +------------------ 2 files changed, 14 insertions(+), 22 deletions(-) diff --git a/addons/medical/functions/fnc_handleUnitVitals.sqf b/addons/medical/functions/fnc_handleUnitVitals.sqf index 6159351cc9..d161bbb385 100644 --- a/addons/medical/functions/fnc_handleUnitVitals.sqf +++ b/addons/medical/functions/fnc_handleUnitVitals.sqf @@ -110,6 +110,19 @@ if (GVAR(level) >= 2) then { }; }; + // Handle toruniquets + private _tourniquets = _unit getVariable [QGVAR(tourniquets), [0,0,0,0,0,0]]; + { + private _appliedTime = _x; + if (_appliedTime > 0) then { + // There's a tourniquet applied at time _appliedTime + if (CBA_missionTime - _appliedTime > 120) then { + // Increase pain at a rate of 0.001 units/s + _unit setVariable [QGVAR(pain), (_unit getVariable [QGVAR(pain), 0]) + 0.001]; + }; + } + } forEach _tourniquets; + // Set the vitals _heartRate = (_unit getVariable [QGVAR(heartRate), 80]) + (([_unit] call FUNC(getHeartRateChange)) * _interval); _unit setVariable [QGVAR(heartRate), _heartRate max 0, _syncValues]; diff --git a/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf b/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf index 3b181b2387..b8acc27c74 100644 --- a/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf +++ b/addons/medical/functions/fnc_treatmentTourniquetLocal.sqf @@ -23,26 +23,5 @@ _part = [_selectionName] call FUNC(selectionNameToNumber); // Place a tourniquet on the bodypart _tourniquets = _target getVariable [QGVAR(tourniquets), [0,0,0,0,0,0]]; -_applyingTo = (_tourniquets select _part) + 1 + round(random(100)); -_tourniquets set[_part, _applyingTo]; +_tourniquets set [_part, CBA_missionTime]; _target setVariable [QGVAR(tourniquets), _tourniquets, true]; - -[{ - params ["_args", "_idPFH"]; - _args params ["_target", "_applyingTo", "_part", "_time"]; - - if (!alive _target) exitWith { - [_idPFH] call CBA_fnc_removePerFrameHandler; - }; - - _tourniquets = _target getVariable [QGVAR(tourniquets), [0,0,0,0,0,0]]; - if !((_tourniquets select _part) == _applyingTo) exitWith { - // Tourniquet has been removed - [_idPFH] call CBA_fnc_removePerFrameHandler; - }; - if (ACE_time - _time > 120) then { - _target setVariable [QGVAR(pain), (_target getVariable [QGVAR(pain), 0]) + 0.005]; - }; -}, 5, [_target, _applyingTo, _part, ACE_time] ] call CBA_fnc_addPerFrameHandler; - -true From 35e13d535710645e116c659554e6d926b87dfde3 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 20:55:05 -0300 Subject: [PATCH 012/215] Fixes --- addons/medical/functions/fnc_handleUnitVitals.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/medical/functions/fnc_handleUnitVitals.sqf b/addons/medical/functions/fnc_handleUnitVitals.sqf index d161bbb385..a76fa9a098 100644 --- a/addons/medical/functions/fnc_handleUnitVitals.sqf +++ b/addons/medical/functions/fnc_handleUnitVitals.sqf @@ -110,7 +110,7 @@ if (GVAR(level) >= 2) then { }; }; - // Handle toruniquets + // Handle tourniquets private _tourniquets = _unit getVariable [QGVAR(tourniquets), [0,0,0,0,0,0]]; { private _appliedTime = _x; @@ -120,7 +120,7 @@ if (GVAR(level) >= 2) then { // Increase pain at a rate of 0.001 units/s _unit setVariable [QGVAR(pain), (_unit getVariable [QGVAR(pain), 0]) + 0.001]; }; - } + }; } forEach _tourniquets; // Set the vitals From 21d4939abb1bee8d66c0ed01a1a54cf2e5af93fb Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 22:08:59 -0300 Subject: [PATCH 013/215] Optimize the computation of tourniquet pain. Fix pain not being able to decrease when above 10 --- .../functions/fnc_handleUnitVitals.sqf | 25 +++++++------------ 1 file changed, 9 insertions(+), 16 deletions(-) diff --git a/addons/medical/functions/fnc_handleUnitVitals.sqf b/addons/medical/functions/fnc_handleUnitVitals.sqf index a76fa9a098..23272f0890 100644 --- a/addons/medical/functions/fnc_handleUnitVitals.sqf +++ b/addons/medical/functions/fnc_handleUnitVitals.sqf @@ -110,18 +110,10 @@ if (GVAR(level) >= 2) then { }; }; - // Handle tourniquets - private _tourniquets = _unit getVariable [QGVAR(tourniquets), [0,0,0,0,0,0]]; - { - private _appliedTime = _x; - if (_appliedTime > 0) then { - // There's a tourniquet applied at time _appliedTime - if (CBA_missionTime - _appliedTime > 120) then { - // Increase pain at a rate of 0.001 units/s - _unit setVariable [QGVAR(pain), (_unit getVariable [QGVAR(pain), 0]) + 0.001]; - }; - }; - } forEach _tourniquets; + // Handle pain due tourniquets, that have been applied more than 120 s ago + private _oldTourniquets = (_unit getVariable [QGVAR(tourniquets), []]) select {_x > 0 && {CBA_missionTime - _x > 120}}; + // Increase pain at a rate of 0.001 units/s per old tourniquet + _painStatus = _painStatus + (count _oldTourniquets) * 0.001 * _interval; // Set the vitals _heartRate = (_unit getVariable [QGVAR(heartRate), 80]) + (([_unit] call FUNC(getHeartRateChange)) * _interval); @@ -130,10 +122,11 @@ if (GVAR(level) >= 2) then { _bloodPressure = [_unit] call FUNC(getBloodPressure); _unit setVariable [QGVAR(bloodPressure), _bloodPressure, _syncValues]; - if (_painStatus > 0 && {_painStatus < 10}) then { - _painReduce = if (_painStatus > 5) then {0.002} else {0.001}; - _unit setVariable [QGVAR(pain), (_painStatus - _painReduce * _interval) max 0, _syncValues]; - }; + _painReduce = if (_painStatus > 5) then {0.002} else {0.001}; + + // @todo: replace this and the rest of the setVariable with EFUNC(common,setApproximateVariablePublic) + _unit setVariable [QGVAR(pain), (_painStatus - _painReduce * _interval) max 0, _syncValues]; + TRACE_8("ACE_DEBUG_ADVANCED_VITALS",_painStatus,_painReduce,_heartRate,_bloodVolume,_bloodPressure,_interval,_syncValues,_unit); // TODO Disabled until implemented fully // Handle airway From 0e82cdfe8208a6ab1d9c8af7481181365aa554f3 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 22:50:04 -0300 Subject: [PATCH 014/215] Move to a function and comments the function that tracks the effects of medications over time. Use waitAndExecute instead of a pfh for better performance. --- addons/medical/XEH_PREP.hpp | 1 + .../functions/fnc_medicationEffectLoop.sqf | 42 +++++++++++++++++++ .../functions/fnc_onMedicationUsage.sqf | 21 +--------- 3 files changed, 45 insertions(+), 19 deletions(-) create mode 100644 addons/medical/functions/fnc_medicationEffectLoop.sqf diff --git a/addons/medical/XEH_PREP.hpp b/addons/medical/XEH_PREP.hpp index 8383b7ad8a..906f4e18f7 100644 --- a/addons/medical/XEH_PREP.hpp +++ b/addons/medical/XEH_PREP.hpp @@ -57,6 +57,7 @@ PREP(isMedic); PREP(isMedicalVehicle); PREP(isInStableCondition); PREP(itemCheck); +PREP(medicationEffectLoop); PREP(modifyMedicalAction); PREP(onMedicationUsage); PREP(onWoundUpdateRequest); diff --git a/addons/medical/functions/fnc_medicationEffectLoop.sqf b/addons/medical/functions/fnc_medicationEffectLoop.sqf new file mode 100644 index 0000000000..5ba54bfc9f --- /dev/null +++ b/addons/medical/functions/fnc_medicationEffectLoop.sqf @@ -0,0 +1,42 @@ +/* + * Author: Glowbal, esteldunedain + * Medication effect loop for an injection. + * + * Arguments: + * 0: Unit + * 1: Name of the Variable that is affected + * 2: Proportion of the effect applied + * 3: Rate at which the effect is applied + * 4: Viscosity adjustment rate + * 5: Pain reduction rate + * + * ReturnValue: + * None + * + * Public: Yes + */ + +#include "script_component.hpp" + +params ["_unit", "_variableName", "_amountDecreased","_decreaseRate", "_viscosityAdjustmentRate", "_painReduceRate"]; + +// If the unit died the loop is finished +if (!alive _unit) exitWith {}; + +// If locality changed finish the local loop +if (!local _unit) exitWith {}; + +// Apply medicinal effect +private _usedMeds = (_unit getVariable [_variableName, 0]) - _decreaseRate; +_unit setVariable [_variableName, _usedMeds]; + +// Restore the viscosity while the medication is leaving the system +_unit setVariable [QGVAR(peripheralResistance), ((_unit getVariable [QGVAR(peripheralResistance), 100]) - _viscosityAdjustmentRate) max 0]; +_unit setVariable [QGVAR(painSuppress), ((_unit getVariable [QGVAR(painSuppress), 0]) - _painReduceRate) max 0]; + +// Exit if the medication has finished it's effect +_amountDecreased = _amountDecreased + _decreaseRate; +if (_amountDecreased >= 1 || (_usedMeds <= 0) || !alive _unit) exitWith {}; + +// Schedule the loop to be executed again 1 sec later +[DFUNC(medicationEffectLoop), [_unit, _variableName, _amountDecreased, _decreaseRate, _viscosityAdjustmentRate, _painReduceRate], 1] call EFUNC(common,waitAndExecute); diff --git a/addons/medical/functions/fnc_onMedicationUsage.sqf b/addons/medical/functions/fnc_onMedicationUsage.sqf index fc7e8daa2d..2f2b9b6363 100644 --- a/addons/medical/functions/fnc_onMedicationUsage.sqf +++ b/addons/medical/functions/fnc_onMedicationUsage.sqf @@ -77,22 +77,5 @@ if (_hasOverDosed > 0 && GVAR(enableOverdosing)) then { _decreaseAmount = 1 / _timeInSystem; _viscosityAdjustment = _viscosityChange / _timeInSystem; -[{ - params ["_args", "_idPFH"]; - _args params ["_target", "_timeInSystem", "_variable", "_amountDecreased","_decreaseAmount", "_viscosityAdjustment", "_painReduce"]; - private "_usedMeds"; - _usedMeds = _target getVariable [_variable, 0]; - _usedMeds = _usedMeds - _decreaseAmount; - _target setVariable [_variable, _usedMeds]; - - _amountDecreased = _amountDecreased + _decreaseAmount; - - // Restoring the viscosity while the medication is leaving the system - _target setVariable [QGVAR(peripheralResistance), ((_target getVariable [QGVAR(peripheralResistance), 100]) - _viscosityAdjustment) max 0]; - _target setVariable [QGVAR(painSuppress), ((_target getVariable [QGVAR(painSuppress), 0]) - _painReduce) max 0]; - - if (_amountDecreased >= 1 || (_usedMeds <= 0) || !alive _target) then { - [_idPFH] call CBA_fnc_removePerFrameHandler; - }; - _args set [3, _amountDecreased]; -}, 1, [_target, _timeInSystem, _variable, 0, _decreaseAmount, _viscosityAdjustment, _painReduce / _timeInSystem] ] call CBA_fnc_addPerFrameHandler; +// Run the loop that computes the effect of the medication over time +[_target, _timeInSystem, _variable, 0, _decreaseAmount, _viscosityAdjustment, _painReduce / _timeInSystem] call FUNC(medicationEffectLoop); From 12895e798309352f7c032fc2c05f551e45a75263 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 22:58:09 -0300 Subject: [PATCH 015/215] Remove unneeded parameter --- addons/medical/functions/fnc_onMedicationUsage.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_onMedicationUsage.sqf b/addons/medical/functions/fnc_onMedicationUsage.sqf index 2f2b9b6363..28b1d4dd0b 100644 --- a/addons/medical/functions/fnc_onMedicationUsage.sqf +++ b/addons/medical/functions/fnc_onMedicationUsage.sqf @@ -78,4 +78,4 @@ _decreaseAmount = 1 / _timeInSystem; _viscosityAdjustment = _viscosityChange / _timeInSystem; // Run the loop that computes the effect of the medication over time -[_target, _timeInSystem, _variable, 0, _decreaseAmount, _viscosityAdjustment, _painReduce / _timeInSystem] call FUNC(medicationEffectLoop); +[_target, _variable, 0, _decreaseAmount, _viscosityAdjustment, _painReduce / _timeInSystem] call FUNC(medicationEffectLoop); From 94e8bee3483911619de7bd92984f2e13f310d992 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 23:08:25 -0300 Subject: [PATCH 016/215] Move the pfh from setDead to a waitAndExecute loop: reviveStepLoop --- addons/medical/XEH_PREP.hpp | 1 + .../medical/functions/fnc_reviveStateLoop.sqf | 56 +++++++++++++++++++ addons/medical/functions/fnc_setDead.sqf | 37 +----------- 3 files changed, 59 insertions(+), 35 deletions(-) create mode 100644 addons/medical/functions/fnc_reviveStateLoop.sqf diff --git a/addons/medical/XEH_PREP.hpp b/addons/medical/XEH_PREP.hpp index 906f4e18f7..b9ad6ba546 100644 --- a/addons/medical/XEH_PREP.hpp +++ b/addons/medical/XEH_PREP.hpp @@ -64,6 +64,7 @@ PREP(onWoundUpdateRequest); PREP(onPropagateWound); PREP(parseConfigForInjuries); PREP(playInjuredSound); +PREP(reviveStateLoop); PREP(selectionNameToNumber); PREP(serverRemoveBody); PREP(setCardiacArrest); diff --git a/addons/medical/functions/fnc_reviveStateLoop.sqf b/addons/medical/functions/fnc_reviveStateLoop.sqf new file mode 100644 index 0000000000..3e55f7b7ce --- /dev/null +++ b/addons/medical/functions/fnc_reviveStateLoop.sqf @@ -0,0 +1,56 @@ +/* + * Author: Glowbal, esteldunedain + * Loop that handles a unit in the revive state. + * + * Arguments: + * 0: Unit + * + * ReturnValue: + * None + * + * Public: No + */ + +#include "script_component.hpp" + +params ["_unit"] + +// If locality changed finish the local loop +// @todo: reinitiate the loop elsewhere +if (!local _unit) exitWith {}; + +private _startTime = _unit getVariable [QGVAR(reviveStartTime), 0]; + +// Remove heartbeat +if (GVAR(level) >= 2) then { + if (_unit getVariable [QGVAR(heartRate), 60] > 0) then { + _unit setVariable [QGVAR(heartRate), 0]; + }; +}; + +// If we are in revive state in a blown up vehicle, try to unload so that people can access the body +if ((alive _unit) && {(vehicle _unit) != _unit} && {!alive (vehicle _unit)}) then { + TRACE_2("Unloading", _unit, vehicle _unit); + [_unit] call EFUNC(common,unloadPerson); +}; + +// If the timer run out, let the unit die and exit the loop +if (GVAR(maxReviveTime) > 0 && {ACE_time - _startTime > GVAR(maxReviveTime)}) exitwith { + _unit setVariable [QGVAR(inReviveState), nil, true]; + _unit setVariable [QGVAR(reviveStartTime), nil]; + [_unit, true] call FUNC(setDead); +}; + +// If the unit was taken out from revive state, exit the loop +if !(_unit getVariable [QGVAR(inReviveState), false]) exitwith { + // Revived without dieing, so in case we have lifes, remove one. + if (GVAR(amountOfReviveLives) > 0) then { + _lifesLeft = _unit getVariable[QGVAR(amountOfReviveLives), GVAR(amountOfReviveLives)]; + _unit setVariable [QGVAR(amountOfReviveLives), _lifesLeft - 1, true]; + }; + + _unit setVariable [QGVAR(reviveStartTime), nil]; +}; + +// Schedule the loop to be executed again 1 sec later +[DFUNC(reviveStateLoop), [_unit], 1] call EFUNC(common,waitAndExecute); diff --git a/addons/medical/functions/fnc_setDead.sqf b/addons/medical/functions/fnc_setDead.sqf index 913431ccac..061a28c081 100644 --- a/addons/medical/functions/fnc_setDead.sqf +++ b/addons/medical/functions/fnc_setDead.sqf @@ -41,41 +41,8 @@ if (((_reviveVal == 1 && {[_unit] call EFUNC(common,isPlayer)} || _reviveVal == _unit setVariable [QGVAR(reviveStartTime), ACE_time]; [_unit, true] call FUNC(setUnconscious); - [{ - private "_startTime"; - params ["_args", "_idPFH"]; - _args params ["_unit"]; - _startTime = _unit getVariable [QGVAR(reviveStartTime), 0]; - - //If we are in reivie state in a blown up vehicle, try to unload so that people can access the body - if ((alive _unit) && {(vehicle _unit) != _unit} && {!alive (vehicle _unit)}) then { - TRACE_2("Unloading", _unit, vehicle _unit); - [_unit] call EFUNC(common,unloadPerson); - }; - - if (GVAR(maxReviveTime) > 0 && {ACE_time - _startTime > GVAR(maxReviveTime)}) exitwith { - [_idPFH] call CBA_fnc_removePerFrameHandler; - _unit setVariable [QGVAR(inReviveState), nil, true]; - _unit setVariable [QGVAR(reviveStartTime), nil]; - [_unit, true] call FUNC(setDead); - }; - - if !(_unit getVariable [QGVAR(inReviveState), false]) exitwith { - // revived without dieing, so in case we have lifes, remove one. - if (GVAR(amountOfReviveLives) > 0) then { - _lifesLeft = _unit getVariable[QGVAR(amountOfReviveLives), GVAR(amountOfReviveLives)]; - _unit setVariable [QGVAR(amountOfReviveLives), _lifesLeft - 1, true]; - }; - - _unit setVariable [QGVAR(reviveStartTime), nil]; - [_idPFH] call CBA_fnc_removePerFrameHandler; - }; - if (GVAR(level) >= 2) then { - if (_unit getVariable [QGVAR(heartRate), 60] > 0) then { - _unit setVariable [QGVAR(heartRate), 0]; - }; - }; - }, 1, [_unit] ] call CBA_fnc_addPerFrameHandler; + // Run the loop that tracks the revive state + [_unit ] call FUNC(reviveStateLoop); false; }; From 4b702f68dfac6a89212b909e15231ae9668438c9 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 23:10:15 -0300 Subject: [PATCH 017/215] Make loops non public --- addons/medical/functions/fnc_medicationEffectLoop.sqf | 2 +- addons/medical/functions/fnc_vitalLoop.sqf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/medical/functions/fnc_medicationEffectLoop.sqf b/addons/medical/functions/fnc_medicationEffectLoop.sqf index 5ba54bfc9f..6d89675d8a 100644 --- a/addons/medical/functions/fnc_medicationEffectLoop.sqf +++ b/addons/medical/functions/fnc_medicationEffectLoop.sqf @@ -13,7 +13,7 @@ * ReturnValue: * None * - * Public: Yes + * Public: No */ #include "script_component.hpp" diff --git a/addons/medical/functions/fnc_vitalLoop.sqf b/addons/medical/functions/fnc_vitalLoop.sqf index d555f00a75..c9df4c6e91 100644 --- a/addons/medical/functions/fnc_vitalLoop.sqf +++ b/addons/medical/functions/fnc_vitalLoop.sqf @@ -9,7 +9,7 @@ * ReturnValue: * None * - * Public: Yes + * Public: No */ #include "script_component.hpp" From 90a54397ae69ea5b6d1ca9812d92481f2716bb88 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 23:20:26 -0300 Subject: [PATCH 018/215] Move the litter cleanup PFH to a loop using waitAndExecute --- addons/medical/XEH_PREP.hpp | 1 + .../functions/fnc_handleCreateLitter.sqf | 19 ++--------- .../functions/fnc_litterCleanupLoop.sqf | 33 +++++++++++++++++++ 3 files changed, 36 insertions(+), 17 deletions(-) create mode 100644 addons/medical/functions/fnc_litterCleanupLoop.sqf diff --git a/addons/medical/XEH_PREP.hpp b/addons/medical/XEH_PREP.hpp index b9ad6ba546..7c030ecf98 100644 --- a/addons/medical/XEH_PREP.hpp +++ b/addons/medical/XEH_PREP.hpp @@ -117,3 +117,4 @@ PREP(unconsciousPFH); // Networked litter PREP(createLitter); PREP(handleCreateLitter); +PREP(litterCleanupLoop); diff --git a/addons/medical/functions/fnc_handleCreateLitter.sqf b/addons/medical/functions/fnc_handleCreateLitter.sqf index c87d51a7e1..971342affb 100644 --- a/addons/medical/functions/fnc_handleCreateLitter.sqf +++ b/addons/medical/functions/fnc_handleCreateLitter.sqf @@ -44,22 +44,7 @@ if((count GVAR(allCreatedLitter)) > _maxLitterCount ) then { GVAR(allCreatedLitter) pushBack [ACE_time, [_litterObject]]; if(!GVAR(litterPFHRunning) && {GVAR(litterCleanUpDelay) > 0}) then { + // Start the litter cleanup loop GVAR(litterPFHRunning) = true; - [{ - { - _x params ["_time", "_objects"]; - if (ACE_time - _time >= GVAR(litterCleanUpDelay)) then { - { - deleteVehicle _x; - } forEach _objects; - GVAR(allCreatedLitter) set[_forEachIndex, objNull]; - }; - } forEach GVAR(allCreatedLitter); - GVAR(allCreatedLitter) = GVAR(allCreatedLitter) - [objNull]; - - if ( (count GVAR(allCreatedLitter)) == 0) exitWith { - [(_this select 1)] call CBA_fnc_removePerFrameHandler; - GVAR(litterPFHRunning) = false; - }; - }, 30, []] call CBA_fnc_addPerFrameHandler; + call FUNC(litterCleanupLoop); }; diff --git a/addons/medical/functions/fnc_litterCleanupLoop.sqf b/addons/medical/functions/fnc_litterCleanupLoop.sqf new file mode 100644 index 0000000000..ac102d5d59 --- /dev/null +++ b/addons/medical/functions/fnc_litterCleanupLoop.sqf @@ -0,0 +1,33 @@ +/* + * Author: Glowbal, esteldunedain + * Loop that cleans up litter + * + * Arguments: + * None + * + * ReturnValue: + * None + * + * Public: No + */ + +#include "script_component.hpp" + +{ + _x params ["_time", "_objects"]; + if (ACE_time - _time >= GVAR(litterCleanUpDelay)) then { + { + deleteVehicle _x; + } forEach _objects; + GVAR(allCreatedLitter) set[_forEachIndex, objNull]; + }; +} forEach GVAR(allCreatedLitter); +GVAR(allCreatedLitter) = GVAR(allCreatedLitter) - [objNull]; + +// If no more litter remaining, exit the loop +if ( (count GVAR(allCreatedLitter)) == 0) exitWith { + GVAR(litterPFHRunning) = false; +}; + +// Schedule the loop to be executed again 30 sec later +[DFUNC(litterCleanupLoop), [], 30] call EFUNC(common,waitAndExecute); From 9e682253f39f1e369f2163cd8912b95c3f71e4af Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 28 Feb 2016 23:33:51 -0300 Subject: [PATCH 019/215] Move the dead body cleanup PFH to a loop using waitAndExecute --- addons/medical/XEH_PREP.hpp | 1 + .../medical/functions/fnc_bodyCleanupLoop.sqf | 30 +++++++++++++++++++ .../functions/fnc_serverRemoveBody.sqf | 20 ++----------- 3 files changed, 34 insertions(+), 17 deletions(-) create mode 100644 addons/medical/functions/fnc_bodyCleanupLoop.sqf diff --git a/addons/medical/XEH_PREP.hpp b/addons/medical/XEH_PREP.hpp index 7c030ecf98..d7322082c6 100644 --- a/addons/medical/XEH_PREP.hpp +++ b/addons/medical/XEH_PREP.hpp @@ -18,6 +18,7 @@ PREP(addUnconsciousCondition); PREP(addUnloadPatientActions); PREP(addVitalLoop); PREP(adjustPainLevel); +PREP(bodyCleanupLoop); PREP(canAccessMedicalEquipment); PREP(canTreat); PREP(canTreatCached); diff --git a/addons/medical/functions/fnc_bodyCleanupLoop.sqf b/addons/medical/functions/fnc_bodyCleanupLoop.sqf new file mode 100644 index 0000000000..03c1234713 --- /dev/null +++ b/addons/medical/functions/fnc_bodyCleanupLoop.sqf @@ -0,0 +1,30 @@ +/* + * Author: Glowbal, esteldunedain + * Loop that cleans up litter + * + * Arguments: + * None + * + * ReturnValue: + * None + * + * Public: No + */ + +#include "script_component.hpp" + +{ + TRACE_2("body",_x,isPlayer _x); + if ((!isNull _x) && {!isPlayer _x}) then {deleteVehicle _x}; +} forEach GVAR(bodiesToDelete); + +// deleteVehicle doesn't have instant results so it won't usualy be filtered until next run +GVAR(bodiesToDelete) = GVAR(bodiesToDelete) - [objNull]; + +// If no more bodies remain, exit the loop +if (GVAR(bodiesToDelete) isEqualTo []) exitWith { + TRACE_1("array emptied - rem PFEH",GVAR(bodiesToDelete)); +}; + +// Schedule the loop to be executed again 20 sec later +[DFUNC(bodyCleanupLoop), [], 20] call EFUNC(common,waitAndExecute); diff --git a/addons/medical/functions/fnc_serverRemoveBody.sqf b/addons/medical/functions/fnc_serverRemoveBody.sqf index de089b199b..311199b1b8 100644 --- a/addons/medical/functions/fnc_serverRemoveBody.sqf +++ b/addons/medical/functions/fnc_serverRemoveBody.sqf @@ -26,23 +26,9 @@ TRACE_2("",_target,isPlayer _target); if (isNil QGVAR(bodiesToDelete)) then {GVAR(bodiesToDelete) = [];}; GVAR(bodiesToDelete) pushBack _target; -//Start up PFEH to wait for bodies to be free to delete -if ((count GVAR(bodiesToDelete)) == 1) then { - TRACE_1("starting PFEH",GVAR(bodiesToDelete)); - [{ - { - TRACE_2("body",_x,isPlayer _x); - if ((!isNull _x) && {!isPlayer _x}) then {deleteVehicle _x}; - } forEach GVAR(bodiesToDelete); - - //deleteVehicle doesn't have instant results so it won't usualy be filtered until next run - GVAR(bodiesToDelete) = GVAR(bodiesToDelete) - [objNull]; - - if (GVAR(bodiesToDelete) isEqualTo []) then { - TRACE_1("array emptied - rem PFEH",GVAR(bodiesToDelete)); - [_this select 1] call CBA_fnc_removePerFrameHandler; - }; - }, 20, []] call CBA_fnc_addPerFrameHandler; +// Start up a loop to wait for bodies to be free to delete +if ((count GVAR(bodiesToDelete)) > 0) then { + [] call FUNC(bodyCleanupLoop); }; nil From 46a96dd5da73e12c8b337c1fe121bd28db81566a Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Tue, 1 Mar 2016 18:14:36 -0300 Subject: [PATCH 020/215] Move spare barrel event handlers out of postInit --- addons/overheating/XEH_PREP.hpp | 2 + addons/overheating/XEH_postInit.sqf | 97 +------------------ .../functions/fnc_loadCoolestSpareBarrel.sqf | 51 ++++++++++ .../fnc_sendSpareBarrelsTemperaturesHint.sqf | 75 ++++++++++++++ .../functions/fnc_swapBarrelCallback.sqf | 2 +- 5 files changed, 132 insertions(+), 95 deletions(-) create mode 100644 addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf create mode 100644 addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf diff --git a/addons/overheating/XEH_PREP.hpp b/addons/overheating/XEH_PREP.hpp index 26366b9896..8f584ef6e6 100644 --- a/addons/overheating/XEH_PREP.hpp +++ b/addons/overheating/XEH_PREP.hpp @@ -8,7 +8,9 @@ PREP(firedEH); PREP(getWeaponData); PREP(handleTakeEH); PREP(jamWeapon); +PREP(loadCoolestSpareBarrel); PREP(overheat); +PREP(sendSpareBarrelsTemperaturesHint); PREP(swapBarrel); PREP(swapBarrelCallback); PREP(updateSpareBarrelsTemperaturesThread); diff --git a/addons/overheating/XEH_postInit.sqf b/addons/overheating/XEH_postInit.sqf index f29a1c624c..0e8eaad7c4 100644 --- a/addons/overheating/XEH_postInit.sqf +++ b/addons/overheating/XEH_postInit.sqf @@ -12,100 +12,9 @@ if (isServer) then { // Keep track of the temperature of stored spare barrels GVAR(storedSpareBarrels) = [] call CBA_fnc_hashCreate; - ["spareBarrelsCheckTemperatures", { - params ["_player","_unit"]; - // Find all spare barrel the player has - private _allMags = magazinesDetail _unit; - _allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; - if ((count _allMags) < 1) exitWith {}; - - // Determine the temp of each barrel - private _temps = []; - { - private _temp = 0; - if ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashHasKey) then { - _temp = ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashGet) select 0; - }; - _temps pushBack _temp; - } forEach _allMags; - TRACE_1("_temps",_temps); - - // Count cool - private _countCool = {_x < 20} count _temps; - private _countWarm = {(_x >= 20) && (_x < 100)} count _temps; - private _countHot = {(_x >= 100) && (_x < 200)} count _temps; - private _countVeryHot = {(_x >= 200) && (_x < 600)} count _temps; - private _countExtremelyHot = {_x >= 600} count _temps; - private _output = ["%1 %2%3%4 %5%6%7 %8%9%10 %11%12%13 %14"]; - private _size = 1.0; - if (_countCool > 0) then { - _output pushBack _countCool; - _output pushBack LSTRING(BarrelCool); - _output pushBack "
"; - _size = _size + 0.5; - }; - if (_countWarm > 0) then { - _output pushBack _countWarm; - _output pushBack LSTRING(BarrelWarm); - _output pushBack "
"; - _size = _size + 0.5; - }; - if (_countHot > 0) then { - _output pushBack _countHot; - _output pushBack LSTRING(BarrelHot); - _output pushBack "
"; - _size = _size + 0.5; - }; - if (_countVeryHot > 0) then { - _output pushBack _countVeryHot; - _output pushBack LSTRING(BarrelVeryHot); - _output pushBack "
"; - _size = _size + 0.5; - }; - if (_countExtremelyHot > 0) then { - _output pushBack _countExtremelyHot; - _output pushBack LSTRING(BarrelExtremelyHot); - _size = _size + 0.5; - }; - - TRACE_1("_output",_output); - ["displayTextStructured", [_player], [_output, _size, _player]] call EFUNC(common,targetEvent); - }] call EFUNC(common,addEventHandler); - - ["spareBarrelLoadedCoolest", { - params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; - TRACE_4("spareBarrelLoadedCoolest1",_unit,_weapon,_weaponTemp,_barrelMass); - - // Find all spare barrel the player has - private _allMags = magazinesDetail _unit; - TRACE_1("spareBarrelLoadedCoolest2",_allMags); - _allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; - TRACE_1("spareBarrelLoadedCoolest3",_allMags); - if ((count _allMags) < 1) exitWith {}; - - // Determine which on is coolest - private _coolestTemp = 10000; - private _coolestMag = _allMags select 0; - { - private _temp = 0; - if ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashHasKey) then { - _temp = ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashGet) select 0; - }; - TRACE_2("spareBarrelLoadedCoolest4",_x,_temp); - if (_temp < _coolestTemp) then { - _coolestTemp = _temp; - _coolestMag = _x; - }; - } forEach _allMags; - TRACE_3("spareBarrelLoadedCoolest5",_coolestTemp,_coolestMag,_weaponTemp); - - // The new weapon temperature is similar to the coolest barrel - // Publish the new temperature value - _unit setVariable [format [QGVAR(%1_temp), _weapon], _coolestTemp, true]; - - // Heat up the coolest barrel to the former weapon temperature - [GVAR(storedSpareBarrels), _coolestMag, [_weaponTemp, ACE_Time, _barrelMass]] call CBA_fnc_hashSet; - }] call EFUNC(common,addEventHandler); + // Install event handlers for spare barrels + ["spareBarrelsSendTemperatureHint", FUNC(sendSpareBarrelsTemperaturesHint)] call EFUNC(common,addEventHandler); + ["spareBarrelsLoadCoolest", FUNC(loadCoolestSpareBarrel)] call EFUNC(common,addEventHandler); // Schedule cool down calculation of stored spare barrels [] call FUNC(updateSpareBarrelsTemperaturesThread); diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf new file mode 100644 index 0000000000..97fe9d8883 --- /dev/null +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -0,0 +1,51 @@ +/* + * Author: esteldunedain + * Collect the temperature of all the spare barrels a unit has and load the + * coolest on the unit weapon. Runs on the server. + * + * Argument: + * 0: Unit + * 1: Weapon + * 2: Weapon temp before switching + * 3: Mass of the removed barrel + * + * Return value: + * None + * + * + * Public: No + */ +#include "script_component.hpp" + +params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; +TRACE_4("loadCoolestSpareBarrel1",_unit,_weapon,_weaponTemp,_barrelMass); + +// Find all spare barrel the player has +private _allMags = magazinesDetail _unit; +TRACE_1("loadCoolestSpareBarrel2",_allMags); +_allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; +TRACE_1("loadCoolestSpareBarrel3",_allMags); +if ((count _allMags) < 1) exitWith {}; + +// Determine which on is coolest +private _coolestTemp = 10000; +private _coolestMag = _allMags select 0; +{ + private _temp = 0; + if ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashHasKey) then { + _temp = ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashGet) select 0; + }; + TRACE_2("loadCoolestSpareBarrel4",_x,_temp); + if (_temp < _coolestTemp) then { + _coolestTemp = _temp; + _coolestMag = _x; + }; +} forEach _allMags; +TRACE_3("loadCoolestSpareBarrel5",_coolestTemp,_coolestMag,_weaponTemp); + +// The new weapon temperature is similar to the coolest barrel +// Publish the new temperature value +_unit setVariable [format [QGVAR(%1_temp), _weapon], _coolestTemp, true]; + +// Heat up the coolest barrel to the former weapon temperature +[GVAR(storedSpareBarrels), _coolestMag, [_weaponTemp, ACE_Time, _barrelMass]] call CBA_fnc_hashSet; diff --git a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf new file mode 100644 index 0000000000..01a6ecc0a4 --- /dev/null +++ b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf @@ -0,0 +1,75 @@ +/* + * Author: esteldunedain + * Collect the temperature of all the spare barrels a unit has and send a hint + * to a client. Runs on the server. + * + * Argument: + * 0: Target unit of the hint + * 1: Unit that has the spare barrels + * + * Return value: + * None + * + * + * Public: No + */ +#include "script_component.hpp" + +params ["_player","_unit"]; + +// Find all spare barrel the player has +private _allMags = magazinesDetail _unit; +_allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; +if ((count _allMags) < 1) exitWith {}; + +// Determine the temp of each barrel +private _temps = []; +{ + private _temp = 0; + if ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashHasKey) then { + _temp = ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashGet) select 0; + }; + _temps pushBack _temp; +} forEach _allMags; +TRACE_1("_temps",_temps); + +// Count cool +private _countCool = {_x < 20} count _temps; +private _countWarm = {(_x >= 20) && (_x < 100)} count _temps; +private _countHot = {(_x >= 100) && (_x < 200)} count _temps; +private _countVeryHot = {(_x >= 200) && (_x < 600)} count _temps; +private _countExtremelyHot = {_x >= 600} count _temps; +private _output = ["%1 %2%3%4 %5%6%7 %8%9%10 %11%12%13 %14"]; +private _size = 1.0; +if (_countCool > 0) then { + _output pushBack _countCool; + _output pushBack LSTRING(BarrelCool); + _output pushBack "
"; + _size = _size + 0.5; +}; +if (_countWarm > 0) then { + _output pushBack _countWarm; + _output pushBack LSTRING(BarrelWarm); + _output pushBack "
"; + _size = _size + 0.5; +}; +if (_countHot > 0) then { + _output pushBack _countHot; + _output pushBack LSTRING(BarrelHot); + _output pushBack "
"; + _size = _size + 0.5; +}; +if (_countVeryHot > 0) then { + _output pushBack _countVeryHot; + _output pushBack LSTRING(BarrelVeryHot); + _output pushBack "
"; + _size = _size + 0.5; +}; +if (_countExtremelyHot > 0) then { + _output pushBack _countExtremelyHot; + _output pushBack LSTRING(BarrelExtremelyHot); + _size = _size + 0.5; +}; + +TRACE_1("_output",_output); +["displayTextStructured", [_player], [_output, _size, _player]] call EFUNC(common,targetEvent); diff --git a/addons/overheating/functions/fnc_swapBarrelCallback.sqf b/addons/overheating/functions/fnc_swapBarrelCallback.sqf index 8bd63e4874..6eba214617 100644 --- a/addons/overheating/functions/fnc_swapBarrelCallback.sqf +++ b/addons/overheating/functions/fnc_swapBarrelCallback.sqf @@ -34,7 +34,7 @@ private _barrelMass = 0.50 * (getNumber (configFile >> "CfgWeapons" >> _weapon > // store the removed barrel with the former weapon temperature. The server // also updates the current weapon temperature to match that of the new // loaded barrel. -["spareBarrelLoadedCoolest", [_player, _weapon, _temp, _barrelMass]] call EFUNC(common,serverEvent); +["spareBarrelsLoadCoolest", [_player, _weapon, _temp, _barrelMass]] call EFUNC(common,serverEvent); // Store the update time _player setVariable [format [QGVAR(%1_time), _weapon], ACE_time]; From a041555381376834bb4d482e6b927080a731fb85 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Tue, 1 Mar 2016 18:16:14 -0300 Subject: [PATCH 021/215] Add an animation and progressbar to the "Check spare barrels temperatures" action --- addons/overheating/CfgVehicles.hpp | 2 +- addons/overheating/XEH_PREP.hpp | 1 + .../fnc_checkSpareBarrelsTemperatures.sqf | 36 +++++++++++++++++++ addons/overheating/stringtable.xml | 5 ++- 4 files changed, 42 insertions(+), 2 deletions(-) create mode 100644 addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index 61b619a79b..928a22420a 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -34,7 +34,7 @@ class CfgVehicles { displayName = CSTRING(CheckTemperatureSpareBarrelsShort); condition = QUOTE( 'ACE_SpareBarrel' in magazines _player); exceptions[] = {"isNotInside", "isNotSitting"}; - statement = QUOTE([ARR_2('spareBarrelsCheckTemperatures',[ARR_2(_player,_player)])] call EFUNC(common,serverEvent);); + statement = QUOTE( [ARR_1(_player)] call FUNC(checkSpareBarrelsTemperatures); ); showDisabled = 0; priority = 2.8; icon = QUOTE(PATHTOF(UI\temp_ca.paa)); diff --git a/addons/overheating/XEH_PREP.hpp b/addons/overheating/XEH_PREP.hpp index 8f584ef6e6..cc1948e6bd 100644 --- a/addons/overheating/XEH_PREP.hpp +++ b/addons/overheating/XEH_PREP.hpp @@ -1,6 +1,7 @@ PREP(calculateCooling); PREP(canUnjam); +PREP(checkSpareBarrelsTemperatures); PREP(checkTemperature); PREP(clearJam); PREP(displayTemperature); diff --git a/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf b/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf new file mode 100644 index 0000000000..b7509671bb --- /dev/null +++ b/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf @@ -0,0 +1,36 @@ +/* + * Author: esteldunedain + * Make the player check the temperature of his spare barrels + * + * Arguments: + * 0: Player + * + * Return Value: + * None + * + * + * Public: No + */ +#include "script_component.hpp" + +params ["_player"]; + +// Check canInteractWith: +if (!([_player, objNull, ["isNotInside", "isNotSitting"]] call EFUNC(common,canInteractWith))) exitWith {}; + +// Make the unit go kneeling +[_unit] call EFUNC(common,goKneeling); + +// Spawn a progress bar +[ + 5.0, + [_player], + { + // Time has enlapsed, ask the server to send the hint + ['spareBarrelsSendTemperatureHint', [_unit, _unit]] call EFUNC(common,serverEvent); + }, + {}, + (localize LSTRING(CheckingSpareBarrelsTemperatures)), + {true}, + ["isNotInside", "isNotSitting"] +] call EFUNC(common,progressBar); diff --git a/addons/overheating/stringtable.xml b/addons/overheating/stringtable.xml index ace5806f61..fc38ae0054 100644 --- a/addons/overheating/stringtable.xml +++ b/addons/overheating/stringtable.xml @@ -230,7 +230,10 @@ Проверка температуры... - Check spare barrel temperatures + Check spare barrels temperatures + + + Checking spare barrels temperatures... Temperature From b8c8c21a02de54fbe9081376fee72db6943ccba0 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Tue, 1 Mar 2016 18:17:23 -0300 Subject: [PATCH 022/215] Remove spare barrels from starting equipments --- addons/overheating/CfgVehicles.hpp | 26 -------------------------- 1 file changed, 26 deletions(-) diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index 928a22420a..8981c907f7 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -108,30 +108,4 @@ class CfgVehicles { MACRO_ADDITEM(ACE_SpareBarrel,6); }; }; -/* - // Add ACE_SpareBarrel to every machine gunner. - #define MACRO_ADDSPAREBARREL \ - items[] = {"FirstAidKit", "ACE_SpareBarrel"}; \ - respawnitems[] = {"FirstAidKit", "ACE_SpareBarrel"}; - - // NATO - class B_Soldier_02_f; class B_soldier_AR_F:B_Soldier_02_f {MACRO_ADDSPAREBARREL}; - class B_Soldier_support_base_F; class B_soldier_AAR_F:B_Soldier_support_base_F {MACRO_ADDSPAREBARREL}; - class B_Soldier_base_F; class B_CTRG_soldier_AR_A_F:B_Soldier_base_F {MACRO_ADDSPAREBARREL}; - - // Guerrilla - class I_G_Soldier_base_F; class I_G_Soldier_AR_F:I_G_Soldier_base_F {MACRO_ADDSPAREBARREL}; - class B_G_Soldier_AR_F:I_G_Soldier_AR_F {MACRO_ADDSPAREBARREL}; - class O_G_Soldier_AR_F:I_G_Soldier_AR_F {MACRO_ADDSPAREBARREL}; - - // Iran - class O_Soldier_base_F; class O_Soldier_AR_F:O_Soldier_base_F {MACRO_ADDSPAREBARREL}; - class O_Soldier_support_base_F; class O_Soldier_AAR_F:O_Soldier_support_base_F {MACRO_ADDSPAREBARREL}; - class O_Soldier_Urban_base; class O_soldierU_AR_F:O_Soldier_Urban_base {MACRO_ADDSPAREBARREL}; - class O_soldierU_AAR_F:O_Soldier_Urban_base {MACRO_ADDSPAREBARREL}; - - // Czech - class I_Soldier_02_F; class I_Soldier_AR_F:I_Soldier_02_F {MACRO_ADDSPAREBARREL}; - class I_Soldier_support_base_F; class I_Soldier_AAR_F:I_Soldier_support_base_F {MACRO_ADDSPAREBARREL}; -*/ }; From f130d6c2530cac2bc6fae3d73744e6bdd2909c02 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Tue, 1 Mar 2016 18:17:58 -0300 Subject: [PATCH 023/215] Increase spare barrel mass to 60 (2.7 Kg) --- addons/overheating/CfgMagazines.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/overheating/CfgMagazines.hpp b/addons/overheating/CfgMagazines.hpp index ad381ff30e..d9b3ee2bdc 100644 --- a/addons/overheating/CfgMagazines.hpp +++ b/addons/overheating/CfgMagazines.hpp @@ -5,7 +5,7 @@ class CfgMagazines { picture = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); displayName = "ACE Spare Barrel"; //!!!CANNOT be localized!!!: because it is used as part of the magazineDetail string count = 1; - mass = 40; + mass = 60; ACE_isUnique = 1; }; }; From e6a2ca71026a090a1f63018c8e93be2fc9573391 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Tue, 1 Mar 2016 19:25:45 -0300 Subject: [PATCH 024/215] Fix typos --- addons/overheating/CfgVehicles.hpp | 2 +- .../functions/fnc_checkSpareBarrelsTemperatures.sqf | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index 8981c907f7..61052553a4 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -34,7 +34,7 @@ class CfgVehicles { displayName = CSTRING(CheckTemperatureSpareBarrelsShort); condition = QUOTE( 'ACE_SpareBarrel' in magazines _player); exceptions[] = {"isNotInside", "isNotSitting"}; - statement = QUOTE( [ARR_1(_player)] call FUNC(checkSpareBarrelsTemperatures); ); + statement = QUOTE( [_player] call FUNC(checkSpareBarrelsTemperatures); ); showDisabled = 0; priority = 2.8; icon = QUOTE(PATHTOF(UI\temp_ca.paa)); diff --git a/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf b/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf index b7509671bb..e8dbaabec0 100644 --- a/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf +++ b/addons/overheating/functions/fnc_checkSpareBarrelsTemperatures.sqf @@ -19,15 +19,17 @@ params ["_player"]; if (!([_player, objNull, ["isNotInside", "isNotSitting"]] call EFUNC(common,canInteractWith))) exitWith {}; // Make the unit go kneeling -[_unit] call EFUNC(common,goKneeling); +[_player] call EFUNC(common,goKneeling); // Spawn a progress bar [ 5.0, [_player], { + params ["_args", "_elapsedTime", "_totalTime", "_errorCode"]; + _args params ["_player"]; // Time has enlapsed, ask the server to send the hint - ['spareBarrelsSendTemperatureHint', [_unit, _unit]] call EFUNC(common,serverEvent); + ['spareBarrelsSendTemperatureHint', [_player, _player]] call EFUNC(common,serverEvent); }, {}, (localize LSTRING(CheckingSpareBarrelsTemperatures)), From 850a499c0e246fbd70b10a90c0e04cc9abf1364d Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Tue, 1 Mar 2016 19:26:20 -0300 Subject: [PATCH 025/215] Localize spare barrel's displayName --- addons/overheating/CfgMagazines.hpp | 2 +- addons/overheating/XEH_preInit.sqf | 10 ++++++++++ .../functions/fnc_loadCoolestSpareBarrel.sqf | 13 ++++++------- .../fnc_sendSpareBarrelsTemperaturesHint.sqf | 9 +++++---- 4 files changed, 22 insertions(+), 12 deletions(-) diff --git a/addons/overheating/CfgMagazines.hpp b/addons/overheating/CfgMagazines.hpp index d9b3ee2bdc..cc040eca0f 100644 --- a/addons/overheating/CfgMagazines.hpp +++ b/addons/overheating/CfgMagazines.hpp @@ -1,9 +1,9 @@ class CfgMagazines { class CA_Magazine; class ACE_SpareBarrel: CA_Magazine { + displayName = CSTRING(SpareBarrelName); descriptionshort = CSTRING(SpareBarrelDescription); picture = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); - displayName = "ACE Spare Barrel"; //!!!CANNOT be localized!!!: because it is used as part of the magazineDetail string count = 1; mass = 60; ACE_isUnique = 1; diff --git a/addons/overheating/XEH_preInit.sqf b/addons/overheating/XEH_preInit.sqf index a7feade1c3..54bc392273 100644 --- a/addons/overheating/XEH_preInit.sqf +++ b/addons/overheating/XEH_preInit.sqf @@ -4,4 +4,14 @@ ADDON = false; #include "XEH_PREP.hpp" +FakeCBA_fnc_getMagazineIds = { + params [["_unit", objNull, [objNull]], ["_magazine", "", [""]]]; + + private _displayName = getText (configFile >> "CfgMagazines" >> _magazine >> "displayName"); + + if (_displayName isEqualTo "") exitWith {[]}; + + magazinesDetail _unit select {_x find _displayName == 0} apply {_x = _x splitString "[:]"; _x select (count _x - 1)}; +}; + ADDON = true; diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf index 97fe9d8883..23d2c7959e 100644 --- a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -21,15 +21,13 @@ params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; TRACE_4("loadCoolestSpareBarrel1",_unit,_weapon,_weaponTemp,_barrelMass); // Find all spare barrel the player has -private _allMags = magazinesDetail _unit; -TRACE_1("loadCoolestSpareBarrel2",_allMags); -_allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; -TRACE_1("loadCoolestSpareBarrel3",_allMags); -if ((count _allMags) < 1) exitWith {}; +private _allBarrels = [_unit, "ACE_SpareBarrel"] call FakeCBA_fnc_getMagazineIds; +TRACE_1("_allBarrels",_allBarrels); +if ((count _allBarrels) < 1) exitWith {}; // Determine which on is coolest private _coolestTemp = 10000; -private _coolestMag = _allMags select 0; +private _coolestMag = _allBarrels select 0; { private _temp = 0; if ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashHasKey) then { @@ -40,7 +38,7 @@ private _coolestMag = _allMags select 0; _coolestTemp = _temp; _coolestMag = _x; }; -} forEach _allMags; +} forEach _allBarrels; TRACE_3("loadCoolestSpareBarrel5",_coolestTemp,_coolestMag,_weaponTemp); // The new weapon temperature is similar to the coolest barrel @@ -49,3 +47,4 @@ _unit setVariable [format [QGVAR(%1_temp), _weapon], _coolestTemp, true]; // Heat up the coolest barrel to the former weapon temperature [GVAR(storedSpareBarrels), _coolestMag, [_weaponTemp, ACE_Time, _barrelMass]] call CBA_fnc_hashSet; + diff --git a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf index 01a6ecc0a4..9f286832c6 100644 --- a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf +++ b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf @@ -18,9 +18,10 @@ params ["_player","_unit"]; // Find all spare barrel the player has -private _allMags = magazinesDetail _unit; -_allMags = _allMags select {_x find "ACE Spare Barrel" == 0}; -if ((count _allMags) < 1) exitWith {}; +TRACE_2("sendSpareBarrelsTemperatureHunt",_player,_unit); +private _allBarrels = [_unit, "ACE_SpareBarrel"] call FakeCBA_fnc_getMagazineIds; +TRACE_1("_allBarrels",_allBarrels); +if ((count _allBarrels) < 1) exitWith {}; // Determine the temp of each barrel private _temps = []; @@ -30,7 +31,7 @@ private _temps = []; _temp = ([GVAR(storedSpareBarrels), _x] call CBA_fnc_hashGet) select 0; }; _temps pushBack _temp; -} forEach _allMags; +} forEach _allBarrels; TRACE_1("_temps",_temps); // Count cool From d8862897163ee46c23a4e3caf382a735eeab6c2e Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Tue, 1 Mar 2016 19:27:39 -0300 Subject: [PATCH 026/215] Display the new weapon temperature right after swapping barrels --- addons/overheating/XEH_postInit.sqf | 5 +++++ addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf | 2 ++ addons/overheating/functions/fnc_swapBarrelCallback.sqf | 3 --- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/addons/overheating/XEH_postInit.sqf b/addons/overheating/XEH_postInit.sqf index 0e8eaad7c4..831c2c2348 100644 --- a/addons/overheating/XEH_postInit.sqf +++ b/addons/overheating/XEH_postInit.sqf @@ -55,3 +55,8 @@ GVAR(cacheSilencerData) = call CBA_fnc_createNamespace; ["firedPlayerNonLocal", DFUNC(firedEH)] call EFUNC(common,addEventHandler); }; }] call EFUNC(common,addEventHandler); + +// Install event handlers to display temp when a barrel was swapped +["barrelSwapped", { + _this call FUNC(displayTemperature); +}] call EFUNC(common,addEventHandler); diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf index 23d2c7959e..dd58d58207 100644 --- a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -48,3 +48,5 @@ _unit setVariable [format [QGVAR(%1_temp), _weapon], _coolestTemp, true]; // Heat up the coolest barrel to the former weapon temperature [GVAR(storedSpareBarrels), _coolestMag, [_weaponTemp, ACE_Time, _barrelMass]] call CBA_fnc_hashSet; +// Send an event so the local machine can show the hint +["barrelSwapped", _unit, [_unit, _weapon]] call EFUNC(common,objectEvent); diff --git a/addons/overheating/functions/fnc_swapBarrelCallback.sqf b/addons/overheating/functions/fnc_swapBarrelCallback.sqf index 6eba214617..62a3b13ef6 100644 --- a/addons/overheating/functions/fnc_swapBarrelCallback.sqf +++ b/addons/overheating/functions/fnc_swapBarrelCallback.sqf @@ -24,9 +24,6 @@ TRACE_2("params",_player,_weapon); _player playAction QGVAR(GestureMountMuzzle); playSound "ACE_BarrelSwap"; -// don't consume the barrel, but rotate through them. -[localize LSTRING(SwappedBarrel), QUOTE(PATHTOF(UI\spare_barrel_ca.paa))] call EFUNC(common,displayTextPicture); - private _temp = _player getVariable [format [QGVAR(%1_temp), _weapon], 0]; private _barrelMass = 0.50 * (getNumber (configFile >> "CfgWeapons" >> _weapon >> "WeaponSlotsInfo" >> "mass") / 22.0) max 1.0; From e7ec87d28427730c0994123a8aee26608d758eef Mon Sep 17 00:00:00 2001 From: ColdEvul Date: Wed, 2 Mar 2016 16:38:23 +0100 Subject: [PATCH 027/215] Added carry and interaction for case. --- addons/cargo/CfgVehicles.hpp | 17 +++++++++++++++++ addons/dragging/CfgVehicles.hpp | 26 ++++++++++++++++++++++++++ 2 files changed, 43 insertions(+) diff --git a/addons/cargo/CfgVehicles.hpp b/addons/cargo/CfgVehicles.hpp index e1750d8aad..96896fdec9 100644 --- a/addons/cargo/CfgVehicles.hpp +++ b/addons/cargo/CfgVehicles.hpp @@ -256,6 +256,7 @@ class CfgVehicles { // Ammo boxes class ThingX; + class Items_base_F; class ReammoBox_F: ThingX { GVAR(size) = 2; // 1 = small, 2 = large GVAR(canLoad) = 1; @@ -278,6 +279,22 @@ class CfgVehicles { class Slingload_01_Base_F: Slingload_base_F { //Huron 20ft containers GVAR(canLoad) = 0; }; + + class PlasticCase_01_base_F: Items_base_F { + GVAR(size) = 1; // 1 = small, 2 = large + GVAR(canLoad) = 1; + }; + class Land_PlasticCase_01_large_F: PlasticCase_01_base_F { + GVAR(size) = 2; // 1 = small, 2 = large + }; + class MetalCase_01_base_F: Items_base_F { + GVAR(size) = 1; // 1 = small, 2 = large + GVAR(canLoad) = 1; + }; + class Land_MetalCase_01_large_F: MetalCase_01_base_F { + GVAR(size) = 2; // 1 = small, 2 = large + }; + // objects class RoadCone_F: ThingX { GVAR(size) = 1; diff --git a/addons/dragging/CfgVehicles.hpp b/addons/dragging/CfgVehicles.hpp index dab8c1e842..92bb6cf12c 100644 --- a/addons/dragging/CfgVehicles.hpp +++ b/addons/dragging/CfgVehicles.hpp @@ -33,6 +33,7 @@ class CfgVehicles { // ammo boxes class ThingX; + class Items_base_F; class ReammoBox_F: ThingX { GVAR(canCarry) = 0; GVAR(carryPosition[]) = {0,1,1}; @@ -85,6 +86,31 @@ class CfgVehicles { GVAR(canDrag) = 0; }; + class PlasticCase_01_base_F: Items_base_F { + class EventHandlers { + class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; + }; + GVAR(canCarry) = 1; + GVAR(carryPosition[]) = {0,1,1}; + GVAR(carryDirection) = 90; + + GVAR(canDrag) = 1; + GVAR(dragPosition[]) = {0,1.2,0}; + GVAR(dragDirection) = 0; + }; + class MetalCase_01_base_F: Items_base_F { + class EventHandlers { + class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; + }; + GVAR(canCarry) = 1; + GVAR(carryPosition[]) = {0,1,1}; + GVAR(carryDirection) = 90; + + GVAR(canDrag) = 1; + GVAR(dragPosition[]) = {0,1.2,0}; + GVAR(dragDirection) = 0; + }; + // Barrier class RoadCone_F: ThingX { class EventHandlers { From b91897de3b4a5ef114129225074ae8c19b1e6de4 Mon Sep 17 00:00:00 2001 From: ColdEvul Date: Wed, 2 Mar 2016 16:41:45 +0100 Subject: [PATCH 028/215] Added comment --- addons/cargo/CfgVehicles.hpp | 1 + addons/dragging/CfgVehicles.hpp | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/cargo/CfgVehicles.hpp b/addons/cargo/CfgVehicles.hpp index 96896fdec9..82475b72a4 100644 --- a/addons/cargo/CfgVehicles.hpp +++ b/addons/cargo/CfgVehicles.hpp @@ -280,6 +280,7 @@ class CfgVehicles { GVAR(canLoad) = 0; }; + //Plastic and metal case class PlasticCase_01_base_F: Items_base_F { GVAR(size) = 1; // 1 = small, 2 = large GVAR(canLoad) = 1; diff --git a/addons/dragging/CfgVehicles.hpp b/addons/dragging/CfgVehicles.hpp index 92bb6cf12c..53b0900744 100644 --- a/addons/dragging/CfgVehicles.hpp +++ b/addons/dragging/CfgVehicles.hpp @@ -85,7 +85,8 @@ class CfgVehicles { GVAR(canCarry) = 0; GVAR(canDrag) = 0; }; - + + //Plastic and metal case class PlasticCase_01_base_F: Items_base_F { class EventHandlers { class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; From 8b4892598ab2f65ded4b0b14e3c321f0fc5cbb74 Mon Sep 17 00:00:00 2001 From: ColdEvul Date: Wed, 2 Mar 2016 22:17:19 +0100 Subject: [PATCH 029/215] added EventHandlers --- addons/cargo/CfgEventHandlers.hpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/addons/cargo/CfgEventHandlers.hpp b/addons/cargo/CfgEventHandlers.hpp index 3f784e7ab4..391c3a662d 100644 --- a/addons/cargo/CfgEventHandlers.hpp +++ b/addons/cargo/CfgEventHandlers.hpp @@ -57,6 +57,16 @@ class Extended_InitPost_EventHandlers { init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); }; }; + class PlasticCase_01_base_F { + class ADDON { + init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); + }; + }; + class MetalCase_01_base_F { + class ADDON { + init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); + }; + }; class RoadCone_F { class ADDON { init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); From 730e79def089075b651ade6e70c45b703e3b3448 Mon Sep 17 00:00:00 2001 From: nomisum Date: Wed, 2 Mar 2016 22:17:49 +0100 Subject: [PATCH 030/215] added fastroping sounds --- addons/fastroping/CfgSounds.hpp | 12 ++++++++++++ addons/fastroping/data/sounds/LICENSE.md | 4 ++++ .../fastroping/data/sounds/fastroping_rope.ogg | Bin 0 -> 32290 bytes .../fastroping/data/sounds/fastroping_thud.ogg | Bin 0 -> 20522 bytes .../functions/fnc_fastRopeLocalPFH.sqf | 9 +++++++++ 5 files changed, 25 insertions(+) create mode 100644 addons/fastroping/CfgSounds.hpp create mode 100644 addons/fastroping/data/sounds/LICENSE.md create mode 100644 addons/fastroping/data/sounds/fastroping_rope.ogg create mode 100644 addons/fastroping/data/sounds/fastroping_thud.ogg diff --git a/addons/fastroping/CfgSounds.hpp b/addons/fastroping/CfgSounds.hpp new file mode 100644 index 0000000000..e6532146fe --- /dev/null +++ b/addons/fastroping/CfgSounds.hpp @@ -0,0 +1,12 @@ +class CfgSounds { + class ACE_Fastroping_Rope { + name = "ACE_Fastroping_Rope"; + sound[] = {PATHTOF(data\sounds\fastroping_rope.ogg), db0, 1.0}; + titles[] = {}; + }; + class ACE_Fastroping_Thud { + name = "ACE_Fastroping_Thud"; + sound[] = {PATHTOF(data\sounds\fastroping_thud.ogg), db0, 1.0}; + titles[] = {}; + }; +}; \ No newline at end of file diff --git a/addons/fastroping/data/sounds/LICENSE.md b/addons/fastroping/data/sounds/LICENSE.md new file mode 100644 index 0000000000..d6312034ca --- /dev/null +++ b/addons/fastroping/data/sounds/LICENSE.md @@ -0,0 +1,4 @@ +Uses a sound from Tessa Elieff (Freesound.org) +according to Creative Commons Attribution License. + +Also sounds from helenacm and Adam_N, both under CC 0. Thanks anyway. \ No newline at end of file diff --git a/addons/fastroping/data/sounds/fastroping_rope.ogg b/addons/fastroping/data/sounds/fastroping_rope.ogg new file mode 100644 index 0000000000000000000000000000000000000000..ec68da29607a9c84d26a198b12a97b0ee3c1bdcc GIT binary patch literal 32290 zcmce;byQr<^Cvt=aCZn0G&sQn1b6pA26uONLU4Br?l!nXfZ*<~2?Pk5;0ZQ6B+plV z`<}DAf4zNrdb;{{SKq4sRCV3H1Im_`>Ht{4KWUTlZ$)b)$Qy3IY#MYvJ=%j{gwU;o{gosCCa>g|8G{N?li z(gO41uW(Fa;+il3B4Gg3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jnVa_ZU8_aHF{k$#IOLI-T?qm6e?weRJP{oXJ;?! z&CJNmP!$<$6#XQRWfn+gMmiQb^hpcw>NB}ym?rycwXoCI=<2HvR#mSDoW?e|9HP(ySEOlPQ1mJvSJA^3MS z8r5uzrL10dXLMBXTcchJ=bPec}w11Up3rzfeilX?dh;UfRW+LK=UlJkm>9} zgP?nKyi}q@94e`n>bo!nn$i+kb;F85#~=pZNzdc}B1ut%Krs0ZI%`g^Fxn2cFW#kC zYV~SBgYX6|y%t0$B3>Zkq)Bb#J3K3q6G@>9Cqcxb;x=IkRV&^|Rw_@W)JD=5qiRD> zMf*|)ztW#hTT1QHq$LZ&xiIa)xKgx&p=j$o)ORImTh?XpSTR9@r;eE{hRiFFe(TR3TgM4GJ z=u%o7a=0hIN#e+{*=D^msWam#KGod8*>|NlX4U88J}$?n_nKDMDBdd8;PH=E9C-{h zQb>QQ?{^2J@>Azv>_1d!_T4ef0rqCQ5McZ1HR9}+@!`BPhNfIkH2iH s76((8cRl<75%t@9$9G#2Q=z~3fBD_pBy3p-&?HVA=?$x3tf`tz0J*%UEdT%j literal 0 HcmV?d00001 diff --git a/addons/fastroping/data/sounds/fastroping_thud.ogg b/addons/fastroping/data/sounds/fastroping_thud.ogg new file mode 100644 index 0000000000000000000000000000000000000000..136a638ea9033a059138df2443eca54539344e4b GIT binary patch literal 20522 zcma&O1z1*1w=lfv4wVi83AyR+M!Ii0rMtU9xV`@0Z~A@yF=m`Tp<(ZY1Jz2W{ztd~Dzm!Np1T8B^OC}{}3vyd4V~t1pS5$;CaCJ*W^YO^>ELW(M$W;+f(61}iKiCYDvw}Rj)#B#jmyfyB`(SR@0P!G{{OVV zApB*HUQApA20#Xm?7CXWK1GQsmoxUl_-? zM_V^4hQ?SoE-TMErD0OthN$oBGR(W3{ZE1N$Okz%7coRaQ*1Hh2l5e+l5}T~)L*v9 zfk2Q=K=LSK3hH2T)7Nx2n{juWare_s57lk*({2jY zoekB$2sI)I`zK%etz10hN7l(gjK=_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I2wHcQ? z^GqN_08#5LGdYOjs#}B@1N0jJx*jp0akp7LH!oQ7;0x0!1p)$*v0&AF)D_%je>=CQj&(+YBfdKW@7pkA?`I^FvHWv?G+BGu-{V&2W_c#u3lyL!gnkuj-D=B6 z--z134&bG<1c0Dqa$*)WJ8%iTqD_^I#Qa+E6G7+1_RSbv z1H#!@*VzT`3T*hU+pdbLwk0Mo#V*91SzS?ux&TL5a!oJ)-mrtWUbF)>%XXC(9<$+N zX&)Nzi&)>8j*a8Wd*jD*YaPY)uKe0rkDOt5Ov!mI2GGzJC=}BPTr@i&3u!5}?c;r< zn^7uS$5~%Q!#IaF+JQ>2Uhr~PoByXI8f)7|^3y7}ubj9z60Pqt_#`58R$YG!2ayxb zeR&W5(udwxB4pUh3;dK~@4oyW7PmjfBn*56|H}4SkJ~VB^10!~lR5$v)6~|>=1N-f zZ@jBm&e&R?;uQ%;92X4%Q>Hg49;KIJm1_sWP?a}Ds9oI17y1NwA#!!ky!LF!oZH6= z>CHVh1zp5K(H*=3Y`Wh`Vvq*J5%esDYUID@b`QvzDvnEOs@7K=vG4UOf9IeBf8sA| zv6Ny>Jvg3rY`P>XwIqt$WZ;n|qXo#IFNBBEi(U#x__Cx4wIrJ@QF;NL^#`MtpNPcn zp;Pa-p$UXmudbcG<4{!IF%WRl_+Q{!i4>j{)U0$u?j+`(aduWavR|)6#MK2+Ifrst zN{<+gTcLL<4(8%@34tOsY8Y)1m{7cBW7+KTX&b3=C5D&O@C%LJOlb+5ZKhj#oEYU|(w? z-R2Gofx6kXRwH6+E0}MXOz0#))Ird{U1T0{!(Dr_Enml^(A7f>32Fz+w9>fyFTiOu QbgX}mJ!-das>SsG0j;W%QUCw| literal 0 HcmV?d00001 diff --git a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf index d05c8bfdbc..7279d4838a 100644 --- a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf @@ -31,10 +31,19 @@ if (animationState _unit != "ACE_FastRoping") exitWith { [_unit, "ACE_FastRoping", 2] call EFUNC(common,doAnimation); }; +[_unit] spawn { + while {!(isNull attachedTo (_this select 0))} do { + playSound "ACE_Fastroping_Rope"; + sleep 1; + }; +}; + //End of fast rope if (isNull attachedTo _unit) exitWith { [_unit, "", 2] call EFUNC(common,doAnimation); _unit setVectorUp [0, 0, 1]; + playSound "ACE_Fastroping_Thud"; + [_pfhHandle] call CBA_fnc_removePerFrameHandler; }; From 80bada0365a00390381788e6620cfed3dde5e386 Mon Sep 17 00:00:00 2001 From: ColdEvul Date: Wed, 2 Mar 2016 22:27:29 +0100 Subject: [PATCH 031/215] Fixed carrying rotation. --- addons/dragging/CfgVehicles.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/dragging/CfgVehicles.hpp b/addons/dragging/CfgVehicles.hpp index 53b0900744..e66186e6c8 100644 --- a/addons/dragging/CfgVehicles.hpp +++ b/addons/dragging/CfgVehicles.hpp @@ -93,7 +93,7 @@ class CfgVehicles { }; GVAR(canCarry) = 1; GVAR(carryPosition[]) = {0,1,1}; - GVAR(carryDirection) = 90; + GVAR(carryDirection) = 270; GVAR(canDrag) = 1; GVAR(dragPosition[]) = {0,1.2,0}; @@ -105,7 +105,7 @@ class CfgVehicles { }; GVAR(canCarry) = 1; GVAR(carryPosition[]) = {0,1,1}; - GVAR(carryDirection) = 90; + GVAR(carryDirection) = 270; GVAR(canDrag) = 1; GVAR(dragPosition[]) = {0,1.2,0}; From 48e9e9c9e4407a5be0958e6611afb93310e05791 Mon Sep 17 00:00:00 2001 From: nomisum Date: Wed, 2 Mar 2016 22:36:42 +0100 Subject: [PATCH 032/215] added CBA-PFH, added QUOTE --- addons/fastroping/CfgSounds.hpp | 4 ++-- .../functions/fnc_fastRopeLocalPFH.sqf | 16 ++++++++++------ 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/addons/fastroping/CfgSounds.hpp b/addons/fastroping/CfgSounds.hpp index e6532146fe..1cdf993adc 100644 --- a/addons/fastroping/CfgSounds.hpp +++ b/addons/fastroping/CfgSounds.hpp @@ -1,12 +1,12 @@ class CfgSounds { class ACE_Fastroping_Rope { name = "ACE_Fastroping_Rope"; - sound[] = {PATHTOF(data\sounds\fastroping_rope.ogg), db0, 1.0}; + sound[] = {QUOTE(PATHTOF(data\sounds\fastroping_rope.ogg)), db0, 1.0}; titles[] = {}; }; class ACE_Fastroping_Thud { name = "ACE_Fastroping_Thud"; - sound[] = {PATHTOF(data\sounds\fastroping_thud.ogg), db0, 1.0}; + sound[] = {QUOTE(PATHTOF(data\sounds\fastroping_thud.ogg)), db0, 1.0}; titles[] = {}; }; }; \ No newline at end of file diff --git a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf index 7279d4838a..1b41404299 100644 --- a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf @@ -31,12 +31,16 @@ if (animationState _unit != "ACE_FastRoping") exitWith { [_unit, "ACE_FastRoping", 2] call EFUNC(common,doAnimation); }; -[_unit] spawn { - while {!(isNull attachedTo (_this select 0))} do { - playSound "ACE_Fastroping_Rope"; - sleep 1; - }; -}; +[{ + params ["_args", "_idPFH"]; + _args params ["_unit"]; + + if (isNull (attachedTo _unit)) exitWith { + [_idPFH] call CBA_fnc_removePerFrameHandler; + }; + + playSound "ACE_Fastroping_Rope"; +}, 1, [_unit]] call CBA_fnc_addPerFrameHandler; //End of fast rope if (isNull attachedTo _unit) exitWith { From 76468d326ba7fd9ac668eb551d71c0882bffd299 Mon Sep 17 00:00:00 2001 From: nomisum Date: Wed, 2 Mar 2016 22:49:25 +0100 Subject: [PATCH 033/215] fixed license file --- addons/fastroping/data/sounds/LICENSE.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/addons/fastroping/data/sounds/LICENSE.md b/addons/fastroping/data/sounds/LICENSE.md index d6312034ca..71835222cd 100644 --- a/addons/fastroping/data/sounds/LICENSE.md +++ b/addons/fastroping/data/sounds/LICENSE.md @@ -1,4 +1,6 @@ -Uses a sound from Tessa Elieff (Freesound.org) -according to Creative Commons Attribution License. +Source sounds are adapted and changed. -Also sounds from helenacm and Adam_N, both under CC 0. Thanks anyway. \ No newline at end of file +**Fastroping_Rope (fastroping_rope.ogg):** +"[Rub.aif](http://freesound.org/people/le_abbaye_Noirlac/sounds/129471/)" by [Tessa Elieff](http://freesound.org/people/le_abbaye_Noirlac/) is [CreativeCommons Attributions 3.0](http://creativecommons.org/licenses/by/3.0/) + +All other sounds from helenacm and Adam_N, both under Creative Commons 0 (no attribution required). \ No newline at end of file From 02616ebbb2ffc88626d499df68371c59ecd85166 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Thu, 3 Mar 2016 19:43:26 -0300 Subject: [PATCH 034/215] Throw a globalEvent when a tag is created. Close #3521. --- addons/tagging/functions/fnc_createTag.sqf | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/addons/tagging/functions/fnc_createTag.sqf b/addons/tagging/functions/fnc_createTag.sqf index fdb2cd08b0..a1a7a89002 100644 --- a/addons/tagging/functions/fnc_createTag.sqf +++ b/addons/tagging/functions/fnc_createTag.sqf @@ -7,6 +7,7 @@ * 1: Vector dir and up * 2: Colour of the tag (valid colours are black, red, green and blue) * 3: Object it should be tied too + * 4: Unit that created the tag * * Return Value: * None @@ -19,8 +20,8 @@ #include "script_component.hpp" -params ["_tagPosASL", "_vectorDirAndUp", "_color", "_object"]; -TRACE_4("createTag:", _tagPosASL, _vectorDirAndUp, _color, _object); +params ["_tagPosASL", "_vectorDirAndUp", "_color", "_object", "_unit"]; +TRACE_5("createTag:", _tagPosASL, _vectorDirAndUp, _color, _object, _unit); if !((toLower _color) in ["black", "red", "green", "blue"]) exitWith { ACE_LOGERROR_1("%1 is not a valid tag colour.", _color); @@ -31,6 +32,9 @@ _tag setObjectTextureGlobal [0, '\z\ace\addons\tagging\UI\tags\' + _color + '\' _tag setPosASL _tagPosASL; _tag setVectorDirAndUp _vectorDirAndUp; +// Throw a global event for mision makers +["tagCreated", [_tag, _color, _object, _unit]] call EFUNC(common,globalEvent); + if (isNull _object) exitWith {}; // If the tag is applied to an object, handle its destruction From 5450954fc2f3875beb3c53582677057f50d4f978 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Fri, 4 Mar 2016 09:16:42 -0300 Subject: [PATCH 035/215] Rename the event as "ace_tagging_tagCreated" --- addons/tagging/functions/fnc_createTag.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/tagging/functions/fnc_createTag.sqf b/addons/tagging/functions/fnc_createTag.sqf index a1a7a89002..812decbbb9 100644 --- a/addons/tagging/functions/fnc_createTag.sqf +++ b/addons/tagging/functions/fnc_createTag.sqf @@ -24,7 +24,7 @@ params ["_tagPosASL", "_vectorDirAndUp", "_color", "_object", "_unit"]; TRACE_5("createTag:", _tagPosASL, _vectorDirAndUp, _color, _object, _unit); if !((toLower _color) in ["black", "red", "green", "blue"]) exitWith { - ACE_LOGERROR_1("%1 is not a valid tag colour.", _color); + ACE_LOGERROR_1("%1 is not a valid tag color.", _color); }; private _tag = "UserTexture1m_F" createVehicle [0,0,0]; @@ -33,7 +33,7 @@ _tag setPosASL _tagPosASL; _tag setVectorDirAndUp _vectorDirAndUp; // Throw a global event for mision makers -["tagCreated", [_tag, _color, _object, _unit]] call EFUNC(common,globalEvent); +[QGVAR(tagCreated), [_tag, _color, _object, _unit]] call EFUNC(common,globalEvent); if (isNull _object) exitWith {}; From 62f598b2a6bca3049438c52154e3b9c612aac952 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 5 Mar 2016 13:11:20 -0300 Subject: [PATCH 036/215] Use the correct CBA function name, defining it in ACE as long as it doesn't exist already. --- addons/overheating/XEH_preInit.sqf | 12 +++++++----- .../functions/fnc_loadCoolestSpareBarrel.sqf | 2 +- .../fnc_sendSpareBarrelsTemperaturesHint.sqf | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/addons/overheating/XEH_preInit.sqf b/addons/overheating/XEH_preInit.sqf index 54bc392273..dcd9ddc092 100644 --- a/addons/overheating/XEH_preInit.sqf +++ b/addons/overheating/XEH_preInit.sqf @@ -4,14 +4,16 @@ ADDON = false; #include "XEH_PREP.hpp" -FakeCBA_fnc_getMagazineIds = { - params [["_unit", objNull, [objNull]], ["_magazine", "", [""]]]; +if (isNil "CBA_fnc_getMagazineIds") then { + CBA_fnc_getMagazineIds = { + params [["_unit", objNull, [objNull]], ["_magazine", "", [""]]]; - private _displayName = getText (configFile >> "CfgMagazines" >> _magazine >> "displayName"); + private _displayName = getText (configFile >> "CfgMagazines" >> _magazine >> "displayName"); - if (_displayName isEqualTo "") exitWith {[]}; + if (_displayName isEqualTo "") exitWith {[]}; - magazinesDetail _unit select {_x find _displayName == 0} apply {_x = _x splitString "[:]"; _x select (count _x - 1)}; + magazinesDetail _unit select {_x find _displayName == 0} apply {_x = _x splitString "[:]"; _x select (count _x - 1)}; + }; }; ADDON = true; diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf index dd58d58207..a3f9998497 100644 --- a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -21,7 +21,7 @@ params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; TRACE_4("loadCoolestSpareBarrel1",_unit,_weapon,_weaponTemp,_barrelMass); // Find all spare barrel the player has -private _allBarrels = [_unit, "ACE_SpareBarrel"] call FakeCBA_fnc_getMagazineIds; +private _allBarrels = [_unit, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIds; TRACE_1("_allBarrels",_allBarrels); if ((count _allBarrels) < 1) exitWith {}; diff --git a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf index 9f286832c6..eb3f514ac1 100644 --- a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf +++ b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf @@ -19,7 +19,7 @@ params ["_player","_unit"]; // Find all spare barrel the player has TRACE_2("sendSpareBarrelsTemperatureHunt",_player,_unit); -private _allBarrels = [_unit, "ACE_SpareBarrel"] call FakeCBA_fnc_getMagazineIds; +private _allBarrels = [_unit, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIds; TRACE_1("_allBarrels",_allBarrels); if ((count _allBarrels) < 1) exitWith {}; From ebfd76107e538888adede5814489f4933f81194e Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 5 Mar 2016 13:15:56 -0300 Subject: [PATCH 037/215] The function name was changed in CBA --- addons/overheating/XEH_preInit.sqf | 4 ++-- addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf | 2 +- .../functions/fnc_sendSpareBarrelsTemperaturesHint.sqf | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/overheating/XEH_preInit.sqf b/addons/overheating/XEH_preInit.sqf index dcd9ddc092..ccb7cba58a 100644 --- a/addons/overheating/XEH_preInit.sqf +++ b/addons/overheating/XEH_preInit.sqf @@ -4,8 +4,8 @@ ADDON = false; #include "XEH_PREP.hpp" -if (isNil "CBA_fnc_getMagazineIds") then { - CBA_fnc_getMagazineIds = { +if (isNil "CBA_fnc_getMagazineIndex") then { + CBA_fnc_getMagazineIndex = { params [["_unit", objNull, [objNull]], ["_magazine", "", [""]]]; private _displayName = getText (configFile >> "CfgMagazines" >> _magazine >> "displayName"); diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf index a3f9998497..b90271abd9 100644 --- a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -21,7 +21,7 @@ params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; TRACE_4("loadCoolestSpareBarrel1",_unit,_weapon,_weaponTemp,_barrelMass); // Find all spare barrel the player has -private _allBarrels = [_unit, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIds; +private _allBarrels = [_unit, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIndex; TRACE_1("_allBarrels",_allBarrels); if ((count _allBarrels) < 1) exitWith {}; diff --git a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf index eb3f514ac1..2ff248016d 100644 --- a/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf +++ b/addons/overheating/functions/fnc_sendSpareBarrelsTemperaturesHint.sqf @@ -19,7 +19,7 @@ params ["_player","_unit"]; // Find all spare barrel the player has TRACE_2("sendSpareBarrelsTemperatureHunt",_player,_unit); -private _allBarrels = [_unit, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIds; +private _allBarrels = [_unit, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIndex; TRACE_1("_allBarrels",_allBarrels); if ((count _allBarrels) < 1) exitWith {}; From 6cf9787fd1d11316d48768d58b2afad840976d59 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 5 Mar 2016 13:18:41 -0300 Subject: [PATCH 038/215] Fix travis warning --- addons/overheating/XEH_preInit.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/overheating/XEH_preInit.sqf b/addons/overheating/XEH_preInit.sqf index ccb7cba58a..cdd1fa78dd 100644 --- a/addons/overheating/XEH_preInit.sqf +++ b/addons/overheating/XEH_preInit.sqf @@ -12,7 +12,7 @@ if (isNil "CBA_fnc_getMagazineIndex") then { if (_displayName isEqualTo "") exitWith {[]}; - magazinesDetail _unit select {_x find _displayName == 0} apply {_x = _x splitString "[:]"; _x select (count _x - 1)}; + (magazinesDetail _unit select {_x find _displayName == 0}) apply {_x = _x splitString "[:]"; _x select (count _x - 1)}; }; }; From e15d534fd106867baf76874bdf6f524f84d8c3b9 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 5 Mar 2016 21:11:53 -0300 Subject: [PATCH 039/215] Rename event, removing prefix. Back to square one. --- addons/tagging/functions/fnc_createTag.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/tagging/functions/fnc_createTag.sqf b/addons/tagging/functions/fnc_createTag.sqf index 812decbbb9..fb966b5b64 100644 --- a/addons/tagging/functions/fnc_createTag.sqf +++ b/addons/tagging/functions/fnc_createTag.sqf @@ -33,7 +33,7 @@ _tag setPosASL _tagPosASL; _tag setVectorDirAndUp _vectorDirAndUp; // Throw a global event for mision makers -[QGVAR(tagCreated), [_tag, _color, _object, _unit]] call EFUNC(common,globalEvent); +["tagCreated", [_tag, _color, _object, _unit]] call EFUNC(common,globalEvent); if (isNull _object) exitWith {}; From ae8cbb4834ac98d6874140d367c930eea5287386 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 5 Mar 2016 23:33:30 -0300 Subject: [PATCH 040/215] Add "check temperature" and "swap barrel" actions for AARs --- addons/overheating/CfgVehicles.hpp | 30 +++++++++++++---- addons/overheating/XEH_PREP.hpp | 1 + addons/overheating/XEH_postInit.sqf | 8 ++--- .../functions/fnc_checkTemperature.sqf | 24 +++++++------- .../functions/fnc_loadCoolestSpareBarrel.sqf | 21 ++++++------ .../overheating/functions/fnc_swapBarrel.sqf | 24 +++++++++----- .../functions/fnc_swapBarrelAssistant.sqf | 33 +++++++++++++++++++ .../functions/fnc_swapBarrelCallback.sqf | 25 +++++++------- 8 files changed, 115 insertions(+), 51 deletions(-) create mode 100644 addons/overheating/functions/fnc_swapBarrelAssistant.sqf diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index 61052553a4..528f77375c 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -4,7 +4,7 @@ class CfgVehicles { class CAManBase: Man { class ACE_SelfActions { class ACE_Equipment { - class ACE_UnJam { + class GVAR(UnJam) { displayName = CSTRING(UnjamWeapon); condition = QUOTE( [_player] call FUNC(canUnjam) ); exceptions[] = {"isNotInside", "isNotSitting"}; @@ -13,7 +13,7 @@ class CfgVehicles { priority = 4; icon = QUOTE(PATHTOF(UI\unjam_ca.paa)); }; - class ACE_SwapBarrel { + class GVAR(SwapBarrel) { displayName = CSTRING(SwapBarrel); condition = QUOTE( 'ACE_SpareBarrel' in magazines _player && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _player >> 'ACE_Overheating_allowSwapBarrel') == 1} ); statement = QUOTE( [ARR_2(_player, currentWeapon _player)] call FUNC(swapBarrel); ); @@ -21,16 +21,16 @@ class CfgVehicles { priority = 3; icon = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); }; - class ACE_CheckTemperature { + class GVAR(CheckTemperature) { displayName = CSTRING(CheckTemperatureShort); - condition = "switch (currentWeapon _player) do {case (''): {false}; case (primaryWeapon _player); case (secondaryWeapon _player); case (handgunWeapon _player): {true}; default {false}}"; + condition = "switch (currentWeapon _player) do {case (''): {false}; case (primaryWeapon _player); case (handgunWeapon _player): {true}; default {false}}"; exceptions[] = {"isNotInside", "isNotSitting"}; - statement = QUOTE( [ARR_2(_player, currentWeapon _player)] call FUNC(CheckTemperature); ); + statement = QUOTE( [ARR_3(_player, _player, currentWeapon _player)] call FUNC(checkTemperature); ); showDisabled = 0; priority = 2.9; icon = QUOTE(PATHTOF(UI\temp_ca.paa)); }; - class ACE_CheckTemperatureSpareBarrels { + class GVAR(CheckTemperatureSpareBarrels) { displayName = CSTRING(CheckTemperatureSpareBarrelsShort); condition = QUOTE( 'ACE_SpareBarrel' in magazines _player); exceptions[] = {"isNotInside", "isNotSitting"}; @@ -41,6 +41,24 @@ class CfgVehicles { }; }; }; + + class ACE_Actions { + class ACE_Weapon { + class GVAR(SwapBarrel) { + displayName = CSTRING(SwapBarrel); + condition = QUOTE( 'ACE_SpareBarrel' in magazines _player && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _target >> 'ACE_Overheating_allowSwapBarrel') == 1} ); + statement = QUOTE([ARR_3(_player, _target, currentWeapon _target)] call FUNC(swapBarrelAssistant);); + icon = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); + }; + class GVAR(CheckTemperature) { + displayName = CSTRING(CheckTemperatureShort); + condition = "switch (currentWeapon _target) do {case (''): {false}; case (primaryWeapon _target); case (handgunWeapon _target): {true}; default {false}}"; + exceptions[] = {"isNotInside", "isNotSitting"}; + statement = QUOTE( [ARR_3(_player, _target, currentWeapon _target)] call FUNC(checkTemperature); ); + icon = QUOTE(PATHTOF(UI\temp_ca.paa)); + }; + }; + }; }; class ReammoBox_F; diff --git a/addons/overheating/XEH_PREP.hpp b/addons/overheating/XEH_PREP.hpp index cc1948e6bd..44fd931ca0 100644 --- a/addons/overheating/XEH_PREP.hpp +++ b/addons/overheating/XEH_PREP.hpp @@ -13,6 +13,7 @@ PREP(loadCoolestSpareBarrel); PREP(overheat); PREP(sendSpareBarrelsTemperaturesHint); PREP(swapBarrel); +PREP(swapBarrelAssistant); PREP(swapBarrelCallback); PREP(updateSpareBarrelsTemperaturesThread); PREP(updateTemperature); diff --git a/addons/overheating/XEH_postInit.sqf b/addons/overheating/XEH_postInit.sqf index 831c2c2348..96d518ac9f 100644 --- a/addons/overheating/XEH_postInit.sqf +++ b/addons/overheating/XEH_postInit.sqf @@ -56,7 +56,7 @@ GVAR(cacheSilencerData) = call CBA_fnc_createNamespace; }; }] call EFUNC(common,addEventHandler); -// Install event handlers to display temp when a barrel was swapped -["barrelSwapped", { - _this call FUNC(displayTemperature); -}] call EFUNC(common,addEventHandler); +// Install event handler to display temp when a barrel was swapped +["showWeaponTemperature", DFUNC(displayTemperature)] call EFUNC(common,addEventHandler); +// Install event handler to initiate an assisted barrel swap +["initiateSwapBarrelAssisted", DFUNC(swapBarrel)] call EFUNC(common,addEventHandler); diff --git a/addons/overheating/functions/fnc_checkTemperature.sqf b/addons/overheating/functions/fnc_checkTemperature.sqf index f720665620..fd2ac5f56c 100644 --- a/addons/overheating/functions/fnc_checkTemperature.sqf +++ b/addons/overheating/functions/fnc_checkTemperature.sqf @@ -3,8 +3,9 @@ * Make the player check the temperature of his weapon * * Arguments: - * 0: Player - * 1: Weapon + * 0: Unit checking + * 1: Unit that has the weapon + * 2: Weapon * * Return Value: * None @@ -16,17 +17,18 @@ */ #include "script_component.hpp" -params ["_player", "_weapon"]; -TRACE_2("params",_player,_weapon); +params ["_assistant", "_gunner", "_weapon"]; +TRACE_3("params",_assistant,_gunner,_weapon); // Play animation and report temperature -private _action = getText (configFile >> "CfgWeapons" >> _weapon >> "ACE_checkTemperatureAction"); - -if (_action == "") then { - _action = "Gear"; +private _action = "PutDown"; +if (_assistant isEqualTo _gunner) then { + _action = getText (configFile >> "CfgWeapons" >> _weapon >> "ACE_checkTemperatureAction"); + if (_action == "") then { + _action = "Gear"; + }; }; - -_player playActionNow _action; +_assistant playActionNow _action; // Waits a sec before displaying the temperature -[FUNC(displayTemperature), [_player, _weapon], 1.0] call EFUNC(common,waitAndExecute); +[FUNC(displayTemperature), [_gunner, _weapon], 1.0] call EFUNC(common,waitAndExecute); diff --git a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf index b90271abd9..08cb85083c 100644 --- a/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf +++ b/addons/overheating/functions/fnc_loadCoolestSpareBarrel.sqf @@ -4,10 +4,11 @@ * coolest on the unit weapon. Runs on the server. * * Argument: - * 0: Unit - * 1: Weapon - * 2: Weapon temp before switching - * 3: Mass of the removed barrel + * 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: * None @@ -17,11 +18,11 @@ */ #include "script_component.hpp" -params ["_unit", "_weapon", "_weaponTemp", "_barrelMass"]; -TRACE_4("loadCoolestSpareBarrel1",_unit,_weapon,_weaponTemp,_barrelMass); +params ["_assistant", "_gunner", "_weapon", "_weaponTemp", "_barrelMass"]; +TRACE_5("loadCoolestSpareBarrel1",_assistant,_gunner,_weapon,_weaponTemp,_barrelMass); // Find all spare barrel the player has -private _allBarrels = [_unit, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIndex; +private _allBarrels = [_assistant, "ACE_SpareBarrel"] call CBA_fnc_getMagazineIndex; TRACE_1("_allBarrels",_allBarrels); if ((count _allBarrels) < 1) exitWith {}; @@ -43,10 +44,10 @@ TRACE_3("loadCoolestSpareBarrel5",_coolestTemp,_coolestMag,_weaponTemp); // The new weapon temperature is similar to the coolest barrel // Publish the new temperature value -_unit setVariable [format [QGVAR(%1_temp), _weapon], _coolestTemp, true]; +_gunner setVariable [format [QGVAR(%1_temp), _weapon], _coolestTemp, true]; // Heat up the coolest barrel to the former weapon temperature [GVAR(storedSpareBarrels), _coolestMag, [_weaponTemp, ACE_Time, _barrelMass]] call CBA_fnc_hashSet; -// Send an event so the local machine can show the hint -["barrelSwapped", _unit, [_unit, _weapon]] call EFUNC(common,objectEvent); +// Send an event so the machines of the assistant and gunner can show the hint +["showWeaponTemperature", [_assistant, _gunner], [_gunner, _weapon]] call EFUNC(common,targetEvent); diff --git a/addons/overheating/functions/fnc_swapBarrel.sqf b/addons/overheating/functions/fnc_swapBarrel.sqf index bbdab91705..a63ef5a36a 100644 --- a/addons/overheating/functions/fnc_swapBarrel.sqf +++ b/addons/overheating/functions/fnc_swapBarrel.sqf @@ -3,29 +3,35 @@ * Make a unit start swapping it's barrel * * Argument: - * 0: Unit - * 1: Weapon + * 0: Unit initiating the action + * 1: Unit that has the weapon + * 2: Weapon * * Return value: * None * * Example: - * [player, currentWeapon player] call ace_overheating_fnc_swapBarrel + * [cursorTarget, player, currentWeapon player] call ace_overheating_fnc_swapBarrel * * Public: No */ #include "script_component.hpp" -params ["_player", "_weapon"]; -TRACE_2("params",_player,_weapon); +params ["_assistant", "_gunner", "_weapon"]; +TRACE_3("params",_assistant,_gunner,_weapon); // Make the standing player kneel down -if (stance _player != "PRONE") then { - [_player, "amovpknlmstpsraswrfldnon", 1] call EFUNC(common,doAnimation); +if (stance _gunner != "PRONE") then { + [_gunner, "amovpknlmstpsraswrfldnon", 1] call EFUNC(common,doAnimation); }; // Barrel dismount gesture -_player playActionNow QGVAR(GestureDismountMuzzle); +_gunner playActionNow QGVAR(GestureDismountMuzzle); playSound "ACE_BarrelSwap"; -[5, [_player, _weapon], {(_this select 0) call FUNC(swapBarrelCallback)}, {}, (localize LSTRING(SwappingBarrel))] call EFUNC(common,progressBar); +private _duration = 3.0; +if (_assistant isEqualTo _gunner) then { + _duration = 5.0; +}; + +[_duration, [_assistant,_gunner,_weapon], {(_this select 0) call FUNC(swapBarrelCallback)}, {}, (localize LSTRING(SwappingBarrel))] call EFUNC(common,progressBar); diff --git a/addons/overheating/functions/fnc_swapBarrelAssistant.sqf b/addons/overheating/functions/fnc_swapBarrelAssistant.sqf new file mode 100644 index 0000000000..5e3c31fc5e --- /dev/null +++ b/addons/overheating/functions/fnc_swapBarrelAssistant.sqf @@ -0,0 +1,33 @@ +/* + * Author: esteldunedain, Commy2 + * Make a unit start swapping the barrel of another unit + * + * Argument: + * 0: Unit initiating the action + * 1: Unit that has the weapon + * 2: Weapon + * + * Return value: + * None + * + * Example: + * [player, cursorTarget, currentWeapon cursorTarget] call ace_overheating_fnc_swapBarrelAssistant + * + * Public: No + */ +#include "script_component.hpp" + +params ["_assistant", "_gunner", "_weapon"]; +TRACE_3("params",_assistant,_gunner,_weapon); + +// Make the standing player kneel down +if (stance _assistant != "PRONE") then { + [_assistant, "amovpknlmstpsraswrfldnon", 1] call EFUNC(common,doAnimation); +}; + +// Barrel dismount gesture +playSound "ACE_BarrelSwap"; + +[3, [_assistant, _gunner, _weapon], {}, {}, (localize LSTRING(SwappingBarrel))] call EFUNC(common,progressBar); + +["initiateSwapBarrelAssisted", _gunner, [_assistant, _gunner, _weapon]] call EFUNC(common,objectEvent); diff --git a/addons/overheating/functions/fnc_swapBarrelCallback.sqf b/addons/overheating/functions/fnc_swapBarrelCallback.sqf index 62a3b13ef6..339b6627b1 100644 --- a/addons/overheating/functions/fnc_swapBarrelCallback.sqf +++ b/addons/overheating/functions/fnc_swapBarrelCallback.sqf @@ -1,10 +1,11 @@ /* - * Author: Commy2 + * Author: Commy2, esteldunedain * Swap barrel callback * * Argument: - * 0: Unit - * 1: Weapon + * 0: Unit initiating the action + * 1: Unit that has the weapon + * 2: Weapon * * Return value: * None @@ -17,21 +18,23 @@ #define DEBUG_MODE_FULL #include "script_component.hpp" -params ["_player", "_weapon"]; -TRACE_2("params",_player,_weapon); +params ["_assistant", "_gunner", "_weapon"]; +TRACE_3("params",_assistant,_gunner,_weapon); -// Barrel mount gesture -_player playAction QGVAR(GestureMountMuzzle); -playSound "ACE_BarrelSwap"; +if (_assistant isEqualTo _gunner) then { + // Barrel mount gesture + _gunner playAction QGVAR(GestureMountMuzzle); + playSound "ACE_BarrelSwap"; +}; -private _temp = _player getVariable [format [QGVAR(%1_temp), _weapon], 0]; +private _temp = _gunner getVariable [format [QGVAR(%1_temp), _weapon], 0]; private _barrelMass = 0.50 * (getNumber (configFile >> "CfgWeapons" >> _weapon >> "WeaponSlotsInfo" >> "mass") / 22.0) max 1.0; // Instruct the server to load the coolest spare barrel into the weapon and // store the removed barrel with the former weapon temperature. The server // also updates the current weapon temperature to match that of the new // loaded barrel. -["spareBarrelsLoadCoolest", [_player, _weapon, _temp, _barrelMass]] call EFUNC(common,serverEvent); +["spareBarrelsLoadCoolest", [_assistant, _gunner, _weapon, _temp, _barrelMass]] call EFUNC(common,serverEvent); // Store the update time -_player setVariable [format [QGVAR(%1_time), _weapon], ACE_time]; +_gunner setVariable [format [QGVAR(%1_time), _weapon], ACE_time]; From a064c0c98db5b5e98a82ac0478bbd5d929c916fa Mon Sep 17 00:00:00 2001 From: jonpas Date: Sun, 6 Mar 2016 12:50:16 +0100 Subject: [PATCH 041/215] Modernize code --- addons/ui/CfgEventHandlers.hpp | 6 ++++++ addons/ui/XEH_PREP.hpp | 4 ++++ addons/ui/XEH_preInit.sqf | 5 +---- addons/ui/XEH_preStart.sqf | 3 +++ .../ui/functions/fnc_setAdvancedElement.sqf | 4 ++-- addons/ui/functions/fnc_setElements.sqf | 21 +++---------------- 6 files changed, 19 insertions(+), 24 deletions(-) create mode 100644 addons/ui/XEH_PREP.hpp create mode 100644 addons/ui/XEH_preStart.sqf diff --git a/addons/ui/CfgEventHandlers.hpp b/addons/ui/CfgEventHandlers.hpp index 423993f757..36c0fca8a3 100644 --- a/addons/ui/CfgEventHandlers.hpp +++ b/addons/ui/CfgEventHandlers.hpp @@ -1,3 +1,9 @@ +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/addons/ui/XEH_PREP.hpp b/addons/ui/XEH_PREP.hpp new file mode 100644 index 0000000000..222afadf25 --- /dev/null +++ b/addons/ui/XEH_PREP.hpp @@ -0,0 +1,4 @@ +PREP(moduleInit); +PREP(moduleInitAdvanced); +PREP(setAdvancedElement); +PREP(setElements); diff --git a/addons/ui/XEH_preInit.sqf b/addons/ui/XEH_preInit.sqf index 8a86e3ec32..a7feade1c3 100644 --- a/addons/ui/XEH_preInit.sqf +++ b/addons/ui/XEH_preInit.sqf @@ -2,9 +2,6 @@ ADDON = false; -PREP(moduleInit); -PREP(moduleInitAdvanced); -PREP(setAdvancedElement); -PREP(setElements); +#include "XEH_PREP.hpp" ADDON = true; diff --git a/addons/ui/XEH_preStart.sqf b/addons/ui/XEH_preStart.sqf new file mode 100644 index 0000000000..022888575e --- /dev/null +++ b/addons/ui/XEH_preStart.sqf @@ -0,0 +1,3 @@ +#include "script_component.hpp" + +#include "XEH_PREP.hpp" diff --git a/addons/ui/functions/fnc_setAdvancedElement.sqf b/addons/ui/functions/fnc_setAdvancedElement.sqf index c87a79ffae..e5fc66d565 100644 --- a/addons/ui/functions/fnc_setAdvancedElement.sqf +++ b/addons/ui/functions/fnc_setAdvancedElement.sqf @@ -11,7 +11,7 @@ * None * * Example: - * [show, 303, [188] ] call ace_ui_fnc_setAdvancedElement + * [show, 303, [188]] call ace_ui_fnc_setAdvancedElement * * Public: No */ @@ -29,7 +29,7 @@ _show = [1, 0] select _show; // Disable/Enable elements { - local _idc = _x; + private _idc = _x; // Loop through IGUI displays as they can be present several times for some reason { diff --git a/addons/ui/functions/fnc_setElements.sqf b/addons/ui/functions/fnc_setElements.sqf index 3952d8e337..1a9ca73399 100644 --- a/addons/ui/functions/fnc_setElements.sqf +++ b/addons/ui/functions/fnc_setElements.sqf @@ -9,17 +9,15 @@ * None * * Example: - * call ace_ui_fnc_setBasicElements + * [] call ace_ui_fnc_setElements * * Public: No */ #include "script_component.hpp" -//@todo - change to EFUNC(common,showHud) setter +private _shownHUD = shownHUD; // [hud, info, radar, compass, direction, menu, group, cursors] -local _shownHUD = shownHUD; // [hud, info, radar, compass, direction, menu, group, cursors] - -showHUD [ +["ui", [ _shownHUD select 0, GVAR(soldierVehicleWeaponInfo), GVAR(vehicleRadar), @@ -28,17 +26,4 @@ showHUD [ GVAR(commandMenu), GVAR(groupBar), _shownHUD select 7 -]; - -/* -["UIselective", [ - _shownHUD select 0, - _shownHUD select 1, - _shownHUD select 2, - _shownHUD select 3, - _shownHUD select 4, - GVAR(commandMenu), - _shownHUD select 6, - _shownHUD select 7 ]] call EFUNC(common,showHud); -*/ From 9b46e8856e800359503174dff788bdf7c91fad47 Mon Sep 17 00:00:00 2001 From: jonpas Date: Sun, 6 Mar 2016 15:41:17 +0100 Subject: [PATCH 042/215] Merge modules, Add base allow client settings toggle, Add requires descriptions --- addons/reload/RscInGameUI.hpp | 24 -- addons/reload/config.cpp | 2 - addons/ui/ACE_Settings.hpp | 224 ++++++++++-------- addons/ui/CfgVehicles.hpp | 62 ++--- addons/ui/XEH_PREP.hpp | 1 - addons/ui/XEH_clientInit.sqf | 22 +- addons/ui/functions/fnc_moduleInit.sqf | 27 ++- .../ui/functions/fnc_moduleInitAdvanced.sqf | 42 ---- .../ui/functions/fnc_setAdvancedElement.sqf | 18 +- addons/ui/functions/fnc_setElements.sqf | 10 +- addons/ui/script_component.hpp | 8 +- addons/ui/stringtable.xml | 39 ++- 12 files changed, 240 insertions(+), 239 deletions(-) delete mode 100644 addons/reload/RscInGameUI.hpp delete mode 100644 addons/ui/functions/fnc_moduleInitAdvanced.sqf diff --git a/addons/reload/RscInGameUI.hpp b/addons/reload/RscInGameUI.hpp deleted file mode 100644 index 7310690f16..0000000000 --- a/addons/reload/RscInGameUI.hpp +++ /dev/null @@ -1,24 +0,0 @@ - -class RscControlsGroup; -class RscText; - -class RscInGameUI { - class RscUnitInfo { - // Soldiers - class WeaponInfoControlsGroupLeft: RscControlsGroup { - class controls { - class CA_AmmoCount: RscText { - sizeEx = 0; - }; - }; - }; - // Vehicles - /*class WeaponInfoControlsGroupRight: RscControlsGroup { - class controls { - class CA_AmmoCount: RscText { - sizeEx = 0; - }; - }; - };*/ - }; -}; diff --git a/addons/reload/config.cpp b/addons/reload/config.cpp index 6ded1cd687..86ba809a93 100644 --- a/addons/reload/config.cpp +++ b/addons/reload/config.cpp @@ -20,6 +20,4 @@ class CfgPatches { #include "CfgActions.hpp" -#include "RscInGameUI.hpp" - #include "ACE_Settings.hpp" diff --git a/addons/ui/ACE_Settings.hpp b/addons/ui/ACE_Settings.hpp index 53e1496b38..3e5c53d328 100644 --- a/addons/ui/ACE_Settings.hpp +++ b/addons/ui/ACE_Settings.hpp @@ -1,182 +1,208 @@ class ACE_Settings { + class GVAR(allowSelectiveUI) { + category = CSTRING(Category); + displayName = CSTRING(AllowSelectiveUI); + description = CSTRING(AllowSelectiveUI_Description); + typeName = "BOOL"; + value = 1; + }; + // BASIC class GVAR(soldierVehicleWeaponInfo) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(SoldierVehicleWeaponInfo); category = CSTRING(Category); + displayName = CSTRING(SoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleRadar) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleRadar); category = CSTRING(Category); + displayName = CSTRING(VehicleRadar); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleCompass) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleCompass); category = CSTRING(Category); + displayName = CSTRING(VehicleCompass); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(commandMenu) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(CommandMenu); category = CSTRING(Category); + displayName = CSTRING(CommandMenu); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(groupBar) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(GroupBar); category = CSTRING(Category); + displayName = CSTRING(GroupBar); + typeName = "BOOL"; + value = 0; + isClientSettable = 1; }; // ADVANCED // Upper Weapon Info class GVAR(weaponName) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(WeaponName); category = CSTRING(Category); + displayName = CSTRING(WeaponName); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(weaponNameBackground) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(WeaponNameBackground); category = CSTRING(Category); + displayName = CSTRING(WeaponNameBackground); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(firingMode) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(FiringMode); category = CSTRING(Category); + displayName = CSTRING(FiringMode); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; // Lower Weapon Info class GVAR(ammoType) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(AmmoType); category = CSTRING(Category); + displayName = CSTRING(AmmoType); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(ammoCount) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(AmmoCount); - description = CSTRING(AmmoCountDesc); category = CSTRING(Category); + displayName = CSTRING(AmmoCount); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 0; + isClientSettable = 1; }; class GVAR(magCount) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; + category = CSTRING(Category); displayName = CSTRING(MagCount); - category = CSTRING(Category); - }; - class GVAR(grenadeFlareType) { - value = 1; + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(GrenadeFlareType); - category = CSTRING(Category); - }; - class GVAR(grenadeFlareCount) { value = 1; - typeName = "BOOL"; isClientSettable = 1; - displayName = CSTRING(GrenadeFlareCount); + }; + class GVAR(throwableName) { category = CSTRING(Category); + displayName = CSTRING(throwableName); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; + }; + class GVAR(throwableCount) { + category = CSTRING(Category); + displayName = CSTRING(throwableCount); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(zeroing) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(Zeroing); category = CSTRING(Category); + displayName = CSTRING(Zeroing); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(weaponLowerInfoBackground) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(WeaponLowerInfoBackground); //todo category = CSTRING(Category); + displayName = CSTRING(WeaponLowerInfoBackground); //todo + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; // Stance class GVAR(stance) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(Stance); category = CSTRING(Category); + displayName = CSTRING(Stance); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; // Vehicle class GVAR(vehicleName) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleName); category = CSTRING(Category); + displayName = CSTRING(VehicleName); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleNameBackground) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleNameBackground); category = CSTRING(Category); + displayName = CSTRING(VehicleNameBackground); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleFuelBar) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleFuelBar); category = CSTRING(Category); + displayName = CSTRING(VehicleFuelBar); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleSpeed) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleSpeed); category = CSTRING(Category); + displayName = CSTRING(VehicleSpeed); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleAltitude) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleAltitude); category = CSTRING(Category); + displayName = CSTRING(VehicleAltitude); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleDamage) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleDamage); category = CSTRING(Category); + displayName = CSTRING(VehicleDamage); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleInfoBackground) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleInfoBackground); category = CSTRING(Category); + displayName = CSTRING(VehicleInfoBackground); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; class GVAR(vehicleGunnerWeapon) { - value = 1; - typeName = "BOOL"; - isClientSettable = 1; - displayName = CSTRING(VehicleGunnerWeapon); category = CSTRING(Category); + displayName = CSTRING(VehicleGunnerWeapon); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; }; }; diff --git a/addons/ui/CfgVehicles.hpp b/addons/ui/CfgVehicles.hpp index 69f28f955e..1441d97217 100644 --- a/addons/ui/CfgVehicles.hpp +++ b/addons/ui/CfgVehicles.hpp @@ -1,8 +1,6 @@ class CfgVehicles { class ACE_Module; - - // Basic - class ACE_ModuleUI: ACE_Module { + class GVAR(Module): ACE_Module { author = ECSTRING(common,ACETeam); category = "ACE"; displayName = CSTRING(ModuleName); @@ -11,6 +9,13 @@ class CfgVehicles { isGlobal = 1; //icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); class Arguments { + // BASIC + class allowSelectiveUI { + displayName = CSTRING(AllowSelectiveUI); + description = CSTRING(AllowSelectiveUI_Description); + typeName = "BOOL"; + defaultValue = 1; + }; class soldierVehicleWeaponInfo { displayName = CSTRING(SoldierVehicleWeaponInfo); typeName = "BOOL"; @@ -34,37 +39,26 @@ class CfgVehicles { class groupBar { displayName = CSTRING(GroupBar); typeName = "BOOL"; - defaultValue = 1; + defaultValue = 0; }; - }; - class ModuleDescription { - description = CSTRING(ModuleDescription); - }; - }; - // Advanced - class ACE_ModuleUI_Advanced: ACE_Module { - author = ECSTRING(common,ACETeam); - category = "ACE"; - displayName = CSTRING(ModuleName_Advanced); - function = QFUNC(moduleInitAdvanced); - scope = 2; - isGlobal = 1; - //icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); - class Arguments { + // ADVANCED // Upper Weapon Info class weaponName { displayName = CSTRING(WeaponName); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class weaponNameBackground { displayName = CSTRING(WeaponNameBackground); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class firingMode { displayName = CSTRING(FiringMode); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; @@ -72,37 +66,43 @@ class CfgVehicles { // Lower Weapon Info class ammoType { displayName = CSTRING(AmmoType); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class ammoCount { displayName = CSTRING(AmmoCount); - description = CSTRING(AmmoCountDesc); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; - defaultValue = 1; + defaultValue = 0; }; class magCount { displayName = CSTRING(MagCount); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; - class grenadeFlareType { - displayName = CSTRING(GrenadeFlareType); + class throwableName { + displayName = CSTRING(throwableName); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; - class grenadeFlareCount { - displayName = CSTRING(GrenadeFlareCount); + class throwableCount { + displayName = CSTRING(throwableCount); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class zeroing { displayName = CSTRING(Zeroing); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class weaponLowerInfoBackground { displayName = CSTRING(WeaponLowerInfoBackground); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; @@ -110,55 +110,63 @@ class CfgVehicles { // Stance class stance { displayName = CSTRING(Stance); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; - // Vehicle class vehicleName { displayName = CSTRING(VehicleName); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class vehicleNameBackground { displayName = CSTRING(VehicleNameBackground); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class vehicleFuelBar { displayName = CSTRING(VehicleFuelBar); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class vehicleSpeed { displayName = CSTRING(VehicleSpeed); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class vehicleAltitude { displayName = CSTRING(VehicleAltitude); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class vehicleDamage { displayName = CSTRING(VehicleDamage); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class vehicleInfoBackground { displayName = CSTRING(VehicleInfoBackground); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; class vehicleGunnerWeapon { displayName = CSTRING(VehicleGunnerWeapon); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); typeName = "BOOL"; defaultValue = 1; }; }; class ModuleDescription { - description = CSTRING(ModuleDescription_Advanced); + description = CSTRING(ModuleDescription); }; }; }; diff --git a/addons/ui/XEH_PREP.hpp b/addons/ui/XEH_PREP.hpp index 222afadf25..6660470ba8 100644 --- a/addons/ui/XEH_PREP.hpp +++ b/addons/ui/XEH_PREP.hpp @@ -1,4 +1,3 @@ PREP(moduleInit); -PREP(moduleInitAdvanced); PREP(setAdvancedElement); PREP(setElements); diff --git a/addons/ui/XEH_clientInit.sqf b/addons/ui/XEH_clientInit.sqf index d778fb2746..23fa19af11 100644 --- a/addons/ui/XEH_clientInit.sqf +++ b/addons/ui/XEH_clientInit.sqf @@ -5,19 +5,24 @@ if (!hasInterface) exitWith {}; ["SettingsInitialized", { - // Selective UI Basic - call FUNC(setElements); - + // Initial settings + [true] call FUNC(setElements); // On load and entering/exiting a vehicle ["infoDisplayChanged", { // Selective UI Advanced - { - _x call FUNC(setAdvancedElement); - } forEach ELEMENTS_ADVANCED; + // Defaults must be set in this EH to make sure controls are activated and advanced settings can be modified + if (!GVAR(allowSelectiveUI)) then { + { + [_x, true] call FUNC(setAdvancedElement); + } forEach ELEMENTS_ADVANCED; + } else { + { + [_x] call FUNC(setAdvancedElement); + } forEach ELEMENTS_ADVANCED; + }; }] call EFUNC(common,addEventHandler); - ["SettingChanged", { params ["_name"]; @@ -31,11 +36,10 @@ if (!hasInterface) exitWith {}; _x params ["_element"]; if (_name == _element) then { - _x call FUNC(setAdvancedElement); + [_x] call FUNC(setAdvancedElement); TRACE_2("Setting Changed",_name,_element); }; } forEach ELEMENTS_ADVANCED; - }] call EFUNC(common,addEventHandler); }] call EFUNC(common,addEventHandler); diff --git a/addons/ui/functions/fnc_moduleInit.sqf b/addons/ui/functions/fnc_moduleInit.sqf index f4a57831c8..fe0f07709a 100644 --- a/addons/ui/functions/fnc_moduleInit.sqf +++ b/addons/ui/functions/fnc_moduleInit.sqf @@ -20,13 +20,36 @@ if (!_activated) exitWith {}; // Exit if HUD visibility is hardcoded in mission config and showHUD command is overriden if (isArray (missionConfigFile >> "showHUD")) exitWith { - ACE_LOGINFO("User Interface (Basic) Module Failed to Initialize - showHUD overriden in mission config!"); + ACE_LOGINFO("User Interface Module Failed to Initialize - showHUD overriden in mission config!"); }; +// Basic +[_logic, QGVAR(allowSelectiveUI), "allowSelectiveUI"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(soldierVehicleWeaponInfo), "soldierVehicleWeaponInfo"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(vehicleRadar), "vehicleRadar"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(vehicleCompass), "vehicleCompass"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(commandMenu), "commandMenu"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(groupBar), "groupBar"] call EFUNC(common,readSettingFromModule); -ACE_LOGINFO("User Interface (Basic) Module Initialized."); +// Advanced +[_logic, QGVAR(weaponName), "weaponName"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(weaponNameBackground), "weaponNameBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(firingMode), "firingMode"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(ammoType), "ammoType"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(ammoCount), "ammoCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(magCount), "magCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(throwableName), "throwableName"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(throwableCount), "throwableCount"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(zeroing), "zeroing"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(weaponLowerInfoBackground), "weaponLowerInfoBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(stance), "stance"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleName), "vehicleName"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleNameBackground), "vehicleNameBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleFuelBar), "vehicleFuelBar"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleSpeed), "vehicleSpeed"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleAltitude), "vehicleAltitude"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleDamage), "vehicleDamage"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleInfoBackground), "vehicleInfoBackground"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(vehicleGunnerWeapon), "vehicleGunnerWeapon"] call EFUNC(common,readSettingFromModule); + +ACE_LOGINFO_1("User Interface Module Initialized. Allow client modifications: %1",GVAR(allowSelectiveUI)); diff --git a/addons/ui/functions/fnc_moduleInitAdvanced.sqf b/addons/ui/functions/fnc_moduleInitAdvanced.sqf deleted file mode 100644 index ab5666af69..0000000000 --- a/addons/ui/functions/fnc_moduleInitAdvanced.sqf +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Author: Jonpas - * Initializes the UI module. - * - * Arguments: - * 0: Module Logic - * 1: Units - * 2: Activated - * - * Return Value: - * None - */ -#include "script_component.hpp" - -if (!isServer) exitWith {}; - -params ["_logic", "_units", "_activated"]; - -if (!_activated) exitWith {}; - -[_logic, QGVAR(weaponName), "weaponName"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(weaponNameBackground), "weaponNameBackground"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(firingMode), "firingMode"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(ammoType), "ammoType"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(ammoCount), "ammoCount"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(magCount), "magCount"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(grenadeFlareType), "grenadeFlareType"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(grenadeFlareCount), "grenadeFlareCount"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(zeroing), "zeroing"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(weaponLowerInfoBackground), "weaponLowerInfoBackground"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(stance), "stance"] call EFUNC(common,readSettingFromModule); - -[_logic, QGVAR(vehicleName), "vehicleName"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleNameBackground), "vehicleNameBackground"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleFuelBar), "vehicleFuelBar"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleSpeed), "vehicleSpeed"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleAltitude), "vehicleAltitude"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleDamage), "vehicleDamage"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleInfoBackground), "vehicleInfoBackground"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleGunnerWeapon), "vehicleGunnerWeapon"] call EFUNC(common,readSettingFromModule); - -ACE_LOGINFO("User Interface (Advanced) Module Initialized."); diff --git a/addons/ui/functions/fnc_setAdvancedElement.sqf b/addons/ui/functions/fnc_setAdvancedElement.sqf index e5fc66d565..21910f0042 100644 --- a/addons/ui/functions/fnc_setAdvancedElement.sqf +++ b/addons/ui/functions/fnc_setAdvancedElement.sqf @@ -3,22 +3,29 @@ * Sets advanced visible element of the UI using displays and controls. * * Arguments: - * 0: Show/Hide Element OR Element Variable - * 1: Element IDD - * 2: Element IDCs + * 0: Element info + * 0: Show/Hide Element OR Element Variable + * 1: Element IDD + * 2: Element IDCs + * 1: Force change even when disallowed * * Return Value: * None * * Example: - * [show, 303, [188]] call ace_ui_fnc_setAdvancedElement + * [[show, 303, [188]], false] call ace_ui_fnc_setAdvancedElement * * Public: No */ #include "script_component.hpp" -params ["_show", "_idd", "_elements"]; +params ["_elementInfo", ["_force", false, [true]] ]; +if (!_force && {!GVAR(allowSelectiveUI)}) exitWith { + [LSTRING(Disallowed), 2] call EFUNC(common,displayTextStructured) +}; + +_elementInfo params ["_show", "_idd", "_elements"]; // Get show/hide boolean from mission namespace if it's a string if (typeName _show == "STRING") then { @@ -26,7 +33,6 @@ if (typeName _show == "STRING") then { }; _show = [1, 0] select _show; - // Disable/Enable elements { private _idc = _x; diff --git a/addons/ui/functions/fnc_setElements.sqf b/addons/ui/functions/fnc_setElements.sqf index 1a9ca73399..c1bb131db5 100644 --- a/addons/ui/functions/fnc_setElements.sqf +++ b/addons/ui/functions/fnc_setElements.sqf @@ -3,18 +3,24 @@ * Sets basic visible elements of the UI using showHUD setter. * * Arguments: - * None + * 0: Force change even when disallowed * * Return Value: * None * * Example: - * [] call ace_ui_fnc_setElements + * [false] call ace_ui_fnc_setElements * * Public: No */ #include "script_component.hpp" +params [ ["_force", false, [true]] ]; + +if (!_force && {!GVAR(allowSelectiveUI)}) exitWith { + [LSTRING(Disallowed), 2] call EFUNC(common,displayTextStructured) +}; + private _shownHUD = shownHUD; // [hud, info, radar, compass, direction, menu, group, cursors] ["ui", [ diff --git a/addons/ui/script_component.hpp b/addons/ui/script_component.hpp index 72f9066f1b..15f0b731b6 100644 --- a/addons/ui/script_component.hpp +++ b/addons/ui/script_component.hpp @@ -1,8 +1,8 @@ #define COMPONENT ui #include "\z\ace\addons\main\script_mod.hpp" -// #define DEBUG_MODE_FULL -// #define DISABLE_COMPILE_CACHE + #define DEBUG_MODE_FULL + #define DISABLE_COMPILE_CACHE // #define CBA_DEBUG_SYNCHRONOUS // #define ENABLE_PERFORMANCE_COUNTERS @@ -28,8 +28,8 @@ [QGVAR(ammoType), 300, [155] ], \ [QGVAR(ammoCount), 300, [184] ], \ [QGVAR(magCount), 300, [185] ], \ - [QGVAR(grenadeName), 300, [152] ], \ - [QGVAR(grenadeCount), 300, [151] ], \ + [QGVAR(throwableName), 300, [152] ], \ + [QGVAR(throwableCount), 300, [151] ], \ [QGVAR(weaponLowerInfoBackground), 300, [1202] ], \ [QGVAR(zeroing), 300, [168] ], \ [QGVAR(stance), 303, [188, 1201] ], \ diff --git a/addons/ui/stringtable.xml b/addons/ui/stringtable.xml index e320d3ce39..21932cb98e 100644 --- a/addons/ui/stringtable.xml +++ b/addons/ui/stringtable.xml @@ -4,14 +4,18 @@ User Interface - - User Interface (Basic) + User Interface - This module allows hiding of basic user interface parts. Makes some User Interface (Advanced) settings inoperable. + This module allows toggling visible user interface parts. + + + Allow Selective UI + + + Allow client to modify their UI. - Soldier/Vehicle/Weapon Information @@ -27,15 +31,6 @@ Group Bar - - - - User Interface (Advanced) - - - This module allows hiding of specific user interface parts, more detailed than basic. User Interface (Basic) settings will make some of the settings inoperable. - - Weapon Name @@ -51,17 +46,14 @@ Ammo Count - - Always disabled on foot by ace_reload. - Magazine Count - - Grenade/Flare Type + + Throwable Type - - Grenade/Flare Count + + Throwable Count Zeroing @@ -72,7 +64,6 @@ Stance - Vehicle Name @@ -97,5 +88,11 @@ Vehicle Gunner Weapon + + Requires Soldier/Vehicle/Weapons Information. + + + Modifying User Interface is disabled. + From 955333b0bc796d2835c11192de7571aad5f21a11 Mon Sep 17 00:00:00 2001 From: novichiv Date: Sun, 6 Mar 2016 22:06:11 +0300 Subject: [PATCH 043/215] Fixed strncpy in parse_imagepath --- extensions/parse_imagepath/ace_parse_imagepath.cpp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/extensions/parse_imagepath/ace_parse_imagepath.cpp b/extensions/parse_imagepath/ace_parse_imagepath.cpp index fa1a8643e7..dc27d60c72 100644 --- a/extensions/parse_imagepath/ace_parse_imagepath.cpp +++ b/extensions/parse_imagepath/ace_parse_imagepath.cpp @@ -36,18 +36,17 @@ std::string getImagePathFromStructuredText(const std::string & input) { return returnValue; } -// i like to live dangerously. jk, fix strncpy sometime pls. #pragma warning( push ) #pragma warning( disable : 4996 ) void __stdcall RVExtension(char *output, int outputSize, const char *function) { ZERO_OUTPUT(); - if (!strcmp(function, "version")) { - strncpy(output, ACE_FULL_VERSION_STR, outputSize); - } else { - strncpy(output, getImagePathFromStructuredText(function).c_str(), outputSize); - output[outputSize - 1] = '\0'; - } + if (!strcmp(function, "version")) { + strncpy_s(output, outputSize, ACE_FULL_VERSION_STR, _TRUNCATE); + } else { + strncpy_s(output, outputSize, getImagePathFromStructuredText(function).c_str(), _TRUNCATE); + output[outputSize - 1] = '\0'; + } EXTENSION_RETURN(); } From b5e95f394501d8ed6eccafdda36f2dc0233f206e Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 8 Mar 2016 01:17:40 -0600 Subject: [PATCH 044/215] Add some names/descriptions to settings configs --- addons/advanced_ballistics/ACE_Settings.hpp | 11 ++++ addons/explosives/ACE_Settings.hpp | 4 ++ addons/interaction/ACE_Settings.hpp | 2 + addons/medical/ACE_Settings.hpp | 60 ++++++++++++++++++++- addons/microdagr/ACE_Settings.hpp | 4 +- addons/mk6mortar/ACE_Settings.hpp | 8 +++ addons/rearm/ACE_Settings.hpp | 1 + addons/refuel/ACE_Settings.hpp | 1 + addons/respawn/ACE_Settings.hpp | 4 ++ addons/spectator/ACE_Settings.hpp | 8 +++ addons/switchunits/ACE_Settings.hpp | 12 +++++ addons/vehiclelock/ACE_Settings.hpp | 10 +++- addons/viewdistance/ACE_Settings.hpp | 6 +++ addons/zeus/ACE_Settings.hpp | 10 ++++ 14 files changed, 136 insertions(+), 5 deletions(-) diff --git a/addons/advanced_ballistics/ACE_Settings.hpp b/addons/advanced_ballistics/ACE_Settings.hpp index d88a9b1148..9815cc8491 100644 --- a/addons/advanced_ballistics/ACE_Settings.hpp +++ b/addons/advanced_ballistics/ACE_Settings.hpp @@ -1,29 +1,34 @@ class ACE_Settings { class GVAR(enabled) { + category = CSTRING(DisplayName); displayName = CSTRING(enabled_DisplayName); description = CSTRING(enabled_Description); typeName = "BOOL"; value = 0; }; class GVAR(simulateForSnipers) { + category = CSTRING(DisplayName); displayName = CSTRING(simulateForSnipers_DisplayName); description = CSTRING(simulateForSnipers_Description); typeName = "BOOL"; value = 1; }; class GVAR(simulateForGroupMembers) { + category = CSTRING(DisplayName); displayName = CSTRING(simulateForGroupMembers_DisplayName); description = CSTRING(simulateForGroupMembers_Description); typeName = "BOOL"; value = 0; }; class GVAR(simulateForEveryone) { + category = CSTRING(DisplayName); displayName = CSTRING(simulateForEveryone_DisplayName); description = CSTRING(simulateForEveryone_Description); typeName = "BOOL"; value = 0; }; class GVAR(disabledInFullAutoMode) { + category = CSTRING(DisplayName); displayName = CSTRING(disabledInFullAutoMod_DisplayName); description = CSTRING(disabledInFullAutoMod_Description); typeName = "BOOL"; @@ -31,6 +36,7 @@ class ACE_Settings { }; /* // TODO: We currently do not have firedEHs on vehicles class GVAR(vehicleGunnerEnabled) { + category = CSTRING(DisplayName); displayName = "Enabled For Vehicle Gunners"; description = "Enables advanced ballistics for vehicle gunners"; typeName = "BOOL"; @@ -38,30 +44,35 @@ class ACE_Settings { }; */ class GVAR(ammoTemperatureEnabled) { + category = CSTRING(DisplayName); displayName = CSTRING(ammoTemperatureEnabled_DisplayName); description = CSTRING(ammoTemperatureEnabled_Description); typeName = "BOOL"; value = 1; }; class GVAR(barrelLengthInfluenceEnabled) { + category = CSTRING(DisplayName); displayName = CSTRING(barrelLengthInfluenceEnabled_DisplayName); description = CSTRING(barrelLengthInfluenceEnabled_Description); typeName = "BOOL"; value = 1; }; class GVAR(bulletTraceEnabled) { + category = CSTRING(DisplayName); displayName = CSTRING(bulletTraceEnabled_DisplayName); description = CSTRING(bulletTraceEnabled_Description); typeName = "BOOL"; value = 1; }; class GVAR(simulationInterval) { + category = CSTRING(DisplayName); displayName = CSTRING(simulationInterval_DisplayName); description = CSTRING(simulationInterval_Description); typeName = "SCALAR"; value = 0.0; }; class GVAR(simulationRadius) { + category = CSTRING(DisplayName); displayName = CSTRING(simulationRadius_DisplayName); description = CSTRING(simulationRadius_Description); typeName = "SCALAR"; diff --git a/addons/explosives/ACE_Settings.hpp b/addons/explosives/ACE_Settings.hpp index ef6a723d5b..ceb6b62d25 100644 --- a/addons/explosives/ACE_Settings.hpp +++ b/addons/explosives/ACE_Settings.hpp @@ -1,9 +1,13 @@ class ACE_Settings { class GVAR(RequireSpecialist) { + displayName = CSTRING(RequireSpecialist_DisplayName); + description = CSTRING(RequireSpecialist_Description); value = 0; typeName = "BOOL"; }; class GVAR(PunishNonSpecialists) { + displayName = CSTRING(PunishNonSpecialists_DisplayName); + description = CSTRING(PunishNonSpecialists_Description); value = 1; typeName = "BOOL"; }; diff --git a/addons/interaction/ACE_Settings.hpp b/addons/interaction/ACE_Settings.hpp index a4e6dad42c..1cb8b747ef 100644 --- a/addons/interaction/ACE_Settings.hpp +++ b/addons/interaction/ACE_Settings.hpp @@ -1,6 +1,8 @@ class ACE_Settings { class GVAR(EnableTeamManagement) { + displayName = CSTRING(EnableTeamManagement_DisplayName); + description = CSTRING(EnableTeamManagement_Description); value = 1; typeName = "BOOL"; }; diff --git a/addons/medical/ACE_Settings.hpp b/addons/medical/ACE_Settings.hpp index 429cb995a1..e029f86d00 100644 --- a/addons/medical/ACE_Settings.hpp +++ b/addons/medical/ACE_Settings.hpp @@ -1,12 +1,16 @@ class ACE_Settings { class GVAR(level) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_level_DisplayName); + description = CSTRING(MedicalSettings_level_Description); value = 1; typeName = "SCALAR"; values[] = {"Disabled", "Basic", "Advanced"}; }; class GVAR(medicSetting) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_medicSetting_DisplayName); + description = CSTRING(MedicalSettings_medicSetting_Description); value = 1; typeName = "SCALAR"; values[] = {"Disabled", "Normal", "Advanced"}; @@ -20,6 +24,8 @@ class ACE_Settings { }; class GVAR(enableFor) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_enableFor_DisplayName); + description = CSTRING(AdvancedMedicalSettings_enableFor_Description); value = 0; typeName = "SCALAR"; values[] = {"Players only", "Players and AI"}; @@ -31,11 +37,15 @@ class ACE_Settings { }; class GVAR(bleedingCoefficient) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_bleedingCoefficient_DisplayName); + description = CSTRING(MedicalSettings_bleedingCoefficient_Description); typeName = "SCALAR"; value = 1; }; class GVAR(painCoefficient) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_painCoefficient_DisplayName); + description = CSTRING(MedicalSettings_painCoefficient_Description); typeName = "SCALAR"; value = 1; }; @@ -51,58 +61,80 @@ class ACE_Settings { }; class GVAR(enableAdvancedWounds) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_enableAdvancedWounds_DisplayName); + description = CSTRING(AdvancedMedicalSettings_enableAdvancedWounds_Description); typeName = "BOOL"; value = false; }; class GVAR(enableVehicleCrashes) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_enableVehicleCrashes_DisplayName); + description = CSTRING(AdvancedMedicalSettings_enableVehicleCrashes_Description); typeName = "BOOL"; value = 1; }; class GVAR(enableScreams) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_enableScreams_DisplayName); + description = CSTRING(MedicalSettings_enableScreams_Description); typeName = "BOOL"; value = 1; }; class GVAR(playerDamageThreshold) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_playerDamageThreshold_DisplayName); + description = CSTRING(MedicalSettings_playerDamageThreshold_Description); typeName = "SCALAR"; value = 1; }; class GVAR(AIDamageThreshold) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_AIDamageThreshold_DisplayName); + description = CSTRING(MedicalSettings_AIDamageThreshold_Description); typeName = "SCALAR"; value = 1; }; class GVAR(enableUnconsciousnessAI) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_enableUnconsciousnessAI_DisplayName); + description = CSTRING(MedicalSettings_enableUnconsciousnessAI_Description); value = 1; typeName = "SCALAR"; values[] = {"Disabled", "50/50", "Enabled"}; }; class GVAR(remoteControlledAI) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_remoteControlledAI_DisplayName); + description = CSTRING(MedicalSettings_remoteControlledAI_Description); typeName = "BOOL"; value = 1; }; class GVAR(preventInstaDeath) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_preventInstaDeath_DisplayName); + description = CSTRING(MedicalSettings_preventInstaDeath_Description); typeName = "BOOL"; value = 0; }; class GVAR(enableRevive) { category = CSTRING(Category_Medical); + displayName = CSTRING(ReviveSettings_enableRevive_DisplayName); + description = CSTRING(ReviveSettings_enableRevive_Description); typeName = "SCALAR"; value = 0; values[] = {"Disabled", "Players only", "Players and AI"}; }; class GVAR(maxReviveTime) { category = CSTRING(Category_Medical); + displayName = CSTRING(ReviveSettings_maxReviveTime_DisplayName); + description = CSTRING(ReviveSettings_maxReviveTime_Description); typeName = "SCALAR"; value = 120; }; class GVAR(amountOfReviveLives) { category = CSTRING(Category_Medical); + displayName = CSTRING(ReviveSettings_amountOfReviveLives_DisplayName); + description = CSTRING(ReviveSettings_amountOfReviveLives_Description); typeName = "SCALAR"; value = -1; }; @@ -113,6 +145,8 @@ class ACE_Settings { }; class GVAR(allowLitterCreation) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_allowLitterCreation_DisplayName); + description = CSTRING(MedicalSettings_allowLitterCreation_Description); typeName = "BOOL"; value = 1; }; @@ -130,53 +164,71 @@ class ACE_Settings { }; class GVAR(litterCleanUpDelay) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_litterCleanUpDelay_DisplayName); + description = CSTRING(MedicalSettings_litterCleanUpDelay_Description); typeName = "SCALAR"; value = 0; }; class GVAR(medicSetting_basicEpi) { category = CSTRING(Category_Medical); + displayName = CSTRING(BasicMedicalSettings_medicSetting_basicEpi_DisplayName); + description = CSTRING(BasicMedicalSettings_medicSetting_basicEpi_Description); typeName = "SCALAR"; value = 1; values[] = {"Anyone", "Medics only", "Doctors only"}; }; class GVAR(medicSetting_PAK) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_medicSetting_PAK_DisplayName); + description = CSTRING(AdvancedMedicalSettings_medicSetting_PAK_Description); typeName = "SCALAR"; value = 1; values[] = {"Anyone", "Medics only", "Doctors only"}; }; class GVAR(medicSetting_SurgicalKit) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_medicSetting_SurgicalKit_DisplayName); + description = CSTRING(AdvancedMedicalSettings_medicSetting_SurgicalKit_Description); typeName = "SCALAR"; value = 1; values[] = {"Anyone", "Medics only", "Doctors only"}; }; class GVAR(consumeItem_PAK) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_consumeItem_PAK_DisplayName); + description = CSTRING(AdvancedMedicalSettings_consumeItem_PAK_Description); typeName = "SCALAR"; value = 0; values[] = {"No", "Yes"}; }; class GVAR(consumeItem_SurgicalKit) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_consumeItem_SurgicalKit_DisplayName); + description = CSTRING(AdvancedMedicalSettings_consumeItem_SurgicalKit_Description); typeName = "SCALAR"; value = 0; values[] = {"No", "Yes"}; }; class GVAR(useLocation_basicEpi) { category = CSTRING(Category_Medical); + displayName = CSTRING(BasicMedicalSettings_useLocation_basicEpi_DisplayName); + description = CSTRING(BasicMedicalSettings_useLocation_basicEpi_Description); typeName = "SCALAR"; value = 0; values[] = {CSTRING(AdvancedMedicalSettings_anywhere), CSTRING(AdvancedMedicalSettings_vehicle), CSTRING(AdvancedMedicalSettings_facility), CSTRING(AdvancedMedicalSettings_vehicleAndFacility), ECSTRING(common,Disabled)}; }; class GVAR(useLocation_PAK) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_useLocation_PAK_DisplayName); + description = CSTRING(AdvancedMedicalSettings_useLocation_PAK_Description); typeName = "SCALAR"; value = 3; values[] = {CSTRING(AdvancedMedicalSettings_anywhere), CSTRING(AdvancedMedicalSettings_vehicle), CSTRING(AdvancedMedicalSettings_facility), CSTRING(AdvancedMedicalSettings_vehicleAndFacility), ECSTRING(common,Disabled)}; }; class GVAR(useLocation_SurgicalKit) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_useLocation_SurgicalKit_DisplayName); + description = CSTRING(AdvancedMedicalSettings_useLocation_SurgicalKit_Description); typeName = "SCALAR"; value = 2; values[] = {CSTRING(AdvancedMedicalSettings_anywhere), CSTRING(AdvancedMedicalSettings_vehicle), CSTRING(AdvancedMedicalSettings_facility), CSTRING(AdvancedMedicalSettings_vehicleAndFacility), ECSTRING(common,Disabled)}; @@ -199,17 +251,23 @@ class ACE_Settings { }; class GVAR(keepLocalSettingsSynced) { category = CSTRING(Category_Medical); + displayName = CSTRING(MedicalSettings_keepLocalSettingsSynced_DisplayName); + description = CSTRING(MedicalSettings_keepLocalSettingsSynced_Description); typeName = "BOOL"; value = 1; }; class GVAR(healHitPointAfterAdvBandage) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_healHitPointAfterAdvBandage_DisplayName); + description = CSTRING(AdvancedMedicalSettings_healHitPointAfterAdvBandage_Description); displayName = CSTRING(healHitPointAfterAdvBandage); typeName = "BOOL"; value = 0; }; class GVAR(painIsOnlySuppressed) { category = CSTRING(Category_Medical); + displayName = CSTRING(AdvancedMedicalSettings_painIsOnlySuppressed_DisplayName); + description = CSTRING(AdvancedMedicalSettings_painIsOnlySuppressed_Description); displayName = CSTRING(painIsOnlySuppressed); typeName = "BOOL"; value = 1; @@ -232,7 +290,6 @@ class ACE_Settings { typeName = "BOOL"; value = 0; }; - class GVAR(menuTypeStyle) { category = CSTRING(Category_Medical); displayName = CSTRING(menuTypeDisplay); @@ -242,7 +299,6 @@ class ACE_Settings { values[] = {CSTRING(useSelection), CSTRING(useRadial), "Disabled"}; isClientSettable = 1; }; - class GVAR(delayUnconCaptive) { category = CSTRING(Category_Medical); displayName = CSTRING(MedicalSettings_delayUnconCaptive_DisplayName); diff --git a/addons/microdagr/ACE_Settings.hpp b/addons/microdagr/ACE_Settings.hpp index db175e7303..4cf83794dd 100644 --- a/addons/microdagr/ACE_Settings.hpp +++ b/addons/microdagr/ACE_Settings.hpp @@ -1,7 +1,9 @@ class ACE_Settings { class GVAR(MapDataAvailable) { + displayName = CSTRING(MapDataAvailable_DisplayName); + description = CSTRING(MapDataAvailable_Description); value = 2; typeName = "SCALAR"; isClientSettable = 0; }; -}; \ No newline at end of file +}; diff --git a/addons/mk6mortar/ACE_Settings.hpp b/addons/mk6mortar/ACE_Settings.hpp index 6d1eebf942..cd7d4e64cb 100644 --- a/addons/mk6mortar/ACE_Settings.hpp +++ b/addons/mk6mortar/ACE_Settings.hpp @@ -1,21 +1,29 @@ class ACE_Settings { //These settings effect gameplay difficutly: defaults will leave the mortar the same as vanilla class GVAR(airResistanceEnabled) { + displayName = CSTRING(airResistanceEnabled_DisplayName); + description = CSTRING(airResistanceEnabled_Description); value = 0; typeName = "BOOL"; isClientSetable = 0; }; class GVAR(allowComputerRangefinder) { + displayName = CSTRING(allowComputerRangefinder_DisplayName); + description = CSTRING(allowComputerRangefinder_Description); value = 1; typeName = "BOOL"; isClientSetable = 0; }; class GVAR(allowCompass) { + displayName = CSTRING(allowCompass_DisplayName); + description = CSTRING(allowCompass_Description); value = 1; typeName = "BOOL"; isClientSetable = 0; }; class GVAR(useAmmoHandling) { + displayName = CSTRING(useAmmoHandling_DisplayName); + description = CSTRING(useAmmoHandling_Description); value = 0; typeName = "BOOL"; isClientSetable = 0; diff --git a/addons/rearm/ACE_Settings.hpp b/addons/rearm/ACE_Settings.hpp index f4d6562807..798bbd7650 100644 --- a/addons/rearm/ACE_Settings.hpp +++ b/addons/rearm/ACE_Settings.hpp @@ -1,5 +1,6 @@ class ACE_Settings { class GVAR(level) { + category = ECSTRING(OptionsMenu,CategoryLogistics); displayName = CSTRING(RearmSettings_level_DisplayName); description = CSTRING(RearmSettings_level_Description); value = 0; diff --git a/addons/refuel/ACE_Settings.hpp b/addons/refuel/ACE_Settings.hpp index 0ae0accaad..b38a880641 100644 --- a/addons/refuel/ACE_Settings.hpp +++ b/addons/refuel/ACE_Settings.hpp @@ -1,5 +1,6 @@ class ACE_Settings { class GVAR(rate) { + category = ECSTRING(OptionsMenu,CategoryLogistics); displayName = CSTRING(RefuelSettings_speed_DisplayName); description = CSTRING(RefuelSettings_speed_Description); value = 1; diff --git a/addons/respawn/ACE_Settings.hpp b/addons/respawn/ACE_Settings.hpp index f704d25412..86083d6d07 100644 --- a/addons/respawn/ACE_Settings.hpp +++ b/addons/respawn/ACE_Settings.hpp @@ -1,10 +1,14 @@ class ACE_Settings { class GVAR(SavePreDeathGear) { + displayName = CSTRING(SavePreDeathGear_DisplayName); + description = CSTRING(SavePreDeathGear_Description); value = 0; typeName = "BOOL"; }; class GVAR(RemoveDeadBodiesDisconnected) { + displayName = CSTRING(RemoveDeadBodiesDisconnected_DisplayName); + description = CSTRING(RemoveDeadBodiesDisconnected_Description); value = 1; typeName = "BOOL"; }; diff --git a/addons/spectator/ACE_Settings.hpp b/addons/spectator/ACE_Settings.hpp index 78402cff23..31e4ea3fd0 100644 --- a/addons/spectator/ACE_Settings.hpp +++ b/addons/spectator/ACE_Settings.hpp @@ -1,20 +1,28 @@ class ACE_Settings { class GVAR(filterUnits) { + displayName = CSTRING(units_DisplayName); + description = CSTRING(units_Description); typeName = "SCALAR"; value = 2; values[] = {CSTRING(units_none), CSTRING(units_players), CSTRING(units_playable), CSTRING(units_all)}; }; class GVAR(filterSides) { + displayName = CSTRING(sides_DisplayName); + description = CSTRING(sides_Description); typeName = "SCALAR"; value = 0; values[] = {CSTRING(sides_player), CSTRING(sides_friendly), CSTRING(sides_hostile), CSTRING(sides_all)}; }; class GVAR(restrictModes) { + displayName = CSTRING(modes_DisplayName); + description = CSTRING(modes_Description); typeName = "SCALAR"; value = 0; values[] = {CSTRING(modes_all), CSTRING(modes_unit), CSTRING(modes_free), CSTRING(modes_internal), CSTRING(modes_external)}; }; class GVAR(restrictVisions) { + displayName = CSTRING(visions_DisplayName); + description = CSTRING(visions_Description); typeName = "SCALAR"; value = 0; values[] = {CSTRING(modes_all), CSTRING(visions_nv), CSTRING(visions_ti), "$STR_Special_None"}; diff --git a/addons/switchunits/ACE_Settings.hpp b/addons/switchunits/ACE_Settings.hpp index 06c1ff274c..fe15e63e87 100644 --- a/addons/switchunits/ACE_Settings.hpp +++ b/addons/switchunits/ACE_Settings.hpp @@ -4,26 +4,38 @@ class ACE_Settings { typeName = "BOOL"; }; class GVAR(SwitchToWest) { + displayName = CSTRING(SwitchToWest_DisplayName); + description = CSTRING(SwitchToWest_Description); value = 0; typeName = "BOOL"; }; class GVAR(SwitchToEast) { + displayName = CSTRING(SwitchToEast_DisplayName); + description = CSTRING(SwitchToEast_Description); value = 0; typeName = "BOOL"; }; class GVAR(SwitchToIndependent) { + displayName = CSTRING(SwitchToIndependent_DisplayName); + description = CSTRING(SwitchToIndependent_Description); value = 0; typeName = "BOOL"; }; class GVAR(SwitchToCivilian) { + displayName = CSTRING(SwitchToCivilian_DisplayName); + description = CSTRING(SwitchToCivilian_Description); value = 0; typeName = "BOOL"; }; class GVAR(EnableSafeZone) { + displayName = CSTRING(EnableSafeZone_DisplayName); + description = CSTRING(EnableSafeZone_Description); value = 1; typeName = "BOOL"; }; class GVAR(SafeZoneRadius) { + displayName = CSTRING(SafeZoneRadius_DisplayName); + description = CSTRING(SafeZoneRadius_Description); value = 100; typeName = "SCALAR"; }; diff --git a/addons/vehiclelock/ACE_Settings.hpp b/addons/vehiclelock/ACE_Settings.hpp index 9eac505db2..fabc8b94ad 100644 --- a/addons/vehiclelock/ACE_Settings.hpp +++ b/addons/vehiclelock/ACE_Settings.hpp @@ -1,14 +1,20 @@ class ACE_Settings { class GVAR(DefaultLockpickStrength) { + displayName = CSTRING(DefaultLockpickStrength_DisplayName); + description = CSTRING(DefaultLockpickStrength_Description); value = 10; typeName = "SCALAR"; }; class GVAR(LockVehicleInventory) { + displayName = CSTRING(LockVehicleInventory_DisplayName); + description = CSTRING(LockVehicleInventory_Description); value = 0; typeName = "BOOL"; - }; + }; class GVAR(VehicleStartingLockState) { + displayName = CSTRING(VehicleStartingLockState_DisplayName); + description = CSTRING(VehicleStartingLockState_Description); value = -1; typeName = "SCALAR"; }; -}; \ No newline at end of file +}; diff --git a/addons/viewdistance/ACE_Settings.hpp b/addons/viewdistance/ACE_Settings.hpp index 1499626b7f..356c7d86f2 100644 --- a/addons/viewdistance/ACE_Settings.hpp +++ b/addons/viewdistance/ACE_Settings.hpp @@ -1,11 +1,13 @@ class ACE_Settings { class GVAR(enabled) { + category = CSTRING(Module_DisplayName); typeName = "BOOL"; value = 1; displayName = CSTRING(enabled_DisplayName); description = CSTRING(enabled_Description); }; class GVAR(viewDistanceOnFoot) { + category = CSTRING(Module_DisplayName); typeName = "SCALAR"; isClientSettable = 1; value = 0; // index, NOT value // Can set it to client's actual viewdistance in the init function once ACE_Settings supports numbers (if ever). @@ -14,6 +16,7 @@ class ACE_Settings { description = CSTRING(onFoot_Description); }; class GVAR(viewDistanceLandVehicle) { + category = CSTRING(Module_DisplayName); typeName = "SCALAR"; isClientSettable = 1; value = 0; // index, NOT value @@ -22,6 +25,7 @@ class ACE_Settings { description = CSTRING(landVehicle_Description); }; class GVAR(viewDistanceAirVehicle) { + category = CSTRING(Module_DisplayName); typeName = "SCALAR"; isClientSettable = 1; value = 0; // index, NOT value @@ -30,12 +34,14 @@ class ACE_Settings { description = CSTRING(airVehicle_Description); }; class GVAR(limitViewDistance) { + category = CSTRING(Module_DisplayName); typeName = "SCALAR"; value = 10000; // Value, NOT index. 10000 is the maximum in A3 displayName = CSTRING(limit_DisplayName); description = CSTRING(limit_setting); }; class GVAR(objectViewDistanceCoeff) { + category = CSTRING(Module_DisplayName); typeName = "SCALAR"; isClientSettable = 1; value = 0; // index. Actual coefficient is given by functions/fnc_returnObjectCoeff.sqf diff --git a/addons/zeus/ACE_Settings.hpp b/addons/zeus/ACE_Settings.hpp index 6488a23e4e..6357992cf6 100644 --- a/addons/zeus/ACE_Settings.hpp +++ b/addons/zeus/ACE_Settings.hpp @@ -1,21 +1,31 @@ class ACE_Settings { class GVAR(zeusAscension) { + displayName = CSTRING(ascension_DisplayName); + description = CSTRING(ascension_Description); typeName = "BOOL"; value = 0; }; class GVAR(zeusBird) { + displayName = CSTRING(bird_DisplayName); + description = CSTRING(bird_Description); typeName = "BOOL"; value = 0; }; class GVAR(remoteWind) { + displayName = CSTRING(remoteWind_DisplayName); + description = CSTRING(remoteWind_Description); typeName = "BOOL"; value = 0; }; class GVAR(radioOrdnance) { + displayName = CSTRING(radioOrdnance_DisplayName); + description = CSTRING(radioOrdnance_Description); typeName = "BOOL"; value = 0; }; class GVAR(revealMines) { + displayName = CSTRING(revealMines_DisplayName); + description = CSTRING(revealMines_Description); typeName = "SCALAR"; value = 0; values[] = {"$STR_A3_OPTIONS_DISABLED", CSTRING(revealMines_partial), CSTRING(revealMines_full)}; From 64fe944b0fdbf7d7db271a0ea488fb1f6e347b6a Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 8 Mar 2016 18:12:01 +0100 Subject: [PATCH 045/215] Add public setter function, Optimize some checks --- addons/ui/XEH_PREP.hpp | 1 + addons/ui/XEH_preInit.sqf | 2 + addons/ui/functions/fnc_moduleInit.sqf | 22 ++++---- .../ui/functions/fnc_setAdvancedElement.sqf | 7 +++ .../ui/functions/fnc_setElementVisibility.sqf | 52 +++++++++++++++++++ addons/ui/functions/fnc_setElements.sqf | 2 + 6 files changed, 75 insertions(+), 11 deletions(-) create mode 100644 addons/ui/functions/fnc_setElementVisibility.sqf diff --git a/addons/ui/XEH_PREP.hpp b/addons/ui/XEH_PREP.hpp index 6660470ba8..8a6b4d2ce1 100644 --- a/addons/ui/XEH_PREP.hpp +++ b/addons/ui/XEH_PREP.hpp @@ -1,3 +1,4 @@ PREP(moduleInit); PREP(setAdvancedElement); PREP(setElements); +PREP(setElementVisibility); diff --git a/addons/ui/XEH_preInit.sqf b/addons/ui/XEH_preInit.sqf index a7feade1c3..4a5638fc03 100644 --- a/addons/ui/XEH_preInit.sqf +++ b/addons/ui/XEH_preInit.sqf @@ -4,4 +4,6 @@ ADDON = false; #include "XEH_PREP.hpp" +GVAR(elementsSet) = []; + ADDON = true; diff --git a/addons/ui/functions/fnc_moduleInit.sqf b/addons/ui/functions/fnc_moduleInit.sqf index fe0f07709a..8327b09e72 100644 --- a/addons/ui/functions/fnc_moduleInit.sqf +++ b/addons/ui/functions/fnc_moduleInit.sqf @@ -18,18 +18,18 @@ params ["_logic", "_units", "_activated"]; if (!_activated) exitWith {}; -// Exit if HUD visibility is hardcoded in mission config and showHUD command is overriden -if (isArray (missionConfigFile >> "showHUD")) exitWith { - ACE_LOGINFO("User Interface Module Failed to Initialize - showHUD overriden in mission config!"); -}; - // Basic -[_logic, QGVAR(allowSelectiveUI), "allowSelectiveUI"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(soldierVehicleWeaponInfo), "soldierVehicleWeaponInfo"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleRadar), "vehicleRadar"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(vehicleCompass), "vehicleCompass"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(commandMenu), "commandMenu"] call EFUNC(common,readSettingFromModule); -[_logic, QGVAR(groupBar), "groupBar"] call EFUNC(common,readSettingFromModule); +if (isArray (missionConfigFile >> "showHUD")) then { + // HUD visibility is hardcoded in mission config and showHUD command is overriden + ACE_LOGINFO("User Interface Module Failed to Initialize Basic settings - showHUD overriden in mission config!"); +} else { + [_logic, QGVAR(allowSelectiveUI), "allowSelectiveUI"] call EFUNC(common,readSettingFromModule); + [_logic, QGVAR(soldierVehicleWeaponInfo), "soldierVehicleWeaponInfo"] call EFUNC(common,readSettingFromModule); + [_logic, QGVAR(vehicleRadar), "vehicleRadar"] call EFUNC(common,readSettingFromModule); + [_logic, QGVAR(vehicleCompass), "vehicleCompass"] call EFUNC(common,readSettingFromModule); + [_logic, QGVAR(commandMenu), "commandMenu"] call EFUNC(common,readSettingFromModule); + [_logic, QGVAR(groupBar), "groupBar"] call EFUNC(common,readSettingFromModule); +}; // Advanced [_logic, QGVAR(weaponName), "weaponName"] call EFUNC(common,readSettingFromModule); diff --git a/addons/ui/functions/fnc_setAdvancedElement.sqf b/addons/ui/functions/fnc_setAdvancedElement.sqf index 21910f0042..9e001d7d9c 100644 --- a/addons/ui/functions/fnc_setAdvancedElement.sqf +++ b/addons/ui/functions/fnc_setAdvancedElement.sqf @@ -21,6 +21,8 @@ params ["_elementInfo", ["_force", false, [true]] ]; +if (_elementInfo in GVAR(elementsSet)) exitWith {}; + if (!_force && {!GVAR(allowSelectiveUI)}) exitWith { [LSTRING(Disallowed), 2] call EFUNC(common,displayTextStructured) }; @@ -34,6 +36,7 @@ if (typeName _show == "STRING") then { _show = [1, 0] select _show; // Disable/Enable elements +private _success = false; { private _idc = _x; @@ -44,6 +47,10 @@ _show = [1, 0] select _show; (_x displayCtrl _idc) ctrlSetFade _show; (_x displayCtrl _idc) ctrlCommit 0; + + _success = true; }; } forEach (uiNamespace getVariable "IGUI_displays"); } forEach _elements; + +_success diff --git a/addons/ui/functions/fnc_setElementVisibility.sqf b/addons/ui/functions/fnc_setElementVisibility.sqf new file mode 100644 index 0000000000..f09fe061f1 --- /dev/null +++ b/addons/ui/functions/fnc_setElementVisibility.sqf @@ -0,0 +1,52 @@ +/* + * Author: Jonpas + * Wrapper for setting advanced element visibility. + * + * Arguments: + * 0: Set/Unset (default: true) + * 1: Element info + * 0: Show/Hide Element OR Element Variable + * 1: Element IDD + * 2: Element IDCs + * + * Return Value: + * None + * + * Example: + * [false] call ace_ui_fnc_setElementVisibility + * + * Public: Yes + */ +#include "script_component.hpp" + +params [ + ["_set", true, [true]], + ["_elementInfo", [true, 0, []], [[]], 3] +]; + +_elementInfo params [ + ["_show", false, [true, ""]], + ["_idd", 0, [0]], + ["_elements", [], [[]]] +]; + +if (_set) then { + if ([_idd, _elements] in GVAR(elementsSet)) exitWith { TRACE_2("Element already set",_elementInfo,GVAR(elementsSet)); }; + + TRACE_2("Setting element",_elementInfo,GVAR(elementsSet)); + private _success = [_elementInfo] call FUNC(setAdvancedElement); + + if (_success) then { + GVAR(elementsSet) pushBack [_idd, _elements]; + }; +} else { + if ([_idd, _elements] in GVAR(elementsSet)) then { + TRACE_2("Unsetting element",_elementInfo,GVAR(elementsSet)); + + TRACE_2("Toggling element",_elementInfo,GVAR(elementsSet)); + [_elementInfo] call FUNC(setAdvancedElement); + + private _index = GVAR(elementsSet) find [_idd, _elements]; + GVAR(elementsSet) deleteAt _index; + }; +}; diff --git a/addons/ui/functions/fnc_setElements.sqf b/addons/ui/functions/fnc_setElements.sqf index c1bb131db5..71fbfdf945 100644 --- a/addons/ui/functions/fnc_setElements.sqf +++ b/addons/ui/functions/fnc_setElements.sqf @@ -15,6 +15,8 @@ */ #include "script_component.hpp" +if (isArray (missionConfigFile >> "showHUD")) exitWith {}; + params [ ["_force", false, [true]] ]; if (!_force && {!GVAR(allowSelectiveUI)}) exitWith { From 23e2617db8c97868d888b7f9e7e34e70f083b031 Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 8 Mar 2016 18:40:23 +0100 Subject: [PATCH 046/215] Change params order and improve clientInit --- addons/ui/XEH_clientInit.sqf | 22 +++++----- .../ui/functions/fnc_setAdvancedElement.sqf | 17 ++++---- .../ui/functions/fnc_setElementVisibility.sqf | 33 +++++++-------- addons/ui/functions/fnc_setElements.sqf | 2 +- addons/ui/script_component.hpp | 40 +++++++++---------- 5 files changed, 51 insertions(+), 63 deletions(-) diff --git a/addons/ui/XEH_clientInit.sqf b/addons/ui/XEH_clientInit.sqf index 23fa19af11..47fb36cb14 100644 --- a/addons/ui/XEH_clientInit.sqf +++ b/addons/ui/XEH_clientInit.sqf @@ -12,17 +12,13 @@ if (!hasInterface) exitWith {}; ["infoDisplayChanged", { // Selective UI Advanced // Defaults must be set in this EH to make sure controls are activated and advanced settings can be modified - if (!GVAR(allowSelectiveUI)) then { - { - [_x, true] call FUNC(setAdvancedElement); - } forEach ELEMENTS_ADVANCED; - } else { - { - [_x] call FUNC(setAdvancedElement); - } forEach ELEMENTS_ADVANCED; - }; + private _force = [true, false] select (GVAR(allowSelectiveUI)); + { + [_x select 0, _x select 1, _x select 2, _force] call FUNC(setAdvancedElement); + } forEach ELEMENTS_ADVANCED; }] call EFUNC(common,addEventHandler); + // On changing settings ["SettingChanged", { params ["_name"]; @@ -33,11 +29,11 @@ if (!hasInterface) exitWith {}; // Selective UI Advanced { - _x params ["_element"]; + params ["_idd", "_elements", "_name"]; - if (_name == _element) then { - [_x] call FUNC(setAdvancedElement); - TRACE_2("Setting Changed",_name,_element); + if (_name == _name) then { + [_idd, _elements, _name] call FUNC(setAdvancedElement); + TRACE_2("Setting Changed",_name,_name); }; } forEach ELEMENTS_ADVANCED; }] call EFUNC(common,addEventHandler); diff --git a/addons/ui/functions/fnc_setAdvancedElement.sqf b/addons/ui/functions/fnc_setAdvancedElement.sqf index 9e001d7d9c..2ef88d5868 100644 --- a/addons/ui/functions/fnc_setAdvancedElement.sqf +++ b/addons/ui/functions/fnc_setAdvancedElement.sqf @@ -3,23 +3,22 @@ * Sets advanced visible element of the UI using displays and controls. * * Arguments: - * 0: Element info - * 0: Show/Hide Element OR Element Variable - * 1: Element IDD - * 2: Element IDCs - * 1: Force change even when disallowed + * 0: Element IDD + * 1: Element IDCs + * 2: Show/Hide Element OR Element ACE Settings Variable + * 3: Force change even when disallowed (default: false) * * Return Value: - * None + * Successfully Set * * Example: - * [[show, 303, [188]], false] call ace_ui_fnc_setAdvancedElement + * [303, [188], true, false] call ace_ui_fnc_setAdvancedElement * * Public: No */ #include "script_component.hpp" -params ["_elementInfo", ["_force", false, [true]] ]; +params ["_idd", "_elements", "_show", ["_force", false, [true]] ]; if (_elementInfo in GVAR(elementsSet)) exitWith {}; @@ -27,8 +26,6 @@ if (!_force && {!GVAR(allowSelectiveUI)}) exitWith { [LSTRING(Disallowed), 2] call EFUNC(common,displayTextStructured) }; -_elementInfo params ["_show", "_idd", "_elements"]; - // Get show/hide boolean from mission namespace if it's a string if (typeName _show == "STRING") then { _show = missionNamespace getVariable _show; diff --git a/addons/ui/functions/fnc_setElementVisibility.sqf b/addons/ui/functions/fnc_setElementVisibility.sqf index f09fe061f1..d2ec34d7ba 100644 --- a/addons/ui/functions/fnc_setElementVisibility.sqf +++ b/addons/ui/functions/fnc_setElementVisibility.sqf @@ -1,19 +1,18 @@ /* * Author: Jonpas - * Wrapper for setting advanced element visibility. + * Setter for toggling advanced element visibility. * * Arguments: * 0: Set/Unset (default: true) - * 1: Element info - * 0: Show/Hide Element OR Element Variable - * 1: Element IDD - * 2: Element IDCs + * 1: Element IDD (default: 0) + * 2: Element IDCs (default: []) + * 3: Show/Hide Element OR Element ACE Settings Variable (default: false) * * Return Value: * None * * Example: - * [false] call ace_ui_fnc_setElementVisibility + * [true, 300, [188], false] call ace_ui_fnc_setElementVisibility * * Public: Yes */ @@ -21,32 +20,28 @@ params [ ["_set", true, [true]], - ["_elementInfo", [true, 0, []], [[]], 3] -]; - -_elementInfo params [ - ["_show", false, [true, ""]], ["_idd", 0, [0]], - ["_elements", [], [[]]] + ["_elements", [], [[]]], + ["_show", false, [true, ""]] ]; if (_set) then { - if ([_idd, _elements] in GVAR(elementsSet)) exitWith { TRACE_2("Element already set",_elementInfo,GVAR(elementsSet)); }; + if ([_idd, _elements] in GVAR(elementsSet)) exitWith { TRACE_3("Element already set",_idd,_elements,GVAR(elementsSet)); }; - TRACE_2("Setting element",_elementInfo,GVAR(elementsSet)); - private _success = [_elementInfo] call FUNC(setAdvancedElement); + TRACE_4("Setting element",_idd,_elements,_show,GVAR(elementsSet)); + private _success = [_idd, _elements, _show] call FUNC(setAdvancedElement); if (_success) then { GVAR(elementsSet) pushBack [_idd, _elements]; }; } else { if ([_idd, _elements] in GVAR(elementsSet)) then { - TRACE_2("Unsetting element",_elementInfo,GVAR(elementsSet)); - - TRACE_2("Toggling element",_elementInfo,GVAR(elementsSet)); - [_elementInfo] call FUNC(setAdvancedElement); + TRACE_4("Setting element",_idd,_elements,_show,GVAR(elementsSet)); + [_idd, _elements, _show] call FUNC(setAdvancedElement); private _index = GVAR(elementsSet) find [_idd, _elements]; GVAR(elementsSet) deleteAt _index; }; }; + +TRACE_1("Visibility set",GVAR(elementsSet)); diff --git a/addons/ui/functions/fnc_setElements.sqf b/addons/ui/functions/fnc_setElements.sqf index 71fbfdf945..92cc981065 100644 --- a/addons/ui/functions/fnc_setElements.sqf +++ b/addons/ui/functions/fnc_setElements.sqf @@ -3,7 +3,7 @@ * Sets basic visible elements of the UI using showHUD setter. * * Arguments: - * 0: Force change even when disallowed + * 0: Force change even when disallowed (default: false) * * Return Value: * None diff --git a/addons/ui/script_component.hpp b/addons/ui/script_component.hpp index 15f0b731b6..14392f5af2 100644 --- a/addons/ui/script_component.hpp +++ b/addons/ui/script_component.hpp @@ -20,27 +20,27 @@ // Elements #define ELEMENTS_BASIC [QGVAR(soldierVehicleWeaponInfo), QGVAR(vehicleRadar), QGVAR(vehicleCompass), QGVAR(commandMenu), QGVAR(groupBar)] -// Element, IDD, IDC +// IDD, IDC, Element (must be string to compare to changed setting name) #define ELEMENTS_ADVANCED [ \ - [QGVAR(weaponName), 300, [118] ], \ - [QGVAR(weaponNameBackground), 300, [1001, 1008] ], \ - [QGVAR(firingMode), 300, [187, 1203] ], \ - [QGVAR(ammoType), 300, [155] ], \ - [QGVAR(ammoCount), 300, [184] ], \ - [QGVAR(magCount), 300, [185] ], \ - [QGVAR(throwableName), 300, [152] ], \ - [QGVAR(throwableCount), 300, [151] ], \ - [QGVAR(weaponLowerInfoBackground), 300, [1202] ], \ - [QGVAR(zeroing), 300, [168] ], \ - [QGVAR(stance), 303, [188, 1201] ], \ - [QGVAR(vehicleName), 300, [120] ], \ - [QGVAR(vehicleNameBackground), 300, [1000, 1013] ], \ - [QGVAR(vehicleFuelBar), 300, [113, 1202] ], \ - [QGVAR(vehicleSpeed), 300, [121, 1004, 1006] ], \ - [QGVAR(vehicleAltitude), 300, [122, 1005, 1014] ], \ - [QGVAR(vehicleDamage), 300, [111] ], \ - [QGVAR(vehicleInfoBackground), 300, [1200] ], \ - [QGVAR(vehicleGunnerWeapon), 300, [150] ] \ + [300, [118], QGVAR(weaponName)], \ + [300, [1001, 1008], QGVAR(weaponNameBackground)], \ + [300, [187, 1203], QGVAR(firingMode)], \ + [300, [155], QGVAR(ammoType)], \ + [300, [184], QGVAR(ammoCount)], \ + [300, [185], QGVAR(magCount)], \ + [300, [152], QGVAR(throwableName)], \ + [300, [151], QGVAR(throwableCount)], \ + [300, [1202], QGVAR(weaponLowerInfoBackground)], \ + [300, [168], QGVAR(zeroing)], \ + [303, [188, 1201], QGVAR(stance)], \ + [300, [120], QGVAR(vehicleName)], \ + [300, [1000, 1013], QGVAR(vehicleNameBackground)], \ + [300, [113, 1202], QGVAR(vehicleFuelBar)], \ + [300, [121, 1004, 1006], QGVAR(vehicleSpeed)], \ + [300, [122, 1005, 1014], QGVAR(vehicleAltitude)], \ + [300, [111], QGVAR(vehicleDamage)], \ + [300, [1200], QGVAR(vehicleInfoBackground)], \ + [300, [150], QGVAR(vehicleGunnerWeapon)] \ ] From e90ef30904cd4ea73f03be9d81ef82d5ce06a8cd Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 8 Mar 2016 18:42:37 +0100 Subject: [PATCH 047/215] Add return value to public setElementVisibility function --- addons/ui/functions/fnc_setElementVisibility.sqf | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/addons/ui/functions/fnc_setElementVisibility.sqf b/addons/ui/functions/fnc_setElementVisibility.sqf index d2ec34d7ba..b019c4c081 100644 --- a/addons/ui/functions/fnc_setElementVisibility.sqf +++ b/addons/ui/functions/fnc_setElementVisibility.sqf @@ -25,6 +25,8 @@ params [ ["_show", false, [true, ""]] ]; +private _return = false; + if (_set) then { if ([_idd, _elements] in GVAR(elementsSet)) exitWith { TRACE_3("Element already set",_idd,_elements,GVAR(elementsSet)); }; @@ -33,6 +35,7 @@ if (_set) then { if (_success) then { GVAR(elementsSet) pushBack [_idd, _elements]; + _return = true; }; } else { if ([_idd, _elements] in GVAR(elementsSet)) then { @@ -41,7 +44,9 @@ if (_set) then { private _index = GVAR(elementsSet) find [_idd, _elements]; GVAR(elementsSet) deleteAt _index; + _return = true; }; }; -TRACE_1("Visibility set",GVAR(elementsSet)); +TRACE_2("Visibility set",_return,GVAR(elementsSet)); +_return From 70100825cf23de1ca2d0ef9ffb4528b420fa1994 Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 8 Mar 2016 18:49:19 +0100 Subject: [PATCH 048/215] Fix params in clientInit --- addons/ui/XEH_clientInit.sqf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/ui/XEH_clientInit.sqf b/addons/ui/XEH_clientInit.sqf index 47fb36cb14..97cc3e026b 100644 --- a/addons/ui/XEH_clientInit.sqf +++ b/addons/ui/XEH_clientInit.sqf @@ -29,11 +29,11 @@ if (!hasInterface) exitWith {}; // Selective UI Advanced { - params ["_idd", "_elements", "_name"]; + _x params ["_idd", "_elements", "_elementName"]; - if (_name == _name) then { - [_idd, _elements, _name] call FUNC(setAdvancedElement); - TRACE_2("Setting Changed",_name,_name); + if (_name == _elementName) then { + [_idd, _elements, _elementName] call FUNC(setAdvancedElement); + TRACE_2("Setting Changed",_name,_elementName); }; } forEach ELEMENTS_ADVANCED; }] call EFUNC(common,addEventHandler); From 94adcf4ccbf2842061b2d94829db74ec546dfe40 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 8 Mar 2016 13:17:20 -0600 Subject: [PATCH 049/215] MicroDagr Scalar Values --- addons/microdagr/ACE_Settings.hpp | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/microdagr/ACE_Settings.hpp b/addons/microdagr/ACE_Settings.hpp index 4cf83794dd..637584178c 100644 --- a/addons/microdagr/ACE_Settings.hpp +++ b/addons/microdagr/ACE_Settings.hpp @@ -5,5 +5,6 @@ class ACE_Settings { value = 2; typeName = "SCALAR"; isClientSettable = 0; + values[] = {CSTRING(MapFill_None), CSTRING(MapFill_OnlyRoads), CSTRING(MapFill_Full)}; }; }; From ad3a03a9c77c59c79bbcbd5be363950a4a4b0aa2 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 8 Mar 2016 13:52:34 -0600 Subject: [PATCH 050/215] versioning - Add warnings for missing compat PBOs --- addons/main/CfgDependencies.hpp | 23 +++++++++++++++++++++++ addons/main/config.cpp | 14 +------------- 2 files changed, 24 insertions(+), 13 deletions(-) create mode 100644 addons/main/CfgDependencies.hpp diff --git a/addons/main/CfgDependencies.hpp b/addons/main/CfgDependencies.hpp new file mode 100644 index 0000000000..6dd58fb60b --- /dev/null +++ b/addons/main/CfgDependencies.hpp @@ -0,0 +1,23 @@ +class CfgSettings { + class CBA { + class Versioning { + class ACE { + class dependencies { + //ACE will hard exit if this is missing + CBA[] = {"cba_main", REQUIRED_CBA_VERSION, "true"}; + + //Warnings for missing compat pbos + compat_r3f[] = {"ace_compat_r3f", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'R3F_Armes')"}; + compat_rh_acc[] = {"ace_compat_rh_acc", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_acc')"}; + compat_rh_de[] = {"ace_compat_rh_de", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_de_cfg')"}; + compat_rh_m4[] = {"ace_compat_rh_m4", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_m4_cfg')"}; + compat_rh_pdw[] = {"ace_compat_rh_pdw", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_PDW')"}; + compat_rhs_afrf3[] = {"ace_compat_rhs_afrf3", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'rhs_main')"}; + compat_rhs_usf3[] = {"ace_compat_rhs_usf3", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'rhsusf_main')"}; + compat_rksl_pm_ii[] = {"ace_compat_rksl_pm_ii", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RKSL_PMII')"}; + compat_sma3_iansky[] = {"ace_compat_sma3_iansky", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'iansky_opt')"}; + }; + }; + }; + }; +}; diff --git a/addons/main/config.cpp b/addons/main/config.cpp index 5f34c6137d..3181df1dea 100644 --- a/addons/main/config.cpp +++ b/addons/main/config.cpp @@ -586,18 +586,6 @@ class CfgMods { }; }; +#include "CfgDependencies.hpp" #include "CfgModuleCategories.hpp" #include "CfgVehicleClasses.hpp" - -class CfgSettings { - class CBA { - class Versioning { - class ACE { - class dependencies { - CBA[] = {"cba_main", REQUIRED_CBA_VERSION, "true"}; - }; - }; - }; - }; -}; - From 32c32b6cc556385d4854440b9f805e51e8ee30d3 Mon Sep 17 00:00:00 2001 From: jonpas Date: Wed, 9 Mar 2016 18:58:46 +0100 Subject: [PATCH 051/215] Add stamina bar selective UI --- addons/ui/ACE_Settings.hpp | 9 +++++++++ addons/ui/CfgVehicles.hpp | 8 ++++++++ addons/ui/functions/fnc_moduleInit.sqf | 1 + addons/ui/script_component.hpp | 6 ++++++ addons/ui/stringtable.xml | 3 +++ 5 files changed, 27 insertions(+) diff --git a/addons/ui/ACE_Settings.hpp b/addons/ui/ACE_Settings.hpp index 3e5c53d328..89ddc8d35d 100644 --- a/addons/ui/ACE_Settings.hpp +++ b/addons/ui/ACE_Settings.hpp @@ -139,6 +139,15 @@ class ACE_Settings { isClientSettable = 1; }; + // Stamina Bar + class GVAR(staminaBar) { + category = CSTRING(Category); + displayName = CSTRING(StaminaBar); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + value = 1; + isClientSettable = 1; + }; // Vehicle class GVAR(vehicleName) { diff --git a/addons/ui/CfgVehicles.hpp b/addons/ui/CfgVehicles.hpp index 1441d97217..ccd79684f5 100644 --- a/addons/ui/CfgVehicles.hpp +++ b/addons/ui/CfgVehicles.hpp @@ -115,6 +115,14 @@ class CfgVehicles { defaultValue = 1; }; + // Stamina Bar + class staminaBar { + displayName = CSTRING(StaminaBar); + description = CSTRING(RequiresSoldierVehicleWeaponInfo); + typeName = "BOOL"; + defaultValue = 1; + }; + // Vehicle class vehicleName { displayName = CSTRING(VehicleName); diff --git a/addons/ui/functions/fnc_moduleInit.sqf b/addons/ui/functions/fnc_moduleInit.sqf index 8327b09e72..10f18f94f3 100644 --- a/addons/ui/functions/fnc_moduleInit.sqf +++ b/addons/ui/functions/fnc_moduleInit.sqf @@ -43,6 +43,7 @@ if (isArray (missionConfigFile >> "showHUD")) then { [_logic, QGVAR(zeroing), "zeroing"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(weaponLowerInfoBackground), "weaponLowerInfoBackground"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(stance), "stance"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(staminaBar), "staminaBar"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(vehicleName), "vehicleName"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(vehicleNameBackground), "vehicleNameBackground"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(vehicleFuelBar), "vehicleFuelBar"] call EFUNC(common,readSettingFromModule); diff --git a/addons/ui/script_component.hpp b/addons/ui/script_component.hpp index 14392f5af2..e9051beeac 100644 --- a/addons/ui/script_component.hpp +++ b/addons/ui/script_component.hpp @@ -32,6 +32,7 @@ [300, [151], QGVAR(throwableCount)], \ [300, [1202], QGVAR(weaponLowerInfoBackground)], \ [300, [168], QGVAR(zeroing)], \ + [305, [193], QGVAR(staminaBar)], \ [303, [188, 1201], QGVAR(stance)], \ [300, [120], QGVAR(vehicleName)], \ [300, [1000, 1013], QGVAR(vehicleNameBackground)], \ @@ -86,4 +87,9 @@ RscStanceInfo = 303 -------------------- 188 (Stance) + 1201 (Stance Background) + + +RscStaminaBar = 305 +-------------------- +193 (Stamina Bar) */ diff --git a/addons/ui/stringtable.xml b/addons/ui/stringtable.xml index 21932cb98e..42e7932411 100644 --- a/addons/ui/stringtable.xml +++ b/addons/ui/stringtable.xml @@ -64,6 +64,9 @@ Stance + + Stamina Bar + Vehicle Name From aad79eda853e01c698189829ffb19c84bdaf8316 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sat, 12 Mar 2016 10:06:45 -0300 Subject: [PATCH 052/215] The dead shouldn't interact (it's not TWD) --- addons/common/XEH_postInit.sqf | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index b17ff292a4..8eeed526f5 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -444,6 +444,11 @@ if (!isNil QGVAR(PreInit_playerChanged_PFHID)) then { // Add various canInteractWith conditions ////////////////////////////////////////////////// +["isNotDead", { + params ["_unit", "_target"]; + alive _unit +}] call FUNC(addCanInteractWithCondition); + ["notOnMap", {!visibleMap}] call FUNC(addCanInteractWithCondition); ["isNotInside", { From fca8b51bb2376ebdc8f754d6fd6362e922ebdfda Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 12 Jan 2016 19:32:26 +0100 Subject: [PATCH 053/215] reset interaction menu time variables on save game load --- addons/interact_menu/XEH_preInit.sqf | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/addons/interact_menu/XEH_preInit.sqf b/addons/interact_menu/XEH_preInit.sqf index 791402cd01..fae8843a4e 100644 --- a/addons/interact_menu/XEH_preInit.sqf +++ b/addons/interact_menu/XEH_preInit.sqf @@ -45,6 +45,13 @@ GVAR(expanded) = false; GVAR(startHoverTime) = ACE_diagTime; GVAR(expandedTime) = ACE_diagTime; + +// reset on mission load +addMissionEventHandler ["Loaded", { + GVAR(startHoverTime) = 0; + GVAR(expandedTime) = 0; +}]; + GVAR(iconCtrls) = []; GVAR(iconCount) = 0; From 61f1959109a97b150065a5515aa164ba63c851f5 Mon Sep 17 00:00:00 2001 From: Thomas Kooi Date: Sat, 12 Mar 2016 18:55:42 +0100 Subject: [PATCH 054/215] Fix morphine increasing viscosity Morphine should decrease viscosity instead of increase. Closes #3579 --- addons/medical/ACE_Medical_Treatments.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/ACE_Medical_Treatments.hpp b/addons/medical/ACE_Medical_Treatments.hpp index 47d78d23e1..14205fbd30 100644 --- a/addons/medical/ACE_Medical_Treatments.hpp +++ b/addons/medical/ACE_Medical_Treatments.hpp @@ -1366,7 +1366,7 @@ class ACE_Medical_Advanced { timeInSystem = 900; maxDose = 4; inCompatableMedication[] = {}; - viscosityChange = 10; + viscosityChange = -10; }; class Epinephrine { painReduce = 0; From 1985e7e20ae94e08b9c59cb7f79a40b6ea0f9397 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 12 Mar 2016 13:42:52 -0600 Subject: [PATCH 055/215] Fix versioning true when compiled --- addons/main/config.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/main/config.cpp b/addons/main/config.cpp index 5f34c6137d..1326014f45 100644 --- a/addons/main/config.cpp +++ b/addons/main/config.cpp @@ -594,7 +594,7 @@ class CfgSettings { class Versioning { class ACE { class dependencies { - CBA[] = {"cba_main", REQUIRED_CBA_VERSION, "true"}; + CBA[] = {"cba_main", REQUIRED_CBA_VERSION, "(true)"}; }; }; }; From 32846014a1b72a115805c488ebe7fb9e2effde1a Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Mon, 14 Mar 2016 14:21:02 +0100 Subject: [PATCH 056/215] fix ammo handling init on dedicated --- addons/mk6mortar/XEH_postInit.sqf | 2 ++ .../fnc_handlePlayerVehicleChanged.sqf | 29 +++++++++---------- addons/mk6mortar/functions/fnc_mortarInit.sqf | 13 +++++---- 3 files changed, 23 insertions(+), 21 deletions(-) diff --git a/addons/mk6mortar/XEH_postInit.sqf b/addons/mk6mortar/XEH_postInit.sqf index 5c82d55f50..9c098b8cdd 100644 --- a/addons/mk6mortar/XEH_postInit.sqf +++ b/addons/mk6mortar/XEH_postInit.sqf @@ -15,6 +15,8 @@ _static setMagazineTurretAmmo [_magazine, _ammoCount, [0]]; }] call EFUNC(common,addEventHandler); +["initMortar", {_this call FUNC(mortarInit);}] call EFUNC(common,addEventHandler); + if (!hasInterface) exitWith {}; ["playerVehicleChanged", {_this call FUNC(handlePlayerVehicleChanged);}] call EFUNC(common,addEventHandler); diff --git a/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf b/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf index 02049289aa..2d921973d4 100644 --- a/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf +++ b/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf @@ -16,31 +16,30 @@ */ #include "script_component.hpp" -PARAMS_2(_player,_newVehicle); - -private["_tubeWeaponName" ,"_fireModes", "_lastFireMode"]; +params ["_player", "_newVehicle"]; if (isNull _newVehicle) exitWith {}; if (!(_newVehicle isKindOf "Mortar_01_base_F")) exitWith {}; // Run magazine handling initialization if enabled -if (!EGVAR(common,settingsInitFinished)) then { - EGVAR(common,runAtSettingsInitialized) pushBack [{ - if (GVAR(useAmmoHandling) && {!(_this getVariable [QGVAR(initialized),false]) && !(_this getVariable [QGVAR(exclude),false])}) then { - _this call FUNC(mortarInit); +if (!(_newVehicle getVariable [QGVAR(initialized),false]) && !(_newVehicle getVariable [QGVAR(exclude),false])) then { + // Make sure that mortar init is executed after settings init + [{ + params ["_mortar"]; + if (GVAR(useAmmoHandling) && {!(_mortar getVariable [QGVAR(initialized),false]) && !(_mortar getVariable [QGVAR(exclude),false])}) then { + //wait for proper turret locality change + [{ + ["initMortar", [_this], [_this]] call EFUNC(common,globalEvent); + }, _mortar, 0.05] call EFUNC(common,waitAndExecute); }; - }, _newVehicle]; -} else { - if (GVAR(useAmmoHandling) && {!(_newVehicle getVariable [QGVAR(initialized),false]) && !(_newVehicle getVariable [QGVAR(exclude),false])}) then { - _newVehicle call FUNC(mortarInit); - }; + }, _newVehicle] call EFUNC(common,runAfterSettingsInit); }; -_tubeWeaponName = (weapons _newVehicle) select 0; -_fireModes = getArray (configFile >> "CfgWeapons" >> _tubeWeaponName >> "modes"); +private _tubeWeaponName = (weapons _newVehicle) select 0; +private _fireModes = getArray (configFile >> "CfgWeapons" >> _tubeWeaponName >> "modes"); //Restore last firemode: -_lastFireMode = _newVehicle getVariable [QGVAR(lastFireMode), -1]; +private _lastFireMode = _newVehicle getVariable [QGVAR(lastFireMode), -1]; if (_lastFireMode != -1) then { _player action ["SwitchWeapon", _newVehicle, _player, _lastFireMode]; }; diff --git a/addons/mk6mortar/functions/fnc_mortarInit.sqf b/addons/mk6mortar/functions/fnc_mortarInit.sqf index 7c74cb8249..68c9eab91e 100644 --- a/addons/mk6mortar/functions/fnc_mortarInit.sqf +++ b/addons/mk6mortar/functions/fnc_mortarInit.sqf @@ -18,27 +18,28 @@ params ["_mortar"]; if (_mortar getVariable [QGVAR(initialized),false] || _mortar getVariable [QGVAR(exclude),false]) exitWith {TRACE_1("Exit",_mortar)}; +if (!(_mortar turretLocal [0])) exitWith {TRACE_1("Exit - turret not local",_mortar)}; -// Remove all magazines +// Remove all magazines from turret if (count magazines _mortar > 0) then { { - [QGVAR(removeMagazine), [_mortar, _x]] call EFUNC(common,globalEvent); + _mortar removeMagazineTurret [_x,[0]]; } forEach magazines _mortar; }; -// Replace current weapon with ammo handling weapon +// Replace current turret weapon with ammo handling weapon private _currentWeapon = _mortar weaponsTurret [0] select 0; private _newWeapon = ""; -if (_currentWeapon == "mortar_82mm") then { +if (tolower _currentWeapon == "mortar_82mm") then { _newWeapon = "ace_mortar_82mm"; } else { _newWeapon = getText (configFile >> "CfgWeapons" >> _currentWeapon >> QGVAR(replaceWith)); }; if (_newWeapon != "") then { - _mortar removeWeaponGlobal _currentWeapon; - _mortar addWeaponGlobal _newWeapon; + _mortar removeWeaponTurret [_currentWeapon,[0]]; + _mortar addWeaponTurret [_newWeapon,[0]]; }; _mortar setVariable [QGVAR(initialized),true,true]; From 14183470bc65251a4ddf2461c1e80b7ff2c89010 Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Mon, 14 Mar 2016 12:16:23 -0300 Subject: [PATCH 057/215] Revert "Improved rope glitchyness" This reverts commit c65656a016fc377eb03583dcc04d144ff1aa3141. --- addons/fastroping/XEH_postInit.sqf | 5 +++++ addons/fastroping/functions/fnc_cutRopes.sqf | 6 ++---- addons/fastroping/functions/fnc_deployRopes.sqf | 5 ++--- addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf | 1 - addons/fastroping/functions/fnc_fastRopeServerPFH.sqf | 4 ++-- 5 files changed, 11 insertions(+), 10 deletions(-) diff --git a/addons/fastroping/XEH_postInit.sqf b/addons/fastroping/XEH_postInit.sqf index ae88feaa76..873d1091e5 100644 --- a/addons/fastroping/XEH_postInit.sqf +++ b/addons/fastroping/XEH_postInit.sqf @@ -7,3 +7,8 @@ [QGVAR(startFastRope), { [FUNC(fastRopeServerPFH), 0, _this] call CBA_fnc_addPerFrameHandler; }] call EFUNC(common,addEventHandler); + +[QGVAR(ropeDetach), { + params ["_object", "_rope"]; + _object ropeDetach _rope; +}] call EFUNC(common,addEventHandler); diff --git a/addons/fastroping/functions/fnc_cutRopes.sqf b/addons/fastroping/functions/fnc_cutRopes.sqf index 71fe682f7e..88b02a70af 100644 --- a/addons/fastroping/functions/fnc_cutRopes.sqf +++ b/addons/fastroping/functions/fnc_cutRopes.sqf @@ -32,10 +32,8 @@ _deployedRopes = _vehicle getVariable [QGVAR(deployedRopes), []]; }; }; - detach _dummy; - deleteVehicle _ropeTop; - deleteVehicle _hook; - [{{deleteVehicle _x} count _this}, [_ropeBottom, _dummy], 60] call EFUNC(common,waitAndExecute); + [QGVAR(ropeDetach), [_hook, _ropeTop]] call EFUNC(common,serverEvent); + [{{deleteVehicle _x} count _this}, [_ropeTop, _ropeBottom, _dummy, _hook], 60] call EFUNC(common,waitAndExecute); } count _deployedRopes; _vehicle setVariable [QGVAR(deployedRopes), [], true]; diff --git a/addons/fastroping/functions/fnc_deployRopes.sqf b/addons/fastroping/functions/fnc_deployRopes.sqf index af79dd2cfe..c944b2c3cb 100644 --- a/addons/fastroping/functions/fnc_deployRopes.sqf +++ b/addons/fastroping/functions/fnc_deployRopes.sqf @@ -35,14 +35,13 @@ _hookAttachment = _vehicle getVariable [QGVAR(FRIES), _vehicle]; _origin = getPosATL _hook; - _dummy = createVehicle [QGVAR(helper), _origin, [], 0, "CAN_COLLIDE"]; + _dummy = createVehicle [QGVAR(helper), _origin vectorAdd [0, 0, -1], [], 0, "CAN_COLLIDE"]; _dummy allowDamage false; _dummy disableCollisionWith _vehicle; - _dummy attachTo [_hook, [0, 0, 0]]; _ropeTop = ropeCreate [_dummy, [0, 0, 0], _hook, [0, 0, 0], 0.5]; _ropeBottom = ropeCreate [_dummy, [0, 0, 0], 1]; - ropeUnwind [_ropeBottom, 30, 35, false]; + ropeUnwind [_ropeBottom, 30, 34.5, false]; _ropeTop addEventHandler ["RopeBreak", {[_this, "top"] call FUNC(onRopeBreak)}]; _ropeBottom addEventHandler ["RopeBreak", {[_this, "bottom"] call FUNC(onRopeBreak)}]; diff --git a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf index 6a4e810ff5..d05c8bfdbc 100644 --- a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf @@ -26,7 +26,6 @@ if (vehicle _unit != _unit) exitWith {}; //Start fast roping if (animationState _unit != "ACE_FastRoping") exitWith { - detach _dummy; _unit disableCollisionWith _dummy; _unit attachTo [_dummy, [0, 0, -1.45]]; [_unit, "ACE_FastRoping", 2] call EFUNC(common,doAnimation); diff --git a/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf b/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf index 627ed959bc..44f9fedd1a 100644 --- a/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf @@ -54,14 +54,14 @@ if (((getPos _unit select 2) < 0.2) || {ropeLength _ropeTop == 34.5} || {vectorM deleteVehicle _ropeBottom; _origin = getPosASL _hook; - _dummy attachTo [_hook, [0, 0, 0]]; + _dummy setPosASL (_origin vectorAdd [0, 0, -1]); //Restore original mass and center of mass _dummy setMass 40; _dummy setCenterOfMass [0.000143227,0.00105986,-0.246147]; _ropeTop = ropeCreate [_dummy, [0, 0, 0], _hook, [0, 0, 0], 0.5]; - _ropeBottom = ropeCreate [_dummy, [0, 0, 0], 35]; + _ropeBottom = ropeCreate [_dummy, [0, 0, 0], 34.5]; _ropeTop addEventHandler ["RopeBreak", {[_this, "top"] call FUNC(onRopeBreak)}]; _ropeBottom addEventHandler ["RopeBreak", {[_this, "bottom"] call FUNC(onRopeBreak)}]; From 89924e927a53520c643402d5b73f09ce803623ad Mon Sep 17 00:00:00 2001 From: jonpas Date: Mon, 14 Mar 2016 17:25:20 +0100 Subject: [PATCH 058/215] Disable debug --- addons/ui/script_component.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/ui/script_component.hpp b/addons/ui/script_component.hpp index e9051beeac..a7410a49b8 100644 --- a/addons/ui/script_component.hpp +++ b/addons/ui/script_component.hpp @@ -1,8 +1,8 @@ #define COMPONENT ui #include "\z\ace\addons\main\script_mod.hpp" - #define DEBUG_MODE_FULL - #define DISABLE_COMPILE_CACHE +// #define DEBUG_MODE_FULL +// #define DISABLE_COMPILE_CACHE // #define CBA_DEBUG_SYNCHRONOUS // #define ENABLE_PERFORMANCE_COUNTERS From c568c18865102bf28cdada9b13f472995a859e51 Mon Sep 17 00:00:00 2001 From: jonpas Date: Mon, 14 Mar 2016 19:14:52 +0100 Subject: [PATCH 059/215] Add module icon --- addons/ui/CfgVehicles.hpp | 2 +- addons/ui/README.md | 4 ++-- addons/ui/UI/Icon_Module_UI_ca.paa | Bin 0 -> 5625 bytes .../Icon_Module_png/Icon_Module_UI_ca.png | Bin 0 -> 2999 bytes extras/assets/icons/Icons_Modules.psd | Bin 2357207 -> 2371272 bytes 5 files changed, 3 insertions(+), 3 deletions(-) create mode 100644 addons/ui/UI/Icon_Module_UI_ca.paa create mode 100644 extras/assets/icons/Icon_Module_png/Icon_Module_UI_ca.png diff --git a/addons/ui/CfgVehicles.hpp b/addons/ui/CfgVehicles.hpp index ccd79684f5..24340db031 100644 --- a/addons/ui/CfgVehicles.hpp +++ b/addons/ui/CfgVehicles.hpp @@ -7,7 +7,7 @@ class CfgVehicles { function = QFUNC(moduleInit); scope = 2; isGlobal = 1; - //icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); + icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); class Arguments { // BASIC class allowSelectiveUI { diff --git a/addons/ui/README.md b/addons/ui/README.md index 7fac3a4946..c55ffbc5c7 100644 --- a/addons/ui/README.md +++ b/addons/ui/README.md @@ -1,7 +1,7 @@ ace_ui ======= -Removes vignette, changes the chat contrast on the map to allow easier reading and provides settings to toggle different UI elements unavailable in Vanilla. +Removes vignette, changes the chat contrast on the map to allow easier reading and provides settings to hide or show different UI elements. ## Maintainers @@ -9,4 +9,4 @@ Removes vignette, changes the chat contrast on the map to allow easier reading a The people responsible for merging changes to this component or answering potential questions. - [VKing](https://github.com/VKing6) -- [Jonpas] (https://github.com/jonpas) +- [Jonpas](https://github.com/jonpas) diff --git a/addons/ui/UI/Icon_Module_UI_ca.paa b/addons/ui/UI/Icon_Module_UI_ca.paa new file mode 100644 index 0000000000000000000000000000000000000000..f23b8b40c9eaa9a2aedc73f5de9adfb4e42814a7 GIT binary patch literal 5625 zcmeHLPe>F|82?r_Rxc${AxJsO(jn~HDcH9Jt}BIyLhKT$$CB{k(S0Rkfz+@ObV$5+ z5)TWVW}=gax)#|%DCoLbU=C^H!4=k z(17sQpJHvqZpjNkbmZ|i@}SG5+u&WcAH~W1@I6Z(xcPE5hO=ci+f09||Hu&cCn-O! zPgLWW`47r2Xy=aciN;eh8~EinEob6h)L z$k75b`~QCa(SNka#1F8z(r~N#SNV_2!<5D3x5N}cJ3d(a!%@8xl`c!3i}l|$zKYxC zr+=FBr{|06C9C*MB(C=fMk2}?msZTCX@mI52 z-_Gmp{fFdNjeVS-%in9<7(lE?Ym#fkZymahXwcfbM2g7mQAD)ra8?LrKby&Ch^ zaF9g#)~D$qwvN#tb8{P+qZ={$vAP)xVHB-4mtLhF*AJUP3;no0HfH#-NNqFH95cut zSomr5qrJ;{>$OD4%5%TAWZGEB+ElNFK^9#5HHNQG;@la>lAol<^((q{>2;0U^*^j%loPGT=CCk+@KbwgLm$YpVs2o*9wdIo zAz^rteVop5H+~AlkBkBfXkv78LNAlvR%Ll>rl7GSE35srCxaRzf8YA(abvdd?`EJp zX~N+6GXv%FK#%5k{I#=)g~r0inPKshsdO2-eEhWs?+BOXKI5&i;*R)3x2!Sbcn@C& z_v^$ShQV=5eOnj48_fATp_4v~eiROMjz4=dH#@Sb@oj(c c&HD%EM>NjjM8$ZDm9-bsHx^Inzm>JW0G*1dMgRZ+ literal 0 HcmV?d00001 diff --git a/extras/assets/icons/Icon_Module_png/Icon_Module_UI_ca.png b/extras/assets/icons/Icon_Module_png/Icon_Module_UI_ca.png new file mode 100644 index 0000000000000000000000000000000000000000..e69102a216a99605b99cecef622f09bc0f1afb14 GIT binary patch literal 2999 zcmV;o3rO^dP)KLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ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)jCVEY4fnLGNg2A-`YwHVD3gv};>)hAvT~AmqS>Lr``i7kw zJ{5_It`yrBmlc25DBO7E8;5VoznR>Ww5hAaxn$2~(q`%A-YuS64wkBy=9dm`4cXeX z4c}I@?e+FW+b@^RDBHV(wnMq2zdX3SWv9u`%{xC-q*U}&`cyXV(%rRT*Z6MH?i+i& z_B8C(+grT%{XWUQ+f@NoP1R=AW&26{v-dx)iK^-Nmiuj8txj!m?Z*Ss1N{dh4z}01 z)YTo*JycSU)+_5r4#yw9{+;i4Ee$peRgIj+;v;ZGdF1K$3E%e~4LaI(jC-u%2h$&R z9cLXcYC@Xwnns&bn)_Q~Te?roKGD|d-g^8;+aC{{G(1^(O7m37Y1-+6)01cN&y1aw zoqc{T`P^XJqPBbIW6s}d4{z_f5Om?vMgNQEJG?v2T=KYd^0M3I6IZxbny)%vZR&LD zJpPl@Psh8QyPB@KTx+@RdcC!KX7}kEo;S|j^u2lU7XQ}Oo;f|;z4Ll+_r>@1-xl3| zawq-H%e&ckC+@AhPrP6BKT#_XdT7&;F71j}Joy zkC~6lh7E@6o;W@^IpRNZ{ptLtL(gQ-CY~4mqW;US7Zxvm_|@yz&e53Bp_lTPlfP|z zrTyx_>lv@x#=^!PzR7qqF<$gm`|ZJZ+;<)Cqu&ot2z=0000WV@Og>004R=004l4008;_004mL004C`008P>0026e000+nl3&F} z0002uNkl^9t6u{dZdFP)c0sznh!XtSv$Tkrm0)?hQD&WI)K>G-Ib$K%l(gOeh;BRAz zzavHk002O-g^;NL003y+14IP?06^;=u<9CI!Q0OK4ix|Z00000000000000000000 z006K9z?0vX0f@e>u9G6*%x8a$JugW)>)DU2fU-}Qu0+{Yb%2?J&`CW&FSDN_HY=N8 tiRqD*V0Qpsk|F{C^d3I|009600|4I#8k=$v3e^Ar002ovPDHLkV1l;Pfg1n- literal 0 HcmV?d00001 diff --git a/extras/assets/icons/Icons_Modules.psd b/extras/assets/icons/Icons_Modules.psd index 553449898aaed4cb6dce26e0cbd677c500206448..0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ace usage of filter to select in tagging --- addons/tagging/functions/fnc_tagTestingThread.sqf | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/addons/tagging/functions/fnc_tagTestingThread.sqf b/addons/tagging/functions/fnc_tagTestingThread.sqf index 18d14e2e4f..a904587f8a 100644 --- a/addons/tagging/functions/fnc_tagTestingThread.sqf +++ b/addons/tagging/functions/fnc_tagTestingThread.sqf @@ -16,7 +16,7 @@ #include "script_component.hpp" -_fnc_isLeaning = { +GVAR(tagsToTest) = GVAR(tagsToTest) select { params ["_tag", "_tagPosASL", "_vectorDirAndUp"]; _vectorDirAndUp params ["_v1", "_v2"]; @@ -34,7 +34,6 @@ _fnc_isLeaning = { }; true }; -GVAR(tagsToTest) = [GVAR(tagsToTest), _fnc_isLeaning] call EFUNC(common,filter); // If there's no more tag if (GVAR(tagsToTest) isEqualTo []) exitWith { From 485900dce8bba0bd80811e95cf300cb43f61c423 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Wed, 16 Mar 2016 22:59:28 +0100 Subject: [PATCH 061/215] increment patch version --- README.md | 2 +- addons/main/script_mod.hpp | 2 +- docs/README_DE.md | 2 +- docs/README_PL.md | 2 +- mod.cpp | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 3de005ce29..3ead78c57f 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@

- ACE3 Version + ACE3 Version ACE3 Issues diff --git a/addons/main/script_mod.hpp b/addons/main/script_mod.hpp index dd2cef0204..1f86448c94 100644 --- a/addons/main/script_mod.hpp +++ b/addons/main/script_mod.hpp @@ -5,7 +5,7 @@ #define MAJOR 3 #define MINOR 5 -#define PATCHLVL 0 +#define PATCHLVL 1 #define BUILD 0 #define VERSION MAJOR.MINOR.PATCHLVL.BUILD diff --git a/docs/README_DE.md b/docs/README_DE.md index 0f9ca83536..95a7b3c406 100644 --- a/docs/README_DE.md +++ b/docs/README_DE.md @@ -4,7 +4,7 @@

- ACE3 Version + ACE3 Version ACE3 Fehlermeldungen diff --git a/docs/README_PL.md b/docs/README_PL.md index f8ff8683e5..87884e3a68 100644 --- a/docs/README_PL.md +++ b/docs/README_PL.md @@ -3,7 +3,7 @@

- ACE3 Wersja + ACE3 Wersja ACE3 Zagadnienia diff --git a/mod.cpp b/mod.cpp index b146f500b0..a0ee3b211e 100644 --- a/mod.cpp +++ b/mod.cpp @@ -1,8 +1,8 @@ -name = "Advanced Combat Environment 3.5.0"; +name = "Advanced Combat Environment 3.5.1"; picture = "logo_ace3_ca.paa"; actionName = "GitHub"; action = "https://github.com/acemod/ACE3"; -description = "ACE3 - Version 3.5.0"; +description = "ACE3 - Version 3.5.1"; logo = "logo_ace3_ca.paa"; logoOver = "logo_ace3_ca.paa"; tooltip = "ACE3"; From 218d333738531a778d249a91afdc5ff74aeefaef Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 17 Mar 2016 11:56:20 -0500 Subject: [PATCH 062/215] Fix nametag error when rank is empty string --- addons/nametags/functions/fnc_drawNameTagIcon.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/nametags/functions/fnc_drawNameTagIcon.sqf b/addons/nametags/functions/fnc_drawNameTagIcon.sqf index c564e6e90f..95c3f5228b 100644 --- a/addons/nametags/functions/fnc_drawNameTagIcon.sqf +++ b/addons/nametags/functions/fnc_drawNameTagIcon.sqf @@ -36,7 +36,7 @@ _fnc_parameters = { _icon = format [QUOTE(PATHTOF(UI\soundwave%1.paa)), floor random 10]; _size = 1; } else { - if (_drawRank) then { + if (_drawRank && {rank _target != ""}) then { _icon = format["\A3\Ui_f\data\GUI\Cfg\Ranks\%1_gs.paa", toLower rank _target]; _size = 1; }; From b25ffdb54febee9698d10253ef8a4562588afc3f Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Fri, 18 Mar 2016 00:15:57 +0100 Subject: [PATCH 063/215] Fixed network race condition --- addons/fastroping/functions/fnc_fastRopeServerPFH.sqf | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf b/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf index 44f9fedd1a..ed78d43592 100644 --- a/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf @@ -25,7 +25,7 @@ private ["_vectorUp", "_vectorDir", "_origin"]; if (vehicle _unit != _unit) exitWith {}; //Start fast roping -if (animationState _unit != "ACE_FastRoping") exitWith { +if (getMass _dummy != 80) exitWith { //Fix for twitchyness _dummy setMass 80; _dummy setCenterOfMass [0, 0, -2]; @@ -38,7 +38,9 @@ if (animationState _unit != "ACE_FastRoping") exitWith { }; //Check if rope broke and unit is falling -if (isNull attachedTo _unit) exitWith { +//Make sure this isn't executed before the unit is actually fastroping +//Note: Stretching ropes does not change ropeLength +if ((isNull attachedTo _unit) && {ropeLength _ropeTop > 0.5}) exitWith { [_pfhHandle] call CBA_fnc_removePerFrameHandler; }; From fc067822561c1b3f52d5fe008d98d724f81168f3 Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Fri, 18 Mar 2016 00:16:31 +0100 Subject: [PATCH 064/215] Fixed broken ropeDetach --- addons/fastroping/XEH_postInit.sqf | 5 ----- addons/fastroping/functions/fnc_cutRopes.sqf | 7 +++++-- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/addons/fastroping/XEH_postInit.sqf b/addons/fastroping/XEH_postInit.sqf index 873d1091e5..ae88feaa76 100644 --- a/addons/fastroping/XEH_postInit.sqf +++ b/addons/fastroping/XEH_postInit.sqf @@ -7,8 +7,3 @@ [QGVAR(startFastRope), { [FUNC(fastRopeServerPFH), 0, _this] call CBA_fnc_addPerFrameHandler; }] call EFUNC(common,addEventHandler); - -[QGVAR(ropeDetach), { - params ["_object", "_rope"]; - _object ropeDetach _rope; -}] call EFUNC(common,addEventHandler); diff --git a/addons/fastroping/functions/fnc_cutRopes.sqf b/addons/fastroping/functions/fnc_cutRopes.sqf index 88b02a70af..dcabda56ba 100644 --- a/addons/fastroping/functions/fnc_cutRopes.sqf +++ b/addons/fastroping/functions/fnc_cutRopes.sqf @@ -32,8 +32,11 @@ _deployedRopes = _vehicle getVariable [QGVAR(deployedRopes), []]; }; }; - [QGVAR(ropeDetach), [_hook, _ropeTop]] call EFUNC(common,serverEvent); - [{{deleteVehicle _x} count _this}, [_ropeTop, _ropeBottom, _dummy, _hook], 60] call EFUNC(common,waitAndExecute); + //Destroy rope + //Only delete the hook first so the rope falls down. + //Note: ropeDetach was used here before, but the command seems a bit broken. + deleteVehicle _hook; + [{{deleteVehicle _x} count _this}, [_ropeTop, _ropeBottom, _dummy], 60] call EFUNC(common,waitAndExecute); } count _deployedRopes; _vehicle setVariable [QGVAR(deployedRopes), [], true]; From 0fc7525cbd0e87ef2fbd388d0281a735242dbdcb Mon Sep 17 00:00:00 2001 From: bux578 Date: Fri, 18 Mar 2016 09:27:06 +0100 Subject: [PATCH 065/215] Update CONTRIBUTING.md --- .github/CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 8eb5664cf5..b8aae89b77 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -24,6 +24,6 @@ ACE2, AGM and CSE had a lot of features implemented or planned. All of them are Please refrain from making requests for any planned or existing features from either ACE2, AGM or CSE. Most of them are already being or have been considered for porting or a rewrite. ## Requesting a feature -In order to avoid duplicates and keep the issue tracker organized, we have created a common issue for [ACE3 Feature requests](https://github.com/acemod/ACE3/issues/414). Any and all relevant requests should be submitted there, where they will also get discussed and evaluated. Before adding a new one, make sure to check the previous entries from the thread and do a quick search for similar suggestions; please don't reiterate requests for features that had already been accepted for inclusion, or those which were disregarded earlier. +In order to avoid duplicates and keep the issue tracker organized, we have created a common issue for [ACE3 Feature requests](https://github.com/acemod/ACE3/issues/3594). Any and all relevant requests should be submitted there, where they will also get discussed and evaluated. Before adding a new one, make sure to check the previous entries from the thread and do a quick search for similar suggestions; please don't reiterate requests for features that had already been accepted for inclusion, or those which were disregarded earlier. Following their approval, feature requests may be moved by moderators to a separate issue for further discussion. From 8555f00889e54cc5c855375bd35cd78e97f59c62 Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Fri, 18 Mar 2016 17:26:37 +0100 Subject: [PATCH 066/215] remove needless tolower from mortarinit --- addons/mk6mortar/functions/fnc_mortarInit.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/mk6mortar/functions/fnc_mortarInit.sqf b/addons/mk6mortar/functions/fnc_mortarInit.sqf index 68c9eab91e..65d0ff74db 100644 --- a/addons/mk6mortar/functions/fnc_mortarInit.sqf +++ b/addons/mk6mortar/functions/fnc_mortarInit.sqf @@ -31,7 +31,7 @@ if (count magazines _mortar > 0) then { private _currentWeapon = _mortar weaponsTurret [0] select 0; private _newWeapon = ""; -if (tolower _currentWeapon == "mortar_82mm") then { +if (_currentWeapon == "mortar_82mm") then { _newWeapon = "ace_mortar_82mm"; } else { _newWeapon = getText (configFile >> "CfgWeapons" >> _currentWeapon >> QGVAR(replaceWith)); From a841839aa60af15b47f49c006ad199c9a60dc5e4 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 19 Mar 2016 19:37:26 +0100 Subject: [PATCH 067/215] don't overwrite helicopter sub class self actions --- addons/fastroping/CfgVehicles.hpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/addons/fastroping/CfgVehicles.hpp b/addons/fastroping/CfgVehicles.hpp index 14804d3526..a9f5ebfbad 100644 --- a/addons/fastroping/CfgVehicles.hpp +++ b/addons/fastroping/CfgVehicles.hpp @@ -35,8 +35,8 @@ class CfgVehicles { }; }; - class Helicopter; - class Helicopter_Base_F: Helicopter { + class Air; + class Helicopter: Air { class ACE_SelfActions { class ACE_prepareFRIES { displayName = CSTRING(Interaction_prepareFRIES); @@ -68,6 +68,8 @@ class CfgVehicles { }; }; }; + + class Helicopter_Base_F; class ACE_friesBase: Helicopter_Base_F { destrType = ""; class Turrets {}; From 5aeb19312ba77735f66b93b0f9d3972a1583d411 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sun, 20 Mar 2016 17:09:03 +0100 Subject: [PATCH 068/215] fix script error in tagging --- addons/tagging/functions/fnc_tagTestingThread.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/tagging/functions/fnc_tagTestingThread.sqf b/addons/tagging/functions/fnc_tagTestingThread.sqf index a904587f8a..0e3bb8075d 100644 --- a/addons/tagging/functions/fnc_tagTestingThread.sqf +++ b/addons/tagging/functions/fnc_tagTestingThread.sqf @@ -17,7 +17,7 @@ #include "script_component.hpp" GVAR(tagsToTest) = GVAR(tagsToTest) select { - params ["_tag", "_tagPosASL", "_vectorDirAndUp"]; + _x params ["_tag", "_tagPosASL", "_vectorDirAndUp"]; _vectorDirAndUp params ["_v1", "_v2"]; From ec2920ed353631740cf1a8609805bf64f9da313a Mon Sep 17 00:00:00 2001 From: esteldunedain Date: Sun, 20 Mar 2016 22:24:30 -0300 Subject: [PATCH 069/215] Improve protractor accuracy. Close #3606 --- addons/advanced_ballistics/functions/fnc_displayProtractor.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf b/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf index 5ad6cb111e..8ff21e60cc 100644 --- a/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf +++ b/addons/advanced_ballistics/functions/fnc_displayProtractor.sqf @@ -47,7 +47,7 @@ GVAR(Protractor) = true; __ctrl1 ctrlSetTextColor [1, 1, 1, 1]; __ctrl2 ctrlSetScale 1; - __ctrl2 ctrlSetPosition [SafeZoneX + 0.001, SafeZoneY + 0.001 - 0.0012 * (-58 max (asin((ACE_player weaponDirection currentWeapon ACE_player) select 2)) min 58), 0.2, 0.2 * 4/3]; + __ctrl2 ctrlSetPosition [SafeZoneX + 0.001, SafeZoneY - 0.001 - 0.1074 * (-0.86 max ((ACE_player weaponDirection currentWeapon ACE_player) select 2) min 0.86), 0.2, 0.2 * 4/3]; __ctrl2 ctrlCommit 0; __ctrl2 ctrlSetText QUOTE(PATHTOF(UI\protractor_marker.paa)); __ctrl2 ctrlSetTextColor [1, 1, 1, 1]; From d6e9890b1b612186692c10bb74c24217c9a258ce Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Mon, 21 Mar 2016 18:25:38 +0100 Subject: [PATCH 070/215] Add remove trench and continue digging trench actions --- addons/trenches/CfgVehicles.hpp | 38 +++++++- addons/trenches/XEH_PREP.hpp | 4 + addons/trenches/config.cpp | 1 + .../fnc_canContinueDiggingTrench.sqf | 27 ++++++ .../functions/fnc_canRemoveTrench.sqf | 26 +++++ .../functions/fnc_continueDiggingTrench.sqf | 97 +++++++++++++++++++ .../trenches/functions/fnc_placeConfirm.sqf | 45 +-------- addons/trenches/functions/fnc_placeTrench.sqf | 2 +- .../trenches/functions/fnc_removeTrench.sqf | 92 ++++++++++++++++++ addons/trenches/script_component.hpp | 5 + addons/trenches/stringtable.xml | 12 +++ 11 files changed, 304 insertions(+), 45 deletions(-) create mode 100644 addons/trenches/functions/fnc_canContinueDiggingTrench.sqf create mode 100644 addons/trenches/functions/fnc_canRemoveTrench.sqf create mode 100644 addons/trenches/functions/fnc_continueDiggingTrench.sqf create mode 100644 addons/trenches/functions/fnc_removeTrench.sqf diff --git a/addons/trenches/CfgVehicles.hpp b/addons/trenches/CfgVehicles.hpp index 81880a4265..3123e9270d 100644 --- a/addons/trenches/CfgVehicles.hpp +++ b/addons/trenches/CfgVehicles.hpp @@ -1,3 +1,28 @@ +class CBA_Extended_EventHandlers; + +#define ACE_TRENCHES_ACTIONS class ACE_Actions { \ + class ACE_MainActions { \ + displayName = ECSTRING(interaction,MainAction); \ + selection = ""; \ + distance = 10; \ + condition = QUOTE(true); \ + class ACE_ContinueDiggingTrench { \ + displayName = CSTRING(ContinueDiggingTrench); \ + condition = QUOTE([ARR_2(_target,_player)] call FUNC(canContinueDiggingTrench)); \ + statement = QUOTE([ARR_2(_target,_player)] call FUNC(continueDiggingTrench);); \ + showDisabled = 0; \ + priority = -1; \ + }; \ + class ACE_RemoveTrench { \ + displayName = CSTRING(RemoveEnvelope); \ + condition = QUOTE([ARR_2(_target,_player)] call FUNC(canRemoveTrench)); \ + statement = QUOTE([ARR_2(_target,_player)] call FUNC(removeTrench);); \ + showDisabled = 0; \ + priority = -1; \ + }; \ + }; \ + } + class CfgVehicles { class Man; class CAManBase: Man { @@ -34,6 +59,12 @@ class CfgVehicles { descriptionShort = CSTRING(EnevlopeSmallDescription); model = QUOTE(PATHTOEF(apl,ace_envelope_small4.p3d)); scope = 2; + GVAR(diggingDuration) = 20; + GVAR(removalDuration) = 12; + ACE_TRENCHES_ACTIONS; + class EventHandlers { + class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; + }; }; class ACE_envelope_big: BagFence_base_F { author = ECSTRING(common,ACETeam); @@ -41,9 +72,14 @@ class CfgVehicles { descriptionShort = CSTRING(EnevlopeBigDescription); model = QUOTE(PATHTOEF(apl,ace_envelope_big4.p3d)); scope = 2; + GVAR(diggingDuration) = 25; + GVAR(removalDuration) = 15; + ACE_TRENCHES_ACTIONS; + class EventHandlers { + class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; + }; }; - class ACE_envelope_small_NoGeo: ACE_envelope_small { scope = 1; //@todo: replace by a no geo model diff --git a/addons/trenches/XEH_PREP.hpp b/addons/trenches/XEH_PREP.hpp index a9050b83bd..c0922b786c 100644 --- a/addons/trenches/XEH_PREP.hpp +++ b/addons/trenches/XEH_PREP.hpp @@ -9,3 +9,7 @@ PREP(handleUnconscious); PREP(placeCancel); PREP(placeConfirm); PREP(placeTrench); +PREP(canContinueDiggingTrench); +PREP(canRemoveTrench); +PREP(continueDiggingTrench); +PREP(removeTrench); diff --git a/addons/trenches/config.cpp b/addons/trenches/config.cpp index e2f2b5b4fe..e1b14fa37c 100644 --- a/addons/trenches/config.cpp +++ b/addons/trenches/config.cpp @@ -11,6 +11,7 @@ class CfgPatches { VERSION_CONFIG; }; }; + #include "CfgEventHandlers.hpp" #include "CfgVehicles.hpp" #include "CfgWeapons.hpp" diff --git a/addons/trenches/functions/fnc_canContinueDiggingTrench.sqf b/addons/trenches/functions/fnc_canContinueDiggingTrench.sqf new file mode 100644 index 0000000000..2e1942d6b8 --- /dev/null +++ b/addons/trenches/functions/fnc_canContinueDiggingTrench.sqf @@ -0,0 +1,27 @@ +/* + * Author: SzwedzikPL + * Checks if a unit can continue digging a trench + * + * Arguments: + * 0: trench + * 1: unit + * + * Return Value: + * Can continue + * + * Example: + * [TrenchObj, ACE_player] call ace_trenches_fnc_canContinueDiggingTrench + * + * Public: No + */ +#include "script_component.hpp" + +params ["_trench", "_unit"]; + +if !("ACE_EntrenchingTool" in items _unit) exitWith {false}; +if ((_trench getVariable [QGVAR(progress), 0]) >= 1) exitWith {false}; + +// Prevent removing/digging trench by more than one person +if (_trench getVariable [QGVAR(digging), false]) exitWith {false}; + +true diff --git a/addons/trenches/functions/fnc_canRemoveTrench.sqf b/addons/trenches/functions/fnc_canRemoveTrench.sqf new file mode 100644 index 0000000000..4e33857637 --- /dev/null +++ b/addons/trenches/functions/fnc_canRemoveTrench.sqf @@ -0,0 +1,26 @@ +/* + * Author: SzwedzikPL + * Checks if a unit can remove a trench + * + * Arguments: + * 0: trench + * 1: unit + * + * Return Value: + * Can remove + * + * Example: + * [TrenchObj, ACE_player] call ace_trenches_fnc_canRemoveTrench + * + * Public: No + */ +#include "script_component.hpp" + +params ["_trench", "_unit"]; + +if !("ACE_EntrenchingTool" in items _unit) exitWith {false}; + +// Prevent removing/digging trench by more than one person +if (_trench getVariable [QGVAR(digging), false]) exitWith {false}; + +true diff --git a/addons/trenches/functions/fnc_continueDiggingTrench.sqf b/addons/trenches/functions/fnc_continueDiggingTrench.sqf new file mode 100644 index 0000000000..25f9fc4150 --- /dev/null +++ b/addons/trenches/functions/fnc_continueDiggingTrench.sqf @@ -0,0 +1,97 @@ +/* + * Author: Garth 'L-H' de Wet, Ruthberg, edited by commy2 for better MP and eventual AI support, esteldunedain + * Continue process of digging trench. + * + * Arguments: + * 0: trench + * 1: unit + * + * Return Value: + * None + * + * Example: + * [TrenchObj, ACE_player] call ace_trenches_fnc_continueDiggingTrench + * + * Public: No + */ +#include "script_component.hpp" + +params ["_trench", "_unit"]; +TRACE_2("continueDiggingTrench",_trench,_unit); + +private _actualProgress = _trench getVariable [QGVAR(progress), 0]; +if(_actualProgress == 1) exitWith {}; + +// Mark trench as being worked on +_trench setVariable [QGVAR(digging), true, true]; + +private _digTime = getNumber (configFile >> "CfgVehicles" >> (typeof _trench) >> QGVAR(diggingDuration)); +private _digTimeLeft = _digTime * (1 - _actualProgress); + +private _placeData = _trench getVariable [QGVAR(placeData), [[], []]]; +_placeData params ["_basePos", "_vecDirAndUp"]; + +private _trenchId = _unit getVariable [QGVAR(isDiggingId), -1]; +if(_trenchId < 0) then { + _trenchId = GVAR(trenchId); + _unit setVariable [QGVAR(isDiggingId), _trenchId, true]; + GVAR(trenchId) = GVAR(trenchId) + 1; +}; + +// Create progress bar +private _fnc_onFinish = { + (_this select 0) params ["_unit", "_trench"]; + _unit setVariable [QGVAR(isDiggingId), -1, true]; + _trench setVariable [QGVAR(digging), false, true]; + + // Save progress global + private _progress = _trench getVariable [QGVAR(progress), 0]; + _trench setVariable [QGVAR(progress), _progress, true]; + + // Reset animation + [_unit, "", 1] call EFUNC(common,doAnimation); +}; +private _fnc_onFailure = { + (_this select 0) params ["_unit", "_trench"]; + _unit setVariable [QGVAR(isDiggingId), -1, true]; + _trench setVariable [QGVAR(digging), false, true]; + + // Save progress global + private _progress = _trench getVariable [QGVAR(progress), 0]; + _trench setVariable [QGVAR(progress), _progress, true]; + + // Reset animation + [_unit, "", 1] call EFUNC(common,doAnimation); +}; +[(_digTimeLeft + 0.5), [_unit, _trench], _fnc_onFinish, _fnc_onFailure, localize LSTRING(DiggingTrench)] call EFUNC(common,progressBar); + +// Schedule progressive raising of the trench +private _fnc_setPlacing = { + params ["_unit", "_trench", "_trenchId", "_pos", "_vecDirAndUp", "_progress"]; + + // If the progress bar was cancelled, cancel elevation + // We use an uid to avoid any chance of an older trench being raised when a new one is built + if (_unit getVariable [QGVAR(isDiggingId), -1] != _trenchId) exitWith {}; + + _trench setPosASL _pos; + _trench setVectorDirAndUp _vecDirAndUp; + + // Save progress local + _trench setVariable [QGVAR(progress), _progress]; +}; + +if(_actualProgress == 0) then { + [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 1.0], _vecDirAndUp, _actualProgress] call _fnc_setPlacing; +}; + +private _progressLeft = (_actualProgress * 10) + 1; +private ["_i"]; +for "_i" from _progressLeft to 10 do { + private _vectorDiffZ = 1 - (_i / 10); + private _delay = _digTime * ((_i / 10) - _actualProgress); + private _progress = _i / 10; + [_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, _vectorDiffZ], _vecDirAndUp, _progress], _delay] call EFUNC(common,waitAndExecute); +}; + +// Play animation +[_unit, "AinvPknlMstpSnonWnonDnon_medic4"] call EFUNC(common,doAnimation); diff --git a/addons/trenches/functions/fnc_placeConfirm.sqf b/addons/trenches/functions/fnc_placeConfirm.sqf index 47f80014f8..8a1407d2d6 100644 --- a/addons/trenches/functions/fnc_placeConfirm.sqf +++ b/addons/trenches/functions/fnc_placeConfirm.sqf @@ -66,49 +66,8 @@ for [{_ix = -_dx/2},{_ix <= _dx/2},{_ix = _ix + _dx/3}] do { }; _basePos set [2, (_basePos select 2) + _minzoffset + _offset]; private _vecDirAndUp = [_v1, _v3]; - GVAR(trench) = objNull; -// Mark the unit as digging -private _trenchId = GVAR(trenchId); -_unit setVariable [QGVAR(isDiggingId), _trenchId, true]; -GVAR(trenchId) = GVAR(trenchId) + 1; +_trench setVariable [QGVAR(placeData), [_basePos, _vecDirAndUp], true]; -// Create progress bar -private _fnc_onFinish = { - (_this select 0) params ["_unit"]; - _unit setVariable [QGVAR(isDiggingId), -1, true]; -}; -private _fnc_onFailure = { - (_this select 0) params ["_unit"]; - _unit setVariable [QGVAR(isDiggingId), -1, true]; -}; -[12.5, [_unit], _fnc_onFinish, _fnc_onFailure, localize LSTRING(DiggingTrench)] call EFUNC(common,progressBar); - -// Schedule progressive raising of the trench -private _fnc_setPlacing = { - params ["_unit", "_trench", "_trenchId", "_pos", "_vecDirAndUp"]; - - // If the progress bar was cancelled, cancel elevation - // We use an uid to avoid any chance of an older trench being raised when a new one is built - if (_unit getVariable [QGVAR(isDiggingId), -1] != _trenchId) exitWith {}; - - _trench setPosASL _pos; - _trench setVectorDirAndUp _vecDirAndUp; -}; - -// For loops are for wimps -[_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 1.0], _vecDirAndUp] call _fnc_setPlacing; -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.9], _vecDirAndUp], 3.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.8], _vecDirAndUp], 4.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.7], _vecDirAndUp], 5.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.6], _vecDirAndUp], 6.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.5], _vecDirAndUp], 7.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.4], _vecDirAndUp], 8.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.3], _vecDirAndUp], 9.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.2], _vecDirAndUp],10.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.1], _vecDirAndUp],11.0] call EFUNC(common,waitAndExecute); -[_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 0.0], _vecDirAndUp],12.0] call EFUNC(common,waitAndExecute); - -// Play animation -[_unit, "AinvPknlMstpSnonWnonDnon_medic4"] call EFUNC(common,doAnimation); +[_trench, _unit] call FUNC(continueDiggingTrench); diff --git a/addons/trenches/functions/fnc_placeTrench.sqf b/addons/trenches/functions/fnc_placeTrench.sqf index 48a768427f..b9a8bae52a 100644 --- a/addons/trenches/functions/fnc_placeTrench.sqf +++ b/addons/trenches/functions/fnc_placeTrench.sqf @@ -10,7 +10,7 @@ * None * * Example: - * [ACE_player] call ace_trenches_fnc_placeTrench + * [ACE_player, "ace_trenches_trenchBig"] call ace_trenches_fnc_placeTrench * * Public: No */ diff --git a/addons/trenches/functions/fnc_removeTrench.sqf b/addons/trenches/functions/fnc_removeTrench.sqf new file mode 100644 index 0000000000..1259d8bb9c --- /dev/null +++ b/addons/trenches/functions/fnc_removeTrench.sqf @@ -0,0 +1,92 @@ +/* + * Author: Garth 'L-H' de Wet, Ruthberg, edited by commy2 for better MP and eventual AI support and esteldunedain + * Removes trench + * + * Arguments: + * 0: trench + * 1: unit + * + * Return Value: + * None + * + * Example: + * [TrenchObj, ACE_player] call ace_trenches_fnc_removeTrench + * + * Public: No + */ +#include "script_component.hpp" + +params ["_trench", "_unit"]; +TRACE_2("removeTrench",_trench,_unit); + +private _actualProgress = _trench getVariable [QGVAR(progress), 0]; +if(_actualProgress == 0) exitWith {}; + +// Mark trench as being worked on +_trench setVariable [QGVAR(digging), true, true]; + +private _removeTime = getNumber (configFile >> "CfgVehicles" >> (typeof _trench) >> QGVAR(removalDuration)); +private _removeTimeLeft = _removeTime * _actualProgress; + +private _placeData = _trench getVariable [QGVAR(placeData), [[], []]]; +_placeData params ["_basePos", "_vecDirAndUp"]; + +private _trenchId = _unit getVariable [QGVAR(isDiggingId), -1]; +if(_trenchId < 0) then { + _trenchId = GVAR(trenchId); + _unit setVariable [QGVAR(isDiggingId), _trenchId, true]; + GVAR(trenchId) = GVAR(trenchId) + 1; +}; + +// Create progress bar +private _fnc_onFinish = { + (_this select 0) params ["_unit", "_trench"]; + _unit setVariable [QGVAR(isDiggingId), -1, true]; + + // Remove trench + deleteVehicle _trench; + + // Reset animation + [_unit, "", 1] call EFUNC(common,doAnimation); +}; +private _fnc_onFailure = { + (_this select 0) params ["_unit", "_trench"]; + _unit setVariable [QGVAR(isDiggingId), -1, true]; + _trench setVariable [QGVAR(digging), false, true]; + + // Save progress global + private _progress = _trench getVariable [QGVAR(progress), 0]; + _trench setVariable [QGVAR(progress), _progress, true]; + + // Reset animation + [_unit, "", 1] call EFUNC(common,doAnimation); +}; +[(_removeTimeLeft + 0.5), [_unit, _trench], _fnc_onFinish, _fnc_onFailure, localize LSTRING(RemovingTrench)] call EFUNC(common,progressBar); + +// Schedule progressive raising of the trench +private _fnc_setPlacing = { + params ["_unit", "_trench", "_trenchId", "_pos", "_vecDirAndUp", "_progress"]; + + // If the progress bar was cancelled, cancel elevation + // We use an uid to avoid any chance of an older trench being raised when a new one is built + if (_unit getVariable [QGVAR(isDiggingId), -1] != _trenchId) exitWith {}; + + _trench setPosASL _pos; + _trench setVectorDirAndUp _vecDirAndUp; + + // Save progress local + _trench setVariable [QGVAR(progress), _progress]; +}; + +private _progressLeft = ((1 - _actualProgress) * 10) + 1; +private ["_i"]; +for "_i" from _progressLeft to 10 do { + private _vectorDiffZ = _i / 10; + private _delay = _removeTime * ((_i / 10) - (1 - _actualProgress)); + private _progress = 1 - (_i / 10); + + [_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, _vectorDiffZ], _vecDirAndUp, _progress], _delay] call EFUNC(common,waitAndExecute); +}; + +// Play animation +[_unit, "AinvPknlMstpSnonWnonDnon_medic4"] call EFUNC(common,doAnimation); diff --git a/addons/trenches/script_component.hpp b/addons/trenches/script_component.hpp index 3bb65ab0a6..432308fa51 100644 --- a/addons/trenches/script_component.hpp +++ b/addons/trenches/script_component.hpp @@ -1,6 +1,11 @@ #define COMPONENT trenches #include "\z\ace\addons\main\script_mod.hpp" +// #define DEBUG_MODE_FULL +// #define DISABLE_COMPILE_CACHE +// #define CBA_DEBUG_SYNCHRONOUS +// #define ENABLE_PERFORMANCE_COUNTERS + #ifdef DEBUG_ENABLED_TRENCHES #define DEBUG_MODE_FULL #endif diff --git a/addons/trenches/stringtable.xml b/addons/trenches/stringtable.xml index 617a604457..44c628de69 100644 --- a/addons/trenches/stringtable.xml +++ b/addons/trenches/stringtable.xml @@ -101,5 +101,17 @@ Cavando trinchera Creuse la tranchée + + Continue Digging Trench + Wzów kopanie okopu + + + Remove Trench + Usuń okop + + + Removing Trench + Usuwanie okopu + From 203c059cc1c26723c4a6c44800fbb7bfd271a1c4 Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Tue, 22 Mar 2016 08:10:37 +0100 Subject: [PATCH 071/215] move placement data to config, setTrenchPlacement fnc, cleanup --- addons/trenches/CfgVehicles.hpp | 16 +++++---- addons/trenches/XEH_PREP.hpp | 7 ++-- addons/trenches/XEH_preInit.sqf | 6 ---- .../trenches/functions/fnc_canDigTrench.sqf | 9 ++--- .../functions/fnc_continueDiggingTrench.sqf | 19 ++--------- .../trenches/functions/fnc_placeConfirm.sqf | 4 +-- addons/trenches/functions/fnc_placeTrench.sqf | 22 ++++++++----- .../trenches/functions/fnc_removeTrench.sqf | 17 +--------- .../functions/fnc_setTrenchPlacement.sqf | 33 +++++++++++++++++++ 9 files changed, 67 insertions(+), 66 deletions(-) create mode 100644 addons/trenches/functions/fnc_setTrenchPlacement.sqf diff --git a/addons/trenches/CfgVehicles.hpp b/addons/trenches/CfgVehicles.hpp index 3123e9270d..68f4a7552a 100644 --- a/addons/trenches/CfgVehicles.hpp +++ b/addons/trenches/CfgVehicles.hpp @@ -4,20 +4,18 @@ class CBA_Extended_EventHandlers; class ACE_MainActions { \ displayName = ECSTRING(interaction,MainAction); \ selection = ""; \ - distance = 10; \ + distance = 3; \ condition = QUOTE(true); \ class ACE_ContinueDiggingTrench { \ displayName = CSTRING(ContinueDiggingTrench); \ condition = QUOTE([ARR_2(_target,_player)] call FUNC(canContinueDiggingTrench)); \ statement = QUOTE([ARR_2(_target,_player)] call FUNC(continueDiggingTrench);); \ - showDisabled = 0; \ priority = -1; \ }; \ class ACE_RemoveTrench { \ displayName = CSTRING(RemoveEnvelope); \ condition = QUOTE([ARR_2(_target,_player)] call FUNC(canRemoveTrench)); \ statement = QUOTE([ARR_2(_target,_player)] call FUNC(removeTrench);); \ - showDisabled = 0; \ priority = -1; \ }; \ }; \ @@ -30,9 +28,9 @@ class CfgVehicles { class ACE_Equipment { class GVAR(digEnvelopeSmall) { displayName = CSTRING(DigEnvelopeSmall); - condition = QUOTE([ARR_2(_this select 0,'ace_trenches_trenchSmall')] call FUNC(canDigTrench)); + condition = QUOTE(_player call FUNC(canDigTrench)); //wait a frame to handle "Do When releasing action menu key" option - statement = QUOTE([ARR_2({_this call FUNC(placeTrench)},[ARR_2(_this select 0,'ace_trenches_trenchSmall')])] call EFUNC(common,execNextFrame)); + statement = QUOTE([ARR_2({_this call FUNC(placeTrench)},[ARR_2(_this select 0,'ACE_envelope_small')])] call EFUNC(common,execNextFrame)); exceptions[] = {}; showDisabled = 0; priority = 4; @@ -40,9 +38,9 @@ class CfgVehicles { }; class GVAR(digEnvelopeBig) { displayName = CSTRING(DigEnvelopeBig); - condition = QUOTE([ARR_2(_this select 0,'ace_trenches_trenchBig')] call FUNC(canDigTrench)); + condition = QUOTE(_player call FUNC(canDigTrench)); //wait a frame to handle "Do When releasing action menu key" option - statement = QUOTE([ARR_2({_this call FUNC(placeTrench)},[ARR_2(_this select 0,'ace_trenches_trenchBig')])] call EFUNC(common,execNextFrame)); + statement = QUOTE([ARR_2({_this call FUNC(placeTrench)},[ARR_2(_this select 0,'ACE_envelope_big')])] call EFUNC(common,execNextFrame)); exceptions[] = {}; showDisabled = 0; priority = 4; @@ -61,6 +59,8 @@ class CfgVehicles { scope = 2; GVAR(diggingDuration) = 20; GVAR(removalDuration) = 12; + GVAR(noGeoClass) = "ACE_envelope_small_NoGeo"; + GVAR(placementData)[] = {2,3,0.35}; ACE_TRENCHES_ACTIONS; class EventHandlers { class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; @@ -74,6 +74,8 @@ class CfgVehicles { scope = 2; GVAR(diggingDuration) = 25; GVAR(removalDuration) = 15; + GVAR(noGeoClass) = "ACE_envelope_big_NoGeo"; + GVAR(placementData)[] = {6,1.1,0.20}; ACE_TRENCHES_ACTIONS; class EventHandlers { class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; diff --git a/addons/trenches/XEH_PREP.hpp b/addons/trenches/XEH_PREP.hpp index c0922b786c..2e671acb85 100644 --- a/addons/trenches/XEH_PREP.hpp +++ b/addons/trenches/XEH_PREP.hpp @@ -1,5 +1,8 @@ +PREP(canContinueDiggingTrench); PREP(canDigTrench); +PREP(canRemoveTrench); +PREP(continueDiggingTrench); PREP(handleInteractMenuOpened); PREP(handleKilled); PREP(handlePlayerChanged); @@ -9,7 +12,5 @@ PREP(handleUnconscious); PREP(placeCancel); PREP(placeConfirm); PREP(placeTrench); -PREP(canContinueDiggingTrench); -PREP(canRemoveTrench); -PREP(continueDiggingTrench); PREP(removeTrench); +PREP(setTrenchPlacement); diff --git a/addons/trenches/XEH_preInit.sqf b/addons/trenches/XEH_preInit.sqf index 8b172b2b9e..a7feade1c3 100644 --- a/addons/trenches/XEH_preInit.sqf +++ b/addons/trenches/XEH_preInit.sqf @@ -4,10 +4,4 @@ ADDON = false; #include "XEH_PREP.hpp" -// Trench types -// Name of the object, name of th dummy no geo object, dx, dy -GVAR(trenchSmall) = ["ACE_envelope_small", "ACE_envelope_small_NoGeo", 2, 3, 0.35]; -GVAR(trenchBig) = ["ACE_envelope_big", "ACE_envelope_big_NoGeo", 6, 1.1, 0.20]; -GVAR(trenchType) = GVAR(trenchSmall); - ADDON = true; diff --git a/addons/trenches/functions/fnc_canDigTrench.sqf b/addons/trenches/functions/fnc_canDigTrench.sqf index 9dc5e29017..0cbed2d9b7 100644 --- a/addons/trenches/functions/fnc_canDigTrench.sqf +++ b/addons/trenches/functions/fnc_canDigTrench.sqf @@ -4,7 +4,6 @@ * * Arguments: * 0: Unit - * 1: Trench type * * Return Value: * Can dig @@ -18,17 +17,15 @@ #define SURFACE_BLACKLIST ["water", "concrete", "tarmac", "wood", "metal", "roof_tin", "roof_tiles", "wood_int", "concrete_int", "tiles_int", "metal_int", "stony", "rock", "int_concrete", "int_tiles", "int_wood", "tiling", "wavymetal", "int_metal"] -params ["_unit","_trenchTypeName"]; +params ["_unit"]; if !("ACE_EntrenchingTool" in items _unit) exitWith {false}; // Can't dig trench if above ground level if ((getPosATL _unit) select 2 > 0.05) exitWith {false}; -private ["_surfaceClass", "_surfaceType"]; - -_surfaceClass = (surfaceType getPosASL _unit) select [1]; -_surfaceType = getText (configFile >> "CfgSurfaces" >> _surfaceClass >> "soundEnviron"); +private _surfaceClass = (surfaceType getPosASL _unit) select [1]; +private _surfaceType = getText (configFile >> "CfgSurfaces" >> _surfaceClass >> "soundEnviron"); TRACE_1("",_surfaceType); !(_surfaceType in SURFACE_BLACKLIST) diff --git a/addons/trenches/functions/fnc_continueDiggingTrench.sqf b/addons/trenches/functions/fnc_continueDiggingTrench.sqf index 25f9fc4150..04a2377f21 100644 --- a/addons/trenches/functions/fnc_continueDiggingTrench.sqf +++ b/addons/trenches/functions/fnc_continueDiggingTrench.sqf @@ -65,23 +65,8 @@ private _fnc_onFailure = { }; [(_digTimeLeft + 0.5), [_unit, _trench], _fnc_onFinish, _fnc_onFailure, localize LSTRING(DiggingTrench)] call EFUNC(common,progressBar); -// Schedule progressive raising of the trench -private _fnc_setPlacing = { - params ["_unit", "_trench", "_trenchId", "_pos", "_vecDirAndUp", "_progress"]; - - // If the progress bar was cancelled, cancel elevation - // We use an uid to avoid any chance of an older trench being raised when a new one is built - if (_unit getVariable [QGVAR(isDiggingId), -1] != _trenchId) exitWith {}; - - _trench setPosASL _pos; - _trench setVectorDirAndUp _vecDirAndUp; - - // Save progress local - _trench setVariable [QGVAR(progress), _progress]; -}; - if(_actualProgress == 0) then { - [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 1.0], _vecDirAndUp, _actualProgress] call _fnc_setPlacing; + [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 1.0], _vecDirAndUp, _actualProgress] call FUNC(setTrenchPlacement); }; private _progressLeft = (_actualProgress * 10) + 1; @@ -90,7 +75,7 @@ for "_i" from _progressLeft to 10 do { private _vectorDiffZ = 1 - (_i / 10); private _delay = _digTime * ((_i / 10) - _actualProgress); private _progress = _i / 10; - [_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, _vectorDiffZ], _vecDirAndUp, _progress], _delay] call EFUNC(common,waitAndExecute); + [DFUNC(setTrenchPlacement), [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, _vectorDiffZ], _vecDirAndUp, _progress], _delay] call EFUNC(common,waitAndExecute); }; // Play animation diff --git a/addons/trenches/functions/fnc_placeConfirm.sqf b/addons/trenches/functions/fnc_placeConfirm.sqf index 8a1407d2d6..7c3be2d901 100644 --- a/addons/trenches/functions/fnc_placeConfirm.sqf +++ b/addons/trenches/functions/fnc_placeConfirm.sqf @@ -36,9 +36,9 @@ params ["_unit"]; if (isNull GVAR(trench)) exitWith {}; deleteVehicle GVAR(trench); -private _trench = createVehicle [GVAR(trenchType) select 0, [0, 0, 0], [], 0, "NONE"]; +private _trench = createVehicle [GVAR(trenchClass), [0, 0, 0], [], 0, "NONE"]; -GVAR(trenchType) params ["", "", "_dx", "_dy", "_offset"]; +GVAR(trenchPlacementData) params ["_dx", "_dy", "_offset"]; private _basePos = GVAR(trenchPos); private _angle = (GVAR(digDirection) + getDir _unit); diff --git a/addons/trenches/functions/fnc_placeTrench.sqf b/addons/trenches/functions/fnc_placeTrench.sqf index b9a8bae52a..35a6706d30 100644 --- a/addons/trenches/functions/fnc_placeTrench.sqf +++ b/addons/trenches/functions/fnc_placeTrench.sqf @@ -4,29 +4,34 @@ * * Arguments: * 0: unit - * 1: Trench type + * 1: Trench class * * Return Value: * None * * Example: - * [ACE_player, "ace_trenches_trenchBig"] call ace_trenches_fnc_placeTrench + * [ACE_player, "ACE_envelope_small"] call ace_trenches_fnc_placeTrench * * Public: No */ #include "script_component.hpp" -params ["_unit","_trenchTypeName"]; +params ["_unit", "_trenchClass"]; -GVAR(trenchType) = missionNamespace getVariable _trenchTypeName; +//Load trench data +private _noGeoModel = getText (configFile >> "CfgVehicles" >> _trenchClass >> QGVAR(noGeoClass)); +if(_noGeoModel == "") then {_noGeoModel = _trenchClass;}; + +GVAR(trenchClass) = _trenchClass; +GVAR(trenchPlacementData) = getArray (configFile >> "CfgVehicles" >> _trenchClass >> QGVAR(placementData)); +TRACE_1("",GVAR(trenchPlacementData)); -TRACE_2("",_trenchTypeName,GVAR(trenchType)); // prevent the placing unit from running [_unit, "forceWalk", "ACE_Trenches", true] call EFUNC(common,statusEffect_set); // create the trench private "_trench"; -_trench = createVehicle [GVAR(trenchType) select 1, [0, 0, 0], [], 0, "NONE"]; +_trench = createVehicle [_noGeoModel, [0, 0, 0], [], 0, "NONE"]; GVAR(trench) = _trench; @@ -38,7 +43,6 @@ GVAR(digDirection) = 0; // pfh that runs while the dig is in progress GVAR(digPFH) = [{ (_this select 0) params ["_unit", "_trench"]; - GVAR(trenchType) params ["", "", "_dx", "_dy", "_offset"]; // Cancel if the helper object is gone if (isNull _trench) exitWith { @@ -46,12 +50,12 @@ GVAR(digPFH) = [{ }; // Cancel if the place is no longer suitable - if !([_unit, GVAR(trenchType)] call FUNC(canDigTrench)) exitWith { + if !([_unit] call FUNC(canDigTrench)) exitWith { [_unit] call FUNC(placeCancel); }; // Update trench position - GVAR(trenchType) params ["", "", "_dx", "_dy", "_offset"]; + GVAR(trenchPlacementData) params ["_dx", "_dy", "_offset"]; private _basePos = eyePos _unit vectorAdd ([sin getDir _unit, +cos getDir _unit, 0] vectorMultiply 1.0); private _angle = (GVAR(digDirection) + getDir _unit); diff --git a/addons/trenches/functions/fnc_removeTrench.sqf b/addons/trenches/functions/fnc_removeTrench.sqf index 1259d8bb9c..dd51bbbae5 100644 --- a/addons/trenches/functions/fnc_removeTrench.sqf +++ b/addons/trenches/functions/fnc_removeTrench.sqf @@ -63,21 +63,6 @@ private _fnc_onFailure = { }; [(_removeTimeLeft + 0.5), [_unit, _trench], _fnc_onFinish, _fnc_onFailure, localize LSTRING(RemovingTrench)] call EFUNC(common,progressBar); -// Schedule progressive raising of the trench -private _fnc_setPlacing = { - params ["_unit", "_trench", "_trenchId", "_pos", "_vecDirAndUp", "_progress"]; - - // If the progress bar was cancelled, cancel elevation - // We use an uid to avoid any chance of an older trench being raised when a new one is built - if (_unit getVariable [QGVAR(isDiggingId), -1] != _trenchId) exitWith {}; - - _trench setPosASL _pos; - _trench setVectorDirAndUp _vecDirAndUp; - - // Save progress local - _trench setVariable [QGVAR(progress), _progress]; -}; - private _progressLeft = ((1 - _actualProgress) * 10) + 1; private ["_i"]; for "_i" from _progressLeft to 10 do { @@ -85,7 +70,7 @@ for "_i" from _progressLeft to 10 do { private _delay = _removeTime * ((_i / 10) - (1 - _actualProgress)); private _progress = 1 - (_i / 10); - [_fnc_setPlacing, [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, _vectorDiffZ], _vecDirAndUp, _progress], _delay] call EFUNC(common,waitAndExecute); + [DFUNC(setTrenchPlacement), [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, _vectorDiffZ], _vecDirAndUp, _progress], _delay] call EFUNC(common,waitAndExecute); }; // Play animation diff --git a/addons/trenches/functions/fnc_setTrenchPlacement.sqf b/addons/trenches/functions/fnc_setTrenchPlacement.sqf new file mode 100644 index 0000000000..49c1efdaae --- /dev/null +++ b/addons/trenches/functions/fnc_setTrenchPlacement.sqf @@ -0,0 +1,33 @@ +/* + * Author: Garth 'L-H' de Wet, Ruthberg, edited by commy2 for better MP and eventual AI support and esteldunedain + * Sets trench placement + * + * Arguments: + * 0: unit + * 1: trench + * 2: trench id + * 3: position ASL + * 4: vector dir and up + * 5: progress + * + * Return Value: + * None + * + * Example: + * [ACE_player, TrenchObj, 2, [0,0,0], [[0,0,0],[0,0,0]], 0.5] call ace_trenches_fnc_setTrenchPlacement + * + * Public: No + */ +#include "script_component.hpp" + +params ["_unit", "_trench", "_trenchId", "_pos", "_vecDirAndUp", "_progress"]; + +// If the progress bar was cancelled, cancel elevation +// We use an uid to avoid any chance of an older trench being raised when a new one is built +if (_unit getVariable [QGVAR(isDiggingId), -1] != _trenchId) exitWith {}; + +_trench setPosASL _pos; +_trench setVectorDirAndUp _vecDirAndUp; + +// Save progress local +_trench setVariable [QGVAR(progress), _progress]; From 10d20472d3303cdfb3ff3129bbd79f690567c41e Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Tue, 22 Mar 2016 11:26:40 +0100 Subject: [PATCH 072/215] Remove grass behind the trench --- addons/trenches/CfgVehicles.hpp | 2 ++ addons/trenches/functions/fnc_continueDiggingTrench.sqf | 9 +++++++++ 2 files changed, 11 insertions(+) diff --git a/addons/trenches/CfgVehicles.hpp b/addons/trenches/CfgVehicles.hpp index 68f4a7552a..8e1eb41fd0 100644 --- a/addons/trenches/CfgVehicles.hpp +++ b/addons/trenches/CfgVehicles.hpp @@ -61,6 +61,7 @@ class CfgVehicles { GVAR(removalDuration) = 12; GVAR(noGeoClass) = "ACE_envelope_small_NoGeo"; GVAR(placementData)[] = {2,3,0.35}; + GVAR(grassCuttingPoints)[] = {{0,-0.5,0}}; ACE_TRENCHES_ACTIONS; class EventHandlers { class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; @@ -76,6 +77,7 @@ class CfgVehicles { GVAR(removalDuration) = 15; GVAR(noGeoClass) = "ACE_envelope_big_NoGeo"; GVAR(placementData)[] = {6,1.1,0.20}; + GVAR(grassCuttingPoints)[] = {{-1.5,-1,0},{1.5,-1,0}}; ACE_TRENCHES_ACTIONS; class EventHandlers { class CBA_Extended_EventHandlers: CBA_Extended_EventHandlers {}; diff --git a/addons/trenches/functions/fnc_continueDiggingTrench.sqf b/addons/trenches/functions/fnc_continueDiggingTrench.sqf index 04a2377f21..223dc42df6 100644 --- a/addons/trenches/functions/fnc_continueDiggingTrench.sqf +++ b/addons/trenches/functions/fnc_continueDiggingTrench.sqf @@ -67,6 +67,15 @@ private _fnc_onFailure = { if(_actualProgress == 0) then { [_unit, _trench, _trenchId, _basePos vectorDiff [0, 0, 1.0], _vecDirAndUp, _actualProgress] call FUNC(setTrenchPlacement); + + //Remove grass + { + private _trenchGrassCutter = createVehicle ["Land_ClutterCutter_medium_F", [0, 0, 0], [], 0, "NONE"]; + private _cutterPos = AGLToASL (_trench modelToWorld _x); + _cutterPos set [2, getTerrainHeightASL _cutterPos]; + _trenchGrassCutter setPosASL _cutterPos; + deleteVehicle _trenchGrassCutter; + } foreach getArray (configFile >> "CfgVehicles" >> (typeof _trench) >> QGVAR(grassCuttingPoints)); }; private _progressLeft = (_actualProgress * 10) + 1; From cdcde46a7da6e5a2ff61f5fe7a21fb38e6d178a9 Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Tue, 22 Mar 2016 13:05:47 +0100 Subject: [PATCH 073/215] Fix double displayName in medical settings --- addons/medical/ACE_Settings.hpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/addons/medical/ACE_Settings.hpp b/addons/medical/ACE_Settings.hpp index e029f86d00..a785c2cad5 100644 --- a/addons/medical/ACE_Settings.hpp +++ b/addons/medical/ACE_Settings.hpp @@ -260,7 +260,6 @@ class ACE_Settings { category = CSTRING(Category_Medical); displayName = CSTRING(AdvancedMedicalSettings_healHitPointAfterAdvBandage_DisplayName); description = CSTRING(AdvancedMedicalSettings_healHitPointAfterAdvBandage_Description); - displayName = CSTRING(healHitPointAfterAdvBandage); typeName = "BOOL"; value = 0; }; @@ -268,7 +267,6 @@ class ACE_Settings { category = CSTRING(Category_Medical); displayName = CSTRING(AdvancedMedicalSettings_painIsOnlySuppressed_DisplayName); description = CSTRING(AdvancedMedicalSettings_painIsOnlySuppressed_Description); - displayName = CSTRING(painIsOnlySuppressed); typeName = "BOOL"; value = 1; }; From 9b1b4a46fa8a3c00efa5cffa011c9bb2dd6ab427 Mon Sep 17 00:00:00 2001 From: SzwedzikPL Date: Wed, 23 Mar 2016 17:17:16 +0100 Subject: [PATCH 074/215] better polish translation --- addons/trenches/stringtable.xml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/trenches/stringtable.xml b/addons/trenches/stringtable.xml index 44c628de69..5af459f7f8 100644 --- a/addons/trenches/stringtable.xml +++ b/addons/trenches/stringtable.xml @@ -96,22 +96,22 @@ Digging Trench Grabe Schützengraben - Kopanie okopu + Kopanie wnęki Sto Scavando la Trincea Cavando trinchera Creuse la tranchée Continue Digging Trench - Wzów kopanie okopu + Wzów kopanie wnęki Remove Trench - Usuń okop + Usuń wnękę Removing Trench - Usuwanie okopu + Usuwanie wnęki From 86ad2ab415e0e3bf30c7ea4331a7182ed80c3e2b Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 24 Mar 2016 11:53:55 -0500 Subject: [PATCH 075/215] Only warn for weapon compat if AB is on --- addons/advanced_ballistics/XEH_postInit.sqf | 15 +++++++++++++++ addons/main/CfgDependencies.hpp | 11 ++--------- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/addons/advanced_ballistics/XEH_postInit.sqf b/addons/advanced_ballistics/XEH_postInit.sqf index a541d30ce8..246529299c 100644 --- a/addons/advanced_ballistics/XEH_postInit.sqf +++ b/addons/advanced_ballistics/XEH_postInit.sqf @@ -33,6 +33,21 @@ if (!hasInterface) exitWith {}; ["firedPlayer", DFUNC(handleFired)] call EFUNC(common,addEventHandler); ["firedPlayerNonLocal", DFUNC(handleFired)] call EFUNC(common,addEventHandler); + //Add warnings for missing compat PBOs (only if AB is on) + { + _x params ["_modPBO", "_compatPBO"]; + if ((isClass (configFile >> "CfgPatches" >> _modPBO)) && {!isClass (configFile >> "CfgPatches" >> _compatPBO)}) then { + ACE_LOGWARNING_2("Weapon Mod [%1] missing ace compat pbo [%2] (from @ace\optionals)",_modPBO,_compatPBO); + }; + } forEach [ + ["RH_acc","ace_compat_rh_acc"], + ["RH_de_cfg","ace_compat_rh_de"], + ["RH_m4_cfg","ace_compat_rh_m4"], + ["RH_PDW","ace_compat_rh_pdw"], + ["RKSL_PMII","ace_compat_rksl_pm_ii"], + ["iansky_opt","ace_compat_sma3_iansky"], + ["R3F_Armes","ace_compat_r3f"] + ]; }] call EFUNC(common,addEventHandler); #ifdef DEBUG_MODE_FULL diff --git a/addons/main/CfgDependencies.hpp b/addons/main/CfgDependencies.hpp index 6dd58fb60b..3414bc80b6 100644 --- a/addons/main/CfgDependencies.hpp +++ b/addons/main/CfgDependencies.hpp @@ -4,18 +4,11 @@ class CfgSettings { class ACE { class dependencies { //ACE will hard exit if this is missing - CBA[] = {"cba_main", REQUIRED_CBA_VERSION, "true"}; + CBA[] = {"cba_main", REQUIRED_CBA_VERSION, "(true)"}; - //Warnings for missing compat pbos - compat_r3f[] = {"ace_compat_r3f", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'R3F_Armes')"}; - compat_rh_acc[] = {"ace_compat_rh_acc", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_acc')"}; - compat_rh_de[] = {"ace_compat_rh_de", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_de_cfg')"}; - compat_rh_m4[] = {"ace_compat_rh_m4", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_m4_cfg')"}; - compat_rh_pdw[] = {"ace_compat_rh_pdw", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RH_PDW')"}; + //Warnings for missing RHS compat pbos compat_rhs_afrf3[] = {"ace_compat_rhs_afrf3", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'rhs_main')"}; compat_rhs_usf3[] = {"ace_compat_rhs_usf3", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'rhsusf_main')"}; - compat_rksl_pm_ii[] = {"ace_compat_rksl_pm_ii", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'RKSL_PMII')"}; - compat_sma3_iansky[] = {"ace_compat_sma3_iansky", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'iansky_opt')"}; }; }; }; From e90609d04352f6c12bc67f1ce5451e48216985d0 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 24 Mar 2016 12:23:48 -0500 Subject: [PATCH 076/215] Fix AB Terrain Extension --- addons/advanced_ballistics/XEH_postInit.sqf | 4 +++- .../functions/fnc_initializeTerrainExtension.sqf | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/addons/advanced_ballistics/XEH_postInit.sqf b/addons/advanced_ballistics/XEH_postInit.sqf index a541d30ce8..ef451ff937 100644 --- a/addons/advanced_ballistics/XEH_postInit.sqf +++ b/addons/advanced_ballistics/XEH_postInit.sqf @@ -21,7 +21,6 @@ if (!GVAR(extensionAvailable)) exitWith { }; }; */ -[] call FUNC(initializeTerrainExtension); if (!hasInterface) exitWith {}; @@ -29,6 +28,9 @@ if (!hasInterface) exitWith {}; //If not enabled, dont't add PFEH if (!GVAR(enabled)) exitWith {}; + //Run the terrain processor + [] call FUNC(initializeTerrainExtension); + // Register fire event handler ["firedPlayer", DFUNC(handleFired)] call EFUNC(common,addEventHandler); ["firedPlayerNonLocal", DFUNC(handleFired)] call EFUNC(common,addEventHandler); diff --git a/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf b/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf index 02468d0349..25562a71d0 100644 --- a/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf +++ b/addons/advanced_ballistics/functions/fnc_initializeTerrainExtension.sqf @@ -24,7 +24,7 @@ _mapSize = getNumber (configFile >> "CfgWorlds" >> worldName >> "MapSize"); if (("ace_advanced_ballistics" callExtension format["init:%1:%2", worldName, _mapSize]) == "Terrain already initialized") exitWith { #ifdef DEBUG_MODE_FULL systemChat "AdvancedBallistics: Terrain already initialized"; - #endIf + #endif }; _mapGrids = ceil(_mapSize / 50) + 1; From e5a7578f92b0fec25ee7ce2822d9f30a3cf2c56b Mon Sep 17 00:00:00 2001 From: Alessandro Foresi Date: Sun, 27 Mar 2016 21:20:15 +0200 Subject: [PATCH 077/215] Translation: IT completed (no BOM) --- addons/advanced_ballistics/stringtable.xml | 2 +- addons/aircraft/stringtable.xml | 2 +- addons/attach/stringtable.xml | 2 +- addons/captives/stringtable.xml | 2 +- addons/cargo/stringtable.xml | 2 +- addons/common/stringtable.xml | 2 +- addons/concertina_wire/stringtable.xml | 2 +- addons/dagr/stringtable.xml | 2 +- addons/dragging/stringtable.xml | 2 +- addons/explosives/stringtable.xml | 10 ++++++++-- addons/fastroping/stringtable.xml | 11 ++++++++++- addons/finger/stringtable.xml | 2 +- addons/flashlights/stringtable.xml | 2 +- addons/frag/stringtable.xml | 2 +- addons/gestures/stringtable.xml | 2 +- addons/hearing/stringtable.xml | 5 +++-- addons/interact_menu/stringtable.xml | 2 +- addons/interaction/stringtable.xml | 6 ++++-- addons/inventory/stringtable.xml | 2 +- addons/main/stringtable.xml | 2 +- addons/map/stringtable.xml | 2 +- addons/map_gestures/stringtable.xml | 2 +- addons/medical/stringtable.xml | 17 ++++++++++++++-- addons/medical_menu/stringtable.xml | 2 +- addons/microdagr/stringtable.xml | 2 +- addons/missileguidance/stringtable.xml | 2 +- addons/mk6mortar/stringtable.xml | 23 +++++++++++++++++++++- addons/nightvision/stringtable.xml | 2 +- addons/optionsmenu/stringtable.xml | 2 +- addons/overheating/stringtable.xml | 9 +++++++-- addons/parachute/stringtable.xml | 2 +- addons/rearm/stringtable.xml | 2 +- addons/refuel/stringtable.xml | 2 +- addons/repair/stringtable.xml | 2 +- addons/respawn/stringtable.xml | 2 +- addons/scopes/stringtable.xml | 2 +- addons/sitting/stringtable.xml | 2 +- addons/slideshow/stringtable.xml | 2 +- addons/spectator/stringtable.xml | 2 +- addons/switchunits/stringtable.xml | 2 +- addons/tacticalladder/stringtable.xml | 5 +++-- addons/tagging/stringtable.xml | 17 ++++++++++++++-- addons/trenches/stringtable.xml | 2 +- addons/tripod/stringtable.xml | 2 +- addons/viewdistance/stringtable.xml | 2 +- addons/yardage450/stringtable.xml | 2 +- addons/zeus/stringtable.xml | 2 +- 47 files changed, 125 insertions(+), 54 deletions(-) diff --git a/addons/advanced_ballistics/stringtable.xml b/addons/advanced_ballistics/stringtable.xml index 718057a5b4..371ef67fea 100644 --- a/addons/advanced_ballistics/stringtable.xml +++ b/addons/advanced_ballistics/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/aircraft/stringtable.xml b/addons/aircraft/stringtable.xml index 5480cb9740..3dec20b5f0 100644 --- a/addons/aircraft/stringtable.xml +++ b/addons/aircraft/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/attach/stringtable.xml b/addons/attach/stringtable.xml index 462e3d725c..a374c42802 100644 --- a/addons/attach/stringtable.xml +++ b/addons/attach/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/captives/stringtable.xml b/addons/captives/stringtable.xml index 4044723c4a..59c7ca7165 100644 --- a/addons/captives/stringtable.xml +++ b/addons/captives/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/cargo/stringtable.xml b/addons/cargo/stringtable.xml index 57daacd207..630f903ca2 100644 --- a/addons/cargo/stringtable.xml +++ b/addons/cargo/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/common/stringtable.xml b/addons/common/stringtable.xml index 32a979653f..a3c593cc2b 100644 --- a/addons/common/stringtable.xml +++ b/addons/common/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/concertina_wire/stringtable.xml b/addons/concertina_wire/stringtable.xml index 616879f31e..100a5ed2df 100644 --- a/addons/concertina_wire/stringtable.xml +++ b/addons/concertina_wire/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/dagr/stringtable.xml b/addons/dagr/stringtable.xml index 01b43391ab..90aaffaaba 100644 --- a/addons/dagr/stringtable.xml +++ b/addons/dagr/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/dragging/stringtable.xml b/addons/dragging/stringtable.xml index b0334f3ca2..393638e0c5 100644 --- a/addons/dragging/stringtable.xml +++ b/addons/dragging/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/explosives/stringtable.xml b/addons/explosives/stringtable.xml index e3ba902a9b..fe41b24e74 100644 --- a/addons/explosives/stringtable.xml +++ b/addons/explosives/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -647,6 +647,7 @@ Mina M6 SLAM (atak od dołu) Mina M6 SLAM (Ataque Inferior) Mine M6 SLAM (par le bas) + Mina M6 SLAM (base) M6 SLAM Mine (Side Attack) @@ -661,6 +662,7 @@ Mina M6 SLAM (atak od boku) Mina M6 SLAM (Ataque Lateral) Mine M6 SLAM (de flanc) + STR_ACE_Explosives_Module_SLAMBottomAttack_DisplayName M6 SLAM Mine (Bottom Attack) Mine M6 SLAM (par le bas) M6-SLAM-Mine (Bodenangriff) Mina M6 SLAM (base) Mina M6 SLAM (atak od dołu) Mina M6 SLAM (Laterale) Large IED (Urban, Pressure Plate) @@ -675,6 +677,7 @@ Duży IED (miejski, płyta naciskowa) IED Grande (Urbano, Placa de presión) Grand EEI (Urbain, plaque de pression) + IED grande (urbano, a pressione) Large IED (Dug-in, Pressure Plate) @@ -689,6 +692,7 @@ Duży IED (zakopany, płyta naciskowa) IED Grande (Enterrado, Placa de presión) Grand EEI (Enterré, plaque de pression) + IED grande (interrato, a pressione) Small IED (Urban, Pressure Plate) @@ -703,6 +707,7 @@ Mały IED (miejski, płyta naciskowa) IED Pequeño (Urbano, Placa de presión) Petit EEI (Urbain, plaque de pression) + IED piccolo (urbano, a pressione) Small IED (Dug-in, Pressure Plate) @@ -717,6 +722,7 @@ Mały IED (zakopany, płyta naciskowa) IED Pequeño (Enterrado, Placa de presión) Petit EEI (Enterré, plaque de pression) + IED piccolo (interrato, a pressione) Connect to %1 @@ -731,4 +737,4 @@ Conectar à %1 - + \ No newline at end of file diff --git a/addons/fastroping/stringtable.xml b/addons/fastroping/stringtable.xml index f6c0f34826..96c4626de1 100644 --- a/addons/fastroping/stringtable.xml +++ b/addons/fastroping/stringtable.xml @@ -7,6 +7,7 @@ Wyposaż FRIES Equiper le FRIES Equipar FRIES + Equipaggia la FRIES Equips compatible helicopters with a Fast Rope Insertion Extraction System. @@ -14,6 +15,7 @@ Wyposaża kompatybilne helikoptery w zestaw Fast Rope Insertion Extraction System. Equipe les hélicoptères compatibles avec un Module Fast Rope Insertion Extraction System. Equipar helicoptero compatible con un Sistema de Inserción Extracción Fast Rope. + Equipagga l'elicottero compatibile con il Fast Rope Insertion Exstraction System Prepare fast roping system @@ -21,6 +23,7 @@ Przygotuj system zjazdu na linach Préparer le système de corde lisse Preparar el sistema fast roping + Prepara le corde Deploy ropes @@ -28,6 +31,7 @@ Wypuść liny Déployer les cordes Desplegar cuerdas + Srotola le corde Fast rope @@ -35,6 +39,7 @@ Zjedź na linie Descendre à la corde Descender por la cuerda + Scendi sulla corda Cut ropes @@ -42,6 +47,7 @@ Odetnij liny Détacher les cordes Cortar cuerdas + Taglia le corde Equip helicopter with FRIES @@ -49,6 +55,7 @@ Wyposaż helikopter w FRIES Equiper l'hélicoptère avec le FRIED Equipar helicoptero con FRIES + Equipaggia l'elicottero con FRIES Equips the selected helicopter with a Fast Rope Insertion Extraction System @@ -56,10 +63,12 @@ Wyposaża wybrany helikopter w zestaw Fast Rope Insertion Extraction System Equipe l'hélicoptère sélectionné avec un Fast Rope Insertion Extraction System Equipa el helicoptero seleccionado con un Sistema de Inserción Extracción Fast Rope + Equipaggia l'elicottero selezionato con il Fast Rope Insertion Extraction System LET UNITS FAST ROPE EINHEITEN ABSEILEN LASSEN + SCENDI DALLE CORDE - + \ No newline at end of file diff --git a/addons/finger/stringtable.xml b/addons/finger/stringtable.xml index 3f68d337f2..f335c12f0a 100644 --- a/addons/finger/stringtable.xml +++ b/addons/finger/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/flashlights/stringtable.xml b/addons/flashlights/stringtable.xml index dad3158b38..56b967e2d4 100644 --- a/addons/flashlights/stringtable.xml +++ b/addons/flashlights/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/frag/stringtable.xml b/addons/frag/stringtable.xml index 4191a405d3..4bdf513aff 100644 --- a/addons/frag/stringtable.xml +++ b/addons/frag/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/gestures/stringtable.xml b/addons/gestures/stringtable.xml index 1f008ddae9..a5af13cd1e 100644 --- a/addons/gestures/stringtable.xml +++ b/addons/gestures/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/hearing/stringtable.xml b/addons/hearing/stringtable.xml index 1777c08e4f..1d40dca8ae 100644 --- a/addons/hearing/stringtable.xml +++ b/addons/hearing/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -115,6 +115,7 @@ Desactiva el efecto de zumbido cuando el jugador recibe daño auditivo. Usuń szum w uszach przy chwilowej utracie słuchu. Enlève les acouphènes quand le joueur prend des dommages auditifs. + Quando il giocatore riceve danni all'udito, non fa sentire i fischi nelle orecchie Hearing @@ -208,4 +209,4 @@ Ajouter l'item "ACE_EarPlugs" à toutes les unités qui ont des armes lourdes. Peut être desactivé si des équipements personnels sont utilisés. - + \ No newline at end of file diff --git a/addons/interact_menu/stringtable.xml b/addons/interact_menu/stringtable.xml index aac120ddbc..00118adee9 100644 --- a/addons/interact_menu/stringtable.xml +++ b/addons/interact_menu/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/interaction/stringtable.xml b/addons/interaction/stringtable.xml index b847a66aa6..05df33e043 100644 --- a/addons/interaction/stringtable.xml +++ b/addons/interaction/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -711,6 +711,7 @@ Włącz Encender Allumer + Accendi Turn off @@ -718,6 +719,7 @@ Wyłącz Apagar Eteindre + Spegni Pass magazine @@ -775,4 +777,4 @@ Montrer l'interaction "donner un chargeur". - + \ No newline at end of file diff --git a/addons/inventory/stringtable.xml b/addons/inventory/stringtable.xml index 6384c11641..cb4aee728d 100644 --- a/addons/inventory/stringtable.xml +++ b/addons/inventory/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/main/stringtable.xml b/addons/main/stringtable.xml index 985bfb4836..f49394a68c 100644 --- a/addons/main/stringtable.xml +++ b/addons/main/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/map/stringtable.xml b/addons/map/stringtable.xml index 73bf0cc774..42a0145d0b 100644 --- a/addons/map/stringtable.xml +++ b/addons/map/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/map_gestures/stringtable.xml b/addons/map_gestures/stringtable.xml index e89d6c07a3..464dcaf352 100644 --- a/addons/map_gestures/stringtable.xml +++ b/addons/map_gestures/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/medical/stringtable.xml b/addons/medical/stringtable.xml index 7091de6b6e..00cde86765 100644 --- a/addons/medical/stringtable.xml +++ b/addons/medical/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -55,6 +55,7 @@ Inyectar Adenosina Wstrzyknij adenozynę Injecter de l'adénosine + Inietta andenosina Inject Atropine @@ -254,6 +255,7 @@ Inyectando Adenosina... Wstrzykiwanie adenozyny... Injection d'adénosine... + Inietto l'andenosina Injecting Atropine... @@ -969,6 +971,7 @@ Asenosina auto-inyectable Autostrzykawka z adenozyną Auto-injécteur d'adénosine + Autoiniettore di adenosina Used to counter effects of Epinephrine @@ -976,6 +979,7 @@ Utilizada para contrarrestar los effectos de la Epinefrina Adenozyna. Stosowana do zwalczania efektów działania adrenaliny. Utilisé pour contrer les effets de l'adrénaline + Usato per contrastare l'effetto dell'epinefrina A drug used to counter the effects of Epinephrine @@ -983,6 +987,7 @@ Medicamento usado para contrarrestar los efectos de la Epinefrina. Organiczny związek chemiczny z grupy nukleozydów. Skuteczna w leczeniu częstoskurczu komorowego. Działa rozszerzająco na naczynia krwionośne. Un composé utilisé pour contrer les effets de l'adrénaline + Medicamento usato per contrastare l'effetto dell'epinefrina Atropine autoinjector @@ -3199,6 +3204,7 @@ Podstawowe ustawienia medyczne Ajustes médicos básicos [ACE] Réglages du système médical basic [ACE] + Impostazioni Mediche Di Base [ACE] Advanced Medical Settings [ACE] @@ -3314,6 +3320,7 @@ Permitir Epinefrina Ograniczenia adrenaliny Autoriser l'adrénaline + Permette epinefrina Who can use Epinephrine for full heal? (Basic medical only) @@ -3321,6 +3328,7 @@ Configura quienes pueden usar Epinefrina (Solo sistema médico básico) Kto może skorzystać z adrenaliny w celu pełnego uleczenia? (Tylko podstawowy system medyczny) Qui peut utiliser l'adrénaline pour les soins complets ? (Médical basique seulement) + Chi può usare l'epinefrina per la cura completa? (solo per sistema medico di base) Allow PAK @@ -3412,6 +3420,7 @@ Ubicaciones epinefrina Ograniczenia adrenaliny Position des adrénalines + Ubicazione epinefrina Where can the Epinephrine be used? (Basic Medical) @@ -3419,6 +3428,7 @@ Configura donde puede usarse Epinefrina (Solo sistema médico básico) Gdzie można korzystać z adrenaliny? (Podstawowy system medyczny) Où peuvent être utilisées les adrénalines ? (Médical basique) + Dove si può usare l'epinefrina? (Sistema medico di base) Locations PAK @@ -3664,6 +3674,7 @@ Configure las opciones de tratamiento del sistema médico básico de ACE Skonfiguruj ustawienia leczenia podstawowego systemu medycznego ACE Configure les réglages de traitement dans ACE médical basique + Configura le impostazioni trattamenti per ACE Medical di base Configure the treatment settings from ACE Advanced Medical @@ -4125,12 +4136,14 @@ Delay cease fire of AI while player is unconscious for medical reasons. Verzögert das Ende des KI-Beschusses auf einen Spieler, wenn dieser aus medizinischen Gründen bewustlos wird. + Ritarda il cessate il fuoco dell'IA quando il giocatore è svenuto per motivi medici. Delay cease fire of AI for unconsciousness Verzögert Ende des KI-Beschusses bei medizinischer Bewustlosigkeit Demora antes de volverse neutral al caer inconsciente Opóźnij status captive u nieprzytomnych osób + Ritarda il cessate il fuoco dell'IA quando si è svenuti - + \ No newline at end of file diff --git a/addons/medical_menu/stringtable.xml b/addons/medical_menu/stringtable.xml index f825882be6..a55bb575cd 100644 --- a/addons/medical_menu/stringtable.xml +++ b/addons/medical_menu/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/microdagr/stringtable.xml b/addons/microdagr/stringtable.xml index c20ea7aede..fcc38b8f7c 100644 --- a/addons/microdagr/stringtable.xml +++ b/addons/microdagr/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/missileguidance/stringtable.xml b/addons/missileguidance/stringtable.xml index ff14fea9f7..1f188db453 100644 --- a/addons/missileguidance/stringtable.xml +++ b/addons/missileguidance/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/mk6mortar/stringtable.xml b/addons/mk6mortar/stringtable.xml index 5daa29a0f6..e77a771b38 100644 --- a/addons/mk6mortar/stringtable.xml +++ b/addons/mk6mortar/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -150,6 +150,7 @@ Usar manejo de munición. Aktywuj obsługę amunicji Utiliser la gestion des munitions + Utilizza la gestione delle munizioni Removes mortar magazines, requiring individual rounds to be loaded by the gunner or loader. Does not affect AI mortars. @@ -157,6 +158,7 @@ Elimina los cargadores del mortero, requiriendo al artillero o cargador la carga manual de cada rondas. No afecta morteros controlados por IA. Usuwa magazynki moździerza, wymagając ładowania pojedynczych pocisków przez strzelca lub ładowniczego. Nie dotyczy moździerzy AI. Enlever les chargeurs de mortier, requiert des obus individuels qui doivent être chargés par le tireur ou le servant. N'affect pas les mortiers IA. + Toglie i proiettili dal mortaio. I colpi singoli devono essere caricati dall'operatore. Non cambia quado l'IA spara. Remove Round @@ -164,6 +166,7 @@ Extraer ronda Wyładuj pocisk Enlever l'obus + Togli proiettile Load Mortar @@ -171,6 +174,7 @@ Cargar mortero Załaduj moździerz Charger le mortier + Carica mortaio Unloading Round @@ -178,6 +182,7 @@ Descargando ronda Rozładowywanie moździerza Déchargement de l'obus + Scarica proiettile Preparing Round @@ -185,6 +190,7 @@ Preparando ronda Przygotowywanie pocisku Praparation de l'obus + Prepara il proiettile Load HE @@ -192,6 +198,7 @@ Cargar HE Załaduj pocisk wybuchowy Charger HE + Carica proiettile esplosivo ad alto potenziale (HE) Load Smoke @@ -199,6 +206,7 @@ Cargar Humo Załaduj pocisk dymny Charger Fumigène + Carica fumogeno Load Illumination @@ -206,6 +214,7 @@ Cargar Iluminación Załaduj pocisk oświetlający Charger Eclairante + Carica illuminante Load Guided HE @@ -213,6 +222,7 @@ Cagar HE Guiada Załaduj kierowany pocisk wybuchowy Charger HE guidé + Carica HE guidata Load Laser Guided HE @@ -220,6 +230,7 @@ Cargar HE Guiada por Laser Załaduj laserowo napr. pocisk wybuchowy Charger HE guidé au laser + Carica HE a guida laser 82mm HE Round @@ -227,6 +238,7 @@ Ronda 82mm HE Pocisk wybuchowy kal. 82mm Obus de 82mm HE + Proiettile da 82mm HE 82mm Smoke Round @@ -234,6 +246,7 @@ Ronda 82mm Humo Pocisk dymny kal. 82mm Obus de 82mm fumigène + Proiettile Fumogeno da 82mm 82mm Illumination Round @@ -241,6 +254,7 @@ Ronda 82mm Iluminación Pocisk oświetlający kal. 82mm Obus de 82mm éclairant + Proiettile illuminante da 82mm 82mm Guided HE Round @@ -248,6 +262,7 @@ Ronda 82mm Guiada Kierowany pocisk wybuchowy kal. 82mm Obus de 82mm HE guidé + Proiettile HE guidato 82mm Laser Guided HE Round @@ -255,6 +270,7 @@ Ronda 82mm Guiada por Laser Laserowo napr. pocisk wybuchowy kal. 82mm Obus de 82mm HE guidé au laser + Proiettile HE a guida laser Used in Mk6 mortar @@ -262,6 +278,7 @@ Usada en el mortero Mk6 Używany w moździerzu Mk6 Utilisé dans le mortier Mk6 + Usato nel mortaio Mk6 [ACE] 82mm HE Rounds Box @@ -269,6 +286,7 @@ [ACE] Caja de municiones 82mm HE [ACE] Skrzynka amunicji wybuchowej 82mm [ACE] Obus de 82mm HE + [ACE] Scatola proiettili espolisvi ad alto potenziale (HE) da 82mm [ACE] 82mm Smoke Rounds Box @@ -276,6 +294,7 @@ [ACE] Caja de municiones 82mm Humo [ACE] Skrzynka amunicji dymnej 82mm [ACE] Obus de 82mm fumigène + [ACE] Scatola fumogeni da 82mm [ACE] 82mm Illumination Rounds Box @@ -283,6 +302,7 @@ [ACE] Caja de municiones 82mm Iluminacion [ACE] Skrzynka amunicji oświetlającej 82mm [ACE] Obus de 82mm éclairants + [ACE] Scatola illuminanti da 82mm [ACE] 82mm Default Loadout Box @@ -290,6 +310,7 @@ [ACE] Caja de municiones 82mm por defecto [ACE] Skrzynka amunicji standardowej 82mm [ACE] Obus de 82mm par défaut + [ACE] Scatola proiettili 82mm standard \ No newline at end of file diff --git a/addons/nightvision/stringtable.xml b/addons/nightvision/stringtable.xml index 708860d134..abc0218908 100644 --- a/addons/nightvision/stringtable.xml +++ b/addons/nightvision/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/optionsmenu/stringtable.xml b/addons/optionsmenu/stringtable.xml index b051e3f219..66ad0dd00b 100644 --- a/addons/optionsmenu/stringtable.xml +++ b/addons/optionsmenu/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/overheating/stringtable.xml b/addons/overheating/stringtable.xml index 23a1b0253a..f17ee88670 100644 --- a/addons/overheating/stringtable.xml +++ b/addons/overheating/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -79,6 +79,7 @@ Desencasquillar el arma al recargar. Usuń zacięcie przy przeładowaniu Des-enrayer l'arme au rechargement. + Disinceppa l'arma quando si ricarica Reloading clears a weapon jam. @@ -86,6 +87,7 @@ Recargar el arma la desencasquilla. Przeładowywanie usuwa zacięcie Recharger vide la chambre de l'arme + L'arma si disinceppa quando si ricarica Chance of unjam failing @@ -93,6 +95,7 @@ Probabilidad de falla al desencasquillar. Szansa na porażkę usuw. zacięcia Chance de rater le des-enrayement + Probabilità di sbagliare a disinceppare l'arma Probability that an unjam action might fail, requiring to be repeated. @@ -100,6 +103,7 @@ Probabilidad de que el proceso de desencasquille falle, teniendo que repetirlo. Szansa na to, że przy przeładowaniu broni zacięcie nie zostanie usunięte, przez co czynność będzie musiała zostać powtórzona ponownie. Probabilité qu'une action de des-enrayement échoue, nécessitant de recommencer. + Probabilità che si possa sbagliare a caso a disinceppare l'arma. Richiede di ripetere. Spare barrel @@ -167,6 +171,7 @@ Falló el desencasquillado Porażka przy usuwaniu zacięcia Toujours enrayé ! + Non si è disinceppata! Swap barrel @@ -253,4 +258,4 @@ Температура - + \ No newline at end of file diff --git a/addons/parachute/stringtable.xml b/addons/parachute/stringtable.xml index 880cc55e5f..db21b182d1 100644 --- a/addons/parachute/stringtable.xml +++ b/addons/parachute/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/rearm/stringtable.xml b/addons/rearm/stringtable.xml index 7806735c57..b7da05d989 100644 --- a/addons/rearm/stringtable.xml +++ b/addons/rearm/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/refuel/stringtable.xml b/addons/refuel/stringtable.xml index 2df51ea540..df30ac2380 100644 --- a/addons/refuel/stringtable.xml +++ b/addons/refuel/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/repair/stringtable.xml b/addons/repair/stringtable.xml index fb505f4f4e..2af94c1ef2 100644 --- a/addons/repair/stringtable.xml +++ b/addons/repair/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/respawn/stringtable.xml b/addons/respawn/stringtable.xml index e0d04aabfa..716679d0d0 100644 --- a/addons/respawn/stringtable.xml +++ b/addons/respawn/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/scopes/stringtable.xml b/addons/scopes/stringtable.xml index 8dc7a9eba0..2e7918cb7d 100644 --- a/addons/scopes/stringtable.xml +++ b/addons/scopes/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/sitting/stringtable.xml b/addons/sitting/stringtable.xml index f7c7b84b93..2231ff5145 100644 --- a/addons/sitting/stringtable.xml +++ b/addons/sitting/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/slideshow/stringtable.xml b/addons/slideshow/stringtable.xml index 4c45399ba6..5459adeea7 100644 --- a/addons/slideshow/stringtable.xml +++ b/addons/slideshow/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/spectator/stringtable.xml b/addons/spectator/stringtable.xml index b78febbef7..3ec849658f 100644 --- a/addons/spectator/stringtable.xml +++ b/addons/spectator/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/switchunits/stringtable.xml b/addons/switchunits/stringtable.xml index 60d7fb0ecd..bd4fe13a56 100644 --- a/addons/switchunits/stringtable.xml +++ b/addons/switchunits/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/tacticalladder/stringtable.xml b/addons/tacticalladder/stringtable.xml index 1e2c037f20..ab1ffbed9b 100644 --- a/addons/tacticalladder/stringtable.xml +++ b/addons/tacticalladder/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -57,6 +57,7 @@ +Ctrl naklonit +Ctrl inclinar +Ctrl incliner + +Ctrl per inclinare Position ladder @@ -83,4 +84,4 @@ Pegar escada - + \ No newline at end of file diff --git a/addons/tagging/stringtable.xml b/addons/tagging/stringtable.xml index 392de0d24f..41964c9b13 100644 --- a/addons/tagging/stringtable.xml +++ b/addons/tagging/stringtable.xml @@ -1,4 +1,4 @@ - + @@ -7,6 +7,7 @@ Marcar en negro Oznakuj na czarno Tag noir + Marca nero Tag red @@ -14,6 +15,7 @@ Marcar en rojo Oznakuj na czerwono Tag rouge + Marca rosso Tag green @@ -21,6 +23,7 @@ Marcar en verde Oznakuj na zielono Tag vert + Marca verde Tag blue @@ -28,6 +31,7 @@ Marcar en azul Oznakuj na niebiesko Tag bleu + Marca blu Tag ground black @@ -35,6 +39,7 @@ Oznakuj ziemię na czarno Marcar suelo en negro Tag fond noir + Segna nero a terra Tag ground red @@ -42,6 +47,7 @@ Oznakuj ziemię na czerwono Marcar suelo en rojo Tag fond rouge + Segna rosso a terra Tag ground green @@ -49,6 +55,7 @@ Oznakuj ziemię na zielono Marcar suelo en verde Tag fond vert + Segna verde a terra Tag ground blue @@ -56,6 +63,7 @@ Oznakuj ziemię na niebiesko Marcar suelo en azul Tag font bleu + Segna blu a terra Black spray paint @@ -63,6 +71,7 @@ Pintura negra Czarna farba w sprayu Peinture pulvérisée noire + Bomboletta spray nera Red spray paint @@ -70,6 +79,7 @@ Pintura roja Czerwona farba w sprayu Peinture pulvérisée rouge + Bomboletta spray rossa Green spray paint @@ -77,6 +87,7 @@ Pintura verde Zielona farba w sprayu Peinture pulvérisée verte + Bomboletta spray verde Blue spray paint @@ -84,6 +95,7 @@ Pintura azul Niebieska farba w sprayu Peinture pulvérisée bleue + Bomboletta spray blu A can of spray paint for tagging walls. @@ -91,6 +103,7 @@ Lata de pintura en aerosol para marcar. Farba w sprayu, służy do oznakowywania terenu. Un spray de peinture pour taguer les murs. + Una bomboletta di spay per contrassegnare i muri. - + \ No newline at end of file diff --git a/addons/trenches/stringtable.xml b/addons/trenches/stringtable.xml index 617a604457..a6b922a00f 100644 --- a/addons/trenches/stringtable.xml +++ b/addons/trenches/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/tripod/stringtable.xml b/addons/tripod/stringtable.xml index a57c6ca51d..c2abcff8bc 100644 --- a/addons/tripod/stringtable.xml +++ b/addons/tripod/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/viewdistance/stringtable.xml b/addons/viewdistance/stringtable.xml index a0f2bceb68..518f673455 100644 --- a/addons/viewdistance/stringtable.xml +++ b/addons/viewdistance/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/yardage450/stringtable.xml b/addons/yardage450/stringtable.xml index c9f1c94b1b..4fdc0dfe72 100644 --- a/addons/yardage450/stringtable.xml +++ b/addons/yardage450/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/zeus/stringtable.xml b/addons/zeus/stringtable.xml index c07d4f7f84..8ef47b9b27 100644 --- a/addons/zeus/stringtable.xml +++ b/addons/zeus/stringtable.xml @@ -1,4 +1,4 @@ - + From e97c7c0f65721e9957e968193134ed462efd451a Mon Sep 17 00:00:00 2001 From: Alessandro Foresi Date: Sun, 27 Mar 2016 21:22:15 +0200 Subject: [PATCH 078/215] Translation: IT completed (with BOM) --- addons/advanced_ballistics/stringtable.xml | 2 +- addons/aircraft/stringtable.xml | 2 +- addons/atragmx/stringtable.xml | 2 +- addons/attach/stringtable.xml | 2 +- addons/ballistics/stringtable.xml | 2 +- addons/captives/stringtable.xml | 2 +- addons/cargo/stringtable.xml | 2 +- addons/common/stringtable.xml | 2 +- addons/concertina_wire/stringtable.xml | 2 +- addons/dagr/stringtable.xml | 2 +- addons/disarming/stringtable.xml | 2 +- addons/disposable/stringtable.xml | 2 +- addons/dragging/stringtable.xml | 2 +- addons/explosives/stringtable.xml | 2 +- addons/fastroping/stringtable.xml | 2 +- addons/fcs/stringtable.xml | 2 +- addons/finger/stringtable.xml | 2 +- addons/flashlights/stringtable.xml | 2 +- addons/flashsuppressors/stringtable.xml | 2 +- addons/frag/stringtable.xml | 2 +- addons/gestures/stringtable.xml | 2 +- addons/goggles/stringtable.xml | 2 +- addons/grenades/stringtable.xml | 2 +- addons/hearing/stringtable.xml | 2 +- addons/huntir/stringtable.xml | 2 +- addons/interact_menu/stringtable.xml | 2 +- addons/interaction/stringtable.xml | 2 +- addons/inventory/stringtable.xml | 2 +- addons/javelin/stringtable.xml | 2 +- addons/kestrel4500/stringtable.xml | 2 +- addons/laser/stringtable.xml | 2 +- addons/laser_selfdesignate/stringtable.xml | 2 +- addons/laserpointer/stringtable.xml | 2 +- addons/logistics_uavbattery/stringtable.xml | 2 +- addons/logistics_wirecutter/stringtable.xml | 2 +- addons/magazinerepack/stringtable.xml | 2 +- addons/main/stringtable.xml | 2 +- addons/map/stringtable.xml | 2 +- addons/map_gestures/stringtable.xml | 2 +- addons/maptools/stringtable.xml | 2 +- addons/markers/stringtable.xml | 2 +- addons/medical/stringtable.xml | 2 +- addons/medical_menu/stringtable.xml | 2 +- addons/microdagr/stringtable.xml | 2 +- addons/missileguidance/stringtable.xml | 2 +- addons/missionmodules/stringtable.xml | 2 +- addons/mk6mortar/stringtable.xml | 2 +- addons/movement/stringtable.xml | 2 +- addons/mx2a/stringtable.xml | 2 +- addons/nametags/stringtable.xml | 2 +- addons/nightvision/stringtable.xml | 2 +- addons/optics/stringtable.xml | 2 +- addons/optionsmenu/stringtable.xml | 2 +- addons/overheating/stringtable.xml | 2 +- addons/parachute/stringtable.xml | 2 +- addons/rangecard/stringtable.xml | 2 +- addons/realisticnames/stringtable.xml | 2 +- addons/rearm/stringtable.xml | 2 +- addons/refuel/stringtable.xml | 2 +- addons/reload/stringtable.xml | 2 +- addons/reloadlaunchers/stringtable.xml | 2 +- addons/repair/stringtable.xml | 2 +- addons/respawn/stringtable.xml | 2 +- addons/safemode/stringtable.xml | 2 +- addons/sandbag/stringtable.xml | 2 +- addons/scopes/stringtable.xml | 2 +- addons/sitting/stringtable.xml | 2 +- addons/slideshow/stringtable.xml | 2 +- addons/spectator/stringtable.xml | 2 +- addons/spottingscope/stringtable.xml | 2 +- addons/switchunits/stringtable.xml | 2 +- addons/tacticalladder/stringtable.xml | 2 +- addons/tagging/stringtable.xml | 2 +- addons/trenches/stringtable.xml | 2 +- addons/tripod/stringtable.xml | 2 +- addons/vector/stringtable.xml | 2 +- addons/vehiclelock/stringtable.xml | 2 +- addons/vehicles/stringtable.xml | 2 +- addons/viewdistance/stringtable.xml | 2 +- addons/weaponselect/stringtable.xml | 2 +- addons/weather/stringtable.xml | 2 +- addons/winddeflection/stringtable.xml | 2 +- addons/yardage450/stringtable.xml | 2 +- addons/zeus/stringtable.xml | 2 +- 84 files changed, 84 insertions(+), 84 deletions(-) diff --git a/addons/advanced_ballistics/stringtable.xml b/addons/advanced_ballistics/stringtable.xml index 371ef67fea..718057a5b4 100644 --- a/addons/advanced_ballistics/stringtable.xml +++ b/addons/advanced_ballistics/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/aircraft/stringtable.xml b/addons/aircraft/stringtable.xml index 3dec20b5f0..5480cb9740 100644 --- a/addons/aircraft/stringtable.xml +++ b/addons/aircraft/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/atragmx/stringtable.xml b/addons/atragmx/stringtable.xml index a8e23ffbda..3790fb1f2d 100644 --- a/addons/atragmx/stringtable.xml +++ b/addons/atragmx/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/attach/stringtable.xml b/addons/attach/stringtable.xml index a374c42802..462e3d725c 100644 --- a/addons/attach/stringtable.xml +++ b/addons/attach/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/ballistics/stringtable.xml b/addons/ballistics/stringtable.xml index 39bbac1726..b51303fa6d 100644 --- a/addons/ballistics/stringtable.xml +++ b/addons/ballistics/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/captives/stringtable.xml b/addons/captives/stringtable.xml index 59c7ca7165..4044723c4a 100644 --- a/addons/captives/stringtable.xml +++ b/addons/captives/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/cargo/stringtable.xml b/addons/cargo/stringtable.xml index 630f903ca2..57daacd207 100644 --- a/addons/cargo/stringtable.xml +++ b/addons/cargo/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/common/stringtable.xml b/addons/common/stringtable.xml index a3c593cc2b..32a979653f 100644 --- a/addons/common/stringtable.xml +++ b/addons/common/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/concertina_wire/stringtable.xml b/addons/concertina_wire/stringtable.xml index 100a5ed2df..616879f31e 100644 --- a/addons/concertina_wire/stringtable.xml +++ b/addons/concertina_wire/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/dagr/stringtable.xml b/addons/dagr/stringtable.xml index 90aaffaaba..01b43391ab 100644 --- a/addons/dagr/stringtable.xml +++ b/addons/dagr/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/disarming/stringtable.xml b/addons/disarming/stringtable.xml index 61eaf9af59..dfa030273a 100644 --- a/addons/disarming/stringtable.xml +++ b/addons/disarming/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/disposable/stringtable.xml b/addons/disposable/stringtable.xml index acdc79473c..ac2b76ee7f 100644 --- a/addons/disposable/stringtable.xml +++ b/addons/disposable/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/dragging/stringtable.xml b/addons/dragging/stringtable.xml index 393638e0c5..b0334f3ca2 100644 --- a/addons/dragging/stringtable.xml +++ b/addons/dragging/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/explosives/stringtable.xml b/addons/explosives/stringtable.xml index fe41b24e74..4cabe2ce06 100644 --- a/addons/explosives/stringtable.xml +++ b/addons/explosives/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/fastroping/stringtable.xml b/addons/fastroping/stringtable.xml index 96c4626de1..1a03e59409 100644 --- a/addons/fastroping/stringtable.xml +++ b/addons/fastroping/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/fcs/stringtable.xml b/addons/fcs/stringtable.xml index 035d9d7a36..8750d2a4e3 100644 --- a/addons/fcs/stringtable.xml +++ b/addons/fcs/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/finger/stringtable.xml b/addons/finger/stringtable.xml index f335c12f0a..3f68d337f2 100644 --- a/addons/finger/stringtable.xml +++ b/addons/finger/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/flashlights/stringtable.xml b/addons/flashlights/stringtable.xml index 56b967e2d4..dad3158b38 100644 --- a/addons/flashlights/stringtable.xml +++ b/addons/flashlights/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/flashsuppressors/stringtable.xml b/addons/flashsuppressors/stringtable.xml index 5f6a0ebc86..f075f1aa34 100644 --- a/addons/flashsuppressors/stringtable.xml +++ b/addons/flashsuppressors/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/frag/stringtable.xml b/addons/frag/stringtable.xml index 4bdf513aff..4191a405d3 100644 --- a/addons/frag/stringtable.xml +++ b/addons/frag/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/gestures/stringtable.xml b/addons/gestures/stringtable.xml index a5af13cd1e..1f008ddae9 100644 --- a/addons/gestures/stringtable.xml +++ b/addons/gestures/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/goggles/stringtable.xml b/addons/goggles/stringtable.xml index 6b5a623715..ce337760d7 100644 --- a/addons/goggles/stringtable.xml +++ b/addons/goggles/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/grenades/stringtable.xml b/addons/grenades/stringtable.xml index a05f6635cd..44d9e7ad47 100644 --- a/addons/grenades/stringtable.xml +++ b/addons/grenades/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/hearing/stringtable.xml b/addons/hearing/stringtable.xml index 1d40dca8ae..e92229cdd4 100644 --- a/addons/hearing/stringtable.xml +++ b/addons/hearing/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/huntir/stringtable.xml b/addons/huntir/stringtable.xml index 2331c3855c..8648f58ea9 100644 --- a/addons/huntir/stringtable.xml +++ b/addons/huntir/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/interact_menu/stringtable.xml b/addons/interact_menu/stringtable.xml index 00118adee9..aac120ddbc 100644 --- a/addons/interact_menu/stringtable.xml +++ b/addons/interact_menu/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/interaction/stringtable.xml b/addons/interaction/stringtable.xml index 05df33e043..0e1afa21a1 100644 --- a/addons/interaction/stringtable.xml +++ b/addons/interaction/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/inventory/stringtable.xml b/addons/inventory/stringtable.xml index cb4aee728d..6384c11641 100644 --- a/addons/inventory/stringtable.xml +++ b/addons/inventory/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/javelin/stringtable.xml b/addons/javelin/stringtable.xml index 385abf586e..dcc03dca91 100644 --- a/addons/javelin/stringtable.xml +++ b/addons/javelin/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/kestrel4500/stringtable.xml b/addons/kestrel4500/stringtable.xml index defb44c2dc..3ad9e8824f 100644 --- a/addons/kestrel4500/stringtable.xml +++ b/addons/kestrel4500/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/laser/stringtable.xml b/addons/laser/stringtable.xml index f51b9cd127..4a478096d0 100644 --- a/addons/laser/stringtable.xml +++ b/addons/laser/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/laser_selfdesignate/stringtable.xml b/addons/laser_selfdesignate/stringtable.xml index 17c562a2bb..cdd7439200 100644 --- a/addons/laser_selfdesignate/stringtable.xml +++ b/addons/laser_selfdesignate/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/laserpointer/stringtable.xml b/addons/laserpointer/stringtable.xml index afd11addb1..1e4b150c3d 100644 --- a/addons/laserpointer/stringtable.xml +++ b/addons/laserpointer/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/logistics_uavbattery/stringtable.xml b/addons/logistics_uavbattery/stringtable.xml index c38c3daae3..6ff6e4b52d 100644 --- a/addons/logistics_uavbattery/stringtable.xml +++ b/addons/logistics_uavbattery/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/logistics_wirecutter/stringtable.xml b/addons/logistics_wirecutter/stringtable.xml index ef5d0522e3..1f9955f4be 100644 --- a/addons/logistics_wirecutter/stringtable.xml +++ b/addons/logistics_wirecutter/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/magazinerepack/stringtable.xml b/addons/magazinerepack/stringtable.xml index 1fc873f0c3..b89b4b587d 100644 --- a/addons/magazinerepack/stringtable.xml +++ b/addons/magazinerepack/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/main/stringtable.xml b/addons/main/stringtable.xml index f49394a68c..985bfb4836 100644 --- a/addons/main/stringtable.xml +++ b/addons/main/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/map/stringtable.xml b/addons/map/stringtable.xml index 42a0145d0b..73bf0cc774 100644 --- a/addons/map/stringtable.xml +++ b/addons/map/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/map_gestures/stringtable.xml b/addons/map_gestures/stringtable.xml index 464dcaf352..e89d6c07a3 100644 --- a/addons/map_gestures/stringtable.xml +++ b/addons/map_gestures/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/maptools/stringtable.xml b/addons/maptools/stringtable.xml index cde1096170..3db0d4d972 100644 --- a/addons/maptools/stringtable.xml +++ b/addons/maptools/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/markers/stringtable.xml b/addons/markers/stringtable.xml index 9d015b0403..44d64eb1e0 100644 --- a/addons/markers/stringtable.xml +++ b/addons/markers/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/medical/stringtable.xml b/addons/medical/stringtable.xml index 00cde86765..a3953be23b 100644 --- a/addons/medical/stringtable.xml +++ b/addons/medical/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/medical_menu/stringtable.xml b/addons/medical_menu/stringtable.xml index a55bb575cd..f825882be6 100644 --- a/addons/medical_menu/stringtable.xml +++ b/addons/medical_menu/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/microdagr/stringtable.xml b/addons/microdagr/stringtable.xml index fcc38b8f7c..c20ea7aede 100644 --- a/addons/microdagr/stringtable.xml +++ b/addons/microdagr/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/missileguidance/stringtable.xml b/addons/missileguidance/stringtable.xml index 1f188db453..ff14fea9f7 100644 --- a/addons/missileguidance/stringtable.xml +++ b/addons/missileguidance/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/missionmodules/stringtable.xml b/addons/missionmodules/stringtable.xml index 4fc1cd08b7..1043d99f64 100644 --- a/addons/missionmodules/stringtable.xml +++ b/addons/missionmodules/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/mk6mortar/stringtable.xml b/addons/mk6mortar/stringtable.xml index e77a771b38..f545bc8a35 100644 --- a/addons/mk6mortar/stringtable.xml +++ b/addons/mk6mortar/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/movement/stringtable.xml b/addons/movement/stringtable.xml index 4ab3d1253b..af5ce71af4 100644 --- a/addons/movement/stringtable.xml +++ b/addons/movement/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/mx2a/stringtable.xml b/addons/mx2a/stringtable.xml index ad46cebfde..e2c7ed2dc7 100644 --- a/addons/mx2a/stringtable.xml +++ b/addons/mx2a/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/nametags/stringtable.xml b/addons/nametags/stringtable.xml index a945339ead..5f048eeb4e 100644 --- a/addons/nametags/stringtable.xml +++ b/addons/nametags/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/nightvision/stringtable.xml b/addons/nightvision/stringtable.xml index abc0218908..708860d134 100644 --- a/addons/nightvision/stringtable.xml +++ b/addons/nightvision/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/optics/stringtable.xml b/addons/optics/stringtable.xml index 4fafdb1996..a6818a90d3 100644 --- a/addons/optics/stringtable.xml +++ b/addons/optics/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/optionsmenu/stringtable.xml b/addons/optionsmenu/stringtable.xml index 66ad0dd00b..b051e3f219 100644 --- a/addons/optionsmenu/stringtable.xml +++ b/addons/optionsmenu/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/overheating/stringtable.xml b/addons/overheating/stringtable.xml index f17ee88670..3269d9cf7e 100644 --- a/addons/overheating/stringtable.xml +++ b/addons/overheating/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/parachute/stringtable.xml b/addons/parachute/stringtable.xml index db21b182d1..880cc55e5f 100644 --- a/addons/parachute/stringtable.xml +++ b/addons/parachute/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/rangecard/stringtable.xml b/addons/rangecard/stringtable.xml index 0bd1160b87..e97a31195e 100644 --- a/addons/rangecard/stringtable.xml +++ b/addons/rangecard/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/realisticnames/stringtable.xml b/addons/realisticnames/stringtable.xml index ad8338b0f1..b9f6c85b93 100644 --- a/addons/realisticnames/stringtable.xml +++ b/addons/realisticnames/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/rearm/stringtable.xml b/addons/rearm/stringtable.xml index b7da05d989..7806735c57 100644 --- a/addons/rearm/stringtable.xml +++ b/addons/rearm/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/refuel/stringtable.xml b/addons/refuel/stringtable.xml index df30ac2380..2df51ea540 100644 --- a/addons/refuel/stringtable.xml +++ b/addons/refuel/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/reload/stringtable.xml b/addons/reload/stringtable.xml index f7412e1d2e..647322e8e6 100644 --- a/addons/reload/stringtable.xml +++ b/addons/reload/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/reloadlaunchers/stringtable.xml b/addons/reloadlaunchers/stringtable.xml index 5e38ce4009..72193d48e2 100644 --- a/addons/reloadlaunchers/stringtable.xml +++ b/addons/reloadlaunchers/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/repair/stringtable.xml b/addons/repair/stringtable.xml index 2af94c1ef2..fb505f4f4e 100644 --- a/addons/repair/stringtable.xml +++ b/addons/repair/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/respawn/stringtable.xml b/addons/respawn/stringtable.xml index 716679d0d0..e0d04aabfa 100644 --- a/addons/respawn/stringtable.xml +++ b/addons/respawn/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/safemode/stringtable.xml b/addons/safemode/stringtable.xml index a6847c17c8..9717ba4dae 100644 --- a/addons/safemode/stringtable.xml +++ b/addons/safemode/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/sandbag/stringtable.xml b/addons/sandbag/stringtable.xml index a1d7a46938..99be2bddf1 100644 --- a/addons/sandbag/stringtable.xml +++ b/addons/sandbag/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/scopes/stringtable.xml b/addons/scopes/stringtable.xml index 2e7918cb7d..8dc7a9eba0 100644 --- a/addons/scopes/stringtable.xml +++ b/addons/scopes/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/sitting/stringtable.xml b/addons/sitting/stringtable.xml index 2231ff5145..f7c7b84b93 100644 --- a/addons/sitting/stringtable.xml +++ b/addons/sitting/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/slideshow/stringtable.xml b/addons/slideshow/stringtable.xml index 5459adeea7..4c45399ba6 100644 --- a/addons/slideshow/stringtable.xml +++ b/addons/slideshow/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/spectator/stringtable.xml b/addons/spectator/stringtable.xml index 3ec849658f..b78febbef7 100644 --- a/addons/spectator/stringtable.xml +++ b/addons/spectator/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/spottingscope/stringtable.xml b/addons/spottingscope/stringtable.xml index a562e31c8c..3a0b89b857 100644 --- a/addons/spottingscope/stringtable.xml +++ b/addons/spottingscope/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/switchunits/stringtable.xml b/addons/switchunits/stringtable.xml index bd4fe13a56..60d7fb0ecd 100644 --- a/addons/switchunits/stringtable.xml +++ b/addons/switchunits/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/tacticalladder/stringtable.xml b/addons/tacticalladder/stringtable.xml index ab1ffbed9b..7a60933ceb 100644 --- a/addons/tacticalladder/stringtable.xml +++ b/addons/tacticalladder/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/tagging/stringtable.xml b/addons/tagging/stringtable.xml index 41964c9b13..2b1f38ba68 100644 --- a/addons/tagging/stringtable.xml +++ b/addons/tagging/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/trenches/stringtable.xml b/addons/trenches/stringtable.xml index a6b922a00f..617a604457 100644 --- a/addons/trenches/stringtable.xml +++ b/addons/trenches/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/tripod/stringtable.xml b/addons/tripod/stringtable.xml index c2abcff8bc..a57c6ca51d 100644 --- a/addons/tripod/stringtable.xml +++ b/addons/tripod/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/vector/stringtable.xml b/addons/vector/stringtable.xml index 9d1936304e..80135294d4 100644 --- a/addons/vector/stringtable.xml +++ b/addons/vector/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/vehiclelock/stringtable.xml b/addons/vehiclelock/stringtable.xml index 9b8b06fd40..32e9c762d0 100644 --- a/addons/vehiclelock/stringtable.xml +++ b/addons/vehiclelock/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/vehicles/stringtable.xml b/addons/vehicles/stringtable.xml index dcf2348175..005bba53a3 100644 --- a/addons/vehicles/stringtable.xml +++ b/addons/vehicles/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/viewdistance/stringtable.xml b/addons/viewdistance/stringtable.xml index 518f673455..a0f2bceb68 100644 --- a/addons/viewdistance/stringtable.xml +++ b/addons/viewdistance/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/weaponselect/stringtable.xml b/addons/weaponselect/stringtable.xml index 4a273a6cf3..c9a8e43f60 100644 --- a/addons/weaponselect/stringtable.xml +++ b/addons/weaponselect/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/weather/stringtable.xml b/addons/weather/stringtable.xml index f2e9027e68..0b0ed8fd17 100644 --- a/addons/weather/stringtable.xml +++ b/addons/weather/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/winddeflection/stringtable.xml b/addons/winddeflection/stringtable.xml index 8e8ad27e7a..6cb4858d21 100644 --- a/addons/winddeflection/stringtable.xml +++ b/addons/winddeflection/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/yardage450/stringtable.xml b/addons/yardage450/stringtable.xml index 4fdc0dfe72..c9f1c94b1b 100644 --- a/addons/yardage450/stringtable.xml +++ b/addons/yardage450/stringtable.xml @@ -1,4 +1,4 @@ - + diff --git a/addons/zeus/stringtable.xml b/addons/zeus/stringtable.xml index 8ef47b9b27..c07d4f7f84 100644 --- a/addons/zeus/stringtable.xml +++ b/addons/zeus/stringtable.xml @@ -1,4 +1,4 @@ - + From bcde9f8ed64cf4c7e6425c211df283b8a4e01c3c Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Mon, 28 Mar 2016 01:15:58 -0500 Subject: [PATCH 079/215] Filter minor falling damage to non-leg hitpoints --- addons/medical/functions/fnc_handleDamage_caching.sqf | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/medical/functions/fnc_handleDamage_caching.sqf b/addons/medical/functions/fnc_handleDamage_caching.sqf index cc969ce961..c1cf726399 100644 --- a/addons/medical/functions/fnc_handleDamage_caching.sqf +++ b/addons/medical/functions/fnc_handleDamage_caching.sqf @@ -58,6 +58,7 @@ if (_unit getVariable [QGVAR(isFalling), false]) then { } else { _newDamage = _newDamage * 0.5; }; + if (_newDamage < 0.075) then {_newDamage = 0;}; //Filter minor falling damage to non-leg hitpoints } else { if (_selectionName == "") then { _selectionName = selectRandom ["leg_l", "leg_r"]; From dc1af390cdf70459f284a44860b7b531c0e3390b Mon Sep 17 00:00:00 2001 From: jonpas Date: Mon, 28 Mar 2016 18:44:30 +0200 Subject: [PATCH 080/215] Allow custom texture for tagging (only direct function call) --- addons/tagging/CfgVehicles.hpp | 2 +- addons/tagging/functions/fnc_createTag.sqf | 18 ++++++++++++------ addons/tagging/functions/fnc_tagDirection.sqf | 6 +++--- addons/tagging/functions/fnc_tagGround.sqf | 6 +++--- addons/tagging/functions/fnc_tagWall.sqf | 6 +++--- 5 files changed, 22 insertions(+), 16 deletions(-) diff --git a/addons/tagging/CfgVehicles.hpp b/addons/tagging/CfgVehicles.hpp index 602ee41d33..ac0b82147c 100644 --- a/addons/tagging/CfgVehicles.hpp +++ b/addons/tagging/CfgVehicles.hpp @@ -98,4 +98,4 @@ class CfgVehicles { MACRO_ADDITEM(ACE_SpraypaintGreen,5); }; }; -}; \ No newline at end of file +}; diff --git a/addons/tagging/functions/fnc_createTag.sqf b/addons/tagging/functions/fnc_createTag.sqf index fdb2cd08b0..81758f8bdb 100644 --- a/addons/tagging/functions/fnc_createTag.sqf +++ b/addons/tagging/functions/fnc_createTag.sqf @@ -5,7 +5,7 @@ * Arguments: * 0: Position ASL * 1: Vector dir and up - * 2: Colour of the tag (valid colours are black, red, green and blue) + * 2: Colour of the tag (valid colours are black, red, green and blue or full path to custom texture) * 3: Object it should be tied too * * Return Value: @@ -19,15 +19,21 @@ #include "script_component.hpp" -params ["_tagPosASL", "_vectorDirAndUp", "_color", "_object"]; -TRACE_4("createTag:", _tagPosASL, _vectorDirAndUp, _color, _object); +params ["_tagPosASL", "_vectorDirAndUp", "_colorTexture", "_object"]; +TRACE_4("createTag:",_tagPosASL,_vectorDirAndUp,_colorTexture,_object); -if !((toLower _color) in ["black", "red", "green", "blue"]) exitWith { - ACE_LOGERROR_1("%1 is not a valid tag colour.", _color); +private _customTexture = [true, false] select (_colorTexture find ".paa" == -1); + +if (!_customTexture && {!((toLower _colorTexture) in ["black", "red", "green", "blue"])}) exitWith { + ACE_LOGERROR_1("%1 is not a valid tag colour.",_colorTexture); }; private _tag = "UserTexture1m_F" createVehicle [0,0,0]; -_tag setObjectTextureGlobal [0, '\z\ace\addons\tagging\UI\tags\' + _color + '\' + str (floor (random 3)) + '.paa']; +if (!_customTexture) then { + _tag setObjectTextureGlobal [0, "\z\ace\addons\tagging\UI\tags\" + _colorTexture + "\" + str (floor (random 3)) + ".paa"]; +} else { + _tag setObjectTextureGlobal [0, _colorTexture]; +}; _tag setPosASL _tagPosASL; _tag setVectorDirAndUp _vectorDirAndUp; diff --git a/addons/tagging/functions/fnc_tagDirection.sqf b/addons/tagging/functions/fnc_tagDirection.sqf index 2c03d97fd0..9dbb65f68e 100644 --- a/addons/tagging/functions/fnc_tagDirection.sqf +++ b/addons/tagging/functions/fnc_tagDirection.sqf @@ -6,7 +6,7 @@ * 0: Unit * 1: Start position ASL * 2: End position ASL - * 3: The colour of the tag (valid colours are black, red, green and blue) + * 3: The colour of the tag (valid colours are black, red, green and blue or full path to custom texture) * * Return Value: * Sucess @@ -19,7 +19,7 @@ #include "script_component.hpp" -params ["_unit", "_startPosASL", "_endPosASL", "_color"]; +params ["_unit", "_startPosASL", "_endPosASL", "_colorTexture"]; // Check for intersections below the unit private _intersections = lineIntersectsSurfaces [_startPosASL, _endPosASL, _unit, objNull, true, 1, "GEOM", "FIRE"]; @@ -102,6 +102,6 @@ _unit playActionNow "PutDown"; // Tell the server to create the tag and handle its destruction ["createTag", _this] call EFUNC(common,serverEvent); -}, [_touchingPoint vectorAdd (_surfaceNormal vectorMultiply 0.06), _vectorDirAndUp, _color, _object, _unit], 0.6] call EFUNC(common,waitAndExecute); +}, [_touchingPoint vectorAdd (_surfaceNormal vectorMultiply 0.06), _vectorDirAndUp, _colorTexture, _object, _unit], 0.6] call EFUNC(common,waitAndExecute); true diff --git a/addons/tagging/functions/fnc_tagGround.sqf b/addons/tagging/functions/fnc_tagGround.sqf index fa8d1795bf..dee9261e1e 100644 --- a/addons/tagging/functions/fnc_tagGround.sqf +++ b/addons/tagging/functions/fnc_tagGround.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Unit - * 1: The colour of the tag (valid colours are black, red, green and blue) + * 1: The colour of the tag (valid colours are black, red, green and blue or full path to custom texture) * * Return Value: * None @@ -17,9 +17,9 @@ #include "script_component.hpp" -params ["_unit", "_color"]; +params ["_unit", "_colorTexture"]; private _startPosASL = getPosASL _unit; private _endPosASL = _startPosASL vectorAdd [0, 0, -2] vectorAdd eyeDirection _unit; -[_unit, _startPosASL, _endPosASL, _color] call FUNC(tagDirection); +[_unit, _startPosASL, _endPosASL, _colorTexture] call FUNC(tagDirection); diff --git a/addons/tagging/functions/fnc_tagWall.sqf b/addons/tagging/functions/fnc_tagWall.sqf index 9b6485f4e8..85b24f7b92 100644 --- a/addons/tagging/functions/fnc_tagWall.sqf +++ b/addons/tagging/functions/fnc_tagWall.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: Unit - * 1: The colour of the tag (valid colours are black, red, green and blue) + * 1: The colour of the tag (valid colours are black, red, green and blue or full path to custom texture) * * Return Value: * None @@ -17,11 +17,11 @@ #include "script_component.hpp" -params ["_unit", "_color"]; +params ["_unit", "_colorTexture"]; private _startPosASL = eyePos _unit; private _cameraPosASL = AGLToASL positionCameraToWorld [0, 0, 0]; private _cameraDir = (AGLToASL positionCameraToWorld [0, 0, 1]) vectorDiff _cameraPosASL; private _endPosASL = _startPosASL vectorAdd (_cameraDir vectorMultiply 2.5); -[_unit, _startPosASL, _endPosASL, _color] call FUNC(tagDirection); +[_unit, _startPosASL, _endPosASL, _colorTexture] call FUNC(tagDirection); From 6469b11f3cd62defa0bf02c348872ccc195e476a Mon Sep 17 00:00:00 2001 From: jonpas Date: Mon, 28 Mar 2016 20:07:02 +0200 Subject: [PATCH 081/215] Cleanup tagging, use internal getTexture for getting texture from color, move tag size definition --- addons/tagging/CfgVehicles.hpp | 50 +++++-------------- addons/tagging/XEH_PREP.hpp | 6 +-- .../tagging/functions/fnc_checkTaggable.sqf | 2 +- addons/tagging/functions/fnc_createTag.sqf | 25 ++++------ addons/tagging/functions/fnc_getTexture.sqf | 26 ++++++++++ .../{fnc_tagDirection.sqf => fnc_tag.sqf} | 34 ++++++++----- addons/tagging/functions/fnc_tagGround.sqf | 25 ---------- addons/tagging/functions/fnc_tagWall.sqf | 27 ---------- addons/tagging/script_component.hpp | 3 ++ addons/tagging/stringtable.xml | 46 ++++------------- 10 files changed, 85 insertions(+), 159 deletions(-) create mode 100644 addons/tagging/functions/fnc_getTexture.sqf rename addons/tagging/functions/{fnc_tagDirection.sqf => fnc_tag.sqf} (78%) delete mode 100644 addons/tagging/functions/fnc_tagGround.sqf delete mode 100644 addons/tagging/functions/fnc_tagWall.sqf diff --git a/addons/tagging/CfgVehicles.hpp b/addons/tagging/CfgVehicles.hpp index ac0b82147c..af4daf6799 100644 --- a/addons/tagging/CfgVehicles.hpp +++ b/addons/tagging/CfgVehicles.hpp @@ -4,57 +4,31 @@ class CfgVehicles { class ACE_SelfActions { class ACE_Equipment { class ACE_tagWallBlack { - displayName = CSTRING(tagWallBlack); + displayName = CSTRING(TagBlack); condition = QUOTE(('ACE_SpraypaintBlack' in items ACE_player) && {[] call FUNC(checkTaggable)}); - statement = QUOTE([ARR_2(ACE_player,'black')] call FUNC(tagWall)); + statement = QUOTE([ARR_2(ACE_player,'black' call FUNC(getTexture))] call FUNC(tag)); showDisabled = 0; priority = 3; icon = QUOTE(PATHTOF(UI\icons\iconTaggingBlack.paa)); }; class ACE_tagWallRed: ACE_tagWallBlack { - displayName = CSTRING(tagWallRed); + displayName = CSTRING(TagRed); condition = QUOTE(('ACE_SpraypaintRed' in items ACE_player) && {[] call FUNC(checkTaggable)}); - statement = QUOTE([ARR_2(ACE_player,'red')] call FUNC(tagWall)); + statement = QUOTE([ARR_2(ACE_player,'red' call FUNC(getTexture))] call FUNC(tag)); icon = QUOTE(PATHTOF(UI\icons\iconTaggingRed.paa)); }; class ACE_tagWallGreen: ACE_tagWallBlack { - displayName = CSTRING(tagWallGreen); + displayName = CSTRING(TagGreen); condition = QUOTE(('ACE_SpraypaintGreen' in items ACE_player) && {[] call FUNC(checkTaggable)}); - statement = QUOTE([ARR_2(ACE_player,'green')] call FUNC(tagWall)); + statement = QUOTE([ARR_2(ACE_player,'green' call FUNC(getTexture))] call FUNC(tag)); icon = QUOTE(PATHTOF(UI\icons\iconTaggingGreen.paa)); }; class ACE_tagWallBlue: ACE_tagWallBlack { - displayName = CSTRING(tagWallBlue); + displayName = CSTRING(TagBlue); condition = QUOTE(('ACE_SpraypaintBlue' in items ACE_player) && {[] call FUNC(checkTaggable)}); - statement = QUOTE([ARR_2(ACE_player,'blue')] call FUNC(tagWall)); + statement = QUOTE([ARR_2(ACE_player,'blue' call FUNC(getTexture))] call FUNC(tag)); icon = QUOTE(PATHTOF(UI\icons\iconTaggingBlue.paa)); }; - /*class ACE_tagGroundBlack { - displayName = CSTRING(tagGroundBlack); - condition = QUOTE('ACE_SpraypaintBlack' in items ACE_player); - statement = QUOTE([ARR_2(ACE_player, 'black')] call FUNC(tagGround)); - showDisabled = 0; - priority = 3; - icon = QUOTE(PATHTOF(UI\icons\iconTaggingBlack.paa)); - }; - class ACE_tagGroundRed: ACE_tagGroundBlack { - displayName = CSTRING(tagGroundRed); - condition = QUOTE('ACE_SpraypaintRed' in items ACE_player); - statement = QUOTE([ARR_2(ACE_player, 'red')] call FUNC(tagGround)); - icon = QUOTE(PATHTOF(UI\icons\iconTaggingRed.paa)); - }; - class ACE_tagGroundGreen: ACE_tagGroundBlack { - displayName = CSTRING(tagGroundGreen); - condition = QUOTE('ACE_SpraypaintGreen' in items ACE_player); - statement = QUOTE([ARR_2(ACE_player, 'green')] call FUNC(tagGround)); - icon = QUOTE(PATHTOF(UI\icons\iconTaggingGreen.paa)); - }; - class ACE_tagGroundBlue: ACE_tagGroundBlack { - displayName = CSTRING(tagGroundBlue); - condition = QUOTE('ACE_SpraypaintBlue' in items ACE_player); - statement = QUOTE([ARR_2(ACE_player, 'blue')] call FUNC(tagGround)); - icon = QUOTE(PATHTOF(UI\icons\iconTaggingBlue.paa)); - };*/ }; }; }; @@ -64,26 +38,26 @@ class CfgVehicles { author = "jokoho48"; scope = 2; scopeCurator = 2; - displayName = CSTRING(spraypaintBlack); + displayName = CSTRING(SpraypaintBlack); vehicleClass = "Items"; class TransportItems { MACRO_ADDITEM(ACE_SpraypaintBlack,1); }; }; class ACE_Item_SpraypaintRed: ACE_Item_SpraypaintBlack { - displayName = CSTRING(spraypaintRed); + displayName = CSTRING(SpraypaintRed); class TransportItems { MACRO_ADDITEM(ACE_SpraypaintRed,1); }; }; class ACE_Item_SpraypaintGreen: ACE_Item_SpraypaintBlack { - displayName = CSTRING(spraypaintGreen); + displayName = CSTRING(SpraypaintGreen); class TransportItems { MACRO_ADDITEM(ACE_SpraypaintGreen,1); }; }; class ACE_Item_SpraypaintBlue: ACE_Item_SpraypaintBlack { - displayName = CSTRING(spraypaintBlue); + displayName = CSTRING(SpraypaintBlue); class TransportItems { MACRO_ADDITEM(ACE_SpraypaintBlue,1); }; diff --git a/addons/tagging/XEH_PREP.hpp b/addons/tagging/XEH_PREP.hpp index eb29d5a9e3..f8a8598cd7 100644 --- a/addons/tagging/XEH_PREP.hpp +++ b/addons/tagging/XEH_PREP.hpp @@ -1,7 +1,5 @@ - PREP(checkTaggable); PREP(createTag); -PREP(tagDirection); -PREP(tagGround); -PREP(tagWall); +PREP(getTexture); +PREP(tag); PREP(tagTestingThread); diff --git a/addons/tagging/functions/fnc_checkTaggable.sqf b/addons/tagging/functions/fnc_checkTaggable.sqf index 4c8f0c750a..b77473f25b 100644 --- a/addons/tagging/functions/fnc_checkTaggable.sqf +++ b/addons/tagging/functions/fnc_checkTaggable.sqf @@ -1,5 +1,5 @@ /* - * Author: BaerMitUmlaut and esteldunedain + * Author: BaerMitUmlaut, esteldunedain * Checks if there is a taggable surface within 2.5m in front of the player. * * Arguments: diff --git a/addons/tagging/functions/fnc_createTag.sqf b/addons/tagging/functions/fnc_createTag.sqf index 81758f8bdb..924fc5582c 100644 --- a/addons/tagging/functions/fnc_createTag.sqf +++ b/addons/tagging/functions/fnc_createTag.sqf @@ -1,5 +1,5 @@ /* - * Author: BaerMitUmlaut and esteldunedain + * Author: BaerMitUmlaut, esteldunedain * Creates a tag and handle its destruction. Only execute on the server. * * Arguments: @@ -9,7 +9,7 @@ * 3: Object it should be tied too * * Return Value: - * None + * Tag created * * Example: * [positionASL, vectorDirAndUp, "black", object] call ace_tagging_fnc_createTag @@ -19,25 +19,20 @@ #include "script_component.hpp" -params ["_tagPosASL", "_vectorDirAndUp", "_colorTexture", "_object"]; -TRACE_4("createTag:",_tagPosASL,_vectorDirAndUp,_colorTexture,_object); +params ["_tagPosASL", "_vectorDirAndUp", "_texture", "_object"]; +TRACE_4("createTag:",_tagPosASL,_vectorDirAndUp,_texture,_object); -private _customTexture = [true, false] select (_colorTexture find ".paa" == -1); - -if (!_customTexture && {!((toLower _colorTexture) in ["black", "red", "green", "blue"])}) exitWith { - ACE_LOGERROR_1("%1 is not a valid tag colour.",_colorTexture); +if (_texture == "") exitWith { + ACE_LOGERROR_1("%1 is not a valid tag texture.",_texture); + false }; private _tag = "UserTexture1m_F" createVehicle [0,0,0]; -if (!_customTexture) then { - _tag setObjectTextureGlobal [0, "\z\ace\addons\tagging\UI\tags\" + _colorTexture + "\" + str (floor (random 3)) + ".paa"]; -} else { - _tag setObjectTextureGlobal [0, _colorTexture]; -}; +_tag setObjectTextureGlobal [0, _texture]; _tag setPosASL _tagPosASL; _tag setVectorDirAndUp _vectorDirAndUp; -if (isNull _object) exitWith {}; +if (isNull _object) exitWith {true}; // If the tag is applied to an object, handle its destruction _object setVariable [QGVAR(testVar), true]; @@ -75,3 +70,5 @@ GVAR(tagsToTest) pushBack [_tag, _tagPosASL, _vectorDirAndUp]; if (!GVAR(testingThread)) then { call FUNC(tagTestingThread); }; + +true diff --git a/addons/tagging/functions/fnc_getTexture.sqf b/addons/tagging/functions/fnc_getTexture.sqf new file mode 100644 index 0000000000..f7f6d7e5e2 --- /dev/null +++ b/addons/tagging/functions/fnc_getTexture.sqf @@ -0,0 +1,26 @@ +/* + * Author: BaerMitUmlaut, esteldunedain, Jonpas + * Puts together a full path to the given tag color texture. Internal ACE3 textures only. + * + * Arguments: + * 0: The colour of the tag (valid colours are black, red, green and blue) + * + * Return Value: + * Texture (full path), "" if not found + * + * Example: + * texture = ["blue"] call ace_tagging_fnc_getTexture + * + * Public: No + */ + +#include "script_component.hpp" + +params ["_color"]; + +if !((toLower _color) in ["black", "red", "green", "blue"]) exitWith { + ACE_LOGERROR_1("%1 is not a valid tag colour.",_color); + "" +}; + +QUOTE(PATHTOF(UI)) + "\tags\" + _color + "\" + str (floor (random 3)) + ".paa" diff --git a/addons/tagging/functions/fnc_tagDirection.sqf b/addons/tagging/functions/fnc_tag.sqf similarity index 78% rename from addons/tagging/functions/fnc_tagDirection.sqf rename to addons/tagging/functions/fnc_tag.sqf index 9dbb65f68e..3bd559f702 100644 --- a/addons/tagging/functions/fnc_tagDirection.sqf +++ b/addons/tagging/functions/fnc_tag.sqf @@ -1,25 +1,35 @@ /* - * Author: BaerMitUmlaut and esteldunedain - * If possible, create a tag on the first surface between Start and End positions + * Author: BaerMitUmlaut, esteldunedain + * Creates a tag on a wall that is on the closest surface within 2m on front of the unit. * * Arguments: - * 0: Unit - * 1: Start position ASL - * 2: End position ASL - * 3: The colour of the tag (valid colours are black, red, green and blue or full path to custom texture) + * 0: Unit + * 1: The colour of the tag (valid colours are black, red, green and blue or full path to custom texture) * * Return Value: - * Sucess + * Sucess * * Example: - * [startPosASL, directiom "blue"] call ace_tagging_fnc_tagDirection + * success = [player, "blue"] call ace_tagging_fnc_tag * - * Public: No + * Public: Yes */ #include "script_component.hpp" -params ["_unit", "_startPosASL", "_endPosASL", "_colorTexture"]; +params [ + ["_unit", objNull, [objNull]], + ["_texture", "", [""]] +]; + +if (isNull _unit || {_texture == ""}) exitWith { + ACE_LOGERROR_2("Tag parameters invalid. Unit: %1, Texture: %2",_unit,_texture); +}; + +private _startPosASL = eyePos _unit; +private _cameraPosASL = AGLToASL positionCameraToWorld [0, 0, 0]; +private _cameraDir = (AGLToASL positionCameraToWorld [0, 0, 1]) vectorDiff _cameraPosASL; +private _endPosASL = _startPosASL vectorAdd (_cameraDir vectorMultiply 2.5); // Check for intersections below the unit private _intersections = lineIntersectsSurfaces [_startPosASL, _endPosASL, _unit, objNull, true, 1, "GEOM", "FIRE"]; @@ -79,8 +89,6 @@ _fnc_isOk = { true }; -#define TAG_SIZE 0.6 - if ( !([ 0.5*TAG_SIZE, 0.5*TAG_SIZE] call _fnc_isOk) || {!([ 0.5*TAG_SIZE,-0.5*TAG_SIZE] call _fnc_isOk) || {!([-0.5*TAG_SIZE, 0.5*TAG_SIZE] call _fnc_isOk) || @@ -102,6 +110,6 @@ _unit playActionNow "PutDown"; // Tell the server to create the tag and handle its destruction ["createTag", _this] call EFUNC(common,serverEvent); -}, [_touchingPoint vectorAdd (_surfaceNormal vectorMultiply 0.06), _vectorDirAndUp, _colorTexture, _object, _unit], 0.6] call EFUNC(common,waitAndExecute); +}, [_touchingPoint vectorAdd (_surfaceNormal vectorMultiply 0.06), _vectorDirAndUp, _texture, _object, _unit], 0.6] call EFUNC(common,waitAndExecute); true diff --git a/addons/tagging/functions/fnc_tagGround.sqf b/addons/tagging/functions/fnc_tagGround.sqf deleted file mode 100644 index dee9261e1e..0000000000 --- a/addons/tagging/functions/fnc_tagGround.sqf +++ /dev/null @@ -1,25 +0,0 @@ -/* - * Author: BaerMitUmlaut and esteldunedain - * Creates a tag on the ground beneath the unit - * - * Arguments: - * 0: Unit - * 1: The colour of the tag (valid colours are black, red, green and blue or full path to custom texture) - * - * Return Value: - * None - * - * Example: - * [player, "blue"] call ace_tagging_fnc_tagGround - * - * Public: No - */ - -#include "script_component.hpp" - -params ["_unit", "_colorTexture"]; - -private _startPosASL = getPosASL _unit; -private _endPosASL = _startPosASL vectorAdd [0, 0, -2] vectorAdd eyeDirection _unit; - -[_unit, _startPosASL, _endPosASL, _colorTexture] call FUNC(tagDirection); diff --git a/addons/tagging/functions/fnc_tagWall.sqf b/addons/tagging/functions/fnc_tagWall.sqf deleted file mode 100644 index 85b24f7b92..0000000000 --- a/addons/tagging/functions/fnc_tagWall.sqf +++ /dev/null @@ -1,27 +0,0 @@ -/* - * Author: BaerMitUmlaut and esteldunedain - * Creates a tag on a wall that is on the closest surface within 2m on front of the unit. - * - * Arguments: - * 0: Unit - * 1: The colour of the tag (valid colours are black, red, green and blue or full path to custom texture) - * - * Return Value: - * None - * - * Example: - * [player, "blue"] call ace_tagging_fnc_tagWall - * - * Public: No - */ - -#include "script_component.hpp" - -params ["_unit", "_colorTexture"]; - -private _startPosASL = eyePos _unit; -private _cameraPosASL = AGLToASL positionCameraToWorld [0, 0, 0]; -private _cameraDir = (AGLToASL positionCameraToWorld [0, 0, 1]) vectorDiff _cameraPosASL; -private _endPosASL = _startPosASL vectorAdd (_cameraDir vectorMultiply 2.5); - -[_unit, _startPosASL, _endPosASL, _colorTexture] call FUNC(tagDirection); diff --git a/addons/tagging/script_component.hpp b/addons/tagging/script_component.hpp index bb94aae3ff..4836d2f209 100644 --- a/addons/tagging/script_component.hpp +++ b/addons/tagging/script_component.hpp @@ -15,3 +15,6 @@ #endif #include "\z\ace\addons\main\script_macros.hpp" + + +#define TAG_SIZE 0.6 diff --git a/addons/tagging/stringtable.xml b/addons/tagging/stringtable.xml index 392de0d24f..0bab4f29c1 100644 --- a/addons/tagging/stringtable.xml +++ b/addons/tagging/stringtable.xml @@ -1,91 +1,63 @@  - + Tag black Schwarz markieren Marcar en negro Oznakuj na czarno Tag noir - + Tag red Rot markieren Marcar en rojo Oznakuj na czerwono Tag rouge - + Tag green Grün markieren Marcar en verde Oznakuj na zielono Tag vert - + Tag blue Blau markieren Marcar en azul Oznakuj na niebiesko Tag bleu - - Tag ground black - Boden schwarz markieren - Oznakuj ziemię na czarno - Marcar suelo en negro - Tag fond noir - - - Tag ground red - Boden rot markieren - Oznakuj ziemię na czerwono - Marcar suelo en rojo - Tag fond rouge - - - Tag ground green - Boden grün markieren - Oznakuj ziemię na zielono - Marcar suelo en verde - Tag fond vert - - - Tag ground blue - Boden blau markieren - Oznakuj ziemię na niebiesko - Marcar suelo en azul - Tag font bleu - - + Black spray paint Schwarze Sprühfarbe Pintura negra Czarna farba w sprayu Peinture pulvérisée noire - + Red spray paint Rote Sprühfarbe Pintura roja Czerwona farba w sprayu Peinture pulvérisée rouge - + Green spray paint Grüne Sprühfarbe Pintura verde Zielona farba w sprayu Peinture pulvérisée verte - + Blue spray paint Blaue Sprühfarbe Pintura azul Niebieska farba w sprayu Peinture pulvérisée bleue - + A can of spray paint for tagging walls. Eine Farbsprühdose um Wände zu markieren. Lata de pintura en aerosol para marcar. From 666a4030b51ffbde67b160cda21084b8b97380b8 Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 29 Mar 2016 13:21:13 +0200 Subject: [PATCH 082/215] make FUNC(scriptedExplosive) work in scheduled env, ref #3621 --- addons/explosives/functions/fnc_scriptedExplosive.sqf | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/addons/explosives/functions/fnc_scriptedExplosive.sqf b/addons/explosives/functions/fnc_scriptedExplosive.sqf index b4abb204b3..6a554ac09c 100644 --- a/addons/explosives/functions/fnc_scriptedExplosive.sqf +++ b/addons/explosives/functions/fnc_scriptedExplosive.sqf @@ -4,7 +4,7 @@ * detonate editor-placed explosives. * * Arguments: - * 0: Explosives objects to detonate + * 0: Explosives objects to detonate * 1: Fuze delay (for each explosive; use negative number for random time up to value) * * Return Value: @@ -18,10 +18,13 @@ */ #include "script_component.hpp" -params ["_explosiveArr",["_fuzeTime",0]]; +params [["_explosiveArr", [], [[], objNull]], ["_fuzeTime", 0, [0]]]; + +if (_explosiveArr isEqualType objNull) then { + _explosiveArr = [_explosiveArr]; +}; -private _detTime; { - _detTime = if (_fuzeTime < 0) then {random abs _fuzeTime} else {_fuzeTime}; + private _detTime = if (_fuzeTime < 0) then {random abs _fuzeTime} else {_fuzeTime}; [objNull, -1, [_x, _detTime]] call FUNC(detonateExplosive); } forEach _explosiveArr; From 1f6f90a5b23069938e728bf350e1c22de462961e Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 29 Mar 2016 13:59:07 +0200 Subject: [PATCH 083/215] fixerrornoname --- addons/common/CfgEventHandlers.hpp | 2 +- addons/common/functions/fnc_setName.sqf | 8 +------- addons/common/script_component.hpp | 2 ++ 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/addons/common/CfgEventHandlers.hpp b/addons/common/CfgEventHandlers.hpp index 2c4f3922bc..6340402639 100644 --- a/addons/common/CfgEventHandlers.hpp +++ b/addons/common/CfgEventHandlers.hpp @@ -33,7 +33,7 @@ class Extended_InitPost_EventHandlers { }; class CAManBase { class GVAR(setName) { - init = QUOTE(if (local (_this select 0)) then {_this call FUNC(setName)};); + init = QUOTE(if (local (_this select 0)) then {[ARR_3(FUNC(setName), _this, DELAY_SETNAME)] call FUNC(waitAndExecute)};); }; class GVAR(muteUnit) { init = QUOTE(_this call FUNC(muteUnitHandleInitPost)); diff --git a/addons/common/functions/fnc_setName.sqf b/addons/common/functions/fnc_setName.sqf index b9ecbdc3a6..1b2b515ec2 100644 --- a/addons/common/functions/fnc_setName.sqf +++ b/addons/common/functions/fnc_setName.sqf @@ -19,13 +19,7 @@ if (isNull _unit || {!alive _unit}) exitWith {}; if (_unit isKindOf "CAManBase") then { private _sanitizedName = [name _unit, true] call FUNC(sanitizeString); private _rawName = [name _unit, false] call FUNC(sanitizeString); - - //Debug Testing Code (with html tags): - // private _sanitizedName = ["Name", true] call FUNC(sanitizeString); - // private _rawName = ["Name", false] call FUNC(sanitizeString); - - //if (_name != _unit getVariable ["ACE_Name", ""]) then { + _unit setVariable ["ACE_Name", _sanitizedName, true]; _unit setVariable ["ACE_NameRaw", _rawName, true]; - //}; }; diff --git a/addons/common/script_component.hpp b/addons/common/script_component.hpp index 4e941943fa..3b915f2c24 100644 --- a/addons/common/script_component.hpp +++ b/addons/common/script_component.hpp @@ -19,3 +19,5 @@ #define VERSION_CONFIG_COMMON VERSION_CONFIG;\ versionDesc = "ACE 3";\ versionAct = QUOTE(call COMPILE_FILE(init_versionTooltip)) + +#define DELAY_SETNAME 1 From 4e1b2dd24a97481bf822145c12cc20994a034459 Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 29 Mar 2016 15:32:05 +0200 Subject: [PATCH 084/215] just delay setName one frame --- addons/common/CfgEventHandlers.hpp | 2 +- addons/common/script_component.hpp | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/addons/common/CfgEventHandlers.hpp b/addons/common/CfgEventHandlers.hpp index 6340402639..6e8528cf03 100644 --- a/addons/common/CfgEventHandlers.hpp +++ b/addons/common/CfgEventHandlers.hpp @@ -33,7 +33,7 @@ class Extended_InitPost_EventHandlers { }; class CAManBase { class GVAR(setName) { - init = QUOTE(if (local (_this select 0)) then {[ARR_3(FUNC(setName), _this, DELAY_SETNAME)] call FUNC(waitAndExecute)};); + init = QUOTE(if (local (_this select 0)) then {[ARR_2(FUNC(setName),_this)] call FUNC(execNextFrame)};); }; class GVAR(muteUnit) { init = QUOTE(_this call FUNC(muteUnitHandleInitPost)); diff --git a/addons/common/script_component.hpp b/addons/common/script_component.hpp index 3b915f2c24..4e941943fa 100644 --- a/addons/common/script_component.hpp +++ b/addons/common/script_component.hpp @@ -19,5 +19,3 @@ #define VERSION_CONFIG_COMMON VERSION_CONFIG;\ versionDesc = "ACE 3";\ versionAct = QUOTE(call COMPILE_FILE(init_versionTooltip)) - -#define DELAY_SETNAME 1 From c24c1b9dc0d427469350d0c917fd48ad96b9b188 Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 29 Mar 2016 15:39:32 +0200 Subject: [PATCH 085/215] Fix inverted Stop and Freeze - prone Stop will still be freeze due to BI animation being wrong --- addons/gestures/CfgVehicles.hpp | 12 ++++---- .../anim/{ace_stop.rtm => ace_freeze.rtm} | Bin ...wered.rtm => ace_freeze_stand_lowered.rtm} | Bin addons/gestures/cfgMovesBasic.hpp | 16 +++++------ addons/gestures/key.sqf | 2 +- addons/gestures/stringtable.xml | 26 +++++++++--------- 6 files changed, 28 insertions(+), 28 deletions(-) rename addons/gestures/anim/{ace_stop.rtm => ace_freeze.rtm} (100%) rename addons/gestures/anim/{ace_stop_stand_lowered.rtm => ace_freeze_stand_lowered.rtm} (100%) diff --git a/addons/gestures/CfgVehicles.hpp b/addons/gestures/CfgVehicles.hpp index d3c7b5ca21..17dbfc0846 100644 --- a/addons/gestures/CfgVehicles.hpp +++ b/addons/gestures/CfgVehicles.hpp @@ -46,10 +46,10 @@ class CfgVehicles { showDisabled = 1; priority = 1.3; }; - class GVAR(Freeze) { - displayName = CSTRING(BIgestureFreeze); + class GVAR(Stop) { + displayName = CSTRING(stop); condition = QUOTE(canStand _target); - statement = QUOTE(_target playActionNow 'gestureFreeze';); + statement = QUOTE(_target playActionNow 'gestureFreeze';); // BI animation - is actualls "stop" in all stances but prone showDisabled = 1; priority = 1.2; }; @@ -67,10 +67,10 @@ class CfgVehicles { showDisabled = 1; priority = 1.8; }; - class GVAR(Stop) { - displayName = CSTRING(stop); + class GVAR(Freeze) { + displayName = CSTRING(freeze); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); - statement = QUOTE(QUOTE(QGVAR(stop)) call FUNC(playSignal)); + statement = QUOTE(QUOTE(QGVAR(freeze)) call FUNC(playSignal)); showDisabled = 1; priority = 1.7; }; diff --git a/addons/gestures/anim/ace_stop.rtm b/addons/gestures/anim/ace_freeze.rtm similarity index 100% rename from addons/gestures/anim/ace_stop.rtm rename to addons/gestures/anim/ace_freeze.rtm diff --git a/addons/gestures/anim/ace_stop_stand_lowered.rtm b/addons/gestures/anim/ace_freeze_stand_lowered.rtm similarity index 100% rename from addons/gestures/anim/ace_stop_stand_lowered.rtm rename to addons/gestures/anim/ace_freeze_stand_lowered.rtm diff --git a/addons/gestures/cfgMovesBasic.hpp b/addons/gestures/cfgMovesBasic.hpp index a708787fd5..50a835abe6 100644 --- a/addons/gestures/cfgMovesBasic.hpp +++ b/addons/gestures/cfgMovesBasic.hpp @@ -1,7 +1,7 @@ class CfgMovesBasic { class ManActions { GVAR(forward) = QGVAR(forward); - GVAR(stop) = QGVAR(stop); + GVAR(freeze) = QGVAR(freeze); GVAR(cover) = QGVAR(cover); GVAR(regroup) = QGVAR(regroup); GVAR(engage) = QGVAR(engage); @@ -10,7 +10,7 @@ class CfgMovesBasic { GVAR(warning) = QGVAR(warningS); GVAR(forwardStandLowered) = QGVAR(forwardStandLowered); - GVAR(stopStandLowered) = QGVAR(stopStandLowered); + GVAR(freezeStandLowered) = QGVAR(freezeStandLowered); GVAR(coverStandLowered) = QGVAR(coverStandLowered); GVAR(regroupStandLowered) = QGVAR(regroupStandLowered); GVAR(engageStandLowered) = QGVAR(engageStandLowered); @@ -22,7 +22,7 @@ class CfgMovesBasic { class Actions { class NoActions: ManActions { GVAR(forward)[] = {QGVAR(forward), "Gesture"}; - GVAR(stop)[] = {QGVAR(stop), "Gesture"}; + GVAR(freeze)[] = {QGVAR(freeze), "Gesture"}; GVAR(cover)[] = {QGVAR(cover), "Gesture"}; GVAR(regroup)[] = {QGVAR(regroup), "Gesture"}; GVAR(engage)[] = {QGVAR(engage), "Gesture"}; @@ -31,7 +31,7 @@ class CfgMovesBasic { GVAR(warning)[] = {QGVAR(warning), "Gesture"}; GVAR(forwardStandLowered)[] = {QGVAR(forwardStandLowered), "Gesture"}; - GVAR(stopStandLowered)[] = {QGVAR(stopStandLowered), "Gesture"}; + GVAR(freezeStandLowered)[] = {QGVAR(freezeStandLowered), "Gesture"}; GVAR(coverStandLowered)[] = {QGVAR(coverStandLowered), "Gesture"}; GVAR(regroupStandLowered)[] = {QGVAR(regroupStandLowered), "Gesture"}; GVAR(engageStandLowered)[] = {QGVAR(engageStandLowered), "Gesture"}; @@ -134,13 +134,13 @@ class CfgGesturesMale { file = QUOTE(PATHTOF(anim\ace_forward_stand_lowered.rtm)); }; - class GVAR(stop): GVAR(forward) { - file = QUOTE(PATHTOF(anim\ace_stop.rtm)); + class GVAR(freeze): GVAR(forward) { + file = QUOTE(PATHTOF(anim\ace_freeze.rtm)); speed = 0.6; }; - class GVAR(stopStandLowered): GVAR(stop) { - file = QUOTE(PATHTOF(anim\ace_stop_stand_lowered.rtm)); + class GVAR(freezeStandLowered): GVAR(freeze) { + file = QUOTE(PATHTOF(anim\ace_freeze_stand_lowered.rtm)); }; class GVAR(cover): GVAR(forward) { diff --git a/addons/gestures/key.sqf b/addons/gestures/key.sqf index 54d6d50c0c..589f116f5b 100644 --- a/addons/gestures/key.sqf +++ b/addons/gestures/key.sqf @@ -25,7 +25,7 @@ false } count [ - ["stop", DIK_NUMPAD2], + ["freeze", DIK_NUMPAD2], ["cover", DIK_NUMPAD3], ["forward", DIK_NUMPAD4], ["regroup", DIK_NUMPAD5], diff --git a/addons/gestures/stringtable.xml b/addons/gestures/stringtable.xml index 1f008ddae9..7ad0e4eaa6 100644 --- a/addons/gestures/stringtable.xml +++ b/addons/gestures/stringtable.xml @@ -97,19 +97,6 @@ Apontar Puntare a - - Freeze - Keine Bewegung - Alto - Stać - Stát - Halte - Замереть - Állj - Alto - Fermi - - Stop Stop @@ -121,6 +108,19 @@ Stop Detenerse + + + Freeze + Keine Bewegung + Alto + Stać + Stát + Halte + Замереть + Állj + Alto + Fermi + Cover From 3489dd48bb4851ecb895e21ed08976b737ec4795 Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 29 Mar 2016 15:51:51 +0200 Subject: [PATCH 086/215] Remove unused gestures, Improve stringtabling and remove duplicate --- addons/gestures/ACE_Settings.hpp | 6 +-- addons/gestures/CfgVehicles.hpp | 55 ++++++---------------- addons/gestures/key.sqf | 37 ++++++++------- addons/gestures/stringtable.xml | 80 +++++++------------------------- 4 files changed, 54 insertions(+), 124 deletions(-) diff --git a/addons/gestures/ACE_Settings.hpp b/addons/gestures/ACE_Settings.hpp index a9e77807c0..8ed8aedb6b 100644 --- a/addons/gestures/ACE_Settings.hpp +++ b/addons/gestures/ACE_Settings.hpp @@ -4,8 +4,8 @@ class ACE_Settings { typeName = "SCALAR"; isClientSettable = 1; category = ECSTRING(interact_menu,Category_InteractionMenu); - displayName = CSTRING(showOnInteractionMenu_displayName); - description = CSTRING(showOnInteractionMenu_description); - values[] = {"$STR_A3_OPTIONS_DISABLED", CSTRING(justKeybinds), CSTRING(keysAndInteractionMenu)}; + displayName = CSTRING(ShowOnInteractionMenu_displayName); + description = CSTRING(ShowOnInteractionMenu_description); + values[] = {"$STR_A3_OPTIONS_DISABLED", CSTRING(JustKeybinds), CSTRING(KeysAndInteractionMenu)}; }; }; diff --git a/addons/gestures/CfgVehicles.hpp b/addons/gestures/CfgVehicles.hpp index 17dbfc0846..4bf98f4978 100644 --- a/addons/gestures/CfgVehicles.hpp +++ b/addons/gestures/CfgVehicles.hpp @@ -12,131 +12,104 @@ class CfgVehicles { icon = PATHTOF(UI\gestures_ca.paa); class GVAR(Advance) { - displayName = CSTRING(BIgestureAdvance); + displayName = CSTRING(Advance); condition = QUOTE(canStand _target); statement = QUOTE(_target playActionNow 'gestureAdvance';); showDisabled = 1; priority = 1.9; }; class GVAR(Go) { - displayName = CSTRING(BIgestureGo); + displayName = CSTRING(Go); condition = QUOTE(canStand _target); statement = QUOTE(_target playActionNow ([ARR_2('gestureGo','gestureGoB')] select floor random 2);); showDisabled = 1; priority = 1.8; }; class GVAR(Follow) { - displayName = CSTRING(BIgestureFollow); + displayName = CSTRING(Follow); condition = QUOTE(canStand _target); statement = QUOTE(_target playActionNow 'gestureFollow';); showDisabled = 1; priority = 1.7; }; class GVAR(Up) { - displayName = CSTRING(BIgestureUp); + displayName = CSTRING(Up); condition = QUOTE(canStand _target); statement = QUOTE(_target playActionNow 'gestureUp';); showDisabled = 1; priority = 1.5; }; class GVAR(CeaseFire) { - displayName = CSTRING(BIgestureCeaseFire); + displayName = CSTRING(CeaseFire); condition = QUOTE(canStand _target); statement = QUOTE(_target playActionNow 'gestureCeaseFire';); showDisabled = 1; priority = 1.3; }; class GVAR(Stop) { - displayName = CSTRING(stop); + displayName = CSTRING(Stop); condition = QUOTE(canStand _target); statement = QUOTE(_target playActionNow 'gestureFreeze';); // BI animation - is actualls "stop" in all stances but prone showDisabled = 1; priority = 1.2; }; class GVAR(Forward) { - displayName = CSTRING(forward); + displayName = CSTRING(Forward); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(forward)) call FUNC(playSignal)); showDisabled = 1; priority = 1.9; }; class GVAR(Regroup) { - displayName = CSTRING(regroup); + displayName = CSTRING(Regroup); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(regroup)) call FUNC(playSignal)); showDisabled = 1; priority = 1.8; }; class GVAR(Freeze) { - displayName = CSTRING(freeze); + displayName = CSTRING(Freeze); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(freeze)) call FUNC(playSignal)); showDisabled = 1; priority = 1.7; }; class GVAR(Cover) { - displayName = CSTRING(cover); + displayName = CSTRING(Cover); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(cover)) call FUNC(playSignal)); showDisabled = 1; priority = 1.6; }; class GVAR(Point) { - displayName = CSTRING(point); + displayName = CSTRING(Point); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(point)) call FUNC(playSignal)); showDisabled = 1; priority = 1.5; }; class GVAR(Engage) { - displayName = CSTRING(engage); + displayName = CSTRING(Engage); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(engage)) call FUNC(playSignal)); showDisabled = 1; priority = 1.4; }; class GVAR(Hold) { - displayName = CSTRING(hold); + displayName = CSTRING(Hold); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(hold)) call FUNC(playSignal)); showDisabled = 1; priority = 1.3; }; class GVAR(Warning) { - displayName = CSTRING(warning); + displayName = CSTRING(Warning); condition = QUOTE(canStand _target && GVAR(ReloadMutex)); statement = QUOTE(QUOTE(QGVAR(warning)) call FUNC(playSignal)); showDisabled = 1; priority = 1.2; }; - /* - class class GVAR(Yes) { - displayName = ECSTRING(common,Yes); - condition = QUOTE(canStand _target); - statement = QUOTE(_target playActionNow ([ARR_2('gestureYes','gestureNod')] select floor random 2);); - showDisabled = 1; - priority = 1.1; - }; - - class class GVAR(No) { - displayName = ECSTRING(common,No); - condition = QUOTE(canStand _target); - statement = QUOTE(_target playActionNow 'gestureNo';); - showDisabled = 1; - priority = 1.0; - }; - - class class GVAR(Hi) { - displayName = CSTRING(Hi); - condition = QUOTE(canStand _target); - statement = QUOTE(_target playActionNow ([ARR_3('gestureHi','gestureHiB','gestureHiC')] select floor random 3);); - showDisabled = 1; - priority = 0.9; - }; - */ - }; - }; }; }; diff --git a/addons/gestures/key.sqf b/addons/gestures/key.sqf index 589f116f5b..98c21d4862 100644 --- a/addons/gestures/key.sqf +++ b/addons/gestures/key.sqf @@ -4,19 +4,20 @@ _x params ["_currentName","_key"]; private _signalName = format [QGVAR(%1), _currentName]; - if (_currentName select [0,2] == "BI") then { - //Don't add "ace_gestures_" prefix to BI gestures + + //Don't add "ace_gestures_" prefix to BI gestures + if (_key == -1) then { _signalName = _currentName; }; - private _code = (compile format [QUOTE('%1' call FUNC(playSignal);), _signalName]); + private _code = compile format [QUOTE('%1' call FUNC(playSignal)), _signalName]; TRACE_4("Adding KeyBind",_currentName,_signalName,_code,_key); [ "ACE3 Gestures", _currentName, - localize format[LSTRING(%1), _currentName], + localize format [LSTRING(%1), _currentName], _code, {false}, [_key, [false, (_key != -1), false]], @@ -25,18 +26,18 @@ false } count [ - ["freeze", DIK_NUMPAD2], - ["cover", DIK_NUMPAD3], - ["forward", DIK_NUMPAD4], - ["regroup", DIK_NUMPAD5], - ["engage", DIK_NUMPAD6], - ["point", DIK_NUMPAD7], - ["hold", DIK_NUMPAD8], - ["warning", DIK_NUMPAD9], - ["BIgestureGo", -1], - ["BIgestureAdvance", -1], - ["BIgestureFollow", -1], - ["BIgestureUp", -1], - ["BIgestureFreeze", -1], - ["BIgestureCeaseFire", -1] + ["Freeze", DIK_NUMPAD2], + ["Cover", DIK_NUMPAD3], + ["Forward", DIK_NUMPAD4], + ["Regroup", DIK_NUMPAD5], + ["Engage", DIK_NUMPAD6], + ["Point", DIK_NUMPAD7], + ["Hold", DIK_NUMPAD8], + ["Warning", DIK_NUMPAD9], + ["Go", -1], + ["Advance", -1], + ["Follow", -1], + ["Up", -1], + ["Stop", -1], + ["CeaseFire", -1] ]; diff --git a/addons/gestures/stringtable.xml b/addons/gestures/stringtable.xml index 7ad0e4eaa6..56b77e97e9 100644 --- a/addons/gestures/stringtable.xml +++ b/addons/gestures/stringtable.xml @@ -25,7 +25,7 @@ Gestos Gesti - + Advance Vordringen Avanzar @@ -37,7 +37,7 @@ Avançar Avanzare - + Go Los Adelante @@ -49,7 +49,7 @@ Mover-se Muoversi - + Follow Folgen Seguirme @@ -61,7 +61,7 @@ Seguir Seguire - + Up Aufstehen Arriba @@ -73,7 +73,7 @@ Acima Alzarsi - + Cease Fire Feuer einstellen Alto el fuego @@ -85,19 +85,7 @@ Cessar Fogo Cessare il Fuoco - - Point - Zeigen - Señalar - Wskazać - Ukázat - Pointer - Показать направление - Mutat - Apontar - Puntare a - - + Stop Stop Halt @@ -108,8 +96,7 @@ Stop Detenerse - - + Freeze Keine Bewegung Alto @@ -121,8 +108,7 @@ Alto Fermi - - + Cover Deckung Cubrirse @@ -134,8 +120,7 @@ Proteger-se Copertura - - + Rally up Regroupement Sammeln @@ -146,8 +131,7 @@ Raggruppare Reunirse - - + Move forward En avant Vorwärts Bewegen @@ -158,8 +142,7 @@ Muovere avanti Avanzar - - + Engage Angriff Engager @@ -170,8 +153,7 @@ Ingaggiare Atacar - - + Point Pointer Zeigen @@ -182,8 +164,7 @@ Puntare Señalar - - + Hold Tenir Anhalten @@ -194,8 +175,7 @@ Mantenere Esperar - - + Warning Attention Achtung @@ -206,31 +186,7 @@ Attenzione Atención - - Hi - Hallo - Hola - Witaj - Ahoj - Salut - Привет - Helló - Olá - Ciao - - - Attack - Angreifen - Atacar - Do ataku - Zaútočit - Attaquer - Атаковать - Támadás - Atacar - Attaccare - - + Show Gestures On Interaction Menu Zeige Gesten im Interaktionsmenü Zobrazit posunky v interakčním menu @@ -239,7 +195,7 @@ Mostrar gestos en el menú de interacción Afficher les gestes au menu d'interaction. - + Show gestures on the self interaction menu, or just use keybinds, or disable completely Zeige Gesten im Selbst-Interkationsmenü, lege sie auf Schnelltasten, oder deaktiviere sie vollständig. Zobrazit posunky pro vlastní interakční menu, nebo prostě použít klávesové zkratky, nebo to zakázat úplně @@ -248,7 +204,7 @@ Muestror los gestos en el menú de interacción propia, utilizar solo combinación de teclas o desactivarlos completamente Afficher les gestes dans le menu d'interaction personnel, ou seulement utiliser les touches, ou desactiver complètement. - + Just Keybinds Nur Schnelltasten Pouze klávesové zkratky @@ -257,7 +213,7 @@ Solo mediante teclas Seulement les touches - + Keybinds + Interaction Menu Schnelltasten+ Interaktionsmenü Klávesové zkratky + interakční menu From 330977a709858636f27275463e0fdc7b7fe0f8e6 Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 29 Mar 2016 16:03:41 +0200 Subject: [PATCH 087/215] Remove including DIK KeyCodes definitions, use decimal codes, Improve BI gesture handling even further --- addons/gestures/XEH_postInit.sqf | 42 ++++++++++++++++++++++++++++++- addons/gestures/key.sqf | 43 -------------------------------- 2 files changed, 41 insertions(+), 44 deletions(-) delete mode 100644 addons/gestures/key.sqf diff --git a/addons/gestures/XEH_postInit.sqf b/addons/gestures/XEH_postInit.sqf index 3b4a92164e..ea63e2a388 100644 --- a/addons/gestures/XEH_postInit.sqf +++ b/addons/gestures/XEH_postInit.sqf @@ -5,4 +5,44 @@ if (!hasInterface) exitWith {}; // reload mutex, you can't play signal while reloading GVAR(ReloadMutex) = true; -#include "key.sqf" +{ + _x params ["_currentName", "_key", ["_vanillaKey", ""] ]; + + private _signalName = format [QGVAR(%1), _currentName]; + + // Don't add "ace_gestures_" prefix to BI gestures + if (_vanillaKey == "BI") then { + _signalName = _currentName; + }; + + private _code = compile format [QUOTE('%1' call FUNC(playSignal)), _signalName]; + + TRACE_4("Adding KeyBind",_currentName,_signalName,_code,_key); + + [ + "ACE3 Gestures", + _currentName, + localize format [LSTRING(%1), _currentName], + _code, + {false}, + [_key, [false, (_key != -1), false]], + false + ] call CBA_fnc_addKeybind; + + false +} count [ + ["Freeze", 80], // Numpad 2 + ["Cover", 81], // Numpad 3 + ["Forward", 75], // Numpad 4 + ["Regroup", 76], // Numpad 5 + ["Engage", 77], // Numpad 6 + ["Point", 71], // Numpad 7 + ["Hold", 72], // Numpad 8 + ["Warning", 73], // Numpad 9 + ["Go", -1, "BI"], + ["Advance", -1, "BI"], + ["Follow", -1, "BI"], + ["Up", -1, "BI"], + ["Stop", -1, "BI"], + ["CeaseFire", -1, "BI"] +]; diff --git a/addons/gestures/key.sqf b/addons/gestures/key.sqf deleted file mode 100644 index 98c21d4862..0000000000 --- a/addons/gestures/key.sqf +++ /dev/null @@ -1,43 +0,0 @@ -#include "\a3\editor_f\Data\Scripts\dikCodes.h" - -{ - _x params ["_currentName","_key"]; - - private _signalName = format [QGVAR(%1), _currentName]; - - //Don't add "ace_gestures_" prefix to BI gestures - if (_key == -1) then { - _signalName = _currentName; - }; - - private _code = compile format [QUOTE('%1' call FUNC(playSignal)), _signalName]; - - TRACE_4("Adding KeyBind",_currentName,_signalName,_code,_key); - - [ - "ACE3 Gestures", - _currentName, - localize format [LSTRING(%1), _currentName], - _code, - {false}, - [_key, [false, (_key != -1), false]], - false - ] call CBA_fnc_addKeybind; - - false -} count [ - ["Freeze", DIK_NUMPAD2], - ["Cover", DIK_NUMPAD3], - ["Forward", DIK_NUMPAD4], - ["Regroup", DIK_NUMPAD5], - ["Engage", DIK_NUMPAD6], - ["Point", DIK_NUMPAD7], - ["Hold", DIK_NUMPAD8], - ["Warning", DIK_NUMPAD9], - ["Go", -1], - ["Advance", -1], - ["Follow", -1], - ["Up", -1], - ["Stop", -1], - ["CeaseFire", -1] -]; From 2d22b0615094623b33de88b18230b3158ec367ac Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 29 Mar 2016 16:08:33 +0200 Subject: [PATCH 088/215] Add README.md to gestures and update author URL --- addons/gestures/README.md | 11 +++++++++++ addons/gestures/config.cpp | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 addons/gestures/README.md diff --git a/addons/gestures/README.md b/addons/gestures/README.md new file mode 100644 index 0000000000..e224ff6d69 --- /dev/null +++ b/addons/gestures/README.md @@ -0,0 +1,11 @@ +ace_gestures +======== + +Gestures system in interaction menu and keybinds. + + +## Maintainers + +The people responsible for merging changes to this component or answering potential questions. + +- [jokoho48](https://github.com/jokoho48) diff --git a/addons/gestures/config.cpp b/addons/gestures/config.cpp index 39cb8f0951..ce60d26545 100644 --- a/addons/gestures/config.cpp +++ b/addons/gestures/config.cpp @@ -7,7 +7,7 @@ class CfgPatches { requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"ace_interact_menu"}; author[] = {"joko // Jonas", "Emperias", "Zigomarvin"}; - authorUrl = "https://github.com/commy2/"; + authorUrl = "https://github.com/jokoho48"; VERSION_CONFIG; }; }; From ec2be36e81bd763c6a51e2940793fbb792f2cca7 Mon Sep 17 00:00:00 2001 From: jonpas Date: Tue, 29 Mar 2016 16:25:55 +0200 Subject: [PATCH 089/215] Use boolean --- addons/gestures/XEH_postInit.sqf | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/addons/gestures/XEH_postInit.sqf b/addons/gestures/XEH_postInit.sqf index ea63e2a388..b764aeb176 100644 --- a/addons/gestures/XEH_postInit.sqf +++ b/addons/gestures/XEH_postInit.sqf @@ -5,14 +5,14 @@ if (!hasInterface) exitWith {}; // reload mutex, you can't play signal while reloading GVAR(ReloadMutex) = true; +// Add keybinds { - _x params ["_currentName", "_key", ["_vanillaKey", ""] ]; - - private _signalName = format [QGVAR(%1), _currentName]; + _x params ["_currentName", "_key", ["_vanillaKey", false] ]; // Don't add "ace_gestures_" prefix to BI gestures - if (_vanillaKey == "BI") then { - _signalName = _currentName; + private _signalName = _currentName; + if (!_vanillaKey) then { + _signalName = format [QGVAR(%1), _currentName]; }; private _code = compile format [QUOTE('%1' call FUNC(playSignal)), _signalName]; @@ -39,10 +39,10 @@ GVAR(ReloadMutex) = true; ["Point", 71], // Numpad 7 ["Hold", 72], // Numpad 8 ["Warning", 73], // Numpad 9 - ["Go", -1, "BI"], - ["Advance", -1, "BI"], - ["Follow", -1, "BI"], - ["Up", -1, "BI"], - ["Stop", -1, "BI"], - ["CeaseFire", -1, "BI"] + ["Go", -1, true], + ["Advance", -1, true], + ["Follow", -1, true], + ["Up", -1, true], + ["Stop", -1, true], + ["CeaseFire", -1, true] ]; From a4c848a090bfa25b0007482344dbaca78076a2f1 Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 29 Mar 2016 17:00:54 +0200 Subject: [PATCH 090/215] formating --- addons/advanced_ballistics/XEH_postInit.sqf | 14 +++++++------- .../main/{CfgDependencies.hpp => CfgSettings.hpp} | 1 + addons/main/config.cpp | 2 +- 3 files changed, 9 insertions(+), 8 deletions(-) rename addons/main/{CfgDependencies.hpp => CfgSettings.hpp} (99%) diff --git a/addons/advanced_ballistics/XEH_postInit.sqf b/addons/advanced_ballistics/XEH_postInit.sqf index 246529299c..7f4fc9341f 100644 --- a/addons/advanced_ballistics/XEH_postInit.sqf +++ b/addons/advanced_ballistics/XEH_postInit.sqf @@ -40,13 +40,13 @@ if (!hasInterface) exitWith {}; ACE_LOGWARNING_2("Weapon Mod [%1] missing ace compat pbo [%2] (from @ace\optionals)",_modPBO,_compatPBO); }; } forEach [ - ["RH_acc","ace_compat_rh_acc"], - ["RH_de_cfg","ace_compat_rh_de"], - ["RH_m4_cfg","ace_compat_rh_m4"], - ["RH_PDW","ace_compat_rh_pdw"], - ["RKSL_PMII","ace_compat_rksl_pm_ii"], - ["iansky_opt","ace_compat_sma3_iansky"], - ["R3F_Armes","ace_compat_r3f"] + ["RH_acc","ace_compat_rh_acc"], + ["RH_de_cfg","ace_compat_rh_de"], + ["RH_m4_cfg","ace_compat_rh_m4"], + ["RH_PDW","ace_compat_rh_pdw"], + ["RKSL_PMII","ace_compat_rksl_pm_ii"], + ["iansky_opt","ace_compat_sma3_iansky"], + ["R3F_Armes","ace_compat_r3f"] ]; }] call EFUNC(common,addEventHandler); diff --git a/addons/main/CfgDependencies.hpp b/addons/main/CfgSettings.hpp similarity index 99% rename from addons/main/CfgDependencies.hpp rename to addons/main/CfgSettings.hpp index 3414bc80b6..661108c53a 100644 --- a/addons/main/CfgDependencies.hpp +++ b/addons/main/CfgSettings.hpp @@ -1,3 +1,4 @@ + class CfgSettings { class CBA { class Versioning { diff --git a/addons/main/config.cpp b/addons/main/config.cpp index 3181df1dea..7b15f0c8f0 100644 --- a/addons/main/config.cpp +++ b/addons/main/config.cpp @@ -586,6 +586,6 @@ class CfgMods { }; }; -#include "CfgDependencies.hpp" +#include "CfgSettings.hpp" #include "CfgModuleCategories.hpp" #include "CfgVehicleClasses.hpp" From ada519a59c2ad2fb371364be2064067fe507b802 Mon Sep 17 00:00:00 2001 From: bux578 Date: Tue, 29 Mar 2016 20:35:34 +0200 Subject: [PATCH 091/215] sort people --- AUTHORS.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AUTHORS.txt b/AUTHORS.txt index c79206137c..46a5e50457 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -75,6 +75,7 @@ Gianmarco Varriale (TeamNuke) GieNkoV GitHawk gpgpgpgp +Grey-Soldierman Grzegorz Hamburger SV Harakhti @@ -119,4 +120,3 @@ voiper VyMajoris(W-Cephei) Winter zGuba -Grey-Soldierman From 6f412c312aaa7097cb049318b908794455d8e0f8 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 30 Mar 2016 10:26:33 -0500 Subject: [PATCH 092/215] Delay calling addCuratorEditableObjects for a frame Fixes createVehicle not always being added on dedicated server. --- addons/zeus/functions/fnc_addObjectToCurator.sqf | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/addons/zeus/functions/fnc_addObjectToCurator.sqf b/addons/zeus/functions/fnc_addObjectToCurator.sqf index 897f51532d..085fff09d1 100644 --- a/addons/zeus/functions/fnc_addObjectToCurator.sqf +++ b/addons/zeus/functions/fnc_addObjectToCurator.sqf @@ -13,12 +13,13 @@ #include "script_component.hpp" -if (!isServer) exitWith {}; - params ["_object"]; if (!(_object getVariable [QGVAR(addObject), GVAR(autoAddObjects)])) exitWith {}; -{ - _x addCuratorEditableObjects [[_object], true]; -}forEach allCurators; +[{ + TRACE_1("Delayed addCuratorEditableObjects",_this); + { + _x addCuratorEditableObjects [[_this], true]; + } forEach allCurators; +}, _object] call EFUNC(common,execNextFrame); From 6038ab89c9095aacb21244a65d24c1a3431b1730 Mon Sep 17 00:00:00 2001 From: Joko Date: Wed, 30 Mar 2016 23:02:52 +0200 Subject: [PATCH 093/215] improve Code to String --- addons/common/functions/fnc_codeToString.sqf | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/addons/common/functions/fnc_codeToString.sqf b/addons/common/functions/fnc_codeToString.sqf index b2817cd2b8..b4fe37db35 100644 --- a/addons/common/functions/fnc_codeToString.sqf +++ b/addons/common/functions/fnc_codeToString.sqf @@ -12,12 +12,11 @@ */ #include "script_component.hpp" -params ["_function"]; +params ["_code"]; +if (_code isEqualType "") exitWith {_code}; -if (_function isEqualType "") exitWith {_function}; +_code = str(_code); +_code = _code select [1, count _code - 2]; -_function = toArray str _function; -_function deleteAt 0; -_function deleteAt (count _function - 1); +_code -toString _function // return From 28468bec820670da5e0318440dca4e0d12872889 Mon Sep 17 00:00:00 2001 From: commy2 Date: Thu, 31 Mar 2016 00:57:04 +0200 Subject: [PATCH 094/215] specify helicopter cargo spaces, fix #3591 --- addons/cargo/CfgVehicles.hpp | 63 ++++++++++++++++++++++++++++++++++-- 1 file changed, 60 insertions(+), 3 deletions(-) diff --git a/addons/cargo/CfgVehicles.hpp b/addons/cargo/CfgVehicles.hpp index e1750d8aad..83fb9c1c00 100644 --- a/addons/cargo/CfgVehicles.hpp +++ b/addons/cargo/CfgVehicles.hpp @@ -194,12 +194,70 @@ class CfgVehicles { GVAR(hasCargo) = 1; }; - class Heli_Transport_02_base_F; - class I_Heli_Transport_02_F: Heli_Transport_02_base_F { + class Helicopter_Base_H; + class Heli_Light_01_base_F: Helicopter_Base_H { + GVAR(space) = 0; + GVAR(hasCargo) = 0; + }; + + class Heli_Light_02_base_F: Helicopter_Base_H { + GVAR(space) = 4; + }; + + class Helicopter_Base_F; + class Heli_light_03_base_F: Helicopter_Base_F { + GVAR(space) = 4; + }; + + class Heli_Transport_01_base_F: Helicopter_Base_H { + GVAR(space) = 8; + }; + + class Heli_Transport_02_base_F: Helicopter_Base_H { + GVAR(space) = 20; + }; + + class Heli_Transport_03_base_F: Helicopter_Base_H { + GVAR(space) = 40; + }; + + class Heli_Transport_04_base_F: Helicopter_Base_H { + GVAR(space) = 0; + GVAR(hasCargo) = 0; + }; + + class O_Heli_Transport_04_box_F: Heli_Transport_04_base_F { GVAR(space) = 20; GVAR(hasCargo) = 1; }; + class O_Heli_Transport_04_repair_F: Heli_Transport_04_base_F { + GVAR(space) = 12; + GVAR(hasCargo) = 1; + }; + + class O_Heli_Transport_04_ammo_F: Heli_Transport_04_base_F { + GVAR(space) = 8; + GVAR(hasCargo) = 1; + }; + + class O_Heli_Transport_04_fuel_F: Heli_Transport_04_base_F {}; + + class O_Heli_Transport_04_medevac_F: Heli_Transport_04_base_F { + GVAR(space) = 8; + GVAR(hasCargo) = 1; + }; + + class Heli_Attack_01_base_F: Helicopter_Base_F { + GVAR(space) = 0; + GVAR(hasCargo) = 0; + }; + + class Heli_Attack_02_base_F: Helicopter_Base_F { + GVAR(space) = 0; + GVAR(hasCargo) = 0; + }; + // jets class Plane: Air { GVAR(space) = 0; @@ -207,7 +265,6 @@ class CfgVehicles { }; // autonomus - class Helicopter_Base_F; class UAV_01_base_F: Helicopter_Base_F { GVAR(space) = 0; GVAR(hasCargo) = 0; From 92af6ffe2eb070005200963ec2c3e6f79df23c79 Mon Sep 17 00:00:00 2001 From: commy2 Date: Thu, 31 Mar 2016 01:03:40 +0200 Subject: [PATCH 095/215] add cargo space to csat attack heli (can transport 8 troops) --- addons/cargo/CfgVehicles.hpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/addons/cargo/CfgVehicles.hpp b/addons/cargo/CfgVehicles.hpp index 83fb9c1c00..a098c7a2b3 100644 --- a/addons/cargo/CfgVehicles.hpp +++ b/addons/cargo/CfgVehicles.hpp @@ -254,8 +254,7 @@ class CfgVehicles { }; class Heli_Attack_02_base_F: Helicopter_Base_F { - GVAR(space) = 0; - GVAR(hasCargo) = 0; + GVAR(space) = 4; }; // jets From c998ab622ec0ae1dcb808adca19efde150d5e197 Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Thu, 31 Mar 2016 14:41:09 +0200 Subject: [PATCH 096/215] fnc_getMGRSdata update1 fnc_getMGRSdata update1 --- addons/common/functions/fnc_getMGRSdata.sqf | 27 +++++++++++++++------ 1 file changed, 19 insertions(+), 8 deletions(-) diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index ee6d1e11dc..c6ab86358c 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -22,27 +22,38 @@ private _long = getNumber (configFile >> "CfgWorlds" >> _map >> "longitude"); private _lat = getNumber (configFile >> "CfgWorlds" >> _map >> "latitude"); private _altitude = getNumber (configFile >> "CfgWorlds" >> _map >> "elevationOffset"); -if (_map in ["Chernarus", "Bootcamp_ACR", "Woodland_ACR", "utes"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["chernarus", "Chernarus_Summer", "chernarus_winter", "Bootcamp_ACR", "Woodland_ACR", "utes"]) then { _lat = 50; _altitude = 0; }; if (_map in ["Altis", "Stratis"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["Takistan", "Zargabad", "Mountains_ACR"]) then { _lat = 35; _altitude = 2000; }; +if (_map in ["takistan", "zargabad", "Mountains_ACR"]) then { _lat = 35; _altitude = 2000; }; if (_map in ["Shapur_BAF", "ProvingGrounds_PMC"]) then { _lat = 35; _altitude = 100; }; if (_map in ["fallujah"]) then { _lat = 33; _altitude = 0; }; -if (_map in ["fata", "Abbottabad"]) then { _lat = 30; _altitude = 1000; }; +if (_map in ["fata"]) then { _lat = 33; _altitude = 1347; }; +if (_map in ["Abbottabad"]) then { _lat = 34; _altitude = 0; }; if (_map in ["sfp_wamako"]) then { _lat = 14; _altitude = 0; }; if (_map in ["sfp_sturko"]) then { _lat = 56; _altitude = 0; }; if (_map in ["Bornholm"]) then { _lat = 55; _altitude = 0; }; -if (_map in ["Imrali"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["bozcaada", "imrali", "imralispring"]) then { _lat = 40; _altitude = 0; }; if (_map in ["Caribou"]) then { _lat = 68; _altitude = 0; }; if (_map in ["Namalsk"]) then { _lat = 65; _altitude = 0; }; if (_map in ["MCN_Aliabad"]) then { _lat = 36; _altitude = 0; }; if (_map in ["Clafghan"]) then { _lat = 34; _altitude = 640; }; if (_map in ["Sangin", "hellskitchen"]) then { _lat = 32; _altitude = 0; }; -if (_map in ["Sara"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["sara", "sara_dbe1", "saralite", "intro", "Desert_E", "porto"]) then { _lat = 40; _altitude = 0; }; if (_map in ["reshmaan"]) then { _lat = 35; _altitude = 2000; }; if (_map in ["Thirsk"]) then { _lat = 65; _altitude = 0; }; -if (_map in ["lingor"]) then { _lat = -4; _altitude = 0; }; -if (_map in ["Panthera3"]) then { _lat = 46; _altitude = 0; }; -if (_map in ["Kunduz"]) then { _lat = 37; _altitude = 400; }; +if (_map in ["lingor", "lingor3"]) then { _lat = -4; _altitude = 0; }; +if (_map in ["panthera3"]) then { _lat = 46; _altitude = 0; }; +if (_map in ["kunduz"]) then { _lat = 37; _altitude = 0; }; +if (_map in ["angel"]) then { _lat = 38; _altitude = 0; }; +if (_map in ["porquerolles"]) then { _lat = 43; _altitude = 0; }; +if (_map in ["napf"]) then { _lat = 47; _altitude = 0; }; +if (_map in ["mef_alaska"]) then { _lat = 60; _altitude = 5; }; +if (_map in ["australia"]) then { _lat = -25; _altitude = 0; }; +if (_map in ["pja301"]) then { _lat = 42; _altitude = 0; }; +if (_map in ["pja305"]) then { _lat = 0; _altitude = 0; }; +if (_map in ["pja306"]) then { _lat = 35; _altitude = 300; }; +if (_map in ["pja307"]) then { _lat = 17; _altitude = 0; }; +if (_map in ["pja308", "pja310"]) then { _lat = 36; _altitude = 0; }; private _UTM = [_long,_lat] call BIS_fnc_posDegToUTM; private _easting = _UTM select 0; From d4a7d864aa3dfc2020f0705ab83306d6c2753f4b Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Thu, 31 Mar 2016 18:54:38 +0200 Subject: [PATCH 097/215] fnc_getMGRSdata update1 --- addons/common/functions/fnc_getMGRSdata.sqf | 27 +++++++++++---------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index c6ab86358c..b19f17a0e7 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -22,25 +22,26 @@ private _long = getNumber (configFile >> "CfgWorlds" >> _map >> "longitude"); private _lat = getNumber (configFile >> "CfgWorlds" >> _map >> "latitude"); private _altitude = getNumber (configFile >> "CfgWorlds" >> _map >> "elevationOffset"); -if (_map in ["chernarus", "Chernarus_Summer", "chernarus_winter", "Bootcamp_ACR", "Woodland_ACR", "utes"]) then { _lat = 50; _altitude = 0; }; -if (_map in ["Altis", "Stratis"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["takistan", "zargabad", "Mountains_ACR"]) then { _lat = 35; _altitude = 2000; }; -if (_map in ["Shapur_BAF", "ProvingGrounds_PMC"]) then { _lat = 35; _altitude = 100; }; +_map = toLower _map; +if (_map in ["chernarus", "chernarus_summer", "chernarus_winter", "bootcamp_acr", "woodland_acr", "utes"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["altis", "stratis"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["takistan", "zargabad", "mountains_acr"]) then { _lat = 35; _altitude = 2000; }; +if (_map in ["shapur_baf", "provingGrounds_pmc"]) then { _lat = 35; _altitude = 100; }; if (_map in ["fallujah"]) then { _lat = 33; _altitude = 0; }; if (_map in ["fata"]) then { _lat = 33; _altitude = 1347; }; -if (_map in ["Abbottabad"]) then { _lat = 34; _altitude = 0; }; +if (_map in ["abbottabad"]) then { _lat = 34; _altitude = 0; }; if (_map in ["sfp_wamako"]) then { _lat = 14; _altitude = 0; }; if (_map in ["sfp_sturko"]) then { _lat = 56; _altitude = 0; }; -if (_map in ["Bornholm"]) then { _lat = 55; _altitude = 0; }; +if (_map in ["bornholm"]) then { _lat = 55; _altitude = 0; }; if (_map in ["bozcaada", "imrali", "imralispring"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["Caribou"]) then { _lat = 68; _altitude = 0; }; -if (_map in ["Namalsk"]) then { _lat = 65; _altitude = 0; }; -if (_map in ["MCN_Aliabad"]) then { _lat = 36; _altitude = 0; }; -if (_map in ["Clafghan"]) then { _lat = 34; _altitude = 640; }; -if (_map in ["Sangin", "hellskitchen"]) then { _lat = 32; _altitude = 0; }; -if (_map in ["sara", "sara_dbe1", "saralite", "intro", "Desert_E", "porto"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["caribou"]) then { _lat = 68; _altitude = 0; }; +if (_map in ["namalsk"]) then { _lat = 65; _altitude = 0; }; +if (_map in ["mcn_aliabad"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["clafghan"]) then { _lat = 34; _altitude = 640; }; +if (_map in ["sangin", "hellskitchen"]) then { _lat = 32; _altitude = 0; }; +if (_map in ["sara", "sara_dbe1", "saralite", "intro", "desert_e", "porto"]) then { _lat = 40; _altitude = 0; }; if (_map in ["reshmaan"]) then { _lat = 35; _altitude = 2000; }; -if (_map in ["Thirsk"]) then { _lat = 65; _altitude = 0; }; +if (_map in ["thirsk"]) then { _lat = 65; _altitude = 0; }; if (_map in ["lingor", "lingor3"]) then { _lat = -4; _altitude = 0; }; if (_map in ["panthera3"]) then { _lat = 46; _altitude = 0; }; if (_map in ["kunduz"]) then { _lat = 37; _altitude = 0; }; From fbaae2beb39805197cfc26f8a879f41f54bcead0 Mon Sep 17 00:00:00 2001 From: jonpas Date: Fri, 1 Apr 2016 21:25:00 +0200 Subject: [PATCH 098/215] Fix stringtable casing --- addons/tagging/stringtable.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/tagging/stringtable.xml b/addons/tagging/stringtable.xml index c19e00b46c..1849206963 100644 --- a/addons/tagging/stringtable.xml +++ b/addons/tagging/stringtable.xml @@ -25,7 +25,7 @@ Tag vert Marca verde - + Tag blue Blau markieren Marcar en azul From 723d27fc99a1edf6bf52dcfc82236f60a1a25cea Mon Sep 17 00:00:00 2001 From: jonpas Date: Fri, 1 Apr 2016 21:29:03 +0200 Subject: [PATCH 099/215] Rename tagging action classes --- addons/tagging/CfgVehicles.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/tagging/CfgVehicles.hpp b/addons/tagging/CfgVehicles.hpp index af4daf6799..4425b646ad 100644 --- a/addons/tagging/CfgVehicles.hpp +++ b/addons/tagging/CfgVehicles.hpp @@ -3,7 +3,7 @@ class CfgVehicles { class CAManBase: Man { class ACE_SelfActions { class ACE_Equipment { - class ACE_tagWallBlack { + class ACE_TagBlack { displayName = CSTRING(TagBlack); condition = QUOTE(('ACE_SpraypaintBlack' in items ACE_player) && {[] call FUNC(checkTaggable)}); statement = QUOTE([ARR_2(ACE_player,'black' call FUNC(getTexture))] call FUNC(tag)); @@ -11,19 +11,19 @@ class CfgVehicles { priority = 3; icon = QUOTE(PATHTOF(UI\icons\iconTaggingBlack.paa)); }; - class ACE_tagWallRed: ACE_tagWallBlack { + class ACE_TagRed: ACE_TagBlack { displayName = CSTRING(TagRed); condition = QUOTE(('ACE_SpraypaintRed' in items ACE_player) && {[] call FUNC(checkTaggable)}); statement = QUOTE([ARR_2(ACE_player,'red' call FUNC(getTexture))] call FUNC(tag)); icon = QUOTE(PATHTOF(UI\icons\iconTaggingRed.paa)); }; - class ACE_tagWallGreen: ACE_tagWallBlack { + class ACE_TagGreen: ACE_TagBlack { displayName = CSTRING(TagGreen); condition = QUOTE(('ACE_SpraypaintGreen' in items ACE_player) && {[] call FUNC(checkTaggable)}); statement = QUOTE([ARR_2(ACE_player,'green' call FUNC(getTexture))] call FUNC(tag)); icon = QUOTE(PATHTOF(UI\icons\iconTaggingGreen.paa)); }; - class ACE_tagWallBlue: ACE_tagWallBlack { + class ACE_TagBlue: ACE_TagBlack { displayName = CSTRING(TagBlue); condition = QUOTE(('ACE_SpraypaintBlue' in items ACE_player) && {[] call FUNC(checkTaggable)}); statement = QUOTE([ARR_2(ACE_player,'blue' call FUNC(getTexture))] call FUNC(tag)); From 84c5a0d26620dd0078e6f92de7c21b5ca5d24ddf Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 1 Apr 2016 21:51:22 -0500 Subject: [PATCH 100/215] FCS - Minor firedEH optimization --- addons/fcs/functions/fnc_firedEH.sqf | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/fcs/functions/fnc_firedEH.sqf b/addons/fcs/functions/fnc_firedEH.sqf index a9f4975780..4c9b7d8b85 100644 --- a/addons/fcs/functions/fnc_firedEH.sqf +++ b/addons/fcs/functions/fnc_firedEH.sqf @@ -16,10 +16,11 @@ TRACE_10("firedEH:",_unit, _weapon, _muzzle, _mode, _ammo, _magazine, _projectile, _vehicle, _gunner, _turret); private _FCSMagazines = _vehicle getVariable [format ["%1_%2", QGVAR(Magazines), _turret], []]; -private _FCSElevation = _vehicle getVariable format ["%1_%2", QGVAR(Elevation), _turret]; if !(_magazine in _FCSMagazines) exitWith {}; +private _FCSElevation = _vehicle getVariable format ["%1_%2", QGVAR(Elevation), _turret]; + // GET ELEVATION OFFSET OF CURRENT MAGAZINE private _offset = 0; From 4576ea019401ca7aca6a7ae5d3c038849c485068 Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Sat, 2 Apr 2016 09:50:50 +0200 Subject: [PATCH 101/215] abbottabad altitude fix altitude 0 for altitude 1256 --- addons/common/functions/fnc_getMGRSdata.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index b19f17a0e7..8da838848a 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -29,7 +29,7 @@ if (_map in ["takistan", "zargabad", "mountains_acr"]) then { _lat = 35; _altitu if (_map in ["shapur_baf", "provingGrounds_pmc"]) then { _lat = 35; _altitude = 100; }; if (_map in ["fallujah"]) then { _lat = 33; _altitude = 0; }; if (_map in ["fata"]) then { _lat = 33; _altitude = 1347; }; -if (_map in ["abbottabad"]) then { _lat = 34; _altitude = 0; }; +if (_map in ["abbottabad"]) then { _lat = 34; _altitude = 1256; }; if (_map in ["sfp_wamako"]) then { _lat = 14; _altitude = 0; }; if (_map in ["sfp_sturko"]) then { _lat = 56; _altitude = 0; }; if (_map in ["bornholm"]) then { _lat = 55; _altitude = 0; }; From fed46628849cce47cf85a7ac426a4630bc53b1db Mon Sep 17 00:00:00 2001 From: nomisum Date: Sat, 2 Apr 2016 15:36:21 +0200 Subject: [PATCH 102/215] changed suggested lines to ace standards --- addons/fastroping/CfgSounds.hpp | 8 ++++---- addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/addons/fastroping/CfgSounds.hpp b/addons/fastroping/CfgSounds.hpp index 1cdf993adc..97479ecafb 100644 --- a/addons/fastroping/CfgSounds.hpp +++ b/addons/fastroping/CfgSounds.hpp @@ -1,12 +1,12 @@ class CfgSounds { - class ACE_Fastroping_Rope { + class GVAR(Rope) { name = "ACE_Fastroping_Rope"; - sound[] = {QUOTE(PATHTOF(data\sounds\fastroping_rope.ogg)), db0, 1.0}; + sound[] = {QUOTE(PATHTOF(data\sounds\fastroping_rope.ogg)), 10, 1.0}; titles[] = {}; }; - class ACE_Fastroping_Thud { + class GVAR(Thud) { name = "ACE_Fastroping_Thud"; - sound[] = {QUOTE(PATHTOF(data\sounds\fastroping_thud.ogg)), db0, 1.0}; + sound[] = {QUOTE(PATHTOF(data\sounds\fastroping_thud.ogg)), 10, 1.0}; titles[] = {}; }; }; \ No newline at end of file diff --git a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf index 1b41404299..8074a5d494 100644 --- a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf @@ -39,7 +39,7 @@ if (animationState _unit != "ACE_FastRoping") exitWith { [_idPFH] call CBA_fnc_removePerFrameHandler; }; - playSound "ACE_Fastroping_Rope"; + playSound QGVAR(Rope); }, 1, [_unit]] call CBA_fnc_addPerFrameHandler; //End of fast rope @@ -47,7 +47,7 @@ if (isNull attachedTo _unit) exitWith { [_unit, "", 2] call EFUNC(common,doAnimation); _unit setVectorUp [0, 0, 1]; - playSound "ACE_Fastroping_Thud"; + playSound QGVAR(Thud); [_pfhHandle] call CBA_fnc_removePerFrameHandler; }; From 5c87161118957904225464618e35c74cec134a37 Mon Sep 17 00:00:00 2001 From: nomisum Date: Sat, 2 Apr 2016 15:53:39 +0200 Subject: [PATCH 103/215] fixed logic problem --- .../functions/fnc_fastRopeLocalPFH.sqf | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf index 8074a5d494..8334e07929 100644 --- a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf @@ -29,18 +29,19 @@ if (animationState _unit != "ACE_FastRoping") exitWith { _unit disableCollisionWith _dummy; _unit attachTo [_dummy, [0, 0, -1.45]]; [_unit, "ACE_FastRoping", 2] call EFUNC(common,doAnimation); + + [{ + params ["_args", "_idPFH"]; + _args params ["_unit"]; + + if (isNull (attachedTo _unit)) exitWith { + [_idPFH] call CBA_fnc_removePerFrameHandler; + }; + + playSound QGVAR(Rope); + }, 1, [_unit]] call CBA_fnc_addPerFrameHandler; }; -[{ - params ["_args", "_idPFH"]; - _args params ["_unit"]; - - if (isNull (attachedTo _unit)) exitWith { - [_idPFH] call CBA_fnc_removePerFrameHandler; - }; - - playSound QGVAR(Rope); -}, 1, [_unit]] call CBA_fnc_addPerFrameHandler; //End of fast rope if (isNull attachedTo _unit) exitWith { From caf06f58c8ceb182a6921841be9ccfe6b67376ca Mon Sep 17 00:00:00 2001 From: jonpas Date: Sat, 2 Apr 2016 18:53:34 +0200 Subject: [PATCH 104/215] Add map altitude to GPS - fix #3650 --- addons/maptools/functions/fnc_openMapGpsUpdate.sqf | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/maptools/functions/fnc_openMapGpsUpdate.sqf b/addons/maptools/functions/fnc_openMapGpsUpdate.sqf index 092f0720c2..4a77f4a6c3 100644 --- a/addons/maptools/functions/fnc_openMapGpsUpdate.sqf +++ b/addons/maptools/functions/fnc_openMapGpsUpdate.sqf @@ -6,15 +6,15 @@ private ["_mapGpsDisplay", "_ctrl"]; if ((!("ItemGPS" in assigneditems ACE_player)) || {isNull (uiNamespace getVariable [QGVAR(ui_mapGpsDisplay), displayNull])}) exitWith { - ("RscACE_MapGps" call BIS_fnc_rscLayer) cutText ["","PLAIN"]; //close GPS RSC - [(_this select 1)] call CBA_fnc_removePerFrameHandler; //remove frameHandler + ("RscACE_MapGps" call BIS_fnc_rscLayer) cutText ["","PLAIN"]; // Close GPS RSC + [(_this select 1)] call CBA_fnc_removePerFrameHandler; // Remove frameHandler }; disableSerialization; _mapGpsDisplay = uiNamespace getVariable [QGVAR(ui_mapGpsDisplay), displayNull]; _ctrl = _mapGpsDisplay displayCtrl 913590; -_ctrl ctrlSetText str(round(getDir ACE_player)); //set Heading +_ctrl ctrlSetText str (round (getDir ACE_player)); // Set Heading _ctrl = _mapGpsDisplay displayCtrl 913591; -_ctrl ctrlSetText str(round((getPosASL ACE_player) select 2)); //set Altitude +_ctrl ctrlSetText str (round ((getPosASL ACE_player) select 2) + EGVAR(common,mapAltitude)); // Set Altitude _ctrl = _mapGpsDisplay displayCtrl 913592; -_ctrl ctrlSetText mapGridPosition ACE_player; //set grid cords +_ctrl ctrlSetText mapGridPosition ACE_player; // Set grid cords From a9fd7c4d6fd18cf508e92505b9341ad100f9cb75 Mon Sep 17 00:00:00 2001 From: jonpas Date: Sun, 3 Apr 2016 02:27:23 +0200 Subject: [PATCH 105/215] Always use junctions for dev environment setup --- tools/setup.py | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/tools/setup.py b/tools/setup.py index 62925a6066..edab37dbcb 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", "/D", "/J", "P:\\{}\\{}".format(MAINDIR,PROJECTDIR), projectpath]) + subprocess.call(["cmd", "/c", "mklink", "/D", "/J", os.path.join(armapath, MAINDIR, PROJECTDIR), projectpath]) except: raise print("Something went wrong during the link creation. Please finish the setup manually.") From 2a7e0b2a4852e87a79da02e9679f185255e57ed8 Mon Sep 17 00:00:00 2001 From: jonpas Date: Sun, 3 Apr 2016 13:23:20 +0200 Subject: [PATCH 106/215] Remove redundant directory symlink directive --- tools/setup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/setup.py b/tools/setup.py index edab37dbcb..af1b224cbb 100644 --- a/tools/setup.py +++ b/tools/setup.py @@ -79,8 +79,8 @@ def main(): if not os.path.exists(os.path.join(armapath, MAINDIR)): os.mkdir(os.path.join(armapath, MAINDIR)) - 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.") From d931eb4e15ff70e0d94f01dd381fe0ad206010e2 Mon Sep 17 00:00:00 2001 From: jonpas Date: Sun, 3 Apr 2016 14:17:16 +0200 Subject: [PATCH 107/215] Improve XEH adding in cargo --- addons/cargo/CfgEventHandlers.hpp | 56 ++-------------------- addons/cargo/functions/fnc_initVehicle.sqf | 3 +- 2 files changed, 5 insertions(+), 54 deletions(-) diff --git a/addons/cargo/CfgEventHandlers.hpp b/addons/cargo/CfgEventHandlers.hpp index 391c3a662d..ff4a88693e 100644 --- a/addons/cargo/CfgEventHandlers.hpp +++ b/addons/cargo/CfgEventHandlers.hpp @@ -27,27 +27,7 @@ class Extended_Killed_EventHandlers { //Need initPost or we have problems with setVariable with 'ACE_Cargo' class Extended_InitPost_EventHandlers { - class StaticWeapon { - class ADDON { - init = QUOTE(_this call DFUNC(initObject)); - }; - }; - class ReammoBox_F { - class ADDON { - init = QUOTE(_this call DFUNC(initObject)); - }; - }; - class Cargo_base_F { - class ADDON { - init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); - }; - }; - class CargoNet_01_box_F { - class ADDON { - init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); - }; - }; - class Land_CargoBox_V1_F { + class ThingX { class ADDON { init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); }; @@ -62,32 +42,12 @@ class Extended_InitPost_EventHandlers { init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); }; }; - class MetalCase_01_base_F { - class ADDON { - init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); - }; - }; - class RoadCone_F { - class ADDON { - init = QUOTE(_this call DFUNC(initObject); _this call DFUNC(initVehicle)); - }; - }; - class Car { + class LandVehicle { class ADDON { init = QUOTE(_this call DFUNC(initVehicle)); }; }; - class Tank { - class ADDON { - init = QUOTE(_this call DFUNC(initVehicle)); - }; - }; - class Helicopter { - class ADDON { - init = QUOTE(_this call DFUNC(initVehicle)); - }; - }; - class Plane { + class Air { class ADDON { init = QUOTE(_this call DFUNC(initVehicle)); }; @@ -97,16 +57,6 @@ class Extended_InitPost_EventHandlers { init = QUOTE(_this call DFUNC(initVehicle)); }; }; - class ACE_RepairItem_Base { - class ADDON { - init = QUOTE(_this call DFUNC(initObject)); - }; - }; - class ACE_bodyBagObject { - class ADDON { - init = QUOTE(_this call DFUNC(initObject)); - }; - }; class ACE_ConcertinaWireCoil { class ADDON { init = QUOTE(_this call DFUNC(initObject)); diff --git a/addons/cargo/functions/fnc_initVehicle.sqf b/addons/cargo/functions/fnc_initVehicle.sqf index c0b312146b..7e19b0acd0 100644 --- a/addons/cargo/functions/fnc_initVehicle.sqf +++ b/addons/cargo/functions/fnc_initVehicle.sqf @@ -20,6 +20,8 @@ TRACE_1("params", _vehicle); private _type = typeOf _vehicle; +if (getNumber (configFile >> "CfgVehicles" >> _type >> QGVAR(hasCargo)) != 1) exitWith {}; + if (isServer) then { { if (isClass _x) then { @@ -38,7 +40,6 @@ if (_type in GVAR(initializedVehicleClasses)) exitWith {}; GVAR(initializedVehicleClasses) pushBack _type; if (!hasInterface) exitWith {}; -if (getNumber (configFile >> "CfgVehicles" >> _type >> QGVAR(hasCargo)) != 1) exitWith {}; TRACE_1("Adding unload cargo action to class", _type); From f8b46e859caaa23a3d3373b15218f4232d153b1c Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sun, 3 Apr 2016 23:36:38 -0500 Subject: [PATCH 108/215] Wait until postInit to install playerChanged event --- addons/common/XEH_postInit.sqf | 6 ------ addons/common/XEH_preInit.sqf | 19 +------------------ 2 files changed, 1 insertion(+), 24 deletions(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 8eeed526f5..ae1014ddc8 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -332,12 +332,6 @@ GVAR(OldVisibleMap) = false; GVAR(OldInventoryDisplayIsOpen) = nil; //@todo check this GVAR(OldIsCamera) = false; -// clean up playerChanged eventhandler from preinit and put it in the same PFH as the other events to reduce overhead and guarantee advantageous execution order -if (!isNil QGVAR(PreInit_playerChanged_PFHID)) then { - [GVAR(PreInit_playerChanged_PFHID)] call CBA_fnc_removePerFrameHandler; - GVAR(PreInit_playerChanged_PFHID) = nil; -}; - // PFH to raise varios events [{ BEGIN_COUNTER(stateChecker); diff --git a/addons/common/XEH_preInit.sqf b/addons/common/XEH_preInit.sqf index 20b3692b9f..16e0a65159 100644 --- a/addons/common/XEH_preInit.sqf +++ b/addons/common/XEH_preInit.sqf @@ -47,29 +47,12 @@ GVAR(statusEffect_Names) = []; GVAR(statusEffect_isGlobal) = []; ////////////////////////////////////////////////// -// Set up PlayerChanged eventhandler for pre init +// Set up PlayerChanged eventhandler for pre init (EH is installed in postInit) ////////////////////////////////////////////////// ACE_player = objNull; uiNamespace setVariable ["ACE_player", objNull]; -// @todo check if this can be removed -if (hasInterface) then { - // PFH to update the ACE_player variable - GVAR(PreInit_playerChanged_PFHID) = [{ - if !(ACE_player isEqualTo (call FUNC(player))) then { - private _oldPlayer = ACE_player; - - ACE_player = call FUNC(player); - uiNamespace setVariable ["ACE_player", ACE_player]; - - // Raise ACE event - ["playerChanged", [ACE_player, _oldPlayer]] call FUNC(localEvent); - }; - }, 0, []] call CBA_fnc_addPerFrameHandler; -}; - - ////////////////////////////////////////////////// // Time handling ////////////////////////////////////////////////// From f409ce8248282e4ec8461330a63df3374be26018 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Thu, 7 Apr 2016 19:51:12 +0200 Subject: [PATCH 109/215] Add config style validation --- .travis.yml | 1 + addons/dagr/Dialog.hpp | 606 +++++++++++++------------- addons/dagr/RscTitles.hpp | 176 ++++---- addons/hearing/CfgSounds.hpp | 8 +- addons/huntir/CfgAmmo.hpp | 16 +- addons/realisticnames/CfgVehicles.hpp | 4 +- addons/tripod/CfgWeapons.hpp | 16 +- tools/config_style_checker.py | 157 +++++++ 8 files changed, 571 insertions(+), 413 deletions(-) create mode 100644 tools/config_style_checker.py diff --git a/.travis.yml b/.travis.yml index 1d2a49e2e6..3828300d7f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,6 +12,7 @@ before_script: fi script: - python3 tools/sqf_validator.py +- python3 tools/config_style_checker.py - if [ -n "${GH_TOKEN}" ] && [ "${TRAVIS_BRANCH}" == "master" ] && [ "${TRAVIS_PULL_REQUEST}" == "false" ]; then python3 tools/deploy.py; fi diff --git a/addons/dagr/Dialog.hpp b/addons/dagr/Dialog.hpp index 17c065f830..8511829e5e 100644 --- a/addons/dagr/Dialog.hpp +++ b/addons/dagr/Dialog.hpp @@ -76,349 +76,349 @@ class RscText; class DAGR_Button { - idc = -1; - type = CT_BUTTON; - style = ST_LEFT; - font = "RobotoCondensed"; - sizeEx = 0.02; - colorText[] = { 0, 1, 0, 1 }; - colorFocused[] = { 0, 0, 0, 0 }; // border color for focused state - colorDisabled[] = { 0, 0, 0, 0 }; // text color for disabled state - colorBackground[] = { 0, 0, 0, 0 }; - colorBackgroundDisabled[] = { 0, 0, 0, 0 }; // background color for disabled state - colorBackgroundActive[] = { 0, 0, 0, 0 }; // background color for active state - offsetX = 0; - offsetY = 0; - offsetPressedX = 0; - offsetPressedY = 0; - colorShadow[] = { 0, 0, 0, 0 }; - colorBorder[] = { 0, 0, 0, 0 }; - borderSize = 0; - soundEnter[] = { "", 0, 1 }; // no sound - soundPush[] = { "", 0, 1 }; - soundClick[] = { "", 0, 1 }; // no sound - soundEscape[] = { "", 0, 1 }; // no sound - x = 0.5; - y = 0.5; - w = 0.07; - h = 0.05; - text = ""; - action = ""; + idc = -1; + type = CT_BUTTON; + style = ST_LEFT; + font = "RobotoCondensed"; + sizeEx = 0.02; + colorText[] = { 0, 1, 0, 1 }; + colorFocused[] = { 0, 0, 0, 0 }; // border color for focused state + colorDisabled[] = { 0, 0, 0, 0 }; // text color for disabled state + colorBackground[] = { 0, 0, 0, 0 }; + colorBackgroundDisabled[] = { 0, 0, 0, 0 }; // background color for disabled state + colorBackgroundActive[] = { 0, 0, 0, 0 }; // background color for active state + offsetX = 0; + offsetY = 0; + offsetPressedX = 0; + offsetPressedY = 0; + colorShadow[] = { 0, 0, 0, 0 }; + colorBorder[] = { 0, 0, 0, 0 }; + borderSize = 0; + soundEnter[] = { "", 0, 1 }; // no sound + soundPush[] = { "", 0, 1 }; + soundClick[] = { "", 0, 1 }; // no sound + soundEscape[] = { "", 0, 1 }; // no sound + x = 0.5; + y = 0.5; + w = 0.07; + h = 0.05; + text = ""; + action = ""; }; class DAGR_Menu_Pic { - type = 0; - idc = -1; - style = 48; - x = 0; - y = 0; - w = 0.7; - h = 1.4; - text = ""; - colorBackground[] = {}; - colorText[] = {}; - font = "RobotoCondensed"; - sizeEx = 0.04; - waitForLoad = 0; + type = 0; + idc = -1; + style = 48; + x = 0; + y = 0; + w = 0.7; + h = 1.4; + text = ""; + colorBackground[] = {}; + colorText[] = {}; + font = "RobotoCondensed"; + sizeEx = 0.04; + waitForLoad = 0; }; class DAGR_Menu_Text { - type = 0; - idc = -1; - style = 0x00; - x = 0.5; - y = 0.5; - w = 0.15; - h = 0.15; - colorBackground[] = { 0, 0, 0, 0 }; - colorText[] = { 0.239, 0.216, 0.153, 1 }; - font = "RobotoCondensed"; - sizeEx = 0.03; - waitForLoad = 0; - text = ""; + type = 0; + idc = -1; + style = 0x00; + x = 0.5; + y = 0.5; + w = 0.15; + h = 0.15; + colorBackground[] = { 0, 0, 0, 0 }; + colorText[] = { 0.239, 0.216, 0.153, 1 }; + font = "RobotoCondensed"; + sizeEx = 0.03; + waitForLoad = 0; + text = ""; }; class DAGR_Menu { - idd = 266860; - movingEnable = false; - duration = 100000; - fadein = 0; - fadeout = 0; - name = "Dagr_Menu"; - onLoad = "uiNamespace setVariable ['DAGR_Menu', _this select 0]"; + idd = 266860; + movingEnable = false; + duration = 100000; + fadein = 0; + fadeout = 0; + name = "Dagr_Menu"; + onLoad = "uiNamespace setVariable ['DAGR_Menu', _this select 0]"; onUnload = QUOTE(GVAR(PWR) = true); // Simulate pressing the power button - controls[] = {"DAGR_MENU_UI", "DAGR_PWR_Button", "DAGR_UP_Button", "DAGR_DOWN_Button", "DAGR_LEFT_Button", "DAGR_RIGHT_Button", "DAGR_NEXT_Button", - "DAGR_SEL_Button", "DAGR_MENU_Button", "DAGR_F1_Button", "DAGR_F2_Button", "DAGR_F3_Button", "DAGR_F1_Text", "DAGR_F2_Text", "DAGR_F3_Text", "DAGR_MENU_OPTION0", - "DAGR_MENU_OPTION1", "DAGR_MENU_OPTION2", "DAGR_MENU_OPTION3", "DAGR_MENU_OPTION4", "DAGR_MENU_SELECTION0", "DAGR_MENU_SELECTION1", "DAGR_MENU_SELECTION2", - "DAGR_MENU_SELECTION3", "DAGR_MENU_SELECTION4", "DAGR_MENU_Main_Text", "DAGR_MENU_PSELECTION1", "DAGR_MENU_PSELECTION2", "DAGR_MENU_PSELECTION3", - "DAGR_MENU_PSELECTION4", "DAGR_MENU_PSELECTION5", "DAGR_MENU_PSELECTION6","DAGR_MENU_PSELECTION7", "DAGR_MENU_PSELECTION8"}; + controls[] = {"DAGR_MENU_UI", "DAGR_PWR_Button", "DAGR_UP_Button", "DAGR_DOWN_Button", "DAGR_LEFT_Button", "DAGR_RIGHT_Button", "DAGR_NEXT_Button", + "DAGR_SEL_Button", "DAGR_MENU_Button", "DAGR_F1_Button", "DAGR_F2_Button", "DAGR_F3_Button", "DAGR_F1_Text", "DAGR_F2_Text", "DAGR_F3_Text", "DAGR_MENU_OPTION0", + "DAGR_MENU_OPTION1", "DAGR_MENU_OPTION2", "DAGR_MENU_OPTION3", "DAGR_MENU_OPTION4", "DAGR_MENU_SELECTION0", "DAGR_MENU_SELECTION1", "DAGR_MENU_SELECTION2", + "DAGR_MENU_SELECTION3", "DAGR_MENU_SELECTION4", "DAGR_MENU_Main_Text", "DAGR_MENU_PSELECTION1", "DAGR_MENU_PSELECTION2", "DAGR_MENU_PSELECTION3", + "DAGR_MENU_PSELECTION4", "DAGR_MENU_PSELECTION5", "DAGR_MENU_PSELECTION6","DAGR_MENU_PSELECTION7", "DAGR_MENU_PSELECTION8"}; - class DAGR_MENU_UI : DAGR_Menu_Pic { - idc = 266861; - x = 0.175; - y = -0.173; - text = QUOTE(PATHTOF(UI\dagr_menu.paa)); - sizeEx = 0.1; - }; + class DAGR_MENU_UI : DAGR_Menu_Pic { + idc = 266861; + x = 0.175; + y = -0.173; + text = QUOTE(PATHTOF(UI\dagr_menu.paa)); + sizeEx = 0.1; + }; - class DAGR_PWR_Button : DAGR_Button { - idc = 266863; - action = QUOTE(GVAR(PWR) = true); - x = 0.40; - y = 0.65; - }; + class DAGR_PWR_Button : DAGR_Button { + idc = 266863; + action = QUOTE(GVAR(PWR) = true); + x = 0.40; + y = 0.65; + }; - class DAGR_UP_Button : DAGR_Button { - idc = 266864; - action = QUOTE(GVAR(UP) = true); - x = 0.50; - y = 0.675; - }; + class DAGR_UP_Button : DAGR_Button { + idc = 266864; + action = QUOTE(GVAR(UP) = true); + x = 0.50; + y = 0.675; + }; - class DAGR_DOWN_Button : DAGR_Button { - idc = 266865; - action = QUOTE(GVAR(DOWN) = true); - x = 0.50; - y = 0.81; - }; + class DAGR_DOWN_Button : DAGR_Button { + idc = 266865; + action = QUOTE(GVAR(DOWN) = true); + x = 0.50; + y = 0.81; + }; - class DAGR_LEFT_Button : DAGR_Button { - idc = 266866; - action = QUOTE(GVAR(LEFT) = true); - x = 0.40; - y = 0.735; - w = 0.05; - h = 0.07; - }; + class DAGR_LEFT_Button : DAGR_Button { + idc = 266866; + action = QUOTE(GVAR(LEFT) = true); + x = 0.40; + y = 0.735; + w = 0.05; + h = 0.07; + }; - class DAGR_RIGHT_Button : DAGR_Button { - idc = 266867; - action = QUOTE(GVAR(RIGHT) = true); - x = 0.62; - y = 0.735; - w = 0.05; - h = 0.07; - }; + class DAGR_RIGHT_Button : DAGR_Button { + idc = 266867; + action = QUOTE(GVAR(RIGHT) = true); + x = 0.62; + y = 0.735; + w = 0.05; + h = 0.07; + }; - class DAGR_NEXT_Button : DAGR_Button { - idc = 266868; - action = QUOTE(DAGR_NEXT = true); - x = 0.60; - y = 0.65; - }; + class DAGR_NEXT_Button : DAGR_Button { + idc = 266868; + action = QUOTE(DAGR_NEXT = true); + x = 0.60; + y = 0.65; + }; - class DAGR_SEL_Button : DAGR_Button { - idc = 266869; - action = QUOTE(GVAR(SEL) = true); - x = 0.54; - y = 0.735; - w = 0.06; - h = 0.06; - }; + class DAGR_SEL_Button : DAGR_Button { + idc = 266869; + action = QUOTE(GVAR(SEL) = true); + x = 0.54; + y = 0.735; + w = 0.06; + h = 0.06; + }; - class DAGR_MENU_Button : DAGR_Button { - idc = 266870; - action = QUOTE(GVAR(MENU_B) = true); - x = 0.46; - y = 0.735; - w = 0.06; - h = 0.06; - }; + class DAGR_MENU_Button : DAGR_Button { + idc = 266870; + action = QUOTE(GVAR(MENU_B) = true); + x = 0.46; + y = 0.735; + w = 0.06; + h = 0.06; + }; - class DAGR_F1_Button : DAGR_Button { - idc = 266871; - action = QUOTE(GVAR(F1) = true); - x = 0.40; - y = 0.575; - }; + class DAGR_F1_Button : DAGR_Button { + idc = 266871; + action = QUOTE(GVAR(F1) = true); + x = 0.40; + y = 0.575; + }; - class DAGR_F2_Button : DAGR_Button { - idc = 266872; - action = QUOTE(GVAR(F2) = true); - x = 0.495; - y = 0.575; - }; + class DAGR_F2_Button : DAGR_Button { + idc = 266872; + action = QUOTE(GVAR(F2) = true); + x = 0.495; + y = 0.575; + }; - class DAGR_F3_Button : DAGR_Button { - idc = 266873; - action = QUOTE(GVAR(F3) = true); - x = 0.59; - y = 0.575; - }; + class DAGR_F3_Button : DAGR_Button { + idc = 266873; + action = QUOTE(GVAR(F3) = true); + x = 0.59; + y = 0.575; + }; - class DAGR_F1_Text : DAGR_Menu_Text { - idc = 266874; - x = 0.388; - y = 0.38; - text = ""; - }; + class DAGR_F1_Text : DAGR_Menu_Text { + idc = 266874; + x = 0.388; + y = 0.38; + text = ""; + }; - class DAGR_F2_Text : DAGR_Menu_Text { - idc = 266875; - x = 0.506; - y = 0.38; - }; + class DAGR_F2_Text : DAGR_Menu_Text { + idc = 266875; + x = 0.506; + y = 0.38; + }; - class DAGR_F3_Text : DAGR_Menu_Text { - idc = 266876; - x = 0.612; - y = 0.38; - }; + class DAGR_F3_Text : DAGR_Menu_Text { + idc = 266876; + x = 0.612; + y = 0.38; + }; - class DAGR_MENU_OPTION0 : DAGR_Menu_Text { - idc = 2668777; - style = 0x02; - sizeEx = 0.035; - x = 0.43; - y = 0.19; - }; + class DAGR_MENU_OPTION0 : DAGR_Menu_Text { + idc = 2668777; + style = 0x02; + sizeEx = 0.035; + x = 0.43; + y = 0.19; + }; - class DAGR_MENU_OPTION1 : DAGR_Menu_Text { - idc = 2668778; - style = 0x02; - sizeEx = 0.035; - x = 0.43; - y = 0.225; - }; + class DAGR_MENU_OPTION1 : DAGR_Menu_Text { + idc = 2668778; + style = 0x02; + sizeEx = 0.035; + x = 0.43; + y = 0.225; + }; - class DAGR_MENU_OPTION2 : DAGR_Menu_Text { - idc = 2668779; - style = 0x02; - sizeEx = 0.035; - x = 0.43; - y = 0.26; - }; + class DAGR_MENU_OPTION2 : DAGR_Menu_Text { + idc = 2668779; + style = 0x02; + sizeEx = 0.035; + x = 0.43; + y = 0.26; + }; - class DAGR_MENU_OPTION3 : DAGR_Menu_Text { - idc = 2668780; - style = 0x02; - sizeEx = 0.035; - x = 0.43; - y = 0.295; - }; + class DAGR_MENU_OPTION3 : DAGR_Menu_Text { + idc = 2668780; + style = 0x02; + sizeEx = 0.035; + x = 0.43; + y = 0.295; + }; - class DAGR_MENU_OPTION4 : DAGR_Menu_Text { - idc = 2668781; - style = 0x02; - sizeEx = 0.035; - x = 0.43; - y = 0.33; - }; - class DAGR_MENU_SELECTION0 : DAGR_Menu_Pic { - idc = 2668783; - x = 0.42; - y = 0.246; - w = 0.17; - h = 0.035; - sizeEx = 0.05; - }; + class DAGR_MENU_OPTION4 : DAGR_Menu_Text { + idc = 2668781; + style = 0x02; + sizeEx = 0.035; + x = 0.43; + y = 0.33; + }; + class DAGR_MENU_SELECTION0 : DAGR_Menu_Pic { + idc = 2668783; + x = 0.42; + y = 0.246; + w = 0.17; + h = 0.035; + sizeEx = 0.05; + }; - class DAGR_MENU_SELECTION1 : DAGR_Menu_Pic { - idc = 2668784; - x = 0.42; - y = 0.281; - w = 0.17; - h = 0.035; - sizeEx = 0.05; - }; + class DAGR_MENU_SELECTION1 : DAGR_Menu_Pic { + idc = 2668784; + x = 0.42; + y = 0.281; + w = 0.17; + h = 0.035; + sizeEx = 0.05; + }; - class DAGR_MENU_SELECTION2 : DAGR_Menu_Pic { - idc = 2668785; - x = 0.42; - y = 0.316; - w = 0.17; - h = 0.035; - sizeEx = 0.05; - }; + class DAGR_MENU_SELECTION2 : DAGR_Menu_Pic { + idc = 2668785; + x = 0.42; + y = 0.316; + w = 0.17; + h = 0.035; + sizeEx = 0.05; + }; - class DAGR_MENU_SELECTION3 : DAGR_Menu_Pic { - idc = 2668786; - x = 0.42; - y = 0.351; - w = 0.17; - h = 0.035; - sizeEx = 0.05; - }; + class DAGR_MENU_SELECTION3 : DAGR_Menu_Pic { + idc = 2668786; + x = 0.42; + y = 0.351; + w = 0.17; + h = 0.035; + sizeEx = 0.05; + }; - class DAGR_MENU_SELECTION4 : DAGR_Menu_Pic { - idc = 2668787; - x = 0.42; - y = 0.386; - w = 0.17; - h = 0.035; - sizeEx = 0.05; - }; + class DAGR_MENU_SELECTION4 : DAGR_Menu_Pic { + idc = 2668787; + x = 0.42; + y = 0.386; + w = 0.17; + h = 0.035; + sizeEx = 0.05; + }; - class DAGR_MENU_Main_Text : DAGR_Menu_Text { - idc = 2668782; - style = ST_CENTER; - x = 0.38; - y = 0.32; - w = 0.25; - h = 0.035; - sizeEx = 0.04; - }; + class DAGR_MENU_Main_Text : DAGR_Menu_Text { + idc = 2668782; + style = ST_CENTER; + x = 0.38; + y = 0.32; + w = 0.25; + h = 0.035; + sizeEx = 0.04; + }; - class DAGR_MENU_PSELECTION1 : DAGR_Menu_Pic { - idc = 2668788; - x = 0.451; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION1 : DAGR_Menu_Pic { + idc = 2668788; + x = 0.451; + y = 0.352; + w = 0.01; + h = 0.003; + }; - class DAGR_MENU_PSELECTION2 : DAGR_Menu_Pic { - idc = 2668789; - x = 0.465; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION2 : DAGR_Menu_Pic { + idc = 2668789; + x = 0.465; + y = 0.352; + w = 0.01; + h = 0.003; + }; - class DAGR_MENU_PSELECTION3 : DAGR_Menu_Pic { - idc = 2668790; - x = 0.479; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION3 : DAGR_Menu_Pic { + idc = 2668790; + x = 0.479; + y = 0.352; + w = 0.01; + h = 0.003; + }; - class DAGR_MENU_PSELECTION4 : DAGR_Menu_Pic { - idc = 2668791; - x = 0.493; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION4 : DAGR_Menu_Pic { + idc = 2668791; + x = 0.493; + y = 0.352; + w = 0.01; + h = 0.003; + }; - class DAGR_MENU_PSELECTION5 : DAGR_Menu_Pic { - idc = 2668792; - x = 0.507; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION5 : DAGR_Menu_Pic { + idc = 2668792; + x = 0.507; + y = 0.352; + w = 0.01; + h = 0.003; + }; - class DAGR_MENU_PSELECTION6 : DAGR_Menu_Pic { - idc = 2668793; - x = 0.521; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION6 : DAGR_Menu_Pic { + idc = 2668793; + x = 0.521; + y = 0.352; + w = 0.01; + h = 0.003; + }; - class DAGR_MENU_PSELECTION7 : DAGR_Menu_Pic { - idc = 2668794; - x = 0.535; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION7 : DAGR_Menu_Pic { + idc = 2668794; + x = 0.535; + y = 0.352; + w = 0.01; + h = 0.003; + }; - class DAGR_MENU_PSELECTION8 : DAGR_Menu_Pic { - idc = 2668795; - x = 0.549; - y = 0.352; - w = 0.01; - h = 0.003; - }; + class DAGR_MENU_PSELECTION8 : DAGR_Menu_Pic { + idc = 2668795; + x = 0.549; + y = 0.352; + w = 0.01; + h = 0.003; + }; }; diff --git a/addons/dagr/RscTitles.hpp b/addons/dagr/RscTitles.hpp index 9ab34ee86f..ab70517c9a 100644 --- a/addons/dagr/RscTitles.hpp +++ b/addons/dagr/RscTitles.hpp @@ -1,95 +1,95 @@ class RscTitles { - class DAGR_Text { - type = 0; - idc = -1; - style = 0x01; - x = 0; - y = 0; - w = 0.15; - h = 0.050; - text = ""; - colorBackground[] = { 0, 0, 0, 0 }; - colorText[] = { 0.239, 0.216, 0.153, 1 }; - font = "RobotoCondensed"; - sizeEx = 0.04; - waitForLoad = 0; - }; - class DAGR_Pic { - type = 0; - idc = -1; - style = 48; - x = 0; - y = 0; - w = 0.50; - h = 0.50; - text = ""; - colorBackground[] = {}; - colorText[] = {}; - font = "RobotoCondensed"; - sizeEx = 0.02; - waitForLoad = 0; - }; + class DAGR_Text { + type = 0; + idc = -1; + style = 0x01; + x = 0; + y = 0; + w = 0.15; + h = 0.050; + text = ""; + colorBackground[] = { 0, 0, 0, 0 }; + colorText[] = { 0.239, 0.216, 0.153, 1 }; + font = "RobotoCondensed"; + sizeEx = 0.04; + waitForLoad = 0; + }; + class DAGR_Pic { + type = 0; + idc = -1; + style = 48; + x = 0; + y = 0; + w = 0.50; + h = 0.50; + text = ""; + colorBackground[] = {}; + colorText[] = {}; + font = "RobotoCondensed"; + sizeEx = 0.02; + waitForLoad = 0; + }; - class DAGR_Display { - idd = 266850; - movingEnable = false; - duration = 100000; - fadein = 0; - fadeout = 0; - name = "Dagr_Display"; - onLoad="uiNamespace setVariable ['DAGR_Display', _this select 0]"; - controls[] = {"DAGR_UI", "DAGR_Grid", "DAGR_Speed", "DAGR_Elevation", "DAGR_Heading", "DAGR_Time", "DAGR_WP", "DAGR_Bearing", "DAGR_DIST"}; + class DAGR_Display { + idd = 266850; + movingEnable = false; + duration = 100000; + fadein = 0; + fadeout = 0; + name = "Dagr_Display"; + onLoad="uiNamespace setVariable ['DAGR_Display', _this select 0]"; + controls[] = {"DAGR_UI", "DAGR_Grid", "DAGR_Speed", "DAGR_Elevation", "DAGR_Heading", "DAGR_Time", "DAGR_WP", "DAGR_Bearing", "DAGR_DIST"}; - class DAGR_UI : DAGR_Pic { - idc = 266856; - x = "(SafeZoneW + SafeZoneX) - 0.45"; - y = "(SafeZoneH + SafeZoneY) - 0.47"; - }; + class DAGR_UI : DAGR_Pic { + idc = 266856; + x = "(SafeZoneW + SafeZoneX) - 0.45"; + y = "(SafeZoneH + SafeZoneY) - 0.47"; + }; - class DAGR_Grid : DAGR_Text { - idc = 266851; - x = "(SafeZoneW + SafeZoneX) - 0.370";// 0.830 - y = "(SafeZoneH + SafeZoneY)- 0.250";// 0.845 - w = 0.25; - h = 0.06; - sizeEx = 0.07; - }; - class DAGR_Speed : DAGR_Text { - idc = 266852; - x = "(SafeZoneW + SafeZoneX) - 0.388"; //0.812 - y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 - }; - class DAGR_Elevation : DAGR_Text { - idc = 266853; - x = "(SafeZoneW + SafeZoneX) - 0.270"; //0.930 - y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 - }; - class DAGR_Heading : DAGR_Text { - idc = 266854; - x = "(SafeZoneW + SafeZoneX) - 0.413"; //0.787 - y = "(SafeZoneH + SafeZoneY) - 0.1294"; //0.9656 - }; - class DAGR_Time : DAGR_Text { - idc = 266855; - x = "(SafeZoneW + SafeZoneX) - 0.275"; //0.925 - y = "(SafeZoneH + SafeZoneY) - 0.129"; //0.965 - }; + class DAGR_Grid : DAGR_Text { + idc = 266851; + x = "(SafeZoneW + SafeZoneX) - 0.370";// 0.830 + y = "(SafeZoneH + SafeZoneY)- 0.250";// 0.845 + w = 0.25; + h = 0.06; + sizeEx = 0.07; + }; + class DAGR_Speed : DAGR_Text { + idc = 266852; + x = "(SafeZoneW + SafeZoneX) - 0.388"; //0.812 + y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 + }; + class DAGR_Elevation : DAGR_Text { + idc = 266853; + x = "(SafeZoneW + SafeZoneX) - 0.270"; //0.930 + y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 + }; + class DAGR_Heading : DAGR_Text { + idc = 266854; + x = "(SafeZoneW + SafeZoneX) - 0.413"; //0.787 + y = "(SafeZoneH + SafeZoneY) - 0.1294"; //0.9656 + }; + class DAGR_Time : DAGR_Text { + idc = 266855; + x = "(SafeZoneW + SafeZoneX) - 0.275"; //0.925 + y = "(SafeZoneH + SafeZoneY) - 0.129"; //0.965 + }; - class DAGR_WP : DAGR_Text { - idc = 266857; - x = "(SafeZoneW + SafeZoneX) - 0.235"; //0.965 - y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 - }; + class DAGR_WP : DAGR_Text { + idc = 266857; + x = "(SafeZoneW + SafeZoneX) - 0.235"; //0.965 + y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 + }; - class DAGR_Bearing : DAGR_Text { - idc = 266858; - x = "(SafeZoneW + SafeZoneX) - 0.413"; //0.787 - y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 - }; - class DAGR_DIST : DAGR_Text { - idc = 266859; - x = "(SafeZoneW + SafeZoneX) - 0.265"; //0.935 - y = "(SafeZoneH + SafeZoneY) - 0.129"; //0.965 - }; - }; + class DAGR_Bearing : DAGR_Text { + idc = 266858; + x = "(SafeZoneW + SafeZoneX) - 0.413"; //0.787 + y = "(SafeZoneH + SafeZoneY) - 0.181"; //0.914 + }; + class DAGR_DIST : DAGR_Text { + idc = 266859; + x = "(SafeZoneW + SafeZoneX) - 0.265"; //0.935 + y = "(SafeZoneH + SafeZoneY) - 0.129"; //0.965 + }; + }; }; diff --git a/addons/hearing/CfgSounds.hpp b/addons/hearing/CfgSounds.hpp index 7afdae88cb..0a1bc82ed1 100644 --- a/addons/hearing/CfgSounds.hpp +++ b/addons/hearing/CfgSounds.hpp @@ -27,8 +27,8 @@ class CfgSounds { sound[] = {QUOTE(PATHTOF(sounds\deafness_noring.ogg)),3,1}; titles[] = {}; }; - class ACE_Ring_Backblast { - sound[] = {QUOTE(PATHTOF(sounds\backblast_ring.ogg)),1,1}; - titles[] = {}; - }; + class ACE_Ring_Backblast { + sound[] = {QUOTE(PATHTOF(sounds\backblast_ring.ogg)),1,1}; + titles[] = {}; + }; }; diff --git a/addons/huntir/CfgAmmo.hpp b/addons/huntir/CfgAmmo.hpp index fac4d6fe60..86f73e9755 100644 --- a/addons/huntir/CfgAmmo.hpp +++ b/addons/huntir/CfgAmmo.hpp @@ -33,13 +33,13 @@ class CfgAmmo { soundFakeFall2[] = {"",3.16228,1,1000}; soundFakeFall3[] = {"",3.16228,1,1000}; soundFakeFall[] = {}; - hit = 0; - indirectHit = 0; - indirectHitRange = 0; - explosive = 1; - model = "\A3\weapons_f\empty"; - airFriction = 0; - timeToLive = 1; - explosionTime = 0.001; + hit = 0; + indirectHit = 0; + indirectHitRange = 0; + explosive = 1; + model = "\A3\weapons_f\empty"; + airFriction = 0; + timeToLive = 1; + explosionTime = 0.001; }; }; diff --git a/addons/realisticnames/CfgVehicles.hpp b/addons/realisticnames/CfgVehicles.hpp index 61864a8259..4ecbbe1b89 100644 --- a/addons/realisticnames/CfgVehicles.hpp +++ b/addons/realisticnames/CfgVehicles.hpp @@ -642,6 +642,6 @@ class CfgVehicles { class Item_Base_F; class Item_acc_flashlight: Item_Base_F { - displayName="UTG Defender 126"; - }; + displayName="UTG Defender 126"; + }; }; diff --git a/addons/tripod/CfgWeapons.hpp b/addons/tripod/CfgWeapons.hpp index 5ae0ee84d2..adc14912c2 100644 --- a/addons/tripod/CfgWeapons.hpp +++ b/addons/tripod/CfgWeapons.hpp @@ -2,16 +2,16 @@ class CfgWeapons { class ACE_ItemCore; class InventoryItem_Base_F; - class ACE_Tripod: ACE_ItemCore { - author[] = {"Rocko", "Scubaman3D"}; - scope = 2; - displayName = CSTRING(DisplayName); - descriptionShort = ""; - model = PATHTOF(data\w_sniper_tripod.p3d); - picture = PATHTOF(UI\w_sniper_tripod_ca.paa); + class ACE_Tripod: ACE_ItemCore { + author[] = {"Rocko", "Scubaman3D"}; + scope = 2; + displayName = CSTRING(DisplayName); + descriptionShort = ""; + model = PATHTOF(data\w_sniper_tripod.p3d); + picture = PATHTOF(UI\w_sniper_tripod_ca.paa); class ItemInfo: InventoryItem_Base_F { mass = 40; }; - }; + }; }; diff --git a/tools/config_style_checker.py b/tools/config_style_checker.py new file mode 100644 index 0000000000..65bd57a449 --- /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 = 0 + + 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()) From 121c45eb84939ae2ec67b32ec83d3f63bf3216b2 Mon Sep 17 00:00:00 2001 From: James McCartney Date: Mon, 11 Apr 2016 22:29:33 +0100 Subject: [PATCH 110/215] Raise a local event when a weapon is jammed --- addons/overheating/functions/fnc_jamWeapon.sqf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/addons/overheating/functions/fnc_jamWeapon.sqf b/addons/overheating/functions/fnc_jamWeapon.sqf index 38184808d2..ee6f86f388 100644 --- a/addons/overheating/functions/fnc_jamWeapon.sqf +++ b/addons/overheating/functions/fnc_jamWeapon.sqf @@ -43,6 +43,9 @@ if (_ammo > 0) then { // only display the hint once, after you try to shoot an already jammed weapon GVAR(knowAboutJam) = false; +["overheating_jammed", [_unit,_weapon]] call EFUNC(common,localEvent); + + if (_unit getVariable [QGVAR(JammingActionID), -1] == -1) then { private _condition = { From 153cd28f94579505dd10321e07f634d2cfca2ffb Mon Sep 17 00:00:00 2001 From: James McCartney Date: Mon, 11 Apr 2016 23:09:45 +0100 Subject: [PATCH 111/215] Change event name to weaponJammed --- addons/overheating/functions/fnc_jamWeapon.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/overheating/functions/fnc_jamWeapon.sqf b/addons/overheating/functions/fnc_jamWeapon.sqf index ee6f86f388..b6cacdbea3 100644 --- a/addons/overheating/functions/fnc_jamWeapon.sqf +++ b/addons/overheating/functions/fnc_jamWeapon.sqf @@ -43,7 +43,7 @@ if (_ammo > 0) then { // only display the hint once, after you try to shoot an already jammed weapon GVAR(knowAboutJam) = false; -["overheating_jammed", [_unit,_weapon]] call EFUNC(common,localEvent); +["weaponJammed", [_unit,_weapon]] call EFUNC(common,localEvent); if (_unit getVariable [QGVAR(JammingActionID), -1] == -1) then { From 2869a53e6dad4ca8ec53363c48da11b90fd0c47c Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 12 Apr 2016 00:19:24 -0500 Subject: [PATCH 112/215] Googles - Only play wipe anim for primary weapon Close #3638 Animation only makes sense for primary weapon, so skip for others. --- addons/goggles/functions/fnc_clearGlasses.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/goggles/functions/fnc_clearGlasses.sqf b/addons/goggles/functions/fnc_clearGlasses.sqf index d0b14e4f90..e7d5584938 100644 --- a/addons/goggles/functions/fnc_clearGlasses.sqf +++ b/addons/goggles/functions/fnc_clearGlasses.sqf @@ -26,7 +26,7 @@ _effects set [BROKEN, _broken]; SETGLASSES(_unit,_effects); -if (stance _unit != "PRONE") then { +if ((stance _unit != "PRONE") && {primaryWeapon _unit != ""} && {currentWeapon _unit == primaryWeapon _unit}) then { _unit playActionNow "gestureWipeFace"; }; From 3744b980f49128946e21aed055a5d2bbbec6f778 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 12 Apr 2016 02:14:06 -0500 Subject: [PATCH 113/215] Javelin - Verify player has LOS to cursorTarget Fix #3668 --- addons/javelin/functions/fnc_onOpticDraw.sqf | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/addons/javelin/functions/fnc_onOpticDraw.sqf b/addons/javelin/functions/fnc_onOpticDraw.sqf index f561806eaa..4bf80641e3 100644 --- a/addons/javelin/functions/fnc_onOpticDraw.sqf +++ b/addons/javelin/functions/fnc_onOpticDraw.sqf @@ -99,7 +99,10 @@ if (_range > 50 && {_range < 2500}) then { }; if (isNull _newTarget) then { - _newTarget = cursorTarget; + private _intersectionsToCursorTarget = lineIntersectsSurfaces [(AGLtoASL positionCameraToWorld [0,0,0]), aimPos cursorTarget, ace_player, cursorTarget, true, 1]; + if (_intersectionsToCursorTarget isEqualTo []) then { + _newTarget = cursorTarget; + }; }; // Create constants From 5d70db3d9b12ef5131f1aae87cc0b43fb805f592 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 12 Apr 2016 12:12:49 -0500 Subject: [PATCH 114/215] LoadPerson - Only try vehicles that have room Fix #2965 The FRIES is a "Helicopter" so we were trying to load into it, because it was closest. Also disable Cargo system on it so we don't load other things into it And remove all interactions on it as well. --- addons/common/XEH_postInit.sqf | 1 + addons/common/functions/fnc_loadPerson.sqf | 29 ++++++---------------- addons/fastroping/CfgVehicles.hpp | 4 +++ 3 files changed, 12 insertions(+), 22 deletions(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index ae1014ddc8..4c05b1cf7a 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -133,6 +133,7 @@ if (isServer) then { ["fixFloating", FUNC(fixFloating)] call FUNC(addEventhandler); ["fixPosition", FUNC(fixPosition)] call FUNC(addEventhandler); +["loadPersonEvent", FUNC(loadPersonLocal)] call FUNC(addEventhandler); ["unloadPersonEvent", FUNC(unloadPersonLocal)] call FUNC(addEventhandler); ["lockVehicle", { diff --git a/addons/common/functions/fnc_loadPerson.sqf b/addons/common/functions/fnc_loadPerson.sqf index 3071ffbd47..6c728134d1 100644 --- a/addons/common/functions/fnc_loadPerson.sqf +++ b/addons/common/functions/fnc_loadPerson.sqf @@ -21,33 +21,18 @@ private _vehicle = objNull; if (!([_caller, _unit, ["isNotDragging", "isNotCarrying"]] call FUNC(canInteractWith)) || {_caller == _unit}) exitWith {_vehicle}; -private _loadcar = nearestObject [_unit, "Car"]; +private _nearVehicles = nearestObjects [_unit, ["Car", "Air", "Tank", "Ship_F"], 10]; -if (_unit distance _loadcar <= 10) then { - _vehicle = _loadcar; -} else { - private _loadair = nearestObject [_unit, "Air"]; - - if (_unit distance _loadair <= 10) then { - _vehicle = _loadair; - } else { - private _loadtank = nearestObject [_unit, "Tank"]; - - if (_unit distance _loadtank <= 10) then { - _vehicle = _loadtank; - } else { - private _loadboat = nearestObject [_unit, "Ship_F"]; - - if (_unit distance _loadboat <= 10) then { - _vehicle = _loadboat; - }; - }; +{ + TRACE_1("",_x); + if ((_x emptyPositions "cargo" > 0) || {_x emptyPositions "gunner" > 0}) exitWith { + _vehicle = _x; }; -}; +} forEach _nearVehicles; if (!isNull _vehicle) then { [_unit, true, GROUP_SWITCH_ID, side group _caller] call FUNC(switchToGroupSide); - [[_unit, _vehicle, _caller], QFUNC(loadPersonLocal), _unit, false] call FUNC(execRemoteFnc); + ["loadPersonEvent", _unit, [_unit, _vehicle, _caller]] call FUNC(objectEvent); }; _vehicle diff --git a/addons/fastroping/CfgVehicles.hpp b/addons/fastroping/CfgVehicles.hpp index a9f5ebfbad..dcd399508b 100644 --- a/addons/fastroping/CfgVehicles.hpp +++ b/addons/fastroping/CfgVehicles.hpp @@ -73,6 +73,10 @@ class CfgVehicles { class ACE_friesBase: Helicopter_Base_F { destrType = ""; class Turrets {}; + class ACE_Actions {}; + class ACE_SelfActions {}; + EGVAR(cargo,hasCargo) = 0; + EGVAR(cargo,space) = 0; }; class ACE_friesAnchorBar: ACE_friesBase { author = "jokoho48"; From d7b0bde1ca3e6c455d63538f773733a615bc9b0b Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 12 Apr 2016 12:28:48 -0500 Subject: [PATCH 115/215] Fix Wildcat attach point --- addons/fastroping/CfgVehicles.hpp | 2 +- addons/fastroping/script_component.hpp | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/addons/fastroping/CfgVehicles.hpp b/addons/fastroping/CfgVehicles.hpp index dcd399508b..609e386e68 100644 --- a/addons/fastroping/CfgVehicles.hpp +++ b/addons/fastroping/CfgVehicles.hpp @@ -209,7 +209,7 @@ class CfgVehicles { GVAR(enabled) = 2; GVAR(ropeOrigins)[] = {"ropeOriginRight", "ropeOriginLeft"}; GVAR(friesType) = "ACE_friesGantryReverse"; - GVAR(friesAttachmentPoint)[] = {1.04, 2.5, -0.34}; + GVAR(friesAttachmentPoint)[] = {-1.04, 2.5, -0.34}; EQUIP_FRIES_ATTRIBUTE; }; class Heli_light_03_unarmed_base_F: Heli_light_03_base_F { diff --git a/addons/fastroping/script_component.hpp b/addons/fastroping/script_component.hpp index ccfa2c3e56..3770bfe0d4 100644 --- a/addons/fastroping/script_component.hpp +++ b/addons/fastroping/script_component.hpp @@ -1,6 +1,11 @@ #define COMPONENT fastroping #include "\z\ace\addons\main\script_mod.hpp" +// #define DEBUG_MODE_FULL +// #define DISABLE_COMPILE_CACHE +// #define CBA_DEBUG_SYNCHRONOUS +// #define ENABLE_PERFORMANCE_COUNTERS + #ifdef DEBUG_ENABLED_FASTROPING #define DEBUG_MODE_FULL #endif From 4f6b11c2a6de9a313c194bfaf67e731aa9508001 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 12 Apr 2016 20:04:12 -0500 Subject: [PATCH 116/215] Clarify repair while engine is running #3348 - Show action, but exit and show warning when selected - Optional (default off) setting to auto shut off engine to keep compatibility with missions --- addons/common/XEH_postInit.sqf | 1 + addons/repair/ACE_Settings.hpp | 5 +++++ addons/repair/functions/fnc_canRepair.sqf | 3 ++- addons/repair/functions/fnc_repair.sqf | 9 ++++++++- addons/repair/stringtable.xml | 5 +++++ 5 files changed, 21 insertions(+), 2 deletions(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index ae1014ddc8..c10246212c 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -146,6 +146,7 @@ if (isServer) then { ["setDir", {(_this select 0) setDir (_this select 1)}] call FUNC(addEventhandler); ["setFuel", {(_this select 0) setFuel (_this select 1)}] call FUNC(addEventhandler); +["engineOn", {(_this select 0) engineOn (_this select 1)}] call FUNC(addEventhandler); ["setSpeaker", {(_this select 0) setSpeaker (_this select 1)}] call FUNC(addEventhandler); ["selectLeader", {(_this select 0) selectLeader (_this select 1)}] call FUNC(addEventHandler); ["setVelocity", {(_this select 0) setVelocity (_this select 1)}] call FUNC(addEventHandler); diff --git a/addons/repair/ACE_Settings.hpp b/addons/repair/ACE_Settings.hpp index c3c8daad16..9f6d20ae97 100644 --- a/addons/repair/ACE_Settings.hpp +++ b/addons/repair/ACE_Settings.hpp @@ -77,4 +77,9 @@ class ACE_Settings { values[] = {"None", "ToolKit"}; _values[] = {{}, {"ToolKit"}}; }; + class GVAR(autoShutOffEngineWhenStartingRepair) { + typeName = "BOOL"; + value = 1; + category = ECSTRING(OptionsMenu,CategoryLogistics); + }; }; diff --git a/addons/repair/functions/fnc_canRepair.sqf b/addons/repair/functions/fnc_canRepair.sqf index f7c3f60a8a..6027a34fd5 100644 --- a/addons/repair/functions/fnc_canRepair.sqf +++ b/addons/repair/functions/fnc_canRepair.sqf @@ -25,7 +25,8 @@ private ["_config", "_engineerRequired", "_items", "_return", "_condition", "_ve _config = (ConfigFile >> "ACE_Repair" >> "Actions" >> _className); if !(isClass _config) exitWith {false}; // or go for a default? -if(isEngineOn _target) exitWith {false}; + +// if(isEngineOn _target) exitWith {false}; // Ignore here so action shows, then exit and show warning when selected #3348 _engineerRequired = if (isNumber (_config >> "requiredEngineer")) then { getNumber (_config >> "requiredEngineer"); diff --git a/addons/repair/functions/fnc_repair.sqf b/addons/repair/functions/fnc_repair.sqf index 25e58151c5..f5b7d8cbfc 100644 --- a/addons/repair/functions/fnc_repair.sqf +++ b/addons/repair/functions/fnc_repair.sqf @@ -36,7 +36,14 @@ _engineerRequired = if (isNumber (_config >> "requiredEngineer")) then { 0; }; if !([_caller, _engineerRequired] call FUNC(isEngineer)) exitWith {false}; -if (isEngineOn _target) exitWith {false}; + +if ((isEngineOn _target) && {GVAR(autoShutOffEngineWhenStartingRepair)}) then { + ["engineOn", _target, [_target, false]] call EFUNC(common,objectEvent); +}; +if ((isEngineOn _target) && {!GVAR(autoShutOffEngineWhenStartingRepair)}) exitWith { + ["displayTextStructured", [LSTRING(shutOffEngineWarning), 1.5, _caller]] call EFUNC(common,localEvent); + false +}; //Items can be an array of required items or a string to a ACE_Setting array _items = if (isArray (_config >> "items")) then { diff --git a/addons/repair/stringtable.xml b/addons/repair/stringtable.xml index fb505f4f4e..ee79a1d427 100644 --- a/addons/repair/stringtable.xml +++ b/addons/repair/stringtable.xml @@ -1316,5 +1316,10 @@ Oggetti richiesti per riparare/rimuovere ruote Items exigés pour enlever/remplacer les roues + + Engine must be off to repair + Motor muss ausgeschaltet zu reparieren sein + El motor necesita desactivado para la reparación + From f16a65f3815f6da47eab963467fc6b39f1a00d64 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 12 Apr 2016 20:05:56 -0500 Subject: [PATCH 117/215] Fix default --- addons/repair/ACE_Settings.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/repair/ACE_Settings.hpp b/addons/repair/ACE_Settings.hpp index 9f6d20ae97..9ee40529e7 100644 --- a/addons/repair/ACE_Settings.hpp +++ b/addons/repair/ACE_Settings.hpp @@ -79,7 +79,7 @@ class ACE_Settings { }; class GVAR(autoShutOffEngineWhenStartingRepair) { typeName = "BOOL"; - value = 1; + value = 0; category = ECSTRING(OptionsMenu,CategoryLogistics); }; }; From 33600472045af602797df69c9beb9d5146470e20 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 13 Apr 2016 13:05:32 -0500 Subject: [PATCH 118/215] Better handle unloading on slopes Close #3667 --- addons/common/functions/fnc_findUnloadPosition.sqf | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/addons/common/functions/fnc_findUnloadPosition.sqf b/addons/common/functions/fnc_findUnloadPosition.sqf index f7155fd87b..c3b0dc3f34 100644 --- a/addons/common/functions/fnc_findUnloadPosition.sqf +++ b/addons/common/functions/fnc_findUnloadPosition.sqf @@ -92,6 +92,15 @@ while {_rangeToCheck < _maxDistance} do { private _point1ASL = (AGLtoASL _roundAGL) vectorAdd [_radiusOfItem * cos _angle, _radiusOfItem * sin _angle, 0.1]; private _point2ASL = (AGLtoASL _roundAGL) vectorAdd [-_radiusOfItem * cos _angle, -_radiusOfItem * sin _angle, (_radiusOfItem + 0.5)]; private _testIntersections = lineIntersectsSurfaces [_point1ASL, _point2ASL]; + if (((count _testIntersections) == 1) && {isNull ((_testIntersections select 0) select 2)}) then { + private _hitGroundASL = (_testIntersections select 0) select 0; + private _hitHeightOffset = ((AGLtoASL _roundAGL) select 2) - (_hitGroundASL select 2); + private _hit2dOffset = _roundAGL distance2D _hitGroundASL; + private _slope = _hitHeightOffset atan2 _hit2dOffset; + if (_slope < 25) then { //Ignore ground hit if slope is reasonable + _testIntersections = []; + }; + }; if (!(_testIntersections isEqualTo [])) exitWith { TRACE_2("collision low/high",_roundAGL,_testIntersections); _roundPointIsValid = false; From dec266a5462470ab077fc33aca264e160ff073d6 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 14 Apr 2016 13:52:20 +0200 Subject: [PATCH 119/215] Fix ship view distance using foot instead of vehicle setting, Cleanup view distance component --- addons/viewdistance/CfgVehicles.hpp | 4 +- addons/viewdistance/XEH_PREP.hpp | 1 - addons/viewdistance/XEH_clientInit.sqf | 2 +- .../functions/fnc_adaptViewDistance.sqf | 23 ++++++----- .../functions/fnc_changeViewDistance.sqf | 34 ++++++++-------- .../functions/fnc_returnObjectCoeff.sqf | 6 +-- .../functions/fnc_returnValue.sqf | 39 ++++++++----------- .../functions/fnc_setFovBasedOvdPFH.sqf | 31 ++++++--------- addons/viewdistance/script_component.hpp | 5 +++ 9 files changed, 64 insertions(+), 81 deletions(-) diff --git a/addons/viewdistance/CfgVehicles.hpp b/addons/viewdistance/CfgVehicles.hpp index 86d906bfce..4c6639370c 100644 --- a/addons/viewdistance/CfgVehicles.hpp +++ b/addons/viewdistance/CfgVehicles.hpp @@ -1,6 +1,6 @@ class CfgVehicles { class ACE_Module; - class GVAR(ModuleSettings) : ACE_Module { + class GVAR(ModuleSettings): ACE_Module { author = ECSTRING(common,ACETeam); category = "ACE"; function = QUOTE(DFUNC(initModule)); @@ -28,4 +28,4 @@ class CfgVehicles { sync[] = {}; }; }; -}; \ No newline at end of file +}; diff --git a/addons/viewdistance/XEH_PREP.hpp b/addons/viewdistance/XEH_PREP.hpp index fea5de5a4f..c040baf334 100644 --- a/addons/viewdistance/XEH_PREP.hpp +++ b/addons/viewdistance/XEH_PREP.hpp @@ -1,4 +1,3 @@ - PREP(adaptViewDistance); PREP(changeViewDistance); PREP(initModule); diff --git a/addons/viewdistance/XEH_clientInit.sqf b/addons/viewdistance/XEH_clientInit.sqf index 45b86d944d..dfcfd7e405 100644 --- a/addons/viewdistance/XEH_clientInit.sqf +++ b/addons/viewdistance/XEH_clientInit.sqf @@ -24,6 +24,6 @@ if (!hasInterface) exitWith {}; // Set the EH which waits for a vehicle change to automatically swap between On Foot/In Land Vehicle/In Air Vehicle // Also run when SettingsInitialized runs (not guaranteed) ["playerVehicleChanged",{ - [false] call FUNC(adaptViewDistance) + [false] call FUNC(adaptViewDistance); }] call EFUNC(common,addEventHandler); }] call EFUNC(common,addEventHandler); diff --git a/addons/viewdistance/functions/fnc_adaptViewDistance.sqf b/addons/viewdistance/functions/fnc_adaptViewDistance.sqf index f1ea7121b2..87b6232e99 100644 --- a/addons/viewdistance/functions/fnc_adaptViewDistance.sqf +++ b/addons/viewdistance/functions/fnc_adaptViewDistance.sqf @@ -2,7 +2,6 @@ * Author: Winter * Sets the player's current view distance according to whether s/he is on foot, in a land vehicle or in an air vehicle. * - * * Arguments: * 0: Show Prompt * @@ -17,23 +16,23 @@ #include "script_component.hpp" -private["_land_vehicle","_air_vehicle"]; - -params ["_show_prompt"]; +params ["_showPrompt"]; if (!GVAR(enabled) || isNull ACE_player) exitWith {}; -_land_vehicle = (vehicle ACE_player) isKindOf "LandVehicle"; -_air_vehicle = (vehicle ACE_player) isKindOf "Air"; +private _vehicle = vehicle ACE_player; -if (!_land_vehicle && !_air_vehicle) exitWith { - [GVAR(viewDistanceOnFoot),_show_prompt] call FUNC(changeViewDistance); +private _landVehicle = _vehicle isKindOf "LandVehicle" || _vehicle isKindOf "Ship_F"; +private _airVehicle = _vehicle isKindOf "Air"; + +if (!_landVehicle && !_airVehicle) exitWith { + [GVAR(viewDistanceOnFoot), _showPrompt] call FUNC(changeViewDistance); }; -if (_land_vehicle) exitWith { - [GVAR(viewDistanceLandVehicle),_show_prompt] call FUNC(changeViewDistance); +if (_landVehicle) exitWith { + [GVAR(viewDistanceLandVehicle), _showPrompt] call FUNC(changeViewDistance); }; -if (_air_vehicle) exitWith { - [GVAR(viewDistanceAirVehicle),_show_prompt] call FUNC(changeViewDistance); +if (_airVehicle) exitWith { + [GVAR(viewDistanceAirVehicle), _showPrompt] call FUNC(changeViewDistance); }; diff --git a/addons/viewdistance/functions/fnc_changeViewDistance.sqf b/addons/viewdistance/functions/fnc_changeViewDistance.sqf index 28bba29b67..c5f39ff2f8 100644 --- a/addons/viewdistance/functions/fnc_changeViewDistance.sqf +++ b/addons/viewdistance/functions/fnc_changeViewDistance.sqf @@ -16,20 +16,18 @@ */ #include "script_component.hpp" -private ["_text", "_new_view_distance", "_view_distance_limit", "_object_view_distance_coeff"]; +params ["_indexRequested", "_showPrompt"]; -params ["_index_requested", "_show_prompt"]; +private _newViewDistance = [_indexRequested] call FUNC(returnValue); // changes the setting index into an actual view distance value +private _objectViewDistanceCoeff = [GVAR(objectViewDistanceCoeff)] call FUNC(returnObjectCoeff); // changes the setting index into a coefficient. +private _viewDistanceLimit = GVAR(limitViewDistance); // Grab the limit -_new_view_distance = [_index_requested] call FUNC(returnValue); // changes the setting index into an actual view distance value -_object_view_distance_coeff = [GVAR(objectViewDistanceCoeff)] call FUNC(returnObjectCoeff); // changes the setting index into a coefficient. -_view_distance_limit = GVAR(limitViewDistance); // Grab the limit +TRACE_3("Limit",_newViewDistance,_viewDistanceLimit,_showPrompt); +setViewDistance (_newViewDistance min _viewDistanceLimit); -TRACE_2("Limit",_new_view_distance,_view_distance_limit); -setViewDistance (_new_view_distance min _view_distance_limit); - -if (typeName _object_view_distance_coeff == "SCALAR") then { - if (_object_view_distance_coeff > 0) then { - setObjectViewDistance (_object_view_distance_coeff * viewDistance); +if (_objectViewDistanceCoeff isEqualType 0) then { + if (_objectViewDistanceCoeff > 0) then { + setObjectViewDistance (_objectViewDistanceCoeff * viewDistance); } else { // Restore correct view distance when changing from FoV Based to Off // Restoring directly inside PFH's self-exit resulted in the need of selecting another option to take effect @@ -42,18 +40,18 @@ if (typeName _object_view_distance_coeff == "SCALAR") then { }; }; -if (_show_prompt) then { +if (_showPrompt) then { if (GVAR(objectViewDistanceCoeff) > 0) then { + private _text = ""; // FoV Based or % if (GVAR(objectViewDistanceCoeff) == 6) then { _text = format ["%1 %2
Min. %3
Max. %4
", localize LSTRING(objectinfotext), localize LSTRING(object_fovBased), GVAR(fovBasedPFHminimalViewDistance), viewDistance]; } else { - _text = if (_new_view_distance <= _view_distance_limit) then { - format ["%1 %2m", localize LSTRING(infotext), viewDistance]; - } else { - format ["%1 %2m", localize LSTRING(invalid), viewDistance]; - }; - _text = _text + format ["
%1 %2%3", localize LSTRING(objectinfotext), _object_view_distance_coeff * 100, "%"]; + _text = [ + format ["%1 %2m", localize LSTRING(invalid), viewDistance], + format ["%1 %2m", localize LSTRING(infotext), viewDistance] + ] select (_newViewDistance <= _viewDistanceLimit); + _text = _text + format ["
%1 %2%3", localize LSTRING(objectinfotext), _objectViewDistanceCoeff * 100, "%"]; }; [parseText _text, 2] call EFUNC(common,displayTextStructured); }; diff --git a/addons/viewdistance/functions/fnc_returnObjectCoeff.sqf b/addons/viewdistance/functions/fnc_returnObjectCoeff.sqf index 90c70b810c..257dca2995 100644 --- a/addons/viewdistance/functions/fnc_returnObjectCoeff.sqf +++ b/addons/viewdistance/functions/fnc_returnObjectCoeff.sqf @@ -16,11 +16,9 @@ #include "script_component.hpp" -private ["_return"]; - params ["_index"]; -_return = switch (_index) do { +switch (_index) do { case 0: {0.00}; // Off case 1: {0.20}; // Very Low case 2: {0.40}; // Low @@ -30,5 +28,3 @@ _return = switch (_index) do { case 6: {"fov"}; // FoV Based default {0.50}; // something broke if this returns }; - -_return; diff --git a/addons/viewdistance/functions/fnc_returnValue.sqf b/addons/viewdistance/functions/fnc_returnValue.sqf index 7224292fa4..35c0894520 100644 --- a/addons/viewdistance/functions/fnc_returnValue.sqf +++ b/addons/viewdistance/functions/fnc_returnValue.sqf @@ -16,28 +16,23 @@ #include "script_component.hpp" -private ["_return"]; - params ["_index"]; -_return = switch (_index) do { - case 0: {viewDistance}; // Video Settings option - case 1: {500}; - case 2: {1000}; - case 3: {1500}; - case 4: {2000}; - case 5: {2500}; - case 6: {3000}; - case 7: {3500}; - case 8: {4000}; - case 9: {5000}; - case 10: {6000}; - case 11: {7000}; - case 12: {8000}; - case 13: {9000}; - case 14: {10000}; - default {1000}; +switch (_index) do { + case 0: {viewDistance}; // Video Settings option + case 1: {500}; + case 2: {1000}; + case 3: {1500}; + case 4: {2000}; + case 5: {2500}; + case 6: {3000}; + case 7: {3500}; + case 8: {4000}; + case 9: {5000}; + case 10: {6000}; + case 11: {7000}; + case 12: {8000}; + case 13: {9000}; + case 14: {10000}; + default {1000}; }; - -TRACE_1("VD Index Return",_return); -_return diff --git a/addons/viewdistance/functions/fnc_setFovBasedOvdPFH.sqf b/addons/viewdistance/functions/fnc_setFovBasedOvdPFH.sqf index bcde34316a..4a57747d97 100644 --- a/addons/viewdistance/functions/fnc_setFovBasedOvdPFH.sqf +++ b/addons/viewdistance/functions/fnc_setFovBasedOvdPFH.sqf @@ -17,10 +17,6 @@ #include "script_component.hpp" -#define VD_ZOOM_NORMAL 1.00041 -#define VD_ZOOM_DIVISION 35 -#define VD_ZOOM_DIVISION_AIR 10 - params ["", "_idPFH"]; // Remove PFH and set Object View Distance back to what it was before @@ -29,25 +25,20 @@ if (GVAR(objectViewDistanceCoeff) < 6) exitWith { GVAR(fovBasedPFHminimalViewDistance) = nil; }; -private ["_zoom"]; -_zoom = (call CBA_fnc_getFov) select 1; +private _zoom = (call CBA_fnc_getFov) select 1; -// Air -if ((vehicle ACE_player) isKindOf "Air") exitWith { - if (_zoom > VD_ZOOM_NORMAL) then { - // Dynamically set Object View Distance based on player's Zoom Level and View Distance - setObjectViewDistance ((_zoom / VD_ZOOM_DIVISION_AIR * (viewDistance - GVAR(fovBasedPFHminimalViewDistance))) + GVAR(fovBasedPFHminimalViewDistance)); - } else { - setObjectViewDistance (GVAR(fovBasedPFHminimalViewDistance) + viewDistance / 10); - }; - TRACE_2("FoV Based",getObjectViewDistance select 0,_zoom); -}; - -// Land if (_zoom > VD_ZOOM_NORMAL) then { // Dynamically set Object View Distance based on player's Zoom Level and View Distance - setObjectViewDistance ((_zoom / VD_ZOOM_DIVISION * (viewDistance - GVAR(fovBasedPFHminimalViewDistance))) + GVAR(fovBasedPFHminimalViewDistance)); + if ((vehicle ACE_player) isKindOf "Air") then { + setObjectViewDistance ((_zoom / VD_ZOOM_DIVISION_AIR * (viewDistance - GVAR(fovBasedPFHminimalViewDistance))) + GVAR(fovBasedPFHminimalViewDistance)); + } else { + setObjectViewDistance ((_zoom / VD_ZOOM_DIVISION * (viewDistance - GVAR(fovBasedPFHminimalViewDistance))) + GVAR(fovBasedPFHminimalViewDistance)); + }; } else { - setObjectViewDistance GVAR(fovBasedPFHminimalViewDistance); + if ((vehicle ACE_player) isKindOf "Air") then { + setObjectViewDistance (GVAR(fovBasedPFHminimalViewDistance) + viewDistance / 10); + } else { + setObjectViewDistance GVAR(fovBasedPFHminimalViewDistance); + }; }; TRACE_2("FoV Based",getObjectViewDistance select 0,_zoom); diff --git a/addons/viewdistance/script_component.hpp b/addons/viewdistance/script_component.hpp index dfd04bbf9d..f5cd31f8ce 100644 --- a/addons/viewdistance/script_component.hpp +++ b/addons/viewdistance/script_component.hpp @@ -15,3 +15,8 @@ #endif #include "\z\ace\addons\main\script_macros.hpp" + + +#define VD_ZOOM_NORMAL 1.00041 +#define VD_ZOOM_DIVISION 35 +#define VD_ZOOM_DIVISION_AIR 10 From 04831267f24557e3da260d8db366643c7a0e2792 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 14 Apr 2016 13:55:15 +0200 Subject: [PATCH 120/215] Use lazy evaluation --- addons/viewdistance/functions/fnc_adaptViewDistance.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/viewdistance/functions/fnc_adaptViewDistance.sqf b/addons/viewdistance/functions/fnc_adaptViewDistance.sqf index 87b6232e99..4816ee946e 100644 --- a/addons/viewdistance/functions/fnc_adaptViewDistance.sqf +++ b/addons/viewdistance/functions/fnc_adaptViewDistance.sqf @@ -22,7 +22,7 @@ if (!GVAR(enabled) || isNull ACE_player) exitWith {}; private _vehicle = vehicle ACE_player; -private _landVehicle = _vehicle isKindOf "LandVehicle" || _vehicle isKindOf "Ship_F"; +private _landVehicle = _vehicle isKindOf "LandVehicle" || {_vehicle isKindOf "Ship_F"}; private _airVehicle = _vehicle isKindOf "Air"; if (!_landVehicle && !_airVehicle) exitWith { From 300d069e782e7877f67d367536cc9da2dee49f32 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 14 Apr 2016 13:59:31 +0200 Subject: [PATCH 121/215] Exclude FRIES from repair interactions --- addons/repair/CfgEventHandlers.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/repair/CfgEventHandlers.hpp b/addons/repair/CfgEventHandlers.hpp index ffd75a38bc..3de22a2da4 100644 --- a/addons/repair/CfgEventHandlers.hpp +++ b/addons/repair/CfgEventHandlers.hpp @@ -35,7 +35,7 @@ class Extended_InitPost_EventHandlers { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); serverInit = QUOTE(_this call DFUNC(addSpareParts)); - exclude[] = {QEGVAR(fastroping,helper)}; + exclude[] = {QEGVAR(fastroping,helper), "ACE_friesAnchorBar"}; }; }; class Plane { From 839d06779789a481d033f5d60f57183aeb37af57 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 14 Apr 2016 17:38:11 +0200 Subject: [PATCH 122/215] Exclude base FRIES class --- addons/repair/CfgEventHandlers.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/repair/CfgEventHandlers.hpp b/addons/repair/CfgEventHandlers.hpp index 3de22a2da4..06647d8dd5 100644 --- a/addons/repair/CfgEventHandlers.hpp +++ b/addons/repair/CfgEventHandlers.hpp @@ -35,7 +35,7 @@ class Extended_InitPost_EventHandlers { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); serverInit = QUOTE(_this call DFUNC(addSpareParts)); - exclude[] = {QEGVAR(fastroping,helper), "ACE_friesAnchorBar"}; + exclude[] = {QEGVAR(fastroping,helper), "ACE_friesBase"}; }; }; class Plane { From d523ef1fcd8ee75b852fa35a0893658edb29c120 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 14 Apr 2016 10:57:36 -0500 Subject: [PATCH 123/215] Try to use cursorObject first --- addons/javelin/functions/fnc_onOpticDraw.sqf | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/addons/javelin/functions/fnc_onOpticDraw.sqf b/addons/javelin/functions/fnc_onOpticDraw.sqf index 4bf80641e3..67e337291b 100644 --- a/addons/javelin/functions/fnc_onOpticDraw.sqf +++ b/addons/javelin/functions/fnc_onOpticDraw.sqf @@ -98,11 +98,17 @@ if (_range > 50 && {_range < 2500}) then { }; }; -if (isNull _newTarget) then { - private _intersectionsToCursorTarget = lineIntersectsSurfaces [(AGLtoASL positionCameraToWorld [0,0,0]), aimPos cursorTarget, ace_player, cursorTarget, true, 1]; - if (_intersectionsToCursorTarget isEqualTo []) then { - _newTarget = cursorTarget; - }; +if ((isNull _newTarget) && {cursorObject isKindOf "AllVehicles"}) then { + private _intersectionsToCursorTarget = lineIntersectsSurfaces [(AGLtoASL positionCameraToWorld [0,0,0]), aimPos cursorObject, ace_player, cursorObject, true, 1]; + if (_intersectionsToCursorTarget isEqualTo []) then { + _newTarget = cursorObject; + }; +}; +if ((isNull _newTarget) && {cursorTarget isKindOf "AllVehicles"}) then { + private _intersectionsToCursorTarget = lineIntersectsSurfaces [(AGLtoASL positionCameraToWorld [0,0,0]), aimPos cursorTarget, ace_player, cursorTarget, true, 1]; + if (_intersectionsToCursorTarget isEqualTo []) then { + _newTarget = cursorTarget; + }; }; // Create constants From d90fc3dd06a90c87d7aacc4c92186a9cca4eca2d Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 14 Apr 2016 18:58:01 +0200 Subject: [PATCH 124/215] Fix variable name and header examples --- addons/tagging/functions/fnc_createTag.sqf | 8 ++++---- addons/tagging/functions/fnc_tag.sqf | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/tagging/functions/fnc_createTag.sqf b/addons/tagging/functions/fnc_createTag.sqf index 5fa31478e2..4f83196524 100644 --- a/addons/tagging/functions/fnc_createTag.sqf +++ b/addons/tagging/functions/fnc_createTag.sqf @@ -13,15 +13,15 @@ * Tag created * * Example: - * [positionASL, vectorDirAndUp, "black", object] call ace_tagging_fnc_createTag + * [positionASL, vectorDirAndUp, "z\ace\addons\tagging\UI\tags\black\0.paa", object] call ace_tagging_fnc_createTag * * Public: No */ #include "script_component.hpp" -params ["_tagPosASL", "_vectorDirAndUp", "_color", "_object", "_unit"]; -TRACE_5("createTag:",_tagPosASL,_vectorDirAndUp,_color,_object,_unit); +params ["_tagPosASL", "_vectorDirAndUp", "_texture", "_object", "_unit"]; +TRACE_5("createTag:",_tagPosASL,_vectorDirAndUp,_texture,_object,_unit); if (_texture == "") exitWith { ACE_LOGERROR_1("%1 is not a valid tag texture.",_texture); @@ -34,7 +34,7 @@ _tag setPosASL _tagPosASL; _tag setVectorDirAndUp _vectorDirAndUp; // Throw a global event for mision makers -["tagCreated", [_tag, _color, _object, _unit]] call EFUNC(common,globalEvent); +["tagCreated", [_tag, _texture, _object, _unit]] call EFUNC(common,globalEvent); if (isNull _object) exitWith {true}; diff --git a/addons/tagging/functions/fnc_tag.sqf b/addons/tagging/functions/fnc_tag.sqf index 3bd559f702..43e951629e 100644 --- a/addons/tagging/functions/fnc_tag.sqf +++ b/addons/tagging/functions/fnc_tag.sqf @@ -10,7 +10,7 @@ * Sucess * * Example: - * success = [player, "blue"] call ace_tagging_fnc_tag + * success = [player, "z\ace\addons\tagging\UI\tags\black\0.paa"] call ace_tagging_fnc_tag * * Public: Yes */ From 7bd2378c41bf6b6275ecd25e1755ec7bfed34393 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 16 Apr 2016 12:54:33 -0500 Subject: [PATCH 125/215] Concertina Wire - Don't recoil broken wire, fix killer Close #3695 - Don't recoil broken wire - Use midpoint to search for nearby cars, and ensure the veh was moving. --- addons/concertina_wire/CfgVehicles.hpp | 2 +- addons/concertina_wire/functions/fnc_handleKilled.sqf | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/addons/concertina_wire/CfgVehicles.hpp b/addons/concertina_wire/CfgVehicles.hpp index dd18c07209..88975ea7e9 100644 --- a/addons/concertina_wire/CfgVehicles.hpp +++ b/addons/concertina_wire/CfgVehicles.hpp @@ -86,7 +86,7 @@ class CfgVehicles { selection = ""; displayName = "$STR_ACE_UNROLLWIRE"; distance = 5; - condition = "true"; + condition = "alive _target"; statement = QUOTE([ARR_2(_target,_player)] call FUNC(dismount)); showDisabled = 0; exceptions[] = {}; diff --git a/addons/concertina_wire/functions/fnc_handleKilled.sqf b/addons/concertina_wire/functions/fnc_handleKilled.sqf index ac59798d10..1af3f93151 100644 --- a/addons/concertina_wire/functions/fnc_handleKilled.sqf +++ b/addons/concertina_wire/functions/fnc_handleKilled.sqf @@ -14,13 +14,17 @@ */ #include "script_component.hpp" params ["_wire", "_killer"]; +TRACE_2("params",_wire,_killer); private ["_distance", "_vehicle"]; if (isNull _killer) then { _killer = _wire getVariable ["ace_concertina_wire_lastDamager", objNull]; if (isNull _killer) then { - _killer = nearestObject [_wire, "car"]; + private _midPoint = ((_wire selectionPosition "start") vectorAdd (_wire selectionPosition "deploy")) vectorMultiply 0.5; + { + if ((vectorMagnitude velocity _x) > 0) exitWith {_killer = _x}; + } forEach (nearestObjects [(_wire modelToWorld _midPoint), ["Car"], 8]); }; }; if (isNull _killer || {_killer == _wire} || {_killer == gunner (vehicle _killer)}) exitWith {}; From 23632281cfe8c1f3bed73833dfd0cb574b7686ef Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sun, 17 Apr 2016 23:22:41 -0500 Subject: [PATCH 126/215] Add day (non night vision) version of the vector 21 --- .../functions/fnc_handleFired.sqf | 2 +- addons/dagr/functions/fnc_menuInit.sqf | 2 +- addons/vector/CfgWeapons.hpp | 5 +++++ addons/vector/config.cpp | 2 +- addons/vector/functions/fnc_onKeyHold.sqf | 2 +- addons/vector/initKeybinds.sqf | 4 ++-- addons/vector/stringtable.xml | 12 ++++++++++++ 7 files changed, 23 insertions(+), 6 deletions(-) diff --git a/addons/advanced_ballistics/functions/fnc_handleFired.sqf b/addons/advanced_ballistics/functions/fnc_handleFired.sqf index 9646f065d4..aa6922946a 100644 --- a/addons/advanced_ballistics/functions/fnc_handleFired.sqf +++ b/addons/advanced_ballistics/functions/fnc_handleFired.sqf @@ -88,7 +88,7 @@ if (GVAR(ammoTemperatureEnabled) || GVAR(barrelLengthInfluenceEnabled)) then { _bulletTraceVisible = false; if (GVAR(bulletTraceEnabled) && cameraView == "GUNNER") then { - if (currentWeapon ACE_player in ["ACE_Vector", "Binocular", "Rangefinder", "Laserdesignator"]) then { + if (currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay", "Binocular", "Rangefinder", "Laserdesignator"]) then { _bulletTraceVisible = true; } else { if (currentWeapon ACE_player == primaryWeapon ACE_player && count primaryWeaponItems ACE_player > 2) then { diff --git a/addons/dagr/functions/fnc_menuInit.sqf b/addons/dagr/functions/fnc_menuInit.sqf index e4fb341537..471150dd1c 100644 --- a/addons/dagr/functions/fnc_menuInit.sqf +++ b/addons/dagr/functions/fnc_menuInit.sqf @@ -522,7 +522,7 @@ GVAR(menuRun) = true; (__dsp displayCtrl __mainText) ctrlSetText "Connecting..."; }; if (ACE_time - GVAR(busyTimer) > 0.6) then { - if (ACE_player hasWeapon "ACE_Vector") then { + if ((ACE_player hasWeapon "ACE_Vector") || {ACE_player hasWeapon "ACE_VectorDay"}) then { GVAR(displaySelection) = "VECTOR"; (__dsp displayCtrl __mainText) ctrlSetText "Vector Connected"; GVAR(vectorConnected) = true; diff --git a/addons/vector/CfgWeapons.hpp b/addons/vector/CfgWeapons.hpp index 019d774da8..a28321bdc8 100644 --- a/addons/vector/CfgWeapons.hpp +++ b/addons/vector/CfgWeapons.hpp @@ -13,4 +13,9 @@ class CfgWeapons { opticsZoomMin = 0.06621; weaponInfoType = "ACE_RscOptics_vector"; }; + class ACE_VectorDay: ACE_Vector { + author = ECSTRING(common,ACETeam); + displayName = CSTRING(VectorDayName); + visionMode[] = {"Normal"}; + }; }; diff --git a/addons/vector/config.cpp b/addons/vector/config.cpp index e2a52b47ef..e4cdf9a55b 100644 --- a/addons/vector/config.cpp +++ b/addons/vector/config.cpp @@ -3,7 +3,7 @@ class CfgPatches { class ADDON { units[] = {"ACE_Item_Vector"}; - weapons[] = {"ACE_Vector"}; + weapons[] = {"ACE_Vector", "ACE_VectorDay"}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"ace_common"}; author[] = {"Ghost","Hamburger SV","commy2","bux578"}; diff --git a/addons/vector/functions/fnc_onKeyHold.sqf b/addons/vector/functions/fnc_onKeyHold.sqf index ff4e5fc6ad..b76fe0ad0c 100644 --- a/addons/vector/functions/fnc_onKeyHold.sqf +++ b/addons/vector/functions/fnc_onKeyHold.sqf @@ -7,7 +7,7 @@ PFH executed while holding a vector key down. */ #include "script_component.hpp" -if (currentWeapon ACE_player != "ACE_Vector") exitWith { +if (!(currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay"])) exitWith { [_this select 1] call CBA_fnc_removePerFrameHandler; GVAR(currentMode) = ""; diff --git a/addons/vector/initKeybinds.sqf b/addons/vector/initKeybinds.sqf index babef0819c..0d4bb59d27 100644 --- a/addons/vector/initKeybinds.sqf +++ b/addons/vector/initKeybinds.sqf @@ -5,7 +5,7 @@ // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if !(currentWeapon ACE_player == "ACE_Vector" && {cameraView == "GUNNER"}) exitWith {false}; + if !((currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay"]) && {cameraView == "GUNNER"}) exitWith {false}; // prevent holding down if (GETGVAR(isDownStateKey1,false)) exitWith {false}; @@ -34,7 +34,7 @@ // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if !(currentWeapon ACE_player == "ACE_Vector" && {cameraView == "GUNNER"}) exitWith {false}; + if !((currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay"]) && {cameraView == "GUNNER"}) exitWith {false}; // prevent holding down if (GETGVAR(isDownStateKey2,false)) exitWith {false}; diff --git a/addons/vector/stringtable.xml b/addons/vector/stringtable.xml index 80135294d4..fd8d73858c 100644 --- a/addons/vector/stringtable.xml +++ b/addons/vector/stringtable.xml @@ -2,6 +2,18 @@ + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + Vector 21 Nite + + Vector 21 Vector 21 Vector 21 From 65ccf66d004cacdad823c109fe7f9a1d27ce43ed Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Mon, 18 Apr 2016 15:20:35 +0200 Subject: [PATCH 127/215] Fixed redundant privates in setCardiacArrest --- addons/medical/functions/fnc_setCardiacArrest.sqf | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/addons/medical/functions/fnc_setCardiacArrest.sqf b/addons/medical/functions/fnc_setCardiacArrest.sqf index 7b2c195f10..bf4a679bdc 100644 --- a/addons/medical/functions/fnc_setCardiacArrest.sqf +++ b/addons/medical/functions/fnc_setCardiacArrest.sqf @@ -27,11 +27,10 @@ _unit setVariable [QGVAR(heartRate), 0]; _timeInCardiacArrest = 120 + round(random(600)); [{ - private ["_args","_unit","_startTime","_timeInCardiacArrest","_heartRate"]; params ["_args", "_idPFH"]; _args params ["_unit", "_startTime", "_timeInCardiacArrest"]; - _heartRate = _unit getVariable [QGVAR(heartRate), 80]; + private _heartRate = _unit getVariable [QGVAR(heartRate), 80]; if (_heartRate > 0 || !alive _unit) exitWith { [_idPFH] call CBA_fnc_removePerFrameHandler; _unit setVariable [QGVAR(inCardiacArrest), nil,true]; From 236ad912af949e3b077d33326ab46fc9afb5c808 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 19 Apr 2016 12:59:41 -0500 Subject: [PATCH 128/215] Gforces - Add ace_setting to only run in aircraft --- addons/gforces/ACE_Settings.hpp | 8 ++++ addons/gforces/XEH_PREP.hpp | 2 +- addons/gforces/XEH_postInit.sqf | 42 +++++++++++++++---- addons/gforces/functions/fnc_addPFEH.sqf | 29 +++++++++++++ .../functions/fnc_pfhUpdateGForces.sqf | 6 ++- addons/gforces/stringtable.xml | 15 +++++++ 6 files changed, 90 insertions(+), 12 deletions(-) create mode 100644 addons/gforces/ACE_Settings.hpp create mode 100644 addons/gforces/functions/fnc_addPFEH.sqf create mode 100644 addons/gforces/stringtable.xml diff --git a/addons/gforces/ACE_Settings.hpp b/addons/gforces/ACE_Settings.hpp new file mode 100644 index 0000000000..617adb21da --- /dev/null +++ b/addons/gforces/ACE_Settings.hpp @@ -0,0 +1,8 @@ +class ACE_Settings { + class GVAR(enabledFor) { + displayName = CSTRING(enabledFor_displayName); + typeName = "SCALAR"; + value = 2; + values[] = {ECSTRING(Common,Disabled), CSTRING(enabledFor_onlyAircraft), ECSTRING(Common,Enabled)}; + }; +}; diff --git a/addons/gforces/XEH_PREP.hpp b/addons/gforces/XEH_PREP.hpp index 1d3d8dac05..d7ef509174 100644 --- a/addons/gforces/XEH_PREP.hpp +++ b/addons/gforces/XEH_PREP.hpp @@ -1,2 +1,2 @@ - +PREP(addPFEH); PREP(pfhUpdateGForces); diff --git a/addons/gforces/XEH_postInit.sqf b/addons/gforces/XEH_postInit.sqf index 23abe8e826..d1df112606 100644 --- a/addons/gforces/XEH_postInit.sqf +++ b/addons/gforces/XEH_postInit.sqf @@ -2,14 +2,38 @@ if (!hasInterface) exitWith {}; -// Setup ppEffect -GVAR(GForces_CC) = ppEffectCreate ["ColorCorrections", 4215]; -GVAR(GForces_CC) ppEffectEnable true; -GVAR(GForces_CC) ppEffectForceInNVG true; -GVAR(GForces_CC) ppEffectAdjust [1,1,0,[0,0,0,1],[0,0,0,0],[1,1,1,1],[10,10,0,0,0,0.1,0.5]]; -GVAR(GForces_CC) ppEffectCommit 0.4; +GVAR(pfID) = -1; -GVAR(lastUpdateTime) = 0; -GVAR(oldVel) = [0,0,0]; +["SettingsInitialized", { + TRACE_1("SettingsInitialized eh",GVAR(enabledFor)); -[DFUNC(pfhUpdateGForces), 0, []] call CBA_fnc_addPerFrameHandler; + if (GVAR(enabledFor) == 0) exitWith {}; //Module has no effect if enabledFor is "None" + if (GVAR(enabledFor) == 2) exitWith { //PFEH is always on when enabledFor is "All" + [] call FUNC(addPFEH); + TRACE_1("adding perm PFEH",GVAR(pfID)); + }; + + //PFEH only runs when player is in a type "Air" vehicle when enabledFor is "Aircraft" + + if ((!isNull (vehicle ACE_player)) && {(vehicle ACE_player) isKindOf "Air"}) then { //"playerVehicleChanged" can happen before "settingInit" + [] call FUNC(addPFEH); + TRACE_1("adding temp PFEH [start in]",GVAR(pfID)); + }; + ["playerVehicleChanged", { + params ["", "_vehicle"]; + TRACE_2("playerVehicleChanged",_vehicle,typeOf _vehicle); + if (_vehicle isKindOf "Air") then { + if (GVAR(pfID) == -1) then { + [] call FUNC(addPFEH); + TRACE_1("adding temp PFEH",GVAR(pfID)); + }; + } else { + if (GVAR(pfID) != -1) then { + TRACE_1("removing temp PFEH",GVAR(pfID)); + ppEffectDestroy GVAR(GForces_CC); + [GVAR(pfID)] call CBA_fnc_removePerFrameHandler; + GVAR(pfID) = -1; + }; + }; + }] call EFUNC(common,addEventHandler); +}] call EFUNC(common,addEventHandler); diff --git a/addons/gforces/functions/fnc_addPFEH.sqf b/addons/gforces/functions/fnc_addPFEH.sqf new file mode 100644 index 0000000000..50311c3a06 --- /dev/null +++ b/addons/gforces/functions/fnc_addPFEH.sqf @@ -0,0 +1,29 @@ +/* + * Author: KoffeinFlummi and esteldunedain + * Adds the PFEH + * + * Argument: + * None + * + * Return value: + * None + * + * Public: No + */ +#include "script_component.hpp" + +//Reset forces array +GVAR(GForces) = []; +GVAR(GForces_Index) = 0; + +// Setup ppEffect +GVAR(GForces_CC) = ppEffectCreate ["ColorCorrections", 4215]; +GVAR(GForces_CC) ppEffectEnable true; +GVAR(GForces_CC) ppEffectForceInNVG true; +GVAR(GForces_CC) ppEffectAdjust [1,1,0,[0,0,0,1],[0,0,0,0],[1,1,1,1],[10,10,0,0,0,0.1,0.5]]; +GVAR(GForces_CC) ppEffectCommit 0.4; + +GVAR(lastUpdateTime) = 0; +GVAR(oldVel) = [0,0,0]; + +GVAR(pfID) = [DFUNC(pfhUpdateGForces), 0, []] call CBA_fnc_addPerFrameHandler; diff --git a/addons/gforces/functions/fnc_pfhUpdateGForces.sqf b/addons/gforces/functions/fnc_pfhUpdateGForces.sqf index dd569781e7..dc6f11ee39 100644 --- a/addons/gforces/functions/fnc_pfhUpdateGForces.sqf +++ b/addons/gforces/functions/fnc_pfhUpdateGForces.sqf @@ -13,14 +13,14 @@ */ #include "script_component.hpp" -EXPLODE_2_PVT(_this,_params,_pfhId); - // Update the g-forces at constant mission time intervals (taking accTime into account) if ((ACE_time - GVAR(lastUpdateTime)) < INTERVAL) exitWith {}; GVAR(lastUpdateTime) = ACE_time; if (isNull ACE_player || !(alive ACE_player)) exitWith {}; +BEGIN_COUNTER(everyInterval); + private _newVel = velocity (vehicle ACE_player); private _accel = ((_newVel vectorDiff GVAR(oldVel)) vectorMultiply (1 / INTERVAL)) vectorAdd [0, 0, 9.8]; // Cap maximum G's to +- 10 to avoid g-effects when the update is low fps. @@ -91,3 +91,5 @@ if !(ACE_player getVariable ["ACE_isUnconscious", false]) then { }; GVAR(GForces_CC) ppEffectCommit INTERVAL; + +END_COUNTER(everyInterval); diff --git a/addons/gforces/stringtable.xml b/addons/gforces/stringtable.xml new file mode 100644 index 0000000000..ee57af2f86 --- /dev/null +++ b/addons/gforces/stringtable.xml @@ -0,0 +1,15 @@ + + + + + Gforces Effects + Gforces Effekte + Efectos Gforces + + + Only Aircraft + Nur Luftfahrzeug + Sólo Aeronave + + + \ No newline at end of file From 3adbb59f048cd1c46fbcfd03917e841cad75dec0 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 19 Apr 2016 23:04:51 -0500 Subject: [PATCH 129/215] Geforce - Change default to aircraft only --- addons/gforces/ACE_Settings.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/gforces/ACE_Settings.hpp b/addons/gforces/ACE_Settings.hpp index 617adb21da..dbe6dec13a 100644 --- a/addons/gforces/ACE_Settings.hpp +++ b/addons/gforces/ACE_Settings.hpp @@ -2,7 +2,7 @@ class ACE_Settings { class GVAR(enabledFor) { displayName = CSTRING(enabledFor_displayName); typeName = "SCALAR"; - value = 2; + value = 1; values[] = {ECSTRING(Common,Disabled), CSTRING(enabledFor_onlyAircraft), ECSTRING(Common,Enabled)}; }; }; From cf9479efabbed227ee553af9f0b8a1edc24375e8 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 20 Apr 2016 10:40:00 -0500 Subject: [PATCH 130/215] Non-hardcoded binocular / vector detection --- addons/advanced_ballistics/functions/fnc_handleFired.sqf | 2 +- addons/dagr/functions/fnc_menuInit.sqf | 2 +- addons/vector/functions/fnc_onKeyHold.sqf | 2 +- addons/vector/initKeybinds.sqf | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/advanced_ballistics/functions/fnc_handleFired.sqf b/addons/advanced_ballistics/functions/fnc_handleFired.sqf index aa6922946a..c73cbda3d7 100644 --- a/addons/advanced_ballistics/functions/fnc_handleFired.sqf +++ b/addons/advanced_ballistics/functions/fnc_handleFired.sqf @@ -88,7 +88,7 @@ if (GVAR(ammoTemperatureEnabled) || GVAR(barrelLengthInfluenceEnabled)) then { _bulletTraceVisible = false; if (GVAR(bulletTraceEnabled) && cameraView == "GUNNER") then { - if (currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay", "Binocular", "Rangefinder", "Laserdesignator"]) then { + if ((currentWeapon ACE_player == binocular ACE_player) && {binocular ACE_player != ""}) then { _bulletTraceVisible = true; } else { if (currentWeapon ACE_player == primaryWeapon ACE_player && count primaryWeaponItems ACE_player > 2) then { diff --git a/addons/dagr/functions/fnc_menuInit.sqf b/addons/dagr/functions/fnc_menuInit.sqf index 471150dd1c..54cb4467c5 100644 --- a/addons/dagr/functions/fnc_menuInit.sqf +++ b/addons/dagr/functions/fnc_menuInit.sqf @@ -522,7 +522,7 @@ GVAR(menuRun) = true; (__dsp displayCtrl __mainText) ctrlSetText "Connecting..."; }; if (ACE_time - GVAR(busyTimer) > 0.6) then { - if ((ACE_player hasWeapon "ACE_Vector") || {ACE_player hasWeapon "ACE_VectorDay"}) then { + if (({_x isKindOf ["ACE_Vector", configFile >> "CfgWeapons"]} count (weapons ACE_player)) > 0) then { GVAR(displaySelection) = "VECTOR"; (__dsp displayCtrl __mainText) ctrlSetText "Vector Connected"; GVAR(vectorConnected) = true; diff --git a/addons/vector/functions/fnc_onKeyHold.sqf b/addons/vector/functions/fnc_onKeyHold.sqf index b76fe0ad0c..517cf3ea37 100644 --- a/addons/vector/functions/fnc_onKeyHold.sqf +++ b/addons/vector/functions/fnc_onKeyHold.sqf @@ -7,7 +7,7 @@ PFH executed while holding a vector key down. */ #include "script_component.hpp" -if (!(currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay"])) exitWith { +if (!((currentWeapon ACE_player) isKindOf ["ACE_Vector", configFile >> "CfgWeapons"])) exitWith { [_this select 1] call CBA_fnc_removePerFrameHandler; GVAR(currentMode) = ""; diff --git a/addons/vector/initKeybinds.sqf b/addons/vector/initKeybinds.sqf index 0d4bb59d27..5b099235da 100644 --- a/addons/vector/initKeybinds.sqf +++ b/addons/vector/initKeybinds.sqf @@ -5,7 +5,7 @@ // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if !((currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay"]) && {cameraView == "GUNNER"}) exitWith {false}; + if !(((currentWeapon ACE_player) isKindOf ["ACE_Vector", configFile >> "CfgWeapons"]) && {cameraView == "GUNNER"}) exitWith {false}; // prevent holding down if (GETGVAR(isDownStateKey1,false)) exitWith {false}; @@ -34,7 +34,7 @@ // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if !((currentWeapon ACE_player in ["ACE_Vector", "ACE_VectorDay"]) && {cameraView == "GUNNER"}) exitWith {false}; + if !(((currentWeapon ACE_player) isKindOf ["ACE_Vector", configFile >> "CfgWeapons"]) && {cameraView == "GUNNER"}) exitWith {false}; // prevent holding down if (GETGVAR(isDownStateKey2,false)) exitWith {false}; From c2126c3bd42b5e14d37bebdced6101d38414cf70 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 20 Apr 2016 10:48:25 -0500 Subject: [PATCH 131/215] Simplify binocular check --- addons/advanced_ballistics/functions/fnc_handleFired.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/advanced_ballistics/functions/fnc_handleFired.sqf b/addons/advanced_ballistics/functions/fnc_handleFired.sqf index c73cbda3d7..7844e8a53a 100644 --- a/addons/advanced_ballistics/functions/fnc_handleFired.sqf +++ b/addons/advanced_ballistics/functions/fnc_handleFired.sqf @@ -88,7 +88,7 @@ if (GVAR(ammoTemperatureEnabled) || GVAR(barrelLengthInfluenceEnabled)) then { _bulletTraceVisible = false; if (GVAR(bulletTraceEnabled) && cameraView == "GUNNER") then { - if ((currentWeapon ACE_player == binocular ACE_player) && {binocular ACE_player != ""}) then { + if (currentWeapon ACE_player == binocular ACE_player) then { _bulletTraceVisible = true; } else { if (currentWeapon ACE_player == primaryWeapon ACE_player && count primaryWeaponItems ACE_player > 2) then { From 4214e31678fd6bd1e2c3c95f4694d23dcc054ece Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 21 Apr 2016 13:15:35 -0500 Subject: [PATCH 132/215] Fix BIS gesture keybinds - From #3635 - FUNC(playSignal) needs "BIgesture" prefix - Interaction conditions are checked on parent, don't need on every child --- addons/gestures/CfgVehicles.hpp | 28 ++++++++++++++-------------- addons/gestures/XEH_postInit.sqf | 7 ++++--- 2 files changed, 18 insertions(+), 17 deletions(-) diff --git a/addons/gestures/CfgVehicles.hpp b/addons/gestures/CfgVehicles.hpp index 4bf98f4978..8294f43759 100644 --- a/addons/gestures/CfgVehicles.hpp +++ b/addons/gestures/CfgVehicles.hpp @@ -13,98 +13,98 @@ class CfgVehicles { class GVAR(Advance) { displayName = CSTRING(Advance); - condition = QUOTE(canStand _target); + condition = QUOTE(true); statement = QUOTE(_target playActionNow 'gestureAdvance';); showDisabled = 1; priority = 1.9; }; class GVAR(Go) { displayName = CSTRING(Go); - condition = QUOTE(canStand _target); + condition = QUOTE(true); statement = QUOTE(_target playActionNow ([ARR_2('gestureGo','gestureGoB')] select floor random 2);); showDisabled = 1; priority = 1.8; }; class GVAR(Follow) { displayName = CSTRING(Follow); - condition = QUOTE(canStand _target); + condition = QUOTE(true); statement = QUOTE(_target playActionNow 'gestureFollow';); showDisabled = 1; priority = 1.7; }; class GVAR(Up) { displayName = CSTRING(Up); - condition = QUOTE(canStand _target); + condition = QUOTE(true); statement = QUOTE(_target playActionNow 'gestureUp';); showDisabled = 1; priority = 1.5; }; class GVAR(CeaseFire) { displayName = CSTRING(CeaseFire); - condition = QUOTE(canStand _target); + condition = QUOTE(true); statement = QUOTE(_target playActionNow 'gestureCeaseFire';); showDisabled = 1; priority = 1.3; }; class GVAR(Stop) { displayName = CSTRING(Stop); - condition = QUOTE(canStand _target); + condition = QUOTE(true); statement = QUOTE(_target playActionNow 'gestureFreeze';); // BI animation - is actualls "stop" in all stances but prone showDisabled = 1; priority = 1.2; }; class GVAR(Forward) { displayName = CSTRING(Forward); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(forward)) call FUNC(playSignal)); showDisabled = 1; priority = 1.9; }; class GVAR(Regroup) { displayName = CSTRING(Regroup); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(regroup)) call FUNC(playSignal)); showDisabled = 1; priority = 1.8; }; class GVAR(Freeze) { displayName = CSTRING(Freeze); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(freeze)) call FUNC(playSignal)); showDisabled = 1; priority = 1.7; }; class GVAR(Cover) { displayName = CSTRING(Cover); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(cover)) call FUNC(playSignal)); showDisabled = 1; priority = 1.6; }; class GVAR(Point) { displayName = CSTRING(Point); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(point)) call FUNC(playSignal)); showDisabled = 1; priority = 1.5; }; class GVAR(Engage) { displayName = CSTRING(Engage); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(engage)) call FUNC(playSignal)); showDisabled = 1; priority = 1.4; }; class GVAR(Hold) { displayName = CSTRING(Hold); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(hold)) call FUNC(playSignal)); showDisabled = 1; priority = 1.3; }; class GVAR(Warning) { displayName = CSTRING(Warning); - condition = QUOTE(canStand _target && GVAR(ReloadMutex)); + condition = QUOTE(true); statement = QUOTE(QUOTE(QGVAR(warning)) call FUNC(playSignal)); showDisabled = 1; priority = 1.2; diff --git a/addons/gestures/XEH_postInit.sqf b/addons/gestures/XEH_postInit.sqf index b764aeb176..5aa1de9874 100644 --- a/addons/gestures/XEH_postInit.sqf +++ b/addons/gestures/XEH_postInit.sqf @@ -10,9 +10,10 @@ GVAR(ReloadMutex) = true; _x params ["_currentName", "_key", ["_vanillaKey", false] ]; // Don't add "ace_gestures_" prefix to BI gestures - private _signalName = _currentName; - if (!_vanillaKey) then { - _signalName = format [QGVAR(%1), _currentName]; + private _signalName = if (_vanillaKey) then { + format ["BIgesture%1", _currentName]; + } else { + format [QGVAR(%1), _currentName]; }; private _code = compile format [QUOTE('%1' call FUNC(playSignal)), _signalName]; From 097bba9b6867e1aa1b2c4f0b09182f7f0eca4bc0 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 21 Apr 2016 13:21:55 -0500 Subject: [PATCH 133/215] Spaces --- addons/gestures/XEH_postInit.sqf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/gestures/XEH_postInit.sqf b/addons/gestures/XEH_postInit.sqf index 5aa1de9874..6d9e057e29 100644 --- a/addons/gestures/XEH_postInit.sqf +++ b/addons/gestures/XEH_postInit.sqf @@ -10,10 +10,10 @@ GVAR(ReloadMutex) = true; _x params ["_currentName", "_key", ["_vanillaKey", false] ]; // Don't add "ace_gestures_" prefix to BI gestures - private _signalName = if (_vanillaKey) then { - format ["BIgesture%1", _currentName]; + private _signalName = if (_vanillaKey) then { + format ["BIgesture%1", _currentName]; } else { - format [QGVAR(%1), _currentName]; + format [QGVAR(%1), _currentName]; }; private _code = compile format [QUOTE('%1' call FUNC(playSignal)), _signalName]; From c432ce714e89ea891fb396e43aa212c5b572b00e Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 21 Apr 2016 13:56:32 -0500 Subject: [PATCH 134/215] Make explosives helpers hidden in eden. --- addons/explosives/CfgVehicles.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/explosives/CfgVehicles.hpp b/addons/explosives/CfgVehicles.hpp index 5f81bde127..d5e7e5c968 100644 --- a/addons/explosives/CfgVehicles.hpp +++ b/addons/explosives/CfgVehicles.hpp @@ -50,7 +50,7 @@ class CfgVehicles { mapSize = 0.2; icon = "iconObject_1x2"; model = "\A3\Weapons_f\dummyweapon.p3d"; - scope = 2; + scope = 1; scopeCurator = 1; vehicleClass = "Cargo"; class ACE_Actions { @@ -81,7 +81,7 @@ class CfgVehicles { mapSize = 0.2; icon = "iconObject_1x2"; model = "\A3\Structures_F\Items\Tools\MultiMeter_F.p3d"; - scope = 2; + scope = 1; scopeCurator = 1; vehicleClass = "Cargo"; class ACE_Actions { From 9bd66bc40f01699776031d05fcc4a0b6d3c5dea9 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 21 Apr 2016 15:07:13 -0500 Subject: [PATCH 135/215] Cleanup scopeCurator --- addons/explosives/CfgVehicles.hpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/addons/explosives/CfgVehicles.hpp b/addons/explosives/CfgVehicles.hpp index d5e7e5c968..3db6546208 100644 --- a/addons/explosives/CfgVehicles.hpp +++ b/addons/explosives/CfgVehicles.hpp @@ -51,7 +51,6 @@ class CfgVehicles { icon = "iconObject_1x2"; model = "\A3\Weapons_f\dummyweapon.p3d"; scope = 1; - scopeCurator = 1; vehicleClass = "Cargo"; class ACE_Actions { class ACE_MainActions { @@ -82,7 +81,6 @@ class CfgVehicles { icon = "iconObject_1x2"; model = "\A3\Structures_F\Items\Tools\MultiMeter_F.p3d"; scope = 1; - scopeCurator = 1; vehicleClass = "Cargo"; class ACE_Actions { class ACE_MainActions { From b06659a2e40e4d1136e2fa614b15e27a1fea0635 Mon Sep 17 00:00:00 2001 From: jonpas Date: Sat, 23 Apr 2016 00:29:58 +0200 Subject: [PATCH 136/215] Fix params error --- addons/ui/CfgVehicles.hpp | 3 ++- addons/ui/XEH_clientInit.sqf | 3 +-- addons/ui/functions/fnc_setElements.sqf | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/ui/CfgVehicles.hpp b/addons/ui/CfgVehicles.hpp index 24340db031..391b3627eb 100644 --- a/addons/ui/CfgVehicles.hpp +++ b/addons/ui/CfgVehicles.hpp @@ -9,13 +9,14 @@ class CfgVehicles { isGlobal = 1; icon = QUOTE(PATHTOF(UI\Icon_Module_UI_ca.paa)); class Arguments { - // BASIC class allowSelectiveUI { displayName = CSTRING(AllowSelectiveUI); description = CSTRING(AllowSelectiveUI_Description); typeName = "BOOL"; defaultValue = 1; }; + + // BASIC class soldierVehicleWeaponInfo { displayName = CSTRING(SoldierVehicleWeaponInfo); typeName = "BOOL"; diff --git a/addons/ui/XEH_clientInit.sqf b/addons/ui/XEH_clientInit.sqf index 97cc3e026b..d228696fc0 100644 --- a/addons/ui/XEH_clientInit.sqf +++ b/addons/ui/XEH_clientInit.sqf @@ -1,4 +1,3 @@ -//#define DEBUG_MODE_FULL #include "script_component.hpp" // Exit on Headless @@ -24,7 +23,7 @@ if (!hasInterface) exitWith {}; // Selective UI Basic if (_name in ELEMENTS_BASIC) then { - call FUNC(setElements); + [false] call FUNC(setElements); }; // Selective UI Advanced diff --git a/addons/ui/functions/fnc_setElements.sqf b/addons/ui/functions/fnc_setElements.sqf index 92cc981065..b94b0f9a22 100644 --- a/addons/ui/functions/fnc_setElements.sqf +++ b/addons/ui/functions/fnc_setElements.sqf @@ -20,7 +20,7 @@ if (isArray (missionConfigFile >> "showHUD")) exitWith {}; params [ ["_force", false, [true]] ]; if (!_force && {!GVAR(allowSelectiveUI)}) exitWith { - [LSTRING(Disallowed), 2] call EFUNC(common,displayTextStructured) + [LSTRING(Disallowed), 2] call EFUNC(common,displayTextStructured); }; private _shownHUD = shownHUD; // [hud, info, radar, compass, direction, menu, group, cursors] From 27c55981358383e00ad0a6b4774005c896a98f6d Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sun, 24 Apr 2016 11:26:13 -0500 Subject: [PATCH 137/215] vehicle inventory lock - compatibility with acre --- addons/vehiclelock/CfgEventHandlers.hpp | 8 ----- addons/vehiclelock/XEH_postInit.sqf | 10 +++++++ .../functions/fnc_onOpenInventory.sqf | 29 ++++++++++--------- 3 files changed, 25 insertions(+), 22 deletions(-) diff --git a/addons/vehiclelock/CfgEventHandlers.hpp b/addons/vehiclelock/CfgEventHandlers.hpp index 705415e65d..712cc2be1c 100644 --- a/addons/vehiclelock/CfgEventHandlers.hpp +++ b/addons/vehiclelock/CfgEventHandlers.hpp @@ -17,14 +17,6 @@ class Extended_PostInit_EventHandlers { }; }; -class Extended_InventoryOpened_EventHandlers { - class CAManBase { - class ADDON { - clientInventoryOpened = QUOTE(_this call FUNC(onOpenInventory);); - }; - }; -}; - class Extended_InitPost_EventHandlers { class Car { class ADDON { diff --git a/addons/vehiclelock/XEH_postInit.sqf b/addons/vehiclelock/XEH_postInit.sqf index c635de2bd3..93d8bd6426 100644 --- a/addons/vehiclelock/XEH_postInit.sqf +++ b/addons/vehiclelock/XEH_postInit.sqf @@ -3,3 +3,13 @@ //Add Event Handlers ["VehicleLock_SetupCustomKey", {_this call FUNC(serverSetupCustomKeyEH)}] call EFUNC(common,addEventHandler); ["VehicleLock_SetVehicleLock", {_this call FUNC(setVehicleLockEH)}] call EFUNC(common,addEventHandler); + +if (!hasInterface) exitwith {}; + +["SettingsInitialized", { + TRACE_1("SettingsInitialized eh",GVAR(LockVehicleInventory)); + + if (GVAR(LockVehicleInventory)) then { + ["CAManBase", "InventoryOpened", {_this call FUNC(onOpenInventory);}] call CBA_fnc_addClassEventHandler; + }; +}] call EFUNC(common,addEventHandler); diff --git a/addons/vehiclelock/functions/fnc_onOpenInventory.sqf b/addons/vehiclelock/functions/fnc_onOpenInventory.sqf index 17682c72de..5ac9ee427e 100644 --- a/addons/vehiclelock/functions/fnc_onOpenInventory.sqf +++ b/addons/vehiclelock/functions/fnc_onOpenInventory.sqf @@ -7,7 +7,7 @@ * 1: Container * * Return Value: - * Handeled + * None * * Example: * [player, car] call ACE_VehicleLock_fnc_onOpenInventory; @@ -20,10 +20,7 @@ params ["_unit", "_container"]; TRACE_2("params",_unit,_container); //Only check for player: -if (_unit != ace_player) exitWith {false}; - -private "_handeled"; -_handeled = false; +if (_unit != ace_player) exitWith {}; if (GVAR(LockVehicleInventory) && //if setting not enabled {(vehicle ace_player) == ace_player} && //Player dismounted @@ -33,15 +30,19 @@ if (GVAR(LockVehicleInventory) && //if setting not enabled ) then { //Give feedback that vehicle is locked playSound "ACE_Sound_Click"; - //don't open the vehicles inventory - _handeled = true; - // As of 1.54 the action needs to be delayed a frame to work, which used not to be the case + //For compatibiltiy with ACRE, wait until the display is open, close it and then reopen the player's own inventory + //ref: http://gitlab.idi-systems.com/idi-systems/acre2-public/issues/70 [{ - TRACE_1("delaying a frame", ace_player); - //Just opens a dummy groundContainer (so the player can still see their own inventory) - ACE_player action ["Gear", objNull]; - }, []] call EFUNC(common,execNextFrame); + !isNull (findDisplay 602) + }, + { + TRACE_1("car display open: closing", _this); + (findDisplay 602) closeDisplay 0; + [{ + TRACE_1("Opening Player Inventory", _this); + ACE_player action ["Gear", objNull] + }, []] call EFUNC(common,execNextFrame); + }, + []] call EFUNC(common,waitUntilAndExecute); }; - -_handeled From 5c3f5f5751d35751335e9e01099a809f37775b6c Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 25 Apr 2016 21:34:25 +0200 Subject: [PATCH 138/215] fix wrong macro names --- addons/recoil/CfgMoves.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/recoil/CfgMoves.hpp b/addons/recoil/CfgMoves.hpp index ecad382cb5..29bca9c81a 100644 --- a/addons/recoil/CfgMoves.hpp +++ b/addons/recoil/CfgMoves.hpp @@ -7,7 +7,7 @@ // Go through all modes that have a camshakefire defined and change it to ours. class CfgMovesBasic { class Default { - camShakeFire = ACE_CAMSHAKEFIRE_NORMAL; + camShakeFire = ACE_CAMSHAKEFIRE_BASE; }; }; @@ -69,7 +69,7 @@ class CfgMovesMaleSdr: CfgMovesBasic { class AmovPknlMstpSrasWrflDnon; class AmovPknlMwlkSrasWrflDf: AmovPknlMstpSrasWrflDnon { - camShakeFire = ACE_CAMSHAKEFIRE_NORMAL; + camShakeFire = ACE_CAMSHAKEFIRE_BASE; }; class AmovPknlMrunSrasWrflDf; From d40735d5c2a1a3fdd1f624b3ceea772c12363a56 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Mon, 25 Apr 2016 15:48:24 -0500 Subject: [PATCH 139/215] Improve synced event error logging --- addons/common/functions/fnc__handleRequestSyncedEvent.sqf | 2 +- addons/common/functions/fnc__handleSyncedEvent.sqf | 2 +- addons/common/functions/fnc_addSyncedEventHandler.sqf | 5 ++++- addons/common/functions/fnc_removeSyncedEventHandler.sqf | 2 +- addons/common/functions/fnc_syncedEvent.sqf | 2 +- 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/addons/common/functions/fnc__handleRequestSyncedEvent.sqf b/addons/common/functions/fnc__handleRequestSyncedEvent.sqf index 605af2fa85..9d6c062ac2 100644 --- a/addons/common/functions/fnc__handleRequestSyncedEvent.sqf +++ b/addons/common/functions/fnc__handleRequestSyncedEvent.sqf @@ -23,7 +23,7 @@ if (isServer) then { params ["_eventName", "_client"]; if (!HASH_HASKEY(GVAR(syncedEvents),_eventName)) exitWith { - ACE_LOGERROR("Request for synced event - key not found."); + ACE_LOGERROR_1("Request for synced event - key [%1] not found.", _eventName); false }; diff --git a/addons/common/functions/fnc__handleSyncedEvent.sqf b/addons/common/functions/fnc__handleSyncedEvent.sqf index f8fe21d760..db8151dbd7 100644 --- a/addons/common/functions/fnc__handleSyncedEvent.sqf +++ b/addons/common/functions/fnc__handleSyncedEvent.sqf @@ -17,7 +17,7 @@ params ["_name", "_args", "_ttl"]; if (!HASH_HASKEY(GVAR(syncedEvents),_name)) exitWith { - ACE_LOGERROR("Synced event key not found."); + ACE_LOGERROR_1("Synced event key [%1] not found (_handleSyncedEvent).", _name); false }; diff --git a/addons/common/functions/fnc_addSyncedEventHandler.sqf b/addons/common/functions/fnc_addSyncedEventHandler.sqf index 0964e419bc..126bb6a957 100644 --- a/addons/common/functions/fnc_addSyncedEventHandler.sqf +++ b/addons/common/functions/fnc_addSyncedEventHandler.sqf @@ -10,6 +10,9 @@ * Return Value: * Boolean of success * + * Example: + * ["myEvent", {_this call x}, 0] call ace_common_fnc_addSyncedEventHandler + * * Public: Yes */ #include "script_component.hpp" @@ -17,7 +20,7 @@ params ["_name", "_handler", ["_ttl", 0]]; if (HASH_HASKEY(GVAR(syncedEvents),_name)) exitWith { - ACE_LOGERROR("Duplicate synced event creation."); + ACE_LOGERROR_1("Duplicate synced event [%1] creation.",_name); false }; diff --git a/addons/common/functions/fnc_removeSyncedEventHandler.sqf b/addons/common/functions/fnc_removeSyncedEventHandler.sqf index 126bf0b70f..23803acdd1 100644 --- a/addons/common/functions/fnc_removeSyncedEventHandler.sqf +++ b/addons/common/functions/fnc_removeSyncedEventHandler.sqf @@ -15,7 +15,7 @@ params ["_name"]; if (!HASH_HASKEY(GVAR(syncedEvents),_name)) exitWith { - ACE_LOGERROR("Synced event key not found."); + ACE_LOGERROR_1("Synced event key [%1] not found (removeSyncedEventHandler).", _name); false }; diff --git a/addons/common/functions/fnc_syncedEvent.sqf b/addons/common/functions/fnc_syncedEvent.sqf index 4ed8107330..c752d1eba2 100644 --- a/addons/common/functions/fnc_syncedEvent.sqf +++ b/addons/common/functions/fnc_syncedEvent.sqf @@ -17,7 +17,7 @@ params ["_name", "_args", ["_ttl", 0]]; if (!HASH_HASKEY(GVAR(syncedEvents),_name)) exitWith { - ACE_LOGERROR("Synced event key not found."); + ACE_LOGERROR_1("Synced event key [%1] not found (syncedEvent).", _name); false }; From 3389bc5e1b0005c808c8b8f835b9d7a8c6c6d3ee Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 28 Apr 2016 04:44:57 +0200 Subject: [PATCH 140/215] Add cargo to Taru pods --- addons/cargo/CfgVehicles.hpp | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/addons/cargo/CfgVehicles.hpp b/addons/cargo/CfgVehicles.hpp index dfeab3b017..3b2239019d 100644 --- a/addons/cargo/CfgVehicles.hpp +++ b/addons/cargo/CfgVehicles.hpp @@ -304,6 +304,25 @@ class CfgVehicles { GVAR(canLoad) = 1; }; + // Taru pods + class Pod_Heli_Transport_04_base_F; + class Land_Pod_Heli_Transport_04_ammo_F: Pod_Heli_Transport_04_base_F { + GVAR(space) = 8; + GVAR(hasCargo) = 1; + }; + class Land_Pod_Heli_Transport_04_box_F: Pod_Heli_Transport_04_base_F { + GVAR(space) = 20; + GVAR(hasCargo) = 1; + }; + class Land_Pod_Heli_Transport_04_medevac_F: Pod_Heli_Transport_04_base_F { + GVAR(space) = 8; + GVAR(hasCargo) = 1; + }; + class Land_Pod_Heli_Transport_04_repair_F: Pod_Heli_Transport_04_base_F { + GVAR(space) = 12; + GVAR(hasCargo) = 1; + }; + class StaticMortar; class Mortar_01_base_F: StaticMortar { GVAR(size) = 2; // 1 = small, 2 = large From d826c91c99358f633f3338e6232bdd11087823ec Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 27 Apr 2016 22:58:47 -0500 Subject: [PATCH 141/215] Cleanup reload launchers --- .../functions/fnc_addMissileReloadActions.sqf | 28 +++++++++++-------- .../reloadlaunchers/functions/fnc_canLoad.sqf | 11 +++----- .../functions/fnc_getLoadableMissiles.sqf | 12 ++++---- addons/reloadlaunchers/functions/fnc_load.sqf | 11 +++----- .../functions/fnc_reloadLauncher.sqf | 6 ++-- 5 files changed, 33 insertions(+), 35 deletions(-) diff --git a/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf b/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf index a07afe8e22..f6cd923845 100644 --- a/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf +++ b/addons/reloadlaunchers/functions/fnc_addMissileReloadActions.sqf @@ -3,28 +3,31 @@ * Create one action per reloadable missile * * Argument: - * 1: Player (Object) - * 0: Target (Object) - * 2: Parameters ??? (Array) + * 1: Target (Object) + * 0: Player (Object) * * Return value: * Children actions (Array) * + * Public: No + * */ #include "script_component.hpp" -private ["_unit", "_target", "_parameters"]; +params ["_target", "_unit"]; +TRACE_2("params",_target,_unit); -_unit = _this select 1; -_target = _this select 0; -_parameters = _this select 2; // ??? +//Fast exit for common case: +private _weapon = secondaryWeapon _target; +if ((_weapon == "") || {(getNumber (configFile >> "CfgWeapons" >> _weapon >> QGVAR(enabled))) == 0}) exitWith { + TRACE_1("weapon not supported",_weapon); + [] +}; -private ["_actions", "_weapon", "_loadableMissiles"]; +private _actions = []; -_actions = []; - -_weapon = secondaryWeapon _target; -_loadableMissiles = [_unit, _weapon] call FUNC(getLoadableMissiles); +private _loadableMissiles = [_unit, _weapon] call FUNC(getLoadableMissiles); +TRACE_2("",_weapon,_loadableMissiles); { private ["_name", "_displayName", "_statement", "_condition", "_action"]; @@ -45,4 +48,5 @@ _loadableMissiles = [_unit, _weapon] call FUNC(getLoadableMissiles); _actions pushBack [_action, [], _unit]; } forEach _loadableMissiles; +TRACE_1("return",_actions); _actions diff --git a/addons/reloadlaunchers/functions/fnc_canLoad.sqf b/addons/reloadlaunchers/functions/fnc_canLoad.sqf index 5bbfe4dd87..116a900092 100644 --- a/addons/reloadlaunchers/functions/fnc_canLoad.sqf +++ b/addons/reloadlaunchers/functions/fnc_canLoad.sqf @@ -1,6 +1,5 @@ /* * Author: commy2 - * * Check of the unit can reload the launcher of target unit. * * Argument: @@ -11,15 +10,13 @@ * * Return value: * NONE + * + * Public: No */ #include "script_component.hpp" -private ["_unit", "_target", "_weapon", "_magazine"]; - -_unit = _this select 0; -_target = _this select 1; -_weapon = _this select 2; -_magazine = _this select 3; +params ["_unit", "_target", "_weapon", "_magazine"]; +TRACE_4("params",_unit,_target,_weapon,_magazine); if (!alive _target) exitWith {false}; if (vehicle _target != _target) exitWith {false}; diff --git a/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf b/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf index e75d826513..f466490b64 100644 --- a/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf +++ b/addons/reloadlaunchers/functions/fnc_getLoadableMissiles.sqf @@ -1,6 +1,5 @@ /* * Author: commy2 - * * Return all magazine types from reloaders inventory that are compatible with given weapon. * * Argument: @@ -9,17 +8,16 @@ * * Return value: * Reloable magazines (Array) + * + * Public: No */ #include "script_component.hpp" -private ["_unit", "_weapon"]; - -_unit = _this select 0; -_weapon = _this select 1; +params ["_unit", "_weapon"]; +TRACE_2("params",_unit,_weapon); // get available magazines of reloader, Note: "magazines" does not include currently loaded magazines -private "_magazines"; -_magazines = magazines _unit; +private _magazines = magazines _unit; // case sensitvity _magazines = _magazines apply {toLower _x}; diff --git a/addons/reloadlaunchers/functions/fnc_load.sqf b/addons/reloadlaunchers/functions/fnc_load.sqf index ce7b743df5..db010b5e47 100644 --- a/addons/reloadlaunchers/functions/fnc_load.sqf +++ b/addons/reloadlaunchers/functions/fnc_load.sqf @@ -1,6 +1,5 @@ /* * Author: commy2 - * * Reload a launcher * * Argument: @@ -11,15 +10,13 @@ * * Return value: * NONE + * + * Public: No */ #include "script_component.hpp" -private ["_unit", "_target", "_weapon", "_magazine"]; - -_unit = _this select 0; -_target = _this select 1; -_weapon = _this select 2; -_magazine = _this select 3; +params ["_unit", "_target", "_weapon", "_magazine"]; +TRACE_4("params",_unit,_target,_weapon,_magazine); private "_reloadTime"; _reloadTime = getNumber (configFile >> "CfgWeapons" >> _weapon >> "magazineReloadTime"); diff --git a/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf b/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf index fc802a025c..2aec180d22 100644 --- a/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf +++ b/addons/reloadlaunchers/functions/fnc_reloadLauncher.sqf @@ -1,6 +1,5 @@ /* * Author: commy2 - * * Reload a launcher * * Argument: @@ -11,10 +10,13 @@ * * Return value: * NONE + * + * Public: No */ #include "script_component.hpp" -PARAMS_4(_unit,_target,_weapon,_magazine); +params ["_unit","_target","_weapon","_magazine"]; +TRACE_4("params",_unit,_target,_weapon,_magazine); _target selectWeapon _weapon; From 76659356413a9518aaa064e2dac0fb880cf0521e Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 29 Apr 2016 13:00:35 -0500 Subject: [PATCH 142/215] Use constant reload time value instead of config --- addons/reloadlaunchers/functions/fnc_load.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/reloadlaunchers/functions/fnc_load.sqf b/addons/reloadlaunchers/functions/fnc_load.sqf index db010b5e47..9f0b36ce8d 100644 --- a/addons/reloadlaunchers/functions/fnc_load.sqf +++ b/addons/reloadlaunchers/functions/fnc_load.sqf @@ -18,8 +18,8 @@ params ["_unit", "_target", "_weapon", "_magazine"]; TRACE_4("params",_unit,_target,_weapon,_magazine); -private "_reloadTime"; -_reloadTime = getNumber (configFile >> "CfgWeapons" >> _weapon >> "magazineReloadTime"); +// private _reloadTime = getNumber (configFile >> "CfgWeapons" >> _weapon >> "magazineReloadTime"); //Not a good config value, use a constant for now: +private _reloadTime = 2.5; // do animation [_unit] call EFUNC(common,goKneeling); From 7d0fcde9fa695c4612ad656a712d2c5236c3598f Mon Sep 17 00:00:00 2001 From: ProfessorCZ Date: Sat, 30 Apr 2016 00:57:24 +0200 Subject: [PATCH 143/215] CZ Translate - Update 04/30/2016 --- addons/cargo/stringtable.xml | 5 +- addons/common/stringtable.xml | 1 + addons/explosives/stringtable.xml | 6 ++ addons/fastroping/stringtable.xml | 8 +++ addons/gforces/stringtable.xml | 2 + addons/interaction/stringtable.xml | 5 +- addons/medical/stringtable.xml | 77 +++++++++++++++----------- addons/medical_menu/stringtable.xml | 10 ++-- addons/missileguidance/stringtable.xml | 4 +- addons/mk6mortar/stringtable.xml | 18 ++++++ addons/overheating/stringtable.xml | 10 +++- addons/repair/stringtable.xml | 3 +- addons/spectator/stringtable.xml | 6 +- addons/tagging/stringtable.xml | 11 +++- addons/trenches/stringtable.xml | 11 +++- addons/ui/stringtable.xml | 34 +++++++++++- 16 files changed, 160 insertions(+), 51 deletions(-) diff --git a/addons/cargo/stringtable.xml b/addons/cargo/stringtable.xml index 57daacd207..e3cb368362 100644 --- a/addons/cargo/stringtable.xml +++ b/addons/cargo/stringtable.xml @@ -175,6 +175,7 @@ Rendi oggetto caricabile Hacer objeto cargable Rendre l'objet chargeable + Vytvořit objekt nakladatelným Sets the synced object as loadable by the cargo system. @@ -183,6 +184,7 @@ Imposta l'oggetto sincronizzato come caricabile dal sistema cargo Sincronizar un objecto para hacerlo cargable. Rend l'objet synchronisé comme chargeable par le système de cargaison. + Nastaví synchronizované objekty nakladatelnými za pomocí Nákladního systému. Object's Size @@ -191,6 +193,7 @@ Dimensioni dell'oggetto Tamaño del objeto Taille de l'objet + Velikost objektu - + \ No newline at end of file diff --git a/addons/common/stringtable.xml b/addons/common/stringtable.xml index 32a979653f..820712189f 100644 --- a/addons/common/stringtable.xml +++ b/addons/common/stringtable.xml @@ -802,6 +802,7 @@ Non c'è spazio per scaricare No hay espacio para descargar. Pas de place pour décharger + Nedostatek místa k vyložení \ No newline at end of file diff --git a/addons/explosives/stringtable.xml b/addons/explosives/stringtable.xml index 4cabe2ce06..c49d09502f 100644 --- a/addons/explosives/stringtable.xml +++ b/addons/explosives/stringtable.xml @@ -648,6 +648,7 @@ Mina M6 SLAM (Ataque Inferior) Mine M6 SLAM (par le bas) Mina M6 SLAM (base) + M6 SLAM (Útok zespoda) M6 SLAM Mine (Side Attack) @@ -663,6 +664,7 @@ Mina M6 SLAM (Ataque Lateral) Mine M6 SLAM (de flanc) STR_ACE_Explosives_Module_SLAMBottomAttack_DisplayName M6 SLAM Mine (Bottom Attack) Mine M6 SLAM (par le bas) M6-SLAM-Mine (Bodenangriff) Mina M6 SLAM (base) Mina M6 SLAM (atak od dołu) Mina M6 SLAM (Laterale) + M6 SLAM (Útok do strany) Large IED (Urban, Pressure Plate) @@ -678,6 +680,7 @@ IED Grande (Urbano, Placa de presión) Grand EEI (Urbain, plaque de pression) IED grande (urbano, a pressione) + IED, Velké (Městské, Nášlapné) Large IED (Dug-in, Pressure Plate) @@ -693,6 +696,7 @@ IED Grande (Enterrado, Placa de presión) Grand EEI (Enterré, plaque de pression) IED grande (interrato, a pressione) + IED, Velké (Zakopané, Nášlapné) Small IED (Urban, Pressure Plate) @@ -708,6 +712,7 @@ IED Pequeño (Urbano, Placa de presión) Petit EEI (Urbain, plaque de pression) IED piccolo (urbano, a pressione) + IED, Malé (Městské, Nášlapné) Small IED (Dug-in, Pressure Plate) @@ -723,6 +728,7 @@ IED Pequeño (Enterrado, Placa de presión) Petit EEI (Enterré, plaque de pression) IED piccolo (interrato, a pressione) + IED, Malé (Zakopané, Nášlapné) Connect to %1 diff --git a/addons/fastroping/stringtable.xml b/addons/fastroping/stringtable.xml index 1a03e59409..7b0e4ad1f8 100644 --- a/addons/fastroping/stringtable.xml +++ b/addons/fastroping/stringtable.xml @@ -8,6 +8,7 @@ Equiper le FRIES Equipar FRIES Equipaggia la FRIES + Vybavit FRIES Equips compatible helicopters with a Fast Rope Insertion Extraction System. @@ -16,6 +17,7 @@ Equipe les hélicoptères compatibles avec un Module Fast Rope Insertion Extraction System. Equipar helicoptero compatible con un Sistema de Inserción Extracción Fast Rope. Equipagga l'elicottero compatibile con il Fast Rope Insertion Exstraction System + Vybavit kompatibilní vrtulníky systémem Fast Rope Insertion Extraction (FRIES). Prepare fast roping system @@ -24,6 +26,7 @@ Préparer le système de corde lisse Preparar el sistema fast roping Prepara le corde + Připravit systém slaňování Deploy ropes @@ -32,6 +35,7 @@ Déployer les cordes Desplegar cuerdas Srotola le corde + Připravit lana Fast rope @@ -40,6 +44,7 @@ Descendre à la corde Descender por la cuerda Scendi sulla corda + SLANIT Cut ropes @@ -48,6 +53,7 @@ Détacher les cordes Cortar cuerdas Taglia le corde + Odříznout lano Equip helicopter with FRIES @@ -56,6 +62,7 @@ Equiper l'hélicoptère avec le FRIED Equipar helicoptero con FRIES Equipaggia l'elicottero con FRIES + Vybavit vrtulník pomocí FRIES Equips the selected helicopter with a Fast Rope Insertion Extraction System @@ -64,6 +71,7 @@ Equipe l'hélicoptère sélectionné avec un Fast Rope Insertion Extraction System Equipa el helicoptero seleccionado con un Sistema de Inserción Extracción Fast Rope Equipaggia l'elicottero selezionato con il Fast Rope Insertion Extraction System + Vybavit vybraný vrtulník systémem Fast Rope Insertion Extraction (FRIES) LET UNITS FAST ROPE diff --git a/addons/gforces/stringtable.xml b/addons/gforces/stringtable.xml index ee57af2f86..f5d5f1b12d 100644 --- a/addons/gforces/stringtable.xml +++ b/addons/gforces/stringtable.xml @@ -5,11 +5,13 @@ Gforces Effects Gforces Effekte Efectos Gforces + G Force efekty Only Aircraft Nur Luftfahrzeug Sólo Aeronave + Pouze letadla \ No newline at end of file diff --git a/addons/interaction/stringtable.xml b/addons/interaction/stringtable.xml index 0e1afa21a1..812964bbb7 100644 --- a/addons/interaction/stringtable.xml +++ b/addons/interaction/stringtable.xml @@ -356,6 +356,7 @@ Aussteigen! Sal del vehículo! Sortez ! + Vystupte Team Management @@ -712,6 +713,7 @@ Encender Allumer Accendi + Zapnout Turn off @@ -720,6 +722,7 @@ Apagar Eteindre Spegni + Vypnout Pass magazine @@ -760,7 +763,7 @@ %1 podał Ci magazynek %2. %1 передал вам магазин %2. %1 passou a você um carregador %2. - %1 ti podal %2 zásobník. + %1 ti podal zásobník %2. %1 ti ha passato un caricatore %2 . %1 te pasó un cargador %2. %1 vous a passé un chargeur %2. diff --git a/addons/medical/stringtable.xml b/addons/medical/stringtable.xml index a3953be23b..ef0ccc68a2 100644 --- a/addons/medical/stringtable.xml +++ b/addons/medical/stringtable.xml @@ -56,6 +56,7 @@ Wstrzyknij adenozynę Injecter de l'adénosine Inietta andenosina + Aplikovat adenosine Inject Atropine @@ -256,6 +257,7 @@ Wstrzykiwanie adenozyny... Injection d'adénosine... Inietto l'andenosina + Aplikuji adenosine... Injecting Atropine... @@ -363,14 +365,14 @@ Bendaggio compressivo Bandage gauze Bandagem de Compressão - Tlakový obvaz + Obvaz Tlakový Elastic Bandage Elastischer Verband Vendaje elástico Давящая повязка - Elastické obinadlo + Obavaz Elastický Bandaż elastyczny Pansement élastique Rögzitő kötszer @@ -831,7 +833,7 @@ Nyomókötszer Bendaggio compressivo Bandagem de Compressão - Tlakový obvaz + Obvaz (Tlakový) Used to pack medium to large wounds and stem the bleeding @@ -864,7 +866,7 @@ Vendaje (Elástico) Bandage (Élastique) Bandaż (elastyczny) - Obvaz (elastický) + Obvaz (Elastický) Rögzító kötszer Benda (elastica) Bandagem (Elástica) @@ -936,7 +938,7 @@ Morfina auto-inyectable Auto-injecteur de Morphine Autostrzykawka z morfiną - Autoinjektor morfin + Auto-morfin Morfium autoinjektor Autoiniettore di morfina Auto-injetor de morfina @@ -972,6 +974,7 @@ Autostrzykawka z adenozyną Auto-injécteur d'adénosine Autoiniettore di adenosina + Auto-adenosine Used to counter effects of Epinephrine @@ -980,6 +983,7 @@ Adenozyna. Stosowana do zwalczania efektów działania adrenaliny. Utilisé pour contrer les effets de l'adrénaline Usato per contrastare l'effetto dell'epinefrina + Slouží jako protiváha Adrenalinu A drug used to counter the effects of Epinephrine @@ -988,6 +992,7 @@ Organiczny związek chemiczny z grupy nukleozydów. Skuteczna w leczeniu częstoskurczu komorowego. Działa rozszerzająco na naczynia krwionośne. Un composé utilisé pour contrer les effets de l'adrénaline Medicamento usato per contrastare l'effetto dell'epinefrina + Droga používaná k tlumení efektu Adrenalinu Atropine autoinjector @@ -996,7 +1001,7 @@ Auto-injecteur d'Atropine Autostrzykawka AtroPen Atropin-Autoinjektor - Autoinjektor atropin + Auto-atropine Atropin autoinjektor Autoiniettore di atropina Auto-injetor de Atropina @@ -1032,7 +1037,7 @@ Auto-injecteur d'épinéphrine Autostrzykawka EpiPen Epiniphrin-Autoinjektor - Autoinjektor adrenalin + Auto-adrenalin Epinefrin autoinjektor Autoiniettore di adrenalina Auto-injetor de epinefrina @@ -1287,7 +1292,7 @@ Elsősegélycsomag Pronto soccorso personale Kit De Primeiros Socorros Pessoal - Osobní lékárnička + Osobní lékárnička (PAK) Includes various treatment kit needed for stitching or advanced treatment @@ -1322,7 +1327,7 @@ Usar equipo de primeros auxilios Elsősegélycsomag használata Usar o kit de primeiros socorros - Použít osobní lékárničku + Použít osobní lékárničku (PAK) Usa il pronto soccorso personale @@ -1431,7 +1436,7 @@ Vérnyomás megmérése... Controllando la pressione sanguigna.. Aferindo Pressão Arterial... - Kontroluji krevní tlak... + Měřím krevní tlak... %1 checked Blood Pressure: %2 @@ -1442,7 +1447,7 @@ %1 sprawdził ciśnienie krwi: %2 %1 verificada la presión arterial: %2 %1 ellenőrizte a vérnyomást: %2 - %1 zkontrolován krevní tlak: %2 + %1 zkontroloval krevní tlak: %2 %1 verificou pressão arterial: %2 @@ -1467,7 +1472,7 @@ Wyczuwasz ciśnienie krwi o wartości %2/%3 Der Blutdruck liegt bei %2/%3 A Pressão Arterial é de %2/%3 - Našel jsi krevní tlak u %2/%3 + Naměřil si krevní tlak u %2/%3 You find a low blood pressure @@ -1479,7 +1484,7 @@ A vérnyomás alacsony La pressione sanguigna è bassa Pressão Arterial baixa - Naměřil jsi nízký krevní tlak + Naměřil si nízký krevní tlak You find a normal blood pressure @@ -1491,7 +1496,7 @@ A vérnyomás normális La pressione sanguigna è normale Pressão Arterial normal - Naměřil jsi normální krevní tlak + Naměřil si normální krevní tlak You find a high blood pressure @@ -1503,7 +1508,7 @@ A vérnyomás magas La pressione sanguigna è alta Pressão Arterial Alta - Naměřil jsi vysoký krevní tlak + Naměřil si vysoký krevní tlak You find no blood pressure @@ -1515,7 +1520,7 @@ Nem észlelhető vérnyomás La pressione sanguigna è assente Sem Pressão Arterial - Nenaměřil jsi žádný krevní tlak + Nenaměřil si žádný krevní tlak You fail to find a blood pressure @@ -1527,7 +1532,7 @@ Nem sikerült a vérnyomás megmérése Manca strumento per misurare pressione sanguigna Você falhou em aferir a Pressão Arterial - Nedokázal jsi změřit krevní tlak + Nedokázal si změřit krevní tlak Low @@ -1587,7 +1592,7 @@ Pulzus Polso Pulso - Tep + Puls Checking Heart Rate... @@ -1611,7 +1616,7 @@ A %1 ellenőrizve Hai diagnosticato %1 Você aferiu o paciente %1 - Zkontroloval jsi %1 + Zkontroloval si %1 %1 checked Heart Rate: %2 @@ -1695,7 +1700,7 @@ A szívverés-szám alacsony Hai riscontrato un debole battito cardiaco Freqüência Cardíaca baixa - Nahmatal jsi slabý srdeční tep + Nahmatal si slabý srdeční puls You find a strong Heart Rate @@ -1707,7 +1712,7 @@ A szívverés-szám magas Hai riscontrato un forte battito cardiaco Freqüência Cardíaca normal - Nahmatal jsi silný srdeční tep + Nahmatal si silný srdeční puls You find a normal Heart Rate @@ -1719,7 +1724,7 @@ A szívverés-szám normális Hai riscontrato un normale battito cardiaco Freqüência Cardíaca alta - Nahmatal jsi normální srdeční tep + Nahmatal si normální srdeční puls You find no Heart Rate @@ -1731,7 +1736,7 @@ Nem észlelhető szívverés Hai riscontrato una assenza di battito cardiaco Sem Freqüência Cardíaca - Nenašel jsi + Žádný puls Response @@ -2172,7 +2177,7 @@ Gravemente herido Lourdement blessé Erősen sérült - Těžce zraněn + Těžce raněn Gravemente ferido @@ -2184,7 +2189,7 @@ Levemente herido Légèrement blessé Enyhén sérült - Lehce zraněn + Lehce raněn Levemente ferido @@ -2196,7 +2201,7 @@ Muy levemente herido Très légèrement blessé Nagyon enyhén sérült - Velmi lehce zraněn + Velmi lehce raněn Muito levemente ferido @@ -3205,6 +3210,7 @@ Ajustes médicos básicos [ACE] Réglages du système médical basic [ACE] Impostazioni Mediche Di Base [ACE] + Základní zdravotnické nastavení [ACE] Advanced Medical Settings [ACE] @@ -3321,6 +3327,7 @@ Ograniczenia adrenaliny Autoriser l'adrénaline Permette epinefrina + Povolit adrenalin Who can use Epinephrine for full heal? (Basic medical only) @@ -3329,6 +3336,7 @@ Kto może skorzystać z adrenaliny w celu pełnego uleczenia? (Tylko podstawowy system medyczny) Qui peut utiliser l'adrénaline pour les soins complets ? (Médical basique seulement) Chi può usare l'epinefrina per la cura completa? (solo per sistema medico di base) + Kdo může použít adrenalin k úplnému vyléčení? (Pouze základní zdravotní systém) Allow PAK @@ -3336,7 +3344,7 @@ Ustawienie apteczek osobistych Permitir EPA Erlaube Erste-Hilfe-Set - Povolit osobní lékárničky + Povolit osobní lékárničky (PAK) Permitir Kit de Primeiros Socorros Permettre le kit de premier secours Elsősegélycsomag engedélyezése @@ -3421,6 +3429,7 @@ Ograniczenia adrenaliny Position des adrénalines Ubicazione epinefrina + Oblast k použití adrenalinu Where can the Epinephrine be used? (Basic Medical) @@ -3429,6 +3438,7 @@ Gdzie można korzystać z adrenaliny? (Podstawowy system medyczny) Où peuvent être utilisées les adrénalines ? (Médical basique) Dove si può usare l'epinefrina? (Sistema medico di base) + Kde může být použit adrenalin? (Pouze základní zdravotní systém) Locations PAK @@ -3436,7 +3446,7 @@ Ograniczenie apteczek osobistych Ubicaciones del EPA Orte für Erste-Hilfe-Set - Lokace osobní lékárničky + Oblast k použití PAK Localizações do KPS Lieu d'utilisation du KPS Elsősegélycsomag helyek @@ -3448,7 +3458,7 @@ Gdzie można korzystać z apteczek osobistych? ¿Dónde se puede utilizar el equipo de primeros auxilios? Wo kann das Erste-Hilfe-Set verwendet werden? - Kde může být použita osobní lékárnička? + Kde může být použita osobní lékárnička (PAK)? Onde o kit de primeiros socorros pode ser utilizado? Où le Kit de Premier Secour peut être utilisé Hol lehet az elsősegélycsomagot használni? @@ -3457,7 +3467,7 @@ Condition PAK Bedingungen für d. Erste-Hilfe-Set - Podmínka osobní lékárničky + Podmínky pro použití osobní lékárničky Condición EPA Condition d'utilisation du KPS Warunek apteczek @@ -3469,7 +3479,7 @@ When can the PAK be used? Wann kann das Erste-Hilfe-Set verwendet werden? - Kde může být použita osobní lékárnička? + Kdy může být použita osobní lékárnička? ¿Cuando se puede utilizar el Equipo de primeros auxilios? Quand peut être utilisé le Kit de Premier Secours Po spełnieniu jakich warunków apteczka osobista może zostać zastosowana na pacjencie? @@ -3484,7 +3494,7 @@ Wszędzie Donde sea Überall - Kdekoli + Kdekoliv Qualquer lugar PArtout Akárhol @@ -4124,6 +4134,7 @@ Sanitätsausbildung Entrenamiento médico Entraînement médical + Lékařský výcvik Whether or not the object will be a medical vehicle. @@ -4137,6 +4148,7 @@ Delay cease fire of AI while player is unconscious for medical reasons. Verzögert das Ende des KI-Beschusses auf einen Spieler, wenn dieser aus medizinischen Gründen bewustlos wird. Ritarda il cessate il fuoco dell'IA quando il giocatore è svenuto per motivi medici. + Prodleva zastavení palby pro AI, pokud je hráč v bezvědomí ze zdravotních důvodů. Delay cease fire of AI for unconsciousness @@ -4144,6 +4156,7 @@ Demora antes de volverse neutral al caer inconsciente Opóźnij status captive u nieprzytomnych osób Ritarda il cessate il fuoco dell'IA quando si è svenuti + Prodleva zastavení palby AI na bezvědomé \ No newline at end of file diff --git a/addons/medical_menu/stringtable.xml b/addons/medical_menu/stringtable.xml index f825882be6..e9812128f4 100644 --- a/addons/medical_menu/stringtable.xml +++ b/addons/medical_menu/stringtable.xml @@ -295,7 +295,7 @@ Selectioner Bras Gauche Wybierz lewą rękę Selecionar Braço Esquerdo - Vybrat Levou Ruku + Vybrat Levou ruku Seleziona Braccio Sinistro @@ -306,7 +306,7 @@ Selectioner Bras Droit Wybierz prawą rękę Selecionar Braço Direito - Vybrat Pravou Ruku + Vybrat Pravou ruku Seleziona Braccio Destro @@ -317,7 +317,7 @@ Selectioner Jambe Gauche Wybierz lewą nogę Selecionar Perna Esquerda - Vybrat Levou Nohu + Vybrat Levou nohu Seleziona Gamba Sinistra @@ -328,7 +328,7 @@ Selectioner Jambe Droite Wybierz prawą nogę Selecionar Perna Direita - Vybrat Pravou Nohu + Vybrat Pravou nohu Seleziona Gamba Destra @@ -581,7 +581,7 @@ A Perdu Bcp de Sang Stracił dużo krwi Perdeu muito sangue - Ztratil hodně Krve + Ztratil hodně krve Perso molto Sangue diff --git a/addons/missileguidance/stringtable.xml b/addons/missileguidance/stringtable.xml index ff14fea9f7..35b947ce97 100644 --- a/addons/missileguidance/stringtable.xml +++ b/addons/missileguidance/stringtable.xml @@ -114,7 +114,7 @@ Tylko gracz Solo jugador Nur Spieler - Pouze hráči + Pouze hráč Somente jogador Seulement les joueurs Csak játékosok @@ -126,7 +126,7 @@ Gracz oraz AI Jugador e IA Spieler und KI - Hráči a AI + Hráč a AI Jogador e IA Joueurs et IA Játékosok és AI diff --git a/addons/mk6mortar/stringtable.xml b/addons/mk6mortar/stringtable.xml index f545bc8a35..1de69ece38 100644 --- a/addons/mk6mortar/stringtable.xml +++ b/addons/mk6mortar/stringtable.xml @@ -167,6 +167,7 @@ Wyładuj pocisk Enlever l'obus Togli proiettile + Odstranit náboj Load Mortar @@ -175,6 +176,7 @@ Załaduj moździerz Charger le mortier Carica mortaio + Nabít minomet Unloading Round @@ -191,6 +193,7 @@ Przygotowywanie pocisku Praparation de l'obus Prepara il proiettile + Připavuji náboj Load HE @@ -199,6 +202,7 @@ Załaduj pocisk wybuchowy Charger HE Carica proiettile esplosivo ad alto potenziale (HE) + Nabít HE Load Smoke @@ -207,6 +211,7 @@ Załaduj pocisk dymny Charger Fumigène Carica fumogeno + Nabít Dýmovnici Load Illumination @@ -215,6 +220,7 @@ Załaduj pocisk oświetlający Charger Eclairante Carica illuminante + Nabít Světlici Load Guided HE @@ -223,6 +229,7 @@ Załaduj kierowany pocisk wybuchowy Charger HE guidé Carica HE guidata + Nabít HE (Naváděné) Load Laser Guided HE @@ -231,6 +238,7 @@ Załaduj laserowo napr. pocisk wybuchowy Charger HE guidé au laser Carica HE a guida laser + Nabít HE (Naváděné laserem) 82mm HE Round @@ -239,6 +247,7 @@ Pocisk wybuchowy kal. 82mm Obus de 82mm HE Proiettile da 82mm HE + 82mm HE náboj 82mm Smoke Round @@ -247,6 +256,7 @@ Pocisk dymny kal. 82mm Obus de 82mm fumigène Proiettile Fumogeno da 82mm + 82mm Kouřový náboj 82mm Illumination Round @@ -255,6 +265,7 @@ Pocisk oświetlający kal. 82mm Obus de 82mm éclairant Proiettile illuminante da 82mm + 82mm Osvětlovací náboj 82mm Guided HE Round @@ -263,6 +274,7 @@ Kierowany pocisk wybuchowy kal. 82mm Obus de 82mm HE guidé Proiettile HE guidato + 82mm HE náboj (naváděný) 82mm Laser Guided HE Round @@ -271,6 +283,7 @@ Laserowo napr. pocisk wybuchowy kal. 82mm Obus de 82mm HE guidé au laser Proiettile HE a guida laser + 82mm HE náboj (naváděný laserem) Used in Mk6 mortar @@ -279,6 +292,7 @@ Używany w moździerzu Mk6 Utilisé dans le mortier Mk6 Usato nel mortaio Mk6 + Používá se u minometu Mk6 [ACE] 82mm HE Rounds Box @@ -287,6 +301,7 @@ [ACE] Skrzynka amunicji wybuchowej 82mm [ACE] Obus de 82mm HE [ACE] Scatola proiettili espolisvi ad alto potenziale (HE) da 82mm + [ACE] Bedna s municí (82mm HE) [ACE] 82mm Smoke Rounds Box @@ -295,6 +310,7 @@ [ACE] Skrzynka amunicji dymnej 82mm [ACE] Obus de 82mm fumigène [ACE] Scatola fumogeni da 82mm + [ACE] Bedna s municí (82mm Dýmovnice) [ACE] 82mm Illumination Rounds Box @@ -303,6 +319,7 @@ [ACE] Skrzynka amunicji oświetlającej 82mm [ACE] Obus de 82mm éclairants [ACE] Scatola illuminanti da 82mm + [ACE] Bedna s municí (82mm Světlice) [ACE] 82mm Default Loadout Box @@ -311,6 +328,7 @@ [ACE] Skrzynka amunicji standardowej 82mm [ACE] Obus de 82mm par défaut [ACE] Scatola proiettili 82mm standard + [ACE] Bedna se standardní 82mm municí \ No newline at end of file diff --git a/addons/overheating/stringtable.xml b/addons/overheating/stringtable.xml index 3269d9cf7e..abbf9533e7 100644 --- a/addons/overheating/stringtable.xml +++ b/addons/overheating/stringtable.xml @@ -32,6 +32,7 @@ Effetti Particelle Surriscaldamento Efectos de partículas Effet de surchauffe + Částicové efekty přehřívání Show particle effects when weapon overheats @@ -48,6 +49,7 @@ Effetti Particellari Surriscaldamento per tutti Efectos de partículas para todos Effets de surchauffe pour tout le monde. + Částicové efekty přehřívání pro všechny Show particle effects when other players weapon overheats @@ -80,6 +82,7 @@ Usuń zacięcie przy przeładowaniu Des-enrayer l'arme au rechargement. Disinceppa l'arma quando si ricarica + Uvolnit zbraň při přebití Reloading clears a weapon jam. @@ -88,6 +91,7 @@ Przeładowywanie usuwa zacięcie Recharger vide la chambre de l'arme L'arma si disinceppa quando si ricarica + Přebití uvolní zaseknutou zbraň. Chance of unjam failing @@ -96,6 +100,7 @@ Szansa na porażkę usuw. zacięcia Chance de rater le des-enrayement Probabilità di sbagliare a disinceppare l'arma + Šance, že uvolnění zbraně selže Probability that an unjam action might fail, requiring to be repeated. @@ -172,6 +177,7 @@ Porażka przy usuwaniu zacięcia Toujours enrayé ! Non si è disinceppata! + Zbrań se nepodařilo uvolnit Swap barrel @@ -190,7 +196,7 @@ Lauf wird gewechselt... Cambiando el cañón... Wymienianie lufy... - Vyměňuji hlaveň... + Měním hlaveň... Changement du canon... Смена ствола... Cső kicserélése folyamatban... @@ -216,7 +222,7 @@ Sprawdź temperaturę broni Vérifier la température de l'arme Fegyver hőmérsékletének ellenőrzése - Zjistit teplotu zbraně + Zkontrolovat teplotu zbraně Conferir temperatura da arma Controlla la temperatura della canna Проверить температуру оружия diff --git a/addons/repair/stringtable.xml b/addons/repair/stringtable.xml index ee79a1d427..0bce5cd685 100644 --- a/addons/repair/stringtable.xml +++ b/addons/repair/stringtable.xml @@ -1320,6 +1320,7 @@ Engine must be off to repair Motor muss ausgeschaltet zu reparieren sein El motor necesita desactivado para la reparación + Pro opravu je zapotřebí vypnout motor - + \ No newline at end of file diff --git a/addons/spectator/stringtable.xml b/addons/spectator/stringtable.xml index b78febbef7..bdb88a2675 100644 --- a/addons/spectator/stringtable.xml +++ b/addons/spectator/stringtable.xml @@ -321,7 +321,7 @@ Noc Visão Norturna Ночное - Noc + Noční Nocturna Notturno Nuit @@ -332,7 +332,7 @@ Termo Térmica Тепловизор - Termál + Termální Térmica Termico Thermique @@ -689,4 +689,4 @@ RAZ vitesse - + \ No newline at end of file diff --git a/addons/tagging/stringtable.xml b/addons/tagging/stringtable.xml index 1849206963..bf4056df49 100644 --- a/addons/tagging/stringtable.xml +++ b/addons/tagging/stringtable.xml @@ -8,6 +8,7 @@ Oznakuj na czarno Tag noir Marca nero + Označit černě Tag red @@ -16,6 +17,7 @@ Oznakuj na czerwono Tag rouge Marca rosso + Označit červeně Tag green @@ -24,6 +26,7 @@ Oznakuj na zielono Tag vert Marca verde + Označit zeleně Tag blue @@ -32,6 +35,7 @@ Oznakuj na niebiesko Tag bleu Marca blu + Označit modře Black spray paint @@ -40,6 +44,7 @@ Czarna farba w sprayu Peinture pulvérisée noire Bomboletta spray nera + Černý sprej Red spray paint @@ -48,6 +53,7 @@ Czerwona farba w sprayu Peinture pulvérisée rouge Bomboletta spray rossa + Červený sprej Green spray paint @@ -56,6 +62,7 @@ Zielona farba w sprayu Peinture pulvérisée verte Bomboletta spray verde + Zelený sprej Blue spray paint @@ -64,6 +71,7 @@ Niebieska farba w sprayu Peinture pulvérisée bleue Bomboletta spray blu + Modrý sprej A can of spray paint for tagging walls. @@ -72,6 +80,7 @@ Farba w sprayu, służy do oznakowywania terenu. Un spray de peinture pour taguer les murs. Una bomboletta di spay per contrassegnare i muri. + Plechovka se sprejem k vytváření značek. - + \ No newline at end of file diff --git a/addons/trenches/stringtable.xml b/addons/trenches/stringtable.xml index 617a604457..440b3537ba 100644 --- a/addons/trenches/stringtable.xml +++ b/addons/trenches/stringtable.xml @@ -8,6 +8,7 @@ Pala Pala para trincheras Outil de tranchée + Polní lopatka Entrenching Tool @@ -16,6 +17,7 @@ Pala Pala para trincheras Outil de tranchée + Polní lopatky se používají k zákopovým a jiným pracem. Envelope - Small @@ -32,6 +34,7 @@ Piccola Trincea Personale Trinchera personal pequeña Petite tranchée personelle + Malý zákop pro jednoho Dig Small Trench @@ -40,6 +43,7 @@ Scava Trincea Piccola Cavar trinchera pequeña Creuser une petite tranchée + Vykopat malý zákop Envelope - Big @@ -56,6 +60,7 @@ Grande Trincea Personale Trinchera personal grande Grande tranchée personelle + Velký zákop pro jednoho Dig Big Trench @@ -64,6 +69,7 @@ Scava Trincea Grande Cavar trinchera grande Creuser une grande tranchée + Vykopat velký zákop Confirm Dig @@ -72,6 +78,7 @@ Conferma Scava Confirmar cavado Confirmer la creusée + Potvrdit kopání Cancel Dig @@ -80,6 +87,7 @@ Cancella Scava Cancelar cavado Annuler la creusée + Zrušit kopání Rotate @@ -100,6 +108,7 @@ Sto Scavando la Trincea Cavando trinchera Creuse la tranchée + Vykopat zákop - + \ No newline at end of file diff --git a/addons/ui/stringtable.xml b/addons/ui/stringtable.xml index 42e7932411..74cd89e93b 100644 --- a/addons/ui/stringtable.xml +++ b/addons/ui/stringtable.xml @@ -1,101 +1,131 @@ - + User Interface + Uživatelské rozhraní User Interface + Uživatelské rozhraní This module allows toggling visible user interface parts. Allow Selective UI + Povolit selektivní UI Allow client to modify their UI. + Povolit klientovi měnit jeho UI Soldier/Vehicle/Weapon Information + Informace o Vojákovi/Vozidlu/Zbrani Vehicle Radar + Radar vozidla Vehicle Compass + Kompas vozidla Command Menu + Menu rozkazů Group Bar + Panel skupiny Weapon Name + Název zbraně Weapon Name Background + Název zbraně v pozadí Firing Mode + Režim palby Ammo Type + Typ munice Ammo Count + Počet munice Magazine Count + Počet zásobníků Throwable Type + Typ granátů apod. Throwable Count + Počet granátů apod. Zeroing + Náměr Weapon Lower Info Background Stance + Postoj Stamina Bar + Panel výdrže Vehicle Name + Název vozidla Vehicle Name Background + Název vozidla v pozadí Vehicle Fuel Bar + Ukazatel paliva Vehicle Speed + Rychlost vozidla Vehicle Altitude + Výška vozidla Vehicle Damage + Poškození vozidla Vehicle Info Background + Info o vozidle v pozadí Vehicle Gunner Weapon + Střelcova zbraň ve vozidle Requires Soldier/Vehicle/Weapons Information. + Vyžaduje informace o Vojákovi/Vozidlu/Zbrani Modifying User Interface is disabled. + Změna uživatelského rozhraní je zakázána. - + \ No newline at end of file From 7cc2da2bb132c2d44f00aedc8d24a747be451362 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 29 Apr 2016 23:38:01 -0500 Subject: [PATCH 144/215] Fix self swap action --- addons/overheating/CfgVehicles.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index 528f77375c..0a86535231 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -16,7 +16,7 @@ class CfgVehicles { class GVAR(SwapBarrel) { displayName = CSTRING(SwapBarrel); condition = QUOTE( 'ACE_SpareBarrel' in magazines _player && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _player >> 'ACE_Overheating_allowSwapBarrel') == 1} ); - statement = QUOTE( [ARR_2(_player, currentWeapon _player)] call FUNC(swapBarrel); ); + statement = QUOTE( [ARR_3(_player, _player, currentWeapon _player)] call FUNC(swapBarrel); ); showDisabled = 0; priority = 3; icon = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); From 33b624c89609c4d9d7219548c3637bde2ef826f3 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Mon, 2 May 2016 12:10:44 -0500 Subject: [PATCH 145/215] Tactical Ladder - Update model cfg #3745 --- addons/tacticalladder/data/model.cfg | 152 ++++++++++++--------------- 1 file changed, 66 insertions(+), 86 deletions(-) diff --git a/addons/tacticalladder/data/model.cfg b/addons/tacticalladder/data/model.cfg index ba19d58c65..bc7da07960 100644 --- a/addons/tacticalladder/data/model.cfg +++ b/addons/tacticalladder/data/model.cfg @@ -35,76 +35,51 @@ class CfgSkeletons { "Camera","Pelvis", "weapon","Spine1", "launcher","Spine1", - //Head skeleton in hierarchy + + // Head skeleton in hierarchy "neck","Spine3", - "neck1","neck", - "head","neck1", - "HeadCutScene","head", - "jaw","head", - "chin","head", - "jaw_rf","head", - "jaw_rm","head", - "jaw_rs","head", - "jaw_lf","head", - "jaw_lm","head", - "jaw_ls","head", - "ear_r","head", - "ear_l","head", - "lip_lc","head", - "lip_lwlb","head", - "lip_lwlf","head", - "lip_lwm","head", - "lip_lwrf","head", - "lip_lwrb","head", - "lip_rc","head", - "lip_uprb","head", - "lip_uprf","head", - "lip_upm","head", - "lip_uplf","head", - "lip_uplb","head", - "nose_tip","head", - "nose_r","head", - "nose_l","head", - "zig_lt","head", - "zig_lm","head", - "zig_lb","head", - "zig_rt","head", - "zig_rm","head", - "zig_rb","head", - "cheek_r","head", - "cheek_l","head", - "eyebrow_lb","head", - "eyebrow_lm","head", - "eyebrow_lf","head", - "corr","head", - "eyebrow_rf","head", - "eyebrow_rm","head", - "eyebrow_rb","head", - "eye_upr","head", - "eye_lwr","head", - "eye_upl","head", - "eye_lwl","head", - "cheek_rf","head", - "cheek_rm","head", - "cheek_rb","head", - "cheek_lf","head", - "cheek_lm","head", - "cheek_lb","head", - "forehead_l","head", - "forehead_m","head", - "forehead_r","head", - "l_eye","head", - "r_eye","head", - "l_pupila","head", - "r_pupila","head", - "neck_t","head", - "neck_b","head", - "neck_r","head", - "neck_l","head", - "tongue_b","head", - "tongue_m","head", - "tongue_f","head", - //Left upper side + "neck1","neck", + "head","neck1", + + // New facial features + "Face_Hub","head", + "Face_Jawbone","Face_Hub", + "Face_Jowl","Face_Jawbone", + "Face_chopRight","Face_Jawbone", + "Face_chopLeft","Face_Jawbone", + "Face_LipLowerMiddle","Face_Jawbone", + "Face_LipLowerLeft","Face_Jawbone", + "Face_LipLowerRight","Face_Jawbone", + "Face_Chin","Face_Jawbone", + "Face_Tongue","Face_Jawbone", + "Face_CornerRight","Face_Hub", + "Face_CheekSideRight","Face_CornerRight", + "Face_CornerLeft","Face_Hub", + "Face_CheekSideLeft","Face_CornerLeft", + "Face_CheekFrontRight","Face_Hub", + "Face_CheekFrontLeft","Face_Hub", + "Face_CheekUpperRight","Face_Hub", + "Face_CheekUpperLeft","Face_Hub", + "Face_LipUpperMiddle","Face_Hub", + "Face_LipUpperRight","Face_Hub", + "Face_LipUpperLeft","Face_Hub", + "Face_NostrilRight","Face_Hub", + "Face_NostrilLeft","Face_Hub", + "Face_Forehead","Face_Hub", + "Face_BrowFrontRight","Face_Forehead", + "Face_BrowFrontLeft","Face_Forehead", + "Face_BrowMiddle","Face_Forehead", + "Face_BrowSideRight","Face_Forehead", + "Face_BrowSideLeft","Face_Forehead", + "Face_Eyelids","Face_Hub", + "Face_EyelidUpperRight","Face_Hub", + "Face_EyelidUpperLeft","Face_Hub", + "Face_EyelidLowerRight","Face_Hub", + "Face_EyelidLowerLeft","Face_Hub", + "EyeLeft","Face_Hub", + "EyeRight","Face_Hub", + + // Left upper side "LeftShoulder","Spine3", "LeftArm","LeftShoulder", "LeftArmRoll","LeftArm", @@ -127,7 +102,8 @@ class CfgSkeletons { "LeftHandThumb1","LeftHand", "LeftHandThumb2","LeftHandThumb1", "LeftHandThumb3","LeftHandThumb2", - //Right upper side + + // Right upper side "RightShoulder","Spine3", "RightArm","RightShoulder", "RightArmRoll","RightArm", @@ -150,25 +126,26 @@ class CfgSkeletons { "RightHandThumb1","RightHand", "RightHandThumb2","RightHandThumb1", "RightHandThumb3","RightHandThumb2", - //Left lower side + + // Left lower side "LeftUpLeg","Pelvis", "LeftUpLegRoll","LeftUpLeg", "LeftLeg","LeftUpLegRoll", "LeftLegRoll","LeftLeg", "LeftFoot","LeftLegRoll", "LeftToeBase","LeftFoot", - //Right lower side + + // Right lower side "RightUpLeg","Pelvis", "RightUpLegRoll","RightUpLeg", "RightLeg","RightUpLegRoll", "RightLegRoll","RightLeg", "RightFoot","RightLegRoll", "RightToeBase","RightFoot" - }; - // location of pivot points (local axes) for hierarchical animation - //pivotsModel="ca\Anims\Characters\Data\Skeleton\SkeletonPivots.p3d"; - pivotsModel=""; - }; + }; + // location of pivot points (local axes) for hierarchical animation + pivotsModel="A3\anims_f\data\skeleton\SkeletonPivots.p3d"; + }; }; class CfgModels { @@ -249,13 +226,14 @@ class CfgModels { }; }; class ArmaMan: Default { - htMin=60; - htMax=1800; - afMax=30; - mfMax=0; - mFact=1; - tBody=37; - sections[]= { + htMin = 60; // Minimum half-cooling time (in seconds) + htMax = 1800; // Maximum half-cooling time (in seconds) + afMax = 30; // Maximum temperature in case the model is alive (in celsius) + mfMax = 0; // Maximum temperature when the model is moving (in celsius) + mFact = 1; // Metabolism factor - number from interval <0, 1> (0 - metabolism has no influence, 1 - metabolism has full influence (no other temperature source will be considered)). + tBody = 37; // Metabolism temperature of the model (in celsius) + + sections[] = { "osobnost", "Head_Injury", "Body_Injury", @@ -274,9 +252,11 @@ class CfgModels { "Camo2", "personality", "hl", - "injury_head" + "injury_head", + "insignia", + "ghillie_hide" }; - skeletonName="OFP2_ManSkeleton"; + skeletonName = "OFP2_ManSkeleton"; }; class ace_tacticalladder_pack: ArmaMan { }; From 7fcbe93b71f4c3182125d8f77a0ad8cdcdc240ea Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Tue, 3 May 2016 02:32:44 +0200 Subject: [PATCH 146/215] Cleaned up excessive whitespace --- addons/aircraft/CfgAmmo.hpp | 2 +- addons/aircraft/Heli_Attack_01_base_F.hpp | 10 +- addons/atragmx/RscTitles.hpp | 14 +- addons/atragmx/XEH_postInit.sqf | 22 +-- .../functions/fnc_calculate_solution.sqf | 35 +--- addons/atragmx/functions/fnc_change_gun.sqf | 5 +- .../atragmx/functions/fnc_create_dialog.sqf | 2 +- .../atragmx/functions/fnc_show_gun_list.sqf | 1 - .../functions/fnc_show_range_card_setup.sqf | 2 +- .../fnc_show_target_range_assist.sqf | 3 +- .../fnc_show_target_speed_assist.sqf | 4 +- addons/atragmx/functions/fnc_sord.sqf | 5 +- .../fnc_target_speed_assist_timer.sqf | 12 +- .../functions/fnc_toggle_atmo_env_data.sqf | 2 +- .../functions/fnc_toggle_gun_ammo_data.sqf | 2 +- .../atragmx/functions/fnc_toggle_gun_list.sqf | 2 +- .../functions/fnc_toggle_range_card.sqf | 4 +- .../functions/fnc_toggle_range_card_setup.sqf | 4 +- .../functions/fnc_toggle_solution_setup.sqf | 6 +- .../functions/fnc_toggle_target_data.sqf | 2 +- .../fnc_toggle_target_range_assist.sqf | 2 +- .../fnc_toggle_target_speed_assist.sqf | 2 +- .../functions/fnc_update_range_card.sqf | 14 +- .../atragmx/functions/fnc_update_result.sqf | 22 +-- addons/ballistics/CfgMagazines.hpp | 30 +-- addons/ballistics/CfgWeapons.hpp | 38 ++-- .../functions/fnc_doEscortCaptive.sqf | 2 +- addons/common/RscInfoType.hpp | 2 +- .../functions/fnc_dumpPerformanceCounters.sqf | 8 +- addons/dagr/initKeybinds.sqf | 2 +- addons/dragging/CfgVehicles.hpp | 4 +- .../explosives/functions/fnc_setSpeedDial.sqf | 3 +- addons/fastroping/$PBOPREFIX$ | 2 +- addons/finger/XEH_postInit.sqf | 2 +- addons/frag/CfgAmmo.hpp | 38 ++-- addons/frag/functions/fnc_doReflections.sqf | 4 - addons/frag/functions/fnc_drawTraces.sqf | 5 +- addons/gestures/functions/fnc_playSignal.sqf | 2 +- addons/goggles/RscTitles.hpp | 14 +- addons/huntir/CfgAmmo.hpp | 2 +- addons/huntir/CfgWeapons.hpp | 6 +- addons/interaction/CfgVehicles.hpp | 2 +- .../functions/fnc_inventoryDisplayLoad.sqf | 2 +- addons/javelin/CfgMagazines.hpp | 2 +- addons/javelin/CfgVehicles.hpp | 12 +- addons/javelin/CfgWeapons.hpp | 32 ++-- addons/javelin/RscInGameUI.hpp | 22 +-- addons/kestrel4500/initKeybinds.sqf | 6 +- addons/laser/CfgVehicles.hpp | 10 +- addons/laser/CfgWeapons.hpp | 1 - addons/laser/RscInGameUI.hpp | 9 +- addons/laser/functions/fnc_laserOff.sqf | 2 +- addons/laser/functions/fnc_laserTargetPFH.sqf | 3 +- .../functions/fnc_seekerFindLaserSpot.sqf | 2 +- addons/main/CfgSettings.hpp | 2 +- addons/map/CfgAmmo.hpp | 20 +- addons/map/XEH_postInitClient.sqf | 2 +- .../functions/fnc_compileFlashlightMenu.sqf | 2 +- .../functions/fnc_calculateMapScale.sqf | 2 +- .../functions/fnc_initInsertMarker.sqf | 2 +- .../functions/fnc_translateSelections.sqf | 2 +- .../microdagr/functions/fnc_updateDisplay.sqf | 4 +- addons/missileguidance/ACE_GuidanceConfig.hpp | 16 +- addons/missileguidance/CfgMagazines.hpp | 12 +- addons/missileguidance/CfgVehicles.hpp | 4 +- .../functions/fnc_doAttackProfile.sqf | 4 +- .../functions/fnc_doSeekerSearch.sqf | 4 +- .../missileguidance/functions/fnc_onFired.sqf | 32 ++-- addons/modules/XEH_postInit.sqf | 8 +- addons/nametags/functions/fnc_doShow.sqf | 12 +- addons/nightvision/XEH_postInitClient.sqf | 8 +- .../functions/fnc_getDistance.sqf | 2 +- addons/rangecard/RscTitles.hpp | 2 +- .../functions/fnc_calculateSolution.sqf | 41 +--- .../rangecard/functions/fnc_openRangeCard.sqf | 8 +- .../functions/fnc_updateRangeCard.sqf | 12 +- addons/realisticnames/CfgVehicles.hpp | 6 +- addons/repair/ACE_Repair.hpp | 2 +- addons/sandbag/CfgWeapons.hpp | 4 +- addons/scopes/CfgWeapons.hpp | 8 +- addons/scopes/functions/fnc_adjustScope.sqf | 2 +- addons/sitting/XEH_clientInit.sqf | 2 +- addons/spottingscope/CfgWeapons.hpp | 4 +- .../switchunits/functions/fnc_markAiOnMap.sqf | 2 +- addons/tripod/CfgWeapons.hpp | 4 +- addons/weaponselect/XEH_preInit.sqf | 4 +- addons/weather/functions/fnc_getMapData.sqf | 175 ++++++++++-------- addons/weather/functions/fnc_initWind.sqf | 2 +- .../weather/functions/fnc_updateHumidity.sqf | 2 +- addons/weather/functions/fnc_updateRain.sqf | 2 +- .../functions/fnc_acquireTarget.sqf | 10 +- addons/yardage450/functions/fnc_turnOn.sqf | 6 +- addons/yardage450/initKeybinds.sqf | 4 +- addons/zeus/CfgVehicles.hpp | 2 +- 94 files changed, 418 insertions(+), 472 deletions(-) diff --git a/addons/aircraft/CfgAmmo.hpp b/addons/aircraft/CfgAmmo.hpp index 8aa5d3173e..2c3701b8e0 100644 --- a/addons/aircraft/CfgAmmo.hpp +++ b/addons/aircraft/CfgAmmo.hpp @@ -11,7 +11,7 @@ class CfgAmmo { explosive = 1.8; tracersEvery = 3; tracerEndTime = 3.5; - + CraterEffects = "ExploAmmoCrater"; explosionEffects = "ExploAmmoExplosion"; model = "\A3\Weapons_f\Data\bullettracer\tracer_red"; diff --git a/addons/aircraft/Heli_Attack_01_base_F.hpp b/addons/aircraft/Heli_Attack_01_base_F.hpp index 26a4605910..a6868033e6 100644 --- a/addons/aircraft/Heli_Attack_01_base_F.hpp +++ b/addons/aircraft/Heli_Attack_01_base_F.hpp @@ -860,12 +860,12 @@ class Heli_Attack_01_base_F: Helicopter_Base_F { helmetDown[] = {0,-0.07,0}; }; }; - + class Turrets: Turrets { class MainTurret: MainTurret { weapons[] = {"ACE_gatling_20mm_Comanche","missiles_DAGR","missiles_ASRAAM", "ACE_AIR_SAFETY"}; magazines[] = {"ACE_500Rnd_20mm_shells_Comanche","4Rnd_AAA_missiles","24Rnd_PG_missiles"}; - + outGunnerMayFire = 1; commanding = -1; primaryGunner = 1; @@ -888,13 +888,13 @@ class Heli_Attack_01_base_F: Helicopter_Base_F { minTurn = -120; maxTurn = 120; initTurn = 0; - + class OpticsIn { delete Narrow; delete Medium; delete Wide; - + class ACE_WideUnstabilized { opticsDisplayName = "W NS"; initAngleX = 0; @@ -994,4 +994,4 @@ class Heli_Attack_01_base_F: Helicopter_Base_F { weapon = "ACE_gatling_20mm_Comanche"; }; }; -}; \ No newline at end of file +}; diff --git a/addons/atragmx/RscTitles.hpp b/addons/atragmx/RscTitles.hpp index 97dad6e7b6..625cd68deb 100644 --- a/addons/atragmx/RscTitles.hpp +++ b/addons/atragmx/RscTitles.hpp @@ -230,7 +230,7 @@ class ATragMX_Display { idc=-1; x=0.55*safezoneW+safezoneX+0.315; }; - + class TEXT_GUN_FRAME: ATragMX_RscText { idc=1001; style=64; @@ -610,7 +610,7 @@ class ATragMX_Display { x=0.550*safezoneW+safezoneX+0.27; text="4"; action=QUOTE(call FUNC(toggle_solution_setup)); - }; + }; class TEXT_CALCULATE: TEXT_SCOPE_UNIT { idc=3000; style=ST_RIGHT; @@ -1059,7 +1059,7 @@ class ATragMX_Display { text="Cancel"; action=QUOTE(false call FUNC(show_add_new_gun); true call FUNC(show_gun_list)); }; - + class TEXT_GUN_AMMO_DATA_BORE_HEIGHT: TEXT_BORE_HEIGHT { idc=12000; w=0.22; @@ -1147,7 +1147,7 @@ class ATragMX_Display { class TEXT_GUN_AMMO_DATA_NEXT: TEXT_TARGET_SPEED_ASSIST_NEXT { idc=12011; }; - + class TEXT_ATMO_ENV_DATA_DEFAULT: TEXT_LEAD { idc=13000; w=0.08; @@ -1231,7 +1231,7 @@ class ATragMX_Display { y=0.265*safezoneH+safezoneY+0.29; text="Calc Method"; }; - + class TEXT_TARGET_DATA_LATITUDE: TEXT_BORE_HEIGHT { idc=14000; w=0.22; @@ -1379,7 +1379,7 @@ class ATragMX_Display { class TEXT_TARGET_DATA_NEXT: TEXT_TARGET_SPEED_ASSIST_NEXT { idc=14011; }; - + class TEXT_SOLUTION_SETUP_SHOW_RESULT_IN: TEXT_GUN_AMMO_DATA_BORE_HEIGHT { idc=15000; style=64; @@ -1469,4 +1469,4 @@ class ATragMX_Display { action=QUOTE(0 call FUNC(toggle_solution_setup)); }; }; -}; \ No newline at end of file +}; diff --git a/addons/atragmx/XEH_postInit.sqf b/addons/atragmx/XEH_postInit.sqf index 4b61a28551..8d4907523b 100644 --- a/addons/atragmx/XEH_postInit.sqf +++ b/addons/atragmx/XEH_postInit.sqf @@ -7,41 +7,41 @@ if ((profileNamespace getVariable ["ACE_ATragMX_profileNamespaceVersion", 0]) == } else { // Profile Name, Muzzle Velocity, Zero Range, Scope Base Angle, AirFriction, Bore Height, Scope Unit, Scope Click Unit, Scope Click Number, Maximum Elevation, Dialed Elevation, Dialed Windage, Mass, Bullet Diameter, Rifle Twist, BC, Drag Model, Atmosphere Model GVAR(gunList) = [["12.7x108mm" , 820, 100, 0.0657485, -0.00063800, 3.81, 0, 2, 10, 120, 0, 0, 48.28, 12.7, 38.10, 0.630, 1, "ASM" ], - + ["12.7x99mm AMAX" , 860, 100, 0.0611565, -0.00036645, 3.81, 0, 2, 10, 120, 0, 0, 48.60, 12.7, 38.10, 1.050, 1, "ASM" ], ["12.7x99mm" , 900, 100, 0.0582418, -0.00057503, 3.81, 0, 2, 10, 120, 0, 0, 41.92, 12.7, 38.10, 0.670, 1, "ASM" ], - + ["12.7x54mm" , 300, 100, 0.3394630, -0.00019268, 3.81, 0, 2, 10, 120, 0, 0, 48.60, 12.7, 24.13, 1.050, 1, "ASM" ], - + [".408 Chey Tac" , 910, 100, 0.0569400, -0.00038944, 3.81, 0, 2, 10, 120, 0, 0, 27.15, 10.4, 33.02, 0.970, 1, "ASM" ], - + ["9.3×64mm" , 870, 100, 0.0619295, -0.00108571, 3.81, 0, 2, 10, 120, 0, 0, 14.90, 9.30, 35.56, 0.368, 1, "ASM" ], - + [".338LM 250gr" , 880, 100, 0.0598469, -0.00059133, 3.81, 0, 2, 10, 120, 0, 0, 16.20, 8.58, 25.40, 0.322, 7, "ICAO"], [".338LM 300gr" , 800, 100, 0.0677343, -0.00052190, 3.81, 0, 2, 10, 120, 0, 0, 19.44, 8.58, 25.40, 0.381, 7, "ICAO"], [".338LM API526" , 895, 100, 0.0588865, -0.00069611, 3.81, 0, 2, 10, 120, 0, 0, 16.39, 8.58, 25.40, 0.560, 1, "ASM" ], - + [".300WM Mk248 Mod 0", 900, 100, 0.0584442, -0.00070530, 3.81, 0, 2, 10, 120, 0, 0, 13.31, 7.80, 25.40, 0.268, 7, "ICAO"], [".300WM Mk248 Mod 1", 867, 100, 0.0610738, -0.00061188, 3.81, 0, 2, 10, 120, 0, 0, 14.26, 7.80, 25.40, 0.310, 7, "ICAO"], [".300WM Berger OTM" , 853, 100, 0.0622179, -0.00053733, 3.81, 0, 2, 10, 120, 0, 0, 14.90, 7.80, 25.40, 0.368, 7, "ICAO"], - + ["7.62x54mmR" , 800, 100, 0.0691878, -0.00100023, 3.81, 0, 2, 10, 120, 0, 0, 9.849, 7.92, 24.13, 0.400, 1, "ICAO"], - + ["7.62x51mm M80" , 810, 100, 0.0679374, -0.00100957, 3.81, 0, 2, 10, 120, 0, 0, 9.525, 7.82, 25.40, 0.200, 7, "ICAO"], ["7.62x51mm M118LR" , 780, 100, 0.0710319, -0.00082828, 3.81, 0, 2, 10, 120, 0, 0, 11.34, 7.82, 25.40, 0.243, 7, "ICAO"], ["7.62x51mm Mk319" , 910, 100, 0.0584524, -0.00102338, 3.81, 0, 2, 10, 120, 0, 0, 8.424, 7.82, 25.40, 0.377, 1, "ICAO"], ["7.62x51mm M993" , 930, 100, 0.0570316, -0.00107148, 3.81, 0, 2, 10, 120, 0, 0, 8.230, 7.82, 25.40, 0.359, 1, "ICAO"], ["7.62x51mm Subsonic", 320, 100, 0.3059680, -0.00049899, 3.81, 0, 2, 10, 120, 0, 0, 12.96, 7.82, 25.40, 0.235, 7, "ICAO"], - + ["6.5x39mm" , 800, 100, 0.0683482, -0.00075308, 3.81, 0, 2, 10, 120, 0, 0, 7.970, 6.71, 22.86, 0.263, 7, "ICAO"], ["6.5x47mm Lapua" , 800, 100, 0.0682221, -0.00067037, 3.81, 0, 2, 10, 120, 0, 0, 9.007, 6.71, 22.86, 0.290, 7, "ICAO"], ["6.5mm Creedmor" , 840, 100, 0.0636501, -0.00060887, 3.81, 0, 2, 10, 120, 0, 0, 9.072, 6.71, 22.86, 0.317, 7, "ICAO"], - + ["5.56x45mm M855" , 870, 100, 0.0626386, -0.00126466, 3.81, 0, 2, 10, 120, 0, 0, 4.018, 5.70, 17.78, 0.151, 7, "ASM" ], ["5.56x45mm Mk262" , 820, 100, 0.0671481, -0.00109563, 3.81, 0, 2, 10, 120, 0, 0, 4.990, 5.70, 17.78, 0.361, 1, "ASM" ], ["5.56x45mm Mk318" , 880, 100, 0.0615937, -0.00123318, 3.81, 0, 2, 10, 120, 0, 0, 4.018, 5.70, 17.78, 0.307, 1, "ASM" ], ["5.56x45mm M995" , 869, 100, 0.0626713, -0.00123272, 3.81, 0, 2, 10, 120, 0, 0, 4.536, 5.70, 17.78, 0.310, 1, "ASM" ]]; - + [] call FUNC(clear_user_data); profileNamespace setVariable ["ACE_ATragMX_gunList", GVAR(gunList)]; }; diff --git a/addons/atragmx/functions/fnc_calculate_solution.sqf b/addons/atragmx/functions/fnc_calculate_solution.sqf index 869ce8d098..839cba8b69 100644 --- a/addons/atragmx/functions/fnc_calculate_solution.sqf +++ b/addons/atragmx/functions/fnc_calculate_solution.sqf @@ -42,31 +42,8 @@ * Public: No */ #include "script_component.hpp" - -private ["_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed1", "_windSpeed2", "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_drag", "_bc", "_dragModel", "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", "_directionOfFire"]; -_scopeBaseAngle = _this select 0; -_bulletMass = _this select 1; -_boreHeight = _this select 2; -_airFriction = _this select 3; -_muzzleVelocity = _this select 4; -_temperature = _this select 5; -_barometricPressure = _this select 6; -_relativeHumidity = _this select 7; -_simSteps = _this select 8; -_windSpeed1 = (_this select 9) select 0; -_windSpeed2 = (_this select 9) select 1; -_windDirection = _this select 10; -_inclinationAngle = _this select 11; -_targetSpeed = _this select 12; -_targetRange = _this select 13; -_bc = _this select 14; -_dragModel = _this select 15; -_atmosphereModel = _this select 16; -_storeRangeCardData = _this select 17; -_stabilityFactor = _this select 18; -_twistDirection = _this select 19; -_latitude = _this select 20; -_directionOfFire = _this select 21; +params ["_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed", "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_bc", "_dragModel", "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", "_directionOfFire"]; +_windSpeed params ["_windSpeed1", "_windSpeed2"]; private ["_bulletPos", "_bulletVelocity", "_bulletAccel", "_bulletSpeed", "_gravity", "_deltaT"]; _bulletPos = [0, 0, 0]; @@ -133,7 +110,7 @@ _bulletVelocity set [2, Sin(_scopeBaseAngle) * _muzzleVelocity]; while {_TOF < 15 && (_bulletPos select 1) < _targetRange} do { _bulletSpeed = vectorMagnitude _bulletVelocity; - + _speedTotal = _speedTotal + _bulletSpeed; _stepsTotal = _stepsTotal + 1; _speedAverage = (_speedTotal / _stepsTotal); @@ -142,7 +119,7 @@ while {_TOF < 15 && (_bulletPos select 1) < _targetRange} do { _trueSpeed = vectorMagnitude _trueVelocity; if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then { - _drag = if (missionNamespace getVariable [QEGVAR(advanced_ballistics,extensionAvailable), false]) then { + private _drag = if (missionNamespace getVariable [QEGVAR(advanced_ballistics,extensionAvailable), false]) then { parseNumber(("ace_advanced_ballistics" callExtension format["retard:%1:%2:%3", _dragModel, _bc, _trueSpeed])) } else { ([_dragModel, _bc, _trueSpeed] call EFUNC(advanced_ballistics,calculateRetardation)) @@ -173,7 +150,7 @@ while {_TOF < 15 && (_bulletPos select 1) < _targetRange} do { }; _kineticEnergy = 0.5 * (_bulletMass / 1000 * (_bulletSpeed ^ 2)); _kineticEnergy = _kineticEnergy * 0.737562149; - + if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (_bulletPos select 1) > 0) then { // Coriolis _horizontalDeflection = 0.0000729 * ((_bulletPos select 1) ^ 2) * sin(_latitude) / _speedAverage; @@ -190,7 +167,7 @@ while {_TOF < 15 && (_bulletPos select 1) < _targetRange} do { _windage1 = _windage1 + _spinDrift; _windage2 = _windage2 + _spinDrift; }; - + GVAR(rangeCardData) set [_n, [_range, _elevation * 60, [_windage1 * 60, _windage2 * 60], _lead, _TOF, _bulletSpeed, _kineticEnergy]]; _n = _n + 1; }; diff --git a/addons/atragmx/functions/fnc_change_gun.sqf b/addons/atragmx/functions/fnc_change_gun.sqf index 7c5abac47e..8fe89dc4fe 100644 --- a/addons/atragmx/functions/fnc_change_gun.sqf +++ b/addons/atragmx/functions/fnc_change_gun.sqf @@ -17,10 +17,7 @@ */ #include "script_component.hpp" -private ["_gunID", "_restoreMemory", "_updateDisplay"]; -_gunID = _this select 0; -_restoreMemory = _this select 1; -_updateDisplay = _this select 2; +params ["_gunID", "_restoreMemory", "_updateDisplay"]; if (_gunID < 0 || _gunID > (count GVAR(gunList)) - 1) exitWith {}; diff --git a/addons/atragmx/functions/fnc_create_dialog.sqf b/addons/atragmx/functions/fnc_create_dialog.sqf index 07b93eb2da..791374c9d0 100644 --- a/addons/atragmx/functions/fnc_create_dialog.sqf +++ b/addons/atragmx/functions/fnc_create_dialog.sqf @@ -39,7 +39,7 @@ if (GVAR(showRangeCard)) then { }; GVAR(showRangeCardSetup) call FUNC(show_range_card_setup); GVAR(showSolutionSetup) call FUNC(show_solution_setup); -GVAR(showTargetData) call FUNC(show_target_data); +GVAR(showTargetData) call FUNC(show_target_data); GVAR(showTargetRangeAssist) call FUNC(show_target_range_assist); GVAR(showTargetSpeedAssist) call FUNC(show_target_speed_assist); GVAR(showTargetSpeedAssistTimer) call FUNC(show_target_speed_assist_timer); diff --git a/addons/atragmx/functions/fnc_show_gun_list.sqf b/addons/atragmx/functions/fnc_show_gun_list.sqf index 5e1cdfa453..a3c45a977d 100644 --- a/addons/atragmx/functions/fnc_show_gun_list.sqf +++ b/addons/atragmx/functions/fnc_show_gun_list.sqf @@ -21,6 +21,5 @@ GVAR(showGunList) = _this; if (_this) then { ctrlSetFocus ((uiNamespace getVariable "ATragMX_Display") displayCtrl 6002); - lbSetCurSel [6000, GVAR(currentGun)]; }; diff --git a/addons/atragmx/functions/fnc_show_range_card_setup.sqf b/addons/atragmx/functions/fnc_show_range_card_setup.sqf index 3d44c14b53..b3457793b9 100644 --- a/addons/atragmx/functions/fnc_show_range_card_setup.sqf +++ b/addons/atragmx/functions/fnc_show_range_card_setup.sqf @@ -21,7 +21,7 @@ GVAR(showRangeCardSetup) = _this; if (_this) then { ctrlSetFocus ((uiNamespace getVariable "ATragMX_Display") displayCtrl 10006); - + ctrlSetText [10003, Str(Round(GVAR(rangeCardStartRange)))]; ctrlSetText [10004, Str(Round(GVAR(rangeCardEndRange)))]; ctrlSetText [10005, Str(Round(GVAR(rangeCardIncrement)))]; diff --git a/addons/atragmx/functions/fnc_show_target_range_assist.sqf b/addons/atragmx/functions/fnc_show_target_range_assist.sqf index 4f46932a0b..ec61edd1f4 100644 --- a/addons/atragmx/functions/fnc_show_target_range_assist.sqf +++ b/addons/atragmx/functions/fnc_show_target_range_assist.sqf @@ -21,7 +21,6 @@ GVAR(showTargetRangeAssist) = _this; if (_this) then { ctrlSetFocus ((uiNamespace getVariable "ATragMX_Display") displayCtrl 7018); - ctrlSetText [7012, Str(parseNumber(ctrlText 320))]; ctrlSetText [7013, Str(parseNumber(ctrlText 340))]; @@ -30,4 +29,4 @@ if (_this) then { } else { ctrlSetText [7016, "Meters"]; }; -}; \ No newline at end of file +}; diff --git a/addons/atragmx/functions/fnc_show_target_speed_assist.sqf b/addons/atragmx/functions/fnc_show_target_speed_assist.sqf index 2e66b5ea7b..b3cf1b4393 100644 --- a/addons/atragmx/functions/fnc_show_target_speed_assist.sqf +++ b/addons/atragmx/functions/fnc_show_target_speed_assist.sqf @@ -21,7 +21,7 @@ GVAR(showTargetSpeedAssist) = _this; if (_this) then { ctrlSetFocus ((uiNamespace getVariable "ATragMX_Display") displayCtrl 8012); - + ctrlSetText [8004, Str(Round((GVAR(targetRange) select GVAR(currentTarget))))]; if (GVAR(currentUnit) == 1) then { @@ -29,7 +29,7 @@ if (_this) then { } else { ctrlSetText [8008, "Meters"]; }; - + if (GVAR(currentUnit) == 2) then { ctrlSetText [8011, "m/s"]; } else { diff --git a/addons/atragmx/functions/fnc_sord.sqf b/addons/atragmx/functions/fnc_sord.sqf index a433153c0e..b342072018 100644 --- a/addons/atragmx/functions/fnc_sord.sqf +++ b/addons/atragmx/functions/fnc_sord.sqf @@ -17,10 +17,7 @@ */ #include "script_component.hpp" -private ["_slopeDistance", "_azimuth", "_inclination"]; -_slopeDistance = _this select 0; -_azimuth = _this select 1; -_inclination = _this select 2; +params ["_slopeDistance", "_azimuth", "_inclination"]; GVAR(inclinationAngle) set [GVAR(currentTarget), round(_inclination)]; GVAR(directionOfFire) set [GVAR(currentTarget), round(_azimuth)]; diff --git a/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf b/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf index 0f42f9637c..14a0a276cc 100644 --- a/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf +++ b/addons/atragmx/functions/fnc_target_speed_assist_timer.sqf @@ -21,26 +21,26 @@ if !(ctrlVisible 9000) then { true call FUNC(show_target_speed_assist_timer); ctrlSetFocus ((uiNamespace getVariable "ATragMX_Display") displayCtrl 9002); - + [{ private ["_args", "_startTime"]; _args = _this select 0; _startTime = _args select 0; - + if (!(GVAR(speedAssistTimer))) exitWith { GVAR(speedAssistTimer) = true; - + ctrlSetText [8006, Str(Round((ACE_time - _startTime) * 10) / 10)]; [] call FUNC(calculate_target_speed_assist); false call FUNC(show_target_speed_assist_timer); true call FUNC(show_target_speed_assist); - + [_this select 1] call CBA_fnc_removePerFrameHandler; }; - + ctrlSetText [9001, Str(Round((ACE_time - _startTime) * 10) / 10)]; - + }, 0.1, [ACE_time]] call CBA_fnc_addPerFrameHandler; }; diff --git a/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf b/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf index ce761c2216..87e973c7c0 100644 --- a/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_atmo_env_data.sqf @@ -18,7 +18,7 @@ if (ctrlVisible 13000) then { false call FUNC(show_atmo_env_data); true call FUNC(show_main_page); - + if (_this == 1) then { call FUNC(calculate_target_solution); }; diff --git a/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf b/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf index 0fd4b913b8..f3eb814da7 100644 --- a/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_gun_ammo_data.sqf @@ -18,7 +18,7 @@ if (ctrlVisible 12000) then { false call FUNC(show_gun_ammo_data); true call FUNC(show_main_page); - + if (_this == 1) then { call FUNC(update_zero_range); call FUNC(calculate_target_solution); diff --git a/addons/atragmx/functions/fnc_toggle_gun_list.sqf b/addons/atragmx/functions/fnc_toggle_gun_list.sqf index 1cc1f9338b..e5dbf54bd5 100644 --- a/addons/atragmx/functions/fnc_toggle_gun_list.sqf +++ b/addons/atragmx/functions/fnc_toggle_gun_list.sqf @@ -18,7 +18,7 @@ if (ctrlVisible 6000) then { false call FUNC(show_gun_list); true call FUNC(show_main_page); - + if (_this) then { [lbCurSel 6000, true, true] call FUNC(change_gun); }; diff --git a/addons/atragmx/functions/fnc_toggle_range_card.sqf b/addons/atragmx/functions/fnc_toggle_range_card.sqf index 059bc7e40b..7d8b7a0239 100644 --- a/addons/atragmx/functions/fnc_toggle_range_card.sqf +++ b/addons/atragmx/functions/fnc_toggle_range_card.sqf @@ -21,9 +21,9 @@ if (ctrlVisible 5006) then { } else { false call FUNC(show_main_page); true call FUNC(show_range_card); - + ctrlSetFocus ((uiNamespace getVariable "ATragMX_Display") displayCtrl 5001); - + [] call FUNC(calculate_range_card); [] call FUNC(update_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 738a154d17..96c31459b2 100644 --- a/addons/atragmx/functions/fnc_toggle_range_card_setup.sqf +++ b/addons/atragmx/functions/fnc_toggle_range_card_setup.sqf @@ -18,12 +18,12 @@ if (ctrlVisible 10000) then { false call FUNC(show_range_card_setup); true call FUNC(show_range_card); - + if (_this == 1) then { GVAR(rangeCardStartRange) = 0 max Round(parseNumber(ctrlText 10003)) min 3000; GVAR(rangeCardEndRange) = 0 max Round(parseNumber(ctrlText 10004)) min 3000; GVAR(rangeCardIncrement) = 1 max Round(parseNumber(ctrlText 10005)) min 3000; - + [] call FUNC(calculate_range_card); [] call FUNC(update_range_card); }; diff --git a/addons/atragmx/functions/fnc_toggle_solution_setup.sqf b/addons/atragmx/functions/fnc_toggle_solution_setup.sqf index 0e9f702383..5372b205d0 100644 --- a/addons/atragmx/functions/fnc_toggle_solution_setup.sqf +++ b/addons/atragmx/functions/fnc_toggle_solution_setup.sqf @@ -18,7 +18,7 @@ if (ctrlVisible 15000) then { false call FUNC(show_solution_setup); true call FUNC(show_main_page); - + if (_this == 1) then { GVAR(currentScopeClickUnit) = GVAR(currentScopeClickUnitTemp); GVAR(currentScopeClickNumber) = GVAR(currentScopeClickNumberTemp); @@ -30,9 +30,9 @@ if (ctrlVisible 15000) then { } else { true call FUNC(show_solution_setup); false call FUNC(show_main_page); - + GVAR(currentScopeClickUnitTemp) = GVAR(currentScopeClickUnit); GVAR(currentScopeClickNumberTemp) = GVAR(currentScopeClickNumber); - + [] call FUNC(update_solution_setup); }; diff --git a/addons/atragmx/functions/fnc_toggle_target_data.sqf b/addons/atragmx/functions/fnc_toggle_target_data.sqf index 90fefbf37e..2cfa2f8df5 100644 --- a/addons/atragmx/functions/fnc_toggle_target_data.sqf +++ b/addons/atragmx/functions/fnc_toggle_target_data.sqf @@ -18,7 +18,7 @@ if (ctrlVisible 14000) then { false call FUNC(show_target_data); true call FUNC(show_main_page); - + if (_this == 1) then { call FUNC(calculate_target_solution); }; diff --git a/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf b/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf index d13ef4fb2e..83d2daa95f 100644 --- a/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf +++ b/addons/atragmx/functions/fnc_toggle_target_range_assist.sqf @@ -18,7 +18,7 @@ if (ctrlVisible 7000) then { false call FUNC(show_target_range_assist); true call FUNC(show_main_page); - + if (_this == 1) then { ctrlSetText [320, Str(parseNumber(ctrlText 7012))]; ctrlSetText [140040, Str(parseNumber(ctrlText 7012))]; diff --git a/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf b/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf index 5b88a6cfce..4d1680d195 100644 --- a/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf +++ b/addons/atragmx/functions/fnc_toggle_target_speed_assist.sqf @@ -18,7 +18,7 @@ if (ctrlVisible 8000) then { false call FUNC(show_target_speed_assist); true call FUNC(show_main_page); - + if (_this == 1) then { [] call FUNC(calculate_target_speed_assist); private ["_targetSpeed"]; diff --git a/addons/atragmx/functions/fnc_update_range_card.sqf b/addons/atragmx/functions/fnc_update_range_card.sqf index d084754959..e8c910ca74 100644 --- a/addons/atragmx/functions/fnc_update_range_card.sqf +++ b/addons/atragmx/functions/fnc_update_range_card.sqf @@ -43,7 +43,7 @@ _speedOfSound = GVAR(temperature) call EFUNC(weather,calculateSpeedOfSound); _TOF = _x select 4; _velocity = _x select 5; _kineticEnergy = _x select 6; - + switch (GVAR(currentScopeUnit)) do { case 0: { _elevation = _elevation / 3.38; @@ -63,25 +63,25 @@ _speedOfSound = GVAR(temperature) call EFUNC(weather,calculateSpeedOfSound); }; _clickNumber = GVAR(workingMemory) select 8; _clickInterval = _clickSize / _clickNumber; - + _elevation = Round(_elevation / _clickInterval); _windage1 = Round(_windage1 / _clickInterval); _windage2 = Round(_windage2 / _clickInterval); }; }; - + _elevationOutput = Str(Round(_elevation * 100) / 100); _windageOutput = Str(Round(_windage1 * 100) / 100); - + _rangeOutput = Str(_range); if (_velocity < _speedOfSound) then { _rangeOutput = _rangeOutput + "*"; }; - + if (GVAR(currentUnit) == 1) then { _velocity = _velocity * 3.2808399; }; - + switch (GVAR(rangeCardCurrentColumn)) do { case 0: { if (GVAR(showWind2)) then { @@ -100,6 +100,6 @@ _speedOfSound = GVAR(temperature) call EFUNC(weather,calculateSpeedOfSound); _lastColumnOutput = Str(Round(_TOF * 100) / 100); } }; - + lnbAddRow [5007, [_rangeOutput, _elevationOutput, _windageOutput, _lastColumnOutput]]; } forEach GVAR(rangeCardData); diff --git a/addons/atragmx/functions/fnc_update_result.sqf b/addons/atragmx/functions/fnc_update_result.sqf index bb708efaab..2b6ca29e23 100644 --- a/addons/atragmx/functions/fnc_update_result.sqf +++ b/addons/atragmx/functions/fnc_update_result.sqf @@ -33,24 +33,24 @@ switch (GVAR(currentScopeUnit)) do { case 0: { _elevationAbs = _elevationAbs / 3.38; _windageAbs = _windageAbs / 3.38; - + _wind2 = _wind2 / 3.38; - + _elevationRel = _elevationRel / 3.38; _windageRel = _windageRel / 3.38; - + _elevationCur = _elevationCur / 3.38; _windageCur = _windageCur / 3.38; }; case 2: { _elevationAbs = _elevationAbs * 1.047; _windageAbs = _windageAbs * 1.047; - + _wind2 = _wind2 / 1.047; - + _elevationRel = _elevationRel * 1.047; _windageRel = _windageRel * 1.047; - + _elevationCur = _elevationCur * 1.047; _windageCur = _windageCur * 1.047; }; @@ -62,15 +62,15 @@ switch (GVAR(currentScopeUnit)) do { }; _clickNumber = GVAR(workingMemory) select 8; _clickInterval = _clickSize / _clickNumber; - + _elevationAbs = Round(_elevationAbs / _clickInterval); _windageAbs = Round(_windageAbs / _clickInterval); - + _wind2 = Round(_wind2 / _clickInterval); - + _elevationRel = Round(_elevationRel / _clickInterval); _windageRel = Round(_windageRel / _clickInterval); - + _elevationCur = Round(_elevationCur / _clickInterval); _windageCur = Round(_windageCur / _clickInterval); }; @@ -166,4 +166,4 @@ if (GVAR(showWind2)) then { } else { ctrlSetText [420, "0.0"]; }; -}; \ No newline at end of file +}; diff --git a/addons/ballistics/CfgMagazines.hpp b/addons/ballistics/CfgMagazines.hpp index e368381333..931a6c2309 100644 --- a/addons/ballistics/CfgMagazines.hpp +++ b/addons/ballistics/CfgMagazines.hpp @@ -83,7 +83,7 @@ class CfgMagazines { descriptionShort = CSTRING(30Rnd_556x45_mag_Tracer_DimDescription); picture = "\A3\weapons_f\data\ui\m_20stanag_red_ca.paa"; }; - + class 20Rnd_762x51_Mag: CA_Magazine { initSpeed = 833; }; @@ -121,7 +121,7 @@ class CfgMagazines { descriptionShort = CSTRING(20Rnd_762x51_mag_SDDescription); initSpeed = 325; }; - + class ACE_10Rnd_762x51_M118LR_Mag: 10Rnd_762x51_Mag { author = ECSTRING(common,ACETeam); ammo = "ACE_762x51_Ball_M118LR"; @@ -247,7 +247,7 @@ class CfgMagazines { descriptionShort = CSTRING(10Rnd_338_API526_Mag_Description); initSpeed = 880; }; - + class 5Rnd_127x108_Mag; class ACE_5Rnd_127x99_Mag: 5Rnd_127x108_Mag { author = ECSTRING(common,ACETeam); @@ -273,8 +273,8 @@ class CfgMagazines { descriptionShort = CSTRING(5Rnd_127x99_AMAX_Mag_Description); initSpeed = 860; }; - - + + class 30Rnd_9x21_Mag: CA_Magazine { initSpeed = 450; }; @@ -286,27 +286,27 @@ class CfgMagazines { descriptionShort = CSTRING(30Rnd_9x19_mag_Description); initSpeed = 370; }; - + class 11Rnd_45ACP_Mag: CA_Magazine { initSpeed = 250; }; - + class 6Rnd_45ACP_Cylinder : 11Rnd_45ACP_Mag { initSpeed = 250; }; - + class 30Rnd_45ACP_Mag_SMG_01: 30Rnd_9x21_Mag { initSpeed = 250; }; - + class 9Rnd_45ACP_Mag: 30Rnd_45ACP_Mag_SMG_01 { initSpeed = 250; }; - + class 30Rnd_45ACP_Mag_SMG_01_Tracer_Green: 30Rnd_45ACP_Mag_SMG_01 { initSpeed = 250; }; - + class 16Rnd_9x21_Mag: 30Rnd_9x21_Mag { initSpeed = 450; }; @@ -318,7 +318,7 @@ class CfgMagazines { descriptionShort = CSTRING(16Rnd_9x19_mag_Description); initSpeed = 370; }; - + class 10Rnd_762x54_Mag: 10Rnd_762x51_Mag { initSpeed = 800; }; @@ -331,15 +331,15 @@ class CfgMagazines { initSpeed = 800; tracersEvery = 1; }; - + class 150Rnd_762x54_Box: 150Rnd_762x51_Box { initSpeed = 750; }; - + class 150Rnd_93x64_Mag: CA_Magazine { initSpeed = 860; }; - + class 10Rnd_127x54_Mag: CA_Magazine { initSpeed = 300; }; diff --git a/addons/ballistics/CfgWeapons.hpp b/addons/ballistics/CfgWeapons.hpp index 3f6835bbba..4c0495decf 100644 --- a/addons/ballistics/CfgWeapons.hpp +++ b/addons/ballistics/CfgWeapons.hpp @@ -15,81 +15,81 @@ class CfgWeapons { class Rifle_Base_F; class Rifle_Long_Base_F; class MuzzleSlot; - + /* Long Rifles */ - + class GM6_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; }; - + class LRR_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.00020; // radians. Equal to 0.70 MOA. }; }; - + class DMR_06_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; - + class FullAuto: Mode_FullAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; }; - + class DMR_05_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; - + class FullAuto: Mode_FullAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; }; - + class DMR_04_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; }; - + class DMR_03_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.00032; // radians. Equal to 1.10 MOA. }; - + class FullAuto: Mode_FullAuto { dispersion = 0.00032; // radians. Equal to 1.10 MOA. }; }; - + class DMR_02_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.000262; // radians. Equal to 0.90 MOA. }; }; - + class DMR_01_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.0004; // radians. Equal to 1.375 MOA. }; }; - + class EBR_base_F: Rifle_Long_Base_F { class Single: Mode_SemiAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; - + class FullAuto: Mode_FullAuto { dispersion = 0.00029; // radians. Equal to 1.00 MOA. }; }; - + /* MX */ - + class arifle_MX_Base_F: Rifle_Base_F {}; class arifle_MX_SW_F: arifle_MX_Base_F { magazines[] = { @@ -158,7 +158,7 @@ class CfgWeapons { class Burst: Mode_Burst { dispersion = 0.0008727; // radians. Equal to 3 MOA. }; - + class FullAuto: Mode_FullAuto { dispersion = 0.0008727; // radians. Equal to 3 MOA. }; @@ -511,7 +511,7 @@ class CfgWeapons { ACE_barrelTwist=234.95; ACE_barrelLength=609.6; }; - + class HMG_127 : LMG_RCWS { }; class HMG_01: HMG_127 { @@ -521,7 +521,7 @@ class CfgWeapons { ACE_barrelTwist=304.8; ACE_barrelLength=1143.0; }; - + /* Silencers */ class ItemCore; diff --git a/addons/captives/functions/fnc_doEscortCaptive.sqf b/addons/captives/functions/fnc_doEscortCaptive.sqf index 484151853b..e0d3ae8fa6 100644 --- a/addons/captives/functions/fnc_doEscortCaptive.sqf +++ b/addons/captives/functions/fnc_doEscortCaptive.sqf @@ -37,7 +37,7 @@ if (_state) then { [{ params ["_args", "_pfID"]; _args params ["_unit", "_target", "_actionID"]; - + if (_unit getVariable [QGVAR(isEscorting), false]) then { if (!alive _target || {!alive _unit} || {!canStand _target} || {!canStand _unit} || {_target getVariable ["ACE_isUnconscious", false]} || {_unit getVariable ["ACE_isUnconscious", false]} || {!isNull (attachedTo _unit)}) then { _unit setVariable [QGVAR(isEscorting), false, true]; diff --git a/addons/common/RscInfoType.hpp b/addons/common/RscInfoType.hpp index 327a9814d1..e5af2454cb 100644 --- a/addons/common/RscInfoType.hpp +++ b/addons/common/RscInfoType.hpp @@ -15,7 +15,7 @@ class RscInGameUI { class RscUnitInfoTank: RscUnitInfo { onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscUnitInfo"",'IGUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgVehicle', _this select 0)]; [ARR_2('infoDisplayChanged', [ARR_2(_this select 0, 'Vehicle')])] call FUNC(localEvent);); }; - + class RscUnitInfoAirNoWeapon: RscUnitInfo { onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscUnitInfo"",'IGUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgAircraft', _this select 0)]; [ARR_2('infoDisplayChanged', [ARR_2(_this select 0, 'Aircraft')])] call FUNC(localEvent);); }; diff --git a/addons/common/functions/fnc_dumpPerformanceCounters.sqf b/addons/common/functions/fnc_dumpPerformanceCounters.sqf index bdc4588b05..afb71b423a 100644 --- a/addons/common/functions/fnc_dumpPerformanceCounters.sqf +++ b/addons/common/functions/fnc_dumpPerformanceCounters.sqf @@ -21,7 +21,7 @@ if (!isNil "ACE_PFH_COUNTER") then { private _isActive = ["ACTIVE", "REMOVED"] select isNil {CBA_common_PFHhandles select (_pfh select 0)}; - diag_log text format ["Registered PFH: id=%1 [%2, delay %3], %4:%5", _pfh select 0, _isActive, _parameters select 1, _pfh select 1, _pfh select 2]; + diag_log text format ["Registered PFH: id=%1 [%2, delay %3], %4:%5", _pfh select 0, _isActive, _parameters select 1, _pfh select 1, _pfh select 2]; false } count ACE_PFH_COUNTER; }; @@ -42,7 +42,7 @@ diag_log text format ["-------------------------------------------"]; if (_iter > 2) then { _count = _count + 1; private _delta = (_x select 1) - (_x select 0); - + _total = _total + _delta; }; @@ -54,7 +54,7 @@ diag_log text format ["-------------------------------------------"]; _averageResult = (_total / _count) * 1000; // dump results - diag_log text format ["%1: Average: %2s / %3 = %4ms", _counterEntry select 0, _total, _count, _averageResult]; + diag_log text format ["%1: Average: %2s / %3 = %4ms", _counterEntry select 0, _total, _count, _averageResult]; } else { diag_log text format ["%1: No results", _counterEntry select 0]; }; @@ -68,7 +68,7 @@ diag_log text format["-------------------------------------------"]; { private _delay = _x select 2; //if(_delay > 0) then { _delay = _delay / 1000; }; - + diag_log text format["%1: %2s, delay=%3, handle=%4",(_x select 0), _delay, (_x select 3), (_x select 4)]; } forEach ACE_PERFORMANCE_EXCESSIVE_STEP_TRACKER; diff --git a/addons/dagr/initKeybinds.sqf b/addons/dagr/initKeybinds.sqf index 66bd08190e..1a2f25ac4d 100644 --- a/addons/dagr/initKeybinds.sqf +++ b/addons/dagr/initKeybinds.sqf @@ -37,7 +37,7 @@ _conditonCode = { _toggleCode = { // Conditions: canInteract if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {}; - + // Statement [] call FUNC(toggleOverlay); if (!GVAR(run)) then { diff --git a/addons/dragging/CfgVehicles.hpp b/addons/dragging/CfgVehicles.hpp index 31928e8621..1529d39319 100644 --- a/addons/dragging/CfgVehicles.hpp +++ b/addons/dragging/CfgVehicles.hpp @@ -90,7 +90,7 @@ class CfgVehicles { GVAR(canCarry) = 0; GVAR(canDrag) = 0; }; - + //Plastic and metal case class PlasticCase_01_base_F: Items_base_F { class EventHandlers { @@ -116,7 +116,7 @@ class CfgVehicles { GVAR(dragPosition[]) = {0,1.2,0}; GVAR(dragDirection) = 0; }; - + // Barrier class RoadCone_F: ThingX { class EventHandlers { diff --git a/addons/explosives/functions/fnc_setSpeedDial.sqf b/addons/explosives/functions/fnc_setSpeedDial.sqf index 9013c812cc..7e68c9016f 100644 --- a/addons/explosives/functions/fnc_setSpeedDial.sqf +++ b/addons/explosives/functions/fnc_setSpeedDial.sqf @@ -14,8 +14,7 @@ * * Public: No */ - #include "script_component.hpp" - +#include "script_component.hpp" private ["_speedDial", "_amount"]; _speedDial = ace_player getVariable [QGVAR(SpeedDial), []]; diff --git a/addons/fastroping/$PBOPREFIX$ b/addons/fastroping/$PBOPREFIX$ index 352dc2c83a..c2389fdaf5 100644 --- a/addons/fastroping/$PBOPREFIX$ +++ b/addons/fastroping/$PBOPREFIX$ @@ -1 +1 @@ -z\ace\addons\fastroping +z\ace\addons\fastroping diff --git a/addons/finger/XEH_postInit.sqf b/addons/finger/XEH_postInit.sqf index 394c0cfd3b..94a22d7224 100644 --- a/addons/finger/XEH_postInit.sqf +++ b/addons/finger/XEH_postInit.sqf @@ -11,7 +11,7 @@ GVAR(pfeh_id) = -1; if (!GVAR(enabled)) exitWith {}; [QGVAR(fingered), {_this call FUNC(incomingFinger)}] call EFUNC(common,addEventHandler); - + ["ACE3 Common", QGVAR(finger), [(localize LSTRING(keyComb)), (localize LSTRING(keyComb_description))], diff --git a/addons/frag/CfgAmmo.hpp b/addons/frag/CfgAmmo.hpp index 41734d2806..916949bab2 100644 --- a/addons/frag/CfgAmmo.hpp +++ b/addons/frag/CfgAmmo.hpp @@ -8,11 +8,11 @@ class CfgAmmo { //class ace_arty_105mm_m1_m782_delay: ace_arty_105mm_m1_m782_prox { // GVAR(skip) = 1; //}; - + class Bo_GBU12_LGB; class ACE_GBU12 : Bo_GBU12_LGB { GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_large", "ACE_frag_large", "ACE_frag_large_HD", "ACE_frag_large", "ACE_frag_huge", "ACE_frag_huge_HD", "ACE_frag_huge"}; GVAR(metal) = 140000; GVAR(charge) = 87000; @@ -27,7 +27,7 @@ class CfgAmmo { class Grenade; class GrenadeHand: Grenade { GVAR(enabled) = 1; - + GVAR(skip) = 0; GVAR(force) = 1; // This is a good high-drag frag type for grenades. @@ -52,7 +52,7 @@ class CfgAmmo { class R_Hydra_HE: RocketBase { // Source: http://fas.org/man/dod-101/sys/missile/hydra-70.htm GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 3850; GVAR(charge) = 1040; @@ -74,18 +74,18 @@ class CfgAmmo { class BombCore; class Bo_Mk82: BombCore { GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_large", "ACE_frag_large", "ACE_frag_large_HD", "ACE_frag_large", "ACE_frag_huge", "ACE_frag_huge_HD", "ACE_frag_huge"}; GVAR(metal) = 140000; GVAR(charge) = 87000; GVAR(gurney_c) = 2320; GVAR(gurney_k) = 1/2; }; - + class G_40mm_HE: GrenadeBase { // Source: http://www.inetres.com/gp/military/infantry/grenade/40mm_ammo.html#M441 GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_tiny_HD"}; GVAR(metal) = 200; GVAR(charge) = 32; @@ -95,14 +95,14 @@ class CfgAmmo { class G_40mm_HEDP: G_40mm_HE { // Source: http://www.inetres.com/gp/military/infantry/grenade/40mm_ammo.html#M433 GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_tiny_HD"}; GVAR(metal) = 200; GVAR(charge) = 45; GVAR(gurney_c) = 2830; GVAR(gurney_k) = 1/2; }; - + class ACE_G_40mm_HEDP: G_40mm_HEDP { }; class ACE_G_40mm_HE: G_40mm_HE { @@ -121,7 +121,7 @@ class CfgAmmo { class Sh_155mm_AMOS: ShellBase { // Source: http://www.globalsecurity.org/military/systems/munitions/m795.htm GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_large", "ACE_frag_large", "ACE_frag_large_HD", "ACE_frag_large", "ACE_frag_huge", "ACE_frag_huge_HD", "ACE_frag_huge"}; GVAR(metal) = 36000; GVAR(charge) = 9979; @@ -131,7 +131,7 @@ class CfgAmmo { class Sh_82mm_AMOS : Sh_155mm_AMOS { // Source: http://www.arsenal-bg.com/defense_police/mortar_bombs_82mm.htm GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 3200; GVAR(charge) = 420; @@ -140,7 +140,7 @@ class CfgAmmo { }; class ModuleOrdnanceMortar_F_Ammo: Sh_82mm_AMOS { GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 800; GVAR(charge) = 4200; @@ -149,7 +149,7 @@ class CfgAmmo { }; class Sh_105mm_HEAT_MP : Sh_125mm_HEAT { GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 11400; GVAR(charge) = 7100; @@ -158,7 +158,7 @@ class CfgAmmo { }; class Sh_120mm_HE : ShellBase { GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 23000; GVAR(charge) = 3148; @@ -167,7 +167,7 @@ class CfgAmmo { }; class Sh_125mm_HE: Sh_120mm_HE { GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 16000; GVAR(charge) = 3200; @@ -176,7 +176,7 @@ class CfgAmmo { }; class ModuleOrdnanceHowitzer_F_ammo: Sh_155mm_AMOS { GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_large", "ACE_frag_large", "ACE_frag_large_HD", "ACE_frag_large", "ACE_frag_huge", "ACE_frag_huge_HD", "ACE_frag_huge"}; GVAR(metal) = 1950; GVAR(charge) = 15800; @@ -203,7 +203,7 @@ class CfgAmmo { class Missile_AGM_02_F : MissileBase { // Source: http://fas.org/man/dod-101/sys/smart/agm-65.htm GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 56250; GVAR(charge) = 39000; @@ -213,7 +213,7 @@ class CfgAmmo { class M_Hellfire_AT: MissileBase { // Source: http://www.designation-systems.net/dusrm/m-114.html GVAR(enabled) = 1; - + GVAR(classes)[] = {"ACE_frag_medium", "ACE_frag_medium_HD"}; GVAR(metal) = 8000; GVAR(charge) = 2400; @@ -471,6 +471,6 @@ class CfgAmmo { class ACE_frag_spall_huge: ACE_frag_huge { timeToLive = 0.3; }; - + #include "CfgAmmoReflections.hpp" }; diff --git a/addons/frag/functions/fnc_doReflections.sqf b/addons/frag/functions/fnc_doReflections.sqf index 7702e34fd5..64d8ede26d 100644 --- a/addons/frag/functions/fnc_doReflections.sqf +++ b/addons/frag/functions/fnc_doReflections.sqf @@ -13,10 +13,6 @@ if(count _this > 2) then { if(_depth <= 2) then { _indirectHitRange = getNumber(configFile >> "CfgAmmo" >> _ammo >> "indirectHitRange"); _indirectHit = getNumber(configFile >> "CfgAmmo" >> _ammo >> "indirectHit"); - - - - _testParams = [_pos, [_indirectHitRange, _indirectHit], [], [], -4, _depth, 0]; [DFUNC(findReflections), 0, _testParams] call CBA_fnc_addPerFrameHandler; }; diff --git a/addons/frag/functions/fnc_drawTraces.sqf b/addons/frag/functions/fnc_drawTraces.sqf index ac95957ad4..494a2af727 100644 --- a/addons/frag/functions/fnc_drawTraces.sqf +++ b/addons/frag/functions/fnc_drawTraces.sqf @@ -18,12 +18,11 @@ private ["_color", "_index", "_lastPos", "_lastSpd", "_max", "_positions", "_sta } else { _data2 = _positions select (_index + ACE_TRACE_DRAW_INC); }; - + _pos1 = _data1 select 0; _pos2 = _data2 select 0; _index = _index + ACE_TRACE_DRAW_INC; - - + drawLine3D [_pos1, _pos2, _color]; _lastPos = _pos2; _lastSpd = _data1 select 1; diff --git a/addons/gestures/functions/fnc_playSignal.sqf b/addons/gestures/functions/fnc_playSignal.sqf index feb79f5370..8f20c690ef 100644 --- a/addons/gestures/functions/fnc_playSignal.sqf +++ b/addons/gestures/functions/fnc_playSignal.sqf @@ -14,7 +14,7 @@ * Public: No */ #include "script_component.hpp" - + TRACE_1("params",_this); if (!GVAR(ReloadMutex)) exitWith {false}; diff --git a/addons/goggles/RscTitles.hpp b/addons/goggles/RscTitles.hpp index 6c1b9870b6..5544b9b132 100644 --- a/addons/goggles/RscTitles.hpp +++ b/addons/goggles/RscTitles.hpp @@ -1,6 +1,6 @@ class RscTitles{ #include "define.hpp" - + class RscACE_Goggles_BaseTitle{ idd = -1; onLoad = "uiNamespace setVariable ['ACE_Goggles_Display', _this select 0]"; @@ -9,25 +9,25 @@ class RscTitles{ fadeOut=0.5; movingEnable = false; duration = 10e10; - name = "RscACE_Goggles_BaseTitle"; + name = "RscACE_Goggles_BaseTitle"; class controls; }; - + class RscACE_Goggles:RscACE_Goggles_BaseTitle{ idd = 1044; - name = "RscACE_Goggles"; + name = "RscACE_Goggles"; class controls{ class gogglesImage: RscPicture{ idc = 10650; }; }; }; - + class RscACE_GogglesEffects:RscACE_Goggles_BaseTitle{ idd = 1045; onLoad = "uiNamespace setVariable ['ACE_Goggles_DisplayEffects', _this select 0]"; onUnload = "uiNamespace setVariable ['ACE_Goggles_DisplayEffects', displayNull]"; - name = "RscACE_GogglesEffects"; + name = "RscACE_GogglesEffects"; fadeIn=0; fadeOut=0.5; class controls{ @@ -39,4 +39,4 @@ class RscTitles{ }; }; }; -}; \ No newline at end of file +}; diff --git a/addons/huntir/CfgAmmo.hpp b/addons/huntir/CfgAmmo.hpp index 86f73e9755..33328094b2 100644 --- a/addons/huntir/CfgAmmo.hpp +++ b/addons/huntir/CfgAmmo.hpp @@ -6,7 +6,7 @@ class CfgAmmo { smokeColor[] = {0, 0, 0, 0}; timeToLive = 6; }; - + class ShellBase; class ACE_HuntIR_Propell: ShellBase { supersonicCrackNear[] = {"",0.316228,1,50}; diff --git a/addons/huntir/CfgWeapons.hpp b/addons/huntir/CfgWeapons.hpp index 6ff271d604..6d74cbfba9 100644 --- a/addons/huntir/CfgWeapons.hpp +++ b/addons/huntir/CfgWeapons.hpp @@ -2,7 +2,7 @@ class CfgWeapons { class ACE_ItemCore; class InventoryItem_Base_F; - + class ACE_HuntIR_monitor: ACE_ItemCore { scope = 2; displayName = CSTRING(monitor_displayName); @@ -14,7 +14,7 @@ class CfgWeapons { mass = 20; }; }; - + class GrenadeLauncher; class UGL_F: GrenadeLauncher { magazines[] += {"ACE_HuntIR_M203"}; @@ -23,7 +23,7 @@ class CfgWeapons { //magazines[] += {"ACE_HuntIR_M203"}; magazines[] = {"1Rnd_HE_Grenade_shell","UGL_FlareWhite_F","UGL_FlareGreen_F","UGL_FlareRed_F","UGL_FlareYellow_F","UGL_FlareCIR_F","1Rnd_Smoke_Grenade_shell","1Rnd_SmokeRed_Grenade_shell","1Rnd_SmokeGreen_Grenade_shell","1Rnd_SmokeYellow_Grenade_shell","1Rnd_SmokePurple_Grenade_shell","1Rnd_SmokeBlue_Grenade_shell","1Rnd_SmokeOrange_Grenade_shell","3Rnd_HE_Grenade_shell","3Rnd_UGL_FlareWhite_F","3Rnd_UGL_FlareGreen_F","3Rnd_UGL_FlareRed_F","3Rnd_UGL_FlareYellow_F","3Rnd_UGL_FlareCIR_F","3Rnd_Smoke_Grenade_shell","3Rnd_SmokeRed_Grenade_shell","3Rnd_SmokeGreen_Grenade_shell","3Rnd_SmokeYellow_Grenade_shell","3Rnd_SmokePurple_Grenade_shell","3Rnd_SmokeBlue_Grenade_shell","3Rnd_SmokeOrange_Grenade_shell","ACE_HuntIR_M203"}; }; - + class Rifle_Base_F; class arifle_MX_Base_F: Rifle_Base_F { class GL_3GL_F: UGL_F { diff --git a/addons/interaction/CfgVehicles.hpp b/addons/interaction/CfgVehicles.hpp index 0b71ebb4e1..6b6e0e69b0 100644 --- a/addons/interaction/CfgVehicles.hpp +++ b/addons/interaction/CfgVehicles.hpp @@ -577,7 +577,7 @@ class CfgVehicles { class Land_PortableLight_double_off_F: Land_PortableLight_double_F { scope = 1; }; - + class RoadCone_F: ThingX { class ACE_Actions { class ACE_MainActions { diff --git a/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf b/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf index 6e48c1ec2a..ab23701760 100644 --- a/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf +++ b/addons/inventory/functions/fnc_inventoryDisplayLoad.sqf @@ -28,7 +28,7 @@ _filter ctrlAddEventHandler ["LBSelChanged", {_this call FUNC(onLBSelChanged)}]; [{ disableSerialization; params ["_filter"]; - + // remove "All", so we can push it to the back later. // to keep localization we can keep the lbText (displayed name). private _index = lbSize _filter - 1; diff --git a/addons/javelin/CfgMagazines.hpp b/addons/javelin/CfgMagazines.hpp index 3053cf1fa1..80111d9484 100644 --- a/addons/javelin/CfgMagazines.hpp +++ b/addons/javelin/CfgMagazines.hpp @@ -10,7 +10,7 @@ class CfgMagazines { class Titan_AT: Titan_AA { ammo = "ACE_Javelin_FGM148"; //from misssileGuidance, was "M_Titan_AT" }; - + //Handheld Titan "AP" Magazine (SACLOS? "Anti-personal") // class Titan_AP: Titan_AA { //??? diff --git a/addons/javelin/CfgVehicles.hpp b/addons/javelin/CfgVehicles.hpp index 1cd527089d..74863ef08f 100644 --- a/addons/javelin/CfgVehicles.hpp +++ b/addons/javelin/CfgVehicles.hpp @@ -3,20 +3,20 @@ class CfgVehicles { class StaticWeapon : LandVehicle { class Turrets; }; - + class StaticMGWeapon : StaticWeapon { class Turrets : Turrets { class MainTurret; }; }; class AT_01_base_F: StaticMGWeapon {}; - + class B_static_AT_F: AT_01_base_F { class Turrets : Turrets { class MainTurret : MainTurret { weapons[] = { QGVAR(Titan_Static) }; magazines[] = {"1Rnd_GAT_missiles","1Rnd_GAT_missiles","1Rnd_GAT_missiles","1Rnd_GAT_missiles"}; - + turretInfoType = "ACE_RscOptics_javelin"; gunnerOpticsModel = PATHTOF(data\reticle_titan.p3d); opticsZoomMin = 0.08333; @@ -34,7 +34,7 @@ class CfgVehicles { class MainTurret : MainTurret { weapons[] = { QGVAR(Titan_Static) }; magazines[] = {"1Rnd_GAT_missiles","1Rnd_GAT_missiles","1Rnd_GAT_missiles","1Rnd_GAT_missiles"}; - + turretInfoType = "ACE_RscOptics_javelin"; gunnerOpticsModel = PATHTOF(data\reticle_titan.p3d); opticsZoomMin = 0.08333; @@ -52,7 +52,7 @@ class CfgVehicles { class MainTurret : MainTurret { weapons[] = { QGVAR(Titan_Static) }; magazines[] = {"1Rnd_GAT_missiles","1Rnd_GAT_missiles","1Rnd_GAT_missiles","1Rnd_GAT_missiles"}; - + turretInfoType = "ACE_RscOptics_javelin"; gunnerOpticsModel = PATHTOF(data\reticle_titan.p3d); opticsZoomMin = 0.08333; @@ -65,4 +65,4 @@ class CfgVehicles { }; }; }; -}; \ No newline at end of file +}; diff --git a/addons/javelin/CfgWeapons.hpp b/addons/javelin/CfgWeapons.hpp index 75aaf7c332..1e32752145 100644 --- a/addons/javelin/CfgWeapons.hpp +++ b/addons/javelin/CfgWeapons.hpp @@ -1,38 +1,38 @@ class CfgWeapons { class Launcher; class MissileLauncher; - + class Launcher_Base_F : Launcher { - class WeaponSlotsInfo; + class WeaponSlotsInfo; }; // @TODO: AA by default, motherfuckers class missiles_titan : MissileLauncher { - + }; - + class missiles_titan_at : missiles_titan { }; - class GVAR(Titan_Static) : missiles_titan_at { + class GVAR(Titan_Static) : missiles_titan_at { GVAR(enabled) = 1; weaponInfoType = "ACE_RscOptics_javelin"; modelOptics = PATHTOF(data\reticle_titan.p3d); - + canLock = 0; magazines[] = {"1Rnd_GAT_missiles"}; lockingTargetSound[] = {"",0,1}; lockedTargetSound[] = {"",0,1}; }; - + // @TODO: AA by default, motherfuckers class launch_Titan_base : Launcher_Base_F {}; - + class launch_Titan_short_base : launch_Titan_base { }; - + class launch_B_Titan_short_F: launch_Titan_short_base { GVAR(enabled) = 1; weaponInfoType = "ACE_RscOptics_javelin"; modelOptics = PATHTOF(data\reticle_titan.p3d); - + canLock = 0; lockingTargetSound[] = {"",0,1}; @@ -42,7 +42,7 @@ class CfgWeapons { GVAR(enabled) = 1; weaponInfoType = "ACE_RscOptics_javelin"; modelOptics = PATHTOF(data\reticle_titan.p3d); - + canLock = 0; lockingTargetSound[] = {"",0,1}; @@ -52,10 +52,10 @@ class CfgWeapons { GVAR(enabled) = 1; weaponInfoType = "ACE_RscOptics_javelin"; modelOptics = PATHTOF(data\reticle_titan.p3d); - + canLock = 0; - - + + lockingTargetSound[] = {"",0,1}; lockedTargetSound[] = {"",0,1}; }; @@ -63,10 +63,10 @@ class CfgWeapons { GVAR(enabled) = 1; weaponInfoType = "ACE_RscOptics_javelin"; modelOptics = PATHTOF(data\reticle_titan.p3d); - + canLock = 0; lockingTargetSound[] = {"",0,1}; lockedTargetSound[] = {"",0,1}; }; -}; \ No newline at end of file +}; diff --git a/addons/javelin/RscInGameUI.hpp b/addons/javelin/RscInGameUI.hpp index ea1e12626c..d3fff71db0 100644 --- a/addons/javelin/RscInGameUI.hpp +++ b/addons/javelin/RscInGameUI.hpp @@ -15,7 +15,7 @@ class RscInGameUI { controls[] = { "ACE_javelin_elements_group", "ACE_Targeting" }; //, "ACE_TargetingConstrains", "ACE_TargetingGate", "ACE_TargetingLines"}; onLoad = QUOTE(_this call FUNC(onOpticLoad)); onUnload = QUOTE(_this call FUNC(onOpticUnload)); - + class ACE_javelin_elements_group: RscControlsGroup { x = "SafezoneX"; @@ -44,7 +44,7 @@ class RscInGameUI { w = 0; h = 0; }; - + class ACE_javelin_Day_mode_off: RscPicture { idc = 1001; x = "(SafezoneX+(SafezoneW -SafezoneH*3/4)/2)+ (0.03/4)*3*SafezoneH - SafezoneX"; @@ -123,7 +123,7 @@ class RscInGameUI { h = 0; colorText[] = {0.2941,0.8745,0.2157,1}; }; - + }; }; class CA_Javelin_NFOV_mode_off: ACE_javelin_Day_mode_off { @@ -191,7 +191,7 @@ class RscInGameUI { h = "0.1895*SafezoneH"; colorText[] = {0.2941,0.8745,0.2157,1}; }; - + }; }; @@ -253,12 +253,12 @@ class RscInGameUI { }; class ACE_Targeting : RscControlsGroup { idc = 6999; - + x = "SafezoneX"; y = "SafezoneY"; w = "SafezoneW"; h = "SafezoneH"; - + enabled = 0; class Controls { class ACE_TargetingConstrains: RscControlsGroup { @@ -266,7 +266,7 @@ class RscInGameUI { y = "SafezoneY"; w = "SafezoneW-SafezoneX"; h = "SafezoneH-SafezoneY"; - + enabled = 0; class VScrollbar { autoScrollSpeed = -1; @@ -315,7 +315,7 @@ class RscInGameUI { }; }; }; - + class ACE_TargetingGate : ACE_TargetingConstrains { idc = 699200; class Controls { @@ -401,8 +401,8 @@ class RscInGameUI { }; }; }; - - + + class ACE_TargetingLines: ACE_TargetingConstrains { idc = 699300; class Controls { @@ -451,4 +451,4 @@ ACE_Titan_TOP_off: 1006 ACE_Titan_DIR: 1007 ACE_Titan_FLTR_mode_off: 1002 ACE_Titan_FLTR_mode: 161 -*/ \ No newline at end of file +*/ diff --git a/addons/kestrel4500/initKeybinds.sqf b/addons/kestrel4500/initKeybinds.sqf index 5793d36976..581ab1a1ae 100644 --- a/addons/kestrel4500/initKeybinds.sqf +++ b/addons/kestrel4500/initKeybinds.sqf @@ -5,7 +5,7 @@ if (GVAR(Kestrel4500)) exitWith { closeDialog 0; false - }; + }; // Statement [] call FUNC(createKestrelDialog); false @@ -17,7 +17,7 @@ { // Conditions: canInteract if !([ACE_player, objNull, ["notOnMap", "isNotInside", "isNotSitting"]] call EFUNC(common,canInteractWith)) exitWith {false}; - + // Statement [] call FUNC(displayKestrel); false @@ -34,7 +34,7 @@ _conditonCode = { _toggleCode = { // Conditions: canInteract if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {}; - + // Statement if (!GVAR(Overlay)) then { //If no overlay, show it: diff --git a/addons/laser/CfgVehicles.hpp b/addons/laser/CfgVehicles.hpp index d8976ac204..780107fdf7 100644 --- a/addons/laser/CfgVehicles.hpp +++ b/addons/laser/CfgVehicles.hpp @@ -6,20 +6,20 @@ class CfgVehicles { model = "\A3\Weapons_F\empty.p3d"; destrType = "DestructNo"; simulation = "LaserTarget"; - + class EventHandlers { init = QUOTE(_this call FUNC(laser_init)); }; }; - + // Visual laserTarget override class ACE_LaserTarget_Visual : LaserTarget { simulation = "LaserTarget"; model = "\A3\Weapons_f\laserTgt.p3d"; }; - + // Vehicle lockable configurations - + class AllVehicles; class Air: AllVehicles { class Turrets; @@ -42,4 +42,4 @@ class CfgVehicles { }; }; }; -}; \ No newline at end of file +}; diff --git a/addons/laser/CfgWeapons.hpp b/addons/laser/CfgWeapons.hpp index 70a25e6f85..6dff36a4e8 100644 --- a/addons/laser/CfgWeapons.hpp +++ b/addons/laser/CfgWeapons.hpp @@ -1,7 +1,6 @@ class CfgWeapons { class Binocular; - class Laserdesignator : Binocular { visionMode[] = {"Normal","NVG"}; }; diff --git a/addons/laser/RscInGameUI.hpp b/addons/laser/RscInGameUI.hpp index d87136c960..08f0a794be 100644 --- a/addons/laser/RscInGameUI.hpp +++ b/addons/laser/RscInGameUI.hpp @@ -8,11 +8,10 @@ class RscInGameUI { class RscOptics_LaserDesignator { idd = 300; controls[] = {"CA_IGUI_elements_group"}; - + onLoad = "uiNameSpace setVariable ['ACE_RscOptics_LaserDesignator',(_this select 0)];"; onUnload = "uiNameSpace setVariable ['ACE_RscOptics_LaserDesignator',nil];"; - - + class CA_IGUI_elements_group: RscControlsGroup { idc = 170; @@ -118,7 +117,7 @@ class RscInGameUI { w = "3.5 * (0.01875 * SafezoneH)"; h = "1.6 * (0.025 * SafezoneH)"; }; - + class ACE_LaserCode_Helper : RscMapControl { idc = -1; onDraw = QUOTE(_this call FUNC(onLaserDesignatorDraw)); @@ -141,4 +140,4 @@ class RscInGameUI { }; }; }; -}; \ No newline at end of file +}; diff --git a/addons/laser/functions/fnc_laserOff.sqf b/addons/laser/functions/fnc_laserOff.sqf index 84613cd988..7899ec1253 100644 --- a/addons/laser/functions/fnc_laserOff.sqf +++ b/addons/laser/functions/fnc_laserOff.sqf @@ -8,7 +8,7 @@ * Return value: * None */ - + #include "script_component.hpp" private ["_uuid"]; diff --git a/addons/laser/functions/fnc_laserTargetPFH.sqf b/addons/laser/functions/fnc_laserTargetPFH.sqf index 6d993b07de..8726ce4201 100644 --- a/addons/laser/functions/fnc_laserTargetPFH.sqf +++ b/addons/laser/functions/fnc_laserTargetPFH.sqf @@ -12,7 +12,7 @@ _uuid = _args select 2; if(isNull _laserTarget || !alive _shooter) exitWith { [(_this select 1)] call CBA_fnc_removePerFrameHandler; REM(GVAR(VanillaLasers), _laserTarget); - + // Remove laseron [_uuid] call FUNC(laserOff); }; @@ -28,4 +28,3 @@ drawIcon3D ["\a3\ui_f\data\IGUI\Cfg\Cursors\select_target_ca.paa", [1,0,0,1], (A } forEach DRAW_LINES; DRAW_LINES = []; #endif - diff --git a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf index 22287f1342..45b60a69c1 100644 --- a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf +++ b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf @@ -62,7 +62,7 @@ _finalOwner = nil; }; }; }; - + //Handle Weird Data Return if (_laser params [["_laserPos", [], [[]], 3], ["_laserDir", [], [[]], 3]]) then { _res = [_laserPos, _laserDir, _divergence] call FUNC(shootCone); diff --git a/addons/main/CfgSettings.hpp b/addons/main/CfgSettings.hpp index 661108c53a..58cb824a6f 100644 --- a/addons/main/CfgSettings.hpp +++ b/addons/main/CfgSettings.hpp @@ -6,7 +6,7 @@ class CfgSettings { class dependencies { //ACE will hard exit if this is missing CBA[] = {"cba_main", REQUIRED_CBA_VERSION, "(true)"}; - + //Warnings for missing RHS compat pbos compat_rhs_afrf3[] = {"ace_compat_rhs_afrf3", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'rhs_main')"}; compat_rhs_usf3[] = {"ace_compat_rhs_usf3", {VERSION_AR}, "isClass (configFile >> 'CfgPatches' >> 'rhsusf_main')"}; diff --git a/addons/map/CfgAmmo.hpp b/addons/map/CfgAmmo.hpp index 9e98d0efea..01cd9427e8 100644 --- a/addons/map/CfgAmmo.hpp +++ b/addons/map/CfgAmmo.hpp @@ -1,21 +1,21 @@ class CfgAmmo { class FlareCore; - + class FlareBase: FlareCore {}; class F_20mm_White: FlareBase {}; - + class ACE_FlashlightProxy_White: F_20mm_White { model = "\A3\Weapons_f\empty"; effectFlare = "FlareShell"; - + triggerTime = 0; intensity = 0.5; flareSize = 1; timeToLive = 10e10; - + lightColor[] = {1,1,1,1}; - + grenadeBurningSound[] = {}; grenadeFireSound[] = {}; soundTrigger[] = {}; @@ -25,24 +25,24 @@ class CfgAmmo { SmokeShellSoundLoop1[] = {}; SmokeShellSoundLoop2[] = {}; }; - + class ACE_FlashlightProxy_Red: ACE_FlashlightProxy_White { intensity = 1; lightColor[] = {1,0,0,1}; }; - + class ACE_FlashlightProxy_Green: ACE_FlashlightProxy_White { intensity = 1; lightColor[] = {0,1,0,1}; }; - + class ACE_FlashlightProxy_Blue: ACE_FlashlightProxy_White { intensity = 1.5; lightColor[] = {0.25,0.25,1,1}; }; - + class ACE_FlashlightProxy_Yellow: ACE_FlashlightProxy_White { intensity = 1; lightColor[] = {1,1,0.5,1}; }; -}; \ No newline at end of file +}; diff --git a/addons/map/XEH_postInitClient.sqf b/addons/map/XEH_postInitClient.sqf index 00e9e737cf..f3b3ba6106 100644 --- a/addons/map/XEH_postInitClient.sqf +++ b/addons/map/XEH_postInitClient.sqf @@ -12,7 +12,7 @@ if (isServer) then { deleteVehicle _x; }; } forEach attachedObjects _disconnectedPlayer; - + nil }]; }; diff --git a/addons/map/functions/fnc_compileFlashlightMenu.sqf b/addons/map/functions/fnc_compileFlashlightMenu.sqf index bc6746f46e..836b483a20 100644 --- a/addons/map/functions/fnc_compileFlashlightMenu.sqf +++ b/addons/map/functions/fnc_compileFlashlightMenu.sqf @@ -30,7 +30,7 @@ _flashlights = [_player] call FUNC(getUnitFlashlights); _cfg = (configFile >> "CfgWeapons" >> _x); _displayName = getText (_cfg >> "displayName"); _icon = getText (_cfg >> "picture"); - + _statement = if (GVAR(flashlightInUse) == _x) then { _displayName = format [localize LSTRING(turnLightOff), _displayName]; {[""] call FUNC(switchFlashlight)} diff --git a/addons/maptools/functions/fnc_calculateMapScale.sqf b/addons/maptools/functions/fnc_calculateMapScale.sqf index 78bfae43af..018edf68d9 100644 --- a/addons/maptools/functions/fnc_calculateMapScale.sqf +++ b/addons/maptools/functions/fnc_calculateMapScale.sqf @@ -14,7 +14,7 @@ private ["_screenOffset", "_pos"]; -_pos = ((findDisplay 12) displayCtrl 51) ctrlMapScreenToWorld [0.5, 0.5]; +_pos = ((findDisplay 12) displayCtrl 51) ctrlMapScreenToWorld [0.5, 0.5]; _screenOffset = ((findDisplay 12) displayCtrl 51) posWorldToScreen [(_pos select 0) + 100, (_pos select 1)]; (_screenOffset select 0) - 0.5 diff --git a/addons/markers/functions/fnc_initInsertMarker.sqf b/addons/markers/functions/fnc_initInsertMarker.sqf index 08c078c4f5..2de05575f7 100644 --- a/addons/markers/functions/fnc_initInsertMarker.sqf +++ b/addons/markers/functions/fnc_initInsertMarker.sqf @@ -22,7 +22,7 @@ disableserialization; params ["_display"]; TRACE_1("params",_display); - + //Can't place markers when can't interact if !([ACE_player, objNull, ["notOnMap", "isNotInside", "isNotSitting"]] call EFUNC(common,canInteractWith)) exitWith { _display closeDisplay 2; //emulate "Cancel" button diff --git a/addons/medical/functions/fnc_translateSelections.sqf b/addons/medical/functions/fnc_translateSelections.sqf index 98a4cf8c51..e6624507d1 100644 --- a/addons/medical/functions/fnc_translateSelections.sqf +++ b/addons/medical/functions/fnc_translateSelections.sqf @@ -46,7 +46,7 @@ if (_hitPointIndex isEqualTo true) exitWith { if (!isNil {_unit getHitPointDamage _returnHitPoint}) exitWith { _returnHitPoint; }; - + //Those VR fuckers have weird limb hitpoints private _hitPoints = switch (_selection) do { case ("hand_l"): {L_ARM_HITPOINTS}; diff --git a/addons/microdagr/functions/fnc_updateDisplay.sqf b/addons/microdagr/functions/fnc_updateDisplay.sqf index 4b609085a8..5042cbac97 100644 --- a/addons/microdagr/functions/fnc_updateDisplay.sqf +++ b/addons/microdagr/functions/fnc_updateDisplay.sqf @@ -171,7 +171,7 @@ case (APP_MODE_WAYPOINTS): { _currentIndex = (_currentIndex max 0) min (count _waypoints); _wpListBox lbSetCurSel _currentIndex; - + //Reset focus to a dummy ctrl (top button), otherwise HOME/POS1 key goes to top of listBox and has keybind blocked ctrlSetFocus (_display displayCtrl IDC_TOPMENUBUTTON); }; @@ -193,7 +193,7 @@ case (APP_MODE_SETUP): { } else { _settingListBox lbSetTextRight [1, (localize LSTRING(settingOff))]; }; - + //Reset focus to a dummy ctrl (top button), otherwise HOME/POS1 key goes to top of listBox and has keybind blocked ctrlSetFocus (_display displayCtrl IDC_TOPMENUBUTTON); }; diff --git a/addons/missileguidance/ACE_GuidanceConfig.hpp b/addons/missileguidance/ACE_GuidanceConfig.hpp index f3434fef9b..96e417a7e8 100644 --- a/addons/missileguidance/ACE_GuidanceConfig.hpp +++ b/addons/missileguidance/ACE_GuidanceConfig.hpp @@ -3,42 +3,42 @@ class GVAR(AttackProfiles) { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(attackProfile_LIN); }; class DIR { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(attackProfile_DIR); }; class MID { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(attackProfile_MID); }; class HI { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(attackProfile_HI); }; class JAV_DIR { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(attackProfile_JAV_DIR); }; class JAV_TOP { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(attackProfile_JAV_TOP); }; }; @@ -48,14 +48,14 @@ class GVAR(SeekerTypes) { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(seekerType_SALH); }; class Optic { name = ""; visualName = ""; description = ""; - + functionName = QFUNC(seekerType_Optic); }; }; diff --git a/addons/missileguidance/CfgMagazines.hpp b/addons/missileguidance/CfgMagazines.hpp index 31f4739417..a7e729cf32 100644 --- a/addons/missileguidance/CfgMagazines.hpp +++ b/addons/missileguidance/CfgMagazines.hpp @@ -1,6 +1,6 @@ class CfgMagazines { class 12Rnd_PG_missiles; - + class 6Rnd_ACE_Hydra70_DAGR : 12Rnd_PG_missiles { ammo = "ACE_Hydra70_DAGR"; count = 12; @@ -8,7 +8,7 @@ class CfgMagazines { displayNameShort = "6 Round DAGR"; descriptionShort = "6 Round DAGR"; weight = 36; - + }; class 12Rnd_ACE_Hydra70_DAGR : 6Rnd_ACE_Hydra70_DAGR { count = 12; @@ -24,7 +24,7 @@ class CfgMagazines { descriptionShort = "24 Round DAGR"; weight = 72; }; - + // Hellfires class 6Rnd_ACE_Hellfire_AGM114K : 12Rnd_PG_missiles { count = 12; @@ -33,7 +33,7 @@ class CfgMagazines { displayNameShort = "6Rnd_ACE_Hellfire_AGM114K"; descriptionShort = "6Rnd_ACE_Hellfire_AGM114K"; weight = 36; - + }; class 12Rnd_ACE_Hellfire_AGM114K : 6Rnd_ACE_Hydra70_DAGR { count = 12; @@ -49,5 +49,5 @@ class CfgMagazines { descriptionShort = "24Rnd_ACE_Hellfire_AGM114K"; weight = 72; }; - -}; \ No newline at end of file + +}; diff --git a/addons/missileguidance/CfgVehicles.hpp b/addons/missileguidance/CfgVehicles.hpp index 5069556078..16b4b87767 100644 --- a/addons/missileguidance/CfgVehicles.hpp +++ b/addons/missileguidance/CfgVehicles.hpp @@ -17,7 +17,7 @@ class CfgVehicles { class MainTurret; }; }; - + class ACE_Comanche_Test : B_Heli_Attack_01_F { scope = 1; scopeCurator = 0; @@ -32,5 +32,5 @@ class CfgVehicles { }; }; }; - + }; diff --git a/addons/missileguidance/functions/fnc_doAttackProfile.sqf b/addons/missileguidance/functions/fnc_doAttackProfile.sqf index b9a3502035..171e169651 100644 --- a/addons/missileguidance/functions/fnc_doAttackProfile.sqf +++ b/addons/missileguidance/functions/fnc_doAttackProfile.sqf @@ -15,7 +15,7 @@ for [{_i=0}, {_i< (count _attackProfilesCfg) }, {_i=_i+1}] do { _testProfile = _attackProfilesCfg select _i; _testName = configName _testProfile; TRACE_3("", _testName, _testProfile, _attackProfilesCfg); - + if( _testName == _attackProfileName) exitWith { _attackProfile = _attackProfilesCfg select _i; }; @@ -26,4 +26,4 @@ if(!isNil "_attackProfile") then { _attackProfilePos = _this call (missionNamespace getVariable (getText (_attackProfile >> "functionName"))); }; -_attackProfilePos; \ No newline at end of file +_attackProfilePos; diff --git a/addons/missileguidance/functions/fnc_doSeekerSearch.sqf b/addons/missileguidance/functions/fnc_doSeekerSearch.sqf index 081ab16353..bd300effe8 100644 --- a/addons/missileguidance/functions/fnc_doSeekerSearch.sqf +++ b/addons/missileguidance/functions/fnc_doSeekerSearch.sqf @@ -16,7 +16,7 @@ for [{_i=0}, {_i< (count _seekerTypesCfg) }, {_i=_i+1}] do { _testProfile = _seekerTypesCfg select _i; _testName = configName _testProfile; TRACE_3("", _testName, _testProfile, _seekerTypesCfg); - + if( _testName == _seekerTypeName) exitWith { _seekerType = _seekerTypesCfg select _i; }; @@ -27,4 +27,4 @@ if(!isNil "_seekerType") then { _seekerProfilePos = _this call (missionNamespace getVariable (getText (_seekerType >> "functionName"))); }; -_seekerProfilePos; \ No newline at end of file +_seekerProfilePos; diff --git a/addons/missileguidance/functions/fnc_onFired.sqf b/addons/missileguidance/functions/fnc_onFired.sqf index 7fc77fdd56..26f8d14c6e 100644 --- a/addons/missileguidance/functions/fnc_onFired.sqf +++ b/addons/missileguidance/functions/fnc_onFired.sqf @@ -11,7 +11,7 @@ if(GVAR(enabled) < 1 || {!local _projectile} ) exitWith { false }; if( !isPlayer _shooter && { GVAR(enabled) < 2 } ) exitWith { false }; // Bail on not missile -if(! (_ammo isKindOf "MissileBase") ) exitWith { false }; +if(! (_ammo isKindOf "MissileBase") ) exitWith { false }; private["_config", "_configs", "_enabled", "_target", "_seekerType", "_attackProfile"]; private["_args", "_canUseLock", "_guidingUnit", "_launchPos", "_lockMode", "_targetPos", "_vanillaTarget"]; @@ -30,7 +30,7 @@ _target = (vehicle _shooter) getVariable [QGVAR(target), nil]; _targetPos = (vehicle _shooter) getVariable [QGVAR(targetPosition), nil]; _seekerType = (vehicle _shooter) getVariable [QGVAR(seekerType), nil]; _attackProfile = (vehicle _shooter) getVariable [QGVAR(attackProfile), nil]; -_lockMode = (vehicle _shooter) getVariable [QGVAR(lockMode), nil]; +_lockMode = (vehicle _shooter) getVariable [QGVAR(lockMode), nil]; // @TODO: make this vehicle shooter, but we need to differentiate where its set in ace_laser _laserCode = _shooter getVariable [QEGVAR(laser,code), ACE_DEFAULT_LASER_CODE]; @@ -40,14 +40,14 @@ _launchPos = getPosASL (vehicle _shooter); TRACE_3("Begin guidance", _target, _seekerType, _attackProfile); -if ( isNil "_seekerType" || { ! ( _seekerType in (getArray (_config >> "seekerTypes" ) ) ) } ) then { +if (isNil "_seekerType" || {!(_seekerType in (getArray (_config >> "seekerTypes")))}) then { _seekerType = getText (_config >> "defaultSeekerType"); -}; -if ( isNil "_attackProfile" || { ! ( _attackProfile in (getArray (_config >> "attackProfiles" ) ) ) } ) then { - _attackProfile = getText (_config >> "defaultAttackProfile"); }; -if ( isNil "_lockMode" || { ! ( _lockMode in (getArray (_config >> "seekerLockModes" ) ) ) } ) then { - _lockMode = getText (_config >> "defaultSeekerLockMode"); +if (isNil "_attackProfile" || {!(_attackProfile in (getArray (_config >> "attackProfiles")))}) then { + _attackProfile = getText (_config >> "defaultAttackProfile"); +}; +if (isNil "_lockMode" || {!(_lockMode in (getArray (_config >> "seekerLockModes")))}) then { + _lockMode = getText (_config >> "defaultSeekerLockMode"); }; // If we didn't get a target, try to fall back on tab locking @@ -61,7 +61,7 @@ if(isNil "_target") then { // @TODO: Get vanilla target if(_canUseLock > 0 || difficulty < 1) then { _vanillaTarget = cursorTarget; - + TRACE_1("Using Vanilla Locking", _vanillaTarget); if(!isNil "_vanillaTarget") then { _target = _vanillaTarget; @@ -71,14 +71,14 @@ if(isNil "_target") then { }; TRACE_4("Beginning ACE guidance system",_target,_ammo,_seekerType,_attackProfile); -_args = [_this, - [_shooter, - [_target, _targetPos, _launchPos], - _seekerType, +_args = [_this, + [_shooter, + [_target, _targetPos, _launchPos], + _seekerType, _attackProfile, _lockMode, _laserInfo - ], + ], [ getNumber ( _config >> "minDeflection" ), getNumber ( _config >> "maxDeflection" ), @@ -91,7 +91,7 @@ _args = [_this, ], [ ACE_diagTime, [], [] ] ]; - + // Hand off to the guiding unit. We just use local player so local PFH fires for now // Laser code needs to give us a shooter for LOBL, or the seeker unit needs to be able to shift locality // Based on its homing laser @@ -115,4 +115,4 @@ _args = [_this, (vehicle _shooter) setVariable [QGVAR(seekerType), nil]; (vehicle _shooter) setVariable [QGVAR(attackProfile), nil]; (vehicle _shooter) setVariable [QGVAR(lockMode), nil]; -*/ \ No newline at end of file +*/ diff --git a/addons/modules/XEH_postInit.sqf b/addons/modules/XEH_postInit.sqf index 0b8cc67842..8f0c430db2 100644 --- a/addons/modules/XEH_postInit.sqf +++ b/addons/modules/XEH_postInit.sqf @@ -4,7 +4,7 @@ ["InitSettingsFromModules", { // TODO This is a basic and limited implementation that mimics some of the functionality from the A3 module framework, but not all of it. // We have to execute this in the postInit XEH because on object init, the parameters of the modules are not yet available. They are if we execute it at the start of postInit execution. - + private _uniqueModulesHandled = []; { [_x] call { @@ -28,8 +28,8 @@ }; if (_isSingular && {_logicType in _uniqueModulesHandled}) then { //ToDo: should this be an exit? ACE_LOGWARNING_1("Module [%1] - More than 1 singular module placed", _logicType); - }; - if (_isSingular) then {_uniqueModulesHandled pushBack _logicType;}; + }; + if (_isSingular) then {_uniqueModulesHandled pushBack _logicType;}; if (_isGlobal || isServer) then { [_logic, (synchronizedObjects _logic), true] call _function; @@ -44,7 +44,7 @@ }; }; } forEach GVAR(moduleInitCollection); - + if (isServer) then { GVAR(serverModulesRead) = true; publicVariable QGVAR(serverModulesRead); diff --git a/addons/nametags/functions/fnc_doShow.sqf b/addons/nametags/functions/fnc_doShow.sqf index 615916de7f..18c434f4c6 100644 --- a/addons/nametags/functions/fnc_doShow.sqf +++ b/addons/nametags/functions/fnc_doShow.sqf @@ -35,16 +35,16 @@ _turretRoles = _data apply {_x select 1}; _roleType = CARGO; _toShow = []; { - switch (_x) do { + switch (_x) do { case commander _vehicle: { _roleType = COMMANDER; }; case gunner _vehicle: { _roleType = GUNNER; - }; - case driver _vehicle: { + }; + case driver _vehicle: { _roleType = if(_isAir) then { PILOT } else { DRIVER }; - }; + }; default { _index = _turretUnits find _x; if(_index !=-1 ) then { @@ -61,7 +61,7 @@ _toShow = [ _toShow, [], { - _x select 1 + _x select 1 }, "ASCEND", { @@ -71,7 +71,7 @@ _toShow = [ ] call BIS_fnc_sortBy; _roleImages = ROLE_IMAGES; -{ +{ _unit = _x select 0; _roleType = _x select 1; _text = _text + format["%1
", [_unit] call EFUNC(common,getName), _roleImages select _roleType]; diff --git a/addons/nightvision/XEH_postInitClient.sqf b/addons/nightvision/XEH_postInitClient.sqf index 17cb92f9cc..5a6714a374 100644 --- a/addons/nightvision/XEH_postInitClient.sqf +++ b/addons/nightvision/XEH_postInitClient.sqf @@ -29,18 +29,18 @@ GVAR(ppEffectMuzzleFlash) ppEffectAdjust [1, 1, 0, [0, 0, 0, 0], [0, 0, 0, 1], [ GVAR(ppEffectMuzzleFlash) ppEffectCommit 0; // Setup the event handlers -["playerInventoryChanged", {_this call FUNC(updatePPEffects)}] call EFUNC(common,addEventHandler); +["playerInventoryChanged", {_this call FUNC(updatePPEffects)}] call EFUNC(common,addEventHandler); ["playerVisionModeChanged", { _this call FUNC(updatePPEffects); _this call FUNC(onVisionModeChanged); }] call EFUNC(common,addEventHandler); -["cameraViewChanged", { +["cameraViewChanged", { _this call FUNC(updatePPEffects); _this call FUNC(onCameraViewChanged); }] call EFUNC(common,addEventHandler); -["playerVehicleChanged", {_this call FUNC(updatePPEffects)}] call EFUNC(common,addEventHandler); -["playerTurretChanged", {_this call FUNC(updatePPEffects)}] call EFUNC(common,addEventHandler); +["playerVehicleChanged", {_this call FUNC(updatePPEffects)}] call EFUNC(common,addEventHandler); +["playerTurretChanged", {_this call FUNC(updatePPEffects)}] call EFUNC(common,addEventHandler); // Add keybinds ["ACE3 Equipment", QGVAR(IncreaseNVGBrightness), localize LSTRING(IncreaseNVGBrightness), diff --git a/addons/overpressure/functions/fnc_getDistance.sqf b/addons/overpressure/functions/fnc_getDistance.sqf index 341da388ca..616feb8660 100644 --- a/addons/overpressure/functions/fnc_getDistance.sqf +++ b/addons/overpressure/functions/fnc_getDistance.sqf @@ -30,7 +30,7 @@ private _distance = 999; { _x params ["_intersectPosASL", "_surfaceNormal", "_intersectObject"]; TRACE_3("Intersect",_intersectPosASL,_surfaceNormal,_intersectObject); - + //Hit something solid that can reflect - (Static covers Building) [Need to manually filter out _shoot for FFV shots] if ((isNull _intersectObject) || {(_intersectObject != _shooter) && {(_intersectObject isKindOf "Static") || {_intersectObject isKindOf "AllVehicles"}}}) exitWith { _distance = _posASL vectorDistance _intersectPosASL; diff --git a/addons/rangecard/RscTitles.hpp b/addons/rangecard/RscTitles.hpp index c4da1862ca..bc4101c483 100644 --- a/addons/rangecard/RscTitles.hpp +++ b/addons/rangecard/RscTitles.hpp @@ -64,7 +64,7 @@ class ACE_RangeCard_Dialog { onLoad = "uiNamespace setVariable ['RangleCard_Display', (_this select 0)]"; onUnload = QUOTE(_this call FUNC(onCloseDialog)); objects[] = {}; - + class controls { class BACKGROUND { moving=1; diff --git a/addons/rangecard/functions/fnc_calculateSolution.sqf b/addons/rangecard/functions/fnc_calculateSolution.sqf index ea86d9986e..e1659016bb 100644 --- a/addons/rangecard/functions/fnc_calculateSolution.sqf +++ b/addons/rangecard/functions/fnc_calculateSolution.sqf @@ -45,33 +45,8 @@ * Public: No */ #include "script_component.hpp" - -private ["_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed1", "_windSpeed2", "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_drag", "_bc", "_dragModel", "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", "_directionOfFire", "_rangeCardSlot", "_useABConfig"]; -_scopeBaseAngle = _this select 0; -_bulletMass = _this select 1; -_boreHeight = _this select 2; -_airFriction = _this select 3; -_muzzleVelocity = _this select 4; -_temperature = _this select 5; -_barometricPressure = _this select 6; -_relativeHumidity = _this select 7; -_simSteps = _this select 8; -_windSpeed1 = (_this select 9) select 0; -_windSpeed2 = (_this select 9) select 1; -_windDirection = _this select 10; -_inclinationAngle = _this select 11; -_targetSpeed = _this select 12; -_targetRange = _this select 13; -_bc = _this select 14; -_dragModel = _this select 15; -_atmosphereModel = _this select 16; -_storeRangeCardData = _this select 17; -_stabilityFactor = _this select 18; -_twistDirection = _this select 19; -_latitude = _this select 20; -_directionOfFire = _this select 21; -_rangeCardSlot = _this select 22; -_useABConfig = _this select 23; +params ["_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed", "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_bc", "_dragModel", "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", "_directionOfFire", "_rangeCardSlot", "_useABConfig"]; +_windSpeed params ["_windSpeed1", "_windSpeed2"]; if (_storeRangeCardData) then { GVAR(rangeCardDataMVs) set [_rangeCardSlot, format[" %1", round(_muzzleVelocity)]]; @@ -138,19 +113,19 @@ _bulletVelocity set [2, Sin(_scopeBaseAngle) * _muzzleVelocity]; while {_TOF < 6 && (_bulletPos select 1) < _targetRange} do { _bulletSpeed = vectorMagnitude _bulletVelocity; - + _speedTotal = _speedTotal + _bulletSpeed; _stepsTotal = _stepsTotal + 1; _speedAverage = (_speedTotal / _stepsTotal); - + if (_speedAverage > 450 && _bulletSpeed < _speedOfSound) exitWith {}; if (atan((_bulletPos select 2) / (abs(_bulletPos select 1) + 1)) < -2.254) exitWith {}; - + _trueVelocity = _bulletVelocity vectorDiff _wind1; _trueSpeed = vectorMagnitude _trueVelocity; - + if (_useABConfig) then { - _drag = if (missionNamespace getVariable [QEGVAR(advanced_ballistics,extensionAvailable), false]) then { + private _drag = if (missionNamespace getVariable [QEGVAR(advanced_ballistics,extensionAvailable), false]) then { parseNumber(("ace_advanced_ballistics" callExtension format["retard:%1:%2:%3", _dragModel, _bc, _trueSpeed])) } else { ([_dragModel, _bc, _trueSpeed] call EFUNC(advanced_ballistics,calculateRetardation)) @@ -215,4 +190,4 @@ if (_targetRange != 0) then { _kineticEnergy = 0.5 * (_bulletMass / 1000 * (_bulletSpeed ^ 2)); _kineticEnergy = _kineticEnergy * 0.737562149; -[_elevation * 60, [_windage1 * 60, _windage2 * 60], _lead, _TOF, _bulletSpeed, _kineticEnergy, _verticalCoriolis * 60, _horizontalCoriolis * 60, _spinDrift * 60] \ No newline at end of file +[_elevation * 60, [_windage1 * 60, _windage2 * 60], _lead, _TOF, _bulletSpeed, _kineticEnergy, _verticalCoriolis * 60, _horizontalCoriolis * 60, _spinDrift * 60] diff --git a/addons/rangecard/functions/fnc_openRangeCard.sqf b/addons/rangecard/functions/fnc_openRangeCard.sqf index 3e886eb97a..ea085ed5b1 100644 --- a/addons/rangecard/functions/fnc_openRangeCard.sqf +++ b/addons/rangecard/functions/fnc_openRangeCard.sqf @@ -20,17 +20,17 @@ if (GVAR(RangeCardOpened)) exitWith {}; if (_this) then { if (GVAR(ammoClassCopy) != "" && GVAR(magazineClassCopy) != "" && GVAR(weaponClassCopy) != "") then { GVAR(RangeCardOpened) = true; - + createDialog "ACE_RangeCard_Dialog"; - + [GVAR(ammoClassCopy), GVAR(magazineClassCopy), GVAR(weaponClassCopy)] call FUNC(updateRangeCard); }; } else { if (ACE_player call FUNC(updateClassNames)) then { GVAR(RangeCardOpened) = true; - + createDialog "ACE_RangeCard_Dialog"; - + [GVAR(ammoClass), GVAR(magazineClass), GVAR(weaponClass)] call FUNC(updateRangeCard); }; }; diff --git a/addons/rangecard/functions/fnc_updateRangeCard.sqf b/addons/rangecard/functions/fnc_updateRangeCard.sqf index 04317d46d7..a7b0b996e2 100644 --- a/addons/rangecard/functions/fnc_updateRangeCard.sqf +++ b/addons/rangecard/functions/fnc_updateRangeCard.sqf @@ -107,7 +107,7 @@ _dragModel = _ammoConfig select 5; _atmosphereModel = _ammoConfig select 8; _bulletMass = 5; _boreHeight = 3.81; -_zeroRange = 100; +_zeroRange = 100; if (_bc == 0) then { _useABConfig = false; @@ -169,13 +169,13 @@ if (isNil {_cacheEntry}) then { { _mvShift = [_ammoConfig select 9, _x] call EFUNC(advanced_ballistics,calculateAmmoTemperatureVelocityShift); _mv = _muzzleVelocity + _mvShift; - + [_scopeBaseAngle,_bulletMass,_boreHeight,_airFriction,_mv,_x,_barometricPressure,_relativeHumidity,1000,[4,0],3,0,1,GVAR(rangeCardEndRange),_bc,_dragModel,_atmosphereModel,true,1.5,1,46,23,_forEachIndex,_useABConfig] call FUNC(calculateSolution); } forEach [-15, -5, 5, 10, 15, 20, 25, 30, 35]; - } else { + } else { [_scopeBaseAngle,_bulletMass,_boreHeight,_airFriction,_muzzleVelocity,15,_barometricPressure,_relativeHumidity,1000,[4,0],3,0,1,GVAR(rangeCardEndRange),_bc,_dragModel,_atmosphereModel,true,1.5,1,46,23,3,_useABConfig] call FUNC(calculateSolution); }; - + for "_i" from 0 to 9 do { GVAR(lastValidRow) pushBack count (GVAR(rangeCardDataElevation) select _i); while {count (GVAR(rangeCardDataElevation) select _i) < 50} do { @@ -190,7 +190,7 @@ if (isNil {_cacheEntry}) then { }; }; }; - + missionNamespace setVariable [format[QGVAR(%1_%2_%3), _ammoClass, _weaponClass, missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]], [GVAR(rangeCardDataElevation), GVAR(rangeCardDataWindage), GVAR(rangeCardDataLead), GVAR(rangeCardDataMVs), GVAR(lastValidRow)]]; } else { GVAR(rangeCardDataElevation) = _cacheEntry select 0; @@ -246,4 +246,4 @@ if (_useABConfig) then { } else { ctrlSetText [770020, ""]; ctrlSetText [770021, ""]; -}; \ No newline at end of file +}; diff --git a/addons/realisticnames/CfgVehicles.hpp b/addons/realisticnames/CfgVehicles.hpp index 4ecbbe1b89..db42e693bf 100644 --- a/addons/realisticnames/CfgVehicles.hpp +++ b/addons/realisticnames/CfgVehicles.hpp @@ -636,11 +636,11 @@ class CfgVehicles { class Weapon_MMG_02_sand_F: Weapon_Base_F { displayName = CSTRING(MMG_02_sand); };*/ - + //attachments - + class Item_Base_F; - + class Item_acc_flashlight: Item_Base_F { displayName="UTG Defender 126"; }; diff --git a/addons/repair/ACE_Repair.hpp b/addons/repair/ACE_Repair.hpp index d47773cd83..6e5eac4fa8 100644 --- a/addons/repair/ACE_Repair.hpp +++ b/addons/repair/ACE_Repair.hpp @@ -12,7 +12,7 @@ class ACE_Repair { condition = QUOTE(call FUNC(canReplaceWheel)); itemConsumed = 0; claimObjects[] = {{"ACE_Wheel"}}; - + callbackSuccess = QUOTE(call FUNC(doReplaceWheel)); callbackFailure = ""; callbackProgress = ""; diff --git a/addons/sandbag/CfgWeapons.hpp b/addons/sandbag/CfgWeapons.hpp index 1a26fc78d4..5f8ef61315 100644 --- a/addons/sandbag/CfgWeapons.hpp +++ b/addons/sandbag/CfgWeapons.hpp @@ -9,7 +9,7 @@ class CfgWeapons { displayName = CSTRING(sandbagEmpty_displayName); model = PATHTOF(data\ace_sandbag_m.p3d); picture = PATHTOF(data\m_sandbag_ca.paa); - + class ItemInfo: InventoryItem_Base_F { mass = 8; }; @@ -21,7 +21,7 @@ class CfgWeapons { displayName = CSTRING(sandbag_displayName); model = PATHTOF(data\ace_sandbag_build.p3d); picture = PATHTOF(data\m_sandbag_ca.paa); - + class ItemInfo: InventoryItem_Base_F { mass = 160; }; diff --git a/addons/scopes/CfgWeapons.hpp b/addons/scopes/CfgWeapons.hpp index 442d4c39d0..eb1d8400a2 100644 --- a/addons/scopes/CfgWeapons.hpp +++ b/addons/scopes/CfgWeapons.hpp @@ -1,7 +1,7 @@ class CfgWeapons { class ItemCore; class InventoryOpticsItem_Base_F; - + class optic_LRPS : ItemCore { ACE_ScopeAdjust_Vertical[] = { -4, 30 }; ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; @@ -46,7 +46,7 @@ class CfgWeapons { }; }; }; - + class optic_AMS_base : ItemCore { ACE_ScopeAdjust_Vertical[] = { -4, 30 }; ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; @@ -61,7 +61,7 @@ class CfgWeapons { }; }; }; - + class optic_KHS_base : ItemCore { ACE_ScopeAdjust_Vertical[] = { -4, 30 }; ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; @@ -76,7 +76,7 @@ class CfgWeapons { }; }; }; - + class optic_KHS_old : ItemCore { ACE_ScopeAdjust_Vertical[] = { -4, 30 }; ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; diff --git a/addons/scopes/functions/fnc_adjustScope.sqf b/addons/scopes/functions/fnc_adjustScope.sqf index 50ee1a4f71..5b0c6d11a6 100644 --- a/addons/scopes/functions/fnc_adjustScope.sqf +++ b/addons/scopes/functions/fnc_adjustScope.sqf @@ -47,7 +47,7 @@ if ((count _maxHorizontal < 2) || (count _maxVertical < 2)) exitWith {false}; if ((_verticalIncrement == 0) && (_turretAndDirection in [ELEVATION_UP, ELEVATION_DOWN])) exitWith {false}; if ((_horizontalIncrement == 0) && (_turretAndDirection in [WINDAGE_UP, WINDAGE_DOWN])) exitWith {false}; -_zeroing = _adjustment select _weaponIndex; +_zeroing = _adjustment select _weaponIndex; _zeroing params ["_elevation", "_windage", "_zero"]; switch (_turretAndDirection) do { diff --git a/addons/sitting/XEH_clientInit.sqf b/addons/sitting/XEH_clientInit.sqf index a167e0fea5..e15017d715 100644 --- a/addons/sitting/XEH_clientInit.sqf +++ b/addons/sitting/XEH_clientInit.sqf @@ -5,7 +5,7 @@ if (!hasInterface) exitWith {}; ["SettingsInitialized", { TRACE_1("SettingInit", GVAR(enable)); - + //If not enabled, then do not add CanInteractWith Condition or event handlers: if (!GVAR(enable)) exitWith {}; diff --git a/addons/spottingscope/CfgWeapons.hpp b/addons/spottingscope/CfgWeapons.hpp index 9b5825572b..3b550f9f5d 100644 --- a/addons/spottingscope/CfgWeapons.hpp +++ b/addons/spottingscope/CfgWeapons.hpp @@ -2,14 +2,14 @@ class CfgWeapons { class ACE_ItemCore; class InventoryItem_Base_F; - + class ACE_SpottingScope: ACE_ItemCore { scope = 2; displayName = CSTRING(DisplayName); descriptionShort = ""; picture = PATHTOF(UI\w_spottingscope_ca.paa); model = PATHTOF(data\ace_spottingscope.p3d); - + class ItemInfo: InventoryItem_Base_F { mass = 40; }; diff --git a/addons/switchunits/functions/fnc_markAiOnMap.sqf b/addons/switchunits/functions/fnc_markAiOnMap.sqf index d29e75b6a4..5d7eac6f1a 100644 --- a/addons/switchunits/functions/fnc_markAiOnMap.sqf +++ b/addons/switchunits/functions/fnc_markAiOnMap.sqf @@ -37,7 +37,7 @@ GVAR(AllMarkerNames) = []; // create markers { if (([_x] call FUNC(isValidAi) && (side group _x in _sides)) || (_x getVariable [QGVAR(IsPlayerControlled), false])) then { - + private _markerName = str _x; private _marker = createMarkerLocal [_markerName, position _x]; diff --git a/addons/tripod/CfgWeapons.hpp b/addons/tripod/CfgWeapons.hpp index adc14912c2..6322ef1906 100644 --- a/addons/tripod/CfgWeapons.hpp +++ b/addons/tripod/CfgWeapons.hpp @@ -1,7 +1,7 @@ class CfgWeapons { class ACE_ItemCore; class InventoryItem_Base_F; - + class ACE_Tripod: ACE_ItemCore { author[] = {"Rocko", "Scubaman3D"}; scope = 2; @@ -9,7 +9,7 @@ class CfgWeapons { descriptionShort = ""; model = PATHTOF(data\w_sniper_tripod.p3d); picture = PATHTOF(UI\w_sniper_tripod_ca.paa); - + class ItemInfo: InventoryItem_Base_F { mass = 40; }; diff --git a/addons/weaponselect/XEH_preInit.sqf b/addons/weaponselect/XEH_preInit.sqf index b457e10cad..4166247505 100644 --- a/addons/weaponselect/XEH_preInit.sqf +++ b/addons/weaponselect/XEH_preInit.sqf @@ -5,8 +5,8 @@ ADDON = false; #include "XEH_PREP.hpp" // collect frag and other grenades separately -GVAR(GrenadesAll) = []; -GVAR(GrenadesFrag) = []; +GVAR(GrenadesAll) = []; +GVAR(GrenadesFrag) = []; GVAR(GrenadesNonFrag) = []; { diff --git a/addons/weather/functions/fnc_getMapData.sqf b/addons/weather/functions/fnc_getMapData.sqf index b344ad2bdf..e1b56f2ed2 100644 --- a/addons/weather/functions/fnc_getMapData.sqf +++ b/addons/weather/functions/fnc_getMapData.sqf @@ -17,24 +17,26 @@ // Assume default wind values // Source: https://weatherspark.com/averages/32194/Lemnos-Limnos-North-Aegean-Islands-Greece -GVAR(WindSpeedMax) = [[8.8, 5.5], [8.8, 5], [8.6, 4.8], [7.6, 3.4], [7.0, 3.0], [7.1, 3.0], [7.5, 3.1], [8.0, 3.2], [7.6, 3.5], [7.8, 4.6], [7.9, 5.0], [8.2, 5.5]]; +GVAR(WindSpeedMax) = [[8.8, 5.5], [8.8, 5], [8.6, 4.8], [7.6, 3.4], [7.0, 3.0], [7.1, 3.0], [7.5, 3.1], [8.0, 3.2], [7.6, 3.5], [7.8, 4.6], [7.9, 5.0], [8.2, 5.5]]; GVAR(WindSpeedMean) = [4.8, 4.9, 4.6, 4.1, 3.5, 3.5, 4.3, 4.4, 4.1, 4.5, 4.5, 5.0]; -GVAR(WindSpeedMin) = [[0.2, 5.0], [0.1, 5.0], [0.2, 4.3], [0.0, 3.0], [0.0, 2.1], [0.0, 2.0], [0.1, 3.1], [0.3, 3.1], [0.0, 3.6], [0.0, 4.2], [0.1, 5.0], [0.2, 5.5]]; -GVAR(WindDirectionProbabilities) = [[0.06, 0.32, 0.05, 0.04, 0.15, 0.06, 0.02, 0.02], // January - [0.08, 0.32, 0.04, 0.04, 0.18, 0.06, 0.02, 0.02], // February - [0.09, 0.30, 0.04, 0.04, 0.20, 0.06, 0.02, 0.03], // March - [0.10, 0.25, 0.03, 0.04, 0.22, 0.06, 0.02, 0.04], // April - [0.18, 0.25, 0.03, 0.04, 0.18, 0.04, 0.01, 0.05], // May - [0.25, 0.25, 0.03, 0.03, 0.15, 0.03, 0.00, 0.08], // June - [0.32, 0.30, 0.02, 0.02, 0.10, 0.01, 0.00, 0.09], // July - [0.28, 0.35, 0.02, 0.01, 0.08, 0.01, 0.00, 0.08], // August - [0.20, 0.37, 0.03, 0.01, 0.11, 0.01, 0.01, 0.05], // September - [0.10, 0.39, 0.04, 0.02, 0.15, 0.02, 0.01, 0.03], // October - [0.08, 0.38, 0.06, 0.04, 0.19, 0.03, 0.02, 0.02], // November - [0.06, 0.37, 0.05, 0.03, 0.18, 0.04, 0.02, 0.02]];// December - +GVAR(WindSpeedMin) = [[0.2, 5.0], [0.1, 5.0], [0.2, 4.3], [0.0, 3.0], [0.0, 2.1], [0.0, 2.0], [0.1, 3.1], [0.3, 3.1], [0.0, 3.6], [0.0, 4.2], [0.1, 5.0], [0.2, 5.5]]; +GVAR(WindDirectionProbabilities) = [ + [0.06, 0.32, 0.05, 0.04, 0.15, 0.06, 0.02, 0.02], // January + [0.08, 0.32, 0.04, 0.04, 0.18, 0.06, 0.02, 0.02], // February + [0.09, 0.30, 0.04, 0.04, 0.20, 0.06, 0.02, 0.03], // March + [0.10, 0.25, 0.03, 0.04, 0.22, 0.06, 0.02, 0.04], // April + [0.18, 0.25, 0.03, 0.04, 0.18, 0.04, 0.01, 0.05], // May + [0.25, 0.25, 0.03, 0.03, 0.15, 0.03, 0.00, 0.08], // June + [0.32, 0.30, 0.02, 0.02, 0.10, 0.01, 0.00, 0.09], // July + [0.28, 0.35, 0.02, 0.01, 0.08, 0.01, 0.00, 0.08], // August + [0.20, 0.37, 0.03, 0.01, 0.11, 0.01, 0.01, 0.05], // September + [0.10, 0.39, 0.04, 0.02, 0.15, 0.02, 0.01, 0.03], // October + [0.08, 0.38, 0.06, 0.04, 0.19, 0.03, 0.02, 0.02], // November + [0.06, 0.37, 0.05, 0.03, 0.18, 0.04, 0.02, 0.02] // December +]; + // Check if the wind data is defined in the map config -if (isArray (configFile >> "CfgWorlds" >> worldName >> "ACE_WindSpeedMean")) then { +if (isArray (configFile >> "CfgWorlds" >> worldName >> "ACE_WindSpeedMean")) then { GVAR(WindSpeedMin) = getArray (configFile >> "CfgWorlds" >> worldName >> "ACE_WindSpeedMin"); GVAR(WindSpeedMean) = getArray (configFile >> "CfgWorlds" >> worldName >> "ACE_WindSpeedMean"); GVAR(WindSpeedMax) = getArray (configFile >> "CfgWorlds" >> worldName >> "ACE_WindSpeedMax"); @@ -55,23 +57,25 @@ if (toLower worldName in ["chernarus", "bootcamp_acr", "woodland_acr", "utes"]) GVAR(TempNight) = [-4, -3, 0, 4, 9, 12, 14, 14, 10, 6, 2, -2]; // Source: http://www.weather-and-climate.com/average-monthly-Humidity-perc,Prague,Czech-Republic GVAR(Humidity) = [82, 80, 78, 70, 71, 72, 70, 73, 78, 80, 83, 82]; - + // Source: https://weatherspark.com/averages/32335/Prague-Central-Bohemia-Czech-Republic GVAR(WindSpeedMax) = [[6.7, 2.4], [6.8, 2.2], [7.1, 2.0], [6.7, 1.9], [6.5, 1.8], [6.4, 1.8], [6.4, 1.8], [5.9, 1.9], [5.8, 2.1], [5.9, 2.3], [6.4, 2.8], [7.0, 3.0]]; GVAR(WindSpeedMean) = [4.5, 4.3, 4.4, 4.1, 3.6, 3.6, 3.6, 3.4, 3.6, 0, 4.1, 4.6]; GVAR(WindSpeedMin) = [[1.5, 1.1], [1.5, 1.1], [1.5, 1.0], [1.2, 0.9], [1.1, 0.8], [1.0, 0.8], [1.0, 1.0], [1.0, 0.9], [1.1, 1.0], [1.0, 1.0], [1.3, 1.1], [1.8, 1.2]]; - GVAR(WindDirectionProbabilities) = [[0.06, 0.02, 0.06, 0.06, 0.10, 0.23, 0.15, 0.06], // January - [0.08, 0.03, 0.08, 0.06, 0.08, 0.18, 0.15, 0.08], // February - [0.08, 0.02, 0.10, 0.06, 0.07, 0.17, 0.15, 0.08], // March - [0.12, 0.04, 0.10, 0.05, 0.06, 0.12, 0.13, 0.10], // April - [0.12, 0.05, 0.09, 0.05, 0.05, 0.10, 0.13, 0.10], // May - [0.12, 0.04, 0.06, 0.03, 0.05, 0.13, 0.16, 0.10], // June - [0.09, 0.03, 0.07, 0.04, 0.06, 0.16, 0.18, 0.10], // July - [0.09, 0.03, 0.08, 0.04, 0.06, 0.15, 0.16, 0.09], // August - [0.07, 0.03, 0.08, 0.06, 0.08, 0.18, 0.15, 0.08], // September - [0.06, 0.03, 0.10, 0.07, 0.10, 0.19, 0.13, 0.05], // October - [0.06, 0.02, 0.08, 0.07, 0.10, 0.15, 0.13, 0.05], // November - [0.06, 0.02, 0.06, 0.06, 0.10, 0.24, 0.15, 0.05]];// December + GVAR(WindDirectionProbabilities) = [ + [0.06, 0.02, 0.06, 0.06, 0.10, 0.23, 0.15, 0.06], // January + [0.08, 0.03, 0.08, 0.06, 0.08, 0.18, 0.15, 0.08], // February + [0.08, 0.02, 0.10, 0.06, 0.07, 0.17, 0.15, 0.08], // March + [0.12, 0.04, 0.10, 0.05, 0.06, 0.12, 0.13, 0.10], // April + [0.12, 0.05, 0.09, 0.05, 0.05, 0.10, 0.13, 0.10], // May + [0.12, 0.04, 0.06, 0.03, 0.05, 0.13, 0.16, 0.10], // June + [0.09, 0.03, 0.07, 0.04, 0.06, 0.16, 0.18, 0.10], // July + [0.09, 0.03, 0.08, 0.04, 0.06, 0.15, 0.16, 0.09], // August + [0.07, 0.03, 0.08, 0.06, 0.08, 0.18, 0.15, 0.08], // September + [0.06, 0.03, 0.10, 0.07, 0.10, 0.19, 0.13, 0.05], // October + [0.06, 0.02, 0.08, 0.07, 0.10, 0.15, 0.13, 0.05], // November + [0.06, 0.02, 0.06, 0.06, 0.10, 0.24, 0.15, 0.05] // December + ]; }; if (toLower worldName in ["takistan", "zargabad", "mountains_acr", "shapur_baf", "provinggrounds_pmc"]) exitWith { @@ -80,23 +84,25 @@ if (toLower worldName in ["takistan", "zargabad", "mountains_acr", "shapur_baf", GVAR(TempNight) = [-7.1, -5.7, 0.7, 6, 8.8, 12.4, 15.3, 14.3, 9.4, 3.9, -1.2, -4.7]; // Source: http://www.weather-and-climate.com/average-monthly-Humidity-perc,Kabul,Afghanistan GVAR(Humidity) = [68, 69, 62, 60, 49, 37, 38, 39, 40, 41, 56, 61]; - + // Source: https://weatherspark.com/averages/32750/Kabul-Afghanistan GVAR(WindSpeedMax) = [[4.0, 1.0], [4.1, 1.0], [5.1, 1.1], [6.9, 1.2], [8.9, 1.2], [10.0, 1.1], [9.1,1.0], [8.2, 1.0], [6.9, 1.0], [5.2, 1.0], [3.8, 0.9], [3.7, 0.9]]; GVAR(WindSpeedMean) = [2.2, 2.2, 2.5, 2.8, 3.8, 4.4, 0, 3.3, 2.7, 2.4, 1.8, 1.9]; GVAR(WindSpeedMin) = [[0.2, 0.4], [0.2, 0.4], [0.2, 0.4], [0.3, 0.4], [0.6, 0.4], [0.9, 0.4], [0.7, 0.4], [0.5, 0.4], [0.2, 0.5], [0.1, 0.1], [0, 0.1], [0, 0.1]]; - GVAR(WindDirectionProbabilities) = [[0.04, 0.02, 0.05, 0.04, 0.05, 0.04, 0.11, 0.29], // January - [0.08, 0.04, 0.06, 0.04, 0.06, 0.04, 0.10, 0.20], // February - [0.12, 0.06, 0.08, 0.04, 0.05, 0.04, 0.09, 0.19], // March - [0.18, 0.07, 0.09, 0.05, 0.05, 0.04, 0.08, 0.16], // April - [0.27, 0.05, 0.05, 0.03, 0.04, 0.03, 0.08, 0.16], // May - [0.35, 0.04, 0.04, 0.02, 0.02, 0.02, 0.07, 0.13], // June - [0.30, 0.07, 0.09, 0.04, 0.02, 0.02, 0.05, 0.10], // July - [0.23, 0.07, 0.08, 0.06, 0.03, 0.02, 0.05, 0.10], // August - [0.15, 0.06, 0.10, 0.06, 0.04, 0.02, 0.07, 0.13], // September - [0.12, 0.04, 0.07, 0.06, 0.04, 0.03, 0.10, 0.17], // October - [0.07, 0.03, 0.06, 0.05, 0.06, 0.02, 0.10, 0.20], // November - [0.05, 0.03, 0.06, 0.05, 0.06, 0.04, 0.11, 0.26]];// December + GVAR(WindDirectionProbabilities) = [ + [0.04, 0.02, 0.05, 0.04, 0.05, 0.04, 0.11, 0.29], // January + [0.08, 0.04, 0.06, 0.04, 0.06, 0.04, 0.10, 0.20], // February + [0.12, 0.06, 0.08, 0.04, 0.05, 0.04, 0.09, 0.19], // March + [0.18, 0.07, 0.09, 0.05, 0.05, 0.04, 0.08, 0.16], // April + [0.27, 0.05, 0.05, 0.03, 0.04, 0.03, 0.08, 0.16], // May + [0.35, 0.04, 0.04, 0.02, 0.02, 0.02, 0.07, 0.13], // June + [0.30, 0.07, 0.09, 0.04, 0.02, 0.02, 0.05, 0.10], // July + [0.23, 0.07, 0.08, 0.06, 0.03, 0.02, 0.05, 0.10], // August + [0.15, 0.06, 0.10, 0.06, 0.04, 0.02, 0.07, 0.13], // September + [0.12, 0.04, 0.07, 0.06, 0.04, 0.03, 0.10, 0.17], // October + [0.07, 0.03, 0.06, 0.05, 0.06, 0.02, 0.10, 0.20], // November + [0.05, 0.03, 0.06, 0.05, 0.06, 0.04, 0.11, 0.26] // December + ]; }; if (toLower worldName in ["fallujah"]) exitWith { @@ -113,24 +119,25 @@ if (toLower worldName in ["fata", "Abbottabad"]) exitWith { GVAR(TempNight) = [-0.6, 2.4, 7.4, 13.1, 18.2, 22.8, 23.8, 22.9, 19.2, 12, 5.6, 1.2]; // Source: http://www.weather-and-climate.com/average-monthly-Humidity-perc,Zhob,Pakistan GVAR(Humidity) = [50, 40, 42, 40, 30, 30, 50, 49, 40, 32, 38, 41]; - + // Source: https://weatherspark.com/averages/31382/Shkin-Paktika-Afghanistan GVAR(WindSpeedMax) = [[3.0, 1.0], [3.3, 1.0], [4.0, 1.0], [4.3, 1.4], [4.3, 1.5], [4.6, 1.4], [4.5, 1.3], [4.0, 0.9], [4.0, 1.0], [3.5, 1.0], [3.4, 1.0], [3.1, 1.0]]; GVAR(WindSpeedMean) = [1.3, 1.5, 1.6, 1.7, 1.7, 1.7, 1.6, 1.5, 1.5, 1.4, 1.4, 1.2]; GVAR(WindSpeedMin) = [[0.2, 0.1], [0.2, 0.1], [0.2, 0.1], [0.2, 0.1], [0.1, 0.1], [0.1, 0.1], [0.3, 0.1], [0.2, 0.1], [0.1, 0.1], [0.1, 0.1], [0.1, 0.1], [0.1, 0.1]]; - GVAR(WindDirectionProbabilities) = [[0.09, 0.03, 0.02, 0.03, 0.05, 0.07, 0.07, 0.18], // January - [0.07, 0.02, 0.01, 0.05, 0.10, 0.10, 0.06, 0.12], // February - [0.07, 0.02, 0.01, 0.07, 0.14, 0.11, 0.08, 0.12], // March - [0.07, 0.04, 0.03, 0.05, 0.12, 0.08, 0.06, 0.13], // April - [0.10, 0.03, 0.02, 0.04, 0.10, 0.09, 0.08, 0.18], // May - [0.12, 0.05, 0.04, 0.05, 0.08, 0.06, 0.06, 0.16], // June - [0.06, 0.04, 0.02, 0.06, 0.05, 0.01, 0.02, 0.06], // July - [0.08, 0.03, 0.04, 0.05, 0.09, 0.04, 0.02, 0.06], // August - [0.10, 0.04, 0.02, 0.06, 0.11, 0.09, 0.06, 0.13], // September - [0.07, 0.02, 0.01, 0.04, 0.11, 0.08, 0.08, 0.19], // October - [0.06, 0.01, 0.00, 0.05, 0.11, 0.09, 0.08, 0.13], // November - [0.07, 0.01, 0.01, 0.03, 0.08, 0.09, 0.09, 0.18]];// December - + GVAR(WindDirectionProbabilities) = [ + [0.09, 0.03, 0.02, 0.03, 0.05, 0.07, 0.07, 0.18], // January + [0.07, 0.02, 0.01, 0.05, 0.10, 0.10, 0.06, 0.12], // February + [0.07, 0.02, 0.01, 0.07, 0.14, 0.11, 0.08, 0.12], // March + [0.07, 0.04, 0.03, 0.05, 0.12, 0.08, 0.06, 0.13], // April + [0.10, 0.03, 0.02, 0.04, 0.10, 0.09, 0.08, 0.18], // May + [0.12, 0.05, 0.04, 0.05, 0.08, 0.06, 0.06, 0.16], // June + [0.06, 0.04, 0.02, 0.06, 0.05, 0.01, 0.02, 0.06], // July + [0.08, 0.03, 0.04, 0.05, 0.09, 0.04, 0.02, 0.06], // August + [0.10, 0.04, 0.02, 0.06, 0.11, 0.09, 0.06, 0.13], // September + [0.07, 0.02, 0.01, 0.04, 0.11, 0.08, 0.08, 0.19], // October + [0.06, 0.01, 0.00, 0.05, 0.11, 0.09, 0.08, 0.13], // November + [0.07, 0.01, 0.01, 0.03, 0.08, 0.09, 0.09, 0.18] // December + ]; }; if (worldName in ["sfp_wamako"]) exitWith { @@ -155,23 +162,25 @@ if (worldName in ["Bornholm"]) exitWith { GVAR(TempNight) = [-1.6, -2.1, -0.7, 1.7, 6.2, 10.7, 13, 13.1, 10.6, 7.2, 3.5, 0.1]; // Source: http://www.weather-and-climate.com/average-monthly-Humidity-perc,allinge,Denmark GVAR(Humidity) = [85, 84, 80, 76, 69, 69, 76, 77, 79, 81, 86, 86]; - + // Source: https://weatherspark.com/averages/28830/R-nne-Capital-Region-of-Denmark GVAR(WindSpeedMax) = [[9.3, 2.2], [8.4, 2.2], [7.9, 2.2], [7.1, 2.1], [7.2, 2.1], [6.8, 2.0], [6.8, 2.0], [7.1, 2.1], [7.7, 2.2], [8.6, 2.2], [8.8, 2.2], [9.3, 2.2]]; GVAR(WindSpeedMean) = [6.9, 6.0, 5.7, 4.9, 4.8, 4.6, 4.7, 4.9, 5.5, 6.2, 6.5, 6.7]; GVAR(WindSpeedMin) = [[3.9, 2.0], [3.0, 2.0], [2.3, 2.0], [1.8, 1.8], [1.7, 1.8], [1.7, 1.7], [1.7, 1.8], [1.9, 1.9], [2.6, 2.0], [2.9, 2.0], [3.3, 2.1], [3.5, 2.0]]; - GVAR(WindDirectionProbabilities) = [[0.07, 0.04, 0.07, 0.05, 0.09, 0.12, 0.20, 0.07], // January - [0.08, 0.06, 0.10, 0.06, 0.06, 0.08, 0.20, 0.08], // February - [0.05, 0.06, 0.13, 0.08, 0.07, 0.08, 0.19, 0.06], // March - [0.05, 0.11, 0.16, 0.09, 0.05, 0.06, 0.17, 0.06], // April - [0.04, 0.10, 0.15, 0.08, 0.05, 0.06, 0.20, 0.05], // May - [0.03, 0.07, 0.10, 0.07, 0.05, 0.07, 0.28, 0.06], // June - [0.04, 0.06, 0.11, 0.07, 0.04, 0.07, 0.28, 0.06], // July - [0.05, 0.06, 0.11, 0.07, 0.06, 0.08, 0.26, 0.06], // August - [0.06, 0.06, 0.11, 0.07, 0.06, 0.09, 0.21, 0.06], // September - [0.07, 0.05, 0.09, 0.08, 0.08, 0.12, 0.18, 0.07], // October - [0.08, 0.06, 0.08, 0.07, 0.10, 0.12, 0.16, 0.07], // November - [0.08, 0.05, 0.06, 0.04, 0.10, 0.14, 0.19, 0.07]];// December + GVAR(WindDirectionProbabilities) = [ + [0.07, 0.04, 0.07, 0.05, 0.09, 0.12, 0.20, 0.07], // January + [0.08, 0.06, 0.10, 0.06, 0.06, 0.08, 0.20, 0.08], // February + [0.05, 0.06, 0.13, 0.08, 0.07, 0.08, 0.19, 0.06], // March + [0.05, 0.11, 0.16, 0.09, 0.05, 0.06, 0.17, 0.06], // April + [0.04, 0.10, 0.15, 0.08, 0.05, 0.06, 0.20, 0.05], // May + [0.03, 0.07, 0.10, 0.07, 0.05, 0.07, 0.28, 0.06], // June + [0.04, 0.06, 0.11, 0.07, 0.04, 0.07, 0.28, 0.06], // July + [0.05, 0.06, 0.11, 0.07, 0.06, 0.08, 0.26, 0.06], // August + [0.06, 0.06, 0.11, 0.07, 0.06, 0.09, 0.21, 0.06], // September + [0.07, 0.05, 0.09, 0.08, 0.08, 0.12, 0.18, 0.07], // October + [0.08, 0.06, 0.08, 0.07, 0.10, 0.12, 0.16, 0.07], // November + [0.08, 0.05, 0.06, 0.04, 0.10, 0.14, 0.19, 0.07] // December + ]; }; if (worldName in ["Imrali"]) exitWith { // Source: http://www.iten-online.ch/klima/europa/tuerkei/bursa.htm @@ -186,23 +195,25 @@ if (worldName in ["Kunduz"]) exitWith { GVAR(TempNight) = [-2.4, 0, 5.7, 11.6, 15.7, 20.9, 21.5, 21.5, 16.3, 10.6, 4.1, 0]; // Source: http://www.weather-and-climate.com/average-monthly-Humidity-perc,Kabul,Afghanistan GVAR(Humidity) = [70, 72, 64, 61, 49, 34, 36, 38, 39, 52, 51, 63]; - + // Source: https://weatherspark.com/averages/32753/Kunduz-Afghanistan GVAR(WindSpeedMax) = [[3.5, 0.8], [4.0, 0.6], [4.3, 2.0], [4.6, 1.1], [5.1, 1.2], [5.7, 1.0], [4.9, 0.8], [4.5, 0.3], [4.3, 0.3], [3.8, 0.5], [3.0, 1.3], [3.1, 0.8]]; GVAR(WindSpeedMean) = [1.5, 1.8, 2.1, 2.4, 2.5, 2.8, 2.7, 2.5, 2.3, 2.1, 1.7, 1.6]; GVAR(WindSpeedMin) = [[0.2, 0.1], [0.3, 0.3], [0.4, 0.1], [0.8, 0.2], [0.8, 0.1], [1.0, 0.3], [0.9, 0.5], [0.8, 0.2], [0.8, 0.1], [0.7, 0.1], [0.5, 0.1], [0.2, 0.2]]; - GVAR(WindDirectionProbabilities) = [[0.04, 0.02, 0.05, 0.11, 0.12, 0.06, 0.09, 0.06], // January - [0.04, 0.02, 0.05, 0.11, 0.12, 0.06, 0.08, 0.07], // February - [0.05, 0.04, 0.06, 0.14, 0.12, 0.06, 0.10, 0.08], // March - [0.09, 0.05, 0.08, 0.13, 0.07, 0.05, 0.07, 0.07], // April - [0.14, 0.07, 0.13, 0.13, 0.06, 0.05, 0.05, 0.08], // May - [0.16, 0.06, 0.12, 0.12, 0.05, 0.04, 0.05, 0.10], // June - [0.17, 0.06, 0.08, 0.12, 0.06, 0.04, 0.05, 0.12], // July - [0.15, 0.05, 0.06, 0.16, 0.08, 0.05, 0.07, 0.13], // August - [0.15, 0.04, 0.08, 0.20, 0.13, 0.05, 0.10, 0.14], // September - [0.08, 0.02, 0.08, 0.22, 0.15, 0.06, 0.13, 0.13], // October - [0.06, 0.02, 0.05, 0.20, 0.17, 0.06, 0.12, 0.10], // November - [0.04, 0.02, 0.05, 0.14, 0.19, 0.07, 0.10, 0.07]];// December + GVAR(WindDirectionProbabilities) = [ + [0.04, 0.02, 0.05, 0.11, 0.12, 0.06, 0.09, 0.06], // January + [0.04, 0.02, 0.05, 0.11, 0.12, 0.06, 0.08, 0.07], // February + [0.05, 0.04, 0.06, 0.14, 0.12, 0.06, 0.10, 0.08], // March + [0.09, 0.05, 0.08, 0.13, 0.07, 0.05, 0.07, 0.07], // April + [0.14, 0.07, 0.13, 0.13, 0.06, 0.05, 0.05, 0.08], // May + [0.16, 0.06, 0.12, 0.12, 0.05, 0.04, 0.05, 0.10], // June + [0.17, 0.06, 0.08, 0.12, 0.06, 0.04, 0.05, 0.12], // July + [0.15, 0.05, 0.06, 0.16, 0.08, 0.05, 0.07, 0.13], // August + [0.15, 0.04, 0.08, 0.20, 0.13, 0.05, 0.10, 0.14], // September + [0.08, 0.02, 0.08, 0.22, 0.15, 0.06, 0.13, 0.13], // October + [0.06, 0.02, 0.05, 0.20, 0.17, 0.06, 0.12, 0.10], // November + [0.04, 0.02, 0.05, 0.14, 0.19, 0.07, 0.10, 0.07] // December + ]; }; // Assume default values diff --git a/addons/weather/functions/fnc_initWind.sqf b/addons/weather/functions/fnc_initWind.sqf index 4c88f59f95..ddd314c0c6 100644 --- a/addons/weather/functions/fnc_initWind.sqf +++ b/addons/weather/functions/fnc_initWind.sqf @@ -19,7 +19,7 @@ private _month = date select 1; private _windDirectionProbabilities = GVAR(WindDirectionProbabilities) select (_month - 1); ACE_wind = [0, 0, 0]; - + GVAR(wind_direction_reference) = random 360; private _sum = 0; for "_i" from 0 to 7 do { diff --git a/addons/weather/functions/fnc_updateHumidity.sqf b/addons/weather/functions/fnc_updateHumidity.sqf index 3ea28d6a44..66a351096c 100644 --- a/addons/weather/functions/fnc_updateHumidity.sqf +++ b/addons/weather/functions/fnc_updateHumidity.sqf @@ -27,7 +27,7 @@ if ((rain > 0) && {overcast > 0.7}) then { private _PS2 = 6.112 * exp((17.62 * GVAR(currentTemperature)) / (243.12 + GVAR(currentTemperature))); GVAR(currentHumidity) = GVAR(currentHumidity) * _PS1 / _PS2; GVAR(currentHumidity) = GVAR(currentHumidity) + GVAR(humidityShift); - + TRACE_1("humidityShift",GVAR(humidityShift)); }; diff --git a/addons/weather/functions/fnc_updateRain.sqf b/addons/weather/functions/fnc_updateRain.sqf index 8fa18500e8..9146b266b3 100644 --- a/addons/weather/functions/fnc_updateRain.sqf +++ b/addons/weather/functions/fnc_updateRain.sqf @@ -22,6 +22,6 @@ if (!isNil "ACE_RAIN_PARAMS") then { private _periodPercent = (_periodPosition / _period) min 1; GVAR(ACE_Rain) = linearConversion [GVAR(rain_period_start_time), (GVAR(rain_period_start_time) + _period), ACE_time, _oldRain, _newRain]; - + TRACE_3("Update Rain",rain,ACE_RAIN_PARAMS,GVAR(ACE_Rain)); }; diff --git a/addons/yardage450/functions/fnc_acquireTarget.sqf b/addons/yardage450/functions/fnc_acquireTarget.sqf index 1d89bf5971..a7e56e815d 100644 --- a/addons/yardage450/functions/fnc_acquireTarget.sqf +++ b/addons/yardage450/functions/fnc_acquireTarget.sqf @@ -32,15 +32,15 @@ GVAR(distanceIndex) = -1; GVAR(lasing) = false; [_this select 1] call CBA_fnc_removePerFrameHandler; }; - + _result = [eyePos ACE_player, ACE_player weaponDirection (currentWeapon ACE_player)] call EFUNC(laser,shootRay); _distance = _result select 1; - + _distance = _distance - 1 + (random 2); - + GVAR(distanceIndex) = (GVAR(distanceIndex) + 1) % METERING_POINT_NUMBER; GVAR(distances) set [GVAR(distanceIndex), _distance]; - + if (count GVAR(distances) == METERING_POINT_NUMBER) then { _min = MAX_DISTANCE; _max = MIN_DISTANCE; @@ -48,7 +48,7 @@ GVAR(distanceIndex) = -1; _min = _x min _min; _max = _max max _x; } forEach GVAR(distances); - + if (abs(_max - _min) < 5) then { _range = (_min + _max) / 2; if (_range >= MIN_DISTANCE && _range <= MAX_DISTANCE) then { diff --git a/addons/yardage450/functions/fnc_turnOn.sqf b/addons/yardage450/functions/fnc_turnOn.sqf index 5f123b8cb2..1cb20e71b6 100644 --- a/addons/yardage450/functions/fnc_turnOn.sqf +++ b/addons/yardage450/functions/fnc_turnOn.sqf @@ -35,10 +35,10 @@ GVAR(active) = true; 74210 cutText ["", "PLAIN"]; [_this select 1] call CBA_fnc_removePerFrameHandler; }; - + if (currentWeapon ACE_player == "ACE_Yardage450" && cameraView == "GUNNER") then { 74210 cutRsc ["ACE_RscYardage450", "PLAIN", 1, false]; - + __ctrlLaser ctrlShow GVAR(lasing); if (GVAR(targetAcquired)) then { __ctrlTarget ctrlSetText "Target Acquired"; @@ -52,5 +52,5 @@ GVAR(active) = true; } else { 74210 cutText ["", "PLAIN"]; }; - + }, 0, []] call CBA_fnc_addPerFrameHandler; diff --git a/addons/yardage450/initKeybinds.sqf b/addons/yardage450/initKeybinds.sqf index 578f55ee40..9ad3005d28 100644 --- a/addons/yardage450/initKeybinds.sqf +++ b/addons/yardage450/initKeybinds.sqf @@ -6,7 +6,7 @@ // Conditions: specific if !(GVAR(active)) exitWith {false}; if (currentWeapon ACE_player != "ACE_Yardage450" || cameraView != "GUNNER") exitWith {false}; - + // Statement if !(GVAR(powerButtonPressed)) then { GVAR(powerButtonPressed) = true; @@ -19,7 +19,7 @@ if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific if (currentWeapon ACE_player != "ACE_Yardage450" || cameraView != "GUNNER") exitWith {false}; - + // Statement GVAR(powerButtonPressed) = false; call FUNC(turnOn); diff --git a/addons/zeus/CfgVehicles.hpp b/addons/zeus/CfgVehicles.hpp index 0013355370..c7ea7b6ec8 100644 --- a/addons/zeus/CfgVehicles.hpp +++ b/addons/zeus/CfgVehicles.hpp @@ -167,7 +167,7 @@ class CfgVehicles { sync[] = {}; }; }; - + // class GVAR(moduleSetSuppression): GVAR(moduleBase) { // curatorCanAttach = 1; // displayName = CSTRING(ModuleSetSupp_DisplayName); From 75cbe7df4f98f2973db779da1cca9b3654717a83 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Tue, 3 May 2016 15:15:10 +0200 Subject: [PATCH 147/215] Change start line count of config validation at 1 --- tools/config_style_checker.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/config_style_checker.py b/tools/config_style_checker.py index 65bd57a449..03d8f222fe 100644 --- a/tools/config_style_checker.py +++ b/tools/config_style_checker.py @@ -40,7 +40,7 @@ def check_config_style(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 From 0c55d0ca0639438452fbce55e9c6083f5544f9ab Mon Sep 17 00:00:00 2001 From: Glowbal Date: Tue, 3 May 2016 15:15:55 +0200 Subject: [PATCH 148/215] Change start line number count sqf validation at 1 --- tools/sqf_validator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/sqf_validator.py b/tools/sqf_validator.py index 7414d7d715..7a905a3315 100644 --- a/tools/sqf_validator.py +++ b/tools/sqf_validator.py @@ -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 From 8585ea568845ef63f6ed1b2b6a487906c33a14c1 Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 3 May 2016 18:12:47 +0200 Subject: [PATCH 149/215] add framework to add virtual mass to containers --- addons/movement/XEH_PREP.hpp | 2 + addons/movement/XEH_postInit.sqf | 3 ++ .../functions/fnc_addLoadToUnitContainer.sqf | 31 ++++++++++++++ .../functions/fnc_handleVirtualMass.sqf | 42 +++++++++++++++++++ 4 files changed, 78 insertions(+) create mode 100644 addons/movement/functions/fnc_addLoadToUnitContainer.sqf create mode 100644 addons/movement/functions/fnc_handleVirtualMass.sqf diff --git a/addons/movement/XEH_PREP.hpp b/addons/movement/XEH_PREP.hpp index 8e465970eb..04913f7670 100644 --- a/addons/movement/XEH_PREP.hpp +++ b/addons/movement/XEH_PREP.hpp @@ -1,5 +1,7 @@ +PREP(addLoadToUnitContainer); PREP(getWeight); PREP(canClimb); PREP(climb); PREP(handleClimb); +PREP(handleVirtualMass); diff --git a/addons/movement/XEH_postInit.sqf b/addons/movement/XEH_postInit.sqf index 806823f4c4..d9179a912a 100644 --- a/addons/movement/XEH_postInit.sqf +++ b/addons/movement/XEH_postInit.sqf @@ -3,6 +3,9 @@ if (!hasInterface) exitWith {}; +["playerChanged", FUNC(handleVirtualMass)] call FUNC(addEventHandler); +["playerInventoryChanged", FUNC(handleVirtualMass)] call FUNC(addEventHandler); + ["ACE3 Movement", QGVAR(climb), localize LSTRING(Climb), { // Conditions: canInteract diff --git a/addons/movement/functions/fnc_addLoadToUnitContainer.sqf b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf new file mode 100644 index 0000000000..28fea8f697 --- /dev/null +++ b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf @@ -0,0 +1,31 @@ +/* + * Author: commy2 + * Add (negative numbers to subtract) a virtual mass to a units container. + * + * Arguments: + * 0: The Unit + * 1: The Container + * 2: The Virtual Load + * + * Return Value: + * Success? + * + * Public: No + */ +#include "script_component.hpp" + +params [["_unit", objNull, [objNull]], ["_container", objNull, [objNull]], ["_virtualLoadToAdd", 0, [0]]]; + +if !(_container in [ + uniformContainer _unit, + vestContainer _unit, + backpackContainer _unit +]) exitWith {false}; + +private _virtualLoad = (_container getVariable [QGVAR(vLoad), 0]) + _virtualLoadToAdd; +_container setVariable [QGVAR(vLoad), _virtualLoad]; + +// update +_unit call FUNC(handleVirtualMass); + +true diff --git a/addons/movement/functions/fnc_handleVirtualMass.sqf b/addons/movement/functions/fnc_handleVirtualMass.sqf new file mode 100644 index 0000000000..5d71c58df4 --- /dev/null +++ b/addons/movement/functions/fnc_handleVirtualMass.sqf @@ -0,0 +1,42 @@ +/* + * Author: commy2 + * Recalculate the units loadCoef to emulate a mass added to uniform, vest or backpack. + * + * Arguments: + * 0: The Unit (usually the player) + * + * Return Value: + * Nothing + * + * Public: No + */ +#include "script_component.hpp" + +params ["_unit"]; + +// add sum of virtual loads +private _virtualLoad = 0; + +{ + _virtualLoad = _virtualLoad + (_x getVariable [QGVAR(vLoad), 0]); +} forEach [ + uniformContainer _unit, + vestContainer _unit, + backpackContainer _unit +]; + +// get absolute vanilla load +private _absLoad = loadAbs _unit / load _unit; + +// try to preserve other changes to the "LoadCoef" unitTrait +private _loadCoef = _unit getVariable QGVAR(loadCoef); + +if (isNil "_loadCoef") then { + _loadCoef = _unit getUnitTrait "loadCoef"; + _unit setVariable [QGVAR(loadCoef), _loadCoef, true]; +}; + +// calc. new "virtual" loadCoef +private _virtualLoadCoef = (1 + _virtualLoad / _absLoad) * _loadCoef; + +_unit setUnitTrait ["loadCoef", _virtualLoadCoef]; From 736807f994f62405333a591fcf4c261a21b87a67 Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 3 May 2016 18:16:39 +0200 Subject: [PATCH 150/215] fix typo, make variable global --- addons/movement/functions/fnc_addLoadToUnitContainer.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/movement/functions/fnc_addLoadToUnitContainer.sqf b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf index 28fea8f697..3928d1c822 100644 --- a/addons/movement/functions/fnc_addLoadToUnitContainer.sqf +++ b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: The Unit - * 1: The Container + * 1: The Container * 2: The Virtual Load * * Return Value: @@ -23,7 +23,7 @@ if !(_container in [ ]) exitWith {false}; private _virtualLoad = (_container getVariable [QGVAR(vLoad), 0]) + _virtualLoadToAdd; -_container setVariable [QGVAR(vLoad), _virtualLoad]; +_container setVariable [QGVAR(vLoad), _virtualLoad, true]; // update _unit call FUNC(handleVirtualMass); From 66c2bf050625d51ae453a662d3d7d78253840b04 Mon Sep 17 00:00:00 2001 From: Cuel Date: Tue, 3 May 2016 20:10:28 +0200 Subject: [PATCH 151/215] Fix dead bodies removal, when forced = 1 - Removed unused(?) GVAR(Module) - Removed "white space alignment" in module.sqf --- addons/respawn/CfgEventHandlers.hpp | 1 + addons/respawn/XEH_serverPostInit.sqf | 17 +++++++++++++++++ addons/respawn/functions/fnc_module.sqf | 20 ++------------------ 3 files changed, 20 insertions(+), 18 deletions(-) create mode 100644 addons/respawn/XEH_serverPostInit.sqf diff --git a/addons/respawn/CfgEventHandlers.hpp b/addons/respawn/CfgEventHandlers.hpp index a4601c6f95..481d36cf30 100644 --- a/addons/respawn/CfgEventHandlers.hpp +++ b/addons/respawn/CfgEventHandlers.hpp @@ -14,6 +14,7 @@ class Extended_PreInit_EventHandlers { class Extended_PostInit_EventHandlers { class ADDON { init = QUOTE(call COMPILE_FILE(XEH_postInit)); + serverInit = QUOTE(call COMPILE_FILE(XEH_serverPostInit)); }; }; diff --git a/addons/respawn/XEH_serverPostInit.sqf b/addons/respawn/XEH_serverPostInit.sqf new file mode 100644 index 0000000000..d472bb0d5c --- /dev/null +++ b/addons/respawn/XEH_serverPostInit.sqf @@ -0,0 +1,17 @@ +#include "script_component.hpp" + +["SettingsInitialized", { + if (GVAR(RemoveDeadBodiesDisconnected)) then { + addMissionEventHandler ["HandleDisconnect", { + [{ + params ["_unit"]; + + if (!alive _unit) then { + deleteVehicle _unit; + }; + }, + _this, 4] call EFUNC(common,waitAndExecute); + false + }]; + }; +}] call EFUNC(common,addEventHandler); diff --git a/addons/respawn/functions/fnc_module.sqf b/addons/respawn/functions/fnc_module.sqf index ea6ba555d5..bc4f197c07 100644 --- a/addons/respawn/functions/fnc_module.sqf +++ b/addons/respawn/functions/fnc_module.sqf @@ -19,25 +19,9 @@ params ["_logic", "_units", "_activated"]; -if !(_activated) exitWith {}; +if (!_activated) exitWith {}; -GVAR(Module) = true; - -[_logic, QGVAR(SavePreDeathGear), "SavePreDeathGear"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(SavePreDeathGear), "SavePreDeathGear"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(RemoveDeadBodiesDisconnected), "RemoveDeadBodiesDisconnected"] call EFUNC(common,readSettingFromModule); -if (isServer && {GVAR(RemoveDeadBodiesDisconnected)}) then { - addMissionEventHandler ["HandleDisconnect", { - [{ - params ["_unit"]; - - if (!alive _unit) then { - deleteVehicle _unit; - }; - }, - _this, 4] call EFUNC(common,waitAndExecute); - false - }]; -}; - ACE_LOGINFO("Respawn Module Initialized."); From e125911c3b88259d6b307dc46a09ec79b2441184 Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Tue, 3 May 2016 20:52:43 +0200 Subject: [PATCH 152/215] Added blockEngine status effect --- addons/common/CfgEventHandlers.hpp | 6 ++++++ addons/common/XEH_PREP.hpp | 1 + addons/common/XEH_postInit.sqf | 6 ++++++ addons/common/functions/fnc_handleEngine.sqf | 19 +++++++++++++++++++ 4 files changed, 32 insertions(+) create mode 100644 addons/common/functions/fnc_handleEngine.sqf diff --git a/addons/common/CfgEventHandlers.hpp b/addons/common/CfgEventHandlers.hpp index 6e8528cf03..5d55e40f2d 100644 --- a/addons/common/CfgEventHandlers.hpp +++ b/addons/common/CfgEventHandlers.hpp @@ -76,3 +76,9 @@ class Extended_FiredBIS_EventHandlers { ADDON = QUOTE(_this call FUNC(firedEH)); }; }; + +class Extended_Engine_EventHandlers { + class All { + ADDON = QUOTE(_this call FUNC(handleEngine)); + }; +}; diff --git a/addons/common/XEH_PREP.hpp b/addons/common/XEH_PREP.hpp index 0b125af1aa..3dea56a98d 100644 --- a/addons/common/XEH_PREP.hpp +++ b/addons/common/XEH_PREP.hpp @@ -87,6 +87,7 @@ PREP(getWindDirection); PREP(getZoom); PREP(goKneeling); PREP(hadamardProduct); +PREP(handleEngine); PREP(handleModifierKey); PREP(handleModifierKeyUp); PREP(handleScrollWheel); diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 22257e3cb5..a6b952062e 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -64,6 +64,7 @@ ["blockSprint", false, []] call FUNC(statusEffect_addType); ["setCaptive", true, [QEGVAR(captives,Handcuffed), QEGVAR(captives,Surrendered), QEGVAR(medical,unconscious)]] call FUNC(statusEffect_addType); ["blockDamage", false, ["fixCollision"]] call FUNC(statusEffect_addType); +["blockEngine", false, ["ACE_Refuel"]] call FUNC(statusEffect_addType); ["forceWalk", { params ["_object", "_set"]; @@ -90,6 +91,11 @@ _object allowDamage (_set == 0); }; }] call FUNC(addEventHandler); +["blockEngine", { + params ["_vehicle", "_set"]; + _vehicle setVariable [QGVAR(blockEngine), _set > 0, true]; + _vehicle engineOn false; +}] call FUNC(addEventHandler); //Add a fix for BIS's zeus remoteControl module not reseting variables on DC when RC a unit //This variable is used for isPlayer checks diff --git a/addons/common/functions/fnc_handleEngine.sqf b/addons/common/functions/fnc_handleEngine.sqf new file mode 100644 index 0000000000..829ad5bb49 --- /dev/null +++ b/addons/common/functions/fnc_handleEngine.sqf @@ -0,0 +1,19 @@ +/* + * Author: BaerMitUmlaut + * Blocks turning on the vehicles engine if set by the status effect handler. + * + * Arguments: + * 0: Vehicle + * 1: Engine state + * + * Return Value: + * None + * + * Public: No + */ +#include "script_component.hpp" +params ["_vehicle", "_engineOn"]; + +if (local _vehicle && {_engineOn} && {_vehicle getVariable [QGVAR(blockEngine), false]}) then { + _vehicle engineOn false; +}; From 304f1a22b444f32c198b99984ae257b25245a1f2 Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Tue, 3 May 2016 21:08:22 +0200 Subject: [PATCH 153/215] Use blockeEngine status effect in refuel --- addons/refuel/functions/fnc_reset.sqf | 4 +--- addons/refuel/functions/fnc_returnNozzle.sqf | 3 +-- addons/refuel/functions/fnc_takeNozzle.sqf | 3 +-- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/addons/refuel/functions/fnc_reset.sqf b/addons/refuel/functions/fnc_reset.sqf index 6e3bdbe774..767e4b6c88 100644 --- a/addons/refuel/functions/fnc_reset.sqf +++ b/addons/refuel/functions/fnc_reset.sqf @@ -17,9 +17,7 @@ params [["_target", objNull, [objNull]]]; -["setVanillaHitPointDamage", _target, [_target, ["HitEngine", _target getVariable [QGVAR(engineHit), 0]] ] ] call EFUNC(common,objectEvent); - -_target setVariable [QGVAR(engineHit), nil, true]; +[_target, "blockEngine", "ACE_Refuel", false] call EFUNC(common,statusEffect_set); _target setVariable [QGVAR(isConnected), false, true]; private _nozzle = _target getVariable [QGVAR(ownedNozzle), nil]; diff --git a/addons/refuel/functions/fnc_returnNozzle.sqf b/addons/refuel/functions/fnc_returnNozzle.sqf index bd4da5569b..1bd364eafb 100644 --- a/addons/refuel/functions/fnc_returnNozzle.sqf +++ b/addons/refuel/functions/fnc_returnNozzle.sqf @@ -48,8 +48,7 @@ if (isNull _nozzle || {_source != _target}) exitWith {false}; }; deleteVehicle _nozzle; - ["setVanillaHitPointDamage", _target, [_target, ["HitEngine", _target getVariable [QGVAR(engineHit), 0]] ] ] call EFUNC(common,objectEvent); - _target setVariable [QGVAR(engineHit), nil, true]; + [_target, "blockEngine", "ACE_Refuel", false] call EFUNC(common,statusEffect_set); }, "", localize LSTRING(ReturnAction), diff --git a/addons/refuel/functions/fnc_takeNozzle.sqf b/addons/refuel/functions/fnc_takeNozzle.sqf index 3d557f9a2e..75601002a3 100644 --- a/addons/refuel/functions/fnc_takeNozzle.sqf +++ b/addons/refuel/functions/fnc_takeNozzle.sqf @@ -26,8 +26,7 @@ REFUEL_HOLSTER_WEAPON private _endPosOffset = [0, 0, 0]; if (isNull _nozzle) then { // func is called on fuel truck - _target setVariable [QGVAR(engineHit), _target getHitPointDamage "HitEngine", true]; - ["setVanillaHitPointDamage", _target, [_target, ["HitEngine", 1]] ] call EFUNC(common,objectEvent); + [_target, "blockEngine", "ACE_Refuel", true] call EFUNC(common,statusEffect_set); _target setVariable [QGVAR(isConnected), true, true]; _endPosOffset = getArray (configFile >> "CfgVehicles" >> typeOf _target >> QGVAR(hooks)); From b6324e61e9c231cefac974094a3c0082eb1a407f Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Tue, 3 May 2016 21:24:10 +0200 Subject: [PATCH 154/215] Improved params formatting --- addons/atragmx/functions/fnc_calculate_solution.sqf | 8 +++++++- addons/rangecard/functions/fnc_calculateSolution.sqf | 8 +++++++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/addons/atragmx/functions/fnc_calculate_solution.sqf b/addons/atragmx/functions/fnc_calculate_solution.sqf index 839cba8b69..e71658f490 100644 --- a/addons/atragmx/functions/fnc_calculate_solution.sqf +++ b/addons/atragmx/functions/fnc_calculate_solution.sqf @@ -42,7 +42,13 @@ * Public: No */ #include "script_component.hpp" -params ["_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed", "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_bc", "_dragModel", "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", "_directionOfFire"]; +params [ + "_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", + "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed", + "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_bc", "_dragModel", + "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", + "_directionOfFire" +]; _windSpeed params ["_windSpeed1", "_windSpeed2"]; private ["_bulletPos", "_bulletVelocity", "_bulletAccel", "_bulletSpeed", "_gravity", "_deltaT"]; diff --git a/addons/rangecard/functions/fnc_calculateSolution.sqf b/addons/rangecard/functions/fnc_calculateSolution.sqf index e1659016bb..b921b71ff8 100644 --- a/addons/rangecard/functions/fnc_calculateSolution.sqf +++ b/addons/rangecard/functions/fnc_calculateSolution.sqf @@ -45,7 +45,13 @@ * Public: No */ #include "script_component.hpp" -params ["_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed", "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_bc", "_dragModel", "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", "_directionOfFire", "_rangeCardSlot", "_useABConfig"]; +params [ + "_scopeBaseAngle", "_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", + "_temperature", "_barometricPressure", "_relativeHumidity", "_simSteps", "_windSpeed", + "_windDirection", "_inclinationAngle", "_targetSpeed", "_targetRange", "_bc", "_dragModel", + "_atmosphereModel", "_storeRangeCardData", "_stabilityFactor", "_twistDirection", "_latitude", + "_directionOfFire", "_rangeCardSlot", "_useABConfig" +]; _windSpeed params ["_windSpeed1", "_windSpeed2"]; if (_storeRangeCardData) then { From 012ce9fb16940b043bf7f50aa323bc1cc037eb00 Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Tue, 3 May 2016 21:38:36 +0200 Subject: [PATCH 155/215] Removed old occurances of AGM and CSE --- addons/missionmodules/config.cpp | 2 +- addons/nametags/functions/fnc_getVehicleData.sqf | 2 +- addons/optionsmenu/gui/define.hpp | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/addons/missionmodules/config.cpp b/addons/missionmodules/config.cpp index 0867b486c6..c373b84615 100644 --- a/addons/missionmodules/config.cpp +++ b/addons/missionmodules/config.cpp @@ -2,7 +2,7 @@ class CfgPatches { class ADDON { - units[] = {"cse_moduleAmbianceSound"}; + units[] = {}; weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"ace_common"}; diff --git a/addons/nametags/functions/fnc_getVehicleData.sqf b/addons/nametags/functions/fnc_getVehicleData.sqf index b0e0b1ff34..656cb8dc81 100644 --- a/addons/nametags/functions/fnc_getVehicleData.sqf +++ b/addons/nametags/functions/fnc_getVehicleData.sqf @@ -1,6 +1,6 @@ /* * Author: aeroson - * Gathers and caches data needed by AGM_CrewInfo_fnc_doShow. + * Gathers and caches data needed by ace_nametags_fnc_doShow. * What really does make difference for the engine is simulation of CfgAmmo. * Priority of roles is: driver/pilot, gunner, copilot, commander, FFV, cargo. * diff --git a/addons/optionsmenu/gui/define.hpp b/addons/optionsmenu/gui/define.hpp index ef9ef0d02b..c2b1faf9cf 100644 --- a/addons/optionsmenu/gui/define.hpp +++ b/addons/optionsmenu/gui/define.hpp @@ -92,6 +92,5 @@ class RscText; // Listbox styles #define LB_TEXTURES 0x10 #define LB_MULTI 0x20 -#define FontCSE "RobotoCondensed" #endif From 98a74aca6ef2badc22121f604adb0b7b3d6ea229 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 3 May 2016 22:49:05 -0500 Subject: [PATCH 156/215] UI - Don't overwrite other showHud indexes --- addons/ui/functions/fnc_setElements.sqf | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/addons/ui/functions/fnc_setElements.sqf b/addons/ui/functions/fnc_setElements.sqf index b94b0f9a22..64b716ee29 100644 --- a/addons/ui/functions/fnc_setElements.sqf +++ b/addons/ui/functions/fnc_setElements.sqf @@ -23,15 +23,13 @@ if (!_force && {!GVAR(allowSelectiveUI)}) exitWith { [LSTRING(Disallowed), 2] call EFUNC(common,displayTextStructured); }; -private _shownHUD = shownHUD; // [hud, info, radar, compass, direction, menu, group, cursors] - ["ui", [ - _shownHUD select 0, + true, GVAR(soldierVehicleWeaponInfo), GVAR(vehicleRadar), GVAR(vehicleCompass), - _shownHUD select 4, + true, GVAR(commandMenu), GVAR(groupBar), - _shownHUD select 7 + true ]] call EFUNC(common,showHud); From 398b76f30bc0e8a6dffeaff0050038b77cee0ac6 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 3 May 2016 23:13:43 -0500 Subject: [PATCH 157/215] Get reload time from QGVAR(buddyReloadTime) --- addons/reloadlaunchers/functions/fnc_load.sqf | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/addons/reloadlaunchers/functions/fnc_load.sqf b/addons/reloadlaunchers/functions/fnc_load.sqf index 9f0b36ce8d..db18e7edaa 100644 --- a/addons/reloadlaunchers/functions/fnc_load.sqf +++ b/addons/reloadlaunchers/functions/fnc_load.sqf @@ -18,8 +18,11 @@ params ["_unit", "_target", "_weapon", "_magazine"]; TRACE_4("params",_unit,_target,_weapon,_magazine); -// private _reloadTime = getNumber (configFile >> "CfgWeapons" >> _weapon >> "magazineReloadTime"); //Not a good config value, use a constant for now: -private _reloadTime = 2.5; +private _reloadTime = if (isNumber (configFile >> "CfgWeapons" >> _weapon >> QGVAR(buddyReloadTime))) then { + getNumber (configFile >> "CfgWeapons" >> _weapon >> QGVAR(buddyReloadTime)) +} else { + 2.5 +}; // do animation [_unit] call EFUNC(common,goKneeling); From cf92ba9c46203fb734c9949b6d4f3617009620f6 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 4 May 2016 14:59:04 -0500 Subject: [PATCH 158/215] Overheating - Add Master Enabled Setting (barrelPR) --- addons/overheating/ACE_Settings.hpp | 6 ++ addons/overheating/CfgEventHandlers.hpp | 8 -- addons/overheating/CfgVehicles.hpp | 12 +-- addons/overheating/XEH_postInit.sqf | 101 ++++++++++-------- .../functions/fnc_swapBarrelCallback.sqf | 2 +- ...c_updateSpareBarrelsTemperaturesThread.sqf | 2 +- addons/overheating/stringtable.xml | 10 +- 7 files changed, 77 insertions(+), 64 deletions(-) diff --git a/addons/overheating/ACE_Settings.hpp b/addons/overheating/ACE_Settings.hpp index 6cff3268ff..abf08c9874 100644 --- a/addons/overheating/ACE_Settings.hpp +++ b/addons/overheating/ACE_Settings.hpp @@ -38,4 +38,10 @@ class ACE_Settings { displayName = CSTRING(unJamFailChance_displayName); description = CSTRING(unJamFailChance_description); }; + class GVAR(enabled) { + typeName = "BOOL"; + value = 1; + displayName = CSTRING(enabled_displayName); + description = CSTRING(enabled_description); + }; }; diff --git a/addons/overheating/CfgEventHandlers.hpp b/addons/overheating/CfgEventHandlers.hpp index 492230513f..5da5fd0dc2 100644 --- a/addons/overheating/CfgEventHandlers.hpp +++ b/addons/overheating/CfgEventHandlers.hpp @@ -16,11 +16,3 @@ class Extended_PostInit_EventHandlers { init = QUOTE( call COMPILE_FILE(XEH_postInit) ); }; }; - -class Extended_Take_EventHandlers { - class CAManBase { - class GVAR(UnjamReload) { - clientTake = QUOTE( _this call FUNC(handleTakeEH) ); - }; - }; -}; diff --git a/addons/overheating/CfgVehicles.hpp b/addons/overheating/CfgVehicles.hpp index 0a86535231..23a2b613f5 100644 --- a/addons/overheating/CfgVehicles.hpp +++ b/addons/overheating/CfgVehicles.hpp @@ -6,7 +6,7 @@ class CfgVehicles { class ACE_Equipment { class GVAR(UnJam) { displayName = CSTRING(UnjamWeapon); - condition = QUOTE( [_player] call FUNC(canUnjam) ); + condition = QUOTE( GVAR(enabled) && {[_player] call FUNC(canUnjam)} ); exceptions[] = {"isNotInside", "isNotSitting"}; statement = QUOTE( [ARR_2(_player, currentMuzzle _player)] call FUNC(clearJam); ); showDisabled = 0; @@ -15,7 +15,7 @@ class CfgVehicles { }; class GVAR(SwapBarrel) { displayName = CSTRING(SwapBarrel); - condition = QUOTE( 'ACE_SpareBarrel' in magazines _player && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _player >> 'ACE_Overheating_allowSwapBarrel') == 1} ); + condition = QUOTE( GVAR(enabled) && {'ACE_SpareBarrel' in magazines _player} && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _player >> 'ACE_Overheating_allowSwapBarrel') == 1} ); statement = QUOTE( [ARR_3(_player, _player, currentWeapon _player)] call FUNC(swapBarrel); ); showDisabled = 0; priority = 3; @@ -23,7 +23,7 @@ class CfgVehicles { }; class GVAR(CheckTemperature) { displayName = CSTRING(CheckTemperatureShort); - condition = "switch (currentWeapon _player) do {case (''): {false}; case (primaryWeapon _player); case (handgunWeapon _player): {true}; default {false}}"; + condition = "ace_overheating_enabled && {switch (currentWeapon _player) do {case (''): {false}; case (primaryWeapon _player); case (handgunWeapon _player): {true}; default {false}}}"; exceptions[] = {"isNotInside", "isNotSitting"}; statement = QUOTE( [ARR_3(_player, _player, currentWeapon _player)] call FUNC(checkTemperature); ); showDisabled = 0; @@ -32,7 +32,7 @@ class CfgVehicles { }; class GVAR(CheckTemperatureSpareBarrels) { displayName = CSTRING(CheckTemperatureSpareBarrelsShort); - condition = QUOTE( 'ACE_SpareBarrel' in magazines _player); + condition = QUOTE( GVAR(enabled) && {'ACE_SpareBarrel' in magazines _player}); exceptions[] = {"isNotInside", "isNotSitting"}; statement = QUOTE( [_player] call FUNC(checkSpareBarrelsTemperatures); ); showDisabled = 0; @@ -46,13 +46,13 @@ class CfgVehicles { class ACE_Weapon { class GVAR(SwapBarrel) { displayName = CSTRING(SwapBarrel); - condition = QUOTE( 'ACE_SpareBarrel' in magazines _player && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _target >> 'ACE_Overheating_allowSwapBarrel') == 1} ); + condition = QUOTE( GVAR(enabled) && {'ACE_SpareBarrel' in magazines _player} && {getNumber (configFile >> 'CfgWeapons' >> currentWeapon _target >> 'ACE_Overheating_allowSwapBarrel') == 1} ); statement = QUOTE([ARR_3(_player, _target, currentWeapon _target)] call FUNC(swapBarrelAssistant);); icon = QUOTE(PATHTOF(UI\spare_barrel_ca.paa)); }; class GVAR(CheckTemperature) { displayName = CSTRING(CheckTemperatureShort); - condition = "switch (currentWeapon _target) do {case (''): {false}; case (primaryWeapon _target); case (handgunWeapon _target): {true}; default {false}}"; + condition = "ace_overheating_enabled && {switch (currentWeapon _target) do {case (''): {false}; case (primaryWeapon _target); case (handgunWeapon _target): {true}; default {false}}}"; exceptions[] = {"isNotInside", "isNotSitting"}; statement = QUOTE( [ARR_3(_player, _target, currentWeapon _target)] call FUNC(checkTemperature); ); icon = QUOTE(PATHTOF(UI\temp_ca.paa)); diff --git a/addons/overheating/XEH_postInit.sqf b/addons/overheating/XEH_postInit.sqf index 96d518ac9f..e4935b8831 100644 --- a/addons/overheating/XEH_postInit.sqf +++ b/addons/overheating/XEH_postInit.sqf @@ -1,62 +1,69 @@ // by esteldunedain #include "script_component.hpp" -if (isServer) then { - GVAR(pseudoRandomList) = []; - // Construct a list of pseudo random 2D vectors - for "_i" from 0 to 30 do { - GVAR(pseudoRandomList) pushBack [-1 + random 2, -1 + random 2]; - }; - publicVariable QGVAR(pseudoRandomList); +if (hasInterface) then { + // Add keybinds + ["ACE3 Weapons", QGVAR(unjamWeapon), localize LSTRING(UnjamWeapon), + { + // Conditions: canInteract + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; + // Conditions: specific - // Keep track of the temperature of stored spare barrels - GVAR(storedSpareBarrels) = [] call CBA_fnc_hashCreate; + if !(GVAR(enabled) && {[ACE_player] call FUNC(canUnjam)}) exitWith {false}; - // Install event handlers for spare barrels - ["spareBarrelsSendTemperatureHint", FUNC(sendSpareBarrelsTemperaturesHint)] call EFUNC(common,addEventHandler); - ["spareBarrelsLoadCoolest", FUNC(loadCoolestSpareBarrel)] call EFUNC(common,addEventHandler); - - // Schedule cool down calculation of stored spare barrels - [] call FUNC(updateSpareBarrelsTemperaturesThread); + // Statement + [ACE_player, currentMuzzle ACE_player, false] call FUNC(clearJam); + true + }, + {false}, + [19, [true, false, false]], false] call CBA_fnc_addKeybind; //SHIFT + R Key }; - -if !(hasInterface) exitWith {}; - -GVAR(cacheWeaponData) = call CBA_fnc_createNamespace; -GVAR(cacheAmmoData) = call CBA_fnc_createNamespace; -GVAR(cacheSilencerData) = call CBA_fnc_createNamespace; - -// Add keybinds -["ACE3 Weapons", QGVAR(unjamWeapon), localize LSTRING(UnjamWeapon), -{ - // Conditions: canInteract - if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; - // Conditions: specific - - if !([ACE_player] call FUNC(canUnjam)) exitWith {false}; - - // Statement - [ACE_player, currentMuzzle ACE_player, false] call FUNC(clearJam); - true -}, -{false}, -[19, [true, false, false]], false] call CBA_fnc_addKeybind; //SHIFT + R Key - - -// Schedule cool down calculation of player weapons at (infrequent) regular intervals -[] call FUNC(updateTemperatureThread); - ["SettingsInitialized", { + TRACE_1("SettingsInitialized eh", GVAR(enabled)); + if (!GVAR(enabled)) exitWith {}; + + if (isServer) then { + GVAR(pseudoRandomList) = []; + // Construct a list of pseudo random 2D vectors + for "_i" from 0 to 30 do { + GVAR(pseudoRandomList) pushBack [-1 + random 2, -1 + random 2]; + }; + publicVariable QGVAR(pseudoRandomList); + + // Keep track of the temperature of stored spare barrels + GVAR(storedSpareBarrels) = [] call CBA_fnc_hashCreate; + + // Install event handlers for spare barrels + ["spareBarrelsSendTemperatureHint", FUNC(sendSpareBarrelsTemperaturesHint)] call EFUNC(common,addEventHandler); + ["spareBarrelsLoadCoolest", FUNC(loadCoolestSpareBarrel)] call EFUNC(common,addEventHandler); + + // Schedule cool down calculation of stored spare barrels + [] call FUNC(updateSpareBarrelsTemperaturesThread); + }; + + if !(hasInterface) exitWith {}; + + GVAR(cacheWeaponData) = call CBA_fnc_createNamespace; + GVAR(cacheAmmoData) = call CBA_fnc_createNamespace; + GVAR(cacheSilencerData) = call CBA_fnc_createNamespace; + + //Add Take EH (for reload) + ["CAManBase", "Take", {_this call FUNC(handleTakeEH);}] call CBA_fnc_addClassEventHandler; + // Register fire event handler ["firedPlayer", DFUNC(firedEH)] call EFUNC(common,addEventHandler); // Only add eh to non local players if dispersion is enabled if (GVAR(overheatingDispersion)) then { ["firedPlayerNonLocal", DFUNC(firedEH)] call EFUNC(common,addEventHandler); }; -}] call EFUNC(common,addEventHandler); -// Install event handler to display temp when a barrel was swapped -["showWeaponTemperature", DFUNC(displayTemperature)] call EFUNC(common,addEventHandler); -// Install event handler to initiate an assisted barrel swap -["initiateSwapBarrelAssisted", DFUNC(swapBarrel)] call EFUNC(common,addEventHandler); + // Schedule cool down calculation of player weapons at (infrequent) regular intervals + [] call FUNC(updateTemperatureThread); + + // Install event handler to display temp when a barrel was swapped + ["showWeaponTemperature", DFUNC(displayTemperature)] call EFUNC(common,addEventHandler); + // Install event handler to initiate an assisted barrel swap + ["initiateSwapBarrelAssisted", DFUNC(swapBarrel)] call EFUNC(common,addEventHandler); + +}] call EFUNC(common,addEventHandler); diff --git a/addons/overheating/functions/fnc_swapBarrelCallback.sqf b/addons/overheating/functions/fnc_swapBarrelCallback.sqf index 339b6627b1..403989deca 100644 --- a/addons/overheating/functions/fnc_swapBarrelCallback.sqf +++ b/addons/overheating/functions/fnc_swapBarrelCallback.sqf @@ -15,7 +15,7 @@ * * Public: No */ -#define DEBUG_MODE_FULL +// #define DEBUG_MODE_FULL #include "script_component.hpp" params ["_assistant", "_gunner", "_weapon"]; diff --git a/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf index 852cb1c580..d6b74f6769 100644 --- a/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf +++ b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf @@ -13,7 +13,7 @@ * * Public: No */ -#define DEBUG_MODE_FULL +// #define DEBUG_MODE_FULL #include "script_component.hpp" private _pairs = []; diff --git a/addons/overheating/stringtable.xml b/addons/overheating/stringtable.xml index 3eb67701de..e49ad433fc 100644 --- a/addons/overheating/stringtable.xml +++ b/addons/overheating/stringtable.xml @@ -282,7 +282,15 @@ Very Hot Spare Barrel/s - Extremele Hot Spare Barrel/s + Extremely Hot Spare Barrel/s + + + Overheating Enabled + Überhitzen Aktiviert + Activada Sobrecalentamiento + + + Master enable for the overheating/jamming module \ No newline at end of file From 28c65c4bed0a87c09eef0ce10cb9bb46df481fe3 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 5 May 2016 14:36:56 -0500 Subject: [PATCH 159/215] Fix explosive sync on dedi --- addons/explosives/XEH_postInit.sqf | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/addons/explosives/XEH_postInit.sqf b/addons/explosives/XEH_postInit.sqf index 57cbecba75..fe12a88b7f 100644 --- a/addons/explosives/XEH_postInit.sqf +++ b/addons/explosives/XEH_postInit.sqf @@ -27,18 +27,7 @@ if (isServer) then { TRACE_1("Knocked Out, Doing Deadman", _unit); [_unit] call FUNC(onIncapacitated); }] call EFUNC(common,addEventHandler); -}; -if (!hasInterface) exitWith {}; - -GVAR(PlacedCount) = 0; -GVAR(Setup) = objNull; -GVAR(pfeh_running) = false; -GVAR(CurrentSpeedDial) = 0; - -// In case we are a JIP client, ask the server for orientation of any previously -// placed mine. -if (isServer) then { ["clientRequestsOrientations", { params ["_logic"]; TRACE_1("clientRequestsOrientations received:",_logic); @@ -50,7 +39,18 @@ if (isServer) then { TRACE_1("serverSendsOrientations sent:",GVAR(explosivesOrientations)); ["serverSendsOrientations", _logic, [GVAR(explosivesOrientations)]] call EFUNC(common,targetEvent); }] call EFUNC(common,addEventHandler); -} else { +}; + +if (!hasInterface) exitWith {}; + +GVAR(PlacedCount) = 0; +GVAR(Setup) = objNull; +GVAR(pfeh_running) = false; +GVAR(CurrentSpeedDial) = 0; + +// In case we are a JIP client, ask the server for orientation of any previously +// placed mine. +if (didJIP) then { ["serverSendsOrientations", { params ["_explosivesOrientations"]; TRACE_1("serverSendsOrientations received:",_explosivesOrientations); @@ -59,14 +59,12 @@ if (isServer) then { TRACE_3("orientation set:",_explosive,_direction,_pitch); [_explosive, _direction, _pitch] call FUNC(setPosition); } forEach _explosivesOrientations; - private _group = group GVAR(localLogic); deleteVehicle GVAR(localLogic); GVAR(localLogic) = nil; - deleteGroup _group; }] call EFUNC(common,addEventHandler); // Create a logic to get the client ID - GVAR(localLogic) = (createGroup sideLogic) createUnit ["Logic", [0,0,0], [], 0, "NONE"]; + GVAR(localLogic) = ([sideLogic] call CBA_fnc_getSharedGroup) createUnit ["Logic", [0,0,0], [], 0, "NONE"]; TRACE_1("clientRequestsOrientations sent:",GVAR(localLogic)); ["clientRequestsOrientations", [GVAR(localLogic)]] call EFUNC(common,serverEvent); }; From 9b46e77f662faf4212ec0579b704f901864ad0e5 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 6 May 2016 12:47:59 -0500 Subject: [PATCH 160/215] Add key to toggle wind info display --- addons/weather/XEH_postInit.sqf | 13 +++++++++++++ addons/weather/stringtable.xml | 12 ++++++++++++ 2 files changed, 25 insertions(+) diff --git a/addons/weather/XEH_postInit.sqf b/addons/weather/XEH_postInit.sqf index a19e000332..9c32634060 100644 --- a/addons/weather/XEH_postInit.sqf +++ b/addons/weather/XEH_postInit.sqf @@ -39,6 +39,19 @@ GVAR(WindInfo) = false; }, {false}, [37, [true, false, false]], false, 0] call CBA_fnc_addKeybind; // (SHIFT + K) +["ACE3 Common", QGVAR(WindInfoKey_hold), localize LSTRING(WindInfoKey_hold), +{ + // Conditions: canInteract + if !([ACE_player, ACE_player, []] call EFUNC(common,canInteractWith)) exitWith {false}; + + // Statement + [] call FUNC(displayWindInfo); +}, +{ + GVAR(WindInfo) = false; + (["RscWindIntuitive"] call BIS_fnc_rscLayer) cutText ["", "PLAIN", 2]; +}, +[0, [false, false, false]], false, 0] call CBA_fnc_addKeybind; // (empty default key) simulWeatherSync; diff --git a/addons/weather/stringtable.xml b/addons/weather/stringtable.xml index 0b0ed8fd17..571fa9c25a 100644 --- a/addons/weather/stringtable.xml +++ b/addons/weather/stringtable.xml @@ -13,6 +13,18 @@ Zobrazit údaje o větru Mostrar informação do vento + + Show Wind Info (Toggle) + Pokaż inf. o wietrze (przełącz) + Показать информацию о ветре (перекл.) + Afficher information sur le vent (bascule) + Mostrar información del viento (cambiar) + Mostra informazioni sul vento (camb.) + Zeige Windinformationen (umsch.) + Széladatok mutatása (pecek) + Zobrazit údaje o větru (přep.) + Mostrar informação do vento (alternar) + Weather Pogoda From b8abec0c61806ec9b90fe71aacde13dc8ce14bda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ozan=20E=C4=9Fitmen?= Date: Sat, 7 May 2016 23:14:56 +0300 Subject: [PATCH 161/215] Fix Capitalization of ACE Settings classes. (#3627) --- addons/common/ACE_Settings.hpp | 2 +- addons/common/functions/fnc_progressBar.sqf | 2 +- addons/explosives/ACE_Settings.hpp | 6 +++--- addons/frag/ACE_Settings.hpp | 10 +++++----- addons/hearing/ACE_Settings.hpp | 8 ++++---- addons/interact_menu/ACE_Settings.hpp | 6 +++--- addons/interaction/ACE_Settings.hpp | 2 +- addons/magazinerepack/ACE_Settings.hpp | 6 +++--- addons/map/ACE_Settings.hpp | 2 +- addons/map_gestures/ACE_Settings.hpp | 12 ++++++------ addons/maptools/ACE_Settings.hpp | 2 +- addons/microdagr/ACE_Settings.hpp | 2 +- addons/overheating/ACE_Settings.hpp | 2 +- addons/reload/ACE_Settings.hpp | 2 +- addons/repair/ACE_Settings.hpp | 10 +++++----- addons/respawn/ACE_Settings.hpp | 6 +++--- addons/switchunits/ACE_Settings.hpp | 14 +++++++------- addons/vehiclelock/ACE_Settings.hpp | 6 +++--- addons/weaponselect/ACE_Settings.hpp | 2 +- 19 files changed, 51 insertions(+), 51 deletions(-) diff --git a/addons/common/ACE_Settings.hpp b/addons/common/ACE_Settings.hpp index d6226fd0ab..2d8a5d7a27 100644 --- a/addons/common/ACE_Settings.hpp +++ b/addons/common/ACE_Settings.hpp @@ -49,7 +49,7 @@ class ACE_Settings { description = CSTRING(SettingFeedbackIconsDesc); values[] = {ECSTRING(optionsmenu,Hide), ECSTRING(optionsmenu,TopRightDown), ECSTRING(optionsmenu,TopRightLeft), ECSTRING(optionsmenu,TopLeftDown), ECSTRING(optionsmenu,TopLeftRight)}; }; - class GVAR(SettingProgressBarLocation) { + class GVAR(settingProgressBarLocation) { value = 0; typeName = "SCALAR"; force = 0; diff --git a/addons/common/functions/fnc_progressBar.sqf b/addons/common/functions/fnc_progressBar.sqf index e842590f35..6129f14a65 100644 --- a/addons/common/functions/fnc_progressBar.sqf +++ b/addons/common/functions/fnc_progressBar.sqf @@ -34,7 +34,7 @@ createDialog QGVAR(ProgressBar_Dialog); //Adjust position based on user setting: private _ctrlPos = ctrlPosition (uiNamespace getVariable QGVAR(ctrlProgressBarTitle)); -_ctrlPos set [1, ((0 + 29 * GVAR(SettingProgressBarLocation)) * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2))]; +_ctrlPos set [1, ((0 + 29 * GVAR(settingProgressBarLocation)) * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2))]; (uiNamespace getVariable QGVAR(ctrlProgressBG)) ctrlSetPosition _ctrlPos; (uiNamespace getVariable QGVAR(ctrlProgressBG)) ctrlCommit 0; diff --git a/addons/explosives/ACE_Settings.hpp b/addons/explosives/ACE_Settings.hpp index ceb6b62d25..e103b6e018 100644 --- a/addons/explosives/ACE_Settings.hpp +++ b/addons/explosives/ACE_Settings.hpp @@ -1,17 +1,17 @@ class ACE_Settings { - class GVAR(RequireSpecialist) { + class GVAR(requireSpecialist) { displayName = CSTRING(RequireSpecialist_DisplayName); description = CSTRING(RequireSpecialist_Description); value = 0; typeName = "BOOL"; }; - class GVAR(PunishNonSpecialists) { + class GVAR(punishNonSpecialists) { displayName = CSTRING(PunishNonSpecialists_DisplayName); description = CSTRING(PunishNonSpecialists_Description); value = 1; typeName = "BOOL"; }; - class GVAR(ExplodeOnDefuse) { + class GVAR(explodeOnDefuse) { displayName = CSTRING(ExplodeOnDefuse_DisplayName); description = CSTRING(ExplodeOnDefuse_Description); value = 1; diff --git a/addons/frag/ACE_Settings.hpp b/addons/frag/ACE_Settings.hpp index 3e1c83839b..4dfa172bb3 100644 --- a/addons/frag/ACE_Settings.hpp +++ b/addons/frag/ACE_Settings.hpp @@ -1,19 +1,19 @@ class ACE_Settings { - class GVAR(Enabled) { + class GVAR(enabled) { category = CSTRING(Module_DisplayName); displayName = CSTRING(EnableFrag); description = CSTRING(EnableFrag_Desc); typeName = "BOOL"; value = 1; }; - class GVAR(SpallEnabled) { + class GVAR(spallEnabled) { category = CSTRING(Module_DisplayName); displayName = CSTRING(EnableSpall); description = CSTRING(EnableSpall_Desc); typeName = "BOOL"; value = 0; }; - class GVAR(ReflectionsEnabled) { + class GVAR(reflectionsEnabled) { category = CSTRING(Module_DisplayName); displayName = CSTRING(EnableReflections); description = CSTRING(EnableReflections_Desc); @@ -27,7 +27,7 @@ class ACE_Settings { typeName = "SCALAR"; value = 500; }; - class GVAR(MaxTrackPerFrame) { + class GVAR(maxTrackPerFrame) { category = CSTRING(Module_DisplayName); displayName = CSTRING(MaxTrackPerFrame); description = CSTRING(MaxTrackPerFrame_Desc); @@ -35,7 +35,7 @@ class ACE_Settings { value = 50; }; - class GVAR(EnableDebugTrace) { + class GVAR(enableDebugTrace) { category = CSTRING(Module_DisplayName); displayName = CSTRING(EnableDebugTrace); description = CSTRING(EnableDebugTrace_Desc); diff --git a/addons/hearing/ACE_Settings.hpp b/addons/hearing/ACE_Settings.hpp index dcae85fa25..2fb2a46211 100644 --- a/addons/hearing/ACE_Settings.hpp +++ b/addons/hearing/ACE_Settings.hpp @@ -1,22 +1,22 @@ class ACE_Settings { - class GVAR(EnableCombatDeafness) { + class GVAR(enableCombatDeafness) { category = CSTRING(Module_DisplayName); value = 1; typeName = "BOOL"; displayName = CSTRING(EnableCombatDeafness_DisplayName); description = CSTRING(EnableCombatDeafness_Description); }; - class GVAR(EarplugsVolume) { + class GVAR(earplugsVolume) { category = CSTRING(Module_DisplayName); value = 0.5; typeName = "SCALAR"; }; - class GVAR(UnconsciousnessVolume) { + class GVAR(unconsciousnessVolume) { category = CSTRING(Module_DisplayName); value = 0.4; typeName = "SCALAR"; }; - class GVAR(DisableEarRinging) { + class GVAR(disableEarRinging) { category = CSTRING(Module_DisplayName); value = 0; typeName = "BOOL"; diff --git a/addons/interact_menu/ACE_Settings.hpp b/addons/interact_menu/ACE_Settings.hpp index 075408499b..a36d3dd98d 100644 --- a/addons/interact_menu/ACE_Settings.hpp +++ b/addons/interact_menu/ACE_Settings.hpp @@ -1,5 +1,5 @@ class ACE_Settings { - class GVAR(AlwaysUseCursorSelfInteraction) { + class GVAR(alwaysUseCursorSelfInteraction) { value = 0; typeName = "BOOL"; isClientSettable = 1; @@ -14,14 +14,14 @@ class ACE_Settings { displayName = CSTRING(cursorKeepCentered); description = CSTRING(cursorKeepCenteredDescription); }; - class GVAR(AlwaysUseCursorInteraction) { + class GVAR(alwaysUseCursorInteraction) { value = 0; typeName = "BOOL"; isClientSettable = 1; category = CSTRING(Category_InteractionMenu); displayName = CSTRING(AlwaysUseCursorInteraction); }; - class GVAR(UseListMenu) { + class GVAR(useListMenu) { value = 0; typeName = "BOOL"; isClientSettable = 1; diff --git a/addons/interaction/ACE_Settings.hpp b/addons/interaction/ACE_Settings.hpp index 1cb8b747ef..e95947ec75 100644 --- a/addons/interaction/ACE_Settings.hpp +++ b/addons/interaction/ACE_Settings.hpp @@ -1,6 +1,6 @@ class ACE_Settings { - class GVAR(EnableTeamManagement) { + class GVAR(enableTeamManagement) { displayName = CSTRING(EnableTeamManagement_DisplayName); description = CSTRING(EnableTeamManagement_Description); value = 1; diff --git a/addons/magazinerepack/ACE_Settings.hpp b/addons/magazinerepack/ACE_Settings.hpp index 0b7b2d4628..940af87d15 100644 --- a/addons/magazinerepack/ACE_Settings.hpp +++ b/addons/magazinerepack/ACE_Settings.hpp @@ -1,16 +1,16 @@ class ACE_Settings { //Time to move a round from one magazine to another - class GVAR(TimePerAmmo) { + class GVAR(timePerAmmo) { value = 1.5; typeName = "SCALAR"; }; //Time to swap between magazines when repacking - class GVAR(TimePerMagazine) { + class GVAR(timePerMagazine) { value = 2.0; typeName = "SCALAR"; }; //Time to relink 2 belts together - class GVAR(TimePerBeltLink) { + class GVAR(timePerBeltLink) { value = 8.0; typeName = "SCALAR"; }; diff --git a/addons/map/ACE_Settings.hpp b/addons/map/ACE_Settings.hpp index 6ff2e1e867..b04c7b39b3 100644 --- a/addons/map/ACE_Settings.hpp +++ b/addons/map/ACE_Settings.hpp @@ -62,7 +62,7 @@ class ACE_Settings { displayName = CSTRING(MapShowCursorCoordinates_DisplayName); description = CSTRING(MapShowCursorCoordinates_Description); }; - class GVAR(DefaultChannel) { + class GVAR(defaultChannel) { category = CSTRING(Module_DisplayName); value = -1; typeName = "SCALAR"; diff --git a/addons/map_gestures/ACE_Settings.hpp b/addons/map_gestures/ACE_Settings.hpp index 0038027e3b..3730c08c58 100644 --- a/addons/map_gestures/ACE_Settings.hpp +++ b/addons/map_gestures/ACE_Settings.hpp @@ -44,16 +44,16 @@ class ACE_Settings { typeName = "COLOR"; value[] = {1, 0.88, 0, 0.7}; }; - class GVAR(GroupColorConfigurations) { - displayName = CSTRING(GroupColorConfigurations_displayName); - description = CSTRING(GroupColorConfigurations_description); + class GVAR(groupColorConfigurations) { + displayName = CSTRING(groupColorConfigurations_displayName); + description = CSTRING(groupColorConfigurations_description); category = CSTRING(mapGestures_category); typeName = "ARRAY"; value[] = {}; }; - class GVAR(GroupColorConfigurationMapping) { - displayName = CSTRING(GroupColorConfigurationMapping_displayName); - description = CSTRING(GroupColorConfigurationMapping_description); + class GVAR(groupColorConfigurationMapping) { + displayName = CSTRING(groupColorConfigurationMapping_displayName); + description = CSTRING(groupColorConfigurationMapping_description); category = CSTRING(mapGestures_category); typeName = "ARRAY"; value[] = {{}, {}}; diff --git a/addons/maptools/ACE_Settings.hpp b/addons/maptools/ACE_Settings.hpp index 9c53a84a7c..0a88948a7f 100644 --- a/addons/maptools/ACE_Settings.hpp +++ b/addons/maptools/ACE_Settings.hpp @@ -1,5 +1,5 @@ class ACE_Settings { - class GVAR(EveryoneCanDrawOnBriefing) { + class GVAR(everyoneCanDrawOnBriefing) { value = 1; typeName = "BOOL"; }; diff --git a/addons/microdagr/ACE_Settings.hpp b/addons/microdagr/ACE_Settings.hpp index 637584178c..f1e7595b74 100644 --- a/addons/microdagr/ACE_Settings.hpp +++ b/addons/microdagr/ACE_Settings.hpp @@ -1,5 +1,5 @@ class ACE_Settings { - class GVAR(MapDataAvailable) { + class GVAR(mapDataAvailable) { displayName = CSTRING(MapDataAvailable_DisplayName); description = CSTRING(MapDataAvailable_Description); value = 2; diff --git a/addons/overheating/ACE_Settings.hpp b/addons/overheating/ACE_Settings.hpp index abf08c9874..fc3237da0f 100644 --- a/addons/overheating/ACE_Settings.hpp +++ b/addons/overheating/ACE_Settings.hpp @@ -1,5 +1,5 @@ class ACE_Settings { - class GVAR(DisplayTextOnJam) { + class GVAR(displayTextOnJam) { typeName = "BOOL"; isClientSettable = 1; value = 1; diff --git a/addons/reload/ACE_Settings.hpp b/addons/reload/ACE_Settings.hpp index 7b60527449..72d26b46cf 100644 --- a/addons/reload/ACE_Settings.hpp +++ b/addons/reload/ACE_Settings.hpp @@ -1,5 +1,5 @@ class ACE_Settings { - class GVAR(DisplayText) { + class GVAR(displayText) { typeName = "BOOL"; isClientSettable = 1; value = 1; diff --git a/addons/repair/ACE_Settings.hpp b/addons/repair/ACE_Settings.hpp index 9ee40529e7..46228e2e44 100644 --- a/addons/repair/ACE_Settings.hpp +++ b/addons/repair/ACE_Settings.hpp @@ -1,5 +1,5 @@ class ACE_Settings { - class GVAR(DisplayTextOnRepair) { + class GVAR(displayTextOnRepair) { displayName = CSTRING(SettingDisplayTextName); description = CSTRING(SettingDisplayTextDesc); typeName = "BOOL"; @@ -7,7 +7,7 @@ class ACE_Settings { value = 1; category = ECSTRING(OptionsMenu,CategoryLogistics); }; - class GVAR(engineerSetting_Repair) { + class GVAR(engineerSetting_repair) { displayName = CSTRING(enginerSetting_Repair_name); description = CSTRING(enginerSetting_Repair_description); typeName = "SCALAR"; @@ -15,7 +15,7 @@ class ACE_Settings { values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)}; category = ECSTRING(OptionsMenu,CategoryLogistics); }; - class GVAR(engineerSetting_Wheel) { + class GVAR(engineerSetting_wheel) { displayName = CSTRING(enginerSetting_Wheel_name); description = CSTRING(enginerSetting_Wheel_description); typeName = "SCALAR"; @@ -30,14 +30,14 @@ class ACE_Settings { value = 0.6; category = ECSTRING(OptionsMenu,CategoryLogistics); }; - class GVAR(repairDamageThreshold_Engineer) { + class GVAR(repairDamageThreshold_engineer) { displayName = CSTRING(repairDamageThreshold_Engineer_name); description = CSTRING(repairDamageThreshold_Engineer_description); typeName = "SCALAR"; value = 0.4; category = ECSTRING(OptionsMenu,CategoryLogistics); }; - class GVAR(consumeItem_ToolKit) { + class GVAR(consumeItem_toolKit) { displayName = CSTRING(consumeItem_ToolKit_name); description = CSTRING(consumeItem_ToolKit_description); typeName = "SCALAR"; diff --git a/addons/respawn/ACE_Settings.hpp b/addons/respawn/ACE_Settings.hpp index 86083d6d07..7f0c4f9d96 100644 --- a/addons/respawn/ACE_Settings.hpp +++ b/addons/respawn/ACE_Settings.hpp @@ -1,18 +1,18 @@ class ACE_Settings { - class GVAR(SavePreDeathGear) { + class GVAR(savePreDeathGear) { displayName = CSTRING(SavePreDeathGear_DisplayName); description = CSTRING(SavePreDeathGear_Description); value = 0; typeName = "BOOL"; }; - class GVAR(RemoveDeadBodiesDisconnected) { + class GVAR(removeDeadBodiesDisconnected) { displayName = CSTRING(RemoveDeadBodiesDisconnected_DisplayName); description = CSTRING(RemoveDeadBodiesDisconnected_Description); value = 1; typeName = "BOOL"; }; - class GVAR(BodyRemoveTimer) { + class GVAR(bodyRemoveTimer) { value = 0; typeName = "SCALAR"; }; diff --git a/addons/switchunits/ACE_Settings.hpp b/addons/switchunits/ACE_Settings.hpp index fe15e63e87..e3fc653cb2 100644 --- a/addons/switchunits/ACE_Settings.hpp +++ b/addons/switchunits/ACE_Settings.hpp @@ -1,39 +1,39 @@ class ACE_Settings { - class GVAR(EnableSwitchUnits) { + class GVAR(enableSwitchUnits) { value = 0; typeName = "BOOL"; }; - class GVAR(SwitchToWest) { + class GVAR(switchToWest) { displayName = CSTRING(SwitchToWest_DisplayName); description = CSTRING(SwitchToWest_Description); value = 0; typeName = "BOOL"; }; - class GVAR(SwitchToEast) { + class GVAR(switchToEast) { displayName = CSTRING(SwitchToEast_DisplayName); description = CSTRING(SwitchToEast_Description); value = 0; typeName = "BOOL"; }; - class GVAR(SwitchToIndependent) { + class GVAR(switchToIndependent) { displayName = CSTRING(SwitchToIndependent_DisplayName); description = CSTRING(SwitchToIndependent_Description); value = 0; typeName = "BOOL"; }; - class GVAR(SwitchToCivilian) { + class GVAR(switchToCivilian) { displayName = CSTRING(SwitchToCivilian_DisplayName); description = CSTRING(SwitchToCivilian_Description); value = 0; typeName = "BOOL"; }; - class GVAR(EnableSafeZone) { + class GVAR(enableSafeZone) { displayName = CSTRING(EnableSafeZone_DisplayName); description = CSTRING(EnableSafeZone_Description); value = 1; typeName = "BOOL"; }; - class GVAR(SafeZoneRadius) { + class GVAR(safeZoneRadius) { displayName = CSTRING(SafeZoneRadius_DisplayName); description = CSTRING(SafeZoneRadius_Description); value = 100; diff --git a/addons/vehiclelock/ACE_Settings.hpp b/addons/vehiclelock/ACE_Settings.hpp index fabc8b94ad..f8a431410f 100644 --- a/addons/vehiclelock/ACE_Settings.hpp +++ b/addons/vehiclelock/ACE_Settings.hpp @@ -1,17 +1,17 @@ class ACE_Settings { - class GVAR(DefaultLockpickStrength) { + class GVAR(defaultLockpickStrength) { displayName = CSTRING(DefaultLockpickStrength_DisplayName); description = CSTRING(DefaultLockpickStrength_Description); value = 10; typeName = "SCALAR"; }; - class GVAR(LockVehicleInventory) { + class GVAR(lockVehicleInventory) { displayName = CSTRING(LockVehicleInventory_DisplayName); description = CSTRING(LockVehicleInventory_Description); value = 0; typeName = "BOOL"; }; - class GVAR(VehicleStartingLockState) { + class GVAR(vehicleStartingLockState) { displayName = CSTRING(VehicleStartingLockState_DisplayName); description = CSTRING(VehicleStartingLockState_Description); value = -1; diff --git a/addons/weaponselect/ACE_Settings.hpp b/addons/weaponselect/ACE_Settings.hpp index 2214451247..5b58659f6e 100644 --- a/addons/weaponselect/ACE_Settings.hpp +++ b/addons/weaponselect/ACE_Settings.hpp @@ -1,6 +1,6 @@ class ACE_Settings { - class GVAR(DisplayText) { + class GVAR(displayText) { typeName = "BOOL"; isClientSettable = 1; value = 1; From 4a8e727ba5ac8e2e77d7258418019c3e94810084 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 7 May 2016 22:17:21 +0200 Subject: [PATCH 162/215] end spectator by global mission end event from server (#3659) * end spectator by global mission end event from server * add ; --- addons/spectator/XEH_postInit.sqf | 12 +++++++++++- addons/spectator/functions/fnc_setSpectator.sqf | 2 +- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/addons/spectator/XEH_postInit.sqf b/addons/spectator/XEH_postInit.sqf index 4b1f653223..43c812d1a2 100644 --- a/addons/spectator/XEH_postInit.sqf +++ b/addons/spectator/XEH_postInit.sqf @@ -16,4 +16,14 @@ if (isServer) then { }; // Should prevent unending spectator on mission end -addMissionEventHandler ["Ended",{ [QGVAR(EndMission)] call FUNC(interrupt) }]; +if (isServer) then { + addMissionEventHandler ["Ended", { + [QGVAR(endMission), []] call EFUNC(common,globalEvent); + }]; +}; + +[QGVAR(endMission), { + if (GVAR(isSet)) then { + [false] call FUNC(setSpectator); + }; +}] call EFUNC(common,addEventHandler); diff --git a/addons/spectator/functions/fnc_setSpectator.sqf b/addons/spectator/functions/fnc_setSpectator.sqf index ce9428cea4..1f010962b5 100644 --- a/addons/spectator/functions/fnc_setSpectator.sqf +++ b/addons/spectator/functions/fnc_setSpectator.sqf @@ -92,7 +92,7 @@ if (_set) then { if (_this) then { _display displayAddEventHandler ["KeyDown", { if (_this select 1 == 1) then { - [false] call ace_spectator_fnc_setSpectator; + [false] call FUNC(setSpectator); true }; }]; From fd8167b7e7471b34d9e577575cf4a792b1d134f6 Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Sat, 7 May 2016 22:20:50 +0200 Subject: [PATCH 163/215] AB - correct mildot reticle LRPS/AMS/KHS (#3664) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * correct mildot reticle LRPS/AMS/KHS correct mildot reticle LRPS/AMS/KHS * replace 1 tab with 1 space replace 1 tab with 1 space * fix tab * ace_scope : correct mildot reticle for LRPS and SOS 2D/PiP SFP scopes ace_scope : correct mildot reticle for LRPS and SOS 2D/PiP SFP scopes, same opticszoommax/min for each scopes : 1µ (1meter for 1000meter) / 4µ (4meter for 1000meter), LRPS : variable magnification / SOS : 2 magnifications --- addons/optics/CfgWeapons.hpp | 12 ++++++--- addons/scopes/CfgWeapons.hpp | 52 +++++++++++++++++++++++------------- 2 files changed, 43 insertions(+), 21 deletions(-) diff --git a/addons/optics/CfgWeapons.hpp b/addons/optics/CfgWeapons.hpp index 1be66d3aa2..2089a1dc80 100644 --- a/addons/optics/CfgWeapons.hpp +++ b/addons/optics/CfgWeapons.hpp @@ -228,6 +228,12 @@ class CfgWeapons { class OpticsModes: OpticsModes { class Snip: Snip { modelOptics[] = {QUOTE(PATHTOF(models\ace_optics_reticle90.p3d)),QUOTE(PATHTOF(models\ace_optics_reticle90.p3d))}; + useModelOptics = 1; + opticsZoomInit = 0.0116; + opticsZoomMax = 0.0464; + opticsZoomMin = 0.0116; + discreteFOV[] = {0.0464, 0.0116}; + opticsPPEffects[] = {"OpticsCHAbera1","OpticsBlur1","ACE_OpticsRadBlur1"}; opticsDisablePeripherialVision = 0; }; class Iron: Iron {}; @@ -275,9 +281,9 @@ class CfgWeapons { class Snip: Snip { modelOptics[] = {QUOTE(PATHTOF(models\ace_optics_reticle90.p3d)),QUOTE(PATHTOF(models\ace_optics_reticle90.p3d))}; useModelOptics = 1; - opticsZoomInit = 0.01234; - opticsZoomMax = 0.04673; - opticsZoomMin = 0.01234; + opticsZoomInit = 0.0116; + opticsZoomMax = 0.0464; + opticsZoomMin = 0.0116; discreteFOV[] = {}; opticsPPEffects[] = {"OpticsCHAbera1","OpticsBlur1","ACE_OpticsRadBlur1"}; opticsDisablePeripherialVision = 0; diff --git a/addons/scopes/CfgWeapons.hpp b/addons/scopes/CfgWeapons.hpp index eb1d8400a2..cd87167f22 100644 --- a/addons/scopes/CfgWeapons.hpp +++ b/addons/scopes/CfgWeapons.hpp @@ -3,14 +3,18 @@ class CfgWeapons { class InventoryOpticsItem_Base_F; class optic_LRPS : ItemCore { - ACE_ScopeAdjust_Vertical[] = { -4, 30 }; - ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; + ACE_ScopeAdjust_Vertical[] = {-4, 30}; + ACE_ScopeAdjust_Horizontal[] = {-6, 6}; ACE_ScopeAdjust_VerticalIncrement = 0.1; ACE_ScopeAdjust_HorizontalIncrement = 0.1; class ItemInfo : InventoryOpticsItem_Base_F { class OpticsModes { class Snip { - discreteDistance[] = { 100 }; + opticsZoomMin = 0.011; + opticsZoomMax = 0.045; + opticsZoomInit = 0.045; + discretefov[] = {0.045, 0.011}; + discreteDistance[] = {100}; discreteDistanceInitIndex = 0; }; }; @@ -18,14 +22,14 @@ class CfgWeapons { }; class optic_SOS : ItemCore { - ACE_ScopeAdjust_Vertical[] = { -4, 30 }; - ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; + ACE_ScopeAdjust_Vertical[] = {-4, 30}; + ACE_ScopeAdjust_Horizontal[] = {-6, 6}; ACE_ScopeAdjust_VerticalIncrement = 0.1; ACE_ScopeAdjust_HorizontalIncrement = 0.1; class ItemInfo : InventoryOpticsItem_Base_F { class OpticsModes { class Snip { - discreteDistance[] = { 100 }; + discreteDistance[] = {100}; discreteDistanceInitIndex = 0; }; }; @@ -33,14 +37,14 @@ class CfgWeapons { }; class optic_DMS : ItemCore { - ACE_ScopeAdjust_Vertical[] = { -4, 20 }; - ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; + ACE_ScopeAdjust_Vertical[] = {-4, 20}; + ACE_ScopeAdjust_Horizontal[] = {-6, 6}; ACE_ScopeAdjust_VerticalIncrement = 0.1; ACE_ScopeAdjust_HorizontalIncrement = 0.1; class ItemInfo : InventoryOpticsItem_Base_F { class OpticsModes { class Snip { - discreteDistance[] = { 100 }; + discreteDistance[] = {100}; discreteDistanceInitIndex = 0; }; }; @@ -48,14 +52,18 @@ class CfgWeapons { }; class optic_AMS_base : ItemCore { - ACE_ScopeAdjust_Vertical[] = { -4, 30 }; - ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; + ACE_ScopeAdjust_Vertical[] = {-4, 30}; + ACE_ScopeAdjust_Horizontal[] = {-6, 6}; ACE_ScopeAdjust_VerticalIncrement = 0.1; ACE_ScopeAdjust_HorizontalIncrement = 0.1; class ItemInfo : InventoryOpticsItem_Base_F { class OpticsModes { class AMS { - discreteDistance[] = { 100 }; + opticsZoomMin = 0.0285; + opticsZoomMax = 0.085; + opticsZoomInit = 0.085; + discretefov[] = {0.085, 0.0285}; + discreteDistance[] = {100}; discreteDistanceInitIndex = 0; }; }; @@ -63,14 +71,18 @@ class CfgWeapons { }; class optic_KHS_base : ItemCore { - ACE_ScopeAdjust_Vertical[] = { -4, 30 }; - ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; + ACE_ScopeAdjust_Vertical[] = {-4, 30}; + ACE_ScopeAdjust_Horizontal[] = {-6, 6}; ACE_ScopeAdjust_VerticalIncrement = 0.1; ACE_ScopeAdjust_HorizontalIncrement = 0.1; class ItemInfo : InventoryOpticsItem_Base_F { class OpticsModes { class KHS { - discreteDistance[] = { 100 }; + opticsZoomMin = 0.026; + opticsZoomMax = 0.06; + opticsZoomInit = 0.06; + discretefov[] = {0.06, 0.026}; + discreteDistance[] = {100}; discreteDistanceInitIndex = 0; }; }; @@ -78,14 +90,18 @@ class CfgWeapons { }; class optic_KHS_old : ItemCore { - ACE_ScopeAdjust_Vertical[] = { -4, 30 }; - ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; + ACE_ScopeAdjust_Vertical[] = {-4, 30}; + ACE_ScopeAdjust_Horizontal[] = {-6, 6}; ACE_ScopeAdjust_VerticalIncrement = 0.1; ACE_ScopeAdjust_HorizontalIncrement = 0.1; class ItemInfo : InventoryOpticsItem_Base_F { class OpticsModes { class KHS { - discreteDistance[] = { 100 }; + opticsZoomMin = 0.026; + opticsZoomMax = 0.06; + opticsZoomInit = 0.06; + discretefov[] = {0.06, 0.026}; + discreteDistance[] = {100}; discreteDistanceInitIndex = 0; }; }; From 8bd4afed6bbfdc7e3faa837967a733f2ee36b2e4 Mon Sep 17 00:00:00 2001 From: Rebel Date: Sat, 7 May 2016 23:23:38 +0300 Subject: [PATCH 164/215] Drag and carry icons. (#3676) --- addons/dragging/UI/icons/box_carry.paa | Bin 0 -> 5625 bytes addons/dragging/UI/icons/box_drag.paa | Bin 0 -> 5625 bytes addons/dragging/UI/icons/person_carry.paa | Bin 0 -> 5625 bytes addons/dragging/UI/icons/person_drag.paa | Bin 0 -> 5625 bytes addons/dragging/functions/fnc_setCarryable.sqf | 4 +++- addons/dragging/functions/fnc_setDraggable.sqf | 4 +++- 6 files changed, 6 insertions(+), 2 deletions(-) create mode 100644 addons/dragging/UI/icons/box_carry.paa create mode 100644 addons/dragging/UI/icons/box_drag.paa create mode 100644 addons/dragging/UI/icons/person_carry.paa create mode 100644 addons/dragging/UI/icons/person_drag.paa diff --git a/addons/dragging/UI/icons/box_carry.paa b/addons/dragging/UI/icons/box_carry.paa new file mode 100644 index 0000000000000000000000000000000000000000..5e9c83057c8df68f73fdc54dfbecdc4292570eed GIT binary patch literal 5625 zcmdT|e@s<%6hHU%F26*;@Ku5c>QkIQ(4jH4luI@66|T4SE~8w{M5LKW|K$1yc@j=@ zjYk%>S_`)9pO)p1y46;|aw7^S+LmGvPp1ye6_1cTkoWlZIrrX&?x`sj4A1U+aK87v z^ZT6d`F>@QmzU#uJg*?fN<@Q$gZVmMn6s8~0bo2YCqI{Q2_MFv$<2LQ!T)Z2b|ny1 zPbI3g5q07-I#5U<0*7&iXmaeeJN8 zZBkU9w&y}n2rulHAw7FwXYi;PLb!>Xz$aCL{&28~->a%i8FK~yqkuRwp5;A8Jgwhq zrLPwp)9q1Zi5B}V)&T)D`0s-(wv&NZjK4ZMf-mo{=*{Mrpl`yf=p)+Nc2A(Li~Z+R zXvzf3mvnN}AfN5e!+skQdefF^>pKua)|V4}(}|X{;lFx@b!#O_x}E(movZMjstBIa z=@g<(rS1*a^UI($Tt9a9w+s9sWkN$gO{)>mm-AneRJEVT2YjFIA5!Pc>UUU3TV?nQ z5e7cF3H~$epZNBLJKti~Lqe5N4|I~yXd451{@NtUY0B-=(;L~(P2G7cKG3KyFdfmf zv)ZDL^gxN1>mTJGIl=Nh++I4)E4wdnd{q>DYPS|MJjeza{Y{S}D2$cc*MB(u0$*(~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^N%4ZQs6gd#->1tD9z|IWD1Sj6 zGt^sK_=!`yR?>N3Ul(eP)KhWlTU+lNcvkHXxYz7pdCedFYMU%my1v5BNlU{8{bLa^ z7O6_E&sgpqE7jP*(8r4$)Tr{B6C~Zjch|g^gKtS?fs=pMeNNbThs$4l{H2m!cg##F zYrYg6ahuGK8n%C%JEriIGVjtaI@?%(uKdT+Uz(=d^Zp}5ZP`YNBYIYGOG=waY5Oie ztwrF&;p&)*d+D!0jphH`sXj5Nx}l+K+Wa%E@qOX=elj~H%aUT$w0?thE3{r!_{w0z z3FpCLqKBHssxQLv4!$QqILCTr_d9iuIM-DWZX3qjubz4F;DPW+l<-Orct3V>CS!-7 zA<~5Oqd(gMH&zl3@Gf|B*SQ}CVuuO$dO0r~4tE@Qu}-ED?apDR zX0rQXNI{X)nD)(yz)rW@a6Z*-d=QS6L@vuEJ&mEkzlFOVY$Y~CS1WoI*%8$Igxf1L tw&a7Z=ub;(eoZ*Q!;V>vd2`$>F)a@s!Jom-=YRYB!6#&q01Ckb{|BEd0tWy9 literal 0 HcmV?d00001 diff --git a/addons/dragging/functions/fnc_setCarryable.sqf b/addons/dragging/functions/fnc_setCarryable.sqf index 9e15e42446..0253c6ed4b 100644 --- a/addons/dragging/functions/fnc_setCarryable.sqf +++ b/addons/dragging/functions/fnc_setCarryable.sqf @@ -43,7 +43,9 @@ if (_type in _initializedClasses) exitWith {}; _initializedClasses pushBack _type; GVAR(initializedClasses_carry) = _initializedClasses; -private _carryAction = [QGVAR(carry), localize LSTRING(Carry), "", {[_player, _target] call FUNC(startCarry)}, {[_player, _target] call FUNC(canCarry)}] call EFUNC(interact_menu,createAction); +private _icon = [QUOTE(PATHTOF(UI\icons\box_carry.paa)), QUOTE(PATHTOF(UI\icons\person_carry.paa))] select (_object isKindOf "Man"); + +private _carryAction = [QGVAR(carry), localize LSTRING(Carry), _icon, {[_player, _target] call FUNC(startCarry)}, {[_player, _target] call FUNC(canCarry)}] call EFUNC(interact_menu,createAction); private _dropAction = [QGVAR(drop_carry), localize LSTRING(Drop), "", {[_player, _target] call FUNC(dropObject_carry)}, {[_player, _target] call FUNC(canDrop_carry)}] call EFUNC(interact_menu,createAction); [_type, 0, ["ACE_MainActions"], _carryAction] call EFUNC(interact_menu,addActionToClass); diff --git a/addons/dragging/functions/fnc_setDraggable.sqf b/addons/dragging/functions/fnc_setDraggable.sqf index 0adcb624d8..4c4d11ecf6 100644 --- a/addons/dragging/functions/fnc_setDraggable.sqf +++ b/addons/dragging/functions/fnc_setDraggable.sqf @@ -44,7 +44,9 @@ if (_type in _initializedClasses) exitWith {}; _initializedClasses pushBack _type; GVAR(initializedClasses) = _initializedClasses; -private _dragAction = [QGVAR(drag), localize LSTRING(Drag), "", {[_player, _target] call FUNC(startDrag)}, {[_player, _target] call FUNC(canDrag)}] call EFUNC(interact_menu,createAction); +private _icon = [QUOTE(PATHTOF(UI\icons\box_drag.paa)), QUOTE(PATHTOF(UI\icons\person_drag.paa))] select (_object isKindOf "Man"); + +private _dragAction = [QGVAR(drag), localize LSTRING(Drag), _icon, {[_player, _target] call FUNC(startDrag)}, {[_player, _target] call FUNC(canDrag)}] call EFUNC(interact_menu,createAction); private _dropAction = [QGVAR(drop), localize LSTRING(Drop), "", {[_player, _target] call FUNC(dropObject)}, {[_player, _target] call FUNC(canDrop)}] call EFUNC(interact_menu,createAction); [_type, 0, ["ACE_MainActions"], _dragAction] call EFUNC(interact_menu,addActionToClass); From 174262904534eabef674e76cead1fa0eb1ee7c55 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 7 May 2016 15:26:02 -0500 Subject: [PATCH 165/215] Add NonSteerable Reserve Parachute (#3689) * Add NonSteerable Reserve Parachute Close #3364 * Use params --- addons/parachute/CfgVehicles.hpp | 7 ++++++- addons/parachute/functions/fnc_storeParachute.sqf | 13 +++++++------ 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/addons/parachute/CfgVehicles.hpp b/addons/parachute/CfgVehicles.hpp index ff9196ca60..4127bad166 100644 --- a/addons/parachute/CfgVehicles.hpp +++ b/addons/parachute/CfgVehicles.hpp @@ -83,7 +83,8 @@ class CfgVehicles { //model = "\A3\Weapons_F\Ammoboxes\Bags\Backpack_Parachute"; // @todo // backpackSimulation = "ParachuteNonSteerable"; //ParachuteSteerable //Bis broke this in 1.40 ParachuteClass = "NonSteerable_Parachute_F"; - MACRO_HASRESERVE + ace_hasReserveParachute = 1; + ace_reserveParachute = "ACE_NonSteerableReserveParachute"; maximumLoad = 0; mass = 100; }; @@ -97,6 +98,10 @@ class CfgVehicles { ace_reserveParachute = ""; ace_hasReserveParachute = 0; }; + + class ACE_NonSteerableReserveParachute: ACE_ReserveParachute { + ParachuteClass = "NonSteerable_Parachute_F"; + }; class B_Soldier_05_f; class B_Pilot_F: B_Soldier_05_f {backpack = "ACE_NonSteerableParachute";}; class I_Soldier_04_F; class I_pilot_F: I_Soldier_04_F {backpack = "ACE_NonSteerableParachute";}; diff --git a/addons/parachute/functions/fnc_storeParachute.sqf b/addons/parachute/functions/fnc_storeParachute.sqf index 42ad18b304..55e887f3e6 100644 --- a/addons/parachute/functions/fnc_storeParachute.sqf +++ b/addons/parachute/functions/fnc_storeParachute.sqf @@ -15,16 +15,17 @@ * Public: No */ #include "script_component.hpp" -private ["_unit","_backpack"]; -_unit = _this select 0; -_backpack = (_this select 1) select 6; -if ((vehicle _unit) isKindOf "ParachuteBase" && backpack _unit == "" && !(_unit getVariable [QGVAR(chuteIsCut),false]) && (_unit getVariable [QGVAR(hasReserve),false])) then { + +params ["_unit", "_gear"]; +private _backpack = _gear select 6; + +if ((vehicle _unit) isKindOf "ParachuteBase" && {backpack _unit == ""} && {!(_unit getVariable [QGVAR(chuteIsCut),false])} && {_unit getVariable [QGVAR(hasReserve),false]}) then { _unit addBackpackGlobal (_unit getVariable[QGVAR(backpackClass),"ACE_NonSteerableParachute"]); } else { - if ([false,true] select (getNumber(configFile >> "CfgVehicles" >> _backpack >> "ace_hasReserveParachute"))) then { + if ((getNumber(configFile >> "CfgVehicles" >> _backpack >> "ace_hasReserveParachute")) == 1) then { _unit setVariable[QGVAR(backpackClass),getText(configFile >> "CfgVehicles" >> _backpack >> "ace_reserveParachute"),true]; }; - if (!(_unit getVariable [QGVAR(chuteIsCut),false]) && !(animationState _unit == 'para_pilot')) then { + if (!(_unit getVariable [QGVAR(chuteIsCut),false]) && {!(animationState _unit == 'para_pilot')}) then { _unit setVariable [QGVAR(hasReserve),[false,true] select (getNumber(configFile >> "CfgVehicles" >> _backpack >> "ace_hasReserveParachute")),true]; }; }; From 82f8eb758c68880257c3a2028328e8e2b434b3a7 Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Sat, 7 May 2016 22:27:33 +0200 Subject: [PATCH 166/215] Removed remaining usage of player (#3710) --- addons/common/functions/fnc_setHearingCapability.sqf | 2 +- addons/rearm/functions/fnc_makeDummy.sqf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/common/functions/fnc_setHearingCapability.sqf b/addons/common/functions/fnc_setHearingCapability.sqf index 7bd375a58b..2366081ec1 100644 --- a/addons/common/functions/fnc_setHearingCapability.sqf +++ b/addons/common/functions/fnc_setHearingCapability.sqf @@ -54,5 +54,5 @@ private _lowestVolume = 1; 0 fadeMusic _lowestVolume; // Set Radio mod variables. -player setVariable ["tf_globalVolume", _lowestVolume]; +ACE_player setVariable ["tf_globalVolume", _lowestVolume]; if (!isNil "acre_api_fnc_setGlobalVolume") then { [_lowestVolume^0.33] call acre_api_fnc_setGlobalVolume; }; diff --git a/addons/rearm/functions/fnc_makeDummy.sqf b/addons/rearm/functions/fnc_makeDummy.sqf index 390ff658e0..5c19f8f12d 100644 --- a/addons/rearm/functions/fnc_makeDummy.sqf +++ b/addons/rearm/functions/fnc_makeDummy.sqf @@ -20,4 +20,4 @@ params [["_obj", objNull, [objNull]], ["_dirAndUp", [[1,0,0],[0,0,1]], [[]]]]; _obj setVectorDirAndUp _dirAndUp; _obj allowDamage false; -player disableCollisionWith _obj; +ACE_player disableCollisionWith _obj; From 4eb2ecb0b617befd762c49ca1e4f32190a3d6025 Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Sat, 7 May 2016 22:35:18 +0200 Subject: [PATCH 167/215] Fixed getting stuck on rope whilst fastroping (#3734) --- addons/fastroping/functions/fnc_fastRope.sqf | 2 +- .../fastroping/functions/fnc_fastRopeServerPFH.sqf | 13 +++++++++---- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/addons/fastroping/functions/fnc_fastRope.sqf b/addons/fastroping/functions/fnc_fastRope.sqf index bf2730efc7..adeb536362 100644 --- a/addons/fastroping/functions/fnc_fastRope.sqf +++ b/addons/fastroping/functions/fnc_fastRope.sqf @@ -35,6 +35,6 @@ _deployedRopes set [_usableRopeIndex, _usableRope]; _vehicle setVariable [QGVAR(deployedRopes), _deployedRopes, true]; //Start server PFH asap -[QGVAR(startFastRope), [_unit, _vehicle, _usableRope, _usableRopeIndex]] call EFUNC(common,serverEvent); +[QGVAR(startFastRope), [_unit, _vehicle, _usableRope, _usableRopeIndex, false]] call EFUNC(common,serverEvent); moveOut _unit; [FUNC(fastRopeLocalPFH), 0, [_unit, _vehicle, _usableRope, _usableRopeIndex]] call CBA_fnc_addPerFrameHandler; diff --git a/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf b/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf index ed78d43592..2ebffe680e 100644 --- a/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeServerPFH.sqf @@ -17,7 +17,7 @@ #include "script_component.hpp" params ["_arguments", "_pfhHandle"]; -_arguments params ["_unit", "_vehicle", "_rope", "_ropeIndex"]; +_arguments params ["_unit", "_vehicle", "_rope", "_ropeIndex", "_hasBeenAttached"]; _rope params ["_attachmentPoint", "_ropeTop", "_ropeBottom", "_dummy", "_hook", "_occupied"]; private ["_vectorUp", "_vectorDir", "_origin"]; @@ -37,10 +37,15 @@ if (getMass _dummy != 80) exitWith { ropeUnwind [_ropeBottom, 6, 0.5]; }; -//Check if rope broke and unit is falling +//Check if the player has been attached to the rope yet +if (!_hasBeenAttached && {!(isNull attachedTo _unit)}) then { + _hasBeenAttached = true; + _arguments set [4, true]; +}; + +//Exit when the unit has been detached and is falling (rope broke, heli flew too fast, etc.) //Make sure this isn't executed before the unit is actually fastroping -//Note: Stretching ropes does not change ropeLength -if ((isNull attachedTo _unit) && {ropeLength _ropeTop > 0.5}) exitWith { +if (_hasBeenAttached && {isNull attachedTo _unit}) exitWith { [_pfhHandle] call CBA_fnc_removePerFrameHandler; }; From 9f6661f4db00ecd7586c3bfb118db5ec3274412b Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 7 May 2016 15:35:39 -0500 Subject: [PATCH 168/215] Make 40mm Grenades Frag (#3679) * Make 40mm Grenades Frag * Just use existing force cfg instead of adding new Add RHS compat entries --- addons/frag/CfgAmmo.hpp | 2 + addons/frag/XEH_PREP.hpp | 1 + addons/frag/functions/fnc_dev_debugAmmo.sqf | 62 +++++++++++++++++++++ optionals/compat_rhs_afrf3/CfgAmmo.hpp | 16 ++++++ 4 files changed, 81 insertions(+) create mode 100644 addons/frag/functions/fnc_dev_debugAmmo.sqf diff --git a/addons/frag/CfgAmmo.hpp b/addons/frag/CfgAmmo.hpp index 916949bab2..cd6cc64cfd 100644 --- a/addons/frag/CfgAmmo.hpp +++ b/addons/frag/CfgAmmo.hpp @@ -85,6 +85,7 @@ class CfgAmmo { class G_40mm_HE: GrenadeBase { // Source: http://www.inetres.com/gp/military/infantry/grenade/40mm_ammo.html#M441 GVAR(enabled) = 1; + GVAR(force) = 1; GVAR(classes)[] = {"ACE_frag_tiny_HD"}; GVAR(metal) = 200; @@ -109,6 +110,7 @@ class CfgAmmo { }; class ACE_G_40mm_Practice: ACE_G_40mm_HE { GVAR(skip) = 1; + GVAR(force) = 0; }; class ACE_G40mm_HE_VOG25P: G_40mm_HE { GVAR(skip) = 0; diff --git a/addons/frag/XEH_PREP.hpp b/addons/frag/XEH_PREP.hpp index 926cbaab0c..2fed1630f2 100644 --- a/addons/frag/XEH_PREP.hpp +++ b/addons/frag/XEH_PREP.hpp @@ -1,3 +1,4 @@ +PREP(dev_debugAmmo); PREP(doSpall); PREP(fired); diff --git a/addons/frag/functions/fnc_dev_debugAmmo.sqf b/addons/frag/functions/fnc_dev_debugAmmo.sqf new file mode 100644 index 0000000000..1323639621 --- /dev/null +++ b/addons/frag/functions/fnc_dev_debugAmmo.sqf @@ -0,0 +1,62 @@ +#define DEBUG_MODE_FULL +#include "script_component.hpp" + +params [["_debugMissing", true, [false]], ["_debugForce", false, [false]], ["_debugNonFrag", false, [false]]]; + +diag_log text format ["~~~~~~~~~~~~~Start [%1]~~~~~~~~~~~~~", _this]; + +private _allMagsConfigs = configProperties [configFile >> "CfgMagazines", "isClass _x", true]; +private _processedCfgAmmos = []; + +{ + private _ammo = toLower getText (_x >> "ammo"); + if ((_ammo != "") && {!(_ammo in _processedCfgAmmos)}) then { + _processedCfgAmmos pushBack _ammo; + + //Ignore mines/bombs + if (_ammo isKindOf "TimeBombCore") exitWith {}; + + _ammoConfig = configFile >> "CfgAmmo" >> _ammo; + + //Read configs and test if it would actually cause a frag, using same logic as FUNC(pfhRound) + private _skip = getNumber (_ammoConfig >> QGVAR(skip)); + private _explosive = getNumber (_ammoConfig >> "explosive"); + private _indirectRange = getNumber (_ammoConfig >> "indirectHitRange"); + private _force = getNumber (_ammoConfig >> QGVAR(force)); + private _fragPower = getNumber(_ammoConfig >> "indirecthit")*(sqrt((getNumber (_ammoConfig >> "indirectHitRange")))); + + private _shouldAdd = (_skip == 0) && {(_force == 1) || {_explosive > 0.5 && {_indirectRange >= 4.5} && {_fragPower >= 35}}}; + + if (_shouldAdd) then { + if (_debugForce && {((getNumber(_ammoConfig >> "hit")) < 5) || {_fragPower < 10}}) then { + diag_log text format ["Ammo [%1] from Mag [%2] - Weak but will still frag!",_ammo,configName _x]; + diag_log text format [" - _force=%1,_fragPower=%2",_force,_fragPower]; + }; + + _warn = false; + + _fragTypes = getArray (_ammoConfig >> "ACE_frag_CLASSES"); + if(_fragTypes isEqualTo []) then {_warn = true;}; + _c = getNumber(_ammoConfig >> "ACE_frag_CHARGE"); + if(_c == 0) then {_warn = true;}; + _m = getNumber(_ammoConfig >> "ACE_frag_METAL"); + if(_m == 0) then {_warn = true;}; + _k = getNumber(_ammoConfig >> "ACE_frag_GURNEY_K"); + if(_k == 0) then {_warn = true;}; + _gC = getNumber(_ammoConfig >> "ACE_frag_GURNEY_C"); + if(_gC == 0) then { _warn = true;}; + + if(_debugMissing && _warn) then { + diag_log text format ["Ammo [%1] from Mag [%2] MISSING frag configs:",_ammo,configName _x]; + diag_log text format [" - _c=%1,_m=%2,_k=%3,_gC=%4,_fragTypes=%5",_c,_m,_k,_gC,_fragTypes]; + }; + } else { + if (_debugNonFrag && {isArray (_ammoConfig >> "ACE_frag_CLASSES")}) then { + diag_log text format ["Ammo [%1] from Mag [%2] has frag configs but will NOT frag:",_ammo,configName _x]; + diag_log text format ["- skip=%1,explosive=%2,indirectHitRange=%3,force=%4,fragPower=%5",_skip,_explosive,_indirectRange,_force,_fragPower]; + }; + }; + }; +} forEach _allMagsConfigs; + +diag_log text format ["~~~~~~~~~~~~~End [%1-%2]~~~~~~~~~~~~~", count _allMagsConfigs, count _processedCfgAmmos]; diff --git a/optionals/compat_rhs_afrf3/CfgAmmo.hpp b/optionals/compat_rhs_afrf3/CfgAmmo.hpp index ead78866c1..3a00fdea68 100644 --- a/optionals/compat_rhs_afrf3/CfgAmmo.hpp +++ b/optionals/compat_rhs_afrf3/CfgAmmo.hpp @@ -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; + }; + }; From d79cbe0844b5368c7de0cfb80a0502b5f863643a Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Sat, 7 May 2016 22:37:58 +0200 Subject: [PATCH 169/215] Getmgrsdata update2 (#3736) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * correct mildot reticle LRPS/AMS/KHS correct mildot reticle LRPS/AMS/KHS * replace 1 tab with 1 space replace 1 tab with 1 space * fix tab * ace_scope : correct mildot reticle for LRPS and SOS 2D/PiP SFP scopes ace_scope : correct mildot reticle for LRPS and SOS 2D/PiP SFP scopes, same opticszoommax/min for each scopes : 1µ (1meter for 1000meter) / 4µ (4meter for 1000meter), LRPS : variable magnification / SOS : 2 magnifications * fnc_getMGRSdata.sqf update2 fnc_getMGRSdata.sqf update2 * fnc_getMGRSdata.sqf update2 add new maps, in alphabetic order now --- addons/common/functions/fnc_getMGRSdata.sqf | 81 +++++++++++++++------ 1 file changed, 57 insertions(+), 24 deletions(-) diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index 8da838848a..04c063ac79 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -23,38 +23,71 @@ private _lat = getNumber (configFile >> "CfgWorlds" >> _map >> "latitude"); private _altitude = getNumber (configFile >> "CfgWorlds" >> _map >> "elevationOffset"); _map = toLower _map; -if (_map in ["chernarus", "chernarus_summer", "chernarus_winter", "bootcamp_acr", "woodland_acr", "utes"]) then { _lat = 50; _altitude = 0; }; -if (_map in ["altis", "stratis"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["takistan", "zargabad", "mountains_acr"]) then { _lat = 35; _altitude = 2000; }; -if (_map in ["shapur_baf", "provingGrounds_pmc"]) then { _lat = 35; _altitude = 100; }; +if (_map in ["abbottabad", "abbottabad1"]) then { _lat = 34; _altitude = 1256; }; +if (_map in ["abramia"]) then { _lat = 60; _altitude = 0; }; +if (_map in ["af_kandahar_province"]) then { _lat = 42; _altitude = 0; }; +if (_map in ["altis"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["angel"]) then { _lat = 38; _altitude = 0; }; +if (_map in ["anim_helvantis_v2"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["australia"]) then { _lat = -25; _altitude = 0; }; +if (_map in ["bootcamp_acr"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["bornholm"]) then { _lat = 55; _altitude = 0; }; +if (_map in ["bozcaada"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["caribou"]) then { _lat = 68; _altitude = 0; }; +if (_map in ["chernarus", "chernarus_summer", "chernarus_winter"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["clafghan"]) then { _lat = 34; _altitude = 640; }; +if (_map in ["dakrong"]) then { _lat = 17; _altitude = 0; }; +if (_map in ["desert_e"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["esseker"]) then { _lat = 43; _altitude = 2000; }; if (_map in ["fallujah"]) then { _lat = 33; _altitude = 0; }; if (_map in ["fata"]) then { _lat = 33; _altitude = 1347; }; -if (_map in ["abbottabad"]) then { _lat = 34; _altitude = 1256; }; -if (_map in ["sfp_wamako"]) then { _lat = 14; _altitude = 0; }; -if (_map in ["sfp_sturko"]) then { _lat = 56; _altitude = 0; }; -if (_map in ["bornholm"]) then { _lat = 55; _altitude = 0; }; -if (_map in ["bozcaada", "imrali", "imralispring"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["caribou"]) then { _lat = 68; _altitude = 0; }; -if (_map in ["namalsk"]) then { _lat = 65; _altitude = 0; }; -if (_map in ["mcn_aliabad"]) then { _lat = 36; _altitude = 0; }; -if (_map in ["clafghan"]) then { _lat = 34; _altitude = 640; }; -if (_map in ["sangin", "hellskitchen"]) then { _lat = 32; _altitude = 0; }; -if (_map in ["sara", "sara_dbe1", "saralite", "intro", "desert_e", "porto"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["reshmaan"]) then { _lat = 35; _altitude = 2000; }; -if (_map in ["thirsk"]) then { _lat = 65; _altitude = 0; }; -if (_map in ["lingor", "lingor3"]) then { _lat = -4; _altitude = 0; }; -if (_map in ["panthera3"]) then { _lat = 46; _altitude = 0; }; +if (_map in ["gorgona"]) then { _lat = 43; _altitude = 0; }; +if (_map in ["hellskitchen", "hellskitchens"]) then { _lat = 32; _altitude = 0; }; +if (_map in ["hindukush"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["imrali", "imralispring"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["intro"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["isladuala3"]) then { _lat = -19; _altitude = 0; }; +if (_map in ["jacobi"]) then { _lat = -19; _altitude = 0; }; +if (_map in ["kholm"]) then { _lat = 36; _altitude = 0; }; if (_map in ["kunduz"]) then { _lat = 37; _altitude = 0; }; -if (_map in ["angel"]) then { _lat = 38; _altitude = 0; }; -if (_map in ["porquerolles"]) then { _lat = 43; _altitude = 0; }; -if (_map in ["napf"]) then { _lat = 47; _altitude = 0; }; +if (_map in ["lingor", "lingor3"]) then { _lat = -4; _altitude = 0; }; +if (_map in ["lost", "lostw"]) then { _lat = 60; _altitude = 0; }; +if (_map in ["mcn_aliabad"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["malvinas"]) then { _lat = -52; _altitude = 0; }; +if (_map in ["namalsk"]) then { _lat = 65; _altitude = 0; }; if (_map in ["mef_alaska"]) then { _lat = 60; _altitude = 5; }; -if (_map in ["australia"]) then { _lat = -25; _altitude = 0; }; +if (_map in ["mountains_acr"]) then { _lat = 35; _altitude = 2000; }; +if (_map in ["napf", "napfwinter"]) then { _lat = 47; _altitude = 0; }; +if (_map in ["panthera3"]) then { _lat = 46; _altitude = 0; }; if (_map in ["pja301"]) then { _lat = 42; _altitude = 0; }; if (_map in ["pja305"]) then { _lat = 0; _altitude = 0; }; if (_map in ["pja306"]) then { _lat = 35; _altitude = 300; }; if (_map in ["pja307"]) then { _lat = 17; _altitude = 0; }; -if (_map in ["pja308", "pja310"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["pja308"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["pja310"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["porquerolles"]) then { _lat = 43; _altitude = 0; }; +if (_map in ["porto"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["provingGrounds_pmc"]) then { _lat = 35; _altitude = 100; }; +if (_map in ["reshmaan"]) then { _lat = 35; _altitude = 2000; }; +if (_map in ["sara", "sara_dbe1"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["saralite"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["sb3"]) then { _lat = 53; _altitude = 0; }; +if (_map in ["shapur_baf"]) then { _lat = 35; _altitude = 100; }; +if (_map in ["sfp_sturko"]) then { _lat = 56; _altitude = 0; }; +if (_map in ["sfp_wamako"]) then { _lat = 14; _altitude = 0; }; +if (_map in ["stratis"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["sugarlake"]) then { _lat = 29; _altitude = 0; }; +if (_map in ["takistan"]) then { _lat = 35; _altitude = 2000; }; +if (_map in ["thirsk"]) then { _lat = 65; _altitude = 0; }; +if (_map in ["tilos"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["utes"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["vt5"]) then { _lat = 61; _altitude = 100; }; +if (_map in ["wake"]) then { _lat = 19; _altitude = 0; }; +if (_map in ["wintermap"]) then { _lat = 61; _altitude = 0; }; +if (_map in ["wintertown", "wintertowna3"]) then { _lat = 39; _altitude = 0; }; +if (_map in ["woodland_acr"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["xcam_prototype"]) then { _lat = 35; _altitude = 0; }; +if (_map in ["zargabad"]) then { _lat = 35; _altitude = 2000; }; private _UTM = [_long,_lat] call BIS_fnc_posDegToUTM; private _easting = _UTM select 0; From 2a5ec421487f08faf9e47fdfa7c98ff609d168f1 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 7 May 2016 16:04:27 -0500 Subject: [PATCH 170/215] Repair - Improve wheel detection for RHS (#3760) * Repair - Improve backup wheel detection Fix #3759 * Cleanup --- addons/repair/functions/fnc_getWheelHitPointsWithSelections.sqf | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/repair/functions/fnc_getWheelHitPointsWithSelections.sqf b/addons/repair/functions/fnc_getWheelHitPointsWithSelections.sqf index 2611d10b38..2ed50c5d0e 100644 --- a/addons/repair/functions/fnc_getWheelHitPointsWithSelections.sqf +++ b/addons/repair/functions/fnc_getWheelHitPointsWithSelections.sqf @@ -70,6 +70,8 @@ _wheelHitPointSelections = []; _bestIndex = -1; { if (_x != "") then { + //Filter out things that definitly aren't wheeels (#3759) + if ((toLower (_hitPoints select _forEachIndex)) in ["hitengine", "hitfuel", "hitbody"]) exitWith {TRACE_1("filter",_x)}; _xPos = _vehicle selectionPosition _x; if (_xPos isEqualTo [0,0,0]) exitWith {}; _xDist = _wheelCenterPos distance _xPos; From 7d063d099509924c90e1705f08699ca5acbcf612 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 7 May 2016 23:26:44 +0200 Subject: [PATCH 171/215] Add downloads count shield --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3ead78c57f..37b5f2a626 100644 --- a/README.md +++ b/README.md @@ -3,12 +3,15 @@

- + ACE3 Version ACE3 Issues + + ACE3 Downloads + BIF Thread From a0bd521a4058f9717ee827f3948a969e77c2434c Mon Sep 17 00:00:00 2001 From: jonpas Date: Sat, 7 May 2016 23:48:31 +0200 Subject: [PATCH 172/215] Remove difficulties component --- addons/difficulties/$PBOPREFIX$ | 1 - addons/difficulties/CfgDifficulties.hpp | 33 ------------------------ addons/difficulties/README.md | 12 --------- addons/difficulties/config.cpp | 15 ----------- addons/difficulties/script_component.hpp | 17 ------------ 5 files changed, 78 deletions(-) delete mode 100644 addons/difficulties/$PBOPREFIX$ delete mode 100644 addons/difficulties/CfgDifficulties.hpp delete mode 100644 addons/difficulties/README.md delete mode 100644 addons/difficulties/config.cpp delete mode 100644 addons/difficulties/script_component.hpp diff --git a/addons/difficulties/$PBOPREFIX$ b/addons/difficulties/$PBOPREFIX$ deleted file mode 100644 index 6280fc4731..0000000000 --- a/addons/difficulties/$PBOPREFIX$ +++ /dev/null @@ -1 +0,0 @@ -z\ace\addons\difficulties \ No newline at end of file diff --git a/addons/difficulties/CfgDifficulties.hpp b/addons/difficulties/CfgDifficulties.hpp deleted file mode 100644 index a65d31f1a5..0000000000 --- a/addons/difficulties/CfgDifficulties.hpp +++ /dev/null @@ -1,33 +0,0 @@ - -class CfgDifficulties { - class Mercenary { - class Flags { - armor[] = {0,0}; - friendlyTag[] = {0,0}; - enemyTag[] = {0,0}; - mineTag[] = {0,0}; - hud[] = {0,1};//{1,1}; - hudPerm[] = {0,0}; - hudWp[] = {0,0}; - hudWpPerm[] = {0,0}; - autoSpot[] = {0,1}; - map[] = {0,0}; - weaponCursor[] = {0,1};//{1,1}; - autoGuideAT[] = {0,0}; - clockIndicator[] = {0,0}; - 3rdPersonView[] = {0,0}; - autoAim[] = {0,0}; - unlimitedSaves[] = {0,0}; - deathMessages[] = {0,1};//{1,1}; - netStats[] = {0,1};//{1,1}; - vonID[] = {0,1}; - cameraShake[] = {1,0}; - hudGroupInfo[] = {0,0}; - extendetInfoType[] = {0,0}; - roughLanding[] = {0,0}; - windEnabled[] = {1,0}; - autoTrimEnabled[] = {0,0}; - stressDamageEnabled[] = {1,0}; - }; - }; -}; diff --git a/addons/difficulties/README.md b/addons/difficulties/README.md deleted file mode 100644 index 4aefb4570a..0000000000 --- a/addons/difficulties/README.md +++ /dev/null @@ -1,12 +0,0 @@ -ace_difficulties -================ - -Changes the elite difficulty setting to more closely resemble Arma 2. - - -## Maintainers - -The people responsible for merging changes to this component or answering potential questions. - -- [KoffeinFlummi](https://github.com/KoffeinFlummi) -- [commy2](https://github.com/commy2) diff --git a/addons/difficulties/config.cpp b/addons/difficulties/config.cpp deleted file mode 100644 index 34784706a0..0000000000 --- a/addons/difficulties/config.cpp +++ /dev/null @@ -1,15 +0,0 @@ -#include "script_component.hpp" - -class CfgPatches { - class ADDON { - units[] = {}; - weapons[] = {}; - requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"ace_common"}; - author[] = {"commy2"}; - authorUrl = "https://github.com/commy2/"; - VERSION_CONFIG; - }; -}; - -#include "CfgDifficulties.hpp" diff --git a/addons/difficulties/script_component.hpp b/addons/difficulties/script_component.hpp deleted file mode 100644 index b6f387b02f..0000000000 --- a/addons/difficulties/script_component.hpp +++ /dev/null @@ -1,17 +0,0 @@ -#define COMPONENT difficulties -#include "\z\ace\addons\main\script_mod.hpp" - -// #define DEBUG_MODE_FULL -// #define DISABLE_COMPILE_CACHE -// #define CBA_DEBUG_SYNCHRONOUS -// #define ENABLE_PERFORMANCE_COUNTERS - -#ifdef DEBUG_ENABLED_DIFFICULTIES - #define DEBUG_MODE_FULL -#endif - -#ifdef DEBUG_ENABLED_DIFFICULTIES - #define DEBUG_SETTINGS DEBUG_ENABLED_DIFFICULTIES -#endif - -#include "\z\ace\addons\main\script_macros.hpp" \ No newline at end of file From b08af3fea627cd4529f5187c31dd4e996b2a212f Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sun, 8 May 2016 13:42:45 +0200 Subject: [PATCH 173/215] Add read auto add objects setting from module --- addons/zeus/functions/fnc_moduleZeusSettings.sqf | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/zeus/functions/fnc_moduleZeusSettings.sqf b/addons/zeus/functions/fnc_moduleZeusSettings.sqf index 0b9c0f8dd8..0f3d720599 100644 --- a/addons/zeus/functions/fnc_moduleZeusSettings.sqf +++ b/addons/zeus/functions/fnc_moduleZeusSettings.sqf @@ -24,3 +24,4 @@ if !(_activated) exitWith {}; [_logic, QGVAR(radioOrdnance), "radioOrdnance"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(revealMines), "revealMines"] call EFUNC(common,readSettingFromModule); [_logic, QGVAR(remoteWind), "remoteWind"] call EFUNC(common,readSettingFromModule); +[_logic, QGVAR(autoAddObjects), "autoAddObjects"] call EFUNC(common,readSettingFromModule); From a526d33aba5d39f1133211bdb2252ad5630fd302 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sun, 8 May 2016 13:44:51 +0200 Subject: [PATCH 174/215] Fix inconsistent name for module setting --- addons/zeus/CfgVehicles.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/zeus/CfgVehicles.hpp b/addons/zeus/CfgVehicles.hpp index 332f13d982..fbf63930c4 100644 --- a/addons/zeus/CfgVehicles.hpp +++ b/addons/zeus/CfgVehicles.hpp @@ -71,7 +71,7 @@ class CfgVehicles { }; }; }; - class GVAR(autoAddObjects) { + class autoAddObjects { displayName = CSTRING(AddObjectsToCurator); description = CSTRING(AddObjectsToCurator_desc); typeName = "BOOL"; From 74fd4b4b5260a63ae53de030e0d3882987a7b244 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sun, 8 May 2016 13:47:35 +0200 Subject: [PATCH 175/215] Add run at settings initialized auto add objects --- addons/zeus/functions/fnc_addObjectToCurator.sqf | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/addons/zeus/functions/fnc_addObjectToCurator.sqf b/addons/zeus/functions/fnc_addObjectToCurator.sqf index 085fff09d1..176b55dfdc 100644 --- a/addons/zeus/functions/fnc_addObjectToCurator.sqf +++ b/addons/zeus/functions/fnc_addObjectToCurator.sqf @@ -15,6 +15,11 @@ params ["_object"]; +if !(EGVAR(common,settingsInitFinished)) exitWith { + TRACE_1("pushing to runAtSettingsInitialized", _this); + EGVAR(common,runAtSettingsInitialized) pushBack [FUNC(addObjectToCurator), _this]; +}; + if (!(_object getVariable [QGVAR(addObject), GVAR(autoAddObjects)])) exitWith {}; [{ From 505fa0d7737007ed03b4ee24924fb3e8daaf33f4 Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 10 May 2016 11:50:59 +0200 Subject: [PATCH 176/215] add missing magazines, fix #3685 --- addons/ballistics/CfgWeapons.hpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/addons/ballistics/CfgWeapons.hpp b/addons/ballistics/CfgWeapons.hpp index 3f6835bbba..b2c6728a37 100644 --- a/addons/ballistics/CfgWeapons.hpp +++ b/addons/ballistics/CfgWeapons.hpp @@ -285,6 +285,8 @@ class CfgWeapons { "30Rnd_556x45_Stanag_Tracer_Red", "30Rnd_556x45_Stanag_Tracer_Green", "30Rnd_556x45_Stanag_Tracer_Yellow", + "30Rnd_556x45_Stanag_red", + "30Rnd_556x45_Stanag_green", "ACE_30Rnd_556x45_Stanag_M995_AP_mag", "ACE_30Rnd_556x45_Stanag_Mk262_mag", "ACE_30Rnd_556x45_Stanag_Mk318_mag", @@ -305,6 +307,8 @@ class CfgWeapons { "30Rnd_556x45_Stanag_Tracer_Red", "30Rnd_556x45_Stanag_Tracer_Green", "30Rnd_556x45_Stanag_Tracer_Yellow", + "30Rnd_556x45_Stanag_red", + "30Rnd_556x45_Stanag_green", "ACE_30Rnd_556x45_Stanag_M995_AP_mag", "ACE_30Rnd_556x45_Stanag_Mk262_mag", "ACE_30Rnd_556x45_Stanag_Mk318_mag", @@ -320,6 +324,8 @@ class CfgWeapons { "30Rnd_556x45_Stanag_Tracer_Red", "30Rnd_556x45_Stanag_Tracer_Green", "30Rnd_556x45_Stanag_Tracer_Yellow", + "30Rnd_556x45_Stanag_red", + "30Rnd_556x45_Stanag_green", "ACE_30Rnd_556x45_Stanag_M995_AP_mag", "ACE_30Rnd_556x45_Stanag_Mk262_mag", "ACE_30Rnd_556x45_Stanag_Mk318_mag", @@ -335,6 +341,8 @@ class CfgWeapons { "30Rnd_556x45_Stanag_Tracer_Red", "30Rnd_556x45_Stanag_Tracer_Green", "30Rnd_556x45_Stanag_Tracer_Yellow", + "30Rnd_556x45_Stanag_red", + "30Rnd_556x45_Stanag_green", "ACE_30Rnd_556x45_Stanag_M995_AP_mag", "ACE_30Rnd_556x45_Stanag_Mk262_mag", "ACE_30Rnd_556x45_Stanag_Mk318_mag", @@ -356,6 +364,8 @@ class CfgWeapons { "30Rnd_556x45_Stanag_Tracer_Red", "30Rnd_556x45_Stanag_Tracer_Green", "30Rnd_556x45_Stanag_Tracer_Yellow", + "30Rnd_556x45_Stanag_red", + "30Rnd_556x45_Stanag_green", "ACE_30Rnd_556x45_Stanag_M995_AP_mag", "ACE_30Rnd_556x45_Stanag_Mk262_mag", "ACE_30Rnd_556x45_Stanag_Mk318_mag", @@ -371,6 +381,8 @@ class CfgWeapons { "30Rnd_556x45_Stanag_Tracer_Red", "30Rnd_556x45_Stanag_Tracer_Green", "30Rnd_556x45_Stanag_Tracer_Yellow", + "30Rnd_556x45_Stanag_red", + "30Rnd_556x45_Stanag_green", "ACE_30Rnd_556x45_Stanag_M995_AP_mag", "ACE_30Rnd_556x45_Stanag_Mk262_mag", "ACE_30Rnd_556x45_Stanag_Mk318_mag", @@ -386,6 +398,8 @@ class CfgWeapons { "30Rnd_556x45_Stanag_Tracer_Red", "30Rnd_556x45_Stanag_Tracer_Green", "30Rnd_556x45_Stanag_Tracer_Yellow", + "30Rnd_556x45_Stanag_red", + "30Rnd_556x45_Stanag_green", "ACE_30Rnd_556x45_Stanag_M995_AP_mag", "ACE_30Rnd_556x45_Stanag_Mk262_mag", "ACE_30Rnd_556x45_Stanag_Mk318_mag", From 29e7dbf757f3a37094f0276f0d329185acda230c Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Tue, 10 May 2016 12:39:56 +0200 Subject: [PATCH 177/215] fnc_getMGRSdata.sqf update3 --- addons/common/functions/fnc_getMGRSdata.sqf | 38 +++++++++++++-------- 1 file changed, 23 insertions(+), 15 deletions(-) diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index 04c063ac79..2087b0c4bf 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -23,7 +23,7 @@ private _lat = getNumber (configFile >> "CfgWorlds" >> _map >> "latitude"); private _altitude = getNumber (configFile >> "CfgWorlds" >> _map >> "elevationOffset"); _map = toLower _map; -if (_map in ["abbottabad", "abbottabad1"]) then { _lat = 34; _altitude = 1256; }; +if (_map in ["abbottabad"]) then { _lat = 34; _altitude = 1256; }; //Abbottabad elevation 1256m (Wikipedia) if (_map in ["abramia"]) then { _lat = 60; _altitude = 0; }; if (_map in ["af_kandahar_province"]) then { _lat = 42; _altitude = 0; }; if (_map in ["altis"]) then { _lat = 40; _altitude = 0; }; @@ -34,21 +34,27 @@ if (_map in ["bootcamp_acr"]) then { _lat = 50; _altitude = 0; }; if (_map in ["bornholm"]) then { _lat = 55; _altitude = 0; }; if (_map in ["bozcaada"]) then { _lat = 40; _altitude = 0; }; if (_map in ["caribou"]) then { _lat = 68; _altitude = 0; }; +if (_map in ["catalina"]) then { _lat = 33; _altitude = 0; }; if (_map in ["chernarus", "chernarus_summer", "chernarus_winter"]) then { _lat = 50; _altitude = 0; }; +if (_map in ["chernobylzone", "chernobylzonea2"]) then { _lat = 51; _altitude = 0; }; if (_map in ["clafghan"]) then { _lat = 34; _altitude = 640; }; -if (_map in ["dakrong"]) then { _lat = 17; _altitude = 0; }; -if (_map in ["desert_e"]) then { _lat = 40; _altitude = 0; }; +if (_map in ["dakrong"]) then { _lat = 17; _altitude = 0; }; //Unsung Mod +if (_map in ["desert_e"]) then { _lat = 40; _altitude = 800; }; +if (_map in ["dya"]) then { _lat = 34; _altitude = 110; }; //Diyala Iraq - default elevationOffset if (_map in ["esseker"]) then { _lat = 43; _altitude = 2000; }; +if (_map in ["evergreen"]) then { _lat = 41; _altitude = 0; }; //Burgazada, Turkey - default elevationOffset if (_map in ["fallujah"]) then { _lat = 33; _altitude = 0; }; if (_map in ["fata"]) then { _lat = 33; _altitude = 1347; }; if (_map in ["gorgona"]) then { _lat = 43; _altitude = 0; }; -if (_map in ["hellskitchen", "hellskitchens"]) then { _lat = 32; _altitude = 0; }; +if (_map in ["hellskitchen", "hellskitchens"]) then { _lat = 32; _altitude = 900; }; //Sangin summer, Sangin winter - Sangin elevation 888m (Wikipedia) if (_map in ["hindukush"]) then { _lat = 36; _altitude = 0; }; if (_map in ["imrali", "imralispring"]) then { _lat = 40; _altitude = 0; }; if (_map in ["intro"]) then { _lat = 40; _altitude = 0; }; if (_map in ["isladuala3"]) then { _lat = -19; _altitude = 0; }; if (_map in ["jacobi"]) then { _lat = -19; _altitude = 0; }; +if (_map in ["kapaulio"]) then { _lat = 0; _altitude = 0; }; if (_map in ["kholm"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["koplic"]) then { _lat = 42; _altitude = 0; }; if (_map in ["kunduz"]) then { _lat = 37; _altitude = 0; }; if (_map in ["lingor", "lingor3"]) then { _lat = -4; _altitude = 0; }; if (_map in ["lost", "lostw"]) then { _lat = 60; _altitude = 0; }; @@ -59,19 +65,20 @@ if (_map in ["mef_alaska"]) then { _lat = 60; _altitude = 5; }; if (_map in ["mountains_acr"]) then { _lat = 35; _altitude = 2000; }; if (_map in ["napf", "napfwinter"]) then { _lat = 47; _altitude = 0; }; if (_map in ["panthera3"]) then { _lat = 46; _altitude = 0; }; -if (_map in ["pja301"]) then { _lat = 42; _altitude = 0; }; -if (_map in ["pja305"]) then { _lat = 0; _altitude = 0; }; -if (_map in ["pja306"]) then { _lat = 35; _altitude = 300; }; -if (_map in ["pja307"]) then { _lat = 17; _altitude = 0; }; -if (_map in ["pja308"]) then { _lat = 36; _altitude = 0; }; -if (_map in ["pja310"]) then { _lat = 36; _altitude = 0; }; +if (_map in ["pianosa_aut"]) then { _lat = 43; _altitude = 0; }; //Pianosa, Italy - default elevationOffset +if (_map in ["pja305"]) then { _lat = 0; _altitude = 0; }; //G.O.S N'Ziwasogo +if (_map in ["pja306"]) then { _lat = 35; _altitude = 0; }; //G.O.S Kalu Khan +if (_map in ["pja307"]) then { _lat = 17; _altitude = 0; }; //F.S.F Daryah +if (_map in ["pja308"]) then { _lat = 36; _altitude = 0; }; //G.O.S Gunkizli +if (_map in ["pja310"]) then { _lat = 36; _altitude = 0; }; //G.O.S Al Rayak +if (_map in ["pja312"]) then { _lat = 16; _altitude = 0; }; //G.O.S Song Bin Tanh if (_map in ["porquerolles"]) then { _lat = 43; _altitude = 0; }; if (_map in ["porto"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["provingGrounds_pmc"]) then { _lat = 35; _altitude = 100; }; +if (_map in ["provinggrounds_pmc"]) then { _lat = 35; _altitude = 100; }; if (_map in ["reshmaan"]) then { _lat = 35; _altitude = 2000; }; if (_map in ["sara", "sara_dbe1"]) then { _lat = 40; _altitude = 0; }; if (_map in ["saralite"]) then { _lat = 40; _altitude = 0; }; -if (_map in ["sb3"]) then { _lat = 53; _altitude = 0; }; +if (_map in ["sb3"]) then { _lat = 53; _altitude = 25; }; //TrpUebPl Einfelde Nord (Munster North Training Area, Germany) - default elevationOffset if (_map in ["shapur_baf"]) then { _lat = 35; _altitude = 100; }; if (_map in ["sfp_sturko"]) then { _lat = 56; _altitude = 0; }; if (_map in ["sfp_wamako"]) then { _lat = 14; _altitude = 0; }; @@ -81,10 +88,11 @@ if (_map in ["takistan"]) then { _lat = 35; _altitude = 2000; }; if (_map in ["thirsk"]) then { _lat = 65; _altitude = 0; }; if (_map in ["tilos"]) then { _lat = 36; _altitude = 0; }; if (_map in ["utes"]) then { _lat = 50; _altitude = 0; }; -if (_map in ["vt5"]) then { _lat = 61; _altitude = 100; }; +if (_map in ["vt5"]) then { _lat = 61; _altitude = 100; }; //Vt5, Suomi Finland - default elevationOffset if (_map in ["wake"]) then { _lat = 19; _altitude = 0; }; -if (_map in ["wintermap"]) then { _lat = 61; _altitude = 0; }; -if (_map in ["wintertown", "wintertowna3"]) then { _lat = 39; _altitude = 0; }; +if (_map in ["waziristan"]) then { _lat = 33; _altitude = 0; }; +if (_map in ["wintermap"]) then { _lat = 61; _altitude = 0; }; //Nordkvingo - default elevationOffset +if (_map in ["wintertown", "wintertowna3"]) then { _lat = 39; _altitude = 600; }; //U.S. state Kansas mean elevation 610m (Wikipedia) if (_map in ["woodland_acr"]) then { _lat = 50; _altitude = 0; }; if (_map in ["xcam_prototype"]) then { _lat = 35; _altitude = 0; }; if (_map in ["zargabad"]) then { _lat = 35; _altitude = 2000; }; From 980da168263b595674a9b602b2e9a36078793791 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 10 May 2016 10:09:52 -0500 Subject: [PATCH 178/215] FastRope Sounds - Fix Config, Merge PFEH, Add CC Attribution --- AUTHORS.txt | 1 + LICENSE | 2 ++ addons/fastroping/config.cpp | 1 + addons/fastroping/functions/fnc_fastRope.sqf | 2 +- .../functions/fnc_fastRopeLocalPFH.sqf | 19 +++++++------------ 5 files changed, 12 insertions(+), 13 deletions(-) diff --git a/AUTHORS.txt b/AUTHORS.txt index 46a5e50457..42923c77e5 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -112,6 +112,7 @@ Sniperwolf572 System98 SzwedzikPL Tachi +Tessa Elieff Toaster Tonic Tourorist diff --git a/LICENSE b/LICENSE index 037f1df2f3..f748d222de 100644 --- a/LICENSE +++ b/LICENSE @@ -26,6 +26,8 @@ Some folders of this project may contain a separate LICENSE file. Should that be the case, everything in that folder and all subfolders is subject to that license instead. + - ARMA PUBLIC LICENSE (\addons\apl) + - CreativeCommons Attributions 3.0 (\addons\fastroping\data\sounds) ============================================================================ Full GNU General Public License Text diff --git a/addons/fastroping/config.cpp b/addons/fastroping/config.cpp index a74abeb3b8..7275741f40 100644 --- a/addons/fastroping/config.cpp +++ b/addons/fastroping/config.cpp @@ -14,5 +14,6 @@ class CfgPatches { #include "CfgEventHandlers.hpp" #include "CfgMoves.hpp" +#include "CfgSounds.hpp" #include "CfgVehicles.hpp" #include "CfgWaypoints.hpp" diff --git a/addons/fastroping/functions/fnc_fastRope.sqf b/addons/fastroping/functions/fnc_fastRope.sqf index adeb536362..17991c538e 100644 --- a/addons/fastroping/functions/fnc_fastRope.sqf +++ b/addons/fastroping/functions/fnc_fastRope.sqf @@ -37,4 +37,4 @@ _vehicle setVariable [QGVAR(deployedRopes), _deployedRopes, true]; //Start server PFH asap [QGVAR(startFastRope), [_unit, _vehicle, _usableRope, _usableRopeIndex, false]] call EFUNC(common,serverEvent); moveOut _unit; -[FUNC(fastRopeLocalPFH), 0, [_unit, _vehicle, _usableRope, _usableRopeIndex]] call CBA_fnc_addPerFrameHandler; +[FUNC(fastRopeLocalPFH), 0, [_unit, _vehicle, _usableRope, _usableRopeIndex, ACE_diagTime]] call CBA_fnc_addPerFrameHandler; diff --git a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf index 8334e07929..03df460f55 100644 --- a/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf +++ b/addons/fastroping/functions/fnc_fastRopeLocalPFH.sqf @@ -17,7 +17,7 @@ #include "script_component.hpp" params ["_arguments", "_pfhHandle"]; -_arguments params ["_unit", "_vehicle", "_rope", "_ropeIndex"]; +_arguments params ["_unit", "_vehicle", "_rope", "_ropeIndex", "_timeToPlayRopeSound"]; _rope params ["_attachmentPoint", "_ropeTop", "_ropeBottom", "_dummy", "_hook", "_occupied"]; private ["_vectorUp", "_vectorDir", "_origin"]; @@ -29,22 +29,12 @@ if (animationState _unit != "ACE_FastRoping") exitWith { _unit disableCollisionWith _dummy; _unit attachTo [_dummy, [0, 0, -1.45]]; [_unit, "ACE_FastRoping", 2] call EFUNC(common,doAnimation); - - [{ - params ["_args", "_idPFH"]; - _args params ["_unit"]; - - if (isNull (attachedTo _unit)) exitWith { - [_idPFH] call CBA_fnc_removePerFrameHandler; - }; - - playSound QGVAR(Rope); - }, 1, [_unit]] call CBA_fnc_addPerFrameHandler; }; //End of fast rope if (isNull attachedTo _unit) exitWith { + TRACE_1("exit pfeh",_unit); [_unit, "", 2] call EFUNC(common,doAnimation); _unit setVectorUp [0, 0, 1]; @@ -52,3 +42,8 @@ if (isNull attachedTo _unit) exitWith { [_pfhHandle] call CBA_fnc_removePerFrameHandler; }; + +if (ACE_diagTime > _timeToPlayRopeSound) then { + _arguments set [4, (_timeToPlayRopeSound + 1)]; + playSound QGVAR(Rope); +}; From 518a873efdbe7f197aa7d48d1499666d57cd547a Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Tue, 10 May 2016 10:14:15 -0500 Subject: [PATCH 179/215] Add module readme --- addons/fastroping/README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 addons/fastroping/README.md diff --git a/addons/fastroping/README.md b/addons/fastroping/README.md new file mode 100644 index 0000000000..49fcf00960 --- /dev/null +++ b/addons/fastroping/README.md @@ -0,0 +1,11 @@ +ace_fastroping +========== + +Introducing the ability to fastrope out of heliocopters. + +## Maintainers + +The people responsible for merging changes to this component or answering potential questions. + +- [BaerMitUmlaut](https://github.com/BaerMitUmlaut) +- [KoffeinFlummi](https://github.com/KoffeinFlummi) From c619bcb5a3822741865a56ff5ead2dd58106efce Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Tue, 10 May 2016 19:39:01 +0200 Subject: [PATCH 180/215] Fix "jacobi" latitude and elevationOffset --- addons/common/functions/fnc_getMGRSdata.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index 2087b0c4bf..2747752ce1 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -51,7 +51,7 @@ if (_map in ["hindukush"]) then { _lat = 36; _altitude = 0; }; if (_map in ["imrali", "imralispring"]) then { _lat = 40; _altitude = 0; }; if (_map in ["intro"]) then { _lat = 40; _altitude = 0; }; if (_map in ["isladuala3"]) then { _lat = -19; _altitude = 0; }; -if (_map in ["jacobi"]) then { _lat = -19; _altitude = 0; }; +if (_map in ["jacobi"]) then { _lat = 34; _altitude = 2000; }; //default elevationOffset if (_map in ["kapaulio"]) then { _lat = 0; _altitude = 0; }; if (_map in ["kholm"]) then { _lat = 36; _altitude = 0; }; if (_map in ["koplic"]) then { _lat = 42; _altitude = 0; }; From 53c9a96c772da960cd055745d4c8007c1f05a23b Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 10 May 2016 22:14:01 +0200 Subject: [PATCH 181/215] fix getWeaponState, fix #3777 --- .../common/functions/fnc_getWeaponMuzzles.sqf | 2 +- .../common/functions/fnc_getWeaponState.sqf | 26 ++++++++----------- 2 files changed, 12 insertions(+), 16 deletions(-) diff --git a/addons/common/functions/fnc_getWeaponMuzzles.sqf b/addons/common/functions/fnc_getWeaponMuzzles.sqf index d75a01f2e3..e252d879f9 100644 --- a/addons/common/functions/fnc_getWeaponMuzzles.sqf +++ b/addons/common/functions/fnc_getWeaponMuzzles.sqf @@ -18,7 +18,7 @@ private _muzzles = getArray (configFile >> "CfgWeapons" >> _weapon >> "muzzles") { if (_x == "this") then { - _muzzles set [_forEachIndex, _weapon]; + _muzzles set [_forEachIndex, configName (configFile >> "CfgWeapons" >> _weapon)]; }; } forEach _muzzles; diff --git a/addons/common/functions/fnc_getWeaponState.sqf b/addons/common/functions/fnc_getWeaponState.sqf index e7b7bb80ec..73e5897236 100644 --- a/addons/common/functions/fnc_getWeaponState.sqf +++ b/addons/common/functions/fnc_getWeaponState.sqf @@ -4,7 +4,7 @@ * * Arguments: * 0: unit - * 1: weapon + * 1: weapon (optional, default: units current weapon) * * Return Value: * 0: Attachements @@ -16,21 +16,19 @@ */ #include "script_component.hpp" -params ["_unit", "_weapon"]; +params [["_unit", objNull, [objNull]], ["_weapon", nil, [""]]]; + +if (isNil "_weapon") then { + _weapon = currentWeapon _unit; +}; + +private _attachments = [_unit weaponAccessories _weapon] param [0, ["","","",""]]; private _muzzles = _weapon call FUNC(getWeaponMuzzles); -private _weaponInfo = [["","","",""], primaryWeaponItems _unit, secondaryWeaponItems _unit, handgunItems _unit] select ((["", primaryWeapon _unit, secondaryWeapon _unit, handgunWeapon _unit] find _weapon) max 0); - // get loaded magazines and ammo -private _magazines = []; -private _ammo = []; - -{ - _magazines pushBack ""; - _ammo pushBack 0; - false -} count _muzzles; +private _magazines = _muzzles apply {""}; +private _ammo = _muzzles apply {0}; { if (_x select 2) then { @@ -44,6 +42,4 @@ private _ammo = []; false } count magazinesAmmoFull _unit; -_weaponInfo append [_muzzles, _magazines, _ammo]; - -_weaponInfo +[_attachments, _muzzles, _magazines, _ammo]; From f738b17db7dd02b7775537c42ddf1061ce4ab81d Mon Sep 17 00:00:00 2001 From: commy2 Date: Tue, 10 May 2016 22:32:40 +0200 Subject: [PATCH 182/215] show virtual load in inventory menu --- .../functions/fnc_addLoadToUnitContainer.sqf | 1 + addons/movement/functions/fnc_getWeight.sqf | 13 ++++++++++++- addons/movement/functions/fnc_handleVirtualMass.sqf | 1 + 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/addons/movement/functions/fnc_addLoadToUnitContainer.sqf b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf index 3928d1c822..a79b2ab917 100644 --- a/addons/movement/functions/fnc_addLoadToUnitContainer.sqf +++ b/addons/movement/functions/fnc_addLoadToUnitContainer.sqf @@ -17,6 +17,7 @@ params [["_unit", objNull, [objNull]], ["_container", objNull, [objNull]], ["_virtualLoadToAdd", 0, [0]]]; if !(_container in [ + _unit, uniformContainer _unit, vestContainer _unit, backpackContainer _unit diff --git a/addons/movement/functions/fnc_getWeight.sqf b/addons/movement/functions/fnc_getWeight.sqf index 11dd8c4ee6..b64abc3623 100644 --- a/addons/movement/functions/fnc_getWeight.sqf +++ b/addons/movement/functions/fnc_getWeight.sqf @@ -17,7 +17,18 @@ params ["_unit"]; -private _weight = loadAbs _unit * 0.1; +private _virtualLoad = 0; + +{ + _virtualLoad = _virtualLoad + (_x getVariable [QGVAR(vLoad), 0]); +} forEach [ + _unit, + uniformContainer _unit, + vestContainer _unit, + backpackContainer _unit +]; + +private _weight = (loadAbs _unit + _virtualLoad) * 0.1; if (GVAR(useImperial)) then { _weight = format ["%1lb", (round (_weight * 100)) / 100]; diff --git a/addons/movement/functions/fnc_handleVirtualMass.sqf b/addons/movement/functions/fnc_handleVirtualMass.sqf index 5d71c58df4..13a7b77f9a 100644 --- a/addons/movement/functions/fnc_handleVirtualMass.sqf +++ b/addons/movement/functions/fnc_handleVirtualMass.sqf @@ -20,6 +20,7 @@ private _virtualLoad = 0; { _virtualLoad = _virtualLoad + (_x getVariable [QGVAR(vLoad), 0]); } forEach [ + _unit, uniformContainer _unit, vestContainer _unit, backpackContainer _unit From 38bb4f6c2921f9984f72a9ac05ff8c4ae14fe47b Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Tue, 10 May 2016 23:40:03 +0200 Subject: [PATCH 183/215] Adjusted weight of bodybag --- addons/medical/CfgWeapons.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/CfgWeapons.hpp b/addons/medical/CfgWeapons.hpp index 4bd5452794..235e3c154b 100644 --- a/addons/medical/CfgWeapons.hpp +++ b/addons/medical/CfgWeapons.hpp @@ -236,7 +236,7 @@ class CfgWeapons { descriptionShort = CSTRING(Bodybag_Desc_Short); descriptionUse = CSTRING(Bodybag_Desc_Use); class ItemInfo: InventoryItem_Base_F { - mass = 20; + mass = 7.4; }; }; }; From 078c1d585f003df0f07e536edc705340399c72c1 Mon Sep 17 00:00:00 2001 From: J3aLeiNe Date: Wed, 11 May 2016 00:01:35 +0200 Subject: [PATCH 184/215] =?UTF-8?q?Add=20Kerama=20Islands=20by=20"Les=20V?= =?UTF-8?q?=C3=A9t=C3=A9rans"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit add Kerama Islands by "Les Vétérans" with the correct latitude (default config latitude : 1°) --- addons/common/functions/fnc_getMGRSdata.sqf | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/common/functions/fnc_getMGRSdata.sqf b/addons/common/functions/fnc_getMGRSdata.sqf index 2747752ce1..44fc204638 100644 --- a/addons/common/functions/fnc_getMGRSdata.sqf +++ b/addons/common/functions/fnc_getMGRSdata.sqf @@ -53,6 +53,7 @@ if (_map in ["intro"]) then { _lat = 40; _altitude = 0; }; if (_map in ["isladuala3"]) then { _lat = -19; _altitude = 0; }; if (_map in ["jacobi"]) then { _lat = 34; _altitude = 2000; }; //default elevationOffset if (_map in ["kapaulio"]) then { _lat = 0; _altitude = 0; }; +if (_map in ["kerama"]) then { _lat = 26; _altitude = 0; }; //Kerama Islands, Japan - default elevationOffset if (_map in ["kholm"]) then { _lat = 36; _altitude = 0; }; if (_map in ["koplic"]) then { _lat = 42; _altitude = 0; }; if (_map in ["kunduz"]) then { _lat = 37; _altitude = 0; }; From 9364ae60dfd05d53a08d8d46df2c846a8bcd3d4b Mon Sep 17 00:00:00 2001 From: SilentSpike Date: Wed, 11 May 2016 13:30:17 +0100 Subject: [PATCH 185/215] Fix spectator unit tree refreshing - Account for decrement in node index when culling the tree of sides/groups/units - Fix non-zero-based index `to` value when navigating the units in the tree --- .../functions/fnc_handleInterface.sqf | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/addons/spectator/functions/fnc_handleInterface.sqf b/addons/spectator/functions/fnc_handleInterface.sqf index a8a607d537..ea20d0fcdd 100644 --- a/addons/spectator/functions/fnc_handleInterface.sqf +++ b/addons/spectator/functions/fnc_handleInterface.sqf @@ -331,31 +331,40 @@ switch (toLower _mode) do { }; case "onunitsupdate": { _args params ["_tree"]; - private ["_cachedUnits","_cachedGrps","_cachedSides","_s","_g","_grp","_u","_unit","_side"]; + private ["_cachedUnits","_cachedGrps","_cachedSides","_sT","_gT","_uT","_s","_g","_u","_grp","_unit","_side"]; // Cache existing group and side nodes and cull removed data _cachedUnits = []; _cachedGrps = []; _cachedSides = []; - for "_s" from 0 to ((_tree tvCount []) - 1) do { - for "_g" from 0 to ((_tree tvCount [_s]) - 1) do { + // Track deleted nodes to account for decrease in index + _sT = _tree tvCount []; + for [{_s = 0;}, {_s < _sT}, {_s = _s + 1}] do { + _gT = _tree tvCount [_s]; + + for [{_g = 0;}, {_g < _gT}, {_g = _g + 1}] do { _grp = groupFromNetID (_tree tvData [_s,_g]); if (_grp in GVAR(groupList)) then { _cachedGrps pushBack _grp; _cachedGrps pushBack _g; - for "_u" from 0 to ((_tree tvCount [_s,_g])) do { + _uT = _tree tvCount [_s,_g]; + for [{_u = 0;}, {_u < _uT}, {_u = _u + 1}] do { _unit = objectFromNetId (_tree tvData [_s,_g,_u]); if (_unit in GVAR(unitList)) then { _cachedUnits pushBack _unit; } else { _tree tvDelete [_s,_g,_u]; + _u = _u - 1; + _uT = _uT - 1; }; }; } else { _tree tvDelete [_s,_g]; + _g = _g - 1; + _gT = _gT - 1; }; }; @@ -364,6 +373,8 @@ switch (toLower _mode) do { _cachedSides pushBack _s; } else { _tree tvDelete [_s]; + _s = _s - 1; + _sT = _sT - 1; }; }; From 1b1329b3507a8be5e52b7326985def6d624ebd50 Mon Sep 17 00:00:00 2001 From: SilentSpike Date: Wed, 11 May 2016 16:01:07 +0100 Subject: [PATCH 186/215] Increase spectator unit tree refresh rate Reduce the time between automated refreshing of the unit tree. Also makes an initial call to the tree populating code upon first opening to remove the initial delay. --- addons/spectator/functions/fnc_handleInterface.sqf | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/addons/spectator/functions/fnc_handleInterface.sqf b/addons/spectator/functions/fnc_handleInterface.sqf index ea20d0fcdd..381f64505c 100644 --- a/addons/spectator/functions/fnc_handleInterface.sqf +++ b/addons/spectator/functions/fnc_handleInterface.sqf @@ -27,8 +27,11 @@ switch (toLower _mode) do { // Always show interface and hide map upon opening [_display,nil,nil,!GVAR(showInterface),GVAR(showMap)] call FUNC(toggleInterface); + // Initalize the unit tree + ["onUnitsUpdate",[(_display displayCtrl IDC_UNIT) controlsGroupCtrl IDC_UNIT_TREE]] call FUNC(handleInterface); + // Keep unit list and tree up to date - [FUNC(handleUnits), 21, _display] call CBA_fnc_addPerFrameHandler; + [FUNC(handleUnits), 9, _display] call CBA_fnc_addPerFrameHandler; // Handle 3D unit icons GVAR(iconHandler) = addMissionEventHandler ["Draw3D",FUNC(handleIcons)]; From f9c643b941321c8f928a37f53633f927ebb44c9c Mon Sep 17 00:00:00 2001 From: BaerMitUmlaut Date: Wed, 11 May 2016 21:05:59 +0200 Subject: [PATCH 187/215] Modified fastroping thud sound --- .../data/sounds/fastroping_thud.ogg | Bin 20522 -> 7314 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/addons/fastroping/data/sounds/fastroping_thud.ogg b/addons/fastroping/data/sounds/fastroping_thud.ogg index 136a638ea9033a059138df2443eca54539344e4b..40fd823fcf0f17df67e7840ea0c8b227f9bbd555 100644 GIT binary patch delta 5824 zcmaJ_c{r49)PKgl6Vj9=M9eTUmNZJXcr&OBLq^2dvc@pHCC$8ylHD|xEJcic?4x8! z%Zy#Jj9qz&O43_V(egc`_gnw?=DMD9o%{Um`<(ln`*)w`xu&WJLPe2I`};crJix!d zO`YFLM?X*uQG!HWB;W%gxF!g>?cXWUkR9bdWM}2SMgZWhfBmmtFYj+h zS|ENlAnbz9X@b9UZ~)%?vCNQX2EJ2H*f}}u zc#H3h+*Oxs;tPFyS8&JyQQ|~)?0HUzd+xu!>}7X+9mYnW*A`CC<^@7hS+iLe59ucKedh7;^L>W4jOZ zF!B}k?4m*|xUMNw9<;GPX_llJy=N(`xgRXkH(RYHp%B6v>ZpBm4Xhs$lGf;4o>nc7CZ3AneqV2$Kq0yv< z1Pm@1$tl1D8-n`+eNoZD2sX~mj!BfliSBHR!E_D^WU#^L>U5|rx`8Pd6pCElhYnzH zqgS%z+|t14jzNZHoIoz%7GlE5i$F6tW0+JB@DAx1&x=|A&)o5W2sQ`L;6{fxWRa*~ z^yO(>3W_#@2Ypd7Dc};f;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v_9m$+Q-gPHBP#=jg;PxM2VGx2v! zn5j6?!rNwR3e0j*)e*e;N@)!(A}?*VVe^!T7F<&!pS#inMF@Ms%5Up925uob#6c)> ztjXw}Ei;{z&g#S^*bD%4>kH+tA4tapwX9J60t3~x^Xg;bn*UbW@vC;2s~QN)cXjCP zBqBVCPiHltaoK+M1E&?YK)X3XuL1O#l{ns> zUw-6HVi7KgETGTb#)&)55lVYUWCv4EztuQ$Yd>W_w(*kM#4t{xc>!qy!FJoB;T-TZ z{i09^^SHBAQ~6zZNC03`3t>=#vj=^cj84H}*NE7W@{qD@F}J!d`^LUjTy(LACDt-( z9+YIQi$%HMD}^*&+5)jqAlg_?;ZYo!=C+r&6}NpBVp_SW5VR=(o<}P>?D)pnlh~>a zq91EdQBC)(T}bh1eU%ZM)qJB`HrIxrh_^BrlE1Iz_wkctomRqz|Aw9c$(eX1$DI<0 zHqzE(_kaUL|K7iEYt-|Sd9o+F&Q85{DTmQrd9PYy@Z{j>)O3l5Wf4*VUvLsHYR~8g zfe%IliB-o;_<#`>5J&8WeoLR1E$4FmXbE~dP+7A6@%?&HchoS&(5~h4=Ht*3aU6Ki^FpPg?5MB%yxJ(+99M2dvUW=DA2I z1#QP#Dy35*9X)1@BT0f}B#+rOjUZ`p#2;_y9F>2l#D#gpt`NxBb*M6FYQd9>R3KNp zk1O7uh(R{L2r`-+#45Sf& t`Z-4d2UzaeQg5Gsb4a0KgfGKzXOWxW6LSxd$HgP`vn}V=eKn}${THi5nCk!l From 5147f366a5b76664f2de8ef9b7f488c2535f7d14 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 12 May 2016 17:11:35 +0200 Subject: [PATCH 188/215] Execute take nozzle actions only on progress bar success (#3783) * Execute take nozzle actions only on progress bar success - fix #3739, Prettify params * Fix animation on holster --- addons/refuel/functions/fnc_takeNozzle.sqf | 37 ++++++++++++++++------ addons/refuel/script_component.hpp | 1 + 2 files changed, 28 insertions(+), 10 deletions(-) diff --git a/addons/refuel/functions/fnc_takeNozzle.sqf b/addons/refuel/functions/fnc_takeNozzle.sqf index 75601002a3..87a212cd44 100644 --- a/addons/refuel/functions/fnc_takeNozzle.sqf +++ b/addons/refuel/functions/fnc_takeNozzle.sqf @@ -18,17 +18,16 @@ */ #include "script_component.hpp" -params [["_unit", objNull, [objNull]], ["_target", objNull, [objNull]], ["_nozzle", objNull, [objNull]]]; - -[_unit, "forceWalk", "ACE_refuel", true] call EFUNC(common,statusEffect_set); +params [ + ["_unit", objNull, [objNull]], + ["_target", objNull, [objNull]], + ["_nozzle", objNull, [objNull]] +]; REFUEL_HOLSTER_WEAPON private _endPosOffset = [0, 0, 0]; if (isNull _nozzle) then { // func is called on fuel truck - [_target, "blockEngine", "ACE_Refuel", true] call EFUNC(common,statusEffect_set); - - _target setVariable [QGVAR(isConnected), true, true]; _endPosOffset = getArray (configFile >> "CfgVehicles" >> typeOf _target >> QGVAR(hooks)); if (count _endPosOffset == 2) then { if (_unit distance (_target modelToWorld (_endPosOffset select 0)) < _unit distance (_target modelToWorld (_endPosOffset select 1))) then { @@ -44,7 +43,11 @@ if (isNull _nozzle) then { // func is called on fuel truck [_unit, _target, _endPosOffset], { params ["_args"]; - _args params [["_unit", objNull, [objNull]], ["_target", objNull, [objNull]], ["_endPosOffset", [0,0,0], [[]], 3]]; + _args params [ + ["_unit", objNull, [objNull]], + ["_target", objNull, [objNull]], + ["_endPosOffset", [0, 0, 0], [[]], 3] + ]; private _newNozzle = "ACE_refuel_fuelNozzle" createVehicle position _unit; _newNozzle attachTo [_unit, [-0.02,0.05,-0.12], "righthandmiddle1"]; @@ -57,8 +60,12 @@ if (isNull _nozzle) then { // func is called on fuel truck }; _newNozzle setVariable [QGVAR(attachPos), _endPosOffset, true]; _newNozzle setVariable [QGVAR(source), _target, true]; + + [_target, "blockEngine", "ACE_Refuel", true] call EFUNC(common,statusEffect_set); + _target setVariable [QGVAR(isConnected), true, true]; _target setVariable [QGVAR(ownedNozzle), _newNozzle, true]; + [_unit, "forceWalk", "ACE_refuel", true] call EFUNC(common,statusEffect_set); _unit setVariable [QGVAR(isRefueling), true]; private _actionID = _unit getVariable [QGVAR(ReleaseActionID), -1]; if (_actionID != -1) then { @@ -87,7 +94,11 @@ if (isNull _nozzle) then { // func is called on fuel truck [_unit, _nozzle], { params ["_args"]; - _args params [["_unit", objNull, [objNull]], ["_nozzle", objNull, [objNull]]]; + _args params [ + ["_unit", objNull, [objNull]], + ["_nozzle", objNull, [objNull]] + ]; + if (_nozzle getVariable [QGVAR(jerryCan), false]) then { _nozzle attachTo [_unit, [0,1,0], "pelvis"]; } else { @@ -95,6 +106,7 @@ if (isNull _nozzle) then { // func is called on fuel truck }; _unit setVariable [QGVAR(nozzle), _nozzle, true]; + [_unit, "forceWalk", "ACE_refuel", true] call EFUNC(common,statusEffect_set); _unit setVariable [QGVAR(isRefueling), true]; private _actionID = _unit getVariable [QGVAR(ReleaseActionID), -1]; if (_actionID != -1) then { @@ -124,8 +136,13 @@ if (isNull _nozzle) then { // func is called on fuel truck if !(_nozzle getVariable [QGVAR(jerryCan), false]) then { [{ params ["_args", "_pfID"]; - _args params [["_unit", player, [objNull]], ["_source", objNull, [objNull]], ["_endPosOffset", [0, 0, 0], [[]], 3]]; - _args params ["", "", "", ["_nozzle", _unit getVariable [QGVAR(nozzle), objNull], [objNull]]]; + _args params [ + ["_unit", player, [objNull]], + ["_source", objNull, [objNull]], + ["_endPosOffset", [0, 0, 0], [[]], 3], + ["_nozzle", _unit getVariable [QGVAR(nozzle), objNull], [objNull]] + ]; + if (isNull _source || {_unit distance (_source modelToWorld _endPosOffset) > (REFUEL_HOSE_LENGTH - 2)} || {!alive _source}) exitWith { if !(isNull _nozzle) then { [_unit, _nozzle] call FUNC(dropNozzle); diff --git a/addons/refuel/script_component.hpp b/addons/refuel/script_component.hpp index 02a9660bdd..f05018d3e8 100644 --- a/addons/refuel/script_component.hpp +++ b/addons/refuel/script_component.hpp @@ -22,6 +22,7 @@ #define REFUEL_HOLSTER_WEAPON \ _unit setVariable [QGVAR(selectedWeaponOnRefuel), currentWeapon _unit]; \ + _unit call EFUNC(common,fixLoweredRifleAnimation); \ _unit action ["SwitchWeapon", _unit, _unit, 99]; #define REFUEL_UNHOLSTER_WEAPON \ From c591c7af64e60525ce0561c0c96fcaa7c7e2bf52 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 12 May 2016 21:30:32 +0200 Subject: [PATCH 189/215] Add interaction support to Motorcycle class --- addons/interaction/CfgVehicles.hpp | 26 ++++++++++++++++++++++++++ addons/repair/CfgEventHandlers.hpp | 6 ++++++ addons/repair/CfgVehicles.hpp | 4 ++++ 3 files changed, 36 insertions(+) diff --git a/addons/interaction/CfgVehicles.hpp b/addons/interaction/CfgVehicles.hpp index 6b6e0e69b0..b1c1cf852f 100644 --- a/addons/interaction/CfgVehicles.hpp +++ b/addons/interaction/CfgVehicles.hpp @@ -355,6 +355,32 @@ class CfgVehicles { }; }; + class Motorcycle: LandVehicle { + class ACE_Actions { + class ACE_MainActions { + displayName = CSTRING(MainAction); + selection = ""; + distance = 10; + condition = "true"; + class ACE_Passengers { + displayName = CSTRING(Passengers); + condition = "true"; + statement = ""; + insertChildren = QUOTE(_this call DFUNC(addPassengersActions)); + }; + }; + }; + + class ACE_SelfActions { + class ACE_Passengers { + displayName = CSTRING(Passengers); + condition = "true"; + statement = ""; + insertChildren = QUOTE(_this call DFUNC(addPassengersActions)); + }; + }; + }; + class Air; class Helicopter: Air { class ACE_Actions { diff --git a/addons/repair/CfgEventHandlers.hpp b/addons/repair/CfgEventHandlers.hpp index 06647d8dd5..f10cccba3a 100644 --- a/addons/repair/CfgEventHandlers.hpp +++ b/addons/repair/CfgEventHandlers.hpp @@ -31,6 +31,12 @@ class Extended_InitPost_EventHandlers { serverInit = QUOTE(_this call DFUNC(addSpareParts)); }; }; + class Motorcycle { + class ADDON { + init = QUOTE(_this call DFUNC(addRepairActions)); + serverInit = QUOTE(_this call DFUNC(addSpareParts)); + }; + }; class Helicopter { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); diff --git a/addons/repair/CfgVehicles.hpp b/addons/repair/CfgVehicles.hpp index 0a1d6f55dc..da5f42e9a8 100644 --- a/addons/repair/CfgVehicles.hpp +++ b/addons/repair/CfgVehicles.hpp @@ -290,6 +290,10 @@ class CfgVehicles { MACRO_REPAIRVEHICLE }; + class Motorcycle: LandVehicle { + MACRO_REPAIRVEHICLE + }; + class Air; class Helicopter: Air { MACRO_REPAIRVEHICLE From f6e4bd7a6b42a43f37d6984820691415cdc5cff5 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 12 May 2016 21:37:54 +0200 Subject: [PATCH 190/215] Remove redundant spare part adding --- addons/repair/CfgEventHandlers.hpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/addons/repair/CfgEventHandlers.hpp b/addons/repair/CfgEventHandlers.hpp index f10cccba3a..2d8f54b725 100644 --- a/addons/repair/CfgEventHandlers.hpp +++ b/addons/repair/CfgEventHandlers.hpp @@ -28,13 +28,11 @@ class Extended_InitPost_EventHandlers { class Tank { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE(_this call DFUNC(addSpareParts)); }; }; class Motorcycle { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE(_this call DFUNC(addSpareParts)); }; }; class Helicopter { From 58cc686aac9b21d802e9b5d20985329a31d7c715 Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 12 May 2016 21:49:45 +0200 Subject: [PATCH 191/215] Remove initial spare part adding for classes not Car or Tank, Improve addSpareParts --- addons/repair/CfgEventHandlers.hpp | 7 ++----- addons/repair/functions/fnc_addSpareParts.sqf | 12 ++---------- 2 files changed, 4 insertions(+), 15 deletions(-) diff --git a/addons/repair/CfgEventHandlers.hpp b/addons/repair/CfgEventHandlers.hpp index 06647d8dd5..a2f9587524 100644 --- a/addons/repair/CfgEventHandlers.hpp +++ b/addons/repair/CfgEventHandlers.hpp @@ -22,32 +22,29 @@ class Extended_InitPost_EventHandlers { class Car { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE(_this call DFUNC(addSpareParts)); + serverInit = QUOTE([ARR_3(_this select 0,1,'ACE_Wheel')] call DFUNC(addSpareParts)); }; }; class Tank { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE(_this call DFUNC(addSpareParts)); + serverInit = QUOTE([ARR_3(_this select 0,1,'ACE_Wheel')] call DFUNC(addSpareParts)); }; }; class Helicopter { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE(_this call DFUNC(addSpareParts)); exclude[] = {QEGVAR(fastroping,helper), "ACE_friesBase"}; }; }; class Plane { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE(_this call DFUNC(addSpareParts)); }; }; class Ship_F { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE(_this call DFUNC(addSpareParts)); }; }; }; diff --git a/addons/repair/functions/fnc_addSpareParts.sqf b/addons/repair/functions/fnc_addSpareParts.sqf index 74ea0d4c10..3d7247fcaa 100644 --- a/addons/repair/functions/fnc_addSpareParts.sqf +++ b/addons/repair/functions/fnc_addSpareParts.sqf @@ -21,8 +21,8 @@ params ["_vehicle", ["_amount", 1], ["_part", ""], ["_force", false]]; TRACE_2("params",_vehicle,_amount); -// Exit if ace_cargo is not loaded -if !(["ace_cargo"] call EFUNC(common,isModLoaded)) exitWith {}; +// Exit if ace_cargo is not loaded or no part supplied +if (!(["ace_cargo"] call EFUNC(common,isModLoaded)) || {_part == ""}) exitWith {}; // Collect until SettingsInitialized if (!EGVAR(common,settingsInitFinished)) exitWith { @@ -32,13 +32,5 @@ if (!EGVAR(common,settingsInitFinished)) exitWith { // Exit if not forced and add spare parts is disabled (after settings initted to make sure it really is) if (!_force && !GVAR(addSpareParts)) exitWith {}; -// Select appropriate part -if (_part == "") then { - if (_vehicle isKindOf "Car") then { _part = "ACE_Wheel" }; - if (_vehicle isKindOf "Tank") then { _part = "ACE_Track" }; -}; -// Exit if no appropriate part -if (_part == "") exitWith {}; - // Load ["AddCargoByClass", [_part, _vehicle, _amount]] call EFUNC(common,localEvent); From 2d2d5bc828366b5168a477c2557e2a9f26792c0e Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 12 May 2016 21:52:06 +0200 Subject: [PATCH 192/215] Readd mistakenly removed spare part adding --- addons/repair/CfgEventHandlers.hpp | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/repair/CfgEventHandlers.hpp b/addons/repair/CfgEventHandlers.hpp index 2d8f54b725..f38dc21d23 100644 --- a/addons/repair/CfgEventHandlers.hpp +++ b/addons/repair/CfgEventHandlers.hpp @@ -28,6 +28,7 @@ class Extended_InitPost_EventHandlers { class Tank { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); + serverInit = QUOTE(_this call DFUNC(addSpareParts)); }; }; class Motorcycle { From e984fcf7154bf147c5ec98c40779a84a04055e6e Mon Sep 17 00:00:00 2001 From: jonpas Date: Thu, 12 May 2016 21:56:12 +0200 Subject: [PATCH 193/215] Fix part name for Tank class --- addons/repair/CfgEventHandlers.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/repair/CfgEventHandlers.hpp b/addons/repair/CfgEventHandlers.hpp index a2f9587524..6ec3a2cefd 100644 --- a/addons/repair/CfgEventHandlers.hpp +++ b/addons/repair/CfgEventHandlers.hpp @@ -28,7 +28,7 @@ class Extended_InitPost_EventHandlers { class Tank { class ADDON { init = QUOTE(_this call DFUNC(addRepairActions)); - serverInit = QUOTE([ARR_3(_this select 0,1,'ACE_Wheel')] call DFUNC(addSpareParts)); + serverInit = QUOTE([ARR_3(_this select 0,1,'ACE_Track')] call DFUNC(addSpareParts)); }; }; class Helicopter { From a950b2c2fe79d40263027d50a14c21270165d754 Mon Sep 17 00:00:00 2001 From: jonpas Date: Fri, 13 May 2016 16:33:15 +0200 Subject: [PATCH 194/215] Add canPush config entry to enable pushing on boats with mass higher than 2600 --- addons/interaction/CfgVehicles.hpp | 2 +- addons/interaction/XEH_PREP.hpp | 1 + addons/interaction/functions/fnc_canPush.sqf | 22 ++++++++++++++++++++ addons/interaction/functions/fnc_push.sqf | 3 +-- 4 files changed, 25 insertions(+), 3 deletions(-) create mode 100644 addons/interaction/functions/fnc_canPush.sqf diff --git a/addons/interaction/CfgVehicles.hpp b/addons/interaction/CfgVehicles.hpp index 6b6e0e69b0..5a81d0b6fc 100644 --- a/addons/interaction/CfgVehicles.hpp +++ b/addons/interaction/CfgVehicles.hpp @@ -420,7 +420,7 @@ class CfgVehicles { class ACE_Push { displayName = CSTRING(Push); distance = 6; - condition = QUOTE(getMass _target <= 2600 && {alive _target} && {vectorMagnitude velocity _target < 3}); + condition = QUOTE(_target call FUNC(canPush)); statement = QUOTE(_this call FUNC(push)); showDisabled = 0; priority = -1; diff --git a/addons/interaction/XEH_PREP.hpp b/addons/interaction/XEH_PREP.hpp index 71facedc3f..be6158cdd5 100644 --- a/addons/interaction/XEH_PREP.hpp +++ b/addons/interaction/XEH_PREP.hpp @@ -32,6 +32,7 @@ PREP(handleScrollWheel); PREP(openDoor); // interaction with boats +PREP(canPush); PREP(push); PREP(switchLamp); diff --git a/addons/interaction/functions/fnc_canPush.sqf b/addons/interaction/functions/fnc_canPush.sqf new file mode 100644 index 0000000000..478c89ca45 --- /dev/null +++ b/addons/interaction/functions/fnc_canPush.sqf @@ -0,0 +1,22 @@ +/* + * Author: Jonpas + * Checks if the boat can be pushed. + * + * Arguments: + * 0: Target + * + * Return Value: + * Can Push + * + * Example: + * [target] call ace_interaction_fnc_canPush + * + * Public: No + */ +#include "script_component.hpp" + +params ["_target"]; + +alive _target && +{getMass _target <= 2600 || getNumber (configFile >> "CfgVehicles" >> typeOf _target >> QGVAR(canPush)) == 1} && +{vectorMagnitude velocity _target < 3} diff --git a/addons/interaction/functions/fnc_push.sqf b/addons/interaction/functions/fnc_push.sqf index 9a6c86a18e..bdeaf29012 100644 --- a/addons/interaction/functions/fnc_push.sqf +++ b/addons/interaction/functions/fnc_push.sqf @@ -18,8 +18,7 @@ params ["_boat", "_unit"]; -private "_newVelocity"; -_newVelocity = vectorDir _unit; +private _newVelocity = vectorDir _unit; _newVelocity set [2, 0.25]; _newVelocity = _newVelocity vectorMultiply 2; From d48bd3ca8359ba65f165b7978ed16b0e7d238fb3 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 13 May 2016 19:54:14 -0500 Subject: [PATCH 195/215] Remove old testmission addon --- addons/testmissions/$PBOPREFIX$ | 1 - .../ACETestingMap1.Stratis/description.ext | 17 - .../ACETestingMap1.Stratis/init.sqf | 1 - .../ACETestingMap1.Stratis/mission.sqm | 1248 ----------------- addons/testmissions/README.md | 11 - addons/testmissions/config.cpp | 20 - addons/testmissions/script_component.hpp | 17 - 7 files changed, 1315 deletions(-) delete mode 100644 addons/testmissions/$PBOPREFIX$ delete mode 100644 addons/testmissions/MPMissions/ACETestingMap1.Stratis/description.ext delete mode 100644 addons/testmissions/MPMissions/ACETestingMap1.Stratis/init.sqf delete mode 100644 addons/testmissions/MPMissions/ACETestingMap1.Stratis/mission.sqm delete mode 100644 addons/testmissions/README.md delete mode 100644 addons/testmissions/config.cpp delete mode 100644 addons/testmissions/script_component.hpp diff --git a/addons/testmissions/$PBOPREFIX$ b/addons/testmissions/$PBOPREFIX$ deleted file mode 100644 index c899a56127..0000000000 --- a/addons/testmissions/$PBOPREFIX$ +++ /dev/null @@ -1 +0,0 @@ -z\ace\addons\testmissions \ No newline at end of file diff --git a/addons/testmissions/MPMissions/ACETestingMap1.Stratis/description.ext b/addons/testmissions/MPMissions/ACETestingMap1.Stratis/description.ext deleted file mode 100644 index d61b2cf200..0000000000 --- a/addons/testmissions/MPMissions/ACETestingMap1.Stratis/description.ext +++ /dev/null @@ -1,17 +0,0 @@ -enableDebugConsole = 2; //note security risk - -// respawn = "GROUP"; -respawn = "BASE"; -// respawn = "BIRD"; -respawnDelay = 2; - -class Header { - gameType = Coop; - minPlayers = 1; - maxPlayers = 491; -}; - -onLoadName = "ACE3 Testing"; -// onLoadMission = ""; -// author = ""; -// loadScreen = ""; \ No newline at end of file diff --git a/addons/testmissions/MPMissions/ACETestingMap1.Stratis/init.sqf b/addons/testmissions/MPMissions/ACETestingMap1.Stratis/init.sqf deleted file mode 100644 index f2c95b8ca2..0000000000 --- a/addons/testmissions/MPMissions/ACETestingMap1.Stratis/init.sqf +++ /dev/null @@ -1 +0,0 @@ -enableSaving [false, false]; diff --git a/addons/testmissions/MPMissions/ACETestingMap1.Stratis/mission.sqm b/addons/testmissions/MPMissions/ACETestingMap1.Stratis/mission.sqm deleted file mode 100644 index 08bba0bcb1..0000000000 --- a/addons/testmissions/MPMissions/ACETestingMap1.Stratis/mission.sqm +++ /dev/null @@ -1,1248 +0,0 @@ -version=12; -class Mission -{ - addOns[]= - { - "A3_Characters_F_BLUFOR", - "a3_characters_f", - "a3_map_stratis", - "A3_armor_f_beta_APC_Tracked_02", - "A3_Characters_F_INDEP", - "ace_vehiclelock", - "A3_Soft_F_MRAP_01", - "A3_Soft_F_Car", - "ace_map", - "A3_Static_F_Gamma_AA", - "A3_Static_F_Mortar_01", - "A3_Static_F_Gamma", - "a3_static_f", - "ace_captives", - "A3_Armor_F_Slammer", - "A3_Air_F_Beta_Heli_Attack_01", - "ace_medical", - "ace_common", - "A3_Weapons_F_Ammoboxes", - "A3_Armor_F_EPB_APC_tracked_03", - "A3_Air_F_Heli_Light_01", - "A3_Air_F_Beta_Heli_Transport_01", - "A3_Armor_F_T100K", - "A3_Boat_F_Boat_Armed_01", - "A3_Boat_F_Civilian_Boat", - "A3_Boat_F_Boat_Transport_01", - "A3_Characters_F_Gamma", - "A3_Air_F_Gamma_UAV_02", - "A3_Static_F_Gamma_AT" - }; - addOnsAuto[]= - { - "A3_Characters_F_BLUFOR", - "a3_characters_f", - "A3_Characters_F_INDEP", - "ace_vehiclelock", - "ace_captives", - "A3_Air_F_Gamma_UAV_02", - "A3_Characters_F_Gamma", - "A3_Soft_F_MRAP_01", - "A3_Soft_F_Car", - "A3_Static_F_Gamma_AA", - "A3_Static_F_Mortar_01", - "A3_Static_F_Gamma", - "a3_static_f", - "A3_Armor_F_Slammer", - "ace_medical", - "ace_common", - "A3_Weapons_F_Ammoboxes", - "A3_Armor_F_EPB_APC_tracked_03", - "A3_Air_F_Beta_Heli_Attack_01", - "A3_Air_F_Heli_Light_01", - "A3_Air_F_Beta_Heli_Transport_01", - "A3_Armor_F_T100K", - "A3_Boat_F_Boat_Armed_01", - "A3_Boat_F_Civilian_Boat", - "A3_Boat_F_Boat_Transport_01", - "A3_Static_F_Gamma_AT", - "a3_map_stratis" - }; - randomSeed=709402; - class Intel - { - startWeather=0; - startWind=0; - startWaves=0.099999994; - forecastWeather=0; - forecastWind=0; - forecastWaves=0.099999994; - forecastLightnings=0.099999994; - year=2035; - month=7; - day=6; - hour=12; - minute=0; - startFogDecay=0.013; - forecastFogDecay=0.013; - }; - class Groups - { - items=19; - class Item0 - { - side="WEST"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1716.1971,5.5,5752.0244}; - azimut=-50.831005; - id=0; - side="WEST"; - vehicle="B_Soldier_F"; - player="PLAY CDG"; - leader=1; - skill=0.60000002; - init="this addItem ""ACE_key_civ"""; - description="Keys For CD"; - syncId=0; - synchronizations[]={3}; - }; - }; - }; - class Item1 - { - side="GUER"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1709.5989,5.5,5740.709}; - azimut=-67.220284; - id=1; - side="GUER"; - vehicle="I_soldier_F"; - player="PLAY CDG"; - leader=1; - skill=0.60000002; - init="this addItem ""ACE_key_east"""; - description="Keys for AB"; - syncId=1; - synchronizations[]={2}; - }; - }; - }; - class Item2 - { - side="LOGIC"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1712.0765,5.5,5743.5811}; - id=2; - side="LOGIC"; - vehicle="ACE_VehicleLock_ModuleSyncedAssign"; - leader=1; - lock="UNLOCKED"; - skill=0.60000002; - syncId=2; - synchronizations[]={1,6}; - }; - }; - }; - class Item3 - { - side="LOGIC"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1714.5892,5.5,5748.7002}; - id=3; - side="LOGIC"; - vehicle="ACE_VehicleLock_ModuleSyncedAssign"; - leader=1; - lock="UNLOCKED"; - skill=0.60000002; - syncId=3; - synchronizations[]={7,0}; - }; - }; - }; - class Item4 - { - side="LOGIC"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1715.7699,5.5,5745.752}; - class args - { - items=3; - class Item0 - { - value="1"; - parentCls="ACE_VehicleLock_ModuleSetup"; - typeName="LockVehicleInventory"; - }; - class Item1 - { - value="0"; - parentCls="ACE_VehicleLock_ModuleSetup"; - typeName="SetLockState"; - }; - class Item2 - { - value="15"; - parentCls="ACE_VehicleLock_ModuleSetup"; - typeName="DefaultLockpickStrength"; - }; - }; - id=4; - side="LOGIC"; - vehicle="ACE_VehicleLock_ModuleSetup"; - leader=1; - lock="UNLOCKED"; - skill=0.60000002; - }; - }; - }; - class Item5 - { - side="WEST"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1703.6329,5.5,5730.1909}; - azimut=119.576; - id=5; - side="WEST"; - vehicle="B_Soldier_F"; - player="PLAY CDG"; - leader=1; - skill=0.60000002; - text="Q"; - init="nul = this spawn {sleep 3; [_this] call ace_medical_fnc_setUnconscious};"; - description="Q Unconscious at start"; - }; - }; - }; - class Item6 - { - side="WEST"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1702.6882,5.5,5728.8687}; - azimut=103.13899; - id=6; - side="WEST"; - vehicle="B_Soldier_F"; - player="PLAY CDG"; - leader=1; - skill=0.60000002; - text="a1"; - description="Surrender At Start"; - syncId=4; - synchronizations[]={5}; - }; - }; - }; - class Item7 - { - side="LOGIC"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1701.0719,5.5,5727.5586}; - azimut=15.1769; - id=7; - side="LOGIC"; - vehicle="ace_captives_ModuleSurrender"; - leader=1; - lock="UNLOCKED"; - skill=0.60000002; - syncId=5; - synchronizations[]={4}; - }; - }; - }; - class Item8 - { - side="WEST"; - class Vehicles - { - items=4; - class Item0 - { - position[]={1703.7711,5.5,5715.2427}; - azimut=11.294894; - id=8; - side="WEST"; - vehicle="B_Soldier_TL_F"; - player="PLAY CDG"; - leader=1; - rank="CORPORAL"; - skill=0.60000002; - text="GrpNATO_A1_0"; - description="NATO Alpha 1 Fireteam Leader"; - }; - class Item1 - { - position[]={1706.2533,5.5,5712.9951}; - azimut=11.294894; - id=9; - side="WEST"; - vehicle="B_Soldier_LAT_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A1_1"; - description="NATO Alpha 1 Rifleman (AT)"; - }; - class Item2 - { - position[]={1709.2836,5.5,5712.2866}; - azimut=11.294894; - id=10; - side="WEST"; - vehicle="B_Soldier_AAR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A1_2"; - description="NATO Alpha 1 Assistant Automatic Rifleman"; - }; - class Item3 - { - position[]={1712.4042,5.5,5711.6323}; - azimut=11.294894; - id=11; - side="WEST"; - vehicle="B_Soldier_AR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A1_3"; - description="NATO Alpha 1 Automatic Rifleman"; - }; - }; - }; - class Item9 - { - side="WEST"; - class Vehicles - { - items=4; - class Item0 - { - position[]={1700.8379,5.5,5704.4658}; - azimut=11.294894; - id=12; - side="WEST"; - vehicle="B_Soldier_TL_F"; - player="PLAY CDG"; - leader=1; - rank="CORPORAL"; - skill=0.60000002; - text="GrpNATO_A2_0"; - description="NATO Alpha 2 Fireteam Leader"; - }; - class Item1 - { - position[]={1703.1456,5.5,5702.0576}; - azimut=11.294894; - id=13; - side="WEST"; - vehicle="B_Soldier_LAT_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A2_1"; - description="NATO Alpha 2 Rifleman (AT)"; - }; - class Item2 - { - position[]={1706.1492,5.5,5701.3618}; - azimut=11.294894; - id=14; - side="WEST"; - vehicle="B_Soldier_AAR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A2_2"; - description="NATO Alpha 2 Assistant Automatic Rifleman"; - }; - class Item3 - { - position[]={1709.3947,5.5,5700.7007}; - azimut=11.294894; - id=15; - side="WEST"; - vehicle="B_Soldier_AR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A2_3"; - description="NATO Alpha 2 Automatic Rifleman"; - }; - }; - }; - class Item10 - { - side="WEST"; - class Vehicles - { - items=4; - class Item0 - { - position[]={1696.9097,5.5,5693.7847}; - azimut=11.294894; - id=16; - side="WEST"; - vehicle="B_Soldier_TL_F"; - player="PLAY CDG"; - leader=1; - rank="CORPORAL"; - skill=0.60000002; - text="GrpNATO_A3_0"; - description="NATO Alpha 3 Fireteam Leader"; - }; - class Item1 - { - position[]={1699.3469,5.5,5691.3257}; - azimut=11.294894; - id=17; - side="WEST"; - vehicle="B_Soldier_LAT_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A3_1"; - description="NATO Alpha 3 Rifleman (AT)"; - }; - class Item2 - { - position[]={1702.4423,5.5,5690.4912}; - azimut=11.294894; - id=18; - side="WEST"; - vehicle="B_Soldier_AAR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A3_2"; - description="NATO Alpha 3 Assistant Automatic Rifleman"; - }; - class Item3 - { - position[]={1705.6521,5.5,5689.7666}; - azimut=11.294894; - id=19; - side="WEST"; - vehicle="B_Soldier_AR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_A3_3"; - description="NATO Alpha 3 Automatic Rifleman"; - }; - }; - }; - class Item11 - { - side="WEST"; - class Vehicles - { - items=4; - class Item0 - { - position[]={1685.6747,5.5,5720.1187}; - azimut=11.294894; - id=20; - side="WEST"; - vehicle="B_Soldier_TL_F"; - player="PLAY CDG"; - leader=1; - rank="CORPORAL"; - skill=0.60000002; - text="GrpNATO_B1_0"; - description="NATO Bravo 1 Fireteam Leader"; - }; - class Item1 - { - position[]={1688.1687,5.5,5717.9639}; - azimut=11.294894; - id=21; - side="WEST"; - vehicle="B_Soldier_LAT_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B1_1"; - description="NATO Bravo 1 Rifleman (AT)"; - }; - class Item2 - { - position[]={1691.0776,5.5,5717.2754}; - azimut=11.294894; - id=22; - side="WEST"; - vehicle="B_Soldier_AAR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B1_2"; - description="NATO Bravo 1 Assistant Automatic Rifleman"; - }; - class Item3 - { - position[]={1694.293,5.5,5716.6172}; - azimut=11.294894; - id=23; - side="WEST"; - vehicle="B_Soldier_AR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B1_3"; - description="NATO Bravo 1 Automatic Rifleman"; - }; - }; - }; - class Item12 - { - side="WEST"; - class Vehicles - { - items=4; - class Item0 - { - position[]={1682.364,5.5,5709.4131}; - azimut=11.294894; - id=24; - side="WEST"; - vehicle="B_Soldier_TL_F"; - player="PLAY CDG"; - leader=1; - rank="CORPORAL"; - skill=0.60000002; - text="GrpNATO_B2_0"; - description="NATO Bravo 2 Fireteam Leader"; - }; - class Item1 - { - position[]={1685.1151,5.5,5707.0654}; - azimut=11.294894; - id=25; - side="WEST"; - vehicle="B_Soldier_LAT_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B2_1"; - description="NATO Bravo 2 Rifleman (AT)"; - }; - class Item2 - { - position[]={1688.1718,5.5,5706.313}; - azimut=11.294894; - id=26; - side="WEST"; - vehicle="B_Soldier_AAR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B2_2"; - description="NATO Bravo 2 Assistant Automatic Rifleman"; - }; - class Item3 - { - position[]={1691.5254,5.5,5705.6113}; - azimut=11.294894; - id=27; - side="WEST"; - vehicle="B_Soldier_AR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B2_3"; - description="NATO Bravo 2 Automatic Rifleman"; - }; - }; - }; - class Item13 - { - side="WEST"; - class Vehicles - { - items=4; - class Item0 - { - position[]={1678.4825,5.5,5697.4468}; - azimut=11.294894; - id=28; - side="WEST"; - vehicle="B_Soldier_TL_F"; - player="PLAY CDG"; - leader=1; - rank="CORPORAL"; - skill=0.60000002; - text="GrpNATO_B3_0"; - description="NATO Bravo 3 Fireteam Leader"; - }; - class Item1 - { - position[]={1681.5645,5.5,5696.561}; - azimut=11.294894; - id=29; - side="WEST"; - vehicle="B_Soldier_LAT_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B3_1"; - description="NATO Bravo 3 Rifleman (AT)"; - }; - class Item2 - { - position[]={1684.6531,5.5,5695.8491}; - azimut=11.294894; - id=30; - side="WEST"; - vehicle="B_Soldier_AAR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B3_2"; - description="NATO Bravo 3 Assistant Automatic Rifleman"; - }; - class Item3 - { - position[]={1687.8109,5.5,5695.1021}; - azimut=11.294894; - id=31; - side="WEST"; - vehicle="B_Soldier_AR_F"; - player="PLAY CDG"; - skill=0.60000002; - text="GrpNATO_B3_3"; - description="NATO Bravo 3 Automatic Rifleman"; - }; - }; - }; - class Item14 - { - side="WEST"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1540.8328,-27.831757,6018.0283}; - azimut=4.41886; - special="FLY"; - id=32; - side="WEST"; - vehicle="B_UAV_02_CAS_F"; - isUAV=1; - leader=1; - skill=0.60000002; - }; - }; - }; - class Item15 - { - side="WEST"; - class Vehicles - { - items=1; - class Item0 - { - position[]={2861.0947,0,6407.8574}; - azimut=4.41886; - special="FLY"; - id=33; - side="WEST"; - vehicle="B_UAV_02_CAS_F"; - isUAV=1; - leader=1; - skill=0.60000002; - }; - }; - }; - class Item16 - { - side="WEST"; - class Vehicles - { - items=1; - class Item0 - { - position[]={1944.1785,0,6868.8906}; - azimut=4.41886; - special="FLY"; - id=34; - side="WEST"; - vehicle="B_UAV_02_CAS_F"; - isUAV=1; - leader=1; - skill=0.60000002; - }; - }; - }; - class Item17 - { - side="WEST"; - class Vehicles - { - items=4; - class Item0 - { - position[]={1713.3085,5.5,5725.0205}; - azimut=98.173798; - id=35; - side="WEST"; - vehicle="B_medic_F"; - player="PLAY CDG"; - leader=1; - rank="LIEUTENANT"; - skill=0.60000002; - text="Medic2"; - description="Medic 2"; - }; - class Item1 - { - position[]={1712.2098,5.5,5727.1675}; - azimut=98.173798; - id=36; - side="WEST"; - vehicle="B_medic_F"; - player="PLAY CDG"; - skill=0.60000002; - text="Medic1"; - description="Medic 1"; - }; - class Item2 - { - position[]={1711.6387,5.5,5725.041}; - azimut=98.173798; - id=37; - side="WEST"; - vehicle="B_medic_F"; - player="PLAY CDG"; - skill=0.60000002; - text="Medic3"; - description="Medic 3"; - }; - class Item3 - { - position[]={1710.0735,5.5,5726.4287}; - id=38; - side="WEST"; - vehicle="B_soldier_UAV_F"; - player="PLAY CDG"; - skill=0.60000002; - text="uavGuy"; - }; - }; - }; - class Item18 - { - side="WEST"; - class Vehicles - { - items=2; - class Item0 - { - position[]={1722.298,5.5,5733.4629}; - azimut=4.41886; - special="FLY"; - id=39; - side="WEST"; - vehicle="B_Soldier_F"; - player="PLAYER COMMANDER"; - leader=1; - skill=0.60000002; - text="R1"; - description="sp tester"; - }; - class Item1 - { - position[]={1722.7957,5.5,5732.481}; - azimut=4.41886; - special="FLY"; - id=40; - side="WEST"; - vehicle="B_Soldier_F"; - player="PLAY CDG"; - skill=0.60000002; - text="R2"; - description="sp tester2"; - }; - }; - }; - }; - class Vehicles - { - items=38; - class Item0 - { - position[]={1706.5913,5.5,5748.0903}; - azimut=-68.59301; - id=41; - side="EMPTY"; - vehicle="B_MRAP_01_F"; - leader=1; - skill=0.60000002; - text="car1"; - syncId=6; - synchronizations[]={2}; - }; - class Item1 - { - position[]={1707.5599,5.5,5753.0518}; - azimut=-65.45974; - id=42; - side="EMPTY"; - vehicle="B_MRAP_01_F"; - leader=1; - lock="LOCKED"; - skill=0.60000002; - text="car3"; - syncId=7; - synchronizations[]={3}; - }; - class Item2 - { - position[]={1708.7251,5.5,5757.8809}; - azimut=-65.45974; - id=43; - side="EMPTY"; - vehicle="C_Hatchback_01_F"; - leader=1; - lock="UNLOCKED"; - skill=0.60000002; - text="car4"; - }; - class Item3 - { - position[]={1704.4299,5.5,5742.8721}; - azimut=-68.59301; - id=44; - side="EMPTY"; - vehicle="C_Hatchback_01_F"; - leader=1; - lock="UNLOCKED"; - skill=0.60000002; - text="car0"; - init="this setVariable [""ACE_VehicleLock_lockSide"", east];"; - }; - class Item4 - { - position[]={1738.8502,5.5,5728.8525}; - azimut=101.05981; - id=45; - side="EMPTY"; - vehicle="B_static_AA_F"; - skill=0.60000002; - text="q1"; - }; - class Item5 - { - position[]={1738.4388,5.5,5726.1929}; - azimut=101.05981; - id=46; - side="EMPTY"; - vehicle="B_Mortar_01_F"; - skill=0.60000002; - text="q2"; - }; - class Item6 - { - position[]={1737.8582,5.5,5723.3979}; - azimut=101.05981; - id=47; - side="EMPTY"; - vehicle="B_HMG_01_high_F"; - skill=0.60000002; - text="q3"; - }; - class Item7 - { - position[]={1738.9786,5.5,5734.6968}; - azimut=104.535; - id=48; - side="EMPTY"; - vehicle="B_MBT_01_cannon_F"; - lock="UNLOCKED"; - skill=0.60000002; - }; - class Item8 - { - position[]={1734.713,5.5,5720.061}; - azimut=10.202663; - id=49; - side="EMPTY"; - vehicle="ACE_medicalSupplyCrate"; - leader=1; - skill=0.60000002; - }; - class Item9 - { - position[]={1737.2236,5.5,5719.5591}; - azimut=10.202663; - id=50; - side="EMPTY"; - vehicle="ACE_medicalSupplyCrate"; - leader=1; - skill=0.60000002; - }; - class Item10 - { - position[]={1733.2904,5.5,5717.6465}; - azimut=13.57355; - id=51; - side="EMPTY"; - vehicle="ACE_Box_Misc"; - leader=1; - skill=0.60000002; - }; - class Item11 - { - position[]={1736.1099,5.5,5717.1831}; - azimut=13.57355; - id=52; - side="EMPTY"; - vehicle="ACE_Box_Misc"; - leader=1; - skill=0.60000002; - }; - class Item12 - { - position[]={1732.4794,5.5,5715.4067}; - azimut=9.5156059; - id=53; - side="EMPTY"; - vehicle="Box_NATO_AmmoOrd_F"; - leader=1; - skill=0.60000002; - }; - class Item13 - { - position[]={1735.2601,5.5,5714.7891}; - azimut=9.5156059; - id=54; - side="EMPTY"; - vehicle="Box_NATO_AmmoOrd_F"; - leader=1; - skill=0.60000002; - }; - class Item14 - { - position[]={1743.4641,5.5,5753.5161}; - azimut=104.535; - id=55; - side="EMPTY"; - vehicle="B_MRAP_01_hmg_F"; - lock="UNLOCKED"; - skill=0.60000002; - }; - class Item15 - { - position[]={1741.916,5.5,5747.4302}; - azimut=104.535; - id=56; - side="EMPTY"; - vehicle="I_APC_tracked_03_cannon_F"; - lock="UNLOCKED"; - skill=0.60000002; - }; - class Item16 - { - position[]={1722.1113,5.5,5768.3818}; - azimut=193.13876; - id=57; - side="EMPTY"; - vehicle="B_Heli_Attack_01_F"; - skill=0.60000002; - }; - class Item17 - { - position[]={1733.6005,5.5,5765.2881}; - azimut=198.2417; - id=58; - side="EMPTY"; - vehicle="B_Heli_Light_01_armed_F"; - skill=0.60000002; - }; - class Item18 - { - position[]={1746.17,5.5,5764.1099}; - azimut=198.97742; - id=59; - side="EMPTY"; - vehicle="B_Heli_Transport_01_F"; - skill=0.60000002; - }; - class Item19 - { - position[]={1909.3875,10.094501,5668.21}; - azimut=4.41886; - id=60; - side="EMPTY"; - vehicle="O_MBT_02_cannon_F"; - skill=0.60000002; - }; - class Item20 - { - position[]={1724.0231,5.5,5722.8857}; - azimut=104.535; - id=61; - side="EMPTY"; - vehicle="Box_IND_Wps_F"; - skill=0.60000002; - }; - class Item21 - { - position[]={1724.6892,5.5,5724.7744}; - azimut=104.535; - id=62; - side="EMPTY"; - vehicle="Box_IND_Ammo_F"; - skill=0.60000002; - }; - class Item22 - { - position[]={1717.6512,5.5,5724.0181}; - azimut=104.535; - id=63; - side="EMPTY"; - vehicle="Box_IND_Wps_F"; - skill=0.60000002; - }; - class Item23 - { - position[]={1718.2023,5.5,5726.3066}; - azimut=104.535; - id=64; - side="EMPTY"; - vehicle="Box_IND_Ammo_F"; - skill=0.60000002; - }; - class Item24 - { - position[]={1733.6895,5.5,5706.4785}; - azimut=104.535; - id=65; - side="EMPTY"; - vehicle="Box_NATO_WpsLaunch_F"; - skill=0.60000002; - }; - class Item25 - { - position[]={1733.21,5.5,5704.1836}; - azimut=104.535; - id=66; - side="EMPTY"; - vehicle="Box_East_WpsLaunch_F"; - skill=0.60000002; - }; - class Item26 - { - position[]={1732.4906,5.5,5701.6831}; - azimut=104.535; - id=67; - side="EMPTY"; - vehicle="Box_IND_WpsLaunch_F"; - skill=0.60000002; - }; - class Item27 - { - position[]={1825.109,5.5,5676.3613}; - azimut=4.41886; - id=68; - side="EMPTY"; - vehicle="O_MBT_02_cannon_F"; - skill=0.60000002; - text="t1"; - }; - class Item28 - { - position[]={1894.5531,5.6621442,5745.1523}; - azimut=4.41886; - id=69; - side="EMPTY"; - vehicle="O_MBT_02_cannon_F"; - skill=0.60000002; - }; - class Item29 - { - position[]={1863.2545,5.5,5712.0615}; - azimut=4.41886; - id=70; - side="EMPTY"; - vehicle="O_MBT_02_cannon_F"; - skill=0.60000002; - }; - class Item30 - { - position[]={1740.923,5.5,5741.1685}; - azimut=104.535; - id=71; - side="EMPTY"; - vehicle="B_MBT_01_cannon_F"; - lock="UNLOCKED"; - skill=0.60000002; - }; - class Item31 - { - position[]={1721.363,5.5,5724.4956}; - azimut=104.535; - id=72; - side="EMPTY"; - vehicle="Box_NATO_Grenades_F"; - lock="UNLOCKED"; - skill=0.60000002; - }; - class Item32 - { - position[]={1722.3844,5.5,5727.0381}; - azimut=104.535; - id=73; - side="EMPTY"; - vehicle="Box_NATO_WpsSpecial_F"; - lock="UNLOCKED"; - skill=0.60000002; - }; - class Item33 - { - position[]={1644.8666,0,5751.0166}; - azimut=-19.956911; - id=74; - side="EMPTY"; - vehicle="B_Boat_Armed_01_minigun_F"; - skill=0.60000002; - }; - class Item34 - { - position[]={1639.6296,0,5741.1772}; - azimut=-19.956911; - id=75; - side="EMPTY"; - vehicle="B_Boat_Armed_01_minigun_F"; - skill=0.60000002; - }; - class Item35 - { - position[]={1636.3765,0,5727.1333}; - azimut=-19.9569; - id=76; - side="EMPTY"; - vehicle="C_Boat_Civil_01_F"; - skill=0.60000002; - }; - class Item36 - { - position[]={1652.0231,-0.71640843,5760.2349}; - azimut=-19.9569; - id=77; - side="EMPTY"; - vehicle="B_Boat_Transport_01_F"; - skill=0.60000002; - }; - class Item37 - { - position[]={1739.5898,5.5,5730.6455}; - azimut=101.06; - id=78; - side="EMPTY"; - vehicle="B_static_AT_F"; - skill=0.60000002; - text="q0"; - }; - }; -}; -class Intro -{ - addOns[]= - { - "a3_map_stratis" - }; - addOnsAuto[]= - { - "a3_map_stratis" - }; - randomSeed=13628778; - class Intel - { - timeOfChanges=1800.0002; - startWeather=0.30000001; - startWind=0.1; - startWaves=0.1; - forecastWeather=0.30000001; - forecastWind=0.1; - forecastWaves=0.1; - forecastLightnings=0.1; - year=2035; - month=7; - day=6; - hour=12; - minute=0; - startFogDecay=0.013; - forecastFogDecay=0.013; - }; -}; -class OutroWin -{ - addOns[]= - { - "a3_map_stratis" - }; - addOnsAuto[]= - { - "a3_map_stratis" - }; - randomSeed=8997795; - class Intel - { - timeOfChanges=1800.0002; - startWeather=0.30000001; - startWind=0.1; - startWaves=0.1; - forecastWeather=0.30000001; - forecastWind=0.1; - forecastWaves=0.1; - forecastLightnings=0.1; - year=2035; - month=7; - day=6; - hour=12; - minute=0; - startFogDecay=0.013; - forecastFogDecay=0.013; - }; -}; -class OutroLoose -{ - addOns[]= - { - "a3_map_stratis" - }; - addOnsAuto[]= - { - "a3_map_stratis" - }; - randomSeed=1617621; - class Intel - { - timeOfChanges=1800.0002; - startWeather=0.30000001; - startWind=0.1; - startWaves=0.1; - forecastWeather=0.30000001; - forecastWind=0.1; - forecastWaves=0.1; - forecastLightnings=0.1; - year=2035; - month=7; - day=6; - hour=12; - minute=0; - startFogDecay=0.013; - forecastFogDecay=0.013; - }; -}; diff --git a/addons/testmissions/README.md b/addons/testmissions/README.md deleted file mode 100644 index e8737f0ab6..0000000000 --- a/addons/testmissions/README.md +++ /dev/null @@ -1,11 +0,0 @@ -ace_testmissions -=========== - -Provides test missions. - - -## Maintainers - -The people responsible for merging changes to this component or answering potential questions. - -- None diff --git a/addons/testmissions/config.cpp b/addons/testmissions/config.cpp deleted file mode 100644 index 3a73a661d5..0000000000 --- a/addons/testmissions/config.cpp +++ /dev/null @@ -1,20 +0,0 @@ -#include "script_component.hpp" - -class CfgPatches { - class ADDON { - units[] = {}; - weapons[] = {}; - requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"ace_common"}; - VERSION_CONFIG; - }; -}; - -class CfgMissions { - class MPMissions { - class ACETestingMap1 { - briefingName = "ACE Testing Map 1"; - directory = QUOTE(PATHTO_R(MPMissions\ACETestingMap1.Stratis)); - }; - }; -}; diff --git a/addons/testmissions/script_component.hpp b/addons/testmissions/script_component.hpp deleted file mode 100644 index 718356494d..0000000000 --- a/addons/testmissions/script_component.hpp +++ /dev/null @@ -1,17 +0,0 @@ -#define COMPONENT testmissions -#include "\z\ace\addons\main\script_mod.hpp" - -// #define DEBUG_MODE_FULL -// #define DISABLE_COMPILE_CACHE -// #define CBA_DEBUG_SYNCHRONOUS -// #define ENABLE_PERFORMANCE_COUNTERS - -#ifdef DEBUG_ENABLED_TESTMISSIONS - #define DEBUG_MODE_FULL -#endif - -#ifdef DEBUG_ENABLED_TESTMISSIONS - #define DEBUG_SETTINGS DEBUG_ENABLED_TESTMISSIONS -#endif - -#include "\z\ace\addons\main\script_macros.hpp" \ No newline at end of file From eb8390741b744d75c0ad0273eda61fd75b364b0b Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 14 May 2016 09:23:29 +0200 Subject: [PATCH 196/215] Change round down mass of body bag Mass is an integer. --- addons/medical/CfgWeapons.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/CfgWeapons.hpp b/addons/medical/CfgWeapons.hpp index 235e3c154b..1c752c2aea 100644 --- a/addons/medical/CfgWeapons.hpp +++ b/addons/medical/CfgWeapons.hpp @@ -236,7 +236,7 @@ class CfgWeapons { descriptionShort = CSTRING(Bodybag_Desc_Short); descriptionUse = CSTRING(Bodybag_Desc_Use); class ItemInfo: InventoryItem_Base_F { - mass = 7.4; + mass = 7; }; }; }; From 04b61ff32ea6ef0a1c96c3ce975689ea6e31f102 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 14 May 2016 10:37:29 +0200 Subject: [PATCH 197/215] Fix missing semicolon --- addons/medical/functions/fnc_reviveStateLoop.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_reviveStateLoop.sqf b/addons/medical/functions/fnc_reviveStateLoop.sqf index 3e55f7b7ce..77a48c9340 100644 --- a/addons/medical/functions/fnc_reviveStateLoop.sqf +++ b/addons/medical/functions/fnc_reviveStateLoop.sqf @@ -13,7 +13,7 @@ #include "script_component.hpp" -params ["_unit"] +params ["_unit"]; // If locality changed finish the local loop // @todo: reinitiate the loop elsewhere From c5275813a450670372e082e6db2853fdf8b7fd98 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 14 May 2016 10:49:09 +0200 Subject: [PATCH 198/215] use 'getUnitLoadout' instead of 'FUNC(getAllGear)' and deprecate it --- addons/common/XEH_postInit.sqf | 4 +- .../common/functions/fnc_assignedItemFix.sqf | 38 +++----------- addons/common/functions/fnc_getAllGear.sqf | 2 + addons/common/functions/fnc_setAllGear.sqf | 2 + addons/goggles/XEH_postInit.sqf | 4 +- addons/medical/XEH_postInit.sqf | 4 +- addons/nightvision/XEH_postInitClient.sqf | 2 +- addons/parachute/XEH_postInit.sqf | 3 +- addons/respawn/functions/fnc_handleKilled.sqf | 10 ++-- .../respawn/functions/fnc_handleRespawn.sqf | 6 ++- addons/respawn/functions/fnc_restoreGear.sqf | 49 ++++++++++--------- addons/scopes/XEH_postInit.sqf | 5 +- 12 files changed, 55 insertions(+), 74 deletions(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index a6b952062e..2b5637a78f 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -333,7 +333,7 @@ enableCamShake true; GVAR(OldPlayerVehicle) = vehicle objNull; GVAR(OldPlayerTurret) = [objNull] call FUNC(getTurretIndex); GVAR(OldPlayerWeapon) = currentWeapon objNull; -GVAR(OldPlayerInventory) = [objNull] call FUNC(getAllGear); +GVAR(OldPlayerInventory) = []; GVAR(OldPlayerVisionMode) = currentVisionMode objNull; GVAR(OldCameraView) = ""; GVAR(OldVisibleMap) = false; @@ -381,7 +381,7 @@ GVAR(OldIsCamera) = false; }; // "playerInventoryChanged" event - _data = [ACE_player] call FUNC(getAllGear); + _data = getUnitLoadout ACE_player; if !(_data isEqualTo GVAR(OldPlayerInventory)) then { // Raise ACE event locally GVAR(OldPlayerInventory) = _data; diff --git a/addons/common/functions/fnc_assignedItemFix.sqf b/addons/common/functions/fnc_assignedItemFix.sqf index d93409ce7c..3f454f83ff 100644 --- a/addons/common/functions/fnc_assignedItemFix.sqf +++ b/addons/common/functions/fnc_assignedItemFix.sqf @@ -31,37 +31,15 @@ GVAR(AssignedItemsShownItems) = [ ["playerInventoryChanged", { params ["_unit", "_assignedItems"]; - _assignedItems = _assignedItems select 17; + _assignedItems = _assignedItems param [9, ["","","","","",""]]; // ["ItemMap","ItemGPS","ItemRadio","ItemCompass","ItemWatch","NVGoggles"] - GVAR(AssignedItemsShownItems) = [true, true, true, true, true]; - - { - if !(_x in GVAR(AssignedItems)) then { - GVAR(AssignedItems) pushBack _x; - GVAR(AssignedItemsInfo) pushBack toLower getText (configFile >> "CfgWeapons" >> _x >> "ACE_hideItemType"); - }; - - switch (GVAR(AssignedItemsInfo) select (GVAR(AssignedItems) find _x)) do { - case ("map"): { - GVAR(AssignedItemsShownItems) set [0, false]; - }; - case ("compass"): { - GVAR(AssignedItemsShownItems) set [1, false]; - }; - case ("watch"): { - GVAR(AssignedItemsShownItems) set [2, false]; - }; - case ("radio"): { - GVAR(AssignedItemsShownItems) set [3, false]; - }; - case ("gps"): { - GVAR(AssignedItemsShownItems) set [4, false]; - }; - }; - false - } count _assignedItems; - - //systemChat str GVAR(AssignedItemsShownItems); + GVAR(AssignedItemsShownItems) = [ + !((_assignedItems select 0) isEqualTo "") && {getText (configFile >> "CfgWeapons" >> _assignedItems select 0 >> "ACE_hideItemType") != "map"}, + !((_assignedItems select 3) isEqualTo "") && {getText (configFile >> "CfgWeapons" >> _assignedItems select 3 >> "ACE_hideItemType") != "compass"}, + !((_assignedItems select 4) isEqualTo "") && {getText (configFile >> "CfgWeapons" >> _assignedItems select 4 >> "ACE_hideItemType") != "watch"}, + !((_assignedItems select 2) isEqualTo "") && {getText (configFile >> "CfgWeapons" >> _assignedItems select 2 >> "ACE_hideItemType") != "radio"}, + !((_assignedItems select 1) isEqualTo "") && {getText (configFile >> "CfgWeapons" >> _assignedItems select 1 >> "ACE_hideItemType") != "gps"} + ]; GVAR(AssignedItemsShownItems) params ["_showMap", "_showCompass", "_showWatch", "_showRadio", "_showGPS"]; diff --git a/addons/common/functions/fnc_getAllGear.sqf b/addons/common/functions/fnc_getAllGear.sqf index 715966b176..716793f7bd 100644 --- a/addons/common/functions/fnc_getAllGear.sqf +++ b/addons/common/functions/fnc_getAllGear.sqf @@ -33,6 +33,8 @@ */ #include "script_component.hpp" +ACE_DEPRECATED("ace_common_fnc_getAllGear","3.7.0","getUnitLoadout"); + params ["_unit"]; if (isNull _unit) exitWith {[ diff --git a/addons/common/functions/fnc_setAllGear.sqf b/addons/common/functions/fnc_setAllGear.sqf index 152eb4fd60..6334991796 100644 --- a/addons/common/functions/fnc_setAllGear.sqf +++ b/addons/common/functions/fnc_setAllGear.sqf @@ -18,6 +18,8 @@ */ #include "script_component.hpp" +ACE_DEPRECATED("ace_common_fnc_setAllGear","3.7.0","setUnitLoadout"); + params ["_unit", "_allGear", ["_clearAttachments", false], ["_clearBackpack", false]]; if (!local _unit) exitWith { diff --git a/addons/goggles/XEH_postInit.sqf b/addons/goggles/XEH_postInit.sqf index 832c961178..3a038ed923 100644 --- a/addons/goggles/XEH_postInit.sqf +++ b/addons/goggles/XEH_postInit.sqf @@ -42,10 +42,10 @@ GVAR(surfaceCache) = ""; GVAR(surfaceCacheIsDust) = false; // init GlassesChanged eventhandler -GVAR(OldGlasses) = "#NULLSTRING"; +GVAR(OldGlasses) = ""; ["playerInventoryChanged", { - (_this select 1) params ["", "_currentGlasses"]; + private _currentGlasses = (_this select 1) param [7, ""]; if (GVAR(OldGlasses) != _currentGlasses) then { ["GlassesChanged", [ACE_player, _currentGlasses]] call EFUNC(common,localEvent); diff --git a/addons/medical/XEH_postInit.sqf b/addons/medical/XEH_postInit.sqf index 5d29d22cec..8d8911a6bf 100644 --- a/addons/medical/XEH_postInit.sqf +++ b/addons/medical/XEH_postInit.sqf @@ -298,9 +298,7 @@ GVAR(lastHeartBeatSound) = ACE_time; ["isNotUnconscious", {!((_this select 0) getVariable ["ACE_isUnconscious", false])}] call EFUNC(common,addCanInteractWithCondition); // Item Event Handler -["playerInventoryChanged", { - [ACE_player] call FUNC(itemCheck); -}] call EFUNC(common,addEventHandler); +["playerInventoryChanged", FUNC(itemCheck)] call EFUNC(common,addEventHandler); if (hasInterface) then { ["PlayerJip", { diff --git a/addons/nightvision/XEH_postInitClient.sqf b/addons/nightvision/XEH_postInitClient.sqf index 5a6714a374..96badd59af 100644 --- a/addons/nightvision/XEH_postInitClient.sqf +++ b/addons/nightvision/XEH_postInitClient.sqf @@ -29,7 +29,7 @@ GVAR(ppEffectMuzzleFlash) ppEffectAdjust [1, 1, 0, [0, 0, 0, 0], [0, 0, 0, 1], [ GVAR(ppEffectMuzzleFlash) ppEffectCommit 0; // Setup the event handlers -["playerInventoryChanged", {_this call FUNC(updatePPEffects)}] call EFUNC(common,addEventHandler); +["playerInventoryChanged", FUNC(updatePPEffects)] call EFUNC(common,addEventHandler); ["playerVisionModeChanged", { _this call FUNC(updatePPEffects); _this call FUNC(onVisionModeChanged); diff --git a/addons/parachute/XEH_postInit.sqf b/addons/parachute/XEH_postInit.sqf index 598661a3da..ad4044e6e5 100644 --- a/addons/parachute/XEH_postInit.sqf +++ b/addons/parachute/XEH_postInit.sqf @@ -43,5 +43,4 @@ GVAR(PFH) = false; // don't show speed and height when in expert mode ["infoDisplayChanged", {_this call FUNC(handleInfoDisplayChanged)}] call EFUNC(common,addEventHandler); -//[ACE_Player,([ACE_player] call EFUNC(common,getAllGear))] call FUNC(storeParachute); -["playerInventoryChanged", FUNC(storeParachute) ] call EFUNC(common,addEventHandler); +["playerInventoryChanged", FUNC(storeParachute)] call EFUNC(common,addEventHandler); diff --git a/addons/respawn/functions/fnc_handleKilled.sqf b/addons/respawn/functions/fnc_handleKilled.sqf index cd1ad33491..2b9509f39d 100644 --- a/addons/respawn/functions/fnc_handleKilled.sqf +++ b/addons/respawn/functions/fnc_handleKilled.sqf @@ -19,13 +19,9 @@ params ["_unit"]; // Saves the gear when the player! (and only him) is killed -if (ACE_player == _unit) then { - GVAR(unitGear) = []; - - if (GVAR(SavePreDeathGear)) then { - GVAR(unitGear) = [_unit] call EFUNC(common,getAllGear); - GVAR(unitGear) append [currentWeapon _unit, currentMuzzle _unit, currentWeaponMode _unit]; - }; +if (ACE_player == _unit && {GVAR(SavePreDeathGear)}) then { + _unit setVariable [QGVAR(unitGear), getUnitLoadout _unit]; + _unit setVariable [QGVAR(activeWeaponAndMuzzle), [currentWeapon _unit, currentMuzzle _unit, currentWeaponMode _unit]]; }; if (missionNamespace getVariable [QGVAR(showFriendlyFireMessage), false]) then { diff --git a/addons/respawn/functions/fnc_handleRespawn.sqf b/addons/respawn/functions/fnc_handleRespawn.sqf index ab5ecedbda..3b1ae1c86f 100644 --- a/addons/respawn/functions/fnc_handleRespawn.sqf +++ b/addons/respawn/functions/fnc_handleRespawn.sqf @@ -20,7 +20,11 @@ params ["_unit"]; // Restores the gear when the player respawns if (GVAR(SavePreDeathGear)) then { - [_unit, GVAR(unitGear)] call FUNC(restoreGear); + [ + _unit, + _unit getVariable QGVAR(unitGear), + _unit getVariable QGVAR(activeWeaponAndMuzzle) + ] call FUNC(restoreGear); }; // fix for setVariable public being lost on respawn for machines that JIP after the command was broadcasted diff --git a/addons/respawn/functions/fnc_restoreGear.sqf b/addons/respawn/functions/fnc_restoreGear.sqf index af3acb7fb4..a035bdd52d 100644 --- a/addons/respawn/functions/fnc_restoreGear.sqf +++ b/addons/respawn/functions/fnc_restoreGear.sqf @@ -19,30 +19,35 @@ params ["_unit", "_allGear", "_activeWeaponAndMuzzle"]; // restore all gear -[_unit, _allGear, true, true] call EFUNC(common,setAllGear); +if (!isNil "_allGear") then { + _unit setUnitLoadout _allGear; +}; // restore the last active weapon, muzzle and weaponMode -_activeWeaponAndMuzzle params ["_activeWeapon", "_activeMuzzle", "_activeWeaponMode"]; +if (!isNil "_activeWeaponAndMuzzle") then { + // @todo, replace this with CBA_fnc_selectWeapon after next CBA update + _activeWeaponAndMuzzle params ["_activeWeapon", "_activeMuzzle", "_activeWeaponMode"]; -if ( - (_activeMuzzle != "") && - {_activeMuzzle != _activeWeapon} && - {_activeMuzzle in getArray (configFile >> "CfgWeapons" >> _activeWeapon >> "muzzles")} -) then { - _unit selectWeapon _activeMuzzle; -} else { - if (_activeWeapon != "") then { - _unit selectWeapon _activeWeapon; - }; -}; - -if (currentWeapon _unit != "") then { - private _index = 0; - - while { - _index < 100 && {currentWeaponMode _unit != _activeWeaponMode} - } do { - _unit action ["SwitchWeapon", _unit, _unit, _index]; - _index = _index + 1; + if ( + (_activeMuzzle != "") && + {_activeMuzzle != _activeWeapon} && + {_activeMuzzle in getArray (configFile >> "CfgWeapons" >> _activeWeapon >> "muzzles")} + ) then { + _unit selectWeapon _activeMuzzle; + } else { + if (_activeWeapon != "") then { + _unit selectWeapon _activeWeapon; + }; + }; + + if (currentWeapon _unit != "") then { + private _index = 0; + + while { + _index < 100 && {currentWeaponMode _unit != _activeWeaponMode} + } do { + _unit action ["SwitchWeapon", _unit, _unit, _index]; + _index = _index + 1; + }; }; }; diff --git a/addons/scopes/XEH_postInit.sqf b/addons/scopes/XEH_postInit.sqf index 8f2adeb0b7..625f963f33 100644 --- a/addons/scopes/XEH_postInit.sqf +++ b/addons/scopes/XEH_postInit.sqf @@ -10,10 +10,7 @@ if (!hasInterface) exitWith {}; // Check inventory when it changes -["playerInventoryChanged", { - [ACE_player] call FUNC(inventoryCheck); -}] call EFUNC(common,addEventhandler); - +["playerInventoryChanged", FUNC(inventoryCheck)] call EFUNC(common,addEventhandler); // Instantly hide knobs when scoping in ["cameraViewChanged", { From e4c86a8af5738035d0985e6a8df08ea33cf93e07 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 14 May 2016 19:50:08 +0200 Subject: [PATCH 199/215] don't do 'playerInventoryChanged' just because ammo decreased after firing --- addons/common/XEH_postInit.sqf | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 2b5637a78f..0eac9a3e63 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -334,6 +334,7 @@ GVAR(OldPlayerVehicle) = vehicle objNull; GVAR(OldPlayerTurret) = [objNull] call FUNC(getTurretIndex); GVAR(OldPlayerWeapon) = currentWeapon objNull; GVAR(OldPlayerInventory) = []; +GVAR(OldPlayerInventoryNoAmmo) = []; GVAR(OldPlayerVisionMode) = currentVisionMode objNull; GVAR(OldCameraView) = ""; GVAR(OldVisibleMap) = false; @@ -385,7 +386,19 @@ GVAR(OldIsCamera) = false; if !(_data isEqualTo GVAR(OldPlayerInventory)) then { // Raise ACE event locally GVAR(OldPlayerInventory) = _data; - ["playerInventoryChanged", [ACE_player, _data]] call FUNC(localEvent); + + // we don't want to trigger this just because your ammo counter decreased. + _data = + GVAR(OldPlayerInventory); + (_data param [0, []]) set [4, primaryWeaponMagazine ACE_player]; + (_data param [0, []]) set [5, nil]; + (_data param [1, []]) set [4, secondaryWeaponMagazine ACE_player]; + (_data param [1, []]) set [5, nil]; + (_data param [2, []]) set [4, handgunMagazine ACE_player]; + (_data param [2, []]) set [5, nil]; + if !(_data isEqualTo GVAR(OldPlayerInventoryNoAmmo)) then { + GVAR(OldPlayerInventoryNoAmmo) = _data; + ["playerInventoryChanged", [ACE_player, GVAR(OldPlayerInventory)]] call FUNC(localEvent); + }; }; // "playerVisionModeChanged" event From 7628f9a4ab879a8f7e9b89fb6f585cd39417245f Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 14 May 2016 13:08:58 -0500 Subject: [PATCH 200/215] Fix nils in array --- addons/common/XEH_postInit.sqf | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 0eac9a3e63..14e09e2c5b 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -389,12 +389,18 @@ GVAR(OldIsCamera) = false; // we don't want to trigger this just because your ammo counter decreased. _data = + GVAR(OldPlayerInventory); - (_data param [0, []]) set [4, primaryWeaponMagazine ACE_player]; - (_data param [0, []]) set [5, nil]; - (_data param [1, []]) set [4, secondaryWeaponMagazine ACE_player]; - (_data param [1, []]) set [5, nil]; - (_data param [2, []]) set [4, handgunMagazine ACE_player]; - (_data param [2, []]) set [5, nil]; + if (!((_data select 0) isEqualTo [])) then { + (_data param [0, []]) set [4, primaryWeaponMagazine ACE_player]; + (_data param [0, []]) set [5, []]; + }; + if (!((_data select 1) isEqualTo [])) then { + (_data param [1, []]) set [4, secondaryWeaponMagazine ACE_player]; + (_data param [1, []]) set [5, []]; + }; + if (!((_data select 2) isEqualTo [])) then { + (_data param [2, []]) set [4, handgunMagazine ACE_player]; + (_data param [2, []]) set [5, []]; + }; if !(_data isEqualTo GVAR(OldPlayerInventoryNoAmmo)) then { GVAR(OldPlayerInventoryNoAmmo) = _data; ["playerInventoryChanged", [ACE_player, GVAR(OldPlayerInventory)]] call FUNC(localEvent); From 07caf1b0bdf56aeebb5940b887ef2c91789d881e Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 14 May 2016 20:33:33 +0200 Subject: [PATCH 201/215] fix for null player --- addons/common/XEH_postInit.sqf | 25 ++++++++++++------- .../medical/functions/fnc_reviveStateLoop.sqf | 2 +- 2 files changed, 17 insertions(+), 10 deletions(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 14e09e2c5b..e75841cb8e 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -389,18 +389,25 @@ GVAR(OldIsCamera) = false; // we don't want to trigger this just because your ammo counter decreased. _data = + GVAR(OldPlayerInventory); - if (!((_data select 0) isEqualTo [])) then { - (_data param [0, []]) set [4, primaryWeaponMagazine ACE_player]; - (_data param [0, []]) set [5, []]; + + private _weaponInfo = _data param [0, []]; + if !(_weaponInfo isEqualTo []) then { + _weaponInfo set [4, primaryWeaponMagazine ACE_player]; + _weaponInfo deleteAt 5; }; - if (!((_data select 1) isEqualTo [])) then { - (_data param [1, []]) set [4, secondaryWeaponMagazine ACE_player]; - (_data param [1, []]) set [5, []]; + + _weaponInfo = _data param [1, []]; + if !(_weaponInfo isEqualTo []) then { + _weaponInfo set [4, secondaryWeaponMagazine ACE_player]; + _weaponInfo deleteAt 5; }; - if (!((_data select 2) isEqualTo [])) then { - (_data param [2, []]) set [4, handgunMagazine ACE_player]; - (_data param [2, []]) set [5, []]; + + _weaponInfo = _data param [2, []]; + if !(_weaponInfo isEqualTo []) then { + _weaponInfo set [4, handgunMagazine ACE_player]; + _weaponInfo deleteAt 5; }; + if !(_data isEqualTo GVAR(OldPlayerInventoryNoAmmo)) then { GVAR(OldPlayerInventoryNoAmmo) = _data; ["playerInventoryChanged", [ACE_player, GVAR(OldPlayerInventory)]] call FUNC(localEvent); diff --git a/addons/medical/functions/fnc_reviveStateLoop.sqf b/addons/medical/functions/fnc_reviveStateLoop.sqf index 3e55f7b7ce..77a48c9340 100644 --- a/addons/medical/functions/fnc_reviveStateLoop.sqf +++ b/addons/medical/functions/fnc_reviveStateLoop.sqf @@ -13,7 +13,7 @@ #include "script_component.hpp" -params ["_unit"] +params ["_unit"]; // If locality changed finish the local loop // @todo: reinitiate the loop elsewhere From 32055401d3be3b0d38bb173d58d773559c5b437a Mon Sep 17 00:00:00 2001 From: Glowbal Date: Mon, 16 May 2016 00:09:53 +0200 Subject: [PATCH 202/215] Add backwards compatability for InventoryChanged The output of `getUnitLoadout` is different as `getAllGear`. Using a different format in the event would mean that any eventhandler depending on the inventory output would now be broken. --- addons/common/XEH_postInit.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 2b5637a78f..82cf0da2ea 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -385,7 +385,7 @@ GVAR(OldIsCamera) = false; if !(_data isEqualTo GVAR(OldPlayerInventory)) then { // Raise ACE event locally GVAR(OldPlayerInventory) = _data; - ["playerInventoryChanged", [ACE_player, _data]] call FUNC(localEvent); + ["playerInventoryChanged", [ACE_player, [ACE_player, false] call FUNC(getAllGear) ]] call FUNC(localEvent); }; // "playerVisionModeChanged" event From cac7b9c0c36e7ad18c2a8e52e5e93f4a6d92dd19 Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 16 May 2016 15:15:51 +0200 Subject: [PATCH 203/215] optional param to skip deprecated warning --- addons/common/functions/fnc_getAllGear.sqf | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/addons/common/functions/fnc_getAllGear.sqf b/addons/common/functions/fnc_getAllGear.sqf index 716793f7bd..cebcc489f1 100644 --- a/addons/common/functions/fnc_getAllGear.sqf +++ b/addons/common/functions/fnc_getAllGear.sqf @@ -33,9 +33,11 @@ */ #include "script_component.hpp" -ACE_DEPRECATED("ace_common_fnc_getAllGear","3.7.0","getUnitLoadout"); +params ["_unit", ["_showDeprecated", true]]; -params ["_unit"]; +if (_showDeprecated) then { + ACE_DEPRECATED("ace_common_fnc_getAllGear","3.7.0","getUnitLoadout"); +}; if (isNull _unit) exitWith {[ "", From 473149b8ca2da3a7cea3029316b44f413a04bf04 Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 16 May 2016 15:22:37 +0200 Subject: [PATCH 204/215] revert changes from other PR to make it compatible --- addons/common/functions/fnc_assignedItemFix.sqf | 4 ++-- addons/goggles/XEH_postInit.sqf | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/addons/common/functions/fnc_assignedItemFix.sqf b/addons/common/functions/fnc_assignedItemFix.sqf index 3f454f83ff..18dd6b4e0c 100644 --- a/addons/common/functions/fnc_assignedItemFix.sqf +++ b/addons/common/functions/fnc_assignedItemFix.sqf @@ -29,9 +29,9 @@ GVAR(AssignedItemsShownItems) = [ ]; ["playerInventoryChanged", { - params ["_unit", "_assignedItems"]; + params ["_unit"]; - _assignedItems = _assignedItems param [9, ["","","","","",""]]; // ["ItemMap","ItemGPS","ItemRadio","ItemCompass","ItemWatch","NVGoggles"] + private _assignedItems = getUnitLoadout _unit param [9, ["","","","","",""]]; // ["ItemMap","ItemGPS","ItemRadio","ItemCompass","ItemWatch","NVGoggles"] GVAR(AssignedItemsShownItems) = [ !((_assignedItems select 0) isEqualTo "") && {getText (configFile >> "CfgWeapons" >> _assignedItems select 0 >> "ACE_hideItemType") != "map"}, diff --git a/addons/goggles/XEH_postInit.sqf b/addons/goggles/XEH_postInit.sqf index 3a038ed923..37edd7184b 100644 --- a/addons/goggles/XEH_postInit.sqf +++ b/addons/goggles/XEH_postInit.sqf @@ -45,10 +45,12 @@ GVAR(surfaceCacheIsDust) = false; GVAR(OldGlasses) = ""; ["playerInventoryChanged", { - private _currentGlasses = (_this select 1) param [7, ""]; + params ["_unit"]; + + private _currentGlasses = goggles _unit; if (GVAR(OldGlasses) != _currentGlasses) then { - ["GlassesChanged", [ACE_player, _currentGlasses]] call EFUNC(common,localEvent); + ["GlassesChanged", [_unit, _currentGlasses]] call EFUNC(common,localEvent); GVAR(OldGlasses) = _currentGlasses; }; }] call EFUNC(common,addEventHandler); From 25876d82caeef935058b0335e4fc701ef989ad58 Mon Sep 17 00:00:00 2001 From: commy2 Date: Wed, 18 May 2016 12:21:53 +0200 Subject: [PATCH 205/215] manual merge --- addons/common/XEH_postInit.sqf | 1 - 1 file changed, 1 deletion(-) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 8922da7c6f..88012a7884 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -386,7 +386,6 @@ GVAR(OldIsCamera) = false; if !(_data isEqualTo GVAR(OldPlayerInventory)) then { // Raise ACE event locally GVAR(OldPlayerInventory) = _data; -<<<<<<< HEAD // we don't want to trigger this just because your ammo counter decreased. _data = + GVAR(OldPlayerInventory); From 709916c0f3dfec70c6b4131b2f01972be612b1f0 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 19 May 2016 19:53:23 -0500 Subject: [PATCH 206/215] Fix UBC errors for RHS 4.1 (#3800) --- optionals/compat_rhs_afrf3/CfgAmmo.hpp | 2 +- optionals/compat_rhs_afrf3/CfgVehicles.hpp | 4 ++-- optionals/compat_rhs_usf3/CfgAmmo.hpp | 3 ++- optionals/compat_rhs_usf3/CfgWeapons.hpp | 4 ++-- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/optionals/compat_rhs_afrf3/CfgAmmo.hpp b/optionals/compat_rhs_afrf3/CfgAmmo.hpp index 3a00fdea68..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; diff --git a/optionals/compat_rhs_afrf3/CfgVehicles.hpp b/optionals/compat_rhs_afrf3/CfgVehicles.hpp index 87d8673cd8..34effc0a58 100644 --- a/optionals/compat_rhs_afrf3/CfgVehicles.hpp +++ b/optionals/compat_rhs_afrf3/CfgVehicles.hpp @@ -243,8 +243,8 @@ class CfgVehicles { EGVAR(fastroping,onPrepare) = QFUNC(onPrepare); class UserActions { - class openDoor; - class closeDoor_L: openDoor { + 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)])}); }; }; 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/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; From 508b71e7bab96342ba2d1f2be7484959450cdc49 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 19 May 2016 21:39:15 -0500 Subject: [PATCH 207/215] Scopes - Allow Scope Adjust from FFV --- addons/fcs/functions/fnc_adjustRange.sqf | 1 + .../fcs/functions/fnc_calculateSolution.sqf | 1 + addons/fcs/functions/fnc_canUseFCS.sqf | 11 ++++++- addons/fcs/functions/fnc_keyUp.sqf | 1 + addons/scopes/XEH_PREP.hpp | 1 + addons/scopes/XEH_postInit.sqf | 32 ++++++++++++++----- addons/scopes/XEH_preInit.sqf | 2 -- .../scopes/functions/fnc_canAdjustScope.sqf | 26 +++++++++++++++ addons/scopes/functions/fnc_firedEH.sqf | 1 + 9 files changed, 65 insertions(+), 11 deletions(-) create mode 100644 addons/scopes/functions/fnc_canAdjustScope.sqf diff --git a/addons/fcs/functions/fnc_adjustRange.sqf b/addons/fcs/functions/fnc_adjustRange.sqf index f6f543d35a..bed9389716 100644 --- a/addons/fcs/functions/fnc_adjustRange.sqf +++ b/addons/fcs/functions/fnc_adjustRange.sqf @@ -22,6 +22,7 @@ private _min = getNumber (_turretConfig >> QGVAR(MinDistance)); private _max = getNumber (_turretConfig >> QGVAR(MaxDistance)); private _distance = _vehicle getVariable [format ["%1_%2", QGVAR(Distance), _turret], _min]; +TRACE_4("",_distance,_delta,_min,_max); _distance = _distance + _delta; _distance = _distance min _max; diff --git a/addons/fcs/functions/fnc_calculateSolution.sqf b/addons/fcs/functions/fnc_calculateSolution.sqf index 9908832824..6d489de006 100644 --- a/addons/fcs/functions/fnc_calculateSolution.sqf +++ b/addons/fcs/functions/fnc_calculateSolution.sqf @@ -15,6 +15,7 @@ */ #include "script_component.hpp" params ["_vehicle","_turret","_distance","_angleTarget"]; +TRACE_4("params",_vehicle,_turret,_distance,_angleTarget); private _FCSMagazines = []; private _FCSElevation = []; diff --git a/addons/fcs/functions/fnc_canUseFCS.sqf b/addons/fcs/functions/fnc_canUseFCS.sqf index 91b49554c2..1dcd1ca49e 100644 --- a/addons/fcs/functions/fnc_canUseFCS.sqf +++ b/addons/fcs/functions/fnc_canUseFCS.sqf @@ -8,9 +8,18 @@ * Return Value: * Boolean * + * Example: + * [] call ace_fcs_fnc_canUseFCS + * * Public: No */ #include "script_component.hpp" getNumber ([configFile >> "CfgVehicles" >> typeOf vehicle ACE_player, [ACE_player] call EFUNC(common,getTurretIndex)] call EFUNC(common,getTurretConfigPath) >> QGVAR(Enabled)) == 1 -&& {cameraView == "GUNNER"} // return +&& {cameraView == "GUNNER"} +&& { + private _animationState = animationState ACE_player; + private _moves = configFile >> getText (configFile >> "CfgVehicles" >> (typeof ACE_player) >> "moves"); + + (getNumber (_moves >> "States" >> _animationState >> "canPullTrigger") == 0) +} diff --git a/addons/fcs/functions/fnc_keyUp.sqf b/addons/fcs/functions/fnc_keyUp.sqf index 919ac3a58e..4fbd247d16 100644 --- a/addons/fcs/functions/fnc_keyUp.sqf +++ b/addons/fcs/functions/fnc_keyUp.sqf @@ -14,6 +14,7 @@ #include "script_component.hpp" params ["_vehicle", "_turret", "_distance", ["_showHint", false], ["_playSound", true]]; +TRACE_5("params",_vehicle,_turret,_distance,_showHint,_playSound); private _turretConfig = [configFile >> "CfgVehicles" >> typeOf _vehicle, _turret] call EFUNC(common,getTurretConfigPath); diff --git a/addons/scopes/XEH_PREP.hpp b/addons/scopes/XEH_PREP.hpp index 908d8064f0..05f58a5922 100644 --- a/addons/scopes/XEH_PREP.hpp +++ b/addons/scopes/XEH_PREP.hpp @@ -2,6 +2,7 @@ PREP(adjustScope); PREP(adjustZero); PREP(applyScopeAdjustment); +PREP(canAdjustScope); PREP(canAdjustZero); PREP(firedEH); PREP(getOptics); diff --git a/addons/scopes/XEH_postInit.sqf b/addons/scopes/XEH_postInit.sqf index 625f963f33..cc1d9e9c5c 100644 --- a/addons/scopes/XEH_postInit.sqf +++ b/addons/scopes/XEH_postInit.sqf @@ -33,8 +33,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustUpMinor), localize LSTRING(AdjustUpMinor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement @@ -46,8 +48,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustDownMinor), localize LSTRING(AdjustDownMinor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement @@ -59,8 +63,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustLeftMinor), localize LSTRING(AdjustLeftMinor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement @@ -72,8 +78,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustRightMinor), localize LSTRING(AdjustRightMinor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement @@ -85,8 +93,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustUpMajor), localize LSTRING(AdjustUpMajor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement @@ -98,8 +108,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustDownMajor), localize LSTRING(AdjustDownMajor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement @@ -111,8 +123,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustLeftMajor), localize LSTRING(AdjustLeftMajor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement @@ -124,8 +138,10 @@ if (!hasInterface) exitWith {}; ["ACE3 Scope Adjustment", QGVAR(AdjustRightMajor), localize LSTRING(AdjustRightMajor), { // Conditions: canInteract - if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false}; + if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific + if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + [ACE_player] call FUNC(inventoryCheck); // Statement diff --git a/addons/scopes/XEH_preInit.sqf b/addons/scopes/XEH_preInit.sqf index e33c54337d..a7feade1c3 100644 --- a/addons/scopes/XEH_preInit.sqf +++ b/addons/scopes/XEH_preInit.sqf @@ -4,6 +4,4 @@ ADDON = false; #include "XEH_PREP.hpp" -GVAR(fadeScript) = scriptNull; - ADDON = true; diff --git a/addons/scopes/functions/fnc_canAdjustScope.sqf b/addons/scopes/functions/fnc_canAdjustScope.sqf new file mode 100644 index 0000000000..b5cc729cbb --- /dev/null +++ b/addons/scopes/functions/fnc_canAdjustScope.sqf @@ -0,0 +1,26 @@ +/* + * Author: PabstMirror + * Tests if player would be in a position to adjust scope + * Mainly for determining edge cases with turned-out / FFV. + * + * Argument: + * 0: Unit + * + * Return value: + * + * + * Example: + * [player] call ace_scopes_fnc_canAdjustScope + * + * Public: No + */ +#include "script_component.hpp" + +params ["_unit"]; + +if ((vehicle _unit) == _unit) exitWith {true}; + +private _animationState = animationState _unit; +private _moves = configFile >> getText (configFile >> "CfgVehicles" >> (typeof _unit) >> "moves"); + +(getNumber (_moves >> "States" >> _animationState >> "canPullTrigger") == 1) diff --git a/addons/scopes/functions/fnc_firedEH.sqf b/addons/scopes/functions/fnc_firedEH.sqf index d28c0dee7e..07eadb5620 100644 --- a/addons/scopes/functions/fnc_firedEH.sqf +++ b/addons/scopes/functions/fnc_firedEH.sqf @@ -24,6 +24,7 @@ _weaponIndex = [_unit, currentWeapon _unit] call EFUNC(common,getWeaponIndex); if (_weaponIndex < 0) exitWith {}; _zeroing = _adjustment select _weaponIndex; +TRACE_1("Adjusting With",_zeroing); if (_zeroing isEqualTo [0, 0, 0]) exitWith {}; From 0d5385ffaf99e05e1f8b1a973174b39541648fe2 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 19 May 2016 21:50:51 -0500 Subject: [PATCH 208/215] Update FCS hud when manually setting range. --- addons/fcs/functions/fnc_keyUp.sqf | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/fcs/functions/fnc_keyUp.sqf b/addons/fcs/functions/fnc_keyUp.sqf index 4fbd247d16..113d369a3c 100644 --- a/addons/fcs/functions/fnc_keyUp.sqf +++ b/addons/fcs/functions/fnc_keyUp.sqf @@ -24,6 +24,8 @@ if (isNil "_distance") then { getNumber (_turretConfig >> QGVAR(MaxDistance)), getNumber (_turretConfig >> QGVAR(MinDistance)) ] call FUNC(getRange); +} else { + ((uiNamespace getVariable ["ACE_dlgRangefinder", displayNull]) displayCtrl 1713151) ctrlSetText ([_distance, 4, 0] call CBA_fnc_formatNumber); }; // MOVING TARGETS From d464a23d21ae7d45834fc3aa5f06b1e2828eb1a9 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 20 May 2016 01:10:12 -0500 Subject: [PATCH 209/215] Use the lovely CBA_fnc_canUseWeapon function --- addons/fcs/functions/fnc_canUseFCS.sqf | 7 +---- addons/scopes/XEH_PREP.hpp | 1 - addons/scopes/XEH_postInit.sqf | 16 ++++++------ .../scopes/functions/fnc_canAdjustScope.sqf | 26 ------------------- 4 files changed, 9 insertions(+), 41 deletions(-) delete mode 100644 addons/scopes/functions/fnc_canAdjustScope.sqf diff --git a/addons/fcs/functions/fnc_canUseFCS.sqf b/addons/fcs/functions/fnc_canUseFCS.sqf index 1dcd1ca49e..3899584788 100644 --- a/addons/fcs/functions/fnc_canUseFCS.sqf +++ b/addons/fcs/functions/fnc_canUseFCS.sqf @@ -17,9 +17,4 @@ getNumber ([configFile >> "CfgVehicles" >> typeOf vehicle ACE_player, [ACE_player] call EFUNC(common,getTurretIndex)] call EFUNC(common,getTurretConfigPath) >> QGVAR(Enabled)) == 1 && {cameraView == "GUNNER"} -&& { - private _animationState = animationState ACE_player; - private _moves = configFile >> getText (configFile >> "CfgVehicles" >> (typeof ACE_player) >> "moves"); - - (getNumber (_moves >> "States" >> _animationState >> "canPullTrigger") == 0) -} +&& {!([ACE_player] call CBA_fnc_canUseWeapon)} //Not Turned Out diff --git a/addons/scopes/XEH_PREP.hpp b/addons/scopes/XEH_PREP.hpp index 05f58a5922..908d8064f0 100644 --- a/addons/scopes/XEH_PREP.hpp +++ b/addons/scopes/XEH_PREP.hpp @@ -2,7 +2,6 @@ PREP(adjustScope); PREP(adjustZero); PREP(applyScopeAdjustment); -PREP(canAdjustScope); PREP(canAdjustZero); PREP(firedEH); PREP(getOptics); diff --git a/addons/scopes/XEH_postInit.sqf b/addons/scopes/XEH_postInit.sqf index cc1d9e9c5c..1763bb7a32 100644 --- a/addons/scopes/XEH_postInit.sqf +++ b/addons/scopes/XEH_postInit.sqf @@ -35,7 +35,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); @@ -50,7 +50,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); @@ -65,7 +65,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); @@ -80,7 +80,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); @@ -95,7 +95,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); @@ -110,7 +110,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); @@ -125,7 +125,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); @@ -140,7 +140,7 @@ if (!hasInterface) exitWith {}; // Conditions: canInteract if !([ACE_player, objNull, ["isNotInside"]] call EFUNC(common,canInteractWith)) exitWith {false}; // Conditions: specific - if (!([ACE_player] call FUNC(canAdjustScope))) exitWith {false}; + if (!([ACE_player] call CBA_fnc_canUseWeapon)) exitWith {false}; [ACE_player] call FUNC(inventoryCheck); diff --git a/addons/scopes/functions/fnc_canAdjustScope.sqf b/addons/scopes/functions/fnc_canAdjustScope.sqf deleted file mode 100644 index b5cc729cbb..0000000000 --- a/addons/scopes/functions/fnc_canAdjustScope.sqf +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Author: PabstMirror - * Tests if player would be in a position to adjust scope - * Mainly for determining edge cases with turned-out / FFV. - * - * Argument: - * 0: Unit - * - * Return value: - * - * - * Example: - * [player] call ace_scopes_fnc_canAdjustScope - * - * Public: No - */ -#include "script_component.hpp" - -params ["_unit"]; - -if ((vehicle _unit) == _unit) exitWith {true}; - -private _animationState = animationState _unit; -private _moves = configFile >> getText (configFile >> "CfgVehicles" >> (typeof _unit) >> "moves"); - -(getNumber (_moves >> "States" >> _animationState >> "canPullTrigger") == 1) From f69142dd45a9aaa8a318237a5b78185caa9c8c0b Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Fri, 20 May 2016 11:23:14 -0500 Subject: [PATCH 210/215] Hearing - New XEH, Fix dead effects, Medical var (#3802) * Hearing - New XEH, Fix dead effects, Medical var * Use setHearingCapability * Cleanup dead player vol update * Don't change global hearing in medical * Fix exitWith --- addons/common/XEH_preInit.sqf | 2 + .../functions/fnc_setHearingCapability.sqf | 56 +++++++++---------- addons/hearing/CfgEventHandlers.hpp | 16 ------ addons/hearing/XEH_postInit.sqf | 4 ++ .../hearing/functions/fnc_explosionNear.sqf | 3 - addons/hearing/functions/fnc_firedNear.sqf | 3 - addons/hearing/functions/fnc_updateVolume.sqf | 13 +++-- addons/medical/XEH_postInit.sqf | 4 -- 8 files changed, 39 insertions(+), 62 deletions(-) diff --git a/addons/common/XEH_preInit.sqf b/addons/common/XEH_preInit.sqf index 16e0a65159..dea4e64538 100644 --- a/addons/common/XEH_preInit.sqf +++ b/addons/common/XEH_preInit.sqf @@ -46,6 +46,8 @@ if (isServer) then { GVAR(statusEffect_Names) = []; GVAR(statusEffect_isGlobal) = []; +GVAR(setHearingCapabilityMap) = []; + ////////////////////////////////////////////////// // Set up PlayerChanged eventhandler for pre init (EH is installed in postInit) ////////////////////////////////////////////////// diff --git a/addons/common/functions/fnc_setHearingCapability.sqf b/addons/common/functions/fnc_setHearingCapability.sqf index 2366081ec1..5b1e7a5a3a 100644 --- a/addons/common/functions/fnc_setHearingCapability.sqf +++ b/addons/common/functions/fnc_setHearingCapability.sqf @@ -5,48 +5,44 @@ * Arguments: * 0: id * 1: settings - * 2: add (default: true) + * 2: add [true] OR remove [false] (default: true) * * Return Value: * None * - * Public: Yes + * Example: + * ["earwax", 0.5, true] call ace_common_fnc_setHearingCapability * - * Note: uses player + * Public: Yes */ #include "script_component.hpp" -params ["_id", "_settings", ["_add", true]]; - -private _map = missionNamespace getVariable [QGVAR(setHearingCapabilityMap),[]]; +params ["_id", "_setting", ["_add", true]]; private _exists = false; - -{ - if (_id == _x select 0) exitWith { - _exists = true; - if (_add) then { - _x set [1, _settings]; - } else { - _map set [_forEachIndex, 0]; - _map = _map - [0]; - }; - }; -} forEach _map; - -if (!_exists && _add) then { - _map pushBack [_id, _settings]; -}; - -missionNamespace setVariable [QGVAR(setHearingCapabilityMap), _map]; - -// find lowest volume private _lowestVolume = 1; -{ - _lowestVolume = (_x select 1) min _lowestVolume; - false -} count _map; +GVAR(setHearingCapabilityMap) = GVAR(setHearingCapabilityMap) select { + _x params ["_xID", "_xSetting"]; + if (_id == _xID) then { + _exists = true; + if (_add) then { + _x set [1, _setting]; + _lowestVolume = _lowestVolume min _setting; + true + } else { + false + }; + } else { + _lowestVolume = _lowestVolume min _xSetting; + true + }; +}; + +if (!_exists && _add) then { + _lowestVolume = _lowestVolume min _setting; + GVAR(setHearingCapabilityMap) pushBack [_id, _setting]; +}; // in game sounds 0 fadeSound _lowestVolume; diff --git a/addons/hearing/CfgEventHandlers.hpp b/addons/hearing/CfgEventHandlers.hpp index 352f802435..aa8dbf5134 100644 --- a/addons/hearing/CfgEventHandlers.hpp +++ b/addons/hearing/CfgEventHandlers.hpp @@ -25,22 +25,6 @@ class Extended_Init_EventHandlers { }; }; -class Extended_FiredNear_EventHandlers { - class AllVehicles { - class GVAR(FiredNear) { - clientFiredNear = QUOTE(_this call FUNC(firedNear);); - }; - }; -}; - -class Extended_Explosion_EventHandlers { - class CAManBase { - class GVAR(ExplosionNear) { - clientExplosion = QUOTE(_this call FUNC(explosionNear);); - }; - }; -}; - class Extended_Respawn_EventHandlers { class CAManBase { class ADDON { diff --git a/addons/hearing/XEH_postInit.sqf b/addons/hearing/XEH_postInit.sqf index cbae40dee0..fdd61ccfde 100644 --- a/addons/hearing/XEH_postInit.sqf +++ b/addons/hearing/XEH_postInit.sqf @@ -17,6 +17,10 @@ GVAR(volumeAttenuation) = 1; // Only run PFEH and install event handlers if combat deafness is enabled if (!GVAR(EnableCombatDeafness)) exitWith {}; + //Add XEH: + ["CAManBase", "FiredNear", FUNC(firedNear)] call CBA_fnc_addClassEventHandler; + ["CAManBase", "Explosion", FUNC(explosionNear)] call CBA_fnc_addClassEventHandler; + // Update hearing protection now: [] call FUNC(updateHearingProtection); diff --git a/addons/hearing/functions/fnc_explosionNear.sqf b/addons/hearing/functions/fnc_explosionNear.sqf index 799de52320..76c6707de5 100644 --- a/addons/hearing/functions/fnc_explosionNear.sqf +++ b/addons/hearing/functions/fnc_explosionNear.sqf @@ -16,9 +16,6 @@ */ #include "script_component.hpp" -// Only run if combat deafness is enabled -if (!GVAR(EnableCombatDeafness)) exitWith {}; - params ["_unit", "_damage"]; if (_unit != ACE_player) exitWith {}; diff --git a/addons/hearing/functions/fnc_firedNear.sqf b/addons/hearing/functions/fnc_firedNear.sqf index f583ab0050..46bbee4fae 100644 --- a/addons/hearing/functions/fnc_firedNear.sqf +++ b/addons/hearing/functions/fnc_firedNear.sqf @@ -22,9 +22,6 @@ */ #include "script_component.hpp" -// Only run if combat deafness is enabled -if (!GVAR(EnableCombatDeafness)) exitWith {}; - params ["_object", "_firer", "_distance", "_weapon", "", "", "_ammo"]; //Only run if firedNear object is player or player's vehicle: diff --git a/addons/hearing/functions/fnc_updateVolume.sqf b/addons/hearing/functions/fnc_updateVolume.sqf index 58eedc7b39..2212bd6222 100644 --- a/addons/hearing/functions/fnc_updateVolume.sqf +++ b/addons/hearing/functions/fnc_updateVolume.sqf @@ -16,6 +16,12 @@ */ #include "script_component.hpp" +if (!alive ACE_player) exitWith { + if (missionNameSpace getVariable [QGVAR(disableVolumeUpdate), false]) exitWith {}; + TRACE_1("dead - removing hearing effects",ACE_player); + [QUOTE(ADDON), 1, true] call EFUNC(common,setHearingCapability); +}; + (_this select 0) params ["_justUpdateVolume"]; GVAR(deafnessDV) = (GVAR(deafnessDV) min 20) max 0; @@ -54,9 +60,4 @@ if (ACE_player getVariable ["ACE_isUnconscious", false]) then { _volume = _volume min GVAR(UnconsciousnessVolume); }; -private _soundTransitionTime = if (_justUpdateVolume) then {0.1} else {1}; - -_soundTransitionTime fadeSound _volume; -_soundTransitionTime fadeSpeech _volume; -ACE_player setVariable ["tf_globalVolume", _volume]; -if (!isNil "acre_api_fnc_setGlobalVolume") then {[_volume^(0.33)] call acre_api_fnc_setGlobalVolume;}; +[QUOTE(ADDON), _volume, true] call EFUNC(common,setHearingCapability); diff --git a/addons/medical/XEH_postInit.sqf b/addons/medical/XEH_postInit.sqf index 8d8911a6bf..f0d3b907f6 100644 --- a/addons/medical/XEH_postInit.sqf +++ b/addons/medical/XEH_postInit.sqf @@ -37,19 +37,15 @@ if (isServer) then {["placedInBodyBag", FUNC(serverRemoveBody)] call EFUNC(commo params ["_unit", "_status"]; if (local _unit) then { if (_status) then { - _unit setVariable ["tf_globalVolume", 0.4]; _unit setVariable ["tf_voiceVolume", 0, true]; _unit setVariable ["tf_unable_to_use_radio", true, true]; _unit setVariable ["acre_sys_core_isDisabled", true, true]; - if (!isNil "acre_api_fnc_setGlobalVolume") then { [0.4^0.33] call acre_api_fnc_setGlobalVolume; }; } else { - _unit setVariable ["tf_globalVolume", 1]; _unit setVariable ["tf_voiceVolume", 1, true]; _unit setVariable ["tf_unable_to_use_radio", false, true]; _unit setVariable ["acre_sys_core_isDisabled", false, true]; - if (!isNil "acre_api_fnc_setGlobalVolume") then { [1] call acre_api_fnc_setGlobalVolume; }; }; }; }] call EFUNC(common,addEventHandler); From aee4d23bdbbb2ad9e4a7243acf19d1933f84d260 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 21 May 2016 13:07:17 +0200 Subject: [PATCH 211/215] fullCrew new parameter to improve FUNC(getTurretX) --- .../functions/fnc_getTurretCommander.sqf | 17 +------------ .../common/functions/fnc_getTurretCopilot.sqf | 19 +++------------ .../common/functions/fnc_getTurretGunner.sqf | 17 +------------ addons/common/functions/fnc_getTurrets.sqf | 4 +++- addons/common/functions/fnc_getTurretsFFV.sqf | 17 +------------ .../common/functions/fnc_getTurretsOther.sqf | 24 +++---------------- 6 files changed, 12 insertions(+), 86 deletions(-) diff --git a/addons/common/functions/fnc_getTurretCommander.sqf b/addons/common/functions/fnc_getTurretCommander.sqf index e73795e148..3e7f09215f 100644 --- a/addons/common/functions/fnc_getTurretCommander.sqf +++ b/addons/common/functions/fnc_getTurretCommander.sqf @@ -14,19 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -private _turrets = allTurrets [_vehicle, true]; - -private _turret = []; - -{ - private _config = configFile >> "CfgVehicles" >> typeOf _vehicle; - - _config = [_config, _x] call FUNC(getTurretConfigPath); - - if (getNumber (_config >> "primaryObserver") == 1) exitWith { - _turret = _x; - }; - false -} count _turrets; - -_turret +fullCrew [_vehicle, "commander", true] apply {_x select 3} param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretCopilot.sqf b/addons/common/functions/fnc_getTurretCopilot.sqf index 6161f5c4cc..49002cc40e 100644 --- a/addons/common/functions/fnc_getTurretCopilot.sqf +++ b/addons/common/functions/fnc_getTurretCopilot.sqf @@ -14,19 +14,6 @@ params [["_vehicle", objNull, [objNull]]]; -private _turrets = allTurrets [_vehicle, true]; - -private _turret = []; - -{ - private _config = configFile >> "CfgVehicles" >> typeOf _vehicle; - - _config = [_config, _x] call FUNC(getTurretConfigPath); - - if (getNumber (_config >> "isCopilot") == 1 && {getNumber (_config >> "primaryGunner") != 1} && {getNumber (_config >> "primaryObserver") != 1}) exitWith { - _turret = _x; - }; - false -} count _turrets; - -_turret +fullCrew [_vehicle, "turret", true] apply {_x select 3} select { + getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") == 1 +} param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretGunner.sqf b/addons/common/functions/fnc_getTurretGunner.sqf index 6f59798cc6..4a26e2c03d 100644 --- a/addons/common/functions/fnc_getTurretGunner.sqf +++ b/addons/common/functions/fnc_getTurretGunner.sqf @@ -14,19 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -private _turrets = allTurrets [_vehicle, true]; - -private _turret = []; - -{ - private _config = configFile >> "CfgVehicles" >> typeOf _vehicle; - - _config = [_config, _x] call FUNC(getTurretConfigPath); - - if (getNumber (_config >> "primaryGunner") == 1) exitWith { - _turret = _x; - }; - false -} count _turrets; - -_turret +fullCrew [_vehicle, "gunner", true] apply {_x select 3} param [0, []] // return diff --git a/addons/common/functions/fnc_getTurrets.sqf b/addons/common/functions/fnc_getTurrets.sqf index 229f3ab1f7..0479580764 100644 --- a/addons/common/functions/fnc_getTurrets.sqf +++ b/addons/common/functions/fnc_getTurrets.sqf @@ -8,12 +8,14 @@ * Return Value: * Turret Indecies * - * Public: Yes + * Public: No * * Note: It's advised to use allTurrets [_vehicle, true] instead whenever possible */ #include "script_component.hpp" +ACE_DEPRECATED("ace_common_fnc_getTurrets","3.7.0","allTurrets [_vehicle, true]"); + params ["_type"]; private _varName = format [QGVAR(CachedTurrets_%1), _type]; diff --git a/addons/common/functions/fnc_getTurretsFFV.sqf b/addons/common/functions/fnc_getTurretsFFV.sqf index 8c471824cf..5c36e20197 100644 --- a/addons/common/functions/fnc_getTurretsFFV.sqf +++ b/addons/common/functions/fnc_getTurretsFFV.sqf @@ -14,19 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -private _turrets = allTurrets [_vehicle, true]; - -private _turret = []; - -{ - private _config = configFile >> "CfgVehicles" >> typeOf _vehicle; - - _config = [_config, _x] call FUNC(getTurretConfigPath); - - if (getNumber (_config >> "isPersonTurret") == 1) then { - _turret pushBack _x; - }; - false -} count _turrets; - -_turret +fullCrew [_vehicle, "turret", true] select {_x select 4} apply {_x select 3} // return diff --git a/addons/common/functions/fnc_getTurretsOther.sqf b/addons/common/functions/fnc_getTurretsOther.sqf index 408a5529d5..ef2a1278dc 100644 --- a/addons/common/functions/fnc_getTurretsOther.sqf +++ b/addons/common/functions/fnc_getTurretsOther.sqf @@ -14,24 +14,6 @@ params [["_vehicle", objNull, [objNull]]]; -private _turrets = allTurrets [_vehicle, true]; - -private _turret = []; - -{ - private _config = configFile >> "CfgVehicles" >> typeOf _vehicle; - - _config = [_config, _x] call FUNC(getTurretConfigPath); - - if ( - getNumber (_config >> "isCopilot") != 1 - && {getNumber (_config >> "primaryGunner") != 1} - && {getNumber (_config >> "primaryObserver") != 1} - && {getNumber (_config >> "isPersonTurret") != 1} - ) then { - _turret pushBack _x; - }; - false -} count _turrets; - -_turret +fullCrew [_vehicle, "turret", true] select {!(_x select 4)} apply {_x select 3} select { + getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") != 1 +} // return From d395fcd7927c9e68cf6b418f1d941b14b6191a3a Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 21 May 2016 13:22:13 +0200 Subject: [PATCH 212/215] travis pls --- addons/common/functions/fnc_getTurretCommander.sqf | 2 +- addons/common/functions/fnc_getTurretCopilot.sqf | 4 +--- addons/common/functions/fnc_getTurretGunner.sqf | 2 +- addons/common/functions/fnc_getTurretsFFV.sqf | 2 +- addons/common/functions/fnc_getTurretsOther.sqf | 4 +--- 5 files changed, 5 insertions(+), 9 deletions(-) diff --git a/addons/common/functions/fnc_getTurretCommander.sqf b/addons/common/functions/fnc_getTurretCommander.sqf index 3e7f09215f..30860652cc 100644 --- a/addons/common/functions/fnc_getTurretCommander.sqf +++ b/addons/common/functions/fnc_getTurretCommander.sqf @@ -14,4 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -fullCrew [_vehicle, "commander", true] apply {_x select 3} param [0, []] // return +(fullCrew [_vehicle, "commander", true] apply {_x select 3}) param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretCopilot.sqf b/addons/common/functions/fnc_getTurretCopilot.sqf index 49002cc40e..fb4d4cff2e 100644 --- a/addons/common/functions/fnc_getTurretCopilot.sqf +++ b/addons/common/functions/fnc_getTurretCopilot.sqf @@ -14,6 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -fullCrew [_vehicle, "turret", true] apply {_x select 3} select { - getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") == 1 -} param [0, []] // return +((fullCrew [_vehicle, "turret", true] apply {_x select 3}) select {getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") == 1}) param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretGunner.sqf b/addons/common/functions/fnc_getTurretGunner.sqf index 4a26e2c03d..666e70f3c9 100644 --- a/addons/common/functions/fnc_getTurretGunner.sqf +++ b/addons/common/functions/fnc_getTurretGunner.sqf @@ -14,4 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -fullCrew [_vehicle, "gunner", true] apply {_x select 3} param [0, []] // return +(fullCrew [_vehicle, "gunner", true] apply {_x select 3}) param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretsFFV.sqf b/addons/common/functions/fnc_getTurretsFFV.sqf index 5c36e20197..5fc5bd159b 100644 --- a/addons/common/functions/fnc_getTurretsFFV.sqf +++ b/addons/common/functions/fnc_getTurretsFFV.sqf @@ -14,4 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -fullCrew [_vehicle, "turret", true] select {_x select 4} apply {_x select 3} // return +(fullCrew [_vehicle, "turret", true] select {_x select 4}) apply {_x select 3} // return diff --git a/addons/common/functions/fnc_getTurretsOther.sqf b/addons/common/functions/fnc_getTurretsOther.sqf index ef2a1278dc..7dcaff4221 100644 --- a/addons/common/functions/fnc_getTurretsOther.sqf +++ b/addons/common/functions/fnc_getTurretsOther.sqf @@ -14,6 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -fullCrew [_vehicle, "turret", true] select {!(_x select 4)} apply {_x select 3} select { - getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") != 1 -} // return +((fullCrew [_vehicle, "turret", true] select {!(_x select 4)}) apply {_x select 3}) select {getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") != 1} // return From 54caadfb88a42ae36d638e0414f58e8ce8a7a6d8 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 21 May 2016 13:26:04 +0200 Subject: [PATCH 213/215] Add support for new script command select in travis --- tools/sqf_validator.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/sqf_validator.py b/tools/sqf_validator.py index 7a905a3315..8827aaa4ba 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"]; for word in keyWords: try: subWord = content.index(word, index, index+len(word)) @@ -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 c9ea5676eab699ab0a600b829f871437679867a5 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 21 May 2016 13:29:42 +0200 Subject: [PATCH 214/215] travis test --- addons/common/functions/fnc_getTurretCommander.sqf | 2 +- addons/common/functions/fnc_getTurretCopilot.sqf | 4 +++- addons/common/functions/fnc_getTurretGunner.sqf | 2 +- addons/common/functions/fnc_getTurretsFFV.sqf | 2 +- addons/common/functions/fnc_getTurretsOther.sqf | 4 +++- 5 files changed, 9 insertions(+), 5 deletions(-) diff --git a/addons/common/functions/fnc_getTurretCommander.sqf b/addons/common/functions/fnc_getTurretCommander.sqf index 30860652cc..3e7f09215f 100644 --- a/addons/common/functions/fnc_getTurretCommander.sqf +++ b/addons/common/functions/fnc_getTurretCommander.sqf @@ -14,4 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -(fullCrew [_vehicle, "commander", true] apply {_x select 3}) param [0, []] // return +fullCrew [_vehicle, "commander", true] apply {_x select 3} param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretCopilot.sqf b/addons/common/functions/fnc_getTurretCopilot.sqf index fb4d4cff2e..49002cc40e 100644 --- a/addons/common/functions/fnc_getTurretCopilot.sqf +++ b/addons/common/functions/fnc_getTurretCopilot.sqf @@ -14,4 +14,6 @@ params [["_vehicle", objNull, [objNull]]]; -((fullCrew [_vehicle, "turret", true] apply {_x select 3}) select {getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") == 1}) param [0, []] // return +fullCrew [_vehicle, "turret", true] apply {_x select 3} select { + getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") == 1 +} param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretGunner.sqf b/addons/common/functions/fnc_getTurretGunner.sqf index 666e70f3c9..4a26e2c03d 100644 --- a/addons/common/functions/fnc_getTurretGunner.sqf +++ b/addons/common/functions/fnc_getTurretGunner.sqf @@ -14,4 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -(fullCrew [_vehicle, "gunner", true] apply {_x select 3}) param [0, []] // return +fullCrew [_vehicle, "gunner", true] apply {_x select 3} param [0, []] // return diff --git a/addons/common/functions/fnc_getTurretsFFV.sqf b/addons/common/functions/fnc_getTurretsFFV.sqf index 5fc5bd159b..5c36e20197 100644 --- a/addons/common/functions/fnc_getTurretsFFV.sqf +++ b/addons/common/functions/fnc_getTurretsFFV.sqf @@ -14,4 +14,4 @@ params [["_vehicle", objNull, [objNull]]]; -(fullCrew [_vehicle, "turret", true] select {_x select 4}) apply {_x select 3} // return +fullCrew [_vehicle, "turret", true] select {_x select 4} apply {_x select 3} // return diff --git a/addons/common/functions/fnc_getTurretsOther.sqf b/addons/common/functions/fnc_getTurretsOther.sqf index 7dcaff4221..ef2a1278dc 100644 --- a/addons/common/functions/fnc_getTurretsOther.sqf +++ b/addons/common/functions/fnc_getTurretsOther.sqf @@ -14,4 +14,6 @@ params [["_vehicle", objNull, [objNull]]]; -((fullCrew [_vehicle, "turret", true] select {!(_x select 4)}) apply {_x select 3}) select {getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") != 1} // return +fullCrew [_vehicle, "turret", true] select {!(_x select 4)} apply {_x select 3} select { + getNumber ([_vehicle, _x] call CBA_fnc_getTurret >> "isCopilot") != 1 +} // return From 391191241ba55cbfd22659ea45b051cf6142138d Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 21 May 2016 13:46:26 +0200 Subject: [PATCH 215/215] Add apply to script validation --- tools/sqf_validator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/sqf_validator.py b/tools/sqf_validator.py index 8827aaa4ba..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", "param", "select"]; + 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))