User Interface - Add ability to hide Default Action Icon (#8883)

This commit is contained in:
jonpas 2022-05-05 00:28:32 +02:00 committed by GitHub
parent 67842a2656
commit e2a822c828
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 26 additions and 1 deletions

View File

@ -0,0 +1,5 @@
class CfgInGameUI {
class DefaultAction {
size = QUOTE(profileNamespace getVariable [ARR_2('GVAR(hideDefaultActionIcon)', (((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 0.8))]);
};
};

View File

@ -15,6 +15,7 @@ class CfgPatches {
};
#include "CfgEventHandlers.hpp"
#include "CfgInGameUI.hpp"
#include "CfgVehicles.hpp"
#include "ACE_Settings.hpp"
#include "ACE_UI.hpp"

View File

@ -294,7 +294,7 @@ if (productVersion select 4 == 'Development') then {
QGVAR(enableSpeedIndicator),
"CHECKBOX",
[LSTRING(EnableSpeedIndicator), LSTRING(EnableSpeedIndicator_Description)],
"ACE " + LLSTRING(Category),
_category,
true,
true, {
if (!_this) then {
@ -303,3 +303,16 @@ if (productVersion select 4 == 'Development') then {
};
}
] call CBA_fnc_addSetting;
[
QGVAR(hideDefaultActionIcon),
"CHECKBOX",
[LSTRING(HideDefaultActionIcon), LSTRING(HideDefaultActionIcon_Description)],
_category,
false,
2, {
profileNamespace setVariable [QGVAR(hideDefaultActionIcon), [nil, 0] select _this];
saveProfileNamespace;
},
true // needs restart
] call CBA_fnc_addSetting;

View File

@ -688,5 +688,11 @@
<Chinesesimp>为玩家角色启用移动速度指示器。</Chinesesimp>
<Korean>플레이어 캐릭터를 위한 이동속도 표시기를 활성화 합니다.</Korean>
</Key>
<Key ID="STR_ACE_UI_HideDefaultActionIcon">
<English>Hide Default Action Icon</English>
</Key>
<Key ID="STR_ACE_UI_HideDefaultActionIcon_Description">
<English>Hides the icon shown automatically when something is in front of the cursor. Requires a game restart.\nWarning: Does not remove the action itself! It is advisable to unbind 'Use default action' key to prevent unwanted interactions.</English>
</Key>
</Package>
</Project>