Dynamic tank infinite fluid
tossaponk opened this issue ยท 2 comments
Dynamic tank will not draining fluid from the pipe network if the tank is at its full capacity.
if(doFill)
{
dynamicTank.structure.fluidStored.amount = getCapacity(); << This will cause subsequent call for getNeeded to return 0 thus making infinite fluid.
if(getNeeded() > 0)
{
MekanismUtils.saveChunk(dynamicTank);
updateValveData(true);
dynamicTank.sendPacketToRenderer();
updateValveData(false);
}
}
return getNeeded();
This can be fixed by storing getNeeded() in a variable before setting fluid amount to tank capacity.
I am also experiencing this problem whereby a dynamic tank that I have completely filled, when connected to a pipe network with other devices, becomes an infinite source of it's contained liquid.