mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
convert log macros to cba versions (#4282)
* convert log macros to cba versions * Add changes to AB * remove obsolete macro
This commit is contained in:
@ -23,13 +23,13 @@
|
||||
|
||||
private _elements = getArray (_x >> "elements");
|
||||
if (_elements isEqualTo []) then {
|
||||
ACE_LOGERROR_1("Failed compiling ACE_UI for Element: %1 - missing elements",_class);
|
||||
ERROR_1("Failed compiling ACE_UI for Element: %1 - missing elements",_class);
|
||||
_failure = true;
|
||||
};
|
||||
|
||||
private _location = getNumber (_x >> "location");
|
||||
if !(_location in [ANYWHERE, GROUND_ONLY, VEHICLE_ONLY]) then {
|
||||
ACE_LOGERROR_2("Failed compiling ACE_UI for Element: %1 - missing or invalid location %2",_class,_location);
|
||||
ERROR_2("Failed compiling ACE_UI for Element: %1 - missing or invalid location %2",_class,_location);
|
||||
_failure = true;
|
||||
};
|
||||
|
||||
|
@ -23,7 +23,7 @@ if (!_activated) exitWith {};
|
||||
// Basic
|
||||
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!");
|
||||
INFO("User Interface Module Failed to Initialize Basic settings - showHUD overriden in mission config!");
|
||||
} else {
|
||||
[_logic, QGVAR(soldierVehicleWeaponInfo), "soldierVehicleWeaponInfo"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(vehicleRadar), "vehicleRadar"] call EFUNC(common,readSettingFromModule);
|
||||
@ -63,4 +63,4 @@ if (isArray (missionConfigFile >> "showHUD")) then {
|
||||
[_logic, QGVAR(vehicleDamage), "vehicleDamage"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(vehicleInfoBackground), "vehicleInfoBackground"] call EFUNC(common,readSettingFromModule);
|
||||
|
||||
ACE_LOGINFO_1("User Interface Module Initialized. Allow client modifications: %1",GVAR(allowSelectiveUI));
|
||||
INFO_1("User Interface Module Initialized. Allow client modifications: %1",GVAR(allowSelectiveUI));
|
||||
|
@ -40,7 +40,7 @@ if ((_canUseWeapon && {_location == 2}) || {!_canUseWeapon && {_location == 1}})
|
||||
// Display and print info which component forced the element except for default vehicle check
|
||||
if (_showHint) then {
|
||||
[LSTRING(Disabled), 2] call EFUNC(common,displayTextStructured);
|
||||
ACE_LOGINFO_2("Attempted modification of a forced User Interface element '%1' by '%2'.",_element,_x select 1);
|
||||
INFO_2("Attempted modification of a forced User Interface element '%1' by '%2'.",_element,_x select 1);
|
||||
};
|
||||
_show = false;
|
||||
};
|
||||
@ -53,7 +53,7 @@ if (!_force) then {
|
||||
_setElement params ["_sourceSet", "_showSet"];
|
||||
if (_showHint) then {
|
||||
[LSTRING(Disabled), 2] call EFUNC(common,displayTextStructured);
|
||||
ACE_LOGINFO_2("Attempted modification of a forced User Interface element '%1' by '%2'.",_element,_sourceSet);
|
||||
INFO_2("Attempted modification of a forced User Interface element '%1' by '%2'.",_element,_sourceSet);
|
||||
};
|
||||
_show = _showSet;
|
||||
};
|
||||
|
@ -26,7 +26,7 @@ params [
|
||||
];
|
||||
|
||||
if (_source == "" || {_element == ""}) exitWith {
|
||||
ACE_LOGWARNING("Source or Element may not be empty strings!");
|
||||
WARNING("Source or Element may not be empty strings!");
|
||||
};
|
||||
|
||||
_element = toLower _element;
|
||||
@ -34,7 +34,7 @@ _element = toLower _element;
|
||||
// Verify element is bound
|
||||
private _cachedElement = GVAR(configCache) getVariable _element;
|
||||
if (isNil "_cachedElement") exitWith {
|
||||
ACE_LOGWARNING_2("Element '%1' does not exist - modification by '%2' failed.",_element,_source);
|
||||
WARNING_2("Element '%1' does not exist - modification by '%2' failed.",_element,_source);
|
||||
};
|
||||
|
||||
private _setElement = GVAR(elementsSet) getVariable _element;
|
||||
@ -53,7 +53,7 @@ if (isNil "_setElement") then {
|
||||
|
||||
if (_set) then {
|
||||
if (GVAR(interfaceInitialized)) then {
|
||||
ACE_LOGWARNING_3("Element '%1' already set by '%2' - modification by '%3' failed.",_element,_sourceSet,_source);
|
||||
WARNING_3("Element '%1' already set by '%2' - modification by '%3' failed.",_element,_sourceSet,_source);
|
||||
};
|
||||
} else {
|
||||
TRACE_3("Unsetting element",_sourceSet,_element,_show);
|
||||
|
Reference in New Issue
Block a user