Fix fluid P2p voiding excess liquids (#3090)

Backported from 1.12
This commit is contained in:
fscan 2017-09-16 23:38:01 +08:00 committed by xsun2001
parent 0120df7f8c
commit 768a023897

View file

@ -150,7 +150,8 @@ public class PartP2PLiquids extends PartP2PTunnel<PartP2PLiquids> implements IFl
i = list.iterator();
int used = 0;
while( i.hasNext() )
while( i.hasNext() && available > 0 )
{
final PartP2PLiquids l = i.next();
@ -172,7 +173,7 @@ public class PartP2PLiquids extends PartP2PTunnel<PartP2PLiquids> implements IFl
}
available -= insert.amount;
used += insert.amount;
used += l.tmpUsed;
}
if( stack.pop() != this )