Compare commits
9 Commits
rv4.stable.1
...
rv4-1.10
| Author | SHA1 | Date | |
|---|---|---|---|
| 6f30658d41 | |||
| 07bcd528ea | |||
| 5cbdc1d769 | |||
| 05b29d0de0 | |||
| 4a6162907c | |||
| dfb23fd9e7 | |||
| d8ca9fc2f9 | |||
| e9a8a8cdff | |||
| 8163b30479 |
@@ -205,7 +205,15 @@ public class PacketJEIRecipe extends AppEngPacket
|
||||
if( filter == null || filter.isListed( request ) )
|
||||
{
|
||||
request.setStackSize( 1 );
|
||||
final IAEItemStack out = Platform.poweredExtraction( energy, storage, request, cct.getActionSource() );
|
||||
IAEItemStack out;
|
||||
if ( realForFake == Actionable.SIMULATE )
|
||||
{
|
||||
out = storage.extractItems( request, Actionable.SIMULATE, cct.getActionSource() );
|
||||
}
|
||||
else
|
||||
{
|
||||
out = Platform.poweredExtraction( energy, storage, request, cct.getActionSource() );
|
||||
}
|
||||
if( out != null )
|
||||
{
|
||||
whichItem = out.getItemStack();
|
||||
|
||||
@@ -21,8 +21,6 @@ package appeng.helpers;
|
||||
|
||||
import java.util.Iterator;
|
||||
|
||||
import scala.NotImplementedError;
|
||||
|
||||
|
||||
public class NonNullArrayIterator<E> implements Iterator<E>
|
||||
{
|
||||
@@ -58,6 +56,6 @@ public class NonNullArrayIterator<E> implements Iterator<E>
|
||||
@Override
|
||||
public void remove()
|
||||
{
|
||||
throw new NotImplementedError();
|
||||
throw new UnsupportedOperationException();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ package appeng.integration.modules.jei;
|
||||
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
@@ -28,7 +29,6 @@ import net.minecraft.item.ItemStack;
|
||||
import mezz.jei.api.ingredients.IIngredients;
|
||||
import mezz.jei.api.recipe.BlankRecipeWrapper;
|
||||
import mezz.jei.api.recipe.wrapper.IShapedCraftingRecipeWrapper;
|
||||
import scala.actors.threadpool.Arrays;
|
||||
|
||||
import appeng.api.exceptions.MissingIngredientError;
|
||||
import appeng.api.exceptions.RegistrationError;
|
||||
|
||||
@@ -136,10 +136,12 @@ class ItemHandlerAdapter implements IMEInventory<IAEItemStack>, IBaseMonitor<IAE
|
||||
extracted.stackSize = remainingCurrentSlot;
|
||||
}
|
||||
|
||||
// We're just gonna use the first stack we get our hands on as the template for the rest
|
||||
// We're just gonna use the first stack we get our hands on as the template for the rest.
|
||||
// In case some stupid itemhandler (aka forge) returns an internal state we have to do a second
|
||||
// expensive copy again.
|
||||
if( gathered == null )
|
||||
{
|
||||
gathered = extracted;
|
||||
gathered = extracted.copy();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -199,7 +199,7 @@ public class PartP2PFluids extends PartP2PTunnel<PartP2PFluids> implements IFlui
|
||||
i = list.iterator();
|
||||
int used = 0;
|
||||
|
||||
while( i.hasNext() )
|
||||
while( i.hasNext() && available > 0 )
|
||||
{
|
||||
final PartP2PFluids l = i.next();
|
||||
|
||||
@@ -221,7 +221,7 @@ public class PartP2PFluids extends PartP2PTunnel<PartP2PFluids> implements IFlui
|
||||
}
|
||||
|
||||
available -= insert.amount;
|
||||
used += insert.amount;
|
||||
used += l.tmpUsed;
|
||||
}
|
||||
|
||||
if( stack.pop() != this )
|
||||
|
||||
@@ -169,6 +169,7 @@ public class AppEngInternalAEInventory implements IInventory, Iterable<ItemStack
|
||||
if( this.te != null && Platform.isServer() )
|
||||
{
|
||||
this.te.onChangeInventory( this, slot, InvOperation.decreaseStackSize, ns, null );
|
||||
this.te.saveChanges();
|
||||
}
|
||||
|
||||
return ns;
|
||||
@@ -215,6 +216,7 @@ public class AppEngInternalAEInventory implements IInventory, Iterable<ItemStack
|
||||
}
|
||||
|
||||
this.te.onChangeInventory( this, slot, InvOperation.setInventorySlotContents, removed, added );
|
||||
this.te.saveChanges();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -242,6 +244,7 @@ public class AppEngInternalAEInventory implements IInventory, Iterable<ItemStack
|
||||
if( this.te != null && Platform.isServer() )
|
||||
{
|
||||
this.te.onChangeInventory( this, -1, InvOperation.markDirty, null, null );
|
||||
this.te.saveChanges();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -174,6 +174,7 @@ public class AppEngInternalInventory implements IInventory, Iterable<ItemStack>
|
||||
if( this.getTileEntity() != null && this.eventsEnabled() )
|
||||
{
|
||||
this.getTileEntity().onChangeInventory( this, -1, InvOperation.markDirty, null, null );
|
||||
this.getTileEntity().saveChanges();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -200,6 +201,7 @@ public class AppEngInternalInventory implements IInventory, Iterable<ItemStack>
|
||||
if( this.getTileEntity() != null && this.eventsEnabled() )
|
||||
{
|
||||
this.getTileEntity().onChangeInventory( this, slotIndex, InvOperation.markDirty, null, null );
|
||||
this.getTileEntity().saveChanges();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1423,7 +1423,7 @@ public class Platform
|
||||
|
||||
if( target.hasCapability( Capabilities.STORAGE_MONITORABLE_ACCESSOR, null ) )
|
||||
{
|
||||
return 0;
|
||||
return target.getCapability( Capabilities.STORAGE_MONITORABLE_ACCESSOR, null ).hashCode();
|
||||
}
|
||||
else if( target instanceof TileEntityChest )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user