diff --git a/addons/common/functions/fnc_progressBar.sqf b/addons/common/functions/fnc_progressBar.sqf
index 9b52796569..6639b21948 100644
--- a/addons/common/functions/fnc_progressBar.sqf
+++ b/addons/common/functions/fnc_progressBar.sqf
@@ -44,7 +44,7 @@ _ctrlPos set [1, ((0 + 29 * GVAR(settingProgressBarLocation)) * ((((safezoneW /
(uiNamespace getVariable QGVAR(ctrlProgressBarTitle)) ctrlCommit 0;
[{
- (_this select 0) params ["_args", "_onFinish", "_onFail", "_condition", "_player", "_startTime", "_totalTime", "_exceptions"];
+ (_this select 0) params ["_args", "_onFinish", "_onFail", "_condition", "_player", "_startTime", "_totalTime", "_exceptions", "_title"];
private _elapsedTime = CBA_missionTime - _startTime;
private _errorCode = -1;
@@ -95,6 +95,16 @@ _ctrlPos set [1, ((0 + 29 * GVAR(settingProgressBarLocation)) * ((((safezoneW /
};
} else {
//Update Progress Bar (ratio of elepased:total)
- (uiNamespace getVariable QGVAR(ctrlProgressBar)) progressSetPosition (_elapsedTime / _totalTime);
+ private _ratio = _elapsedTime / _totalTime;
+ (uiNamespace getVariable QGVAR(ctrlProgressBar)) progressSetPosition _ratio;
+ switch (GVAR(progressBarInfo)) do {
+ case 0: {};
+ case 1: {
+ (uiNamespace getVariable QGVAR(ctrlProgressBarTitle)) ctrlSetText (_title + format [" (%1", floor (_ratio * 100)] + "%)");
+ };
+ case 2: {
+ (uiNamespace getVariable QGVAR(ctrlProgressBarTitle)) ctrlSetText (_title + " " + format [localize LSTRING(TimeLeft), ceil (_totalTime - _elapsedTime)]);
+ };
+ };
};
-}, 0, [_args, _onFinish, _onFail, _condition, _player, CBA_missionTime, _totalTime, _exceptions]] call CBA_fnc_addPerFrameHandler;
+}, 0, [_args, _onFinish, _onFail, _condition, _player, CBA_missionTime, _totalTime, _exceptions, _localizedTitle]] call CBA_fnc_addPerFrameHandler;
diff --git a/addons/common/initSettings.sqf b/addons/common/initSettings.sqf
index c7b06f5160..02032a629f 100644
--- a/addons/common/initSettings.sqf
+++ b/addons/common/initSettings.sqf
@@ -25,3 +25,12 @@
false,
2
] call CBA_fnc_addSetting;
+
+[
+ QGVAR(progressBarInfo),
+ "LIST",
+ [LSTRING(progressBarInfoName), LSTRING(progressBarInfoDesc)],
+ format ["ACE %1", localize LSTRING(DisplayName)],
+ [[0, 1, 2], [LSTRING(None), LSTRING(progressBarInfoPercentage), LSTRING(progressBarInfoTime)], 2],
+ 0
+] call CBA_fnc_addSetting;
diff --git a/addons/common/stringtable.xml b/addons/common/stringtable.xml
index a6a0659665..8a1f8ba0fe 100644
--- a/addons/common/stringtable.xml
+++ b/addons/common/stringtable.xml
@@ -1470,5 +1470,36 @@
Both
İkisi de
+
+ Additional progress bar information
+
+
+ Controls extra information shown in progress bar.
+
+
+ Percentage
+
+
+ Time remaining
+
+
+ None
+ Žádná
+ Keine
+ Нет
+ Brak
+ Nessuna
+ Nada
+ Aucune
+ 無
+ なし
+ 활성화 없음
+ Nenhuma
+ 无
+ Yok
+
+
+ Time left: %1s
+