Skip to content

Commit 1a2a1e6

Browse files
committed
v1.1.0
1 parent a13f92a commit 1a2a1e6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+508
-384
lines changed

@AIO_SPPack/addons/AIO_AIMENU.pbo

155 KB
Binary file not shown.

@AIO_SPPack/addons/AIO_AIMENU/CustomMenus/cover.hpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,5 +59,20 @@ class AIO_coverSubMenu {
5959
enable = "NotEmpty";
6060
speechId = 0;
6161
};
62+
class Seperator3 {
63+
title = "";
64+
shortcuts[] = {};
65+
command = -1;
66+
speechId = 0;
67+
};
68+
class Building {
69+
title = "<img color='#fffb44' image='\A3\ui_f\data\IGUI\Cfg\simpleTasks\types\getin_ca.paa'/><t font='PuristaBold'> Move into building %POINTED_TARGET_NAME</t>";
70+
shortcuts[] = {6};
71+
shortcutsAction = "CommandingMenu5";
72+
show = "1";
73+
enable = "NotEmpty * CursorOnGround";
74+
menu = "#USER:AIO_moveIntoHouse_subMenu";
75+
speechId = 0;
76+
};
6277
};
6378
};
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
class AIO_flankMenu {
2+
title = "Flank";
3+
access = 0;
4+
atomic = 0;
5+
vocabulary = "";
6+
contexsensitive = 1;
7+
class Items {
8+
class Advance {
9+
title = "<img image='AIO_AIMenu\pictures\advance1.paa'/><t font='PuristaBold'> Advance</t>";
10+
shortcuts[] = {2,72};
11+
command = "CMD_ADVANCE";
12+
show="1";
13+
enable="NotEmpty";
14+
speechId = 0;
15+
};
16+
class FlankL {
17+
title = "<img image='AIO_AIMenu\pictures\flankL.paa'/><t font='PuristaBold'> Flank Left</t>";
18+
shortcuts[] = {3,75};
19+
command = "CMD_FLANK_LEFT";
20+
show="1";
21+
enable="NotEmpty";
22+
speechId = 0;
23+
};
24+
class FlankR {
25+
title = "<img image='AIO_AIMenu\pictures\flankR.paa'/><t font='PuristaBold'> Flank Right</t>";
26+
shortcuts[] = {4,77};
27+
command = "CMD_FLANK_RIGHT";
28+
show="1";
29+
enable="NotEmpty";
30+
speechId = 0;
31+
};
32+
class StayBack {
33+
title = "<img image='AIO_AIMenu\pictures\fallBack.paa'/><t font='PuristaBold'> Stay Back</t>";
34+
shortcuts[] = {5,80};
35+
command = "CMD_STAY_BACK";
36+
show="1";
37+
enable="NotEmpty";
38+
speechId = 0;
39+
};
40+
};
41+
};

@AIO_SPPack/addons/AIO_AIMENU/CustomMenus/formation.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ class AIO_formationSubMenu {
9898
speechId = 0;
9999
};
100100
class EchL {
101-
title = "<img color='#626262' image='AIO_AIMENU\pictures\formM.paa'/><t font='PuristaBold'> Echelon L.</t>";
101+
title = "<img color='#626262' image='AIO_AIMENU\pictures\formEchL.paa'/><t font='PuristaBold'> Echelon L.</t>";
102102
shortcuts[] = {10};
103103
shortcutsAction = "CommandingMenu9";
104104
command = "CMD_FORM_ECHLEFT";
@@ -107,7 +107,7 @@ class AIO_formationSubMenu {
107107
speechId = 0;
108108
};
109109
class EchR {
110-
title = "<img color='#626262' image='AIO_AIMENU\pictures\formM.paa'/><t font='PuristaBold'> Echelon R.</t>";
110+
title = "<img color='#626262' image='AIO_AIMENU\pictures\formEchR.paa'/><t font='PuristaBold'> Echelon R.</t>";
111111
shortcuts[] = {11};
112112
shortcutsAction = "CommandingMenu0";
113113
command = "CMD_FORM_ECHRIGHT";

@AIO_SPPack/addons/AIO_AIMENU/CustomMenus/move.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,13 +71,13 @@ class AIO_moveMenu {
7171
menu = "AIO_formationSubMenu";
7272
speechId = 0;
7373
};
74-
class Building {
75-
title = "<img color='#fffb44' image='\A3\ui_f\data\IGUI\Cfg\simpleTasks\types\getin_ca.paa'/><t font='PuristaBold'> Move into building ...</t>";
74+
class Flank {
75+
title = "<img image='AIO_AIMenu\pictures\advance.paa'/><t font='PuristaBold'> Flank</t>";
7676
shortcuts[] = {7};
7777
shortcutsAction = "CommandingMenu6";
7878
show = "1";
7979
enable = "1";
80-
menu = "#USER:AIO_moveIntoHouse_subMenu";
80+
menu = "AIO_flankMenu";
8181
speechId = 0;
8282
};
8383
};

@AIO_SPPack/addons/AIO_AIMENU/XEH_preInit.sqf

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -96,28 +96,45 @@ if !(AIO_enableMod) exitWith {};
9696

9797
["All-In-One Custom Menus","AIO_AIMENU_menu1", ["Move Menu", "Customized vanilla Move Menu. Unbind this key to disable this feature."], {
9898
private _menu = commandingMenu;
99-
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {_time = diag_tickTime; waitUntil {commandingMenu == "RscMenuMove" || diag_tickTime - _time > 1}; showCommandingMenu "AIO_moveMenu"}};
100-
}, "", [2, [false, false, false]], false] call CBA_fnc_addKeybind;
99+
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {sleep 0.001; showCommandingMenu "AIO_moveMenu"}};
100+
}, {true}, [2, [false, false, false]], false] call CBA_fnc_addKeybind;
101101
["All-In-One Custom Menus","AIO_AIMENU_menu2", ["Target Menu", "Customized vanilla Target Menu. Unbind this key to disable this feature."], {
102102
private _menu = commandingMenu;
103-
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {_time = diag_tickTime; waitUntil {commandingMenu == "#WATCH" || diag_tickTime - _time > 1}; showCommandingMenu "AIO_targetMenu"}};
104-
}, "", [3, [false, false, false]], false] call CBA_fnc_addKeybind;
103+
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {
104+
if ((_this select 1) in ((actionKeys "CommandingMenuSelect2") + (actionKeys "CommandingMenu2"))) then {
105+
[] spawn {_time = time; waitUntil {commandingMenu == "#WATCH" || (time - _time > 0.5)}; showCommandingMenu "AIO_targetMenu"};
106+
} else {
107+
[] spawn {sleep 0.001; showCommandingMenu "AIO_targetMenu"};
108+
};
109+
};
110+
}, {true}, [3, [false, false, false]], false] call CBA_fnc_addKeybind;
105111
["All-In-One Custom Menus","AIO_AIMENU_menu3", ["Attack Menu", "Customized vanilla Attack Menu. Unbind this key to disable this feature."], {
106112
private _menu = commandingMenu;
107-
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {_time = diag_tickTime; waitUntil {commandingMenu == "RscMenuEngage" || diag_tickTime - _time > 1}; showCommandingMenu "AIO_engageMenu"}};
108-
}, "", [4, [false, false, false]], false] call CBA_fnc_addKeybind;
113+
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {sleep 0.001; showCommandingMenu "AIO_engageMenu"}};
114+
}, {true}, [4, [false, false, false]], false] call CBA_fnc_addKeybind;
109115
["All-In-One Custom Menus","AIO_AIMENU_menu4", ["Mount Menu", "Customized vanilla Mount Menu. Unbind this key to disable this feature."], {
110116
private _menu = commandingMenu;
111-
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {_time = diag_tickTime; waitUntil {commandingMenu == "#GET_IN" || diag_tickTime - _time > 1}; showCommandingMenu "AIO_mountMenu"}};
112-
}, "", [5, [false, false, false]], false] call CBA_fnc_addKeybind;
117+
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {
118+
if ((_this select 1) in ((actionKeys "CommandingMenuSelect4") + (actionKeys "CommandingMenu4"))) then {
119+
[] spawn {_time = time; waitUntil {commandingMenu == "#GET_IN" || (time - _time > 0.5)}; showCommandingMenu "AIO_mountMenu"};
120+
} else {
121+
[] spawn {sleep 0.001; showCommandingMenu "AIO_mountMenu"};
122+
};
123+
};
124+
}, {true}, [5, [false, false, false]], false] call CBA_fnc_addKeybind;
113125
["All-In-One Custom Menus","AIO_AIMENU_menu6", ["Communication Menu", "Customized vanilla Communication Menu. Unbind this key to disable this feature."], {
114126
private _menu = commandingMenu;
115-
if (_menu == "RscGroupRootMenu" || {_menu == ""}) then {[] spawn {_time = diag_tickTime; waitUntil {commandingMenu == "RscMenuStatus" || diag_tickTime - _time > 1}; showCommandingMenu "AIO_commsMenu"}};
116-
}, "", [6, [false, false, false]], false] call CBA_fnc_addKeybind;
127+
if (_menu == "RscGroupRootMenu" || {_menu == ""}) then {[] spawn {sleep 0.001; showCommandingMenu "AIO_commsMenu"}};
128+
}, {true}, [6, [false, false, false]], false] call CBA_fnc_addKeybind;
117129
["All-In-One Custom Menus","AIO_AIMENU_menu5", ["Action Menu", "Customized vanilla Action Menu. Unbind this key to disable this feature."], {
118130
private _menu = commandingMenu;
119-
if (_menu == "RscGroupRootMenu" || {_menu == ""}) then {[] spawn {_time = diag_tickTime; waitUntil {commandingMenu == "#ACTION" || diag_tickTime - _time > 1}; showCommandingMenu "#USER:AIO_action_subMenu"}};
120-
}, "", [7, [false, false, false]], false] call CBA_fnc_addKeybind;
131+
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {sleep 0.001; showCommandingMenu "#USER:AIO_action_subMenu"}};
132+
}, {true}, [7, [false, false, false]], false] call CBA_fnc_addKeybind;
133+
134+
["All-In-One Custom Menus","AIO_AIMENU_menu8", ["Formation Menu", "Customized vanilla Formation Menu. Unbind this key to disable this feature."], {
135+
private _menu = commandingMenu;
136+
if (_menu == "RscGroupRootMenu" || {_menu == "" && {count (groupSelectedUnits player) != 0}}) then {[] spawn {sleep 0.001; showCommandingMenu "AIO_formationSubMenu"}};
137+
}, {true}, [9, [false, false, false]], false] call CBA_fnc_addKeybind;
121138

122139
["All-In-One Command Menu","AIO_AIMENU_FireOnMyLead", "Fire On My Lead", {
123140
if (player != leader player) exitWith {};

@AIO_SPPack/addons/AIO_AIMENU/config.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ class Extended_PreInit_EventHandlers
2727
#include "CustomMenus\formation.hpp"
2828
#include "CustomMenus\combatMode.hpp"
2929
#include "CustomMenus\engageSubMenu.hpp"
30+
#include "CustomMenus\flank.hpp"
3031
#include "ui\defines.hpp"
3132
#include "ui\RscTitles.hpp"
3233
#include "ui\waypointUI.hpp"

@AIO_SPPack/addons/AIO_AIMENU/functions/cheats/fn_addAmmo.sqf

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,36 +29,56 @@ if (_type == 4) exitWith {
2929
};
3030

3131
_wpnType = "";
32+
_magType = "";
3233
_cnt = 1;
3334
call {
3435
if (_type == 0) exitWith {
3536
_wpnType = "primaryWeapon";
37+
_magType = "primaryWeaponMagazine";
3638
_cnt = 2;
3739
};
3840

3941
if (_type == 1) exitWith {
4042
_wpnType = "handgunWeapon";
43+
_magType = "handgunMagazine";
4144
};
4245

4346
if (_type == 2) exitWith {
4447
_wpnType = "secondaryWeapon";
48+
_magType = "secondaryWeaponMagazine";
4549
};
4650
};
4751

4852
_cfgWeapons = configFile >> "cfgWeapons";
53+
_cfgMags = configFile >> "cfgMagazines";
4954
{
5055
_unit = _x;
5156
_weapon = call compile format ["%1 _unit", _wpnType];
5257
if (_weapon != "") then {
5358
_muzzles = (getArray(_cfgWeapons >> _weapon >> "muzzles")) select {_x != "this"};
54-
_mags = getArray(_cfgWeapons >> _weapon >> "magazines");
55-
_mag = selectRandom _mags;
59+
_preferedMag = call compile format ["%1 _unit", _magType];
60+
_compatibleMags = getArray(_cfgWeapons >> _weapon >> "magazines");
61+
_mag = if !(_preferedMag isEqualTo []) then {
62+
_preferedMag = _preferedMag select {_x in _compatibleMags};
63+
if (count _preferedMag != 0) then {
64+
_preferedMag = _preferedMag select 0;
65+
_ammoCnt = getNumber(_cfgMags >> _preferedMag >> "Count");
66+
_unit setAmmo [_weapon, _ammoCnt];
67+
_preferedMag
68+
} else {
69+
selectRandom _compatibleMags
70+
}
71+
} else {
72+
selectRandom _compatibleMags
73+
};
5674
_unit addMagazines [_mag, _cnt];
5775
{
5876
_mags = getArray(_cfgWeapons >> _weapon >> _x >> "magazines");
59-
_ideal = _mags select {(["HE", _x, true] call BIS_fnc_inString) || {(["AP", _x, true] call BIS_fnc_inString)}};
60-
_mag = if !(_ideal isEqualTo []) then {selectRandom _ideal} else {selectRandom _mags};
61-
_unit addMagazines [_mag, _cnt];
77+
if (count _mags != 0) then {
78+
_ideal = _mags select {(["HE", _x, true] call BIS_fnc_inString) || {(["AP", _x, true] call BIS_fnc_inString)}};
79+
_mag = if !(_ideal isEqualTo []) then {selectRandom _ideal} else {selectRandom _mags};
80+
_unit addMagazines [_mag, _cnt];
81+
};
6282
} forEach _muzzles;
6383
};
6484
} forEach _units;

@AIO_SPPack/addons/AIO_AIMENU/functions/cheats/fn_fullHeal.sqf

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,14 @@ params ["_units"];
22
_units pushBack player;
33
{
44
_unit = _x;
5-
{
6-
_x setDamage 0;
7-
_x setUnconscious false;
8-
} forEach [_unit, vehicle _unit];
5+
if (_unit == player && {lifeState player == "INCAPACITATED" || player getVariable ["ACE_isUnconscious", false]}) then {
6+
("BlackScreen" call BIS_fnc_rscLayer) cutFadeOut 01;
7+
if !(isNil "AIO_ppColor") then {{ppEffectDestroy _x} forEach [AIO_ppColor, AIO_ppVig, AIO_ppDynBlur, AIO_ppRadBlur]};
8+
};
9+
_unit setUnconscious false;
10+
_unit setCaptive false;
11+
_unit setDamage 0;
12+
(vehicle _unit) setDamage 0;
913
if (AIO_UseAceMedical) then {
1014
_unit setVariable ["ACE_MEDICAL_pain", 0, true];
1115
_unit setVariable ["ACE_MEDICAL_morphine", 0, true];
@@ -52,6 +56,7 @@ _units pushBack player;
5256
{
5357
_unit setVariable [_x select 0, nil];
5458
} forEach _allUsedMedication;
55-
}
59+
};
60+
5661
} forEach _units;
5762

@AIO_SPPack/addons/AIO_AIMENU/functions/driver/fn_createDriver.sqf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ if (_veh isKindOf "Air") exitWith {
3636
};
3737

3838
[[player],1,-1] call AIO_fnc_switchSeat;
39-
sleep 0.001;
39+
40+
if (canSuspend) then {sleep 0.001};
4041

4142
_fullCrew = fullCrew [_veh, "", false];
4243
_unitSeat = _fullCrew findIf {_x select 0 == _unit};

0 commit comments

Comments
 (0)