for (int i = 0; i < extraItems.length; i++) {
ItemStack stack = extraItems[i];
if (stack != null &&
(targetId == null || stack.getItem() == targetId) &&
(targetDamage <= -1 || stack.getMetadata() == targetDamage) &&
<BUG>(targetNBT == null || CommandTestForBlock.func_175775_a(targetNBT, stack.getTagCompound(), true))) {
</BUG>
int temp = amount <= 0 ? stack.stackSize : Math.min(amount - stacks, stack.stackSize);
stacks += temp;
if(amount != 0) {

for (int i = 0; i < extraItems.length; i++) {
ItemStack stack = extraItems[i];
if (stack != null &&
(targetId == null || stack.getItem() == targetId) &&
(targetDamage <= -1 || stack.getMetadata() == targetDamage) &&
(targetNBT == null || NBTUtil.func_181123_a(targetNBT, stack.getTagCompound(), true))) {
int temp = amount <= 0 ? stack.stackSize : Math.min(amount - stacks, stack.stackSize);
stacks += temp;
if(amount != 0) {
