Chunk Collector
Pair minions with a collector so their items gather in one storage, or sweep up the items lying on the ground.
A chunk collector gathers items into one place. Instead of emptying five minions one by one, players empty one collector. Players choose which minions feed it by pairing them, and the collector can also pick up items lying on the ground.
Modes
| Mode | Takes items from paired minions | Picks up ground items |
|---|---|---|
PAIRED | Yes | No |
GROUND | No | Yes |
BOTH | Yes | Yes |
Each collector remembers its own mode. The owner switches it with the Collecting button in the collector's menu, so two collectors of the same type can do different jobs.
settings:
mode: PAIRED
modes:
- PAIRED
- GROUND| Key | Shipped value | What it does |
|---|---|---|
settings.mode | PAIRED | The mode a newly placed collector starts in. An unknown value falls back to PAIRED |
settings.modes | PAIRED, GROUND | The modes the owner can switch between. Add BOTH to offer it, or list one mode to lock every collector of this type to it |
- Each click on the Collecting button moves to the next mode in
settings.modes, in the order they are listed, and starts again from the top after the last one. Only the owner and players withminioncore.admin.bypasscan use it. - When
settings.modeis not insettings.modes, it is added to the front of the list. - A collector whose saved mode is no longer in
settings.modesgoes back tosettings.mode. MINION, the mode name from 1.0.0-1, is read asPAIRED, so older type files keep working.
The collector's area
Like the chunk loader, the area is a square of chunks centred on the collector's chunk, set per level with chunk-radius. 1 is its own chunk, 2 is 3 by 3, and 3 is 5 by 5. The Chunk area item in its menu shows the size and how many other minions stand inside.
A paired minion counts as in range while the block it stands on is inside that square. How far the minion itself works does not matter.
A collector does not keep chunks loaded. Pair it with a chunk loader if the area should keep working while players are away.
Pairing
A collector only takes items from minions that are paired with it and stand inside its area. Players pair minions from the Pair a minion button or with /minion pair, and the number of pairs is capped by the collector's connections. See Collector pairing for how it works.
Ground pickup
In GROUND and BOTH mode, the collector sweeps its area on every action and picks up dropped items. It only looks in chunks that are loaded.
A newly placed collector starts in PAIRED mode, the shipped settings.mode, and picks up nothing from the ground. Switch it to GROUND or BOTH with the Collecting button first.
| Key | Shipped value | What it does |
|---|---|---|
settings.ground-pickup-delay-seconds | 5 | How long an item must have been on the ground first |
settings.ignore-player-drop-seconds | 30 | How long an item a player threw is left alone |
An item is left where it is when any of these is true:
- It has been on the ground for less than
ground-pickup-delay-seconds. - A player threw it less than
ignore-player-drop-secondsago. - It still has a pickup delay, the short wait before anyone can pick an item up.
- It is set so only one player can pick it up.
- It carries a scoreboard tag listed in
ground-items.protected-tagsinconfig.yml, see below. - It carries data from a plugin listed in
ground-items.protected-pluginsinconfig.yml, see below. - The collector's filter does not accept it.
Items with data from other plugins
Many plugins store their own data on items, and some, such as ItemsAdder, tag every item a player drops. Data like that no longer stops an item being collected. Only data from the plugins you name, and scoreboard tags you name, keep an item on the ground:
ground-items:
protected-plugins: []
protected-tags: []Write each plugin by name, for example [ItemsAdder, MyDungeons]. The names are matched against the namespace of the item's data without caring about capitals, which is the plugin's name in lower case for nearly every plugin. The shipped list is empty, so every item is collectable as far as other plugins' data goes. The same list is used by lumberjacks when they pick up saplings.
Up to 1.0.0-2 any item carrying data from another plugin was skipped. On a server with ItemsAdder that meant a ground collector picked up nothing a player dropped. If a plugin of yours drops items that must stay on the ground, such as quest items or loot another plugin tracks, add it to the list.
protected-tags works the same way for scoreboard tags, the plain text tags some plugins put on an item entity. Write each tag exactly as the item carries it, for example [QuestLoot]. Tags are matched with capitals as written, and spaces around a tag are ignored. Tags not on the list are ignored, and the shipped list is empty. To find out which tags an item carries, stand next to it and run /minion admin debug ground, which prints them under the item's line.
Up to 1.0.0-4 any scoreboard tag kept an item on the ground, whichever plugin put it there. On a server where another plugin tags dropped items, a ground collector left those items behind.
Items stacked by RoseStacker
RoseStacker merges dropped items into one item entity and keeps the real size of the stack itself. The item entity holds at most one full stack, 64 for most items, while RoseStacker counts the rest. When RoseStacker is installed, ground collectors and lumberjacks read the real size. They take as much as fits in storage and leave the rest in the same stack on the ground, with its size lowered. Nothing is lost when storage runs out part way.
Nothing needs setting up. The console says RoseStacker was found, collectors and lumberjacks take the full size of stacked items. on start.
If RoseStacker is installed but MinionCore cannot reach its API, for example after a RoseStacker update that changed it, the console logs a warning and collectors and lumberjacks leave every dropped item alone. Taking part of a stack without knowing its size could delete the rest. /minion admin debug ground then gives the reason RoseStacker stack sizes could not be read, items are left alone.
A player's own drops are left alone for 30 seconds with the shipped values, and every other item for 5, so a fresh drop staying where it is for a short while is normal.
Two collectors on one spot
When two ground collectors cover the same spot, the one nearest the item takes it, but only if it really would. A nearer collector that cannot take the item does not hold it back from the next one. That is the case when:
- It is paused, broken, out of fuel, stopped by its owner's offline rules, or in a chunk that is not loaded.
- It is full, or its filter does not accept the item.
- Its own
ground-pickup-delay-secondsorignore-player-drop-secondsmakes it wait longer.
If a stack only partly fits, the rest stays on the ground for the next action.
Up to 1.0.0-3 only a paused nearer collector was skipped. A nearer collector that was full, broken, out of fuel or filtering the item still kept the others away, so items close to it stayed on the ground for good.
Checking why an item stays on the ground
Stand next to the items and run:
/minion admin debug groundIt lists up to 20 dropped items within 16 blocks of you, nearest first, and for each one names the collector that takes it next, or the reason none does. A RoseStacker stack shows its real size, such as x150. When an item carries scoreboard tags, a tags: line under it lists them, so you can tell which plugin tagged it. It needs minioncore.admin.debug.
| Reason | What to do |
|---|---|
| No collector covers this chunk | Place a collector closer, or level it up for a larger area |
Not set to GROUND or BOTH | Switch it with the Collecting button |
| Not working, with its status | Repair it, unpause it, add fuel or load its chunk |
| Outside its area | The item lies in a chunk the collector's level does not reach |
| Still has a pickup delay, belongs to one player | Another plugin set this on the item. MinionCore leaves such items alone |
| Carries the protected scoreboard tag, with the tag | The tag is listed in ground-items.protected-tags |
| Carries data from a protected plugin | The plugin is listed in ground-items.protected-plugins |
| RoseStacker stack sizes could not be read | MinionCore could not reach RoseStacker's API, see Items stacked by RoseStacker |
| Waits N more seconds on the ground | ground-pickup-delay-seconds has not passed yet |
| Dropped by a player, left alone for N more seconds | ignore-player-drop-seconds has not passed yet |
| The filter does not keep it | Change the collector's filter |
| No room for it | Empty the collector or add storage upgrades |
When several collectors cover the item, the line names the one that comes closest to taking it.
A ground collector does not check who dropped an item or whose land it is on. Anything in its area that passes the rules above is picked up.
Storage
Collected items go into the collector's storage. The shipped levels:
| Level | chunk-radius | connections | delay | storage | fuel-efficiency | Cost of the next level |
|---|---|---|---|---|---|---|
| 1 | 1 | 1 | 10 | 9 | 0 | money: 20000 |
| 2 | 2 | 2 | 8 | 18 | 5 | money: 45000 |
| 3 | 3 | 3 | 6 | 27 | 10 | money: 90000 |
| 4 | 3 | 4 | 4 | 36 | 15 | Max level |
max-storage: 90 caps the storage, storage upgrades included. The delay is how often the collector acts, which is when it sweeps the ground and pulls stored items from paired minions. Items made by a paired minion arrive the moment it works, whatever the delay.
Open the storage from the Storage button in the collector's menu:
- Click an item to take the stack, or right click to take half.
- Take everything (slot
48) moves everything that fits into your inventory. - Sell everything (slot
50) sells every item that has a price undersell.pricesinconfig.yml. It only shows whensell.enabledistrueand Vault has an economy. Items without a price stay.
All three need the take-storage access. See The minion menu and Menus.
Collector buttons
These buttons are only shown in a chunk collector's menu, set under minion.items in gui.yml.
| Button | Slot | Who can use it | What it does |
|---|---|---|---|
pair | 19 | pair access | Starts pairing, then right click a minion |
paired | 20 | open access | Opens the paired minions list |
mode | 25 | Owner only | Switches to the next mode in settings.modes |
upgrade-connections | 34 | upgrade access | Takes a Connections upgrade |
Their lore can use %connections% for the minions paired now, %connection_capacity% for how many can be paired, and %collector_mode% for the current mode, which comes from menu.collector-paired, menu.collector-ground or menu.collector-both in the language file.
Limits
| Key | Where | Shipped value | What it does |
|---|---|---|---|
max-per-player | minions/chunkcollector.yml | 3 | How many collectors one player may place |
limits.count-chunk-collectors | config.yml | false | Whether collectors count towards the total limit in limits.default |
The shipped collector does not use fuel (requires-fuel: false). Turn it on in the type file if you want it to. See Fuel.