From 17daea0ff8909fa5814f9ccea88daae1f26428e2 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Mon, 23 Oct 2023 11:53:28 -0500 Subject: [PATCH] Repair - Fix displayed text when repairing lights (#9555) --- .../functions/fnc_getHitPointString.sqf | 3 ++ addons/repair/initSettings.sqf | 9 +++-- addons/repair/stringtable.xml | 40 +++++++++++++------ 3 files changed, 36 insertions(+), 16 deletions(-) diff --git a/addons/repair/functions/fnc_getHitPointString.sqf b/addons/repair/functions/fnc_getHitPointString.sqf index 7845dc7208..5611a6f4e3 100644 --- a/addons/repair/functions/fnc_getHitPointString.sqf +++ b/addons/repair/functions/fnc_getHitPointString.sqf @@ -36,6 +36,9 @@ if (_track) then { //IGNORE_STRING_WARNING(str_ace_repair_hit); private _text = LSTRING(Hit); +// Remove # prefix +if ((_hitpoint select [0, 1]) == "#") then { _hitPoint = _hitPoint select [1] }; + // Remove "Hit" from hitpoint name if one exists private _toFind = if ((toLower _hitPoint) find "hit" == 0) then { [_hitPoint, 3] call CBA_fnc_substr diff --git a/addons/repair/initSettings.sqf b/addons/repair/initSettings.sqf index 3ba13e9ee6..26d502e757 100644 --- a/addons/repair/initSettings.sqf +++ b/addons/repair/initSettings.sqf @@ -1,4 +1,5 @@ private _category = format ["ACE %1", LLSTRING(Repair)]; +private _catFullRepair = [_category, LLSTRING(fullRepair)]; [ QGVAR(enabled), "CHECKBOX", @@ -102,7 +103,7 @@ private _category = format ["ACE %1", LLSTRING(Repair)]; [ QGVAR(fullRepairLocation), "LIST", [LSTRING(fullRepairLocation), LSTRING(fullRepairLocation_description)], - _category, + _catFullRepair, [[0,1,2,3,4],[LSTRING(useAnywhere), LSTRING(repairVehicleOnly), LSTRING(repairFacilityOnly), LSTRING(vehicleAndFacility), ELSTRING(common,Disabled)],2], // [values, titles, defaultIndex] true, // isGlobal {[QGVAR(fullRepairLocation), _this] call EFUNC(common,cbaSettings_settingChanged)} @@ -111,7 +112,7 @@ private _category = format ["ACE %1", LLSTRING(Repair)]; [ QGVAR(engineerSetting_fullRepair), "LIST", [LSTRING(engineerSetting_fullRepair_name), LSTRING(engineerSetting_fullRepair_description)], - _category, + _catFullRepair, [[0,1,2],[LSTRING(engineerSetting_anyone), LSTRING(engineerSetting_EngineerOnly), LSTRING(engineerSetting_AdvancedOnly)],2], // [values, titles, defaultIndex] true, // isGlobal {[QGVAR(engineerSetting_fullRepair), _this] call EFUNC(common,cbaSettings_settingChanged)} @@ -120,7 +121,7 @@ private _category = format ["ACE %1", LLSTRING(Repair)]; [ QGVAR(timeCoefficientFullRepair), "SLIDER", [LSTRING(timeCoefficientFullRepair_name), LSTRING(timeCoefficientFullRepair_description)], - _category, + _catFullRepair, [0,3,1.5,2], true ] call CBA_fnc_addSetting; @@ -157,7 +158,7 @@ private _category = format ["ACE %1", LLSTRING(Repair)]; QGVAR(fullRepairRequiredItems), "LIST", [LSTRING(FullRepairRequiredItems_DisplayName), LSTRING(FullRepairRequiredItems_Description)], - _category, + _catFullRepair, [[[], [ANY_TOOLKIT_FAKECLASS]], ["STR_A3_None", "STR_A3_CfgWeapons_Toolkit0"], 1], true ] call CBA_fnc_addSetting; diff --git a/addons/repair/stringtable.xml b/addons/repair/stringtable.xml index c1afbdec17..215e17e947 100644 --- a/addons/repair/stringtable.xml +++ b/addons/repair/stringtable.xml @@ -505,19 +505,19 @@ 完整維修部分 - Partially repaired %1 + Partially repaired part Bauteil zum Teil repariert - Częściowo naprawiono: %1 - %1 parcialmente reparado - Частично отремонтировано: %1 - Parcialmente reparada %1 - %1 - částečně opraveno - %1 parzialmente riparato - %1 partiellement réparé(e). - %1 を部分的に修理しました - %1 부분적으로 수리됨 - %1已完成部分维修 - %1已完成部分維修 + Częściowo naprawiono część + Parte parcialmente reparado + Частично отремонтировано часть + Parcialmente reparada parte + Díl částečně opraveno + Parte parzialmente riparato + Pièce partiellement réparé(e). + 部品 を部分的に修理しました + 부품 부분적으로 수리됨 + 零件已完成部分维修 + 零件已完成部分維修 Fully repaired %1 @@ -583,6 +583,22 @@ 車殼 Gövde + + Light + + Léger + Claro + Chiaro + Light + Светлый + Hell + Světlá + Claro + 밝은 + 轻型 + + Işık + Engine Motor