Jump to content
  • 0

Adding items to loot tables


Hux

Question

I'm trying to add Rabbitman beer to my loot tables but I'm unsure how to do this.

 

I'm using overpoch custom loot tables and I want to add Rabbitman beer to the market spawns.

 

How do I do this?

 

If someone would be so kind as to post an example from a loot table file.

 

Thank you.

Link to comment
Share on other sites

6 answers to this question

Recommended Posts

  • 0

Yes, its classname is ItemSodaRabbit. There are 2 options. 

 

1. If you dont mind it spawning in other places that food and drinks would spawn. 

 

Open CfgLoot.hpp and find

 

 

trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
 
and change it to this
 
trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"ItemSodaRabbit",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
 
you can change the #s to increase/decrease spawn chance

 
 
 
2. If you only want it to spawn in residential areas this is what i THINK would work. Anyone feel free to correct if im wrong.
 

Find both CfgLoot.hpp and CfgBuildingLoot.hpp. Open CfgLoot.hpp and change
 
class CfgLoot {
trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
 
into
 
class CfgLoot {
trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
class CfgLoot {
beer[] = {
{"ItemSodaRabbit",0.25},
};
 
Then open CfgBuildingLoot.hpp and find 
 
 
class Residential: Default {
zombieChance = 0.3;
maxRoaming = 2;
zombieClass[] = {"zZombie_Base","z_hunter","z_teacher","z_villager1","z_villager2","z_villager3"};
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemWatch","generic",0.04},
{"ItemCompass","generic",0.03},
{"ItemMap","weapon",0.02},
{"ItemFlashlight","generic",0.01},
{"ItemKnife","generic",0.04},
{"ItemMatchbox_DZE","generic",0.01},
{"","generic",0.32},
{"backpacks","backpacks",0.04},
{"tents","tents",0.01},
{"","military",0.02},
{"","trash",0.17},
{"Binocular","weapon",0.02},
{"PartPlywoodPack","magazine",0.02},
{"clothes","clothes",0.01},
{"specialclothes","specialclothes",0.01},
{"WeaponHolder_MeleeCrowbar","object",0.03},
{"pistols", "cfglootweapon", 0.04 },
{"shotgunsingleshot", "cfglootweapon", 0.04 }
};
 
 
and change it too
 
class Residential: Default {
zombieChance = 0.3;
maxRoaming = 2;
zombieClass[] = {"zZombie_Base","z_hunter","z_teacher","z_villager1","z_villager2","z_villager3"};
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemWatch","generic",0.04},
{"ItemCompass","generic",0.03},
{"ItemMap","weapon",0.02},
{"ItemFlashlight","generic",0.01},
{"ItemKnife","generic",0.04},
{"ItemMatchbox_DZE","generic",0.01},
{"","generic",0.32},
{"backpacks","backpacks",0.04},
{"tents","tents",0.01},
{"","military",0.02},
{"","trash",0.17},
{"","beer",0.17},
{"Binocular","weapon",0.02},
{"PartPlywoodPack","magazine",0.02},
{"clothes","clothes",0.01},
{"specialclothes","specialclothes",0.01},
{"WeaponHolder_MeleeCrowbar","object",0.03},
{"pistols", "cfglootweapon", 0.04 },
{"shotgunsingleshot", "cfglootweapon", 0.04 }
};

 
Hope this works for you!
Link to comment
Share on other sites

  • 0

 

Yes, its classname is ItemSodaRabbit. There are 2 options. 

 

1. If you dont mind it spawning in other places that food and drinks would spawn. 

 

Open CfgLoot.hpp and find

 

 

trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
 
and change it to this
 
trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"ItemSodaRabbit",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
 
you can change the #s to increase/decrease spawn chance

 
 
 
2. If you only want it to spawn in residential areas this is what i THINK would work. Anyone feel free to correct if im wrong.
 

Find both CfgLoot.hpp and CfgBuildingLoot.hpp. Open CfgLoot.hpp and change
 
class CfgLoot {
trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
 
into
 
class CfgLoot {
trash[] = {
{"ItemSodaCoke",0.5},
{"ItemSodaPepsi",0.05},
{"FoodCanBakedBeans",0.25},
{"FoodCanSardines",0.1},
{"FoodCanFrankBeans",0.1}
};
class CfgLoot {
beer[] = {
{"ItemSodaRabbit",0.25},
};
 
Then open CfgBuildingLoot.hpp and find 
 
 
class Residential: Default {
zombieChance = 0.3;
maxRoaming = 2;
zombieClass[] = {"zZombie_Base","z_hunter","z_teacher","z_villager1","z_villager2","z_villager3"};
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemWatch","generic",0.04},
{"ItemCompass","generic",0.03},
{"ItemMap","weapon",0.02},
{"ItemFlashlight","generic",0.01},
{"ItemKnife","generic",0.04},
{"ItemMatchbox_DZE","generic",0.01},
{"","generic",0.32},
{"backpacks","backpacks",0.04},
{"tents","tents",0.01},
{"","military",0.02},
{"","trash",0.17},
{"Binocular","weapon",0.02},
{"PartPlywoodPack","magazine",0.02},
{"clothes","clothes",0.01},
{"specialclothes","specialclothes",0.01},
{"WeaponHolder_MeleeCrowbar","object",0.03},
{"pistols", "cfglootweapon", 0.04 },
{"shotgunsingleshot", "cfglootweapon", 0.04 }
};
 
 
and change it too
 
class Residential: Default {
zombieChance = 0.3;
maxRoaming = 2;
zombieClass[] = {"zZombie_Base","z_hunter","z_teacher","z_villager1","z_villager2","z_villager3"};
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemWatch","generic",0.04},
{"ItemCompass","generic",0.03},
{"ItemMap","weapon",0.02},
{"ItemFlashlight","generic",0.01},
{"ItemKnife","generic",0.04},
{"ItemMatchbox_DZE","generic",0.01},
{"","generic",0.32},
{"backpacks","backpacks",0.04},
{"tents","tents",0.01},
{"","military",0.02},
{"","trash",0.17},
{"","beer",0.17},
{"Binocular","weapon",0.02},
{"PartPlywoodPack","magazine",0.02},
{"clothes","clothes",0.01},
{"specialclothes","specialclothes",0.01},
{"WeaponHolder_MeleeCrowbar","object",0.03},
{"pistols", "cfglootweapon", 0.04 },
{"shotgunsingleshot", "cfglootweapon", 0.04 }
};

 
Hope this works for you!

 

 

Oh man I tried your first suggestion. I got in game and headed to the Irish Pub and what do you know........Beer!

 

That worked great. Thank you very much for your help.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...