Finish updating loot system to 1.8 with custom epoch features

This commit is contained in:
[VB]AWOL
2014-05-09 14:23:09 -05:00
parent feec3e19f5
commit 9b52797f84
8 changed files with 585 additions and 367 deletions

View File

@@ -8,7 +8,16 @@ class CfgBuildingLoot {
zombieClass[] = {"zZombie_Base","z_hunter","z_teacher","z_suit1","z_suit2","z_worker1","z_worker2","z_worker3","z_villager1","z_villager2","z_villager3"};
lootChance = 0;
lootPos[] = {};
lootPosSmall[] = {};
lootPosZombie[] = {};
itemType[] = {};
itemChance[] = {};
lootTypeSmall[] = {};
itemChanceSmall[] = {};
hangPos[] = {};
vehPos[] = {};
};
@@ -66,25 +75,43 @@ class CfgBuildingLoot {
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemSodaMdew","magazine",0.01}
,{"ItemSodaRbull","magazine",0.01}
,{"ItemSodaOrangeSherbet","magazine",0.02}
,{"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.36}
,{"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}
{"ItemSodaMdew","magazine",0.01},
{"ItemSodaRbull","magazine",0.01},
{"ItemSodaOrangeSherbet","magazine",0.02},
{"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.36},
{"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}
};
lootTypeSmall[] = {
{ "ItemSodaMdew","magazine",0.01 },
{ "ItemSodaRbull","magazine",0.01 },
{ "ItemSodaOrangeSherbet","magazine",0.02 },
{ "ItemWatch","weapon",0.05 },
{ "ItemCompass","weapon",0.04 },
{ "ItemMap","weapon",0.03 },
{ "pistols","cfglootweapon",0.12 },
{ "ItemFlashlight","weapon",0.02 },
{ "ItemKnife","weapon",0.04 },
{ "ItemMatchbox_DZE","weapon",0.03 },
{ "","generic",0.38 },
{ "","military",0.04 },
{ "","trash",0.17 },
{ "Binocular","weapon",0.02 },
{ "clothes","single",0.01},
{ "specialclothes","single",0.01 }
};
};
class Office: Default {
@@ -94,27 +121,46 @@ class CfgBuildingLoot {
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemSodaMdew","magazine",0.01}
,{"ItemSodaRbull","magazine",0.01}
,{"ItemSodaOrangeSherbet","magazine",0.02}
,{"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.31}
,{"backpacks","backpacks",0.04}
,{"tents","tents",0.01}
,{"","military",0.02}
,{"","trash",0.21}
,{"Binocular","weapon",0.02}
,{"PartPlywoodPack","magazine",0.02}
,{"clothes","clothes",0.01}
,{"specialclothes","specialclothes",0.01}
,{"WeaponHolder_MeleeCrowbar","object",0.03}
,{"ItemBriefcaseEmpty","magazine",0.01}
,{"ItemDocument","magazine",0.01}
{"ItemSodaMdew","magazine",0.01},
{"ItemSodaRbull","magazine",0.01},
{"ItemSodaOrangeSherbet","magazine",0.02},
{"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.31},
{"backpacks","backpacks",0.04},
{"tents","tents",0.01},
{"","military",0.02},
{"","trash",0.21},
{"Binocular","weapon",0.02},
{"PartPlywoodPack","magazine",0.02},
{"clothes","clothes",0.01},
{"specialclothes","specialclothes",0.01},
{"WeaponHolder_MeleeCrowbar","object",0.03},
{"ItemBriefcaseEmpty","magazine",0.01},
{"ItemDocument","magazine",0.01}
};
lootTypeSmall[] = {
{ "ItemSodaMdew","magazine",0.01 },
{ "ItemSodaRbull","magazine",0.01 },
{ "ItemSodaOrangeSherbet","magazine",0.02 },
{ "ItemWatch","weapon",0.05 },
{ "ItemCompass","weapon",0.04 },
{ "ItemMap","weapon",0.03 },
{ "pistols","cfglootweapon",0.15 },
{ "ItemFlashlight","weapon",0.02 },
{ "ItemKnife","weapon",0.05 },
{ "ItemMatchbox_DZE","weapon",0.03 },
{ "","generic",0.31 },
{ "","military",0.04 },
{ "","trash",0.03 },
{ "Binocular","weapon",0.02 },
{ "clothes","single",0.16 },
{ "specialclothes","single",0.02 },
{ "ItemDocument","magazine",0.01 }
};
};
class Industrial: Default {
@@ -124,26 +170,33 @@ class CfgBuildingLoot {
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemGenerator","magazine",0.01}
,{"ItemFuelBarrelEmpty","magazine",0.01}
,{"","generic",0.17}
,{"","trash",0.25}
,{"","military",0.04}
,{"PartGeneric","magazine",0.04}
,{"PartWheel","magazine",0.05}
,{"PartFueltank","magazine",0.02}
,{"PartEngine","magazine",0.02}
,{"PartGlass","magazine",0.04}
,{"PartVRotor","magazine",0.01}
,{"ItemJerrycan","magazine",0.04}
,{"WeaponHolder_ItemHatchet_DZE","object",0.07}
,{"ItemKnife","military",0.07}
,{"ItemToolbox","weapon",0.06}
,{"ItemWire","magazine",0.01}
,{"ItemTankTrap","magazine",0.04}
,{"ItemKeyKit","weapon",0.01}
,{"CinderBlocks","magazine",0.03}
,{"MortarBucket","magazine",0.01}
{"ItemGenerator","magazine",0.01},
{"ItemFuelBarrelEmpty","magazine",0.01},
{"","generic",0.17},
{"","trash",0.25},
{"","military",0.04},
{"PartGeneric","magazine",0.04},
{"PartWheel","magazine",0.05},
{"PartFueltank","magazine",0.02},
{"PartEngine","magazine",0.02},
{"PartGlass","magazine",0.04},
{"PartVRotor","magazine",0.01},
{"ItemJerrycan","magazine",0.04},
{"WeaponHolder_ItemHatchet_DZE","object",0.07},
{"ItemKnife","military",0.07},
{"ItemToolbox","weapon",0.06},
{"ItemWire","magazine",0.01},
{"ItemTankTrap","magazine",0.04},
{"ItemKeyKit","weapon",0.01},
{"CinderBlocks","magazine",0.03},
{"MortarBucket","magazine",0.01}
};
lootTypeSmall[] = {
{ "","generic",0.5 },
{ "","trash",0.28 },
{ "","military",0.14 },
{ "ItemKnife","weapon",0.07 },
{ "ItemKeyKit","weapon",0.01 }
};
};
class IndustrialFuel: Default {
@@ -153,24 +206,31 @@ class CfgBuildingLoot {
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"ItemGenerator","magazine",0.01}
,{"fuel_pump_kit","magazine",0.01}
,{"","generic",0.18}
,{"","trash",0.28}
,{"","military",0.04}
,{"PartGeneric","magazine",0.04}
,{"PartWheel","magazine",0.05}
,{"PartFueltank","magazine",0.02}
,{"PartEngine","magazine",0.02}
,{"PartGlass","magazine",0.04}
,{"PartVRotor","magazine",0.01}
,{"ItemJerrycan","magazine",0.04}
,{"WeaponHolder_ItemHatchet_DZE","object",0.07}
,{"ItemKnife","military",0.07}
,{"ItemToolbox","weapon",0.06}
,{"ItemWire","magazine",0.01}
,{"ItemTankTrap","magazine",0.04}
,{"ItemKeyKit","weapon",0.01}
{"ItemGenerator","magazine",0.01},
{"fuel_pump_kit","magazine",0.01},
{"","generic",0.18},
{"","trash",0.28},
{"","military",0.04},
{"PartGeneric","magazine",0.04},
{"PartWheel","magazine",0.05},
{"PartFueltank","magazine",0.02},
{"PartEngine","magazine",0.02},
{"PartGlass","magazine",0.04},
{"PartVRotor","magazine",0.01},
{"ItemJerrycan","magazine",0.04},
{"WeaponHolder_ItemHatchet_DZE","object",0.07},
{"ItemKnife","military",0.07},
{"ItemToolbox","weapon",0.06},
{"ItemWire","magazine",0.01},
{"ItemTankTrap","magazine",0.04},
{"ItemKeyKit","weapon",0.01}
};
lootTypeSmall[] = {
{ "","generic",0.5 },
{ "","trash",0.28 },
{ "","military",0.14 },
{ "ItemKnife","weapon",0.07 },
{ "ItemKeyKit","weapon",0.01 }
};
};
class Farm: Default {
@@ -180,16 +240,23 @@ class CfgBuildingLoot {
lootChance = 0.5;
lootPos[] = {};
lootType[] = {
{"ItemJerrycan","magazine",0.05}
,{"","generic",0.3}
,{"","trash",0.26}
,{"PartPlankPack","magazine",0.06}
,{"WeaponHolder_ItemHatchet_DZE","object",0.05}
,{"ItemFuelBarrelEmpty","magazine",0.01}
,{"WeaponHolder_ItemMachete","object",0.03}
,{"ItemFishingPole","weapon",0.02}
,{"ItemLightBulb","magazine",0.02}
,{"ItemSledgeHandle","magazine",0.02}
{"ItemJerrycan","magazine",0.05},
{"","generic",0.3},
{"","trash",0.26},
{"PartPlankPack","magazine",0.06},
{"WeaponHolder_ItemHatchet_DZE","object",0.05},
{"ItemFuelBarrelEmpty","magazine",0.01},
{"WeaponHolder_ItemMachete","object",0.03},
{"ItemFishingPole","weapon",0.02},
{"ItemLightBulb","magazine",0.02},
{"ItemSledgeHandle","magazine",0.02}
};
lootTypeSmall[] = {
{ "","generic", 0.79},
{ "","trash",0.14 },
{ "","military",0.05},
{ "ItemLightBulb","magazine",0.01},
{ "ItemSledgeHead","magazine",0.01}
};
};
class Supermarket: Default {
@@ -199,23 +266,40 @@ class CfgBuildingLoot {
zombieChance = 0.3;
zombieClass[] = {"zZombie_Base","zZombie_Base","z_teacher","z_suit1","z_suit2"};
lootType[] = {
{"ItemSodaMdew","magazine",0.01}
,{"ItemSodaRbull","magazine",0.01}
,{"ItemSodaOrangeSherbet","magazine",0.03}
,{"ItemWatch","generic",0.07}
,{"ItemCompass","generic",0.02}
,{"ItemMap","weapon",0.04}
,{"ItemFlashlight","generic",0.01}
,{"ItemKnife","generic",0.02}
,{"ItemMatchbox_DZE","generic",0.04}
,{"","generic",0.04}
,{"backpacks","backpacks",0.07}
,{"tents","tents",0.01}
,{"","food",0.3}
,{"","trash",0.23}
,{"Binocular","weapon",0.05}
,{"PartPlywoodPack","magazine",0.02}
,{"ItemMixOil","magazine",0.02}
{"ItemSodaMdew","magazine",0.01},
{"ItemSodaRbull","magazine",0.01},
{"ItemSodaOrangeSherbet","magazine",0.03},
{"ItemWatch","generic",0.07},
{"ItemCompass","generic",0.02},
{"ItemMap","weapon",0.04},
{"ItemFlashlight","generic",0.01},
{"ItemKnife","generic",0.02},
{"ItemMatchbox_DZE","generic",0.04},
{"","generic",0.04},
{"backpacks","backpacks",0.07},
{"tents","tents",0.01},
{"","food",0.3},
{"","trash",0.23},
{"Binocular","weapon",0.05},
{"PartPlywoodPack","magazine",0.02},
{"ItemMixOil","magazine",0.02}
};
lootTypeSmall[] = {
{ "ItemSodaMdew","magazine",0.01 },
{ "ItemSodaRbull","magazine",0.01 },
{ "ItemSodaOrangeSherbet","magazine",0.03 },
{ "ItemWatch","weapon",0.07 },
{ "ItemCompass","weapon",0.03 },
{ "ItemMap","weapon",0.05 },
{ "pistols","cfglootweapon",0.08 },
{ "ItemFlashlight","weapon",0.01 },
{ "ItemKnife","weapon",0.02 },
{ "ItemMatchbox_DZE","weapon",0.04 },
{ "","generic",0.21 },
{ "","food",0.24 },
{ "","trash",0.16 },
{ "Binocular","weapon",0.02 },
{ "ItemMixOil", "magazine",0.02}
};
};
class HeliCrash: Default {
@@ -225,15 +309,15 @@ class CfgBuildingLoot {
lootChance = 0.5;
lootPos[] = {};
lootType[] = {
{"","military",0.3}
,{"","medical",0.18}
,{"MAAWS","weapon",0.02}
,{"MedBox0","object",0.05}
,{"NVGoggles","weapon",0.01}
,{"AmmoBoxSmall_556","object",0.03}
,{"AmmoBoxSmall_762","object",0.03}
,{"militaryclothes","militaryclothes",0.05}
,{"militaryammo","militaryammo",0.06}
{"","military",0.3},
{"","medical",0.18},
{"MAAWS","weapon",0.02},
{"MedBox0","object",0.05},
{"NVGoggles","weapon",0.01},
{"AmmoBoxSmall_556","object",0.03},
{"AmmoBoxSmall_762","object",0.03},
{"militaryclothes","militaryclothes",0.05},
{"militaryammo","militaryammo",0.06}
};
};
class HeliCrash_No50s: Default {
@@ -243,15 +327,15 @@ class CfgBuildingLoot {
lootChance = 0.5;
lootPos[] = {};
lootType[] = {
{"","military",0.35}
,{"","medical",0.18}
,{"MAAWS","weapon",0.02}
,{"MedBox0","object",0.05}
,{"NVGoggles","weapon",0.01}
,{"AmmoBoxSmall_556","object",0.03}
,{"AmmoBoxSmall_762","object",0.03}
,{"militaryclothes","militaryclothes",0.05}
,{"militaryammo","militaryammo",0.06}
{"","military",0.35},
{"","medical",0.18},
{"MAAWS","weapon",0.02},
{"MedBox0","object",0.05},
{"NVGoggles","weapon",0.01},
{"AmmoBoxSmall_556","object",0.03},
{"AmmoBoxSmall_762","object",0.03},
{"militaryclothes","militaryclothes",0.05},
{"militaryammo","militaryammo",0.06}
};
};
class Hospital: Default {
@@ -262,9 +346,13 @@ class CfgBuildingLoot {
lootChance = 1;
lootPos[] = {};
lootType[] = {
{"","trash",0.1}
,{"","hospital",0.7}
,{"MedBox0","object",0.2}
{"","trash",0.1},
{"","hospital",0.7},
{"MedBox0","object",0.2}
};
lootTypeSmall[] = {
{ "","trash",0.1 },
{ "","hospital",0.9 }
};
};
class Military: Default {
@@ -274,17 +362,30 @@ class CfgBuildingLoot {
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"Binocular","weapon",0.03}
,{"ItemFlashlightRed","military",0.04}
,{"ItemKnife","military",0.01}
,{"ItemGPS","weapon",0.01}
,{"ItemMap","military",0.02}
,{"militarybackpacks","militarybackpacks",0.05}
,{"","medical",0.03}
,{"","generic",0.1}
,{"","military",0.3}
,{"ItemEtool","weapon",0.02}
,{"ItemSandbag","magazine",0.02}
{"Binocular","weapon",0.03},
{"ItemFlashlightRed","military",0.04},
{"ItemKnife","military",0.01},
{"ItemGPS","weapon",0.01},
{"ItemMap","military",0.02},
{"militarybackpacks","militarybackpacks",0.05},
{"","medical",0.03},
{"","generic",0.1},
{"","military",0.3},
{"ItemEtool","weapon",0.02},
{"ItemSandbag","magazine",0.02}
};
lootTypeSmall[] = {
{ "pistols","cfglootweapon",0.15 },
{ "Binocular","weapon",0.02 },
{ "ItemFlashlightRed","weapon",0.03 },
{ "ItemKnife","weapon",0.04 },
{ "ItemGPS","weapon",0.02 },
{ "ItemMap","weapon",0.02 },
{ "","medical",0.09 },
{ "","generic",0.34 },
{ "","military",0.26 },
{ "submachinegun","cfglootweapon",0.02 },
{ "ItemEtool","weapon",0.01 }
};
};
class MilitaryIndustrial: Default {
@@ -294,22 +395,34 @@ class CfgBuildingLoot {
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"PartGeneric","magazine",0.03}
,{"ItemGenerator","magazine",0.01}
,{"PartWheel","magazine",0.02}
,{"Binocular","weapon",0.01}
,{"ItemFlashlightRed","military",0.03}
,{"ItemKnife","military",0.04}
,{"ItemGPS","weapon",0.01}
,{"PartVRotor","magazine",0.01}
,{"militarybackpacks","militarybackpacks",0.03}
,{"","medical",0.05}
,{"","generic",0.35}
,{"","military",0.07}
,{"ItemEtool","weapon",0.03}
,{"ItemSandbag","magazine",0.02}
,{"ItemFuelBarrelEmpty","magazine",0.03}
,{"fuel_pump_kit","magazine",0.01}
{"PartGeneric","magazine",0.03},
{"ItemGenerator","magazine",0.01},
{"PartWheel","magazine",0.02},
{"Binocular","weapon",0.01},
{"ItemFlashlightRed","military",0.03},
{"ItemKnife","military",0.04},
{"ItemGPS","weapon",0.01},
{"PartVRotor","magazine",0.01},
{"militarybackpacks","militarybackpacks",0.03},
{"","medical",0.05},
{"","generic",0.35},
{"","military",0.07},
{"ItemEtool","weapon",0.03},
{"ItemSandbag","magazine",0.02},
{"ItemFuelBarrelEmpty","magazine",0.03},
{"fuel_pump_kit","magazine",0.01}
};
lootTypeSmall[] = {
{ "pistols","cfglootweapon",0.12 },
{ "Binocular","weapon",0.05 },
{ "ItemFlashlightRed","weapon",0.03 },
{ "ItemKnife","weapon",0.04 },
{ "ItemGPS","weapon",0.02 },
{ "","medical",0.02 },
{ "","generic",0.09 },
{ "","military",0.34 },
{ "submachinegun","cfglootweapon",0.26 },
{ "ItemEtool","weapon",0.03 }
};
};
class IndustrialMilitary: Default {
@@ -319,25 +432,37 @@ class CfgBuildingLoot {
lootChance = 0.5;
lootPos[] = {};
lootType[] = {
{"PartGeneric","magazine",0.03}
,{"ItemGenerator","magazine",0.01}
,{"PartWheel","magazine",0.02}
,{"Binocular","weapon",0.01}
,{"ItemFlashlightRed","military",0.03}
,{"ItemKnife","military",0.04}
,{"ItemGPS","weapon",0.01}
,{"PartVRotor","magazine",0.01}
,{"PartFueltank","magazine",0.03}
,{"PartEngine","magazine",0.04}
,{"PartGlass","magazine",0.05}
,{"militarybackpacks","militarybackpacks",0.03}
,{"","medical",0.05}
,{"","generic",0.25}
,{"","military",0.07}
,{"ItemEtool","weapon",0.03}
,{"ItemSandbag","magazine",0.02}
,{"ItemFuelBarrelEmpty","magazine",0.03}
,{"fuel_pump_kit","magazine",0.01}
{"PartGeneric","magazine",0.03},
{"ItemGenerator","magazine",0.01},
{"PartWheel","magazine",0.02},
{"Binocular","weapon",0.01},
{"ItemFlashlightRed","military",0.03},
{"ItemKnife","military",0.04},
{"ItemGPS","weapon",0.01},
{"PartVRotor","magazine",0.01},
{"PartFueltank","magazine",0.03},
{"PartEngine","magazine",0.04},
{"PartGlass","magazine",0.05},
{"militarybackpacks","militarybackpacks",0.03},
{"","medical",0.05},
{"","generic",0.25},
{"","military",0.07},
{"ItemEtool","weapon",0.03},
{"ItemSandbag","magazine",0.02},
{"ItemFuelBarrelEmpty","magazine",0.03},
{"fuel_pump_kit","magazine",0.01},
};
lootTypeSmall[] = {
{ "pistols", "cfglootweapon", 0.12 },
{ "Binocular", "weapon", 0.05 },
{ "ItemFlashlightRed", "weapon", 0.03 },
{ "ItemKnife", "weapon", 0.04 },
{ "ItemGPS", "weapon", 0.02 },
{ "", "medical", 0.02 },
{ "", "generic", 0.09 },
{ "", "military", 0.34 },
{ "submachinegun", "cfglootweapon", 0.26 },
{ "ItemEtool", "weapon", 0.03 }
};
};
class MilitarySpecial: Default {
@@ -348,22 +473,42 @@ class CfgBuildingLoot {
lootChance = 0.4;
lootPos[] = {};
lootType[] = {
{"AmmoBoxSmall_556","object",0.01}
,{"AmmoBoxSmall_762","object",0.02}
,{"Binocular","weapon",0.01}
,{"ItemFlashlightRed","military",0.02}
,{"ItemKnife","military",0.01}
,{"ItemGPS","weapon",0.01}
,{"ItemMap","military",0.01}
,{"Binocular_Vector","military",0.01}
,{"militarybackpacks","militarybackpacks",0.04}
,{"","medical",0.08}
,{"","generic",0.3}
,{"","military",0.01}
,{"machinegunammo","machinegunammo",0.05}
,{"militaryclothes","militaryclothes",0.05}
,{"NVGoggles","weapon",0.01}
,{"100Rnd_762x54_PK","magazine",0.05}
{"AmmoBoxSmall_556","object",0.01},
{"AmmoBoxSmall_762","object",0.02},
{"Binocular","weapon",0.01},
{"ItemFlashlightRed","military",0.02},
{"ItemKnife","military",0.01},
{"ItemGPS","weapon",0.01},
{"ItemMap","military",0.01},
{"Binocular_Vector","military",0.01},
{"militarybackpacks","militarybackpacks",0.04},
{"","medical",0.08},
{"","generic",0.3},
{"","military",0.01},
{"machinegunammo","machinegunammo",0.05},
{"militaryclothes","militaryclothes",0.05},
{"NVGoggles","weapon",0.01},
{"100Rnd_762x54_PK","magazine",0.05}
};
lootTypeSmall[] = {
{ "pistols","cfglootweapon",0.10 },
{ "AmmoBoxSmall_556","object",0.02 },
{ "AmmoBoxSmall_762","object",0.02 },
{ "Binocular","weapon",0.02 },
{ "ItemFlashlightRed","military",0.01 },
{ "ItemKnife","military",0.02 },
{ "ItemGPS","weapon",0.02 },
{ "ItemMap","weapon",0.01 },
{ "Binocular_Vector","weapon",0.03},
{ "","medical",0.08},
{ "","generic",0.15},
{ "","military",0.33 },
{ "5Rnd_86x70_L115A1","magazine",0.03},
{ "10Rnd_127x99_m107","magazine",0.02},
{ "machinegunammoexpl","single",0.02 },
{ "militaryclothes","single",0.05 },
{ "NVGoggles","weapon",0.04 },
{ "100Rnd_762x54_PK","magazine",0.02 }
};
};
class Hunting: Default {
@@ -374,13 +519,21 @@ class CfgBuildingLoot {
lootChance = 1;
lootPos[] = {};
lootType[] = {
{"ItemMap","weapon",0.02}
,{"ItemFlashlight","generic",0.01}
,{"ItemKnife","generic",0.01}
,{"ItemMatchbox_DZE","generic",0.03}
,{"","military",0.38}
,{"WeaponHolder_ItemMachete","object",0.02}
,{"","hunter",0.5}
{"ItemMap","weapon",0.02},
{"ItemFlashlight","generic",0.01},
{"ItemKnife","generic",0.01},
{"ItemMatchbox_DZE","generic",0.03},
{"","military",0.38},
{"WeaponHolder_ItemMachete","object",0.02},
{"","hunter",0.5}
};
lootTypeSmall[] = {
{"ItemMap","weapon",0.02},
{"ItemFlashlight","weapon",0.02},
{"ItemKnife","weapon",0.02},
{"ItemMatchbox_DZE","weapon",0.04},
{"","military",0.4},
{"","hunter",0.5}
};
};
class DynamicDebris: Default
@@ -391,23 +544,23 @@ class CfgBuildingLoot {
zombieChance = 0.3;
zombieClass[] = {"zZombie_Base","zZombie_Base","z_teacher","z_suit1","z_suit2"};
lootType[] = {
{"ItemWatch","generic",0.19}
,{"ItemCompass","generic",0.01}
,{"ItemMap","weapon",0.06}
,{"Makarov","weapon",0.02}
,{"Colt1911","weapon",0.02}
,{"ItemFlashlight","generic",0.06}
,{"ItemKnife","generic",0.06}
,{"ItemMatchbox_DZE","generic",0.06}
,{"ItemToolbox","weapon",0.02}
,{"","generic",0.17}
,{"","food",0.06}
,{"PartGeneric","magazine",0.07}
,{"PartWheel","magazine",0.06}
,{"PartFueltank","magazine",0.03}
,{"PartEngine","magazine",0.01}
,{"PartGlass","magazine",0.08}
,{"WeaponHolder_ItemJerrycan","object",0.03}
{ "ItemWatch", "generic", 0.19 },
{ "ItemCompass", "generic", 0.01 },
{ "ItemMap", "weapon", 0.06 },
{ "Makarov", "weapon", 0.02 },
{ "Colt1911", "weapon", 0.02 },
{ "ItemFlashlight", "generic", 0.06 },
{ "ItemKnife", "generic", 0.06 },
{ "ItemMatchbox_DZE", "generic", 0.06 },
{ "ItemToolbox", "weapon", 0.02 },
{ "", "generic", 0.17 },
{ "", "food", 0.06 },
{ "PartGeneric", "magazine", 0.07 },
{ "PartWheel", "magazine", 0.06 },
{ "PartFueltank", "magazine", 0.03 },
{ "PartEngine", "magazine", 0.01 },
{ "PartGlass", "magazine", 0.08 },
{ "WeaponHolder_ItemJerrycan", "object", 0.03 }
};
};
class DynamicDebrisMilitary: Default
@@ -418,27 +571,27 @@ class CfgBuildingLoot {
zombieChance = 0.3;
zombieClass[] = {"z_soldier_pilot","z_soldier_heavy"};
lootType[] = {
{"ItemEtool","weapon",0.05}
,{"ItemSandbag","magazine",0.1}
,{"","military",0.08}
,{"ItemWatch","generic",0.1}
,{"ItemCompass","generic",0.02}
,{"ItemMap","weapon",0.05}
,{"MakarovSD","weapon",0.01}
,{"Colt1911","weapon",0.02}
,{"ItemFlashlight","generic",0.01}
,{"ItemKnife","generic",0.05}
,{"ItemMatchbox_DZE","generic",0.05}
,{"ItemToolbox","weapon",0.02}
,{"","generic",0.15}
,{"","food",0.05}
,{"PartGeneric","magazine",0.06}
,{"PartWheel","magazine",0.05}
,{"PartFueltank","magazine",0.03}
,{"PartEngine","magazine",0.02}
,{"PartGlass","magazine",0.03}
,{"PartVRotor","magazine",0.02}
,{"WeaponHolder_ItemJerrycan","object",0.03}
{ "ItemEtool", "weapon", 0.05 },
{ "ItemSandbag", "magazine", 0.1 },
{ "", "military", 0.08 },
{ "ItemWatch", "generic", 0.1 },
{ "ItemCompass", "generic", 0.02 },
{ "ItemMap", "weapon", 0.05 },
{ "MakarovSD", "weapon", 0.01 },
{ "Colt1911", "weapon", 0.02 },
{ "ItemFlashlight", "generic", 0.01 },
{ "ItemKnife", "generic", 0.05 },
{ "ItemMatchbox_DZE", "generic", 0.05 },
{ "ItemToolbox", "weapon", 0.02 },
{ "", "generic", 0.15 },
{ "", "food", 0.05 },
{ "PartGeneric", "magazine", 0.06 },
{ "PartWheel", "magazine", 0.05 },
{ "PartFueltank", "magazine", 0.03 },
{ "PartEngine", "magazine", 0.02 },
{ "PartGlass", "magazine", 0.03 },
{ "PartVRotor", "magazine", 0.02 },
{ "WeaponHolder_ItemJerrycan", "object", 0.03 }
};
};
class SupplyDrop: Default {
@@ -448,14 +601,14 @@ class CfgBuildingLoot {
lootChance = 1;
lootPos[] = {};
lootType[] = {
{"PartPlywoodPack","magazine",0.1}
,{"PartPlankPack","magazine",0.2}
,{"CinderBlocks","magazine",0.1}
,{"MortarBucket","magazine",0.1}
,{"bulk_PartGeneric","magazine",0.2}
,{"bulk_ItemSandbag","magazine",0.1}
,{"bulk_ItemTankTrap","magazine",0.1}
,{"ItemSledge","weapon",0.1}
{ "PartPlywoodPack", "magazine", 0.1 },
{ "PartPlankPack", "magazine", 0.2 },
{ "CinderBlocks", "magazine", 0.1 },
{ "MortarBucket", "magazine", 0.1 },
{ "bulk_PartGeneric", "magazine", 0.2 },
{ "bulk_ItemSandbag", "magazine", 0.1 },
{ "bulk_ItemTankTrap", "magazine", 0.1 },
{ "ItemSledge", "weapon", 0.1 }
};
};
class MassGrave: Default {
@@ -465,62 +618,62 @@ class CfgBuildingLoot {
lootChance = 1;
lootPos[] = {};
lootType[] = {
{"M16A2","weapon",0.03}
,{"M16A2GL","weapon",0.01}
,{"M249_EP1_DZ","weapon",0.01}
,{"M9SD","weapon",0.02}
,{"Pecheneg_DZ","weapon",0.02}
,{"PK_DZ","weapon",0.01}
,{"AK_74","weapon",0.02}
,{"M4A1_Aim","weapon",0.01}
,{"AKS_74_kobra","weapon",0.01}
,{"AKS_74_U","weapon",0.02}
,{"AK_47_M","weapon",0.02}
,{"M24","weapon",0.01}
,{"SVD_CAMO","weapon",0.01}
,{"M1014","weapon",0.02}
,{"BAF_LRR_scoped","weapon",0.01}
,{"M4SPR","weapon",0.01}
,{"M4A1","weapon",0.01}
,{"M14_EP1","weapon",0.02}
,{"UZI_EP1","weapon",0.03}
,{"Remington870_lamp","weapon",0.01}
,{"glock17_EP1","weapon",0.02}
,{"M240_DZ","weapon",0.02}
,{"M4A1_AIM_SD_camo","weapon",0.01}
,{"M16A4_ACG","weapon",0.01}
,{"M4A1_HWS_GL_camo","weapon",0.01}
,{"Mk_48_DZ","weapon",0.01}
,{"M4A3_CCO_EP1","weapon",0.01}
,{"AmmoBoxSmall_556","object",0.03}
,{"AmmoBoxSmall_762","object",0.03}
,{"Binocular","weapon",0.01}
,{"ItemFlashlightRed","military",0.02}
,{"ItemKnife","military",0.01}
,{"ItemGPS","weapon",0.01}
,{"ItemMap","military",0.01}
,{"Binocular_Vector","military",0.01}
,{"DZ_ALICE_Pack_EP1","object",0.03}
,{"DZ_TK_Assault_Pack_EP1","object",0.02}
,{"DZ_British_ACU","object",0.02}
,{"DZ_CivilBackpack_EP1","object",0.02}
,{"DZ_Backpack_EP1","object",0.01}
,{"DZ_LargeGunBag_EP1","object",0.01}
,{"","medical",0.05}
,{"","generic",0.05}
,{"","military",0.13}
,{"PipeBomb","magazine",0.01}
,{"Sa58V_RCO_EP1","weapon",0.01}
,{"Sa58V_CCO_EP1","weapon",0.01}
,{"G36_C_SD_camo","weapon",0.01}
,{"M40A3","weapon",0.01}
,{"100Rnd_762x54_PK","magazine",0.01}
,{"","militaryclothes",0.05}
,{"WeaponHolder_ItemMachete","object",0.02}
,{"SCAR_H_LNG_Sniper_SD","weapon",0.01}
,{"2000Rnd_762x51_M134","magazine",0.01}
,{"KSVK_DZE","weapon",0.01}
,{"m240_scoped_EP1_DZE","weapon",0.01}
{ "M16A2", "weapon", 0.03 },
{ "M16A2GL", "weapon", 0.01 },
{ "M249_EP1_DZ", "weapon", 0.01 },
{ "M9SD", "weapon", 0.02 },
{ "Pecheneg_DZ", "weapon", 0.02 },
{ "PK_DZ", "weapon", 0.01 },
{ "AK_74", "weapon", 0.02 },
{ "M4A1_Aim", "weapon", 0.01 },
{ "AKS_74_kobra", "weapon", 0.01 },
{ "AKS_74_U", "weapon", 0.02 },
{ "AK_47_M", "weapon", 0.02 },
{ "M24", "weapon", 0.01 },
{ "SVD_CAMO", "weapon", 0.01 },
{ "M1014", "weapon", 0.02 },
{ "BAF_LRR_scoped", "weapon", 0.01 },
{ "M4SPR", "weapon", 0.01 },
{ "M4A1", "weapon", 0.01 },
{ "M14_EP1", "weapon", 0.02 },
{ "UZI_EP1", "weapon", 0.03 },
{ "Remington870_lamp", "weapon", 0.01 },
{ "glock17_EP1", "weapon", 0.02 },
{ "M240_DZ", "weapon", 0.02 },
{ "M4A1_AIM_SD_camo", "weapon", 0.01 },
{ "M16A4_ACG", "weapon", 0.01 },
{ "M4A1_HWS_GL_camo", "weapon", 0.01 },
{ "Mk_48_DZ", "weapon", 0.01 },
{ "M4A3_CCO_EP1", "weapon", 0.01 },
{ "AmmoBoxSmall_556", "object", 0.03 },
{ "AmmoBoxSmall_762", "object", 0.03 },
{ "Binocular", "weapon", 0.01 },
{ "ItemFlashlightRed", "military", 0.02 },
{ "ItemKnife", "military", 0.01 },
{ "ItemGPS", "weapon", 0.01 },
{ "ItemMap", "military", 0.01 },
{ "Binocular_Vector", "military", 0.01 },
{ "DZ_ALICE_Pack_EP1", "object", 0.03 },
{ "DZ_TK_Assault_Pack_EP1", "object", 0.02 },
{ "DZ_British_ACU", "object", 0.02 },
{ "DZ_CivilBackpack_EP1", "object", 0.02 },
{ "DZ_Backpack_EP1", "object", 0.01 },
{ "DZ_LargeGunBag_EP1", "object", 0.01 },
{ "", "medical", 0.05 },
{ "", "generic", 0.05 },
{ "", "military", 0.13 },
{ "PipeBomb", "magazine", 0.01 },
{ "Sa58V_RCO_EP1", "weapon", 0.01 },
{ "Sa58V_CCO_EP1", "weapon", 0.01 },
{ "G36_C_SD_camo", "weapon", 0.01 },
{ "M40A3", "weapon", 0.01 },
{ "100Rnd_762x54_PK", "magazine", 0.01 },
{ "", "militaryclothes", 0.05 },
{ "WeaponHolder_ItemMachete", "object", 0.02 },
{ "SCAR_H_LNG_Sniper_SD", "weapon", 0.01 },
{ "2000Rnd_762x51_M134", "magazine", 0.01 },
{ "KSVK_DZE", "weapon", 0.01 },
{ "m240_scoped_EP1_DZE", "weapon", 0.01 }
};
};

View File

@@ -79,7 +79,7 @@ _bias = (_bias + random(100 - _bias)) / 100;
// small loot
_posSmall = [] + getArray (_config >> "lootPosSmall");
_itemTypesSmall = [] + getArray (_config >> "itemTypeSmall");
_itemTypesSmall = [] + getArray (_config >> "lootTypeSmall");
_positionsSmall = _posSmall call _ShuffleArray;
@@ -101,8 +101,11 @@ _positionsSmall = _posSmall call _ShuffleArray;
_cntWeights = count _weights;
_index = floor(random _cntWeights);
_index = _weights select _index;
diag_log format["building_spawnLoot.sqf: %1", _itemTypesSmall];
_itemType = _itemTypesSmall select _index;
[_itemType select 0, _itemType select 1 , _iPos, 0.0] call spawn_loot;
[_itemType select 0, _itemType select 1, _iPos, 0.0] call spawn_loot_small;
// diag_log (format["SpawnLoot: Pos: %1, LootType: %2/%3,",_iPos,_itemType select 0,_itemType select 1]);
dayz_currentWeaponHolders = dayz_currentWeaponHolders +1;
//loclout system

View File

@@ -5,6 +5,8 @@ _iPos = _this select 2;
_radius = _this select 3;
_uniq = [];
_item = objNull;
_iPosZ = _iPos select 2;
if((isNil "_iPosZ") OR {( _iPosZ < 0)}) then { _iPos = [_iPos select 0,_iPos select 1,0]; };
if (isNil "_iClass") exitWith {diag_log "_iClass isNil, exiting loot spawn!";};
@@ -13,9 +15,13 @@ switch (_iClass) do {
default {
_itemTypes = [];
if (DZE_MissionLootTable) then {
_itemTypes = ((getArray (missionConfigFile >> "cfgLoot" >> _iClass)) select 0);
{
_itemTypes set [count _itemTypes, _x select 0]
} foreach getArray (missionConfigFile >> "cfgLoot" >> _iClass);
} else {
_itemTypes = ((getArray (configFile >> "cfgLoot" >> _iClass)) select 0);
{
_itemTypes set [count _itemTypes, _x select 0]
} foreach getArray (configFile >> "cfgLoot" >> _iClass);
};
_qty = 0;
_max = ceil(random 2) + 1;
@@ -25,8 +31,14 @@ switch (_iClass) do {
_index = dayz_CLBase find _iClass;
_weights = dayz_CLChances select _index;
_cntWeights = count _weights;
// diag_log ("dayz_CLChances: "+str(dayz_CLChances));
_index = floor(random _cntWeights);
_index = _weights select _index;
//diag_log ("dayz_CLChances: "+str(_itemTypes));
_canType = _itemTypes select _index;
_tQty = round(random 1) + 1;
if (_canType in _uniq) then {
@@ -44,34 +56,39 @@ switch (_iClass) do {
if ((_iItem != "") && (isClass(configFile >> "CfgWeapons" >> _iItem))) then {
_item addWeaponCargoGlobal [_iItem,1];
};
} else {
}
else {
diag_log format["DEBUG dayz_CLBase: %1", dayz_CLBase];
_index = dayz_CLBase find _iClass;
_weights = dayz_CLChances select _index;
_cntWeights = count _weights;
_index = floor(random _cntWeights);
_index = _weights select _index;
_item2 = _itemTypes select _index;
if ((_item2 != "") && (isClass(configFile >> "CfgWeapons" >> _item2))) then {
_item = createVehicle ["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_item addWeaponCargoGlobal [_item2,1];
if ((count _mags) > 0) then {
if (_mags select 0 == "20Rnd_556x45_Stanag") then { _mags set [0, "30Rnd_556x45_Stanag"] };
if (_mags select 0 == "30Rnd_556x45_G36") then { _mags set [0, "30Rnd_556x45_Stanag"] };
if (_mags select 0 == "30Rnd_556x45_G36SD") then { _mags set [0, "30Rnd_556x45_StanagSD"] };
if (!(_item2 in MeleeWeapons)) then {
_magQty = round(random 10);
if (_magQty > 3) then {
_item addMagazineCargoGlobal [(_mags select 0), (round(random 1) + 1)];
if (_index > 0) then {
_weights = dayz_CLChances select _index;
diag_log format["DEBUG dayz_CLChances: %1", dayz_CLChances];
_cntWeights = count _weights;
_index = floor(random _cntWeights);
_index = _weights select _index;
_item2 = _itemTypes select _index;
if ((_item2 != "") && (isClass(configFile >> "CfgWeapons" >> _item2))) then{
_item = createVehicle["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_item addWeaponCargoGlobal[_item2, 1];
if ((count _mags) > 0) then{
if (_mags select 0 == "20Rnd_556x45_Stanag") then{ _mags set[0, "30Rnd_556x45_Stanag"] };
if (_mags select 0 == "30Rnd_556x45_G36") then{ _mags set[0, "30Rnd_556x45_Stanag"] };
if (_mags select 0 == "30Rnd_556x45_G36SD") then{ _mags set[0, "30Rnd_556x45_StanagSD"] };
if (!(_item2 in MeleeWeapons)) then{
_magQty = round(random 10);
if (_magQty > 3) then{
_item addMagazineCargoGlobal[(_mags select 0), (round(random 1) + 1)];
};
};
};
};
};
if ((_item2 != "") && (isClass(configFile >> "CfgMagazines" >> _item2))) then {
_item = createVehicle ["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_item addMagazineCargoGlobal [_item2,1];
};
if ((_item2 != "") && (isClass(configFile >> "CfgVehicles" >> _item2))) then {
_item = createVehicle [_item2, _iPos, [], _radius, "CAN_COLLIDE"];
if ((_item2 != "") && (isClass(configFile >> "CfgMagazines" >> _item2))) then{
_item = createVehicle["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_item addMagazineCargoGlobal[_item2, 1];
};
if ((_item2 != "") && (isClass(configFile >> "CfgVehicles" >> _item2))) then{
_item = createVehicle[_item2, _iPos, [], _radius, "CAN_COLLIDE"];
};
};
};
@@ -81,10 +98,15 @@ switch (_iClass) do {
//Item is sigle, add 1 item from cfgloot
_item = createVehicle ["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_itemTypes = [];
if (DZE_MissionLootTable) then {
_itemTypes = ((getArray (missionConfigFile >> "cfgLoot" >> _iItem)) select 0);
} else {
_itemTypes = ((getArray (configFile >> "cfgLoot" >> _iItem)) select 0);
if (DZE_MissionLootTable) then{
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(missionConfigFile >> "cfgLoot" >> _iClass);
}
else {
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(configFile >> "cfgLoot" >> _iClass);
};
_index = dayz_CLBase find _iItem;
_weights = dayz_CLChances select _index;
@@ -114,10 +136,15 @@ switch (_iClass) do {
};
case "cfglootweapon":
{
if (DZE_MissionLootTable) then {
_itemTypes = ((getArray (missionConfigFile >> "cfgLoot" >> _iItem)) select 0);
} else {
_itemTypes = ((getArray (configFile >> "cfgLoot" >> _iItem)) select 0);
if (DZE_MissionLootTable) then{
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(missionConfigFile >> "cfgLoot" >> _iClass);
}
else {
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(configFile >> "cfgLoot" >> _iClass);
};
_index = dayz_CLBase find _iItem;
_weights = dayz_CLChances select _index;
@@ -179,10 +206,15 @@ switch (_iClass) do {
};
case "object": {
_item = createVehicle [_iItem, _iPos, [], _radius, "CAN_COLLIDE"];
if ((count _iPos) > 2) then {
_item setPosATL _iPos;
};
};
};
if ((count _iPos) > 2) then {
_item setPosATL _iPos;
if (!isNull(_item)) then{
if ((count _iPos) > 2) then{
_item setPosATL _iPos;
};
};
_item

View File

@@ -7,6 +7,8 @@ _iClass = _this select 1;
_iPos = _this select 2;
_radius = _this select 3;
_item = objNull;
switch (_iClass) do
{
default
@@ -14,10 +16,15 @@ switch (_iClass) do
//Item is sigle, add 1 item from CfgLootSmall
_item = createVehicle ["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_itemTypes = [];
if (DZE_MissionLootTable) then {
_itemTypes = ((getArray (missionConfigFile >> "CfgLootSmall" >> _iClass)) select 0);
} else {
_itemTypes = ((getArray (configFile >> "CfgLootSmall" >> _iClass)) select 0);
if (DZE_MissionLootTable) then{
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(missionConfigFile >> "CfgLootSmall" >> _iClass);
}
else {
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(configFile >> "CfgLootSmall" >> _iClass);
};
_index = dayzE_CLSBase find _iClass;
@@ -35,10 +42,15 @@ switch (_iClass) do
_item = createVehicle ["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_itemTypes = [];
if (DZE_MissionLootTable) then {
_itemTypes = ((getArray (missionConfigFile >> "CfgLootSmall" >> _iItem)) select 0);
} else {
_itemTypes = ((getArray (configFile >> "CfgLootSmall" >> _iItem)) select 0);
if (DZE_MissionLootTable) then{
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(missionConfigFile >> "CfgLootSmall" >> _iClass);
}
else {
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(configFile >> "CfgLootSmall" >> _iClass);
};
_index = dayzE_CLSBase find _iItem;
_weights = dayzE_CLSChances select _index;
@@ -55,15 +67,22 @@ switch (_iClass) do
_item = createVehicle ["WeaponHolder", _iPos, [], _radius, "CAN_COLLIDE"];
_itemTypes = [];
if (DZE_MissionLootTable) then {
_itemTypes = ((getArray (missionConfigFile >> "CfgLootSmall" >> _iItem)) select 0);
} else {
_itemTypes = ((getArray (configFile >> "CfgLootSmall" >> _iItem)) select 0);
if (DZE_MissionLootTable) then{
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(missionConfigFile >> "CfgLootSmall" >> _iClass);
}
else {
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(configFile >> "CfgLootSmall" >> _iClass);
};
_index = dayz_CLBase find _iItem;
_weights = dayz_CLChances select _index;
_index = dayzE_CLSBase find _iItem;
_weights = dayzE_CLSChances select _index;
_cntWeights = count _weights;
diag_log("_itemTypes small:" + str(_itemTypes));
_index = floor(random _cntWeights);
_index = _weights select _index;
_iItem = _itemTypes select _index;
@@ -97,8 +116,10 @@ switch (_iClass) do
//do nothing for now
};
};
if ((count _iPos) > 2) then {
_item setPosATL _iPos;
if (!isNull(_item)) then{
if ((count _iPos) > 2) then{
_item setPosATL _iPos;
};
};
_item

View File

@@ -525,6 +525,7 @@ if (!isDedicated) then {
world_isDay = {if ((daytime < (24 - dayz_sunRise)) and (daytime > dayz_sunRise)) then {true} else {false}};
player_humanityChange = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_humanityChange.sqf";
spawn_loot = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\spawn_loot.sqf";
spawn_loot_small = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\spawn_loot_small.sqf";
// player_projectileNear = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_projectileNear.sqf";
local_setFuel = {

View File

@@ -23,7 +23,7 @@ for "_i" from 0 to ((count _config) - 1) do {
_weighted = [];
_j = 0;
for "_l" from 0 to (_itemCount - 1) do {
_weight = round (((_itemChances select _l) select 2) * 100);
_weight = round (((_itemChances select _l) select 2) * 100);
for "_k" from 0 to (_weight - 1) do
{
_weighted set [_j + _k, _l];
@@ -38,18 +38,21 @@ for "_i" from 0 to ((count _config) - 1) do {
dayz_CBLBase set [count dayz_CBLBase, _classname];
};
_itemChancesSmall = [] + getArray (_config >> _classname >> "ItemChanceSmall");
_itemChancesSmall = [] + getArray (_config >> _classname >> "lootTypeSmall");
_itemCountSmall = count _itemChancesSmall;
diag_log format["loot_init.sqf %1", _itemChancesSmall];
if (_itemCountSmall > 0) then {
if (dayzE_CBLSBase find _classname < 0) then {
_weighted = [];
_j = 0;
for "_l" from 0 to ((count _itemChancesSmall) - 1) do
{
_weight = round (((_itemChancesSmall select _l) select 2) * 100);
for "_k" from 0 to _weight - 1 do
for "_l" from 0 to(_itemCountSmall - 1) do {
_weight = round(((_itemChancesSmall select _l) select 2) * 100);
for "_k" from 0 to(_weight - 1) do
{
_weighted set [_j + _k, _l];
_weighted set[_j + _k, _l];
};
_j = _j + _weight;
};

View File

@@ -47,8 +47,8 @@ item42[] = {"New_Character",4,218,-325.000000,400.000000,-225.000000,450.000000,
item43[] = {"Gender_Selection",2,250,-575.000000,400.000000,-475.000000,450.000000,0.000000,"Gender Selection" \n "Dialog"};
item44[] = {"Selected",4,218,-575.000000,475.000000,-475.000000,525.000000,0.000000,"Selected"};
item45[] = {"Process",2,250,-575.000000,550.000000,-475.000000,600.000000,0.000000,"Process"};
item46[] = {"version_check",4,218,50.000000,-100.000000,150.000000,-50.000000,2.000000,"version check"};
item47[] = {"ERROR__version_c",2,4346,175.000000,-100.000000,275.000000,-50.000000,0.000000,"ERROR:" \n "version check"};
item46[] = {"version_check",4,4314,50.000000,-100.000000,150.000000,-50.000000,2.000000,"version check"};
item47[] = {"ERROR__version_c",2,250,175.000000,-100.000000,275.000000,-50.000000,0.000000,"ERROR:" \n "version check"};
item48[] = {"Too_Long",4,218,300.000000,-100.000000,400.000000,-50.000000,0.000000,"Too" \n "Long"};
item49[] = {"Stream",2,250,-75.000000,900.000000,25.000000,950.000000,0.000000,"Stream"};
item50[] = {"Preloaded",4,218,-175.000000,950.000000,-75.000000,1000.000000,0.000000,"Preloaded"};
@@ -170,7 +170,7 @@ link86[] = {76,78};
link87[] = {77,76};
link88[] = {78,57};
globals[] = {25.000000,1,0,0,0,640,480,1,143,6316128,1,-383.230377,382.212097,289.120941,-347.361115,736,612,1};
window[] = {0,-1,-1,-1,-1,810,1732,3010,52,1,754};
window[] = {0,-1,-1,-1,-1,888,130,1408,130,1,754};
*//*%FSM</HEAD>*/
class FSM
{
@@ -1373,7 +1373,7 @@ class FSM
priority = 2.000000;
to="ERROR__version_c";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"(_myEpochAnim != ""1.0.5"") || (_myEpoch != ""1.0.5"") || (_myEpochB != ""1.0.5"") || (_myEpochSfx != ""1.0.5"") || (_myEpochDayZ != ""1.0.5"")"/*%FSM</CONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"(_myEpochAnim != ""1.0.5"") || (_myEpoch != ""1.0.4.2"") || (_myEpochB != ""1.0.5"") || (_myEpochSfx != ""1.0.5"") || (_myEpochDayZ != ""1.0.5"")"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/

View File

@@ -347,10 +347,15 @@ spawn_vehicles = {
_iClass = _allCfgLoots call BIS_fnc_selectRandom;
_itemTypes = [];
if (DZE_MissionLootTable) then {
_itemTypes = ((getArray (missionConfigFile >> "cfgLoot" >> _iClass)) select 0);
} else {
_itemTypes = ((getArray (configFile >> "cfgLoot" >> _iClass)) select 0);
if (DZE_MissionLootTable) then{
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(missionConfigFile >> "cfgLoot" >> _iClass);
}
else {
{
_itemTypes set[count _itemTypes, _x select 0]
} foreach getArray(configFile >> "cfgLoot" >> _iClass);
};
_index = dayz_CLBase find _iClass;