Package erogenousbeef.bigreactors.common.multiblock.helpers

Examples of erogenousbeef.bigreactors.common.multiblock.helpers.CoolantContainer


    updatePlayers = new HashSet<EntityPlayer>();
   
    ticksSinceLastUpdate = 0;
    fuelContainer = new FuelContainer();
    radiationHelper = new RadiationHelper();
    coolantContainer = new CoolantContainer();
   
    reactorVolume = 0;
  }
View Full Code Here


  // IFluidHandler
  @Override
  public int fill(ForgeDirection from, FluidStack resource, boolean doFill) {
    if(!isConnected() || !inlet || from != getOutwardsDir()) { return 0; }
   
    CoolantContainer cc = getReactorController().getCoolantContainer();
    return cc.fill(getConnectedTank(), resource, doFill);
  }
View Full Code Here

  @Override
  public FluidStack drain(ForgeDirection from, FluidStack resource,
      boolean doDrain) {
    if(!isConnected() || from != getOutwardsDir()) { return null; }

    CoolantContainer cc = getReactorController().getCoolantContainer();
    return cc.drain(getConnectedTank(), resource, doDrain);
  }
View Full Code Here

  }

  @Override
  public FluidStack drain(ForgeDirection from, int maxDrain, boolean doDrain) {
    if(!isConnected() || from != getOutwardsDir()) { return null; }
    CoolantContainer cc = getReactorController().getCoolantContainer();
    return cc.drain(getConnectedTank(), maxDrain, doDrain);
  }
View Full Code Here

  public boolean canFill(ForgeDirection from, Fluid fluid) {
    if(!isConnected() || from != getOutwardsDir()) { return false; }

    if(!inlet) { return false; } // Prevent pipes from filling up the output tank inadvertently

    CoolantContainer cc = getReactorController().getCoolantContainer();
    return cc.canFill(getConnectedTank(), fluid);
  }
View Full Code Here

  }

  @Override
  public boolean canDrain(ForgeDirection from, Fluid fluid) {
    if(!isConnected() || from != getOutwardsDir()) { return false; }
    CoolantContainer cc = getReactorController().getCoolantContainer();
    return cc.canDrain(getConnectedTank(), fluid);
  }
View Full Code Here

 
  @Override
  public FluidTankInfo[] getTankInfo(ForgeDirection from) {
    if(!isConnected() || from != getOutwardsDir()) { return emptyTankArray; }

    CoolantContainer cc = getReactorController().getCoolantContainer();
    return cc.getTankInfo(getConnectedTank());
  }
View Full Code Here

  public void onMultiblockServerTick() {
    // Try to pump steam out, if an outlet
    if(pumpDestination == null || isInlet())
      return;

    CoolantContainer cc = getReactorController().getCoolantContainer();
    FluidStack fluidToDrain = cc.drain(CoolantContainer.HOT, cc.getCapacity(), false);
   
    if(fluidToDrain != null && fluidToDrain.amount > 0)
    {
      fluidToDrain.amount = pumpDestination.fill(getOutwardsDir().getOpposite(), fluidToDrain, true);
      cc.drain(CoolantContainer.HOT, fluidToDrain, true);
    }
  }
View Full Code Here

    if(!isConnected()) { return; }
   
    MultiblockReactor reactor = getReactorController();

    if(isInlet()) {
      CoolantContainer cc = reactor.getCoolantContainer();
      if(cc.getCoolantAmount() < cc.getCapacity())
      {
        reactor.getCoolantContainer().addCoolant(new FluidStack(FluidRegistry.WATER, cc.getCapacity()));
      }
    }
    else {
      reactor.getCoolantContainer().emptyVapor();
    }
View Full Code Here

TOP

Related Classes of erogenousbeef.bigreactors.common.multiblock.helpers.CoolantContainer

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.