diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md
index a333dc08fe..b56ddb134a 100644
--- a/.github/ISSUE_TEMPLATE.md
+++ b/.github/ISSUE_TEMPLATE.md
@@ -22,4 +22,4 @@
**RPT log file:**
- Add a link ([gist](https://gist.github.com) or [pastebin](http://pastebin.com)) to the client and/or server RPT file. An instruction to find your RPT files can be found [here](https://community.bistudio.com/wiki/Crash_Files#Arma_3).
-- If possible at the time the bug is encountered, go to ACE Options and select "Debug To Clipboard", this will print extensive debug information to the RPT file.
+- If possible at the time the bug is encountered, go to Options and select "ACE Debug To Clipboard", this will print extensive debug information to the RPT file and copy it to clipboard.
diff --git a/addons/arsenal/XEH_PREP.hpp b/addons/arsenal/XEH_PREP.hpp
index 576115ad68..76c77c8a7c 100644
--- a/addons/arsenal/XEH_PREP.hpp
+++ b/addons/arsenal/XEH_PREP.hpp
@@ -34,6 +34,7 @@ PREP(onSelChangedRight);
PREP(onSelChangedRightListnBox);
PREP(open3DEN);
PREP(openBox);
+PREP(portVALoadouts);
PREP(removeBox);
PREP(removeVirtualItems);
PREP(scanConfig);
diff --git a/addons/arsenal/functions/fnc_portVALoadouts.sqf b/addons/arsenal/functions/fnc_portVALoadouts.sqf
new file mode 100644
index 0000000000..7ad141819d
--- /dev/null
+++ b/addons/arsenal/functions/fnc_portVALoadouts.sqf
@@ -0,0 +1,43 @@
+/*
+ * Author: alganthe
+ * Port VA loadouts to ACE Arsenal.
+ *
+ * Arguments:
+ * None
+ *
+ * Return Value:
+ * None
+ *
+ * Public: Yes
+*/
+#include "script_component.hpp"
+
+private _VALoadouts = +(profilenamespace getvariable ["bis_fnc_saveInventory_data",[]]);
+private _aceLoadouts = +(profileNamespace getVariable [QGVAR(saved_loadouts),[]]);
+
+if (isNull player) exitWith {
+ [localize LSTRING(portLoadoutsPlayerError)] call BIS_fnc_error;
+};
+
+if (_VALoadouts isEqualTo []) exitWith {
+ [localize LSTRING(portLoadoutsLoadoutError)] call BIS_fnc_error;
+};
+
+for "_i" from 0 to (count _VALoadouts - 1) step 2 do {
+ _name = _VALoadouts select _i;
+ _inventory = _VALoadouts select (_i + 1);
+
+ private _sameNameLoadoutsList = _aceLoadouts select {_x select 0 == _name};
+ [player, [profilenamespace, _name]] call bis_fnc_loadinventory;
+
+ private _loadout = getUnitLoadout player;
+
+ if (count _sameNameLoadoutsList > 0) then {
+ _aceLoadouts set [_aceLoadouts find (_sameNameLoadoutsList select 0), [_name, _loadout]];
+
+ } else {
+ _aceLoadouts pushBack [_name, _loadout];
+ };
+};
+
+profileNamespace setVariable [QGVAR(saved_loadouts), _aceLoadouts];
diff --git a/addons/arsenal/stringtable.xml b/addons/arsenal/stringtable.xml
index 8eaff441ca..77afb94c73 100644
--- a/addons/arsenal/stringtable.xml
+++ b/addons/arsenal/stringtable.xml
@@ -434,6 +434,17 @@
Impossibile aprire l'arsenale ACE
ACE 武器庫を開けません
+
+ Import BI VA loadouts to ACE Arsenal
+ Importe les loadouts de BI VA dans ACE Arsenal
+
+
+ No player unit available! Place a unit and mark it as "Player".
+ Aucune unité joueur disponible ! Placez une unité et marquez la en tant que "joueur".
+
+
+ No loadouts to import.
+ Aucun loadout à importer.
ACE Arsenal
ACE-Arsenal
diff --git a/addons/arsenal/ui/RscAttributes.hpp b/addons/arsenal/ui/RscAttributes.hpp
index 14bee4f6a5..44fab0515e 100644
--- a/addons/arsenal/ui/RscAttributes.hpp
+++ b/addons/arsenal/ui/RscAttributes.hpp
@@ -130,7 +130,7 @@ class GVAR(display) {
text = ECSTRING(common,Weight);
x = 0;
y = 0;
- w = QUOTE(40 * GRID_W);
+ w = QUOTE(30 * GRID_W);
h = QUOTE(8 * GRID_H);
sizeEx = QUOTE(7 * GRID_H);
};
@@ -138,9 +138,9 @@ class GVAR(display) {
idc = IDC_totalWeightText;
style = ST_RIGHT;
text = "";
- x = QUOTE(40 * GRID_W);
+ x = QUOTE(30 * GRID_W);
y = 0;
- w = QUOTE(40 * GRID_W);
+ w = QUOTE(50 * GRID_W);
h = QUOTE(8 * GRID_H);
sizeEx = QUOTE(7 * GRID_H);
};
@@ -159,51 +159,58 @@ class GVAR(display) {
h = QUOTE(10 * GRID_H);
sizeEx = QUOTE(5 * GRID_H);
};
+
+ #define WIDTH_TOTAL (safezoneW - 2 * (93 * GRID_W))
+ #define WIDTH_GAP (WIDTH_TOTAL / 100)
+ #define WIDTH_SINGLE ((WIDTH_TOTAL - 6 * WIDTH_GAP) / 5)
+
class menuBar: RscControlsGroupNoScrollbars {
idc = IDC_menuBar;
- x = QUOTE((safezoneX + safezoneW * 0.50) - (105 * GRID_W));
+ x = QUOTE(0.5 - WIDTH_TOTAL / 2);
y = QUOTE(safezoneH + safezoneY - 9 * GRID_H);
- w = QUOTE(210 * GRID_W);
+ w = QUOTE(WIDTH_TOTAL);
h = QUOTE(7 * GRID_H);
class controls {
class buttonHide: ctrlButton {
idc = -1;
colorBackground[] = {0,0,0,0.8};
- x = QUOTE(0 * GRID_W);
+ x = QUOTE(1 * WIDTH_GAP + 0 * WIDTH_SINGLE);
y = QUOTE(0);
- w = QUOTE(40 * GRID_W);
+ w = QUOTE(WIDTH_SINGLE);
h = QUOTE(7 * GRID_H);
text = CSTRING(buttonHideText);
+ sizeEx = QUOTE(5 * GRID_H);
shortcuts[] = {"0x0E"};
tooltip = CSTRING(buttonHideTooltip);
onButtonClick = QUOTE([ctrlparent (_this select 0)] call FUNC(buttonHide));
};
class buttonLoadouts: buttonHide {
idc = -1;
- x = QUOTE(42.5 * GRID_W);
+ x = QUOTE(2 * WIDTH_GAP + 1 * WIDTH_SINGLE);
text = CSTRING(buttonLoadoutsText);
onButtonClick = QUOTE(createDialog QQGVAR(loadoutsDisplay));
};
class buttonExport: buttonHide {
idc = -1;
- x = QUOTE(85 * GRID_W);
+ x = QUOTE(3 * WIDTH_GAP + 2 * WIDTH_SINGLE);
text = CSTRING(buttonExportText);
onButtonClick = QUOTE([ctrlparent (_this select 0)] call FUNC(buttonExport));
};
class buttonImport: buttonHide {
idc = -1;
- x = QUOTE(127.5 * GRID_W);
+ x = QUOTE(4 * WIDTH_GAP + 3 * WIDTH_SINGLE);
text = CSTRING(buttonImportText);
onButtonClick = QUOTE([ctrlparent (_this select 0)] call FUNC(buttonImport));
};
class buttonClose: ctrlButtonClose {
idc = IDC_menuBarClose;
colorBackground[] = {0,0,0,0.8};
- x = QUOTE(170 * GRID_W);
+ x = QUOTE(5 * WIDTH_GAP + 4 * WIDTH_SINGLE);
y = QUOTE(0);
- w = QUOTE(40 * GRID_W);
+ w = QUOTE(WIDTH_SINGLE);
h = QUOTE(7 * GRID_H);
text = CSTRING(buttonCloseText);
+ sizeEx = QUOTE(5 * GRID_H);
shortcuts[]= {"0x01"};
onButtonClick = QUOTE(ctrlparent (_this select 0) closeDisplay 2);
};
@@ -330,6 +337,7 @@ class GVAR(display) {
w = QUOTE(80 * GRID_W);
h = QUOTE(6 * GRID_H);
onLBSelChanged = QUOTE(_this call FUNC(sortPanel));
+ sizeEx = QUOTE(5 * GRID_H);
class Items {
class Alphabet {
text="$STR_a3_rscdisplayarsenal_sort_alphabet";
@@ -760,6 +768,7 @@ class GVAR(loadoutsDisplay) {
y = QUOTE(0);
w = QUOTE(160 * GRID_W);
h = QUOTE(5 * GRID_H);
+ sizeEx = QUOTE(5 * GRID_H);
};
class contentPanel: RscListnBox {
idc = IDC_contentPanel;
@@ -781,6 +790,7 @@ class GVAR(loadoutsDisplay) {
y = QUOTE(safezoneH - (51 * GRID_H));
w = QUOTE(15 * GRID_W);
h = QUOTE(5 * GRID_H);
+ sizeEx = QUOTE(5 * GRID_H);
colorBackground[]={0,0,0,0.2};
};
class textEditBox: ctrlEdit {
@@ -798,6 +808,7 @@ class GVAR(loadoutsDisplay) {
h = QUOTE(10 * GRID_H);
text= CSTRING(buttonSaveText);
tooltip= CSTRING(buttonSaveTooltip);
+ sizeEx = QUOTE(5 * GRID_H);
onButtonClick = QUOTE([ARR_2(ctrlparent (_this select 0), _this select 0)] call FUNC(buttonLoadoutsSave));
colorBackground[] = {0,0,0,0.8};
};
@@ -839,7 +850,7 @@ class GVAR(loadoutsDisplay) {
y = QUOTE(safezoneH + safezoneY - 9 * GRID_H);
w = QUOTE(30 * GRID_W);
h = QUOTE(7 * GRID_H);
- sizeEx = QUOTE(4 * GRID_H);
+ sizeEx = QUOTE(5 * GRID_H);
text= CSTRING(buttonCloseText);
shortcuts[]= {"0x01"};
tooltip= "";
@@ -867,7 +878,7 @@ class GVAR(loadoutsDisplay) {
y = QUOTE(0 * GRID_H);
w = QUOTE(52 * GRID_W);
h = QUOTE(7 * GRID_H);
- sizeEx = QUOTE(4 * GRID_H);
+ sizeEx = QUOTE(5 * GRID_H);
text= CSTRING(tabMyLoadoutsText);
tooltip= CSTRING(tabMyLoadoutsTooltip);
onButtonClick = QUOTE([ARR_2(ctrlparent (_this select 0), _this select 0)] call FUNC(loadoutsChangeTab));
diff --git a/addons/arsenal/ui/RscCommon.hpp b/addons/arsenal/ui/RscCommon.hpp
index 2a88204d7b..5db52bf704 100644
--- a/addons/arsenal/ui/RscCommon.hpp
+++ b/addons/arsenal/ui/RscCommon.hpp
@@ -275,4 +275,18 @@ class Display3DEN {
};
};
};
+ class Controls {
+ class MenuStrip: ctrlMenuStrip {
+ class Items {
+ class Tools {
+ items[] += {"ACE_arsenal_portVALoadouts"};
+ };
+ class ACE_arsenal_portVALoadouts {
+ text = CSTRING(portLoadoutsText);
+ picture = "\z\ace\logo_ace3_ca.paa";
+ action = "call ace_arsenal_fnc_portVALoadouts;";
+ };
+ };
+ };
+ };
};
diff --git a/addons/explosives/functions/fnc_addCellphoneIED.sqf b/addons/explosives/functions/fnc_addCellphoneIED.sqf
index beca3d3246..88da983be9 100644
--- a/addons/explosives/functions/fnc_addCellphoneIED.sqf
+++ b/addons/explosives/functions/fnc_addCellphoneIED.sqf
@@ -27,15 +27,18 @@ private _config = (_this select 3) select (count (_this select 3) - 1);
private _requiredItems = getArray(_config >> "requires");
private _hasRequired = true;
private _detonators = [_unit] call FUNC(getDetonators);
+
{
if !(_x in _detonators) exitWith{
_hasRequired = false;
};
} count _requiredItems;
+private _code = "";
private _codeSet = false;
+
while {!_codeSet} do {
- private _code = str(round (random 9999));
+ _code = str(round (random 9999));
_count = 4 - count (toArray _code);
while {_count > 0} do {
_code = "0" + _code;
@@ -43,9 +46,11 @@ while {!_codeSet} do {
};
_codeSet = (count ([_code] call FUNC(getSpeedDialExplosive))) == 0;
};
+
if (isNil QGVAR(CellphoneIEDs)) then {
GVAR(CellphoneIEDs) = [];
};
+
private _count = GVAR(CellphoneIEDs) pushBack [_explosive,_code,GetNumber(ConfigFile >> "CfgMagazines" >> _magazineClass >> "ACE_Triggers" >> "Cellphone" >> "FuseTime")];
_count = _count + 1;
publicVariable QGVAR(CellphoneIEDs);
diff --git a/addons/explosives/functions/fnc_onIncapacitated.sqf b/addons/explosives/functions/fnc_onIncapacitated.sqf
index 6f9a9f498a..7e2cb249cc 100644
--- a/addons/explosives/functions/fnc_onIncapacitated.sqf
+++ b/addons/explosives/functions/fnc_onIncapacitated.sqf
@@ -19,6 +19,11 @@
params ["_unit"];
TRACE_1("params",_unit);
+if (_unit == ace_player) then {
+ // close cellphone if open
+ closeDialog 0;
+};
+
// Exit if no item:
if (({_x == "ACE_DeadManSwitch"} count (items _unit)) == 0) exitWith {};
diff --git a/addons/frag/functions/fnc_fired.sqf b/addons/frag/functions/fnc_fired.sqf
index b1e29a79ca..a9d13cde08 100644
--- a/addons/frag/functions/fnc_fired.sqf
+++ b/addons/frag/functions/fnc_fired.sqf
@@ -54,6 +54,7 @@ if (_shouldAdd) then {
private _localShooter = if (isNil "_gunner") then {local _unit} else {local _gunner};
TRACE_4("",_localShooter,_unit,_ammo,_projectile);
if (!_localShooter) exitWith {};
+ if (_weapon == "Put") exitWith {}; // Ignore explosives placed without ace_explosives
// Skip if less than 0.5 second from last shot
if ((CBA_missionTime - (_unit getVariable [QGVAR(lastTrack), -1])) < 0.5) exitWith {};
diff --git a/addons/optionsmenu/README.md b/addons/optionsmenu/README.md
index f8d8c54d09..e274229053 100644
--- a/addons/optionsmenu/README.md
+++ b/addons/optionsmenu/README.md
@@ -1,7 +1,8 @@
ace_optionsmenu
===============
-Adds the options menu used by other components.
+Previously held the options menu.
+Now just handles version display on main menu and debug/headbug on options menu.
## Maintainers
diff --git a/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf b/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf
index fcaca6a9de..a502934f50 100644
--- a/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf
+++ b/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf
@@ -55,15 +55,16 @@ if (isNull ace_player) then {"null"} else {animationState ace_player}];
_text = format ["
-------ACE Settings------"];
+------ACE's CBA Settings------"];
[_text] call _outputText;
-
+private _aceSettings = cba_settings_allSettings select {((_x select [0,4]) == "ace_") || {(_x select [0,5]) == "acex_"}};
+_aceSettings sort true;
{
- _var = missionNamespace getVariable [(_x select 0), "ERROR: Not Defined"];
- _text = format ["%1 - %2", (_x select 0), _var];
+ _var = missionNamespace getVariable [_x, "ERROR: Not Defined"];
+ _text = format ["%1 - %2", _x, _var];
[_text] call _outputText;
-} forEach EGVAR(common,settings);
+} forEach _aceSettings;
_text = format ["
diff --git a/addons/optionsmenu/script_component.hpp b/addons/optionsmenu/script_component.hpp
index c13e915702..7ae6409e6c 100644
--- a/addons/optionsmenu/script_component.hpp
+++ b/addons/optionsmenu/script_component.hpp
@@ -20,10 +20,3 @@
#define IDC_MAIN_INFO 80090
#define IDC_MAIN_INFO_CURRENT_VERSION_INFO 80091
#define IDC_MAIN_INFO_NEWEST_VERSION_INFO 80092
-
-#define MENU_TAB_OPTIONS 0
-#define MENU_TAB_COLORS 1
-
-#define MENU_TAB_SERVER_OPTIONS 10
-#define MENU_TAB_SERVER_COLORS 11
-#define MENU_TAB_SERVER_VALUES 12
diff --git a/addons/scopes/functions/fnc_adjustScope.sqf b/addons/scopes/functions/fnc_adjustScope.sqf
index f670fc1720..8c48ee654b 100644
--- a/addons/scopes/functions/fnc_adjustScope.sqf
+++ b/addons/scopes/functions/fnc_adjustScope.sqf
@@ -18,6 +18,7 @@
#include "script_component.hpp"
params ["_unit", "_turretAndDirection", "_majorStep"];
+TRACE_3("adjustScope",_unit,_turretAndDirection,_majorStep);
if (!(_unit isKindOf "Man")) exitWith {false};
if (currentMuzzle _unit != currentWeapon _unit) exitWith {false};
@@ -26,14 +27,16 @@ if (!GVAR(enabled)) exitWith {false};
private _weaponIndex = [_unit, currentWeapon _unit] call EFUNC(common,getWeaponIndex);
if (_weaponIndex < 0) exitWith {false};
+TRACE_2("",GVAR(canAdjustElevation),GVAR(canAdjustWindage));
if (!(GVAR(canAdjustElevation) select _weaponIndex) && (_turretAndDirection in [ELEVATION_UP, ELEVATION_DOWN])) exitWith {false};
-if (!(GVAR(canAdjustWindage) select _weaponIndex) && (_turretAndDirection in [WINDAGE_UP, WINDAGE_DOWN])) exitWith {false};
+if (!(GVAR(canAdjustWindage) select _weaponIndex) && (_turretAndDirection in [WINDAGE_LEFT, WINDAGE_RIGHT])) exitWith {false};
private _adjustment = _unit getVariable [QGVAR(Adjustment), [[0, 0, 0], [0, 0, 0], [0, 0, 0]]];
private _zeroing = _adjustment select _weaponIndex;
_zeroing params ["_elevation", "_windage", "_zero"];
(GVAR(scopeAdjust) select _weaponIndex) params ["_maxVertical", "_verticalIncrement", "_maxHorizontal", "_horizontalIncrement"];
+TRACE_4("",_maxVertical,_verticalIncrement,_maxHorizontal,_horizontalIncrement);
switch (_turretAndDirection) do {
case ELEVATION_UP: { _elevation = _elevation + _verticalIncrement };