Jump to content

[RELEASE] TradeFromVehicle - Version 2.0 is here!


Csus

Recommended Posts

I got it all working but its odd, the guns sell, people get money but then the guns stay in the  vehicles. You cannot sell them twice though but the guns are all still there like you didnt sell them at all.

 

You can even take them and sell them 1 by 1 again but not again from the vehicle

Link to comment
Share on other sites

well this is new :/ have you modified any files other than the init?

i don't get what would cause this, it removes every weapon from the vehicle once you finish trading and just adds back the ones you can't sell.

Link to comment
Share on other sites

this is a chunk of my init.sqf

//Load in compiled functions
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\variables.sqf";				//Initilize the Variables (IMPORTANT: Must happen very early)
progressLoadingScreen 0.1;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\publicEH.sqf";				//Initilize the publicVariable event handlers
progressLoadingScreen 0.2;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\medical\setup_functions_med.sqf";	//Functions used by CLIENT for medical
progressLoadingScreen 0.4;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf";				//Compile regular functions
progressLoadingScreen 0.5;
call compile preprocessFileLineNumbers "server_traders.sqf";				//Compile trader configs
progressLoadingScreen 1.0;

"filmic" setToneMappingParams [0.153, 0.357, 0.231, 0.1573, 0.011, 3.750, 6, 4]; setToneMapping "Filmic";

if (isServer) then {
	//Compile vehicle configs
	call compile preprocessFileLineNumbers "\z\addons\dayz_server\missions\DayZ_Epoch_24.Napf\dynamic_vehicle.sqf";				
	// Add trader citys
	_nil = [] execVM "\z\addons\dayz_server\missions\DayZ_Epoch_24.Napf\mission.sqf";

	_serverMonitor = 	[] execVM "\z\addons\dayz_code\system\server_monitor.sqf";
};

if (!isDedicated) then {

    [] ExecVM "TradeFromVehicle\init.sqf";    //  <<<< Line to launch TradeFromVehicle script
    [10] ExecVM "AutoEpi\AutoEpi.sqf";
	
	//Conduct map operations
	0 fadeSound 0;
	waitUntil {!isNil "dayz_loadScreenMsg"};
	dayz_loadScreenMsg = (localize "STR_AUTHENTICATING");
	
	//Run the player monitor
	_id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}];
	_playerMonitor = 	[] execVM "\z\addons\dayz_code\system\player_monitor.sqf";	
	
};

as long as you have the ExecVM line around the same place I do it should work pefectly.

Aha! Found my problem. Didn't have "[]" before, or ";" after. Sorry, I'm a noob. If it's not in the instructions, I don't know to do it.

Hopefully now I can get it to work. :)

 

With the anticipation that this will work, thanks Hardened for an awesome script!

Oh, BTW, lot of work to create that list of items, weapons, prices, etc. I take it there's no way to just link it somehow to the actual

trader's list? Again, I know nothing about scripting, probably, if it could be done, you would have done it. :D

Link to comment
Share on other sites

can you paste up your init.sqf from the TradeFromVehicle folder please, preferably in a spoiler tag -

[spoiler]Some text here[/spoiler]

 

and you can use the SQL function that's in the install instructions to pull a list of all weapons and items from your traders along with the correct prices.

Link to comment
Share on other sites

waitUntil {!isNil "dayz_animalCheck"};

sleep 1;
 
/*    *******************************************************************************************************************************************   */
/*    Turn debugging functionality on or off.                                                                                                       */
/*    *******************************************************************************************************************************************   */
tfv_DEBUGGING = true;
 
/*    *******************************************************************************************************************************************   */
/*    How many weapons will be sold per cycle.                                                                                                      */
/*    *******************************************************************************************************************************************   */
tfv_SALES_PER_ANIM = 5;
 
/*    *******************************************************************************************************************************************   */
/*    How many magazines will be sold per cycle.                                                                                                      */
/*    *******************************************************************************************************************************************   */
tfv_SALES_PER_ANIM_MAGS = 10;
 
/*    *******************************************************************************************************************************************   */
/*    A list of each trader, along with the weapons they accept.                                                                                    */
/*    *******************************************************************************************************************************************   */
tfv_TRADERS_ITEMS = [
        ["TK_Soldier_AMG_EP1",["RH_m1stacog","m16a4","RH_hk416seotech","RH_hk416sd","RH_hk416sdeotech","RH_hk416eotech","RH_hk416acog","RH_hk416sdglaim","RH_hk416sdgleotech","RH_hk417acog","RH_hk417sp","RH_hk417saim","RH_hk417sacog","RH_hk417sd","RH_hk417sdacog","RH_hk417sdsp","RH_hk417sglaim","RH_ctar21m","RH_star21","RH_masacog","RH_massdeotech","RH_masbeotech","RH_masbacog","RH_masbsdacog","FHQ_ACR_GL_SD_BASE","FHQ_ACR_BASE_L","FHQ_ACR_GL_SD_BASE_F","FHQ_ACR_WDL_CCO_SD_F","FHQ_ACR_WDL_RCO_F","FHQ_ACR_WDL_RCO_SD","FHQ_ACR_WDL_RCO_GL_SD_F","FHQ_ACR_WDL_HWS_F","FHQ_ACR_WDL_HWS_GL","FHQ_ACR_WDL_G33","FHQ_ACR_WDL_G33_SD","FHQ_ACR_WDL_G33_GL_SD","FHQ_ACR_WDL_HAMR","FHQ_ACR_WDL_HAMR_SD_F","FHQ_ACR_BLK_IRN_F","FHQ_ACR_BLK_CCO_F","FHQ_ACR_BLK_CCO_GL_SD_F","FHQ_ACR_BLK_RCO","FHQ_ACR_BLK_RCO_SD_F","FHQ_ACR_BLK_HWS","FHQ_ACR_BLK_HWS_GL_SD","FHQ_ACR_BLK_G33","FHQ_ACR_BLK_G33_SD","FHQ_ACR_BLK_G33_GL","FHQ_ACR_BLK_G33_GL_SD","FHQ_ACR_TAN_IRN","FHQ_ACR_TAN_CCO","FHQ_ACR_TAN_CCO_GL_SD","FHQ_ACR_TAN_RCO","FHQ_ACR_TAN_RCO_GL_SD","FHQ_ACR_TAN_HWS","FHQ_ACR_TAN_HWS_GL","FHQ_ACR_TAN_HWS_SD","FHQ_ACR_TAN_G33_SD","FHQ_ACR_TAN_G33_GL_SD","FHQ_ACR_TAN_HAMR","FHQ_ACR_TAN_HAMR_SD","vil_SKS","vil_RPK74M_P29","vil_RPK74M","vil_AK_47_49","vil_AKMSB","vil_AKMS","vil_AK_nato_m1","vil_PMIS","vil_MPi","vil_AK_74m_EOT_FSB","vil_AK_74m_p29","vil_AK_74m_gp_29","vil_ak12_ap","vil_AeK_23","vil_AeK_3_K","vil_G3a3","vil_G3a4b","vil_G3an","vil_M4_EOT","vil_Galil_arm","vil_G36KVA4","vil_G36a2","vil_G36KV3Des","vil_HK416_Aim","VIL_HK416_EDR","RH_m21","RH_sc2acog","RH_sc2shd","RH_sc2sp","RH_m1saim","RH_m1sshd","RH_m1ssp","RH_m1stacog","RH_m1steot","RH_m1stsp","FHQ_RSASS_TAN","FHQ_XM2010_DESERT","FHQ_XM2010_SD_DESERT","FHQ_XM2010_WDL_CAMO","vil_SVDK","vil_SR25","vil_M110","vil_HK417s","vil_SR25SD","vil_M110sd","USSOF_Mk_48","BAF_L7A2","vil_PKP_EOT","vil_PK","vil_PKM","vil_RPK75_M72","vil_RPD","skavil_M60","skavil_M60e3","vil_Mg3","vil_M249_Para","vil_Minimi","vil_M240_B","vil_MG4","MG36_camo_Large","m8_SAW_Large","vil_USP45SD","vil_USP45","vil_Glock","vil_apssd","vil_APS","RH_muzi","RH_tec9","RH_vz61","RH_g19t","RH_g17sd","RH_g17","RH_m9csd","RH_tt33","RH_m1911","RH_m1911sd","RH_usp","RH_python","RH_bull","RH_anacg","RH_anac","RH_Deaglemzb","RH_Deaglemz","RH_Deagleg","RH_Deagles","G36A_camo","G36C","G36C_camo","G36K_camo","M16A2","M16A2GL","m16a4_acg","M4A1","M4A1_HWS_GL_camo","M4A3_CCO_EP1","M4A1_Aim","Sa58P_EP1","Sa58V_CCO_EP1","Sa58V_EP1","Sa58V_RCO_EP1","AKS_74_kobra","AKS_74_U","AK_47_M","AK_74","FN_FAL","M4A1_AIM_SD_camo","AK_107_kobra","AK_107_GL_kobra","AK_107_pso","AK_107_GL_pso","AKS_74_UN_kobra","SCAR_L_CQC","SCAR_L_CQC_Holo","SCAR_L_STD_Mk4CQT","SCAR_L_STD_EGLM_RCO","SCAR_L_CQC_EGLM_Holo","SCAR_L_STD_HOLO","SCAR_L_CQC_CCO_SD","SCAR_H_CQC_CCO","SCAR_H_CQC_CCO_SD","SCAR_H_STD_EGLM_Spect","BAF_L85A2_RIS_Holo","BAF_L85A2_UGL_Holo","BAF_L85A2_RIS_SUSAT","BAF_L85A2_UGL_SUSAT","BAF_L85A2_RIS_ACOG","BAF_L85A2_UGL_ACOG","AK_74_GL_kobra","m8_carbine_pmc","m8_compact_pmc","m8_holo_sd","M4A1_HWS_GL_SD_Camo","M16A4_GL","M16A4_ACG_GL","M4A1_RCO_GL","M4A1_HWS_GL","G36_C_SD_eotech","G36a","AK_47_S","AK_74_GL","AKS_74_pso","M4A3_RCO_GL_EP1"],["weapons"],0],
["TK_Commander_EP1",["RH_m1stacog","m16a4","RH_hk416seotech","RH_hk416sd","RH_hk416sdeotech","RH_hk416eotech","RH_hk416acog","RH_hk416sdglaim","RH_hk416sdgleotech","RH_hk417acog","RH_hk417sp","RH_hk417saim","RH_hk417sacog","RH_hk417sd","RH_hk417sdacog","RH_hk417sdsp","RH_hk417sglaim","RH_ctar21m","RH_star21","RH_masacog","RH_massdeotech","RH_masbeotech","RH_masbacog","RH_masbsdacog","FHQ_ACR_GL_SD_BASE","FHQ_ACR_BASE_L","FHQ_ACR_GL_SD_BASE_F","FHQ_ACR_WDL_CCO_SD_F","FHQ_ACR_WDL_RCO_F","FHQ_ACR_WDL_RCO_SD","FHQ_ACR_WDL_RCO_GL_SD_F","FHQ_ACR_WDL_HWS_F","FHQ_ACR_WDL_HWS_GL","FHQ_ACR_WDL_G33","FHQ_ACR_WDL_G33_SD","FHQ_ACR_WDL_G33_GL_SD","FHQ_ACR_WDL_HAMR","FHQ_ACR_WDL_HAMR_SD_F","FHQ_ACR_BLK_IRN_F","FHQ_ACR_BLK_CCO_F","FHQ_ACR_BLK_CCO_GL_SD_F","FHQ_ACR_BLK_RCO","FHQ_ACR_BLK_RCO_SD_F","FHQ_ACR_BLK_HWS","FHQ_ACR_BLK_HWS_GL_SD","FHQ_ACR_BLK_G33","FHQ_ACR_BLK_G33_SD","FHQ_ACR_BLK_G33_GL","FHQ_ACR_BLK_G33_GL_SD","FHQ_ACR_TAN_IRN","FHQ_ACR_TAN_CCO","FHQ_ACR_TAN_CCO_GL_SD","FHQ_ACR_TAN_RCO","FHQ_ACR_TAN_RCO_GL_SD","FHQ_ACR_TAN_HWS","FHQ_ACR_TAN_HWS_GL","FHQ_ACR_TAN_HWS_SD","FHQ_ACR_TAN_G33_SD","FHQ_ACR_TAN_G33_GL_SD","FHQ_ACR_TAN_HAMR","FHQ_ACR_TAN_HAMR_SD","vil_SKS","vil_RPK74M_P29","vil_RPK74M","vil_AK_47_49","vil_AKMSB","vil_AKMS","vil_AK_nato_m1","vil_PMIS","vil_MPi","vil_AK_74m_EOT_FSB","vil_AK_74m_p29","vil_AK_74m_gp_29","vil_ak12_ap","vil_AeK_23","vil_AeK_3_K","vil_G3a3","vil_G3a4b","vil_G3an","vil_M4_EOT","vil_Galil_arm","vil_G36KVA4","vil_G36a2","vil_G36KV3Des","vil_HK416_Aim","VIL_HK416_EDR","RH_m21","RH_sc2acog","RH_sc2shd","RH_sc2sp","RH_m1saim","RH_m1sshd","RH_m1ssp","RH_m1stacog","RH_m1steot","RH_m1stsp","FHQ_RSASS_TAN","FHQ_XM2010_DESERT","FHQ_XM2010_SD_DESERT","FHQ_XM2010_WDL_CAMO","vil_SVDK","vil_SR25","vil_M110","vil_HK417s","vil_SR25SD","vil_M110sd","USSOF_Mk_48","BAF_L7A2","vil_PKP_EOT","vil_PK","vil_PKM","vil_RPK75_M72","vil_RPD","skavil_M60","skavil_M60e3","vil_Mg3","vil_M249_Para","vil_Minimi","vil_M240_B","vil_MG4","MG36_camo_Large","m8_SAW_Large","vil_USP45SD","vil_USP45","vil_Glock","vil_apssd","vil_APS","RH_muzi","RH_tec9","RH_vz61","RH_g19t","RH_g17sd","RH_g17","RH_m9csd","RH_tt33","RH_m1911","RH_m1911sd","RH_usp","RH_python","RH_bull","RH_anacg","RH_anac","RH_Deaglemzb","RH_Deaglemz","RH_Deagleg","RH_Deagles","G36A_camo","G36C","G36C_camo","G36K_camo","M16A2","M16A2GL","m16a4_acg","M4A1","M4A1_HWS_GL_camo","M4A3_CCO_EP1","M4A1_Aim","Sa58P_EP1","Sa58V_CCO_EP1","Sa58V_EP1","Sa58V_RCO_EP1","AKS_74_kobra","AKS_74_U","AK_47_M","AK_74","FN_FAL","M4A1_AIM_SD_camo","AK_107_kobra","AK_107_GL_kobra","AK_107_pso","AK_107_GL_pso","AKS_74_UN_kobra","SCAR_L_CQC","SCAR_L_CQC_Holo","SCAR_L_STD_Mk4CQT","SCAR_L_STD_EGLM_RCO","SCAR_L_CQC_EGLM_Holo","SCAR_L_STD_HOLO","SCAR_L_CQC_CCO_SD","SCAR_H_CQC_CCO","SCAR_H_CQC_CCO_SD","SCAR_H_STD_EGLM_Spect","BAF_L85A2_RIS_Holo","BAF_L85A2_UGL_Holo","BAF_L85A2_RIS_SUSAT","BAF_L85A2_UGL_SUSAT","BAF_L85A2_RIS_ACOG","BAF_L85A2_UGL_ACOG","AK_74_GL_kobra","m8_carbine_pmc","m8_compact_pmc","m8_holo_sd","M4A1_HWS_GL_SD_Camo","M16A4_GL","M16A4_ACG_GL","M4A1_RCO_GL","M4A1_HWS_GL","G36_C_SD_eotech","G36a","AK_47_S","AK_74_GL","AKS_74_pso","M4A3_RCO_GL_EP1"],["weapons"],0],
["Tanny_PMC",["RH_m1stacog","m16a4","RH_hk416seotech","RH_hk416sd","RH_hk416sdeotech","RH_hk416eotech","RH_hk416acog","RH_hk416sdglaim","RH_hk416sdgleotech","RH_hk417acog","RH_hk417sp","RH_hk417saim","RH_hk417sacog","RH_hk417sd","RH_hk417sdacog","RH_hk417sdsp","RH_hk417sglaim","RH_ctar21m","RH_star21","RH_masacog","RH_massdeotech","RH_masbeotech","RH_masbacog","RH_masbsdacog","FHQ_ACR_GL_SD_BASE","FHQ_ACR_BASE_L","FHQ_ACR_GL_SD_BASE_F","FHQ_ACR_WDL_CCO_SD_F","FHQ_ACR_WDL_RCO_F","FHQ_ACR_WDL_RCO_SD","FHQ_ACR_WDL_RCO_GL_SD_F","FHQ_ACR_WDL_HWS_F","FHQ_ACR_WDL_HWS_GL","FHQ_ACR_WDL_G33","FHQ_ACR_WDL_G33_SD","FHQ_ACR_WDL_G33_GL_SD","FHQ_ACR_WDL_HAMR","FHQ_ACR_WDL_HAMR_SD_F","FHQ_ACR_BLK_IRN_F","FHQ_ACR_BLK_CCO_F","FHQ_ACR_BLK_CCO_GL_SD_F","FHQ_ACR_BLK_RCO","FHQ_ACR_BLK_RCO_SD_F","FHQ_ACR_BLK_HWS","FHQ_ACR_BLK_HWS_GL_SD","FHQ_ACR_BLK_G33","FHQ_ACR_BLK_G33_SD","FHQ_ACR_BLK_G33_GL","FHQ_ACR_BLK_G33_GL_SD","FHQ_ACR_TAN_IRN","FHQ_ACR_TAN_CCO","FHQ_ACR_TAN_CCO_GL_SD","FHQ_ACR_TAN_RCO","FHQ_ACR_TAN_RCO_GL_SD","FHQ_ACR_TAN_HWS","FHQ_ACR_TAN_HWS_GL","FHQ_ACR_TAN_HWS_SD","FHQ_ACR_TAN_G33_SD","FHQ_ACR_TAN_G33_GL_SD","FHQ_ACR_TAN_HAMR","FHQ_ACR_TAN_HAMR_SD","vil_SKS","vil_RPK74M_P29","vil_RPK74M","vil_AK_47_49","vil_AKMSB","vil_AKMS","vil_AK_nato_m1","vil_PMIS","vil_MPi","vil_AK_74m_EOT_FSB","vil_AK_74m_p29","vil_AK_74m_gp_29","vil_ak12_ap","vil_AeK_23","vil_AeK_3_K","vil_G3a3","vil_G3a4b","vil_G3an","vil_M4_EOT","vil_Galil_arm","vil_G36KVA4","vil_G36a2","vil_G36KV3Des","vil_HK416_Aim","VIL_HK416_EDR","RH_m21","RH_sc2acog","RH_sc2shd","RH_sc2sp","RH_m1saim","RH_m1sshd","RH_m1ssp","RH_m1stacog","RH_m1steot","RH_m1stsp","FHQ_RSASS_TAN","FHQ_XM2010_DESERT","FHQ_XM2010_SD_DESERT","FHQ_XM2010_WDL_CAMO","vil_SVDK","vil_SR25","vil_M110","vil_HK417s","vil_SR25SD","vil_M110sd","USSOF_Mk_48","BAF_L7A2","vil_PKP_EOT","vil_PK","vil_PKM","vil_RPK75_M72","vil_RPD","skavil_M60","skavil_M60e3","vil_Mg3","vil_M249_Para","vil_Minimi","vil_M240_B","vil_MG4","MG36_camo_Large","m8_SAW_Large","vil_USP45SD","vil_USP45","vil_Glock","vil_apssd","vil_APS","RH_muzi","RH_tec9","RH_vz61","RH_g19t","RH_g17sd","RH_g17","RH_m9csd","RH_tt33","RH_m1911","RH_m1911sd","RH_usp","RH_python","RH_bull","RH_anacg","RH_anac","RH_Deaglemzb","RH_Deaglemz","RH_Deagleg","RH_Deagles","G36A_camo","G36C","G36C_camo","G36K_camo","M16A2","M16A2GL","m16a4_acg","M4A1","M4A1_HWS_GL_camo","M4A3_CCO_EP1","M4A1_Aim","Sa58P_EP1","Sa58V_CCO_EP1","Sa58V_EP1","Sa58V_RCO_EP1","AKS_74_kobra","AKS_74_U","AK_47_M","AK_74","FN_FAL","M4A1_AIM_SD_camo","AK_107_kobra","AK_107_GL_kobra","AK_107_pso","AK_107_GL_pso","AKS_74_UN_kobra","SCAR_L_CQC","SCAR_L_CQC_Holo","SCAR_L_STD_Mk4CQT","SCAR_L_STD_EGLM_RCO","SCAR_L_CQC_EGLM_Holo","SCAR_L_STD_HOLO","SCAR_L_CQC_CCO_SD","SCAR_H_CQC_CCO","SCAR_H_CQC_CCO_SD","SCAR_H_STD_EGLM_Spect","BAF_L85A2_RIS_Holo","BAF_L85A2_UGL_Holo","BAF_L85A2_RIS_SUSAT","BAF_L85A2_UGL_SUSAT","BAF_L85A2_RIS_ACOG","BAF_L85A2_UGL_ACOG","AK_74_GL_kobra","m8_carbine_pmc","m8_compact_pmc","m8_holo_sd","M4A1_HWS_GL_SD_Camo","M16A4_GL","M16A4_ACG_GL","M4A1_RCO_GL","M4A1_HWS_GL","G36_C_SD_eotech","G36a","AK_47_S","AK_74_GL","AKS_74_pso","M4A3_RCO_GL_EP1","30Rnd_556x45_Stanag","30Rnd_556x45_G36","30Rnd_545x39_AK","RH_7Rnd_50_AE","RH_6Rnd_44_Mag","RH_6Rnd_357_Mag","RH_13Rnd_9x19_bhp","RH_15Rnd_9x19_usp","RH_8Rnd_9x19_P38","RH_7Rnd_32cal_ppk","RH_8Rnd_9x19_Mk","RH_8Rnd_9x19_Mksd","RH_15Rnd_9x19_uspsd","RH_12Rnd_45cal_usp","RH_8Rnd_45cal_m1911","RH_8Rnd_762_tt33","RH_10Rnd_22LR_mk2","RH_20Rnd_9x19_M93","15Rnd_9x19_M9","15Rnd_9x19_M9SD","RH_19Rnd_9x19_g18","RH_17Rnd_9x19_g17","RH_17Rnd_9x19_g17SD","RH_20Rnd_32cal_vz61","RH_30Rnd_9x19_tec","RH_32Rnd_9x19_Muzi","30Rnd_556x45_StanagSD","RH_20Rnd_762x51_hk417","RH_20Rnd_762x51_SD_hk417","20Rnd_762x51_DMR","USSR_5Rnd_408","FHQ_rem_30Rnd_680x43_ACR","FHQ_rem_30Rnd_680x43_ACR_SD","FHQ_rem_7Rnd_338Lapua_MSR_NT","FHQ_rem_7Rnd_338Lapua_MSR_NT_SD","FHQ_rem_20Rnd_762x51_PMAG_NT","FHQ_rem_20Rnd_762x51_PMAG_NT_SD","FHQ_rem_5Rnd_300Win_XM2010_NT","FHQ_rem_5Rnd_300Win_XM2010_NT_SD","vil_10Rnd_762x39_SKS","vil_8Rnd_TT","vil_20Rnd_9x18_aps","vil_20Rnd_9x18_apsSD","vil_17Rnd_9x19_PYA","vil_20Rnd_9x39_SP6ns_OC","vil_45Rnd_545x39_AK","30Rnd_545x39_AKSD","vil_10Rnd_Mauser","vil_10Rnd_PSL","10Rnd_762x54_SVD","vil_10Rnd_762x54_SV","vil_bhp_mag","17Rnd_9x19_glock17","vil_usp45_mag","vil_usp45sd_mag","vil_32Rnd_uzi","vil_32Rnd_UZI_SD","vil_20Rnd_762x51_G3","20Rnd_762x51_FNFAL","vil_20Rnd_556x45_SG","vil_20Rnd_556x45_IN","Vil_30Rnd_556x45_HK","Vil_35Rnd_556x45_G","100Rnd_762x51_M240","200Rnd_762x54_GPMG","100Rnd_762x54_PK","vil_40Rnd_762x39_AK47","vil_75Rnd_762x39_AK47","vil_100Rnd_762x39_RPD","200Rnd_556x45_M249","100Rnd_556x45_BetaCMag","75Rnd_545x39_RPK"],["weapons","magazines"],5000],
["MVD_Soldier_Marksman",["RH_m1stacog","m16a4","RH_hk416seotech","RH_hk416sd","RH_hk416sdeotech","RH_hk416eotech","RH_hk416acog","RH_hk416sdglaim","RH_hk416sdgleotech","RH_hk417acog","RH_hk417sp","RH_hk417saim","RH_hk417sacog","RH_hk417sd","RH_hk417sdacog","RH_hk417sdsp","RH_hk417sglaim","RH_ctar21m","RH_star21","RH_masacog","RH_massdeotech","RH_masbeotech","RH_masbacog","RH_masbsdacog","FHQ_ACR_GL_SD_BASE","FHQ_ACR_BASE_L","FHQ_ACR_GL_SD_BASE_F","FHQ_ACR_WDL_CCO_SD_F","FHQ_ACR_WDL_RCO_F","FHQ_ACR_WDL_RCO_SD","FHQ_ACR_WDL_RCO_GL_SD_F","FHQ_ACR_WDL_HWS_F","FHQ_ACR_WDL_HWS_GL","FHQ_ACR_WDL_G33","FHQ_ACR_WDL_G33_SD","FHQ_ACR_WDL_G33_GL_SD","FHQ_ACR_WDL_HAMR","FHQ_ACR_WDL_HAMR_SD_F","FHQ_ACR_BLK_IRN_F","FHQ_ACR_BLK_CCO_F","FHQ_ACR_BLK_CCO_GL_SD_F","FHQ_ACR_BLK_RCO","FHQ_ACR_BLK_RCO_SD_F","FHQ_ACR_BLK_HWS","FHQ_ACR_BLK_HWS_GL_SD","FHQ_ACR_BLK_G33","FHQ_ACR_BLK_G33_SD","FHQ_ACR_BLK_G33_GL","FHQ_ACR_BLK_G33_GL_SD","FHQ_ACR_TAN_IRN","FHQ_ACR_TAN_CCO","FHQ_ACR_TAN_CCO_GL_SD","FHQ_ACR_TAN_RCO","FHQ_ACR_TAN_RCO_GL_SD","FHQ_ACR_TAN_HWS","FHQ_ACR_TAN_HWS_GL","FHQ_ACR_TAN_HWS_SD","FHQ_ACR_TAN_G33_SD","FHQ_ACR_TAN_G33_GL_SD","FHQ_ACR_TAN_HAMR","FHQ_ACR_TAN_HAMR_SD","vil_SKS","vil_RPK74M_P29","vil_RPK74M","vil_AK_47_49","vil_AKMSB","vil_AKMS","vil_AK_nato_m1","vil_PMIS","vil_MPi","vil_AK_74m_EOT_FSB","vil_AK_74m_p29","vil_AK_74m_gp_29","vil_ak12_ap","vil_AeK_23","vil_AeK_3_K","vil_G3a3","vil_G3a4b","vil_G3an","vil_M4_EOT","vil_Galil_arm","vil_G36KVA4","vil_G36a2","vil_G36KV3Des","vil_HK416_Aim","VIL_HK416_EDR","RH_m21","RH_sc2acog","RH_sc2shd","RH_sc2sp","RH_m1saim","RH_m1sshd","RH_m1ssp","RH_m1stacog","RH_m1steot","RH_m1stsp","FHQ_RSASS_TAN","FHQ_XM2010_DESERT","FHQ_XM2010_SD_DESERT","FHQ_XM2010_WDL_CAMO","vil_SVDK","vil_SR25","vil_M110","vil_HK417s","vil_SR25SD","vil_M110sd","USSOF_Mk_48","BAF_L7A2","vil_PKP_EOT","vil_PK","vil_PKM","vil_RPK75_M72","vil_RPD","skavil_M60","skavil_M60e3","vil_Mg3","vil_M249_Para","vil_Minimi","vil_M240_B","vil_MG4","MG36_camo_Large","m8_SAW_Large","vil_USP45SD","vil_USP45","vil_Glock","vil_apssd","vil_APS","RH_muzi","RH_tec9","RH_vz61","RH_g19t","RH_g17sd","RH_g17","RH_m9csd","RH_tt33","RH_m1911","RH_m1911sd","RH_usp","RH_python","RH_bull","RH_anacg","RH_anac","RH_Deaglemzb","RH_Deaglemz","RH_Deagleg","RH_Deagles","G36A_camo","G36C","G36C_camo","G36K_camo","M16A2","M16A2GL","m16a4_acg","M4A1","M4A1_HWS_GL_camo","M4A3_CCO_EP1","M4A1_Aim","Sa58P_EP1","Sa58V_CCO_EP1","Sa58V_EP1","Sa58V_RCO_EP1","AKS_74_kobra","AKS_74_U","AK_47_M","AK_74","FN_FAL","M4A1_AIM_SD_camo","AK_107_kobra","AK_107_GL_kobra","AK_107_pso","AK_107_GL_pso","AKS_74_UN_kobra","SCAR_L_CQC","SCAR_L_CQC_Holo","SCAR_L_STD_Mk4CQT","SCAR_L_STD_EGLM_RCO","SCAR_L_CQC_EGLM_Holo","SCAR_L_STD_HOLO","SCAR_L_CQC_CCO_SD","SCAR_H_CQC_CCO","SCAR_H_CQC_CCO_SD","SCAR_H_STD_EGLM_Spect","BAF_L85A2_RIS_Holo","BAF_L85A2_UGL_Holo","BAF_L85A2_RIS_SUSAT","BAF_L85A2_UGL_SUSAT","BAF_L85A2_RIS_ACOG","BAF_L85A2_UGL_ACOG","AK_74_GL_kobra","m8_carbine_pmc","m8_compact_pmc","m8_holo_sd","M4A1_HWS_GL_SD_Camo","M16A4_GL","M16A4_ACG_GL","M4A1_RCO_GL","M4A1_HWS_GL","G36_C_SD_eotech","G36a","AK_47_S","AK_74_GL","AKS_74_pso","M4A3_RCO_GL_EP1","30Rnd_556x45_Stanag","30Rnd_556x45_G36","30Rnd_545x39_AK","RH_7Rnd_50_AE","RH_6Rnd_44_Mag","RH_6Rnd_357_Mag","RH_13Rnd_9x19_bhp","RH_15Rnd_9x19_usp","RH_8Rnd_9x19_P38","RH_7Rnd_32cal_ppk","RH_8Rnd_9x19_Mk","RH_8Rnd_9x19_Mksd","RH_15Rnd_9x19_uspsd","RH_12Rnd_45cal_usp","RH_8Rnd_45cal_m1911","RH_8Rnd_762_tt33","RH_10Rnd_22LR_mk2","RH_20Rnd_9x19_M93","15Rnd_9x19_M9","15Rnd_9x19_M9SD","RH_19Rnd_9x19_g18","RH_17Rnd_9x19_g17","RH_17Rnd_9x19_g17SD","RH_20Rnd_32cal_vz61","RH_30Rnd_9x19_tec","RH_32Rnd_9x19_Muzi","30Rnd_556x45_StanagSD","RH_20Rnd_762x51_hk417","RH_20Rnd_762x51_SD_hk417","20Rnd_762x51_DMR","USSR_5Rnd_408","FHQ_rem_30Rnd_680x43_ACR","FHQ_rem_30Rnd_680x43_ACR_SD","FHQ_rem_7Rnd_338Lapua_MSR_NT","FHQ_rem_7Rnd_338Lapua_MSR_NT_SD","FHQ_rem_20Rnd_762x51_PMAG_NT","FHQ_rem_20Rnd_762x51_PMAG_NT_SD","FHQ_rem_5Rnd_300Win_XM2010_NT","FHQ_rem_5Rnd_300Win_XM2010_NT_SD","vil_10Rnd_762x39_SKS","vil_8Rnd_TT","vil_20Rnd_9x18_aps","vil_20Rnd_9x18_apsSD","vil_17Rnd_9x19_PYA","vil_20Rnd_9x39_SP6ns_OC","vil_45Rnd_545x39_AK","30Rnd_545x39_AKSD","vil_10Rnd_Mauser","vil_10Rnd_PSL","10Rnd_762x54_SVD","vil_10Rnd_762x54_SV","vil_bhp_mag","17Rnd_9x19_glock17","vil_usp45_mag","vil_usp45sd_mag","vil_32Rnd_uzi","vil_32Rnd_UZI_SD","vil_20Rnd_762x51_G3","20Rnd_762x51_FNFAL","vil_20Rnd_556x45_SG","vil_20Rnd_556x45_IN","Vil_30Rnd_556x45_HK","Vil_35Rnd_556x45_G","100Rnd_762x51_M240","200Rnd_762x54_GPMG","100Rnd_762x54_PK","vil_40Rnd_762x39_AK47","vil_75Rnd_762x39_AK47","vil_100Rnd_762x39_RPD","200Rnd_556x45_M249","100Rnd_556x45_BetaCMag","75Rnd_545x39_RPK"],["weapons","magazines"],-5000],
["FR_Cooper",["RH_m1stacog","m16a4","RH_hk416seotech","RH_hk416sd","RH_hk416sdeotech","RH_hk416eotech","RH_hk416acog","RH_hk416sdglaim","RH_hk416sdgleotech","RH_hk417acog","RH_hk417sp","RH_hk417saim","RH_hk417sacog","RH_hk417sd","RH_hk417sdacog","RH_hk417sdsp","RH_hk417sglaim","RH_ctar21m","RH_star21","RH_masacog","RH_massdeotech","RH_masbeotech","RH_masbacog","RH_masbsdacog","FHQ_ACR_GL_SD_BASE","FHQ_ACR_BASE_L","FHQ_ACR_GL_SD_BASE_F","FHQ_ACR_WDL_CCO_SD_F","FHQ_ACR_WDL_RCO_F","FHQ_ACR_WDL_RCO_SD","FHQ_ACR_WDL_RCO_GL_SD_F","FHQ_ACR_WDL_HWS_F","FHQ_ACR_WDL_HWS_GL","FHQ_ACR_WDL_G33","FHQ_ACR_WDL_G33_SD","FHQ_ACR_WDL_G33_GL_SD","FHQ_ACR_WDL_HAMR","FHQ_ACR_WDL_HAMR_SD_F","FHQ_ACR_BLK_IRN_F","FHQ_ACR_BLK_CCO_F","FHQ_ACR_BLK_CCO_GL_SD_F","FHQ_ACR_BLK_RCO","FHQ_ACR_BLK_RCO_SD_F","FHQ_ACR_BLK_HWS","FHQ_ACR_BLK_HWS_GL_SD","FHQ_ACR_BLK_G33","FHQ_ACR_BLK_G33_SD","FHQ_ACR_BLK_G33_GL","FHQ_ACR_BLK_G33_GL_SD","FHQ_ACR_TAN_IRN","FHQ_ACR_TAN_CCO","FHQ_ACR_TAN_CCO_GL_SD","FHQ_ACR_TAN_RCO","FHQ_ACR_TAN_RCO_GL_SD","FHQ_ACR_TAN_HWS","FHQ_ACR_TAN_HWS_GL","FHQ_ACR_TAN_HWS_SD","FHQ_ACR_TAN_G33_SD","FHQ_ACR_TAN_G33_GL_SD","FHQ_ACR_TAN_HAMR","FHQ_ACR_TAN_HAMR_SD","vil_SKS","vil_RPK74M_P29","vil_RPK74M","vil_AK_47_49","vil_AKMSB","vil_AKMS","vil_AK_nato_m1","vil_PMIS","vil_MPi","vil_AK_74m_EOT_FSB","vil_AK_74m_p29","vil_AK_74m_gp_29","vil_ak12_ap","vil_AeK_23","vil_AeK_3_K","vil_G3a3","vil_G3a4b","vil_G3an","vil_M4_EOT","vil_Galil_arm","vil_G36KVA4","vil_G36a2","vil_G36KV3Des","vil_HK416_Aim","VIL_HK416_EDR","RH_m21","RH_sc2acog","RH_sc2shd","RH_sc2sp","RH_m1saim","RH_m1sshd","RH_m1ssp","RH_m1stacog","RH_m1steot","RH_m1stsp","FHQ_RSASS_TAN","FHQ_XM2010_DESERT","FHQ_XM2010_SD_DESERT","FHQ_XM2010_WDL_CAMO","vil_SVDK","vil_SR25","vil_M110","vil_HK417s","vil_SR25SD","vil_M110sd","USSOF_Mk_48","BAF_L7A2","vil_PKP_EOT","vil_PK","vil_PKM","vil_RPK75_M72","vil_RPD","skavil_M60","skavil_M60e3","vil_Mg3","vil_M249_Para","vil_Minimi","vil_M240_B","vil_MG4","MG36_camo_Large","m8_SAW_Large","vil_USP45SD","vil_USP45","vil_Glock","vil_apssd","vil_APS","RH_muzi","RH_tec9","RH_vz61","RH_g19t","RH_g17sd","RH_g17","RH_m9csd","RH_tt33","RH_m1911","RH_m1911sd","RH_usp","RH_python","RH_bull","RH_anacg","RH_anac","RH_Deaglemzb","RH_Deaglemz","RH_Deagleg","RH_Deagles","G36A_camo","G36C","G36C_camo","G36K_camo","M16A2","M16A2GL","m16a4_acg","M4A1","M4A1_HWS_GL_camo","M4A3_CCO_EP1","M4A1_Aim","Sa58P_EP1","Sa58V_CCO_EP1","Sa58V_EP1","Sa58V_RCO_EP1","AKS_74_kobra","AKS_74_U","AK_47_M","AK_74","FN_FAL","M4A1_AIM_SD_camo","AK_107_kobra","AK_107_GL_kobra","AK_107_pso","AK_107_GL_pso","AKS_74_UN_kobra","SCAR_L_CQC","SCAR_L_CQC_Holo","SCAR_L_STD_Mk4CQT","SCAR_L_STD_EGLM_RCO","SCAR_L_CQC_EGLM_Holo","SCAR_L_STD_HOLO","SCAR_L_CQC_CCO_SD","SCAR_H_CQC_CCO","SCAR_H_CQC_CCO_SD","SCAR_H_STD_EGLM_Spect","BAF_L85A2_RIS_Holo","BAF_L85A2_UGL_Holo","BAF_L85A2_RIS_SUSAT","BAF_L85A2_UGL_SUSAT","BAF_L85A2_RIS_ACOG","BAF_L85A2_UGL_ACOG","AK_74_GL_kobra","m8_carbine_pmc","m8_compact_pmc","m8_holo_sd","M4A1_HWS_GL_SD_Camo","M16A4_GL","M16A4_ACG_GL","M4A1_RCO_GL","M4A1_HWS_GL","G36_C_SD_eotech","G36a","AK_47_S","AK_74_GL","AKS_74_pso","M4A3_RCO_GL_EP1"],["weapons"],0],
        ["CIV_EuroWoman01_EP1",["ItemSodaPepsi","ItemSodaCoke","FoodCanPasta","M16A2"],["magazines","weapons"],0],
["US_Delta_Force_AR_EP1",["30Rnd_556x45_Stanag","30Rnd_556x45_G36","30Rnd_545x39_AK","RH_7Rnd_50_AE","RH_6Rnd_44_Mag","RH_6Rnd_357_Mag","RH_13Rnd_9x19_bhp","RH_15Rnd_9x19_usp","RH_8Rnd_9x19_P38","RH_7Rnd_32cal_ppk","RH_8Rnd_9x19_Mk","RH_8Rnd_9x19_Mksd","RH_15Rnd_9x19_uspsd","RH_12Rnd_45cal_usp","RH_8Rnd_45cal_m1911","RH_8Rnd_762_tt33","RH_10Rnd_22LR_mk2","RH_20Rnd_9x19_M93","15Rnd_9x19_M9","15Rnd_9x19_M9SD","RH_19Rnd_9x19_g18","RH_17Rnd_9x19_g17","RH_17Rnd_9x19_g17SD","RH_20Rnd_32cal_vz61","RH_30Rnd_9x19_tec","RH_32Rnd_9x19_Muzi","30Rnd_556x45_StanagSD","RH_20Rnd_762x51_hk417","RH_20Rnd_762x51_SD_hk417","20Rnd_762x51_DMR","USSR_5Rnd_408","FHQ_rem_30Rnd_680x43_ACR","FHQ_rem_30Rnd_680x43_ACR_SD","FHQ_rem_7Rnd_338Lapua_MSR_NT","FHQ_rem_7Rnd_338Lapua_MSR_NT_SD","FHQ_rem_20Rnd_762x51_PMAG_NT","FHQ_rem_20Rnd_762x51_PMAG_NT_SD","FHQ_rem_5Rnd_300Win_XM2010_NT","FHQ_rem_5Rnd_300Win_XM2010_NT_SD","vil_10Rnd_762x39_SKS","vil_8Rnd_TT","vil_20Rnd_9x18_aps","vil_20Rnd_9x18_apsSD","vil_17Rnd_9x19_PYA","vil_20Rnd_9x39_SP6ns_OC","vil_45Rnd_545x39_AK","30Rnd_545x39_AKSD","vil_10Rnd_Mauser","vil_10Rnd_PSL","10Rnd_762x54_SVD","vil_10Rnd_762x54_SV","vil_bhp_mag","17Rnd_9x19_glock17","vil_usp45_mag","vil_usp45sd_mag","vil_32Rnd_uzi","vil_32Rnd_UZI_SD","vil_20Rnd_762x51_G3","20Rnd_762x51_FNFAL","vil_20Rnd_556x45_SG","vil_20Rnd_556x45_IN","Vil_30Rnd_556x45_HK","Vil_35Rnd_556x45_G","100Rnd_762x51_M240","200Rnd_762x54_GPMG","100Rnd_762x54_PK","vil_40Rnd_762x39_AK47","vil_75Rnd_762x39_AK47","vil_100Rnd_762x39_RPD","200Rnd_556x45_M249","100Rnd_556x45_BetaCMag","75Rnd_545x39_RPK"],["magazines"],0],
["Ins_Soldier_AR",["30Rnd_556x45_Stanag","30Rnd_556x45_G36","30Rnd_545x39_AK","RH_7Rnd_50_AE","RH_6Rnd_44_Mag","RH_6Rnd_357_Mag","RH_13Rnd_9x19_bhp","RH_15Rnd_9x19_usp","RH_8Rnd_9x19_P38","RH_7Rnd_32cal_ppk","RH_8Rnd_9x19_Mk","RH_8Rnd_9x19_Mksd","RH_15Rnd_9x19_uspsd","RH_12Rnd_45cal_usp","RH_8Rnd_45cal_m1911","RH_8Rnd_762_tt33","RH_10Rnd_22LR_mk2","RH_20Rnd_9x19_M93","15Rnd_9x19_M9","15Rnd_9x19_M9SD","RH_19Rnd_9x19_g18","RH_17Rnd_9x19_g17","RH_17Rnd_9x19_g17SD","RH_20Rnd_32cal_vz61","RH_30Rnd_9x19_tec","RH_32Rnd_9x19_Muzi","30Rnd_556x45_StanagSD","RH_20Rnd_762x51_hk417","RH_20Rnd_762x51_SD_hk417","20Rnd_762x51_DMR","USSR_5Rnd_408","FHQ_rem_30Rnd_680x43_ACR","FHQ_rem_30Rnd_680x43_ACR_SD","FHQ_rem_7Rnd_338Lapua_MSR_NT","FHQ_rem_7Rnd_338Lapua_MSR_NT_SD","FHQ_rem_20Rnd_762x51_PMAG_NT","FHQ_rem_20Rnd_762x51_PMAG_NT_SD","FHQ_rem_5Rnd_300Win_XM2010_NT","FHQ_rem_5Rnd_300Win_XM2010_NT_SD","vil_10Rnd_762x39_SKS","vil_8Rnd_TT","vil_20Rnd_9x18_aps","vil_20Rnd_9x18_apsSD","vil_17Rnd_9x19_PYA","vil_20Rnd_9x39_SP6ns_OC","vil_45Rnd_545x39_AK","30Rnd_545x39_AKSD","vil_10Rnd_Mauser","vil_10Rnd_PSL","10Rnd_762x54_SVD","vil_10Rnd_762x54_SV","vil_bhp_mag","17Rnd_9x19_glock17","vil_usp45_mag","vil_usp45sd_mag","vil_32Rnd_uzi","vil_32Rnd_UZI_SD","vil_20Rnd_762x51_G3","20Rnd_762x51_FNFAL","vil_20Rnd_556x45_SG","vil_20Rnd_556x45_IN","Vil_30Rnd_556x45_HK","Vil_35Rnd_556x45_G","100Rnd_762x51_M240","200Rnd_762x54_GPMG","100Rnd_762x54_PK","vil_40Rnd_762x39_AK47","vil_75Rnd_762x39_AK47","vil_100Rnd_762x39_RPD","200Rnd_556x45_M249","100Rnd_556x45_BetaCMag","75Rnd_545x39_RPK"],["magazines"],0],
["TK_Soldier_Crew_EP1",["30Rnd_556x45_Stanag","30Rnd_556x45_G36","30Rnd_545x39_AK","RH_7Rnd_50_AE","RH_6Rnd_44_Mag","RH_6Rnd_357_Mag","RH_13Rnd_9x19_bhp","RH_15Rnd_9x19_usp","RH_8Rnd_9x19_P38","RH_7Rnd_32cal_ppk","RH_8Rnd_9x19_Mk","RH_8Rnd_9x19_Mksd","RH_15Rnd_9x19_uspsd","RH_12Rnd_45cal_usp","RH_8Rnd_45cal_m1911","RH_8Rnd_762_tt33","RH_10Rnd_22LR_mk2","RH_20Rnd_9x19_M93","15Rnd_9x19_M9","15Rnd_9x19_M9SD","RH_19Rnd_9x19_g18","RH_17Rnd_9x19_g17","RH_17Rnd_9x19_g17SD","RH_20Rnd_32cal_vz61","RH_30Rnd_9x19_tec","RH_32Rnd_9x19_Muzi","30Rnd_556x45_StanagSD","RH_20Rnd_762x51_hk417","RH_20Rnd_762x51_SD_hk417","20Rnd_762x51_DMR","USSR_5Rnd_408","FHQ_rem_30Rnd_680x43_ACR","FHQ_rem_30Rnd_680x43_ACR_SD","FHQ_rem_7Rnd_338Lapua_MSR_NT","FHQ_rem_7Rnd_338Lapua_MSR_NT_SD","FHQ_rem_20Rnd_762x51_PMAG_NT","FHQ_rem_20Rnd_762x51_PMAG_NT_SD","FHQ_rem_5Rnd_300Win_XM2010_NT","FHQ_rem_5Rnd_300Win_XM2010_NT_SD","vil_10Rnd_762x39_SKS","vil_8Rnd_TT","vil_20Rnd_9x18_aps","vil_20Rnd_9x18_apsSD","vil_17Rnd_9x19_PYA","vil_20Rnd_9x39_SP6ns_OC","vil_45Rnd_545x39_AK","30Rnd_545x39_AKSD","vil_10Rnd_Mauser","vil_10Rnd_PSL","10Rnd_762x54_SVD","vil_10Rnd_762x54_SV","vil_bhp_mag","17Rnd_9x19_glock17","vil_usp45_mag","vil_usp45sd_mag","vil_32Rnd_uzi","vil_32Rnd_UZI_SD","vil_20Rnd_762x51_G3","20Rnd_762x51_FNFAL","vil_20Rnd_556x45_SG","vil_20Rnd_556x45_IN","Vil_30Rnd_556x45_HK","Vil_35Rnd_556x45_G","100Rnd_762x51_M240","200Rnd_762x54_GPMG","100Rnd_762x54_PK","vil_40Rnd_762x39_AK47","vil_75Rnd_762x39_AK47","vil_100Rnd_762x39_RPD","200Rnd_556x45_M249","100Rnd_556x45_BetaCMag","75Rnd_545x39_RPK"],["magazines"],0]
]; if (tfv_DEBUGGING) then { diag_log "tfv - Traders and their weapons loaded in!"; };
 
/*    *******************************************************************************************************************************************   */
/*    List of ALL weapons, regardless of trader, along with the prices.                                                                             */
/*    *******************************************************************************************************************************************   */
 
tfv_TRADERS_PRICES = [
    ["RH_m1stacog",200],
    ["m16a4",200],
    ["RH_hk416seotech",200],
    ["RH_hk416sd",400],
    ["RH_hk416sdeotech",400],
    ["RH_hk416eotech",200],
    ["RH_hk416acog",200],
    ["RH_hk416sdglaim",400],
    ["RH_hk416sdgleotech",400],
    ["RH_hk417acog",200],
    ["RH_hk417sp",300],
    ["RH_hk417saim",200],
    ["RH_hk417sacog",200],
    ["RH_hk417sd",400],
    ["RH_hk417sdacog",400],
    ["RH_hk417sdsp",1000],
    ["RH_hk417sglaim",400],
    ["RH_ctar21m",200],
    ["RH_star21",200],
    ["RH_masacog",300],
    ["RH_massdeotech",400],
    ["RH_masbeotech",200],
["RH_masbacog",200],
    ["RH_masbsdacog",400],
    ["FHQ_ACR_GL_SD_BASE",400],
    ["FHQ_ACR_BASE_L",200],
    ["FHQ_ACR_GL_SD_BASE_F",400],
    ["FHQ_ACR_WDL_CCO_SD_F",300],
    ["FHQ_ACR_WDL_RCO_F",200],
    ["FHQ_ACR_WDL_RCO_SD",300],
    ["FHQ_ACR_WDL_RCO_GL_SD_F",400],
    ["FHQ_ACR_WDL_HWS_F",200],
    ["FHQ_ACR_WDL_HWS_GL",300],
    ["FHQ_ACR_WDL_G33",200],
    ["FHQ_ACR_WDL_G33_SD",300],
    ["FHQ_ACR_WDL_G33_GL_SD",400],
    ["FHQ_ACR_WDL_HAMR",200],
    ["FHQ_ACR_WDL_HAMR_SD_F",300],
    ["FHQ_ACR_BLK_IRN_F",200],
    ["FHQ_ACR_BLK_CCO_F",400],
    ["FHQ_ACR_BLK_CCO_GL_SD_F",200],
    ["FHQ_ACR_BLK_RCO",300],
    ["FHQ_ACR_BLK_RCO_SD_F",200],
    ["FHQ_ACR_BLK_HWS",400],
["FHQ_ACR_BLK_HWS_GL_SD",200],
    ["FHQ_ACR_BLK_G33",300],
    ["FHQ_ACR_BLK_G33_SD",300],
    ["FHQ_ACR_BLK_G33_GL",400],
    ["FHQ_ACR_BLK_G33_GL_SD",200],
    ["FHQ_ACR_TAN_IRN",200],
    ["FHQ_ACR_TAN_CCO",400],
    ["FHQ_ACR_TAN_CCO_GL_SD",200],
    ["FHQ_ACR_TAN_RCO",400],
    ["FHQ_ACR_TAN_RCO_GL_SD",200],
    ["FHQ_ACR_TAN_HWS",300],
    ["FHQ_ACR_TAN_HWS_GL",300],
    ["FHQ_ACR_TAN_HWS_SD",300],
    ["FHQ_ACR_TAN_G33_SD",600],
    ["FHQ_ACR_TAN_G33_GL_SD",200],
    ["FHQ_ACR_TAN_HAMR",300],
    ["FHQ_ACR_TAN_HAMR_SD",300],
    ["vil_SKS",200],
    ["vil_RPK74M_P29",500],
    ["vil_RPK74M",500],
    ["vil_AK_47_49",200],
    ["vil_AKMSB",200],
["vil_AKMS",200],
    ["vil_AK_nato_m1",200],
    ["vil_PMIS",200],
    ["vil_MPi",200],
    ["vil_AK_74m_EOT_FSB",200],
    ["vil_AK_74m_p29",200],
    ["vil_AK_74m_gp_29",200],
    ["vil_ak12_ap",200],
    ["vil_AeK_23",200],
    ["vil_AeK_3_K",200],
    ["vil_G3a3",200],
    ["vil_G3a4b",200],
    ["vil_G3an",200],
    ["vil_M4_EOT",200],
    ["vil_Galil_arm",200],
    ["vil_G36KVA4",200],
    ["vil_G36a2",200],
    ["vil_G36KV3Des",200],
    ["vil_HK416_Aim",200],
    ["VIL_HK416_EDR",200],
["RH_m21",500],
    ["RH_sc2acog",500],
    ["RH_sc2shd",500],
    ["RH_sc2sp",500],
    ["RH_m1saim",500],
    ["RH_m1sshd",500],
    ["RH_m1ssp",500],
    ["RH_m1stacog",500],
    ["RH_m1steot",500],
    ["RH_m1stsp",500],
    ["FHQ_RSASS_TAN",600],
    ["FHQ_XM2010_DESERT",600],
    ["FHQ_XM2010_SD_DESERT",100],
    ["FHQ_XM2010_WDL_CAMO",600],
    ["vil_SVDK",600],
    ["vil_SR25",500],
    ["vil_M110",500],
    ["vil_HK417s",500],
    ["vil_SR25SD",700],
    ["vil_M110sd",100],
    ["USSOF_Mk_48",100],
    ["BAF_L7A2",500],
    ["vil_PKP_EOT",500],
    ["vil_PK",500],
    ["vil_PKM",600],
    ["vil_RPK75_M72",600],
    ["vil_RPD",100],
    ["skavil_M60",600],
    ["skavil_M60e3",600],
    ["vil_Mg3",500],
    ["vil_M249_Para",500],
    ["vil_Minimi",500],
    ["vil_M240_B",700],
    ["vil_MG4",100],
    ["MG36_camo_Large",300],
    ["m8_SAW_Large",300],
    ["30Rnd_556x45_Stanag",50],
["30Rnd_556x45_G36",50],
    ["30Rnd_545x39_AK",50],
    ["RH_7Rnd_50_AE",50],
    ["RH_6Rnd_44_Mag",50],
    ["RH_6Rnd_357_Mag",50],
    ["RH_13Rnd_9x19_bhp",50],
    ["RH_15Rnd_9x19_usp",50],
    ["RH_8Rnd_9x19_P38",50],
    ["RH_7Rnd_32cal_ppk",50],
    ["RH_8Rnd_9x19_Mk",50],
    ["RH_8Rnd_9x19_Mksd",50],
    ["RH_15Rnd_9x19_uspsd",50],
    ["RH_12Rnd_45cal_usp",50],
    ["RH_8Rnd_45cal_m1911",50],
    ["RH_8Rnd_762_tt33",50],
    ["RH_10Rnd_22LR_mk2",50],
    ["RH_20Rnd_9x19_M93",50],
    ["15Rnd_9x19_M9",50],
    ["15Rnd_9x19_M9SD",50],
    ["RH_19Rnd_9x19_g18",50],
["RH_17Rnd_9x19_g17",50],
    ["RH_17Rnd_9x19_g17SD",50],
    ["RH_20Rnd_32cal_vz61",50],
    ["RH_30Rnd_9x19_tec",50],
    ["RH_32Rnd_9x19_Muzi",50],
    ["30Rnd_556x45_StanagSD",50],
    ["RH_20Rnd_762x51_hk417",50],
    ["RH_20Rnd_762x51_SD_hk417",50],
    ["20Rnd_762x51_DMR",50],
    ["USSR_5Rnd_408",50],
    ["FHQ_rem_30Rnd_680x43_ACR",50],
    ["FHQ_rem_30Rnd_680x43_ACR_SD",50],
    ["FHQ_rem_7Rnd_338Lapua_MSR_NT",50],
    ["FHQ_rem_7Rnd_338Lapua_MSR_NT_SD",50],
    ["FHQ_rem_20Rnd_762x51_PMAG_NT",50],
    ["FHQ_rem_20Rnd_762x51_PMAG_NT_SD",50],
    ["FHQ_rem_5Rnd_300Win_XM2010_NT",50],
    ["FHQ_rem_5Rnd_300Win_XM2010_NT_SD",50],
    ["vil_10Rnd_762x39_SKS",50],
    ["vil_8Rnd_TT",50],
    ["vil_20Rnd_9x18_aps",50],
    ["vil_20Rnd_9x18_apsSD",50],
    ["vil_17Rnd_9x19_PYA",50],
    ["vil_20Rnd_9x39_SP6ns_OC",50],
    ["vil_45Rnd_545x39_AK",50],
    ["30Rnd_545x39_AKSD",50],
    ["vil_10Rnd_Mauser",50],
    ["vil_10Rnd_PSL",50],
    ["10Rnd_762x54_SVD",50],
    ["vil_10Rnd_762x54_SV",50],
    ["vil_bhp_mag",50],
    ["17Rnd_9x19_glock17",50],
    ["vil_usp45_mag",50],
    ["vil_usp45sd_mag",50],
    ["vil_32Rnd_uzi",50],
    ["vil_32Rnd_UZI_SD",50],
    ["vil_20Rnd_762x51_G3",50],
    ["20Rnd_762x51_FNFAL",50],
    ["vil_20Rnd_556x45_SG",50],
    ["vil_20Rnd_556x45_IN",50],
    ["Vil_30Rnd_556x45_HK",50],
    ["Vil_35Rnd_556x45_G",50],
    ["100Rnd_762x51_M240",50],
    ["200Rnd_762x54_GPMG",50],
    ["100Rnd_762x54_PK",50],
    ["vil_40Rnd_762x39_AK47",50],
    ["vil_75Rnd_762x39_AK47",50],
    ["vil_100Rnd_762x39_RPD",50],
    ["200Rnd_556x45_M249",50],
    ["100Rnd_556x45_BetaCMag",50],
    ["75Rnd_545x39_RPK",50],
    ["vil_USP45SD",100],
    ["vil_USP45",100],
    ["vil_Glock",100],
    ["vil_apssd",100],
    ["vil_APS",100],
    ["RH_muzi",100],
    ["RH_tec9",100],
    ["RH_vz61",100],
    ["RH_g19t",100],
    ["RH_g17sd",100],
    ["RH_g17",100],
    ["RH_m9csd",100],
    ["RH_tt33",100],
    ["RH_m1911",100],
    ["RH_m1911sd",100],
    ["RH_usp",100],
    ["RH_python",100],
    ["RH_bull",100],
    ["RH_anacg",100],
    ["RH_anac",100],
    ["RH_Deaglemzb",100],
    ["RH_Deaglemz",100],
    ["RH_Deagleg",100],
    ["RH_Deagles",100],
    ["G36A_camo",300],
["G36C",300],
["G36C_camo",300],
["G36K_camo",300],
["M16A2",100],
["M16A2GL",200],
["m16a4_acg",200],
["M4A1",200],
["M4A1_HWS_GL_camo",400],
["M4A3_CCO_EP1",500],
["M4A1_Aim",400],
["Sa58P_EP1",100],
["Sa58V_CCO_EP1",400],
["Sa58V_EP1",100],
["Sa58V_RCO_EP1",400],
["AKS_74_kobra",200],
["AKS_74_U",100],
["AK_47_M",600],
["AK_74",100],
["FN_FAL",500],
["M4A1_AIM_SD_camo",500],
["AK_107_kobra",300],
["AK_107_GL_kobra",500],
["AK_107_pso",500],
["AK_107_GL_pso",500],
["AKS_74_UN_kobra",500],
["SCAR_L_CQC",600],
["SCAR_L_CQC_Holo",600],
["SCAR_L_STD_Mk4CQT",600],
["SCAR_L_STD_EGLM_RCO",800],
["SCAR_L_CQC_EGLM_Holo",800],
["SCAR_L_STD_HOLO",500],
["SCAR_L_CQC_CCO_SD",500],
["SCAR_H_CQC_CCO",700],
["SCAR_H_CQC_CCO_SD",700],
["SCAR_H_STD_EGLM_Spect",800],
["BAF_L85A2_RIS_Holo",400],
["BAF_L85A2_UGL_Holo",400],
["BAF_L85A2_RIS_SUSAT",400],
["BAF_L85A2_UGL_SUSAT",400],
["BAF_L85A2_RIS_ACOG",400],
["BAF_L85A2_UGL_ACOG",400],
["AK_74_GL_kobra",400],
["m8_carbine_pmc",400],
["m8_compact_pmc",400],
["m8_holo_sd",400],
["M4A1_HWS_GL_SD_Camo",300],
["M16A4_GL",300],
["M16A4_ACG_GL",400],
["M4A1_RCO_GL",300],
["M4A1_HWS_GL",300],
["G36_C_SD_eotech",300],
["G36a",200],
["AK_47_S",400],
["AK_74_GL",400],
["AKS_74_pso",500],
["M4A3_RCO_GL_EP1",300],
["ItemSodaPepsi",1],
["ItemSodaCoke",3],
["FoodCanPasta",5]
]; if (tfv_DEBUGGING) then { { diag_log format ["tfv - Price loaded - %1",_x]; } forEach tfv_TRADERS_PRICES; };
 
/*    *******************************************************************************************************************************************   */
/*    Anything below this line was not intended to be modified.                                                                                     */
/*    *******************************************************************************************************************************************   */
 
tfv_TRADERS = [];
{ tfv_TRADERS set [(count tfv_TRADERS),(_x select 0)]; } forEach tfv_TRADERS_ITEMS;
tfv_TRADERS_TYPES = [];
{ tfv_TRADERS_TYPES set [(count tfv_TRADERS_TYPES),(_x select 2)]; } forEach tfv_TRADERS_ITEMS;
if (tfv_DEBUGGING) then { { diag_log format ["tfv - Trader loaded - %1",_x]; } forEach tfv_TRADERS; };
tfv_SALE_SUCCESS_STRING = "Sold %1 weapons from your vehicle";
tfv_SALE_SUCCESS_STRING_MAGS = "Sold %1 items from your vehicle";
tfv_PREP_FOR_TRADE = "Starting trade in %1 seconds, move to cancel";
tfv_CANCELLED_TRADE = "Trade cancelled";
tfv_STARTING_TRADE = "Starting trade";
tfv_TRADE_STEPS = "Trading, stage %1 of %2";
tfv_TRADE_CANCELLED_END = "Trade cancelled\nMake sure your vehicle is empty and isn't moving";
tfv_SIDENOTE = "You were paid an %1";
tfv_VEHICLE_CONFIRM = "Trading from %1";
tfv_NO_WEAPONS = "There is no weapons inside your vehicle (%1)";
tfv_NO_MAGAZINES = "There is no items inside your vehicle (%1)";
tfv_ACTION_INDEX = -1;
tfv_ACTION = 0;
tfv_ACTION_INDEX_MAGS = -1;
tfv_ACTION_MAGS = 0;
tfv_IS_TRADING = false;
tfv_EXCHANGE = [
["ItemBriefcase100oz",10000],
["ItemBriefcase90oz",9000],
["ItemBriefcase80oz",8000],
["ItemBriefcase70oz",7000],
["ItemBriefcase60oz",6000],
["ItemBriefcase50oz",5000],
["ItemBriefcase40oz",4000],
["ItemBriefcase30oz",3000],
["ItemBriefcase20oz",2000],
["ItemGoldBar10oz",1000],
["ItemGoldBar9oz",900],
["ItemGoldBar8oz",800],
["ItemGoldBar7oz",700],
["ItemGoldBar6oz",600],
["ItemGoldBar5oz",500],
["ItemGoldBar4oz",400],
["ItemGoldBar3oz",300],
["ItemGoldBar2oz",200],
["ItemGoldBar",100],
["ItemBriefcaseS90oz",90],
["ItemBriefcaseS80oz",80],
["ItemBriefcaseS70oz",70],
["ItemBriefcaseS60oz",60],
["ItemBriefcaseS50oz",50],
["ItemBriefcaseS40oz",40],
["ItemBriefcaseS30oz",30],
["ItemBriefcaseS20oz",20],
["ItemSilverBar10oz",10],
["ItemSilverBar9oz",9],
["ItemSilverBar8oz",8],
["ItemSilverBar7oz",7],
["ItemSilverBar6oz",6],
["ItemSilverBar5oz",5],
["ItemSilverBar4oz",4],
["ItemSilverBar3oz",3],
["ItemSilverBar2oz",2],
    ["ItemSilverBar",1]
]; if (tfv_DEBUGGING) then { { diag_log format ["tfv - Exchange loaded - %1",_x]; } forEach tfv_EXCHANGE; };
 
/*    *******************************************************************************************************************************************   */
/*    Functions.                                                                                                                                    */
/*    *******************************************************************************************************************************************   */
 
tfv_fnc_aConcat =        compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_aConcat.sqf";
tfv_fnc_checkTrade =     compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_checkTrade.sqf";
tfv_fnc_Convert =        compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_Convert.sqf";
tfv_fnc_findPrices =     compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_findPrices.sqf";
tfv_fnc_findTrWeapons =  compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_findTrWeapons.sqf";
tfv_fnc_getSteps =       compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_getSteps.sqf";
tfv_fnc_payTrade =       compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_payTrade.sqf";
tfv_fnc_wCount =         compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_wCount.sqf";
tfv_fnc_mCount =         compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_mCount.sqf";
tfv_fnc_checkTradeMags = compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_checkTradeMags.sqf";
tfv_fnc_aConcatMags =    compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_aConcatMags.sqf";
tfv_fnc_getStepsMags =   compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_getStepsMags.sqf";
tfv_fnc_payTradem =      compile preprocessFileLineNumbers "TradeFromVehicle\functions\fnc_payTradem.sqf";
 
/*    *******************************************************************************************************************************************   */
/*    Init file finished. Start monitor script.    */    [] ExecVM "TradeFromVehicle\monitor.sqf";
/*    *******************************************************************************************************************************************   */

Link to comment
Share on other sites

 

Not working for me (I added a lot of guns ;p) I've looked and can't seem to find anything. Just wondering if you could take a look at it, second set of eyes.

 

Init from trade

http://pastebin.com/n6GBdrap

 

From Init.sqf

if (!isDedicated) then {
	[]ExecVM "TradeFromVehicle\init.sqf";
	//Conduct map operations

Check your lines 636 - 642.

I'm not (yet) using this script but those lines seem odd :D

Link to comment
Share on other sites

 

Not working for me (I added a lot of guns ;p) I've looked and can't seem to find anything. Just wondering if you could take a look at it, second set of eyes.

 

Init from trade

http://pastebin.com/n6GBdrap

 

From Init.sqf

if (!isDedicated) then {
	[]ExecVM "TradeFromVehicle\init.sqf";
	//Conduct map operations

i don't have the time right now to look through it, im quite busy. in the mean time, before i get a chance to look at it, you could place

systemChat "1";

at certain intervals down your init, increment the number by one each time. when you get in game it will count up from 1 so you can see. if, for  example, it gets to systemChat "6" but not 7, you know which section the problem lies in

Link to comment
Share on other sites

I seem to be having some reliability issues with this.  I came in with a full truck and sold everything and it worked beautifully.  Went out to do some more farming, filled my truck up again, and then came in and the menu would not come up.  I relogged but still no menu.  So I travelled to a different trader area, still no menu at the other trader city.  Looked in arma2oaserver.RPT and I have no errors.  Any thoughts?

Link to comment
Share on other sites

 

Don't want to have to hand update the gun list for this mod?

 

I came up with the SQL needed to generate the list.

 

First you will need a split function:

CREATE FUNCTION SPLIT_STR(
x VARCHAR(255),
delim VARCHAR(12),
pos INT
)
RETURNS VARCHAR(255)
RETURN REPLACE(SUBSTRING(SUBSTRING_INDEX(x, delim, pos),
LENGTH(SUBSTRING_INDEX(x, delim, pos -1)) + 1),
delim, '');

Then just run the query below and copy the results into the init array.

SELECT item,
	case SPLIT_STR(sell,',',2)
		when '\"ItemGoldBar10oz\"' then  
			(concat(SPLIT_STR(item,',',1) ,',',replace(SPLIT_STR(sell,',',1),'[','')*1000,'],') )
		when '\"ItemGoldBar\"' then 
			(concat(SPLIT_STR(item,',',1) ,',',replace(SPLIT_STR(sell,',',1),'[','')*100,'],') )
		when '\"ItemSilverBar10oz\"' then  
			(concat(SPLIT_STR(item,',',1) ,',',replace(SPLIT_STR(sell,',',1),'[','')*10,'],') )
		when '\"ItemSilverBar\"' then 
			(concat(SPLIT_STR(item,',',1) ,',',replace(SPLIT_STR(sell,',',1),'[',''),'],') )
		
	end as list
FROM traders_data where afile in ('trade_weapons','trade_items')
group by item
order by list 

um how do I copy the results ?? HeidiSQL

would love to copy one column the item and then the list. since they need to be separated anyways

when I click select all and copy it only copies one cell

Link to comment
Share on other sites

"I seem to be having some reliability issues with this.  I came in with a full truck and sold everything and it worked beautifully.  Went out to do some more farming, filled my truck up again, and then came in and the menu would not come up.  I relogged but still no menu.  So I travelled to a different trader area, still no menu at the other trader city.  Looked in arma2oaserver.RPT and I have no errors.  Any thoughts?"

 

It seems it works once per trader per restart.  Any thoughts anyone?

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
×
×
  • Create New...