Package net.minecraftforge.fluids

Examples of net.minecraftforge.fluids.FluidTankInfo


      FluidStack fluid = tank.fluid;
      if (fluid != null)
        fluidAmount += fluid.amount;
    }

    FluidTankInfo tank = transport.getTankInfo(ForgeDirection.UNKNOWN)[0];
    FluidStack fluid = null;

    if (tank != null)
      fluid = tank.fluid;
View Full Code Here


      throw new Exception("Unable to access turbine - port is not connected");
    }

    ComputerMethod computerMethod = ComputerMethod.values()[method];
    MultiblockTurbine turbine = getTurbine();
    FluidTankInfo ti;

    switch(computerMethod) {
    case getConnected:
      return new Object[] { isConnected() };
    case getActive:
View Full Code Here

    if(idx < 0) {
      // All tanks
      info = new FluidTankInfo[fluids.length];
      for(int i = 0; i < fluids.length; i++) {
        info[i] = new FluidTankInfo(fluids[i] == null ? null : fluids[i].copy(), getCapacity());
      }
     
      return info;
    }
    else {
      info = new FluidTankInfo[1];
      info[0] = new FluidTankInfo(fluids[idx] == null ? null : fluids[idx].copy(), getCapacity());
    }

    return info;
  }
View Full Code Here

  @Override
  public FluidTankInfo[] getTankInfo(ForgeDirection from)
  {
    if(from == ForgeDirection.getOrientation(facing).getOpposite())
    {
      return new FluidTankInfo[] {new FluidTankInfo(inputFluidTank)};
    }
   
    return PipeUtils.EMPTY;
  }
View Full Code Here

    if(master == null)
    {
      return PipeUtils.EMPTY;
    }

    return new FluidTankInfo[] {new FluidTankInfo(master.waterTank), new FluidTankInfo(master.brineTank)};
  }
View Full Code Here

  }

  @Override
  public FluidTankInfo getInfo()
  {
    return new FluidTankInfo(this);
  }
View Full Code Here

    }

    @Override
    public FluidTankInfo[] getTankInfo(ForgeDirection from)
    {
        return new FluidTankInfo[] { new FluidTankInfo(this.waterTank) };
    }
View Full Code Here

    }

    @Override
    public FluidTankInfo getInfo()
    {
        return new FluidTankInfo(this);
    }
View Full Code Here

  }

  @Override
  public FluidTankInfo getInfo() {

    return new FluidTankInfo(this);
  }
View Full Code Here

    ITileStructure central = ((TileHatch) tile).getCentralTE();
    if (central == null || !(central instanceof TileFarmPlain))
      return false;

    TankManager tankManager = ((TileFarmPlain) central).getTankManager();
    FluidTankInfo info = tankManager.getTankInfo(0);
    if (info.fluid == null)
      return true;
    return ((float) info.fluid.amount / info.capacity) <= threshold;
  }
View Full Code Here

TOP

Related Classes of net.minecraftforge.fluids.FluidTankInfo

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.