mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-13 19:52:38 +03:00
@@ -39,7 +39,7 @@ _totalPrice = 0;
|
|||||||
_processGear = {
|
_processGear = {
|
||||||
private ["_configType","_passedType","_cat","_pic","_text","_sell","_buy","_buyCurrency","_sellCurrency","_worth"];
|
private ["_configType","_passedType","_cat","_pic","_text","_sell","_buy","_buyCurrency","_sellCurrency","_worth"];
|
||||||
|
|
||||||
_passedType = _this select 1;
|
_passedType = _this select 1; //Check for items that have the same magazine and weapon classname (PipeBomb, Stinger, Igla, etc.)
|
||||||
{
|
{
|
||||||
_y = _x;
|
_y = _x;
|
||||||
_swap = false;
|
_swap = false;
|
||||||
@@ -52,7 +52,7 @@ _processGear = {
|
|||||||
_swap2 = true;
|
_swap2 = true;
|
||||||
};
|
};
|
||||||
{
|
{
|
||||||
_cat = format["Category_%1",(_arrayOfTraderCat select _forEachIndex select 1)];
|
_cat = format["Category_%1",(_x select 1)];
|
||||||
if (isNumber (missionConfigFile >> "CfgTraderCategory" >> _cat >> "duplicate")) then {
|
if (isNumber (missionConfigFile >> "CfgTraderCategory" >> _cat >> "duplicate")) then {
|
||||||
_cat = format["Category_%1",getNumber (missionConfigFile >> "CfgTraderCategory" >> _cat >> "duplicate")];
|
_cat = format["Category_%1",getNumber (missionConfigFile >> "CfgTraderCategory" >> _cat >> "duplicate")];
|
||||||
};
|
};
|
||||||
@@ -60,7 +60,7 @@ _processGear = {
|
|||||||
//Use base vehicle prices for upgraded _DZE[1-4] variants only if they are not explicitly added in trader config
|
//Use base vehicle prices for upgraded _DZE[1-4] variants only if they are not explicitly added in trader config
|
||||||
_y = _baseVehicle;
|
_y = _baseVehicle;
|
||||||
};
|
};
|
||||||
if (isClass(missionConfigFile >> "CfgTraderCategory" >> _cat >> _y)) exitWith {
|
if (isClass(missionConfigFile >> "CfgTraderCategory" >> _cat >> _y) && {_passedType in ["find",(getText(missionConfigFile >> "CfgTraderCategory" >> _cat >> _y >> "type"))]}) exitWith {
|
||||||
_pic = "";
|
_pic = "";
|
||||||
_text = "";
|
_text = "";
|
||||||
_configType = getText(missionConfigFile >> "CfgTraderCategory" >> _cat >> _y >> "type");
|
_configType = getText(missionConfigFile >> "CfgTraderCategory" >> _cat >> _y >> "type");
|
||||||
@@ -95,7 +95,7 @@ _processGear = {
|
|||||||
};
|
};
|
||||||
if (Z_SellingFrom != 2) then {_HasKey = false;}; //Only allow selling vehicle from gear
|
if (Z_SellingFrom != 2) then {_HasKey = false;}; //Only allow selling vehicle from gear
|
||||||
};
|
};
|
||||||
if (_passedType != _configType or !_HasKey) exitWith {};
|
if (!_HasKey) exitWith {};
|
||||||
|
|
||||||
_worth = 0;
|
_worth = 0;
|
||||||
_currencyQty = _buy select 0;
|
_currencyQty = _buy select 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user