Weights determine *relative* drop chance, relative to other items in the same list.
If you have a list like this:
Leather Boots (weight 3)
Large Medkit (weight 2)
Kevlar Vest (weight 1)
Then Kevlar Vest will drop 16.6% of the time (not very rare), even though it is only 'weight 1'. If this list is 'min 1 max 2', that chance goes up to 25% (1 in 4 drops will contain Kevlar Vest). So you see that 'weight 1' can still drop a lot.
But if you change it like this:
Leather Boots (weight 50)
Large Medkit (weight 10)
Kevlar Vest (weight 1)
Then, the Kevlar Vest will only drop about 1.6% of the time (or come up in 2.4% of the drops for a min1/max2 list). So it is the same 'weight', but because the total weight for that list is larger, the chance for that item/sublist to drop is smaller. You can work out the chance of drop by this calculation:
((Wi÷Wt) × ((min+max)÷2)) × 100 = % chance that an item will appear in that drop
Where "Wi" is the weight of the item, "Wt" is the total weight of all items in that list/sublist, and min and max are the min/max values for the total list.
So, with your example:
The chance of, for example, AmmoSpawnList being chosen in this droplist, is:Code:"ZombieLootList": { "min": 1, "max": 2, "oneofeach": false, "nodupes": false, "packages": { "0": { "min": 1, "max": 1, "weight": 25, "object": "FoodList" }, "1": { "min": 1, "max": 1, "weight": 20, "object": "RessourceSpawnList" }, "2": { "min": 1, "max": 1, "weight": 15, "object": "AmmoSpawnList" }, "3": { "min": 1, "max": 1, "weight": 10, "object": "RadSuitList" }, "4": { "min": 1, "max": 1, "weight": 8, "object": "WeaponSpawnList" }, "5": { "min": 1, "max": 1, "weight": 4, "object": "LeatherList" }, "6": { "min": 1, "max": 1, "weight": 3, "object": "ArmorWeaponResearchChance" }, "7": { "min": 1, "max": 1, "weight": 2, "object": "MilitaryWeaponList2" }, "8": { "min": 1, "max": 1, "weight": 2, "object": "KevlarList2" }, "9": { "min": 1, "max": 1, "weight": 1, "object": "ResearchKitListDropZombie" } } }
((15 ÷ 90) × ((1+2)÷2)) × 100
= 0.1666 × (3÷2) × 100
= 0.1666 × 1.5 × 100
= 25 (25% chance that a drop from Zombie will contain ammo from this list)
And the chance for KevlarList2 is:
((2 ÷ 90) × ((1+2)÷2)) × 100
= 0.0222 × (3÷2) × 100
= 0.0222 × 1.5 × 100
= 3.33 (3.33% chance, or 1 in 30, that a drop from Zombie will contain KevlarList2 items)
And that's still pretty common - it's not hard to kill 30 zombies in 15-20 mins even with just a bow. But, if you make some of the other items more common (just quadrupling the weights)...
Now it changes the sums a bit:Code:"ZombieLootList": { "min": 1, "max": 2, "oneofeach": false, "nodupes": false, "packages": { "0": { "min": 1, "max": 1, "weight": 100, "object": "FoodList" }, "1": { "min": 1, "max": 1, "weight": 80, "object": "RessourceSpawnList" }, "2": { "min": 1, "max": 1, "weight": 60, "object": "AmmoSpawnList" }, "3": { "min": 1, "max": 1, "weight": 40, "object": "RadSuitList" }, "4": { "min": 1, "max": 1, "weight": 32, "object": "WeaponSpawnList" }, "5": { "min": 1, "max": 1, "weight": 16, "object": "LeatherList" }, "6": { "min": 1, "max": 1, "weight": 3, "object": "ArmorWeaponResearchChance" }, "7": { "min": 1, "max": 1, "weight": 2, "object": "MilitaryWeaponList2" }, "8": { "min": 1, "max": 1, "weight": 2, "object": "KevlarList2" }, "9": { "min": 1, "max": 1, "weight": 1, "object": "ResearchKitListDropZombie" } } }
((2 ÷ 336) × ((1+2)÷2)) × 100
= 0.0059 × (3÷2) × 100
= 0.0059 × 1.5 × 100
= 0.89 (0.89% chance, or about 1 in 112, that a drop from Zombie will contain KevlarList2 items)
It's a lot harder to kill 112 zombies than 30It seems that the post above mine (posted after I started writing this umm.. thesis..) may hint that you won't have to do much maths anymore soon though
Hope I've helped someone!![]()
Loot Spawn Lists [Unmaintained]
Discussion in 'Plugin Support' started by thomasfn, Jan 6, 2014.
-
Can any1 provide me with default loot with this coding style please?. (see the attached file)
Attached Files:
-
-
Wulf Community Admin
Attached Files:
-
-
I have a problem...it's not loading my loot tables anymore.
I tried to re-load the plugin but when I check the log it merely says
reloading oxide plugin...
My loot tables were working fine before... http://pastebin.com/CjKQc1uc
How come it's not working anymore? :/ already tried replacing the .lua but it still doesn't seem to be working. -
I have a question, could anyone possibly make me a loot table to which no metal objects, no military weapons (including c4 and explosives), no kevlar, and no ammo drops?
-
The only problem is that I can't get the SupplyDropSpawnListMaster to work like I want. No matter how much I set the min and max values it always drop a random number of crates between 1 and 3.
Also the SupplyDropA, B, C... doesn't seem to respect the nodupe: true, it keeps getting me two of the same package. [2]
Anyone? -
I have a question and im afraid to start my server up before i get this cleared This is the "default =" looting table http://pastebin.com/EJGThhWf . I have made and calculated a few minor changes. My question is what drops the "ArmorPartSpawnList" and the "WeaponBlueprintSpawnList" and LeatherArmorLootList because its not under the zombiedroplist or any of the crates/boxes lists? please help!!! there is a few lists but i dont under stand how they are implemented into the drops or what even drops them?
-
My list isn't stopping Explosive Charges from dropping. Here's my list: http://pastebin.com/3q8D9Thx
-
-
Do the min/max values for each List have to come at the start of the code? Ever since I modified my lists, boxes and zombies only drop 1 item each, even though I set max to 2 or 3 for most of the lists. However, my code looks like this:
Code:"LeatherArmorLootList":{ "packages":{ "1":{ "object":"Leather Helmet", "min":1, "weight":10, "max":1 }, "2":{ "object":"Leather Pants", "min":1, "weight":45, "max":1 }, "3":{ "object":"Leather Vest", "min":1, "weight":5, "max":1 }, "0":{ "object":"Leather Boots", "min":1, "weight":40, "max":1 } }, "nodupes":false, "max":2, "oneofeach":false, "min":1 },
-
-
Hi there,
I found a modified table for this addon on the internet and it worked fine. I changed some information though in the script to add more wood walls etc to the aidrops.
After i applied this i noticed that the airdrops do drop their original loot again ( c4/F1 grenades etc ) and i want those to be removed from my server in airdrop packages /zombie loot and crates.
I uploaded the config file. Can anyone check what the problem might be? i have 0% experience with this kind of stuff. Thanks a lot !Attached Files:
-
-
Attached Files:
-
-
Hey Makin,
Thanks a lot man ! i tried with the JSON stuff first but i did not get anything of it. il check your modified with my upload so i maybe finally understand what i did wrong -
Hey guys i configured a loot table and loaded it 2 server.. http://pastebin.com/6msdgY1t no where in ammo crate spawns are explosive charges but they drop on the server.. also the airdops spawn wooden stuff which shouldnt be.. thx 4 help
////////////////// could fix it by my own in rly hard work if u have no idea what 2 do rly xDLast edited by a moderator: Jan 28, 2014 -
Your main issue was missing values in the airdrop packages and a few closes here and there.
Hope everything is resolved for you. -
AWESOME. I will try this when I get home. -
I just thought I'd mention I am getting different combinations and numbers to what is actually set in my airdrop packages.
Can you guys see any problems?
Here is my code for airdrops..
Code:"SupplyDropSpawnListMaster": { "min": 1, "max": 1, "oneofeach": false, "nodupes": false, "packages": { "0": { "min": 1, "max": 1, "weight": 40, "object": "SupplyDropA" }, "1": { "min": 1, "max": 1, "weight": 20, "object": "SupplyDropB" }, "2": { "min": 1, "max": 1, "weight": 40, "object": "SupplyDropC" } } },
Code:"SupplyDropA": { "min": 3, "max": 4, "oneofeach": false, "nodupes": true, "packages": { "0": { "min": 1, "max": 1, "weight": 20, "object": "AirdropWeaponList" }, "1": { "min": 50, "max": 50, "weight": 20, "object": "556 Ammo" }, "2": { "min": 50, "max": 50, "weight": 20, "object": "9mm Ammo" }, "3": { "min": 50, "max": 50, "weight": 20, "object": "Shotgun Shells" }, "4": { "min": 1, "max": 2, "weight": 20, "object": "WeaponModList" } } }, "SupplyDropB": { "min": 3, "max": 4, "oneofeach": false, "nodupes": true, "packages": { "0": { "min": 1, "max": 1, "weight": 15, "object": "Explosive Charge" }, "1": { "min": 2, "max": 5, "weight": 15, "object": "F1 Grenade" }, "2": { "min": 1, "max": 1, "weight": 10, "object": "Explosives" }, "3": { "min": 1, "max": 1, "weight": 15, "object": "KevlarList" }, "4": { "min": 50, "max": 50, "weight": 15, "object": "556 Ammo" }, "5": { "min": 50, "max": 50, "weight": 15, "object": "Shotgun Shells" }, "6": { "min": 50, "max": 50, "weight": 15, "object": "9mm Ammo" } } }, "SupplyDropC": { "min": 3, "max": 4, "oneofeach": false, "nodupes": true, "packages": { "0": { "min": 2, "max": 2, "weight": 25, "object": "MetalBuildingList" }, "1": { "min": 40, "max": 90, "weight": 25, "object": "Low Quality Metal" }, "2": { "min": 10, "max": 10, "weight": 25, "object": "Large Medkit" }, "3": { "min": 1, "max": 2, "weight": 20, "object": "ModBlueprintLootList" }, "4": { "min": 1, "max": 1, "weight": 5, "object": "WeaponBlueprintLootList" } } },
-
Hi here is my loot list. I wish to completely disable Explosive charge and F1 grenade from drop. However it seems to drop them by 1 each from supply drop and zombies.
Can any1 help me out with this?.Attached Files:
-
-
Can someone look this over and explain why I only ever get 1 item per box or killed zombie? It is stumping me.
http://pastebin.com/fTfJTPvz