fix #49. you can now actually clear storage and conversion monitors

This commit is contained in:
PrototypeTrousers
2021-09-18 21:41:57 -03:00
parent 2cb452fd9e
commit e6ccc24ae0
2 changed files with 10 additions and 4 deletions
@@ -206,10 +206,17 @@ public abstract class AbstractPartMonitor extends AbstractPartDisplay implements
fluidInTank = fluidHandlerItem.drain( Integer.MAX_VALUE, false );
}
if (fluidInTank == null)
if( fluidInTank == null )
{
this.configuredFluid = null;
this.configuredItem = AEItemStack.fromItemStack( eq );
if( !eq.isEmpty() )
{
this.configuredItem = AEItemStack.fromItemStack( eq ).setStackSize( 0 );
}
else
{
this.configuredItem = null;
}
}
else if( fluidInTank.amount > 0 )
{
@@ -170,8 +170,7 @@ public class PartConversionMonitor extends AbstractPartMonitor
this.insertItem( player, hand, false );
}
}
return true;
return super.onPartActivate( player, hand, pos );
}
@Override