@@ -19,17 +19,13 @@ params ["_object"];
19
19
20
20
if (! createDialog QGVAR(display)) exitWith {};
21
21
22
- private _config = configOf _object ;
23
- private _displayName = getText (_config >> " displayName" );
24
- private _maximumLoad = getNumber (_config >> " maximumLoad" );
25
-
26
22
// Get the object's current cargo and calculate its load
27
23
private _cargo = [getItemCargo _object , getWeaponCargo _object , getMagazineCargo _object , getBackpackCargo _object ];
28
24
private _currentLoad = [_cargo ] call FUNC(calculateLoad);
29
25
30
26
private _display = uiNamespace getVariable QEGVAR(common,display);
31
27
_display setVariable [QGVAR(currentLoad), _currentLoad ];
32
- _display setVariable [QGVAR(maximumLoad), _maximumLoad ];
28
+ _display setVariable [QGVAR(maximumLoad), maxLoad _object ];
33
29
_display setVariable [QGVAR(object), _object ];
34
30
_display setVariable [QGVAR(cargo), _cargo ];
35
31
@@ -38,7 +34,7 @@ _display setVariable [QGVAR(cargo), _cargo];
38
34
39
35
// Set the display's title to the object name
40
36
private _ctrlTitle = _display displayCtrl IDC_TITLE;
41
- _ctrlTitle ctrlSetText toUpper format [localize LSTRING (EditInventory), _displayName ];
37
+ _ctrlTitle ctrlSetText toUpper format [LLSTRING (EditInventory), getText ( configOf _object >> " displayName " ) ];
42
38
43
39
// Refresh the items list when category is changed
44
40
private _ctrlCategory = _display displayCtrl IDC_CATEGORY;
0 commit comments