How does "place_loot"'s chance work?

so I was figuring how to make a new building, I tried both “chance” and “prob” for the spawning in the “place_loot”. But setting 100 on both did not guarantee the item spawn every time. Is it base on one is x or x/100? Or does the item spawn rate in world setting also affect the percentage calculation?

really confused by that, thanks for reading

place_loot is similar to place_items
 "place_items": [{
                        "item": "test_items",
                        "chance": 50,
                        "repeat": [10, 30],
                        "x": [1, 2],
                        "y": [3, 4]
                    }
                ]

You can use place_items instead!

Ok I did some more tests, and here is what I found out:
1.“place_item” does not work with item group, item only
2.“place_group” is a thing, but it just doesn’t work ? once I set to “place_group” nothing spawn again
3.“chance” and “prob” both work in a confusing way, only thing I am sure is both are not base on %

place_items for item group and place_item for an item.

The doc says it is used for spawning monster with monstergroups.

place_items uses chance where n% is the probability of 100%. Item is then picked from the item group to put into the specified point. The repeat is useful too!

1 Like

Thanks so much!
The doc did not have “place_items” anywhere, this is exactly what I want.
enjoy the cataclysm :slight_smile:

IIRC “prob” spawns the item until the probability roll succeeds or something like that (it’s both repeat and probability combined). Meaning low probability numbers generate big stacks of items (or was it the other way around?). It’s been a while so I don’t remember exactly.

Also IIRC 100% chance to spawn made the item spawn regardless of world drop rate, but 99% chance to spawn means it’s subject to world settings.