Examples of IMEInventoryHandler


Examples of appeng.api.storage.IMEInventoryHandler

    double available = extractAEPower( req, Actionable.SIMULATE, PowerMultiplier.CONFIG );
    if ( available >= req - 0.01 )
    {
      try
      {
        IMEInventoryHandler h = getHandler( StorageChannel.FLUIDS );

        extractAEPower( req, Actionable.MODULATE, PowerMultiplier.CONFIG );
        IAEStack results = h.injectItems( AEFluidStack.create( resource ), doFill ? Actionable.MODULATE : Actionable.SIMULATE, mySrc );

        if ( results == null )
          return resource.amount;

        return resource.amount - (int) results.getStackSize();
View Full Code Here

Examples of appeng.api.storage.IMEInventoryHandler

  @Override
  public boolean canFill(ForgeDirection from, Fluid fluid)
  {
    try
    {
      IMEInventoryHandler h = getHandler( StorageChannel.FLUIDS );
      return h.canAccept( AEFluidStack.create( new FluidStack( fluid, 1 ) ) );
    }
    catch (ChestNoHandler ignored)
    {
    }
    return false;
View Full Code Here

Examples of appeng.api.storage.IMEInventoryHandler

  @Override
  public FluidTankInfo[] getTankInfo(ForgeDirection from)
  {
    try
    {
      IMEInventoryHandler h = getHandler( StorageChannel.FLUIDS );
      if ( h.getChannel() == StorageChannel.FLUIDS )
        return new FluidTankInfo[] { new FluidTankInfo( null, 1 ) }; // eh?
    }
    catch (ChestNoHandler ignored)
    {
    }
View Full Code Here

Examples of appeng.api.storage.IMEInventoryHandler

  @Override
  public List<IMEInventoryHandler> getCellArray(StorageChannel channel)
  {
    if ( channel == StorageChannel.ITEMS )
    {
      IMEInventoryHandler out = proxy.isActive() ? getInternalHandler() : null;
      if ( out != null )
        return Arrays.asList( out );
    }
    return Arrays.asList( new IMEInventoryHandler[] {} );
  }
View Full Code Here

Examples of appeng.api.storage.IMEInventoryHandler

        {
          handlersBySlot[x] = AEApi.instance().registries().cell().getHandler( is );

          if ( handlersBySlot[x] != null )
          {
            IMEInventoryHandler cell = handlersBySlot[x].getCellInventory( is, this, StorageChannel.ITEMS );

            if ( cell != null )
            {
              power += handlersBySlot[x].cellIdleDrain( is, cell );
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.