Jump to content

Issues with Traders, Vehicles, and Redis-Database


SirCannibal

Recommended Posts

I am currently running the 436 build of Epoch 0.3.8.0 on a local server. Every time I start a fresh database, as well as on any map, everything loads up fine. The trader inventory is as I have it set to like so:

starterTraderItems[] = { {
//VEHICLES:

//epoch vehicles
"C_Offroad_01_EPOCH","C_Hatchback_01_EPOCH","C_Hatchback_02_EPOCH","C_SUV_01_EPOCH","C_Quadbike_01_EPOCH","ebike_epoch","B_Truck_01_transport_EPOCH","B_Truck_01_covered_EPOCH","B_Truck_01_box_EPOCH","B_Heli_Light_01_EPOCH","B_Heli_Transport_03_unarmed_EPOCH","I_Heli_Transport_02_EPOCH","I_Heli_light_03_unarmed_EPOCH","O_Heli_Light_02_unarmed_EPOCH","O_Heli_Transport_04_EPOCH","O_Heli_Transport_04_bench_EPOCH","O_Heli_Transport_04_box_EPOCH","O_Heli_Transport_04_covered_EPOCH",//ADDED
//cup vehicles
"CUP_B_BAF_Coyote_GMG_W","CUP_B_BAF_Coyote_GMG_D","CUP_B_BAF_Coyote_L2A1_D","CUP_B_BAF_Coyote_L2A1_W","CUP_B_M1128_MGS_Desert","CUP_B_FV510_GB_D_SLAT","CUP_B_AH64D_AT_USA","CUP_B_AH64D_ES_USA","CUP_B_AH1Z","CUP_B_Merlin_HC3A_GB","CUP_B_AW159_Cannon_GB","CUP_B_AW159_Hellfire_GB","CUP_B_CH53E_USMC","CUP_O_Ka52_RU","CUP_O_Mi24_V_RU","CUP_B_UH60M_US","CUP_B_UH1Y_GUNSHIP_USMC","CUP_B_AV8B_CAP_USMC","CUP_B_F35B_AA_USMC","CUP_B_MV22_USMC",//ADDED
//vanilla vehicles
"B_Truck_01_ammo_F","B_Truck_01_fuel_F","I_MRAP_03_hmg_F","B_MRAP_01_hmg_F","B_APC_Wheeled_01_cannon_F","O_APC_Wheeled_02_rcws_F","I_APC_Wheeled_03_cannon_F","I_APC_tracked_03_cannon_F","B_MBT_01_cannon_F","B_MBT_01_arty_F","I_MBT_03_cannon_F","B_Heli_Transport_01_F","B_Heli_Light_01_armed_F","B_Heli_Transport_03_F","B_Heli_Transport_03_black_F","B_Heli_Transport_03_unarmed_green_F","I_Heli_light_03_F","O_Heli_Light_02_F","B_Heli_Attack_01_F","O_Heli_Attack_02_F",//ADDED
//DLC vehicles
"K01","K02","K03","K04","Land_Pod_Heli_Transport_04_bench_F","Land_Pod_Heli_Transport_04_covered_F","Land_Pod_Heli_Transport_04_medevac_F","Land_Pod_Heli_Transport_04_box_F","Land_Pod_Heli_Transport_04_fuel_F","Land_Pod_Heli_Transport_04_repair_F","Land_Pod_Heli_Transport_04_ammo_F",//ADDED

//ITEMS:

//food
"ItemSodaBurst","ItemSodaRbull","FoodWalkNSons","meatballs_epoch","scam_epoch","sweetcorn_epoch","FoodSnooter",//ADDED
//epoch items
"VehicleRepair","jerrycan_epoch","NVG_EPOCH","EnergyPack",//ADDED
//vanillia items
"FAK","Binocular","Rangefinder","ItemGPS",//ADDED

//WEAPONS:

//handguns
"hgun_ACPC2_F","hgun_Rook40_F","hgun_P07_F","hgun_Pistol_heavy_01_F","hgun_Pistol_heavy_02_F",//ADDED
//smg's
"SMG_01_F","SMG_02_F","hgun_PDW2000_F",//ADDED
//rifles
"m4a3_EPOCH","m16_EPOCH","AKM_EPOCH","arifle_MXC_F","arifle_MX_F","arifle_MX_GL_F","arifle_MXM_F","arifle_MX_SW_F",//ADDED
//lmg's
"m249_EPOCH","m249Tan_EPOCH","MMG_01_hex_F","MMG_01_tan_F","MMG_02_camo_F","MMG_02_black_F","MMG_02_sand_F",//ADDED
//snipers
"sr25_epoch","srifle_LRR_F","m107_EPOCH","m107Tan_EPOCH","srifle_EBR_F","srifle_DMR_02_F","srifle_DMR_02_camo_F","srifle_DMR_02_sniper_F","srifle_DMR_03_F","srifle_DMR_03_khaki_F","srifle_DMR_03_tan_F","srifle_DMR_03_multicam_F","srifle_DMR_03_woodland_F","srifle_DMR_03_spotter_F","srifle_DMR_04_Tan_F","srifle_DMR_05_blk_F","srifle_DMR_05_hex_F","srifle_DMR_05_tan_f","srifle_DMR_06_camo_F","srifle_DMR_06_olive_F",//ADDED
//launchers
"launch_NLAW_F","launch_RPG32_F","launch_Titan_F","launch_Titan_short_F",//ADDED

//MAGAZINES:

//handgun ammo
"9Rnd_45ACP_Mag","11Rnd_45ACP_Mag","16Rnd_9x21_Mag","6Rnd_45ACP_Cylinder",//ADDED
//smg ammo
"9mm_30Rnd_Mag","30Rnd_9x21_Mag","30Rnd_45ACP_Mag_SMG_01",//ADDED
//rifle ammo
"30Rnd_556x45_Stanag","30Rnd_762x39_Mag","30Rnd_65x39_caseless_mag","100Rnd_65x39_caseless_mag",//ADDED
//lmg ammo
"200Rnd_556x45_M249","130Rnd_338_Mag","150Rnd_93x64_Mag",//ADDED
//sniper ammo
"20Rnd_762x51_Mag","10Rnd_127x54_Mag","10Rnd_338_Mag","10Rnd_93x64_DMR_05_Mag","7Rnd_408_Mag","5Rnd_127x108_Mag",//ADDED
//throwables
"HandGrenade","MiniGrenade","SmokeShell",//ADDED
//launcher ammo
"Titan_AA","RPG32_F","NLAW_F","Titan_AT","1Rnd_HE_Grenade_shell","UGL_FlareWhite_F","UGL_FlareGreen_F","UGL_FlareRed_F","UGL_FlareYellow_F","UGL_FlareCIR_F",//ADDED

//ATTACHMENTS:

//side attachments
"acc_flashlight","acc_pointer_IR",//ADDED
//optics
"optic_Arco","optic_Hamr","optic_Holosight","optic_SOS","optic_MRCO","optic_DMS","optic_Yorris","optic_MRD","optic_LRPS","optic_NVS","optic_Nightstalker","optic_AMS","optic_AMS_khk","optic_AMS_snd","optic_KHS_blk","optic_KHS_hex","optic_KHS_old","optic_KHS_tan",//ADDED
//Muzzles
"muzzle_snds_H","muzzle_snds_L","muzzle_snds_M","muzzle_snds_B","muzzle_snds_H_MG","muzzle_snds_acp","muzzle_sr25S_epoch","muzzle_snds_338_black","muzzle_snds_338_green","muzzle_snds_93mmg","muzzle_snds_93mmg_tan",//ADDED
//bipods
"bipod_01_F_snd","bipod_01_F_blk","bipod_01_F_mtp","bipod_02_F_blk","bipod_02_F_tan","bipod_02_F_hex","bipod_03_F_blk","bipod_03_F_oli",//ADDED

//CLOTHING:

//headwear
"H_70_EPOCH","H_17_EPOCH","H_22_EPOCH","H_9_EPOCH","H_2_EPOCH","H_35_EPOCH","H_37_EPOCH","H_38_EPOCH","H_33_EPOCH","H_30_EPOCH",//ADDED
//vests
"V_11_EPOCH","V_7_EPOCH","V_12_EPOCH","V_22_EPOCH",//ADDED
//uniforms
"U_O_PilotCoveralls","U_O_CombatUniform_ocamo","U_ghillie1_uniform","U_O_GhillieSuit","U_O_FullGhillie_lsh","U_O_FullGhillie_sard","U_O_FullGhillie_ard","U_OG_Guerilla2_1","U_OG_Guerilla2_3","U_OG_Guerilla3_2","U_Camo_uniform","U_CamoBlue_uniform","U_CamoBrn_uniform","U_CamoRed_uniform",//ADDED
//backpacks
"B_Kitbag_rgr","B_Kitbag_cbr","B_TacticalPack_oli","B_TacticalPack_blk",//ADDED

//CUP WEAPONS:

//handguns
"CUP_hgun_Glock17","CUP_hgun_M9",//ADDED
//smg's
"CUP_smg_MP5A5",//ADDED
//rifles
"CUP_arifle_G36C","CUP_arifle_M4A1","CUP_arifle_M16A2",//ADDED
//snipers
"CUP_srifle_LeeEnfield_rail",//ADDED
//launchers
"CUP_glaunch_M32","CUP_launch_Igla","CUP_launch_Javelin","CUP_launch_M47","CUP_launch_M136","CUP_launch_MAAWS_Scope","CUP_launch_Metis","CUP_launch_NLAW","CUP_launch_RPG7V","CUP_launch_RPG18","CUP_launch_Mk153Mod0_SMAWOptics","CUP_launch_FIM92Stinger","CUP_launch_9K32Strela",//ADDED

//CUP MAGAZINES

//shotgun ammo
"CUP_20Rnd_B_AA12_Pellets","CUP_8Rnd_B_Beneli_74Slug","CUP_8Rnd_B_Saiga12_74Slug_M",//ADDED
//handgun ammo
"CUP_15Rnd_9x19_M9","CUP_17Rnd_9x19_glock17","CUP_18Rnd_9x19_Phantom","CUP_6Rnd_45ACP_M","CUP_7Rnd_45ACP_1911","CUP_8Rnd_9x18_Makarov_M","CUP_8Rnd_9x18_MakarovSD_M",//ADDED
//smg ammo
"CUP_30Rnd_9x19_EVO","CUP_30Rnd_9x19_MP5","CUP_64Rnd_9x19_Bizon_M",//ADDED
//rifle ammo
"CUP_20Rnd_762x51_FNFAL_M","CUP_20Rnd_762x51_B_SCAR","CUP_20Rnd_762x51_CZ805B","CUP_30Rnd_545x39_AK_M","CUP_30Rnd_556x45_G36","CUP_30Rnd_556x45_Stanag","CUP_30Rnd_762x39_AK47_M","CUP_30Rnd_Sa58_M",//ADDED
//lmg ammo
"CUP_100Rnd_556x45_BetaCMag","CUP_100Rnd_TE4_Green_Tracer_556x45_M249","CUP_100Rnd_TE4_LRT4_Red_Tracer_762x51_Belt_M","CUP_100Rnd_TE4_LRT4_762x54_PK_Tracer_Green_M","CUP_200Rnd_TE4_Green_Tracer_556x45_L110A1","CUP_200Rnd_TE4_Green_Tracer_556x45_M249","CUP_75Rnd_TE4_LRT4_Green_Tracer_545x39_RPK_M",//ADDED
//sniper ammo
"CUP_10Rnd_127x99_M107","CUP_10Rnd_762x51_CZ750","CUP_10Rnd_762x54_SVD_M","CUP_10Rnd_9x19_Compact","CUP_10Rnd_9x39_SP5_VSS_M","CUP_10x_303_M","CUP_20Rnd_762x51_DMR","CUP_20Rnd_762x51_B_M110","CUP_5Rnd_127x108_KSVK_M","CUP_5Rnd_127x99_as50_M","CUP_5Rnd_762x51_M24","CUP_5Rnd_86x70_L115A1","CUP_5x_22_LR_17_HMR_M",//ADDED
//throwables
"CUP_HandGrenade_L109A1_HE","CUP_HandGrenade_RGD5","CUP_HandGrenade_M67",//ADDED
//launcher ammo
"CUP_1Rnd_HE_GP25_M","CUP_1Rnd_HEDP_M203","CUP_6Rnd_HE_M203","CUP_AT13_M","CUP_Dragon_EP1_M","CUP_Igla_M","CUP_Javelin_M","CUP_M136_M","CUP_MAAWS_HEAT_M","CUP_MAAWS_HEDP_M","CUP_NLAW_M","CUP_OG7_M","CUP_PG7VL_M","CUP_PG7VR_M","CUP_PipeBomb_M","CUP_RPG18_M","CUP_SMAW_HEAA_M","CUP_SMAW_HEDP_M","CUP_Stinger_M","CUP_Strela_2_M",//ADDED
//extras
"CUP_Mine_M"//ADDED
}, {999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999,999} };

I have even edited the pricing list to accept all of these new vehicles and weapons, ect. The problem I am experiencing is this list of items and quantities not staying consistent within the traders after both the server and database has been shutdown and restarted. After a restart, it seems the database, through redis database manager, shows that the traders have this exact inventory when in all reality they actually have only some of items and only a quantity of 100 for the items that do show. If I flush the trader keys in the database before booting up the server and database after a restart they show the correct items and quantities. I believe this to be a bug, or am I missing something? On the previous version of epoch that I was running (epoch 0.3.2.0) I did not have this issue.

Another problem I have is the vehicles. This may not be a bug, but it seems that I cannot get past the issue of vehicles exceeding maximum slots on my server. No matter what I set, the database exceeds the maximum values for vehicles. I currently have this set in the config to allow vehicles to be bought from traders and it seems to work (so far):

		allowedVehiclesList_CUP[] = {
			{"",5}
			/*
			{"C_Offroad_01_EPOCH",4},
		    {"C_Quadbike_01_EPOCH",4},
		    {"C_Hatchback_01_EPOCH",5},
		    {"C_Hatchback_02_EPOCH",5},
		    {"C_SUV_01_EPOCH",0},
		    {"C_Rubberboat_EPOCH",0},
		    {"C_Rubberboat_02_EPOCH",0},
		    {"C_Rubberboat_03_EPOCH",0},
		    {"C_Rubberboat_04_EPOCH",0},
		    {"C_Van_01_box_EPOCH",4},
		    {"C_Van_01_transport_EPOCH",4},
		    {"C_Boat_Civil_01_EPOCH",0},
		    {"C_Boat_Civil_01_police_EPOCH",0},
		    {"C_Boat_Civil_01_rescue_EPOCH",0},
		    {"B_Heli_Light_01_EPOCH",2},
		    {"B_SDV_01_EPOCH",0},
		    {"B_MRAP_01_EPOCH",2},
			{"I_MRAP_03_EPOCH", 2},
		    {"B_Truck_01_transport_EPOCH",1},
		    {"B_Truck_01_covered_EPOCH",2},
		    {"B_Truck_01_mover_EPOCH",1},
		    {"B_Truck_01_box_EPOCH",1},
		    {"O_Truck_02_covered_EPOCH",0},
		    {"O_Truck_02_transport_EPOCH",0},
		    {"O_Truck_03_covered_EPOCH",0},
		    {"O_Truck_02_box_EPOCH",0},
		    {"I_Heli_light_03_unarmed_EPOCH",1},
		    {"O_Heli_Light_02_unarmed_EPOCH",1},
		    {"I_Heli_Transport_02_EPOCH",1},
		    {"O_Heli_Transport_04_EPOCH",1},
		    {"O_Heli_Transport_04_bench_EPOCH",1},
		    {"O_Heli_Transport_04_box_EPOCH",1},
		    {"O_Heli_Transport_04_covered_EPOCH",1},
		    {"B_Heli_Transport_03_unarmed_EPOCH",1},
		    {"jetski_epoch",0},
		    {"K01",1},
		    {"K02",1},
		    {"K03",1},
		    {"K04",1},
		    {"ebike_epoch",3},
		    {"mosquito_epoch",3},
			{"C_Heli_Light_01_civil_EPOCH",2},
			{"CUP_C_Fishing_Boat_Chernarus",2},
			{"CUP_C_LR_Transport_CTK",2},
			{"CUP_B_Zodiac_USMC",0},
			{"CUP_C_Skoda_Red_CIV",2},
			{"CUP_C_Skoda_White_CIV",2},
			{"CUP_C_Skoda_Blue_CIV",2},
			{"CUP_C_Skoda_Green_CIV",2},
			{"CUP_C_SUV_CIV",2},
			{"CUP_B_HMMWV_Transport_USA",2},
			{"CUP_B_HMMWV_Unarmed_USA",2},
			{"CUP_C_SUV_TK",2},
			{"CUP_B_LR_Transport_CZ_D",2},
			{"CUP_C_Datsun_Covered",0},
			{"CUP_C_Datsun_Plain",0},
			{"CUP_C_Datsun_Tubeframe",0},
			{"CUP_C_Datsun_4seat",0},
			{"CUP_C_Datsun",0},
			{"CUP_C_Golf4_green_Civ",2},
			{"CUP_C_Golf4_red_Civ",2},
			{"CUP_C_Golf4_blue_Civ",2},
			{"CUP_C_Golf4_black_Civ",2},
			{"CUP_C_Golf4_kitty_Civ",2},
			{"CUP_C_Golf4_reptile_Civ",2},
			{"CUP_C_Golf4_camodigital_Civ",2},
			{"CUP_C_Golf4_camodark_Civ",2},
			{"CUP_C_Golf4_camo_Civ",2},
			{"CUP_B_M1030",2},
			{"CUP_C_Ural_Civ_03",2},
			{"CUP_C_Ural_Open_Civ_03",2},
			{"CUP_C_Ural_Civ_02",2},
			{"CUP_B_TowingTractor_USMC",2},
			{"CUP_C_C47_CIV",2},
			{"CUP_B_LR_Transport_CZ_W",2},
			{"CUP_C_Golf4_white_Civ",2},
			{"CUP_C_Golf4_whiteblood_Civ",2},
			{"CUP_C_Golf4_yellow_Civ",2},
			{"CUP_C_Octavia_CIV",2},
			{"CUP_C_Ural_Civ_01",2},
			{"CUP_C_Ural_Open_Civ_01",2},
			{"CUP_B_Ural_CDF",2},
			{"CUP_B_Ural_Open_CDF",2},
			{"CUP_C_Ural_Open_Civ_02",2},
			{"CUP_B_HMMWV_Ambulance_USA",2},
			{"CUP_C_UAZ_Unarmed_TK_CIV",2},
			{"CUP_C_UAZ_Open_TK_CIV",2},
			{"CUP_B_UAZ_Unarmed_CDF",2},
			{"CUP_B_Ural_Empty_CDF",2},
			{"CUP_C_DC3_CIV",2}
			*/
		};
	};

It allows me to buy up to 5 vehicles from the traders before needing to be deleted. If I make that value any higher while there are vehicles already saved to the database then it bugs out and goes straight to the maximum amount of vehicles I have set in the config. Are these known issues with this version of Epoch???

Does anyone have any solution at all to fixing these two problems??

Thank you to all who look this over and give me advice or feedback. I really appreciate it!

Link to comment
Share on other sites

54 minutes ago, He-Man said:

I think you misunderstood the Epoch mod.

What you need is a Blackmarket Trader:

 

For some reason I figured this would cause similar issues to what I am experiencing. I will give this a try instead of the standard epoch traders. I always liked the standard epoch trader system, but if it won't work the way I want it to then I will resort to the blackmarket trader system. Thanks for the reply and your time!

Link to comment
Share on other sites

There are limits on how many Items a trader can have and this can be overridden with adding a 'CfgTraderLimits' class to your description.ext or sandbox_config.hpp (Note that CfgTraderLimits does not exist, you must create one)

class CfgTraderLimits { 
	ItemSodaBurst = 999;
  	jerrycan_epoch = 999;
};

vehicle limits are tied to the max vehicle spawn limits for each class.

For example if the limit here https://github.com/EpochModTeam/Epoch/blob/master/Sources/epoch_server_settings/config.cpp#L66 is set to 8 for C_Offroad_01_EPOCH

It should make sure that no more than 8 vehicles of that type are either spawned in the world or available on the traders. This is so that vehicles that are on the trader can actually be purchased without exceeding the max vehicle limits.

 

Link to comment
Share on other sites

On ‎4‎/‎28‎/‎2016 at 8:27 AM, vbawol said:

There are limits on how many Items a trader can have and this can be overridden with adding a 'CfgTraderLimits' class to your description.ext or sandbox_config.hpp (Note that CfgTraderLimits does not exist, you must create one)


class CfgTraderLimits { 
	ItemSodaBurst = 999;
  	jerrycan_epoch = 999;
};

vehicle limits are tied to the max vehicle spawn limits for each class.

For example if the limit here https://github.com/EpochModTeam/Epoch/blob/master/Sources/epoch_server_settings/config.cpp#L66 is set to 8 for C_Offroad_01_EPOCH

It should make sure that no more than 8 vehicles of that type are either spawned in the world or available on the traders. This is so that vehicles that are on the trader can actually be purchased without exceeding the max vehicle limits.

 

Sorry for not getting back to you sooner, AWOL. First off, thank you for reviewing my topic. Also, thank you for suggesting the CfgTraderLimits. I had no idea this existed so it will be very useful to me. I understand how the vehicle slot system works, but the problem is that it is limiting players on being able to purchase vehicles because no slots are available. It would be awesome if there was a separate vehicle slot limit instead of running directly off the allowedVehicleList. I have incorporated the blackmarket trader system suggested by He-Man and that seems to fulfill a lot of fixes to what I was experiencing. For the mean time I will just use this trader system for my purposes. Thanks for your time and keep up the awesome work on Epoch. It's an awesome mod and my friends and I love it!

 

Cheers!

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
  • Discord

×
×
  • Create New...