mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-14 12:12:34 +03:00
Add back R3F weight text in object_monitorGear
The size of control 1001 was shortened in 1.8.7, so it is better to set it on control 156. The initial text is always blank for that control when cursorTarget isNull. Showing the weight carried when looking at an object or vehicle is not necessary. It cuts off with long vehicle names anyway.
This commit is contained in:
@@ -103,5 +103,13 @@ if (!(isNull (findDisplay 106))) then {
|
|||||||
(_display displayCtrl (_imageIDCs select _i)) ctrlShow false;
|
(_display displayCtrl (_imageIDCs select _i)) ctrlShow false;
|
||||||
(_display displayCtrl (_valueIDCs select _i)) ctrlShow false;
|
(_display displayCtrl (_valueIDCs select _i)) ctrlShow false;
|
||||||
};
|
};
|
||||||
|
if (isNull _object) then {
|
||||||
|
while {!(isNull (findDisplay 106))} do {
|
||||||
|
R3F_Weight = call R3F_WEIGHT_FNCT_GetWeight;
|
||||||
|
_control = _display displayCtrl 156;
|
||||||
|
_control ctrlSetText format[localize "STR_R3F_WEIGHT_InGearBox",R3F_Weight];
|
||||||
|
uiSleep 1;
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -31,14 +31,8 @@ while {true} do
|
|||||||
_gearbox_visible = false;
|
_gearbox_visible = false;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if(_gearbox_visible) then {
|
if (_gearbox_visible) then {
|
||||||
R3F_Weight = call R3F_WEIGHT_FNCT_GetWeight;
|
//Moved code to object_monitorGear.sqf
|
||||||
if(_initial_text == "") then {
|
|
||||||
_control = _display displayCtrl ARMA2_CAPTIONGEARBOX;
|
|
||||||
_initial_text = ctrlText _control ;
|
|
||||||
};
|
|
||||||
_control = _display displayCtrl ARMA2_CAPTIONGEARBOX;
|
|
||||||
_control ctrlSetText format[localize "STR_R3F_WEIGHT_InGearBox",_initial_text,R3F_Weight];
|
|
||||||
_n = 0;
|
_n = 0;
|
||||||
}else{
|
}else{
|
||||||
if( _n > R3F_WEIGHT_LONG_DELAY) then {
|
if( _n > R3F_WEIGHT_LONG_DELAY) then {
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ R3F_WEIGHT_FNCT_GetItemWeight = {
|
|||||||
_total_weight = _total_weight + _weight;
|
_total_weight = _total_weight + _weight;
|
||||||
} else {
|
} else {
|
||||||
// log only if not found
|
// log only if not found
|
||||||
diag_log format["No R3F weight config for: %1", _x];
|
//diag_log format["No R3F weight config for: %1", _x];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -13773,13 +13773,13 @@
|
|||||||
<Czech>Opustili jste %1</Czech>
|
<Czech>Opustili jste %1</Czech>
|
||||||
</Key>
|
</Key>
|
||||||
<Key ID="STR_R3F_WEIGHT_InGearBox">
|
<Key ID="STR_R3F_WEIGHT_InGearBox">
|
||||||
<English>%1 | Weight carried : %2 lb</English>
|
<English>Weight carried : %1 lb</English>
|
||||||
<German>%1 | Getragenes Gewicht : %2 Kg</German>
|
<German>Getragenes Gewicht : %1 Kg</German>
|
||||||
<Russian>%1 | Переносимый вес : %2 Кг</Russian>
|
<Russian>Переносимый вес : %1 Кг</Russian>
|
||||||
<Spanish>%1 | Weight carried : %2 Kg</Spanish>
|
<Spanish>Weight carried : %1 Kg</Spanish>
|
||||||
<Dutch>%1 | Dragend gewicht : %2 Kg</Dutch>
|
<Dutch>Dragend gewicht : %1 Kg</Dutch>
|
||||||
<French>%1 | Poids transporté : %2 Kg</French>
|
<French>Poids transporté : %1 Kg</French>
|
||||||
<Czech>%1 | Nesená váha : %2 Kg</Czech>
|
<Czech>Nesená váha : %1 Kg</Czech>
|
||||||
</Key>
|
</Key>
|
||||||
<Key ID="STR_R3F_WEIGHT_English">
|
<Key ID="STR_R3F_WEIGHT_English">
|
||||||
<English>lb</English>
|
<English>lb</English>
|
||||||
|
|||||||
Reference in New Issue
Block a user