Files
DayZ-Epoch/SQF/dayz_code/actions/AdvancedTrading/functions/z_at_getGearItems.sqf
ebaydayz 8d82693c1b More Advanced Trading localization
Russian translations provided by Epoch forums user koms:
http://epochmod.com/forum/profile/33066-koms/
2016-05-02 17:32:27 -04:00

31 lines
830 B
Plaintext

/**
* call Z_getBackpackItems
*
* Gets all your items stored in your gear and innitiates the selling list.
**/
private ["_mags","_weaps","_skin","_formattedText","_icon"];
#include "defines.sqf";
call Z_clearLists;
Z_SellArray = [];
Z_SellableArray = [];
_mags = magazines player;
_weaps = weapons player;
_skin = typeOf player;
_pic = getText (configFile >> 'CfgVehicles' >> _skin >> 'picture');
_icon = getText (configFile >> 'CfgVehicles' >> _skin >> 'icon');
if (!isNil '_pic' && _pic == "") then {
_pic = _icon;
};
_formattedText = format [
"<t size='1' align='center' color='#ffffff'> %2 </t>"
, _pic, localize "STR_UI_GEAR"
];
(findDisplay Z_AT_DIALOGWINDOW displayCtrl Z_AT_CONTAINERINFO) ctrlSetStructuredText parseText _formattedText;
[_weaps,_mags,localize "STR_EPOCH_YOUR_GEAR"] call Z_checkArrayInConfig;