Define random item groups that spawn together in your DayZ server. Create themed loot bundles with configurable spawn probabilities for more realistic item distribution.
The cfgRandomPresets.xml file defines groups of items that can spawn together. It enables themed item groups like medical supplies or hunting gear, controls individual item probabilities within each group, and creates more realistic loot distribution by spawning contextually related items together.
Each <cargo> element defines a preset group with a name and chance, containing multiple <item> elements.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<randompresets>
<cargo chance="1.0" name="MedicalSupplies">
<item name="BandageDressing" chance="0.8" />
<item name="DisinfectantAlcohol" chance="0.5" />
<item name="PainkillerTablets" chance="0.5" />
<item name="Morphine" chance="0.2" />
<item name="Epinephrine" chance="0.1" />
</cargo>
<cargo chance="1.0" name="HuntingGear">
<item name="HuntingKnife" chance="0.7" />
<item name="Box_762x54_20Rnd" chance="0.5" />
<item name="HuntingOptic" chance="0.3" />
</cargo>
</randompresets>
The unique identifier for this preset group. Use descriptive names that indicate the theme or purpose of the item collection, like "MedicalSupplies" or "MilitaryGear".
The probability (0.0 to 1.0) of this preset group being selected when applicable. A value of 1.0 means the group is always considered when its context matches.
The classname of the item. This must exactly match a classname defined in types.xml. Case-sensitive and must be spelled correctly for the item to spawn.
The probability (0.0 to 1.0) of this specific item spawning when its parent cargo group is selected. Each item rolls independently, so multiple items from the same group can spawn together.
When the server decides to spawn items at a location, it can use these presets to determine which items should appear together. The system creates more realistic and contextual loot distribution.
When spawning items in a medical location, the server might select the "MedicalSupplies" preset based on location tags and context.
Each item in the preset rolls its chance independently. A 0.8 chance item and a 0.5 chance item can both spawn, or neither, or just one.
Finding bandages alongside painkillers in a hospital feels natural. Presets enable this thematic consistency across your server.
Common items get higher chances (0.7-0.9), rare items get lower chances (0.1-0.3). This maintains item rarity within themed groups.
Bandages, disinfectant, painkillers, antibiotics
Knives, rifle ammo, optics, camouflage
Tents, sleeping bags, cooking pots, matches
Fishing rods, hooks, bait, tackle boxes
Various ammunition types, magazines, grenades
Hammers, pliers, screwdrivers, duct tape
Balanced medical loot for hospitals and clinics
<cargo chance="1.0" name="MedicalSupplies">
<item name="BandageDressing" chance="0.85" />
<item name="Rag" chance="0.80" />
<item name="DisinfectantAlcohol" chance="0.50" />
<item name="DisinfectantSpray" chance="0.45" />
<item name="PainkillerTablets" chance="0.55" />
<item name="VitaminBottle" chance="0.40" />
<item name="CharcoalTablets" chance="0.35" />
<item name="TetracyclineAntibiotics" chance="0.25" />
<item name="Morphine" chance="0.15" />
<item name="Epinephrine" chance="0.10" />
<item name="Defibrillator" chance="0.05" />
</cargo>
Structure your chance values in tiers: common items (0.7-0.9), uncommon (0.4-0.6), rare (0.2-0.3), and very rare (0.05-0.15). This creates natural loot progression where players find basic items easily but must search harder for valuable gear. Consider creating multiple presets for the same theme with different rarity distributions for different location types.