[Feature] Abilities to Blacklist items from entering Backpack
JoeSGT opened this issue ยท 4 comments
can this feature be on 1.12.2
basically what the title said Abilities to Blacklist items from entering Backpack
an configuration option to disallow items in backpack the reason for this is to prevent players from putting certains items that can cause you to crash example issue #148 having over sized packet when you tried to put ME cells in them because it's having an HUGE NBT thing causing playerdata or the server to crash cause that error
i feel this is the best way to prevent it because it might be more item's beside just Applied Energistics ME cells that can cause issues and another thing config or just prevent backpack in backpacks
this way it can improve the way not to get corrupted
thanks
Another way I was going to combat this issue was to have a configurable max to how deep you can nest backpacks. The config already exists, it just doesn't function.
It'll be a bit before I can write some proper docs for this, but it's pretty simple. The blacklist consists of 2 different lists. An Item + Meta list and an NBT key list. There is a new file in config/ironbackpacks
called blacklist.json
.
Default:
{
"itemBlacklist": [
],
"nbtBlacklist": [
]
}
itemBlacklist
is an array of objects consisting of 2 values:
item
which is the registry name of the item to blacklist.meta
which is the meta value of the item to blacklist. You can use32767
as a wildcard value.
nbtBlacklist
is an array of strings. These are NBT keys to be found on any item. You can specify sub-tags by separating them with a .
(ie: foo.bar
will look for bar
inside a foo
compound)
Example:
{
"itemBlacklist": [
{
"item": "minecraft:stone",
"meta": 0
}
],
"nbtBlacklist": [
"display"
]
}
This will stop the user from placing default stone or any named item inside a backpack.