Creating a Loot Table
- Content Browser → Right-click → Miscellaneous → Data Asset
-
Choose
LootTableas the class -
Name it, for example:
LT_CommonChestLT_ZombieDropsLT_TreeLootLT_RockLoot
Loot Table Structure
ALootTable asset typically contains:
-
Loot Entries (array)
- Each entry represents a possible drop (item, weight, quantity, rarity override)
-
Max Items To Spawn
- Limits how many different entries are chosen per roll
-
Use Priority For Overflow
- Controls how extra items are handled when there’s no space
-
Global Rarity Weights
- Optional global tuning for rarity distribution
-
Stat Scaling Rules
- Optional rules for scaling stats based on level / difficulty
Loot Entries (FLootEntry)
Each entry in the table defines a potential drop:
ItemData
The item definition (UItemDataAsset) to spawn.DropWeight
Relative weight used when randomly choosing entries. Higher = more likely.MinQuantity/MaxQuantity
If set, a random integer in this range will be used for the stack size.Quantity
Fixed quantity if you don’t want a range. (Typically you use eitherQuantityorMin/Max, not both.)RarityOverride
Optional gameplay tag to override the item’s default rarity (e.g., force an uncommon roll of a common item).
Example: Common Chest Loot Table
Loot Table:LT_CommonChest
Loot Entries:
-
[0] Health Potions
- Item Data:
DA_HealthPotion - Drop Weight:
50.0 - Min Quantity:
1 - Max Quantity:
3 - Rarity Override: None
- Item Data:
-
[1] Wood Logs
- Item Data:
DA_WoodLog - Drop Weight:
30.0 - Min Quantity:
5 - Max Quantity:
15 - Rarity Override: None
- Item Data:
-
[2] Iron Ore
- Item Data:
DA_IronOre - Drop Weight:
20.0 - Min Quantity:
1 - Max Quantity:
5 - Rarity Override: None
- Item Data:
-
[3] Iron Sword
- Item Data:
DA_IronSword - Drop Weight:
10.0 - Quantity:
1 - Rarity Override:
Item.Rarity.Uncommon
- Item Data:
-
[4] Gold Coins
- Item Data:
DA_GoldCoin - Drop Weight:
40.0 - Min Quantity:
10 - Max Quantity:
50 - Rarity Override: None
- Item Data:
3→ Even though there are 5 possible entries, at most 3 distinct entries will be chosen for each loot roll.
Drop Weight Explained
Drop weights behave as relative odds, not absolute percentages. In the example above:- Total weight =
50 + 30 + 20 + 10 + 40 = 150
Health Potion: 50 / 150 ≈ 33.3%Wood Log: 30 / 150 ≈ 20.0%Iron Ore: 20 / 150 ≈ 13.3%Iron Sword: 10 / 150 ≈ 6.7%Gold Coin: 40 / 150 ≈ 26.7%
Rule of thumb:
- Double the weight → roughly double the chance
- Weight = 0 → item is effectively disabled