mirror of
https://github.com/GTNewHorizons/NotEnoughItems.git
synced 2026-11-12 00:17:51 +00:00
Add a way to compare NBT leniently (#209)
* Fix itemstack comparator not handling NBT leniently * add util function to PositionedStack
This commit is contained in:
1 parent
3291dab52d
commit
6609911d96
4 files changed
+101
-2
No files matched your search
@@ -98,6 +98,14 @@ public class PositionedStack
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean containsWithNBT(ItemStack ingredient) {
|
||||
for(ItemStack item : items)
|
||||
if(NEIServerUtils.areStacksSameTypeCraftingWithNBT(item, ingredient))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean contains(Item ingred) {
|
||||
for(ItemStack item : items)
|
||||
if(item.getItem() == ingred)
|
||||
|
||||
Reference in new issue
Block a user