Package appeng.api.storage

Examples of appeng.api.storage.IMEInventory


    ItemStack sharedItemStack = input.getItemStack();

    if ( CellInventory.isStorageCell( sharedItemStack ) )
    {
      IMEInventory meInventory = getCell( sharedItemStack, null );
      if ( meInventory != null && !isEmpty( meInventory ) )
        return input;
    }

    IAEItemStack l = getCellItems().findPrecise( input );
View Full Code Here


    if ( target != null )
    {
      IExternalStorageHandler esh = AEApi.instance().registries().externalStorage().getHandler( target, side.getOpposite(), StorageChannel.ITEMS, mySrc );
      if ( esh != null )
      {
        IMEInventory inv = esh.getInventory( target, side.getOpposite(), StorageChannel.ITEMS, mySrc );

        if ( inv instanceof MEMonitorIInventory )
        {
          MEMonitorIInventory h = (MEMonitorIInventory) inv;
          h.mode = (StorageFilter) getConfigManager().getSetting( Settings.STORAGE_FILTER );
View Full Code Here

      CellUpgrades cu = (CellUpgrades) getUpgradesInventory( item );
      if ( cu != null )
        shots += cu.getInstalledUpgrades( Upgrades.SPEED );

      IMEInventory inv = AEApi.instance().registries().cell().getCellInventory( item, null, StorageChannel.ITEMS );
      if ( inv != null )
      {
        IItemList itemList = inv.getAvailableItems( AEApi.instance().storage().createItemList() );
        IAEStack aeAmmo = itemList.getFirstItem();
        if ( aeAmmo instanceof IAEItemStack )
        {
          shots = Math.min( shots, (int) aeAmmo.getStackSize() );
          for (int sh = 0; sh < shots; sh++)
          {
            extractAEPower( item, 1600 );

            if ( Platform.isClient() )
              return item;

            aeAmmo.setStackSize( 1 );
            ItemStack ammo = ((IAEItemStack) aeAmmo).getItemStack();
            if ( ammo == null )
              return item;

            ammo.stackSize = 1;
            aeAmmo = inv.extractItems( aeAmmo, Actionable.MODULATE, new PlayerSource( p, null ) );
            if ( aeAmmo == null )
              return item;

            float f = 1.0F;
            float f1 = p.prevRotationPitch + (p.rotationPitch - p.prevRotationPitch) * f;
 
View Full Code Here

TOP

Related Classes of appeng.api.storage.IMEInventory

Copyright © 2018 www.massapicom. 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.