100% Custom Loot tables - TUTORIAL

I am having bad luck with where to include the config.hpp line in the description. It says to place it at the top of the file, which i did ( and I tried several other locations as well, to no avail) and get stuck at wait for host. Where does it go exactly?


Code:
#include "cfgBuildingLoot.hpp"
respawn = "BASE";
respawndelay = 5;
onLoadMission= "DayZ Chernarus";
OnLoadIntro = "Welcome to Chernarus";
OnLoadIntroTime = False;

Is what I tried first
 
Code:
#include "cfgBuildingLoot.hpp"
respawn = "BASE";
respawndelay = 5;
onLoadMission= "DayZ Chernarus";
OnLoadIntro = "Welcome to Chernarus";
OnLoadIntroTime = False;

Is what I tried first

resolved my issue, went through every file and examined every line. Apparently i accidentally deleted a } in the configloot.hpp , wasn't a description.sqf error after all.
 
Here are my edits for the two files so far. Barracks are still a little weak in my opinion vs ATC towers. You will find a comment with the default setting to the right of each line if it has changed.

CfgLoot.hpp
Code:
class CfgLoot {
    //0.10
    attachments[] = {
        //{"Attachment_AIM",0.03},
        //{"Attachment_GL",0.03},
        //{"Attachment_Kobra",0.03},
        //{"Attachment_CAMO",0.03},
        //{"Attachment_Pso",0.03},
        //{"Attachment_Silencer",0.01}
    };
    craft[] = {
            //{"equip_wood_pallet",0.03},
            //{"equip_string",0.03},
            //{"equip_scrap_electronics",0.01},
            //{"equip_rope",0.02},
            //{"equip_rag",0.02},
            //{"equip_pvc_box",0.01},
            //{"equip_paper_sheet",0.02},
            //{"equip_paint",0.02},
            //{"equip_note",0.01},
            //{"equip_needle",0.01},
            //{"equip_nail",0.02},
            //{"equip_metal_sheet",0.03},
            //{"equip_scrap_metal",0.03},
            //{"equip_laser",0.01},
            //{"equip_hose_clamp",0.01},
            //{"equip_gauze",0.01},
            //{"equip_empty_barrel",0.01},
            //{"equip_duct_tape",0.03},
            //{"equip_d_battery",0.01},
            //{"equip_cable_tie",0.03},
            //{"equip_aa_battery",0.01},
            //{"equip_2inch_metal_pipe",0.01},
            //{"equip_1inch_metal_pipe",0.02},
            //{"ItemNails",0.01},
            //{"equip_rail_screws",0.01},
            //{"equip_weapon_rails",0.01}
    };
    trash[] = {
            {"ItemSodaCokeEmpty",0.01}, //0.05
            {"ItemSodaPepsiEmpty",0.01}, //0.03
            {"FoodCanUnlabeledEmpty",0.01}, //0.05
            {"FoodCanRusUnlabeledEmpty",0.01}, //0.02
            {"FoodCanRusPorkEmpty",0.01}, //0.02
            {"FoodCanRusPeasEmpty",0.01}, //0.03
            {"FoodCanRusMilkEmpty",0.01}, //0.02
            {"FoodCanRusCornEmpty",0.01}, //0.05
            {"FoodCanRusStewEmpty",0.01}, //0.03
            {"TrashTinCan",0.01}, //0.05
            {"TrashJackDaniels",0.01}, //0.02
            {"ItemSodaEmpty",0.01}, //0.03
            {"ItemTrashToiletpaper",0.01},
            {"ItemTrashRazor",0.01},
            {"ItemCards",0.01}, //0.02
            {"ItemNails",0.01}
    };
    civilian[] = {
            {"TrashTinCan",0.01}, //0.03
            {"TrashJackDaniels",0.01}, //0.03
            {"ItemSodaEmpty",0.04},
            {"ItemSodaCoke",0.05},
            {"ItemSodaPepsi",0.05},
            {"FoodCanBakedBeans",0.05},
            {"FoodCanSardines",0.05},
            {"FoodCanFrankBeans",0.05},
            {"FoodCanPasta",0.05},
            {"8Rnd_9x18_Makarov",0.04},
            {"7Rnd_45ACP_1911",0.04},
            {"2Rnd_shotgun_74Slug",0.04},
            {"2Rnd_shotgun_74Pellets",0.04},
            {"ItemBandage",0.06},
            {"ItemPainkiller",0.03}
    };
    food[] = {
            {"TrashTinCan",0.01}, //0.05
            {"TrashJackDaniels",0.01}, //0.05
            {"ItemSodaEmpty",0.01}, //0.05
            {"ItemSodaCoke",0.05},
            {"ItemSodaPepsi",0.05},
            {"ItemSodaMtngreen",0.01},
            {"ItemSodaR4z0r",0.01},
            {"ItemSodaClays",0.01},
            {"ItemSodaSmasht",0.01},
            {"ItemSodaDrwaste",0.01},
            {"ItemSodaLemonade",0.01},
            {"ItemSodaLvg",0.01},
            {"ItemSodaMzly",0.01},
            {"ItemSodaRabbit",0.01},
            {"FoodCanBakedBeans",0.05},
            {"FoodCanSardines",0.05},
            {"FoodCanFrankBeans",0.05},
            {"FoodCanPasta",0.05},
            {"FoodCanBadguy",0.01},
            {"FoodCanBoneboy",0.01},
            {"FoodCanCorn",0.01},
            {"FoodCanCurgon",0.01},
            {"FoodCanDemon",0.01},
            {"FoodCanFraggleos",0.01},
            {"FoodCanHerpy",0.001},
            {"FoodCanDerpy",0.01},
            {"FoodCanOrlok",0.01},
            {"FoodCanPowell",0.01},
            {"FoodCanTylers",0.01},
            {"FoodCanUnlabeled",0.04},
            {"FoodPistachio",0.03},
            {"FoodNutmix",0.04},
            {"FoodChipsSulahoops",0.01},
            {"FoodChipsMysticales",0.01},
            {"FoodCandyAnders",0.01},
            {"FoodCandyLegacys",0.01},
            {"FoodCandyMintception",0.01},
            {"FoodCanRusUnlabeled",0.05},
            {"FoodCanRusStew",0.05},
            {"FoodCanRusPork",0.05},
            {"FoodCanRusPeas",0.05},
            {"FoodCanRusMilk",0.04},
            {"FoodCanRusCorn",0.05}
    };
    generic[] = {
            {"TrashTinCan",0.01}, //0.06
            {"ItemSodaEmpty",0.01}, //0.06
            {"ItemSodaCoke",0.03},
            {"ItemSodaPepsi",0.02},
            {"TrashJackDaniels",0.01}, //0.04
            {"FoodCanBakedBeans",0.01},
            {"FoodCanSardines",0.01},
            {"FoodCanFrankBeans",0.01},
            {"FoodCanPasta",0.01},
            {"ItemWaterbottleUnfilled",0.01},
            {"ItemBandage",0.03},
            {"7Rnd_45ACP_1911",0.03},
            {"5x_22_LR_17_HMR",0.01},
            {"10x_303",0.04},
            {"6Rnd_45ACP",0.04},
            {"2Rnd_shotgun_74Slug",0.05},
            {"2Rnd_shotgun_74Pellets",0.05},
            {"8Rnd_9x18_Makarov",0.09},
            {"ItemWaterbottle",0.01},
            {"15Rnd_W1866_Slug",0.02},
            {"WoodenArrow",0.04},
            {"HandRoadFlare",0.07},
            {"ItemPainkiller",0.02},
            {"HandChemGreen",0.01},
            {"HandChemBlue",0.03},
            {"HandChemRed",0.03},
            {"ItemHeatPack",0.04},
            {"ItemNails",0.01}
    };
    medical[] = {
            {"ItemBandage",0.08},
            {"ItemPainkiller",0.05},
            {"ItemMorphine",0.05},
            {"ItemEpinephrine",0.03},
            {"ItemAntibiotic",0.03}, //0.01
            {"ItemHeatPack",0.03}
    };
    hospital[] = {
            {"ItemBandage",0.25}, //0.06
            {"ItemPainkiller",0.12}, //0.04
            {"ItemMorphine",0.10}, //0.04
            {"ItemEpinephrine",0.03},
            {"ItemBloodbag",0.12}, //0.03
            {"ItemAntibiotic",0.03} //0.01
    };
    military[] = {
            {"TrashTinCan",0.01}, //0.06
            {"ItemSodaEmpty",0.01}, //0.06
            {"ItemSodaCoke",0.04},
            {"ItemSodaPepsi",0.04},
            {"ItemBandage",0.04},
            {"ItemAntibiotic",0.02}, //0.01
            {"ItemPainkiller",0.02},
            {"ItemMorphine",0.01},
            {"30Rnd_556x45_Stanag",0.02},
            {"75Rnd_545x39_RPK",0.02},
            {"20Rnd_762x51_DMR",0.02},
            {"17Rnd_9x19_glock17",0.05},
            {"15Rnd_9x19_M9SD",0.01},
            {"8Rnd_9x18_MakarovSD",0.01},
            {"15Rnd_9x19_M9",0.03},
            {"30Rnd_762x39_AK47",0.02},
            {"30Rnd_545x39_AK",0.02},
            {"5Rnd_762x51_M24",0.01},
            //{"10Rnd_127x99_m107",0.01},
            {"8Rnd_B_Beneli_74Slug",0.04},
            {"1Rnd_HE_M203",0.01},
            {"FlareWhite_M203",0.02},
            {"FlareGreen_M203",0.02},
            {"1Rnd_Smoke_M203",0.01},       
            {"200Rnd_556x45_M249",0.01},
            {"HandGrenade_west",0.01},
            {"SmokeShell",0.04},
            {"SmokeShellRed",0.04},
            {"SmokeShellGreen",0.04},
            {"8Rnd_B_Beneli_Pellets",0.04},
            {"30Rnd_556x45_StanagSD",0.01},
            {"30Rnd_9x19_MP5",0.02},
            {"30Rnd_9x19_MP5SD",0.01},
            {"100Rnd_762x51_M240",0.01},
            {"HandChemGreen",0.04},
            {"HandChemBlue",0.04},
            {"HandChemRed",0.04},
            {"ItemHeatPack",0.04},
            {"FoodMRE",0.03}
    };
    militaryWEST[] = {
            {"ItemBandage",0.06},
            {"ItemAntibiotic",0.01},
            {"ItemPainkiller",0.06},
            {"ItemMorphine",0.02},
            {"ItemWaterbottleUnfilled",0.02},
            {"30Rnd_556x45_Stanag",0.04},
            {"17Rnd_9x19_glock17",0.05},
            {"7Rnd_45ACP_1911",0.05},
            {"15Rnd_9x19_M9",0.02},
            {"8Rnd_B_Beneli_74Slug",0.04},
            {"1Rnd_HE_M203",0.01},
            {"FlareWhite_M203",0.01},
            {"FlareGreen_M203",0.01},
            {"1Rnd_Smoke_M203",0.01},   
            {"HandGrenade_west",0.01},
            {"SmokeShell",0.04},
            {"SmokeShellRed",0.02},
            {"SmokeShellGreen",0.02},
            {"30Rnd_9x19_MP5",0.02},
            {"HandChemGreen",0.02},
            {"HandChemBlue",0.02},
            {"HandChemRed",0.02},
            {"FoodMRE",0.01},
            {"ItemHeatPack",0.02}
    };
    militaryEAST[] = {
            {"ItemBandage",0.06},
            {"ItemAntibiotic",0.02}, //0.01
            {"ItemPainkiller",0.06},
            {"ItemMorphine",0.02},
            {"HandGrenade_east",0.01},
            {"75Rnd_545x39_RPK",0.03},
            {"30Rnd_762x39_AK47",0.04},
            {"30Rnd_545x39_AK",0.04},
            {"8Rnd_B_Beneli_74Slug",0.08},
            {"ItemHeatPack",0.02},
            {"30Rnd_9x19_UZI",0.02},
            {"SmokeShell",0.02},
            {"SmokeShellRed",0.02},
            {"SmokeShellGreen",0.02}
    };
    policeman[] = {
            {"ItemBandage",0.10},
            {"7Rnd_45ACP_1911",0.03},
            {"6Rnd_45ACP",0.03},
            {"15Rnd_W1866_Slug",0.03},
            {"8Rnd_B_Beneli_74Slug",0.03},
            {"HandRoadFlare",0.05}
    };
    hunter[] = {
            {"ItemBandage",0.5},
            {"5x_22_LR_17_HMR",0.03},
            {"7Rnd_45ACP_1911",0.02},
            {"10x_303",0.03},
            {"ItemWaterbottleUnfilled",0.02},
            {"WoodenArrow",0.5},
            {"ItemHeatPack",0.02},
            {"FoodMRE",0.03},
            {"FoodNutmix",0.03}
        };
};

CfgBuildingLoot.hpp http://pastebin.com/rDeCB1s3
 
Here are my edits for the two files so far. Barracks are still a little weak in my opinion vs ATC towers. You will find a comment with the default setting to the right of each line if it has changed.

CfgLoot.hpp
Code:
class CfgLoot {
    //0.10
    attachments[] = {
        //{"Attachment_AIM",0.03},
        //{"Attachment_GL",0.03},
        //{"Attachment_Kobra",0.03},
        //{"Attachment_CAMO",0.03},
        //{"Attachment_Pso",0.03},
        //{"Attachment_Silencer",0.01}
    };
    craft[] = {
            //{"equip_wood_pallet",0.03},
            //{"equip_string",0.03},
            //{"equip_scrap_electronics",0.01},
            //{"equip_rope",0.02},
            //{"equip_rag",0.02},
            //{"equip_pvc_box",0.01},
            //{"equip_paper_sheet",0.02},
            //{"equip_paint",0.02},
            //{"equip_note",0.01},
            //{"equip_needle",0.01},
            //{"equip_nail",0.02},
            //{"equip_metal_sheet",0.03},
            //{"equip_scrap_metal",0.03},
            //{"equip_laser",0.01},
            //{"equip_hose_clamp",0.01},
            //{"equip_gauze",0.01},
            //{"equip_empty_barrel",0.01},
            //{"equip_duct_tape",0.03},
            //{"equip_d_battery",0.01},
            //{"equip_cable_tie",0.03},
            //{"equip_aa_battery",0.01},
            //{"equip_2inch_metal_pipe",0.01},
            //{"equip_1inch_metal_pipe",0.02},
            //{"ItemNails",0.01},
            //{"equip_rail_screws",0.01},
            //{"equip_weapon_rails",0.01}
    };
    militaryWEST[] = {
            {"ItemBandage",0.06},
            {"ItemAntibiotic",0.01},
            {"ItemPainkiller",0.06},
            {"ItemMorphine",0.02},
            {"ItemWaterbottleUnfilled",0.02},
            {"30Rnd_556x45_Stanag",0.04},
            {"17Rnd_9x19_glock17",0.05},
            {"7Rnd_45ACP_1911",0.05},
            {"15Rnd_9x19_M9",0.02},
            {"8Rnd_B_Beneli_74Slug",0.04},
            {"1Rnd_HE_M203",0.01},
            {"FlareWhite_M203",0.01},
            {"FlareGreen_M203",0.01},
            {"1Rnd_Smoke_M203",0.01}, 
            {"HandGrenade_west",0.01},
            {"SmokeShell",0.04},
            {"SmokeShellRed",0.02},
            {"SmokeShellGreen",0.02},
            {"30Rnd_9x19_MP5",0.02},
            {"HandChemGreen",0.02},
            {"HandChemBlue",0.02},
            {"HandChemRed",0.02},
            {"FoodMRE",0.01},
            {"ItemHeatPack",0.02}
    };
    militaryEAST[] = {
            {"ItemBandage",0.06},
            {"ItemAntibiotic",0.02}, //0.01
            {"ItemPainkiller",0.06},
            {"ItemMorphine",0.02},
            {"HandGrenade_east",0.01},
            {"75Rnd_545x39_RPK",0.03},
            {"30Rnd_762x39_AK47",0.04},
            {"30Rnd_545x39_AK",0.04},
            {"8Rnd_B_Beneli_74Slug",0.08},
            {"ItemHeatPack",0.02},
            {"30Rnd_9x19_UZI",0.02},
            {"SmokeShell",0.02},
            {"SmokeShellRed",0.02},
            {"SmokeShellGreen",0.02}
    };
    policeman[] = {
            {"ItemBandage",0.10},
            {"7Rnd_45ACP_1911",0.03},
            {"6Rnd_45ACP",0.03},
            {"15Rnd_W1866_Slug",0.03},
            {"8Rnd_B_Beneli_74Slug",0.03},
            {"HandRoadFlare",0.05}
    };
    hunter[] = {
            {"ItemBandage",0.5},
            {"5x_22_LR_17_HMR",0.03},
            {"7Rnd_45ACP_1911",0.02},
            {"10x_303",0.03},
            {"ItemWaterbottleUnfilled",0.02},
            {"WoodenArrow",0.5},
            {"ItemHeatPack",0.02},
            {"FoodMRE",0.03},
            {"FoodNutmix",0.03}
        };
};

CfgBuildingLoot.hpp http://pastebin.com/rDeCB1s3

Are you finding loot reliably? because for some reason even with my increased loot chances and such, I can still run into a hospital and find only one loot pile or a firestation and find nothing. It's annoying me to no end.
 
my problem is, I fixed most of the drops, but still, hospitals chance to appear are low, but in my file is chance=1... cant understand that.
 
my problem is, I fixed most of the drops, but still, hospitals chance to appear are low, but in my file is chance=1... cant understand that.

My loot chance is 1 for every building, and I am still getting barely any loot xD
 
It still works for me on 1.7.7.1 with the right files but I have no loot on my heli crashes could there be anything in these files messing that up? I can't find anything wrong.
 
It still works for me on 1.7.7.1 with the right files but I have no loot on my heli crashes could there be anything in these files messing that up? I can't find anything wrong.

Seems like it messes up the heli crash loot and the Trash/rubbel that rocket put in.

Beside that the loot works fine
 
Is moving all the files, such as spawn_loot and zombies, etc really needed? Couldn't you just move some stuff over and cause it to point only to the hpp file that changes the loot variables?
 
Is moving all the files, such as spawn_loot and zombies, etc really needed? Couldn't you just move some stuff over and cause it to point only to the hpp file that changes the loot variables?

Those files have codes that point to the loot variables in your dayz_code. If you don't move them and edit them, then the server will get confused and stop working.
 
It still works for me on 1.7.7.1 with the right files but I have no loot on my heli crashes could there be anything in these files messing that up? I can't find anything wrong.

Same problem here, getting this in my rpt:

Code:
13:51:53 "CRASHSPAWNER: Starting spawn logic for Crash Spawner"
13:51:53 "CRASHSPAWNER: Spawning 'Mi-8 Wreck' with loot table 'HeliCrashEAST' at Vybor [42:67]"
13:51:53 "z\addons\dayz_server\compile\fn_bases.sqf found a nice spot at Novy Lug [99:43] (9)"
13:51:54 "Infected Camps: Loot spawn at 'Camp2_Small:[9879.9,11024.9,0]' with loot table '["ItemWatch","generic",0.05]'"
13:51:54 "Infected Camps: Loot spawn at 'Camp2_Small:[9859.05,11036.6,0]' with loot table '["Colt1911","weapon",0.04]'"
13:51:54 UH60Wreck_DZ: MainTurret - unknown animation source mainTurret
13:51:54 UH60Wreck_DZ: MainGun - unknown animation source mainGun
13:51:54 UH60Wreck_DZ: MachineGun_1 - unknown animation source Gatling_1
13:51:55 Wrong text element 'null'
13:51:55 Wrong text element 'null'
13:51:55 Wrong text element 'null'
13:51:55 Wrong text element 'null'
13:51:55 "CRASHSPAWNER: Spawning 'UH-60 Wreck' with loot table 'HeliCrashWEST' at Old Fields [72:56]"
13:51:55 Error in expression < 1, _lootpos, 1] call spawn_loot;
_item setVariable ["permaLoot",true];
 
if (day>
13:51:55  Error position: <setVariable ["permaLoot",true];
 
if (day>
13:51:55  Error setvariable: Type Nothing, expected Namespace,Object,Group,Team member,Task,Location
13:51:55 File z\addons\dayz_server\compile\server_spawnCrashSite.sqf, line 101
 
Back
Top