From 13a8cac7c7cff732e226465e5cb220b51f1a57ab Mon Sep 17 00:00:00 2001 From: dayz10k Date: Fri, 22 Nov 2013 15:13:07 -0500 Subject: [PATCH 01/11] #761 allow owner to remove modular(no refund, no rubble) --- SQF/dayz_code/compile/fn_selfActions.sqf | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/SQF/dayz_code/compile/fn_selfActions.sqf b/SQF/dayz_code/compile/fn_selfActions.sqf index 31c821005..195205689 100644 --- a/SQF/dayz_code/compile/fn_selfActions.sqf +++ b/SQF/dayz_code/compile/fn_selfActions.sqf @@ -4,7 +4,7 @@ scriptName "Functions\misc\fn_selfActions.sqf"; - Function - [] call fnc_usec_selfActions; ************************************************************/ -private ["_isWreckBuilding","_temp_keys","_magazinesPlayer","_isPZombie","_vehicle","_inVehicle","_hasFuelE","_hasRawMeat","_hasKnife","_hasToolbox","_onLadder","_nearLight","_canPickLight","_canDo","_text","_isHarvested","_isVehicle","_isVehicletype","_isMan","_traderType","_ownerID","_isAnimal","_isDog","_isZombie","_isDestructable","_isTent","_isFuel","_isAlive","_Unlock","_lock","_buy","_dogHandle","_lieDown","_warn","_hastinitem","_allowedDistance","_menu","_menu1","_humanity_logic","_low_high","_cancel","_metals_trader","_traderMenu","_isWreck","_isRemovable","_isDisallowRepair","_rawmeat","_humanity","_speed","_dog","_hasbottleitem","_isAir","_isShip","_playersNear","_findNearestGens","_findNearestGen","_IsNearRunningGen","_cursorTarget","_isnewstorage","_itemsPlayer","_ownerKeyId","_typeOfCursorTarget","_hasKey","_oldOwner","_combi","_key_colors","_player_deleteBuild","_player_flipveh","_player_lockUnlock_crtl","_player_butcher","_player_studybody","_player_cook","_player_boil","_hasFuelBarrelE","_hasHotwireKit","_player_SurrenderedGear","_isSurrendered","_resultKeyname","_ownerIDname"]; +private ["_isWreckBuilding","_temp_keys","_magazinesPlayer","_isPZombie","_vehicle","_inVehicle","_hasFuelE","_hasRawMeat","_hasKnife","_hasToolbox","_onLadder","_nearLight","_canPickLight","_canDo","_text","_isHarvested","_isVehicle","_isVehicletype","_isMan","_traderType","_ownerID","_isAnimal","_isDog","_isZombie","_isDestructable","_isTent","_isFuel","_isAlive","_Unlock","_lock","_buy","_dogHandle","_lieDown","_warn","_hastinitem","_allowedDistance","_menu","_menu1","_humanity_logic","_low_high","_cancel","_metals_trader","_traderMenu","_isWreck","_isRemovable","_isDisallowRepair","_rawmeat","_humanity","_speed","_dog","_hasbottleitem","_isAir","_isShip","_playersNear","_findNearestGens","_findNearestGen","_IsNearRunningGen","_cursorTarget","_isnewstorage","_itemsPlayer","_ownerKeyId","_typeOfCursorTarget","_hasKey","_oldOwner","_combi","_key_colors","_player_deleteBuild","_player_flipveh","_player_lockUnlock_crtl","_player_butcher","_player_studybody","_player_cook","_player_boil","_hasFuelBarrelE","_hasHotwireKit","_player_SurrenderedGear","_isSurrendered","_resultKeyname","_ownerIDname","_isModular"]; if (TradeInprogress) exitWith {}; // Do not allow if any script is running. @@ -153,6 +153,7 @@ if (!isNull cursorTarget and !_inVehicle and !_isPZombie and (player distance cu _isDestructable = _cursorTarget isKindOf "BuiltItems"; _isWreck = _typeOfCursorTarget in DZE_isWreck; _isWreckBuilding = _typeOfCursorTarget in DZE_isWreckBuilding; + _isModular = _cursorTarget isKindOf "ModularItems"; _isRemovable = _typeOfCursorTarget in DZE_isRemovable; _isDisallowRepair = _typeOfCursorTarget in ["M240Nest_DZ"]; @@ -195,6 +196,14 @@ if (!isNull cursorTarget and !_inVehicle and !_isPZombie and (player distance cu }; }; + //Allow owners to delete modulars + if(_isModular and (_ownerID == dayz_playerUID)) then { + if(_hasToolbox and "ItemCrowbar" in _itemsPlayer) then { + {cutText [format["This will not refund any components."], "PLAIN"];}; + _player_deleteBuild = true; + }; + }; + // CURSOR TARGET VEHICLE if(_isVehicle) then { From 2af16d3fcf985f2f5955a3b60098efbe19aeee2f Mon Sep 17 00:00:00 2001 From: dayz10k Date: Fri, 22 Nov 2013 16:47:15 -0500 Subject: [PATCH 02/11] class capitalization --- SQF/dayz_code/actions/trade_any_vehicle.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SQF/dayz_code/actions/trade_any_vehicle.sqf b/SQF/dayz_code/actions/trade_any_vehicle.sqf index 3d8400dce..9f7c16d98 100644 --- a/SQF/dayz_code/actions/trade_any_vehicle.sqf +++ b/SQF/dayz_code/actions/trade_any_vehicle.sqf @@ -25,7 +25,7 @@ if(_buy_o_sell == "buy") then { _qty = {_x == _part_in} count magazines player; } else { - if (_part_in isKindOf "AIR") then { + if (_part_in isKindOf "Air") then { _obj = nearestObjects [(getPosATL player), [_part_in], dayz_sellDistance_air]; } else { _obj = nearestObjects [(getPosATL player), [_part_in], dayz_sellDistance_vehicle]; @@ -226,4 +226,4 @@ if (_qty >= _qty_in) then { }; }; -TradeInprogress = false; \ No newline at end of file +TradeInprogress = false; From f14dbbd6bebe6c81ad2f84d2b970de20ea1a085e Mon Sep 17 00:00:00 2001 From: dayz10k Date: Fri, 22 Nov 2013 16:56:52 -0500 Subject: [PATCH 03/11] #749 unlock returns key name in cutText (WIP) --- SQF/dayz_code/compile/fn_selfActions.sqf | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/SQF/dayz_code/compile/fn_selfActions.sqf b/SQF/dayz_code/compile/fn_selfActions.sqf index 195205689..37a25d992 100644 --- a/SQF/dayz_code/compile/fn_selfActions.sqf +++ b/SQF/dayz_code/compile/fn_selfActions.sqf @@ -4,7 +4,7 @@ scriptName "Functions\misc\fn_selfActions.sqf"; - Function - [] call fnc_usec_selfActions; ************************************************************/ -private ["_isWreckBuilding","_temp_keys","_magazinesPlayer","_isPZombie","_vehicle","_inVehicle","_hasFuelE","_hasRawMeat","_hasKnife","_hasToolbox","_onLadder","_nearLight","_canPickLight","_canDo","_text","_isHarvested","_isVehicle","_isVehicletype","_isMan","_traderType","_ownerID","_isAnimal","_isDog","_isZombie","_isDestructable","_isTent","_isFuel","_isAlive","_Unlock","_lock","_buy","_dogHandle","_lieDown","_warn","_hastinitem","_allowedDistance","_menu","_menu1","_humanity_logic","_low_high","_cancel","_metals_trader","_traderMenu","_isWreck","_isRemovable","_isDisallowRepair","_rawmeat","_humanity","_speed","_dog","_hasbottleitem","_isAir","_isShip","_playersNear","_findNearestGens","_findNearestGen","_IsNearRunningGen","_cursorTarget","_isnewstorage","_itemsPlayer","_ownerKeyId","_typeOfCursorTarget","_hasKey","_oldOwner","_combi","_key_colors","_player_deleteBuild","_player_flipveh","_player_lockUnlock_crtl","_player_butcher","_player_studybody","_player_cook","_player_boil","_hasFuelBarrelE","_hasHotwireKit","_player_SurrenderedGear","_isSurrendered","_resultKeyname","_ownerIDname","_isModular"]; +private ["_isWreckBuilding","_temp_keys","_magazinesPlayer","_isPZombie","_vehicle","_inVehicle","_hasFuelE","_hasRawMeat","_hasKnife","_hasToolbox","_onLadder","_nearLight","_canPickLight","_canDo","_text","_isHarvested","_isVehicle","_isVehicletype","_isMan","_traderType","_ownerID","_isAnimal","_isDog","_isZombie","_isDestructable","_isTent","_isFuel","_isAlive","_Unlock","_lock","_buy","_dogHandle","_lieDown","_warn","_hastinitem","_allowedDistance","_menu","_menu1","_humanity_logic","_low_high","_cancel","_metals_trader","_traderMenu","_isWreck","_isRemovable","_isDisallowRepair","_rawmeat","_humanity","_speed","_dog","_hasbottleitem","_isAir","_isShip","_playersNear","_findNearestGens","_findNearestGen","_IsNearRunningGen","_cursorTarget","_isnewstorage","_itemsPlayer","_ownerKeyId","_typeOfCursorTarget","_hasKey","_oldOwner","_combi","_key_colors","_player_deleteBuild","_player_flipveh","_player_lockUnlock_crtl","_player_butcher","_player_studybody","_player_cook","_player_boil","_hasFuelBarrelE","_hasHotwireKit","_player_SurrenderedGear","_isSurrendered","_resultKeyname","_resultKeyname2","_ownerIDname","_isModular"]; if (TradeInprogress) exitWith {}; // Do not allow if any script is running. @@ -252,7 +252,8 @@ if (!isNull cursorTarget and !_inVehicle and !_isPZombie and (player distance cu if ((_ownerIDname > 5000) && (_ownerIDname <= 7500)) then {_resultKeyname = format["ItemKeyBlue%1",_ownerIDname-5000];}; if ((_ownerIDname > 7500) && (_ownerIDname <= 10000)) then {_resultKeyname = format["ItemKeyYellow%1",_ownerIDname-7500];}; if ((_ownerIDname > 10000) && (_ownerIDname <= 12500)) then {_resultKeyname = format["ItemKeyRed%1",_ownerIDname-10000];}; - {cutText [format["Key [%1] used to unlock vehicle.",_resultKeyname], "PLAIN"];}; + _resultKeyname2 = getText (configFile >> "CfgWeapons" >> _resultKeyname >> "displayName"); + {cutText [format["Key [%1] used to unlock vehicle.",_resultKeyname2], "PLAIN"];}; s_player_lockunlock set [count s_player_lockunlock,_Unlock]; s_player_lockUnlock_crtl = 1; From 0e10cf3096642cc6e1e209614e403dc9d7807215 Mon Sep 17 00:00:00 2001 From: dayz10k Date: Fri, 22 Nov 2013 16:59:18 -0500 Subject: [PATCH 04/11] #749 unlock returns key name in cutText (WIP) --- SQF/dayz_code/compile/fn_selfActions.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SQF/dayz_code/compile/fn_selfActions.sqf b/SQF/dayz_code/compile/fn_selfActions.sqf index 37a25d992..6b55dba1e 100644 --- a/SQF/dayz_code/compile/fn_selfActions.sqf +++ b/SQF/dayz_code/compile/fn_selfActions.sqf @@ -253,7 +253,7 @@ if (!isNull cursorTarget and !_inVehicle and !_isPZombie and (player distance cu if ((_ownerIDname > 7500) && (_ownerIDname <= 10000)) then {_resultKeyname = format["ItemKeyYellow%1",_ownerIDname-7500];}; if ((_ownerIDname > 10000) && (_ownerIDname <= 12500)) then {_resultKeyname = format["ItemKeyRed%1",_ownerIDname-10000];}; _resultKeyname2 = getText (configFile >> "CfgWeapons" >> _resultKeyname >> "displayName"); - {cutText [format["Key [%1] used to unlock vehicle.",_resultKeyname2], "PLAIN"];}; + {cutText [format["[%1] used to unlock vehicle.",_resultKeyname2], "PLAIN"];}; s_player_lockunlock set [count s_player_lockunlock,_Unlock]; s_player_lockUnlock_crtl = 1; From 8348b232c4f3dcafddecba6885f08d329f0ad560 Mon Sep 17 00:00:00 2001 From: dayz10k Date: Fri, 22 Nov 2013 17:38:33 -0500 Subject: [PATCH 05/11] #761 allow owner to remove modular(no refund, no rubble) --- SQF/dayz_code/compile/fn_selfActions.sqf | 1 - 1 file changed, 1 deletion(-) diff --git a/SQF/dayz_code/compile/fn_selfActions.sqf b/SQF/dayz_code/compile/fn_selfActions.sqf index 6b55dba1e..47b400a5c 100644 --- a/SQF/dayz_code/compile/fn_selfActions.sqf +++ b/SQF/dayz_code/compile/fn_selfActions.sqf @@ -199,7 +199,6 @@ if (!isNull cursorTarget and !_inVehicle and !_isPZombie and (player distance cu //Allow owners to delete modulars if(_isModular and (_ownerID == dayz_playerUID)) then { if(_hasToolbox and "ItemCrowbar" in _itemsPlayer) then { - {cutText [format["This will not refund any components."], "PLAIN"];}; _player_deleteBuild = true; }; }; From a0b171d3f59aeb3cae9a4f525b8c3b8b996eaf50 Mon Sep 17 00:00:00 2001 From: dayz10k Date: Fri, 22 Nov 2013 17:43:53 -0500 Subject: [PATCH 06/11] #761 allow owner to remove modular(no refund, no rubble) --- SQF/dayz_code/actions/remove.sqf | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/SQF/dayz_code/actions/remove.sqf b/SQF/dayz_code/actions/remove.sqf index 3cd2cc9e0..c97d831ca 100644 --- a/SQF/dayz_code/actions/remove.sqf +++ b/SQF/dayz_code/actions/remove.sqf @@ -2,7 +2,7 @@ delete object from db with extra waiting by [VB]AWOL parameters: _obj */ -private ["_activatingPlayer","_obj","_objectID","_objectUID","_started","_finished","_animState","_isMedic","_isOk","_proceed","_counter","_limit","_objType","_sfx","_dis","_itemOut","_countOut","_selectedRemoveOutput","_friendlies","_nearestPole","_ownerID","_refundpart","_isWreck","_findNearestPoles","_findNearestPole","_IsNearPlot","_brokenTool","_removeTool","_isDestructable","_isRemovable","_objOwnerID","_isOwnerOfObj","_preventRefund","_ipos","_item","_radius","_isWreckBuilding","_nameVehicle"]; +private ["_activatingPlayer","_obj","_objectID","_objectUID","_started","_finished","_animState","_isMedic","_isOk","_proceed","_counter","_limit","_objType","_sfx","_dis","_itemOut","_countOut","_selectedRemoveOutput","_friendlies","_nearestPole","_ownerID","_refundpart","_isWreck","_findNearestPoles","_findNearestPole","_IsNearPlot","_brokenTool","_removeTool","_isDestructable","_isRemovable","_objOwnerID","_isOwnerOfObj","_preventRefund","_ipos","_item","_radius","_isWreckBuilding","_nameVehicle","_isModular"]; if(TradeInprogress) exitWith { cutText [(localize "str_epoch_player_88") , "PLAIN DOWN"]; }; TradeInprogress = true; @@ -31,6 +31,7 @@ _isDestructable = _obj isKindOf "BuiltItems"; _isWreck = _objType in DZE_isWreck; _isRemovable = _objType in DZE_isRemovable; _isWreckBuilding = _objType in DZE_isWreckBuilding; +_isModular = _objType isKindOf "Modular"; _limit = 3; if(isNumber (configFile >> "CfgVehicles" >> _objType >> "constructioncount")) then { @@ -65,6 +66,12 @@ _nameVehicle = getText(configFile >> "CfgVehicles" >> _objType >> "displayName") cutText [format[(localize "str_epoch_player_162"),_nameVehicle], "PLAIN DOWN"]; +if (_isModular) then { + //allow previous cutText to show, then show this if modular. + sleep 2; + {cutText [format["This will not refund any components."], "PLAIN"];}; +}; + // Alert zombies once. [player,50,true,(getPosATL player)] spawn player_alertZombies; @@ -225,4 +232,4 @@ if (_proceed) then { }; }; TradeInprogress = false; -s_player_deleteBuild = -1; \ No newline at end of file +s_player_deleteBuild = -1; From 3c1984ba88b8789d39128e7a9012c232422f11b6 Mon Sep 17 00:00:00 2001 From: dayz10k Date: Fri, 22 Nov 2013 17:47:11 -0500 Subject: [PATCH 07/11] #761 allow owner to remove modular(no refund, no rubble) --- SQF/dayz_code/actions/remove.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SQF/dayz_code/actions/remove.sqf b/SQF/dayz_code/actions/remove.sqf index c97d831ca..3f7b22fea 100644 --- a/SQF/dayz_code/actions/remove.sqf +++ b/SQF/dayz_code/actions/remove.sqf @@ -69,7 +69,7 @@ cutText [format[(localize "str_epoch_player_162"),_nameVehicle], "PLAIN DOWN"]; if (_isModular) then { //allow previous cutText to show, then show this if modular. sleep 2; - {cutText [format["This will not refund any components."], "PLAIN"];}; + {cutText [format["Deconstructing modular buildables will not refund any components."], "PLAIN"];}; }; // Alert zombies once. From c5e9a78c46a17d6e140fc22292c126fa19a7d3e5 Mon Sep 17 00:00:00 2001 From: dayz10k Date: Sat, 23 Nov 2013 11:55:00 -0500 Subject: [PATCH 08/11] ammo size fixes #751 --- SQF/dayz_code/Configs/CfgMagazines.hpp | 29 +++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/SQF/dayz_code/Configs/CfgMagazines.hpp b/SQF/dayz_code/Configs/CfgMagazines.hpp index 68f3aca73..128ec003b 100644 --- a/SQF/dayz_code/Configs/CfgMagazines.hpp +++ b/SQF/dayz_code/Configs/CfgMagazines.hpp @@ -131,14 +131,33 @@ class CfgMagazines { picture = "\CA\weapons_E\Data\icons\m_m245_CA.paa"; }; class 100Rnd_556x45_BetaCMag: CA_Magazine { + scope = 2; + displayName = "MG36 Mag."; + ammo = "B_556x45_Ball"; + count = 100; + initSpeed = 920; + picture = "\ca\weapons\g36\data\equip\M_MG36_CA.paa"; type="256"; - } + tracersEvery = 4; + lastRoundsTracer = 4; + descriptionShort = "Caliber: 5.56x45 mm NATO + Rounds: 100 + Used in: MG36, X8 SAW"; + }; class 75Rnd_545x39_RPK: CA_Magazine { + scope = 2; + displayName = "75Rnd. RPK"; + ammo = "B_545x39_Ball"; + count = 75; type="256"; - } - class 100Rnd_556x45: CA_Magazine { - type="256"; - } + picture = "\CA\weapons\AK\data\equip\M_RPK_74_CA.paa"; + tracersEvery = 4; + lastRoundsTracer = 4; + nameSound = "mgun"; + descriptionShort = "Caliber: 5.45x39mm + Rounds: 75 + Used in: RPK-74"; + }; // Items class ItemHotwireKit: CA_Magazine From a1c791a9ff246ab419d7afe31464a385f21fd01d Mon Sep 17 00:00:00 2001 From: dayz10k Date: Sat, 23 Nov 2013 12:33:03 -0500 Subject: [PATCH 09/11] #696 autoincrement new values in SQL for new weapons --- Server Files/mysql/add_new_weapons.sql | 62 +++++++++++++------------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/Server Files/mysql/add_new_weapons.sql b/Server Files/mysql/add_new_weapons.sql index 017cd8098..90625c1b6 100644 --- a/Server Files/mysql/add_new_weapons.sql +++ b/Server Files/mysql/add_new_weapons.sql @@ -1,39 +1,39 @@ -- ---------------------------- -- This should be done -- ---------------------------- -INSERT INTO `trader_items` VALUES(771, 'KSVK_DZE', 3, 'Rifle Sniper', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(772, '5Rnd_127x108_KSVK', 1, 'Ammo Rifle Sniper', 'trade_items'); -INSERT INTO `trader_items` VALUES(773, 'Saiga12K', 3, 'Shotgun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(774, '8Rnd_B_Saiga12_74Slug', 1, 'Ammo Shotgun', 'trade_items'); -INSERT INTO `trader_items` VALUES(775, '8Rnd_B_Saiga12_74Pellets', 1, 'Ammo Shotgun', 'trade_items'); -INSERT INTO `trader_items` VALUES(776, 'bizon', 3, 'Sub Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(777, '64Rnd_9x19_Bizon', 1, 'Ammo SMG', 'trade_items'); -INSERT INTO `trader_items` VALUES(778, 'M8_SAW', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(779, 'MG36', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(780, 'RPK_74', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(781, 'M60A4_EP1_DZE', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(782, 'm240_scoped_EP1_DZE', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(783, 'M249_m145_EP1', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(784, 'MG36_camo', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(785, '100Rnd_556x45_BetaCMag', 1, 'Ammo - Light Machine Gun', 'trade_items'); -INSERT INTO `trader_items` VALUES(786, '75Rnd_545x39_RPK', 1, 'Ammo - Light Machine Gun', 'trade_items'); -INSERT INTO `trader_items` VALUES(787, '100Rnd_556x45', 1, 'Ammo - Light Machine Gun', 'trade_items'); +INSERT INTO `trader_items` VALUES(NULL, 'KSVK_DZE', 3, 'Rifle Sniper', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, '5Rnd_127x108_KSVK', 1, 'Ammo Rifle Sniper', 'trade_items'); +INSERT INTO `trader_items` VALUES(NULL, 'Saiga12K', 3, 'Shotgun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, '8Rnd_B_Saiga12_74Slug', 1, 'Ammo Shotgun', 'trade_items'); +INSERT INTO `trader_items` VALUES(NULL, '8Rnd_B_Saiga12_74Pellets', 1, 'Ammo Shotgun', 'trade_items'); +INSERT INTO `trader_items` VALUES(NULL, 'bizon', 3, 'Sub Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, '64Rnd_9x19_Bizon', 1, 'Ammo SMG', 'trade_items'); +INSERT INTO `trader_items` VALUES(NULL, 'M8_SAW', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, 'MG36', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, 'RPK_74', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, 'M60A4_EP1_DZE', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, 'm240_scoped_EP1_DZE', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, 'M249_m145_EP1', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, 'MG36_camo', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, '100Rnd_556x45_BetaCMag', 1, 'Ammo - Light Machine Gun', 'trade_items'); +INSERT INTO `trader_items` VALUES(NULL, '75Rnd_545x39_RPK', 1, 'Ammo - Light Machine Gun', 'trade_items'); +INSERT INTO `trader_items` VALUES(NULL, '100Rnd_556x45', 1, 'Ammo - Light Machine Gun', 'trade_items'); -- ------------------------------------------------------------------------------------------------------------- -- This needs flushed out more, as most is on black market (bizon, saiga should be on other vendors?) -- ------------------------------------------------------------------------------------------------------------- -INSERT INTO `Traders_DATA` VALUES(7370, '["M8_SAW",3]', 10, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7371, '["MG36",3]', 8, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7372, '["RPK_74",3]', 10, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7373, '["M60A4_EP1_DZE",3]', 5, '[2,"ItemGoldBar10oz",1]', '[1,"ItemGoldBar10oz",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7374, '["m240_scoped_EP1_DZE",3]', 5, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7375, '["M249_m145_EP1_DZE",3]', 5, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7376, '["MG36_camo",3]', 8, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7377, '["100Rnd_556x45_BetaCMag",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); -INSERT INTO `Traders_DATA` VALUES(7378, '["100Rnd_556x45",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); -INSERT INTO `Traders_DATA` VALUES(7379, '["75Rnd_545x39_RPK",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); -INSERT INTO `Traders_DATA` VALUES(7380, '["KSVK_DZE",3]', 10, '[3,"ItemGoldBar10oz",1]', '[1,"ItemGoldBar10oz",1]', 0, 526, 'trade_weapons'); -INSERT INTO `Traders_DATA` VALUES(7381, '["64Rnd_9x19_Bizon",1]', 10, '[2,"ItemSilverBar",1]', '[1,"ItemSilverBar",1]', 0, 527, 'trade_items'); -INSERT INTO `Traders_DATA` VALUES(7382, '["5Rnd_127x108_KSVK",1]', 10, '[1,"ItemSilverBar10oz",1]', '[5,"ItemSilverBar",1]', 0, 527, 'trade_items'); -INSERT INTO `Traders_DATA` VALUES(7380, '["bizon",3]', 10, '[1,"ItemGoldBar10oz",1]', '[5,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["M8_SAW",3]', 10, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["MG36",3]', 8, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["RPK_74",3]', 10, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["M60A4_EP1_DZE",3]', 5, '[2,"ItemGoldBar10oz",1]', '[1,"ItemGoldBar10oz",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["m240_scoped_EP1_DZE",3]', 5, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["M249_m145_EP1_DZE",3]', 5, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["MG36_camo",3]', 8, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["100Rnd_556x45_BetaCMag",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["100Rnd_556x45",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["75Rnd_545x39_RPK",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["KSVK_DZE",3]', 10, '[3,"ItemGoldBar10oz",1]', '[1,"ItemGoldBar10oz",1]', 0, 526, 'trade_weapons'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["64Rnd_9x19_Bizon",1]', 10, '[2,"ItemSilverBar",1]', '[1,"ItemSilverBar",1]', 0, 527, 'trade_items'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["5Rnd_127x108_KSVK",1]', 10, '[1,"ItemSilverBar10oz",1]', '[5,"ItemSilverBar",1]', 0, 527, 'trade_items'); +INSERT INTO `Traders_DATA` VALUES(NULL, '["bizon",3]', 10, '[1,"ItemGoldBar10oz",1]', '[5,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); From 32e406fc32466cb7b7062e6d93a654e1939a1d29 Mon Sep 17 00:00:00 2001 From: dayz10k Date: Sat, 23 Nov 2013 12:56:10 -0500 Subject: [PATCH 10/11] #696 cleanup SQL --- Server Files/mysql/add_new_weapons.sql | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Server Files/mysql/add_new_weapons.sql b/Server Files/mysql/add_new_weapons.sql index 90625c1b6..f2af7814e 100644 --- a/Server Files/mysql/add_new_weapons.sql +++ b/Server Files/mysql/add_new_weapons.sql @@ -13,11 +13,10 @@ INSERT INTO `trader_items` VALUES(NULL, 'MG36', 3, 'Machine Gun', 'trade_weapons INSERT INTO `trader_items` VALUES(NULL, 'RPK_74', 3, 'Machine Gun', 'trade_weapons'); INSERT INTO `trader_items` VALUES(NULL, 'M60A4_EP1_DZE', 3, 'Machine Gun', 'trade_weapons'); INSERT INTO `trader_items` VALUES(NULL, 'm240_scoped_EP1_DZE', 3, 'Machine Gun', 'trade_weapons'); -INSERT INTO `trader_items` VALUES(NULL, 'M249_m145_EP1', 3, 'Machine Gun', 'trade_weapons'); +INSERT INTO `trader_items` VALUES(NULL, 'M249_m145_EP1_DZE', 3, 'Machine Gun', 'trade_weapons'); INSERT INTO `trader_items` VALUES(NULL, 'MG36_camo', 3, 'Machine Gun', 'trade_weapons'); INSERT INTO `trader_items` VALUES(NULL, '100Rnd_556x45_BetaCMag', 1, 'Ammo - Light Machine Gun', 'trade_items'); INSERT INTO `trader_items` VALUES(NULL, '75Rnd_545x39_RPK', 1, 'Ammo - Light Machine Gun', 'trade_items'); -INSERT INTO `trader_items` VALUES(NULL, '100Rnd_556x45', 1, 'Ammo - Light Machine Gun', 'trade_items'); -- ------------------------------------------------------------------------------------------------------------- @@ -31,7 +30,6 @@ INSERT INTO `Traders_DATA` VALUES(NULL, '["m240_scoped_EP1_DZE",3]', 5, '[1,"Ite INSERT INTO `Traders_DATA` VALUES(NULL, '["M249_m145_EP1_DZE",3]', 5, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); INSERT INTO `Traders_DATA` VALUES(NULL, '["MG36_camo",3]', 8, '[1,"ItemGoldBar10oz",1]', '[6,"ItemGoldBar",1]', 0, 526, 'trade_weapons'); INSERT INTO `Traders_DATA` VALUES(NULL, '["100Rnd_556x45_BetaCMag",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); -INSERT INTO `Traders_DATA` VALUES(NULL, '["100Rnd_556x45",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); INSERT INTO `Traders_DATA` VALUES(NULL, '["75Rnd_545x39_RPK",1]', 10, '[3,"ItemSilverBar10oz",1]', '[1,"ItemSilverBar10oz",1]', 0, 527, 'trade_items'); INSERT INTO `Traders_DATA` VALUES(NULL, '["KSVK_DZE",3]', 10, '[3,"ItemGoldBar10oz",1]', '[1,"ItemGoldBar10oz",1]', 0, 526, 'trade_weapons'); INSERT INTO `Traders_DATA` VALUES(NULL, '["64Rnd_9x19_Bizon",1]', 10, '[2,"ItemSilverBar",1]', '[1,"ItemSilverBar",1]', 0, 527, 'trade_items'); From a07adf9406260e87f76d0849d5fe5c283da4a685 Mon Sep 17 00:00:00 2001 From: dayz10k Date: Sat, 23 Nov 2013 17:13:58 -0500 Subject: [PATCH 11/11] Update remove.sqf --- SQF/dayz_code/actions/remove.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SQF/dayz_code/actions/remove.sqf b/SQF/dayz_code/actions/remove.sqf index 3f7b22fea..43986b221 100644 --- a/SQF/dayz_code/actions/remove.sqf +++ b/SQF/dayz_code/actions/remove.sqf @@ -31,7 +31,7 @@ _isDestructable = _obj isKindOf "BuiltItems"; _isWreck = _objType in DZE_isWreck; _isRemovable = _objType in DZE_isRemovable; _isWreckBuilding = _objType in DZE_isWreckBuilding; -_isModular = _objType isKindOf "Modular"; +_isModular = _objType isKindOf "ModularItems"; _limit = 3; if(isNumber (configFile >> "CfgVehicles" >> _objType >> "constructioncount")) then {