Compatibility
Minecraft: Java Edition
Platforms
Supported environments
Tags
Creators
Details
Now, before going to sleep, villagers will leisurely approach the nearest chests and barrels and fill them with items they trade. This only works when the villagers are within the player’s simulation.
[Full description of the mechanic] At the end of the gathering, villagers begin scanning the nearest 64 blocks in the x, y, z directions for chests and barrels. If they find any, they will, with a certain probability (default: 8% to 22%, configurable in the config), head over to them, select a random item from their trade (the probability of selecting an emerald has been significantly reduced, as otherwise villagers would almost always choose an emerald), and place it in the chest. Villagers make several attempts to do this within a set time period. This introduces a new reason to level up villagers—they can bring more valuable items, but for balance reasons, the chance of obtaining them is significantly lower.
In the future, I plan to add a condition where villagers will not fill containers if they are in captivity.


