mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-13 19:52:38 +03:00
Add handling for a missing description on backpacks
This commit is contained in:
@@ -19813,6 +19813,13 @@
|
||||
<Dutch>Grote Wapenzak <br/>Inhoud: 70 liter</Dutch>
|
||||
<French>Grand Fourreau <br/>Taille: 70</French>
|
||||
</Key>
|
||||
<Key ID="STR_BACKPACK_NO_DESC">
|
||||
<English>%1 <br/>Capacity: %2 items</English>
|
||||
<German>%1 <br/>Volumen: %2 Liter</German>
|
||||
<Russian>%1 %2 слотов</Russian>
|
||||
<Dutch>%1 <br/>Inhoud: %2 liter</Dutch>
|
||||
<French>%1 <br/>Taille: %2</French>
|
||||
</Key>
|
||||
|
||||
<Key ID="STR_EPOCH_ACTIONS_HALO">
|
||||
<English>HALO Jump</English>
|
||||
|
||||
@@ -207,7 +207,15 @@ HG_itemDescription = {
|
||||
|
||||
if (_inputItem call HG_isBackpack) then {
|
||||
_name = getText(configfile >> "cfgVehicles" >> _inputItem >> "descriptionShort");
|
||||
_return = ( _name);
|
||||
|
||||
if (_name == "") then {
|
||||
private ["_displayname","_capacity"];
|
||||
|
||||
_displayname = getText(configfile >> "cfgVehicles" >> _inputItem >> "displayname");
|
||||
_capacity = getNumber(configfile >> "cfgVehicles" >> _inputItem >> "transportMaxMagazines");
|
||||
_name = [_displayname,format[localize "STR_BACKPACK_NO_DESC",_displayname,_capacity]] select (_capacity > 0);
|
||||
};
|
||||
_return = (_name);
|
||||
};
|
||||
|
||||
_return
|
||||
|
||||
Reference in New Issue
Block a user