Fixed Crafting CPU Render.
Finished Crafting Confirm Screen Added logic to prevent crafting in cpus with too little storage.
This commit is contained in:
@@ -386,8 +386,13 @@ public class CraftingCPUCluster implements IAECluster, ICraftingCPU
|
||||
|
||||
private void updateCPU()
|
||||
{
|
||||
IAEItemStack send = finalOutput;
|
||||
|
||||
if ( finalOutput != null && finalOutput.getStackSize() <= 0 )
|
||||
send = null;
|
||||
|
||||
for (TileCraftingMonitorTile t : status)
|
||||
t.setJob( finalOutput );
|
||||
t.setJob( send );
|
||||
}
|
||||
|
||||
public IGrid getGrid()
|
||||
@@ -468,6 +473,10 @@ public class CraftingCPUCluster implements IAECluster, ICraftingCPU
|
||||
myLastLink = null;
|
||||
tasks.clear();
|
||||
waitingFor.resetStatus();
|
||||
|
||||
finalOutput = null;
|
||||
updateCPU();
|
||||
|
||||
storeItems(); // marks dirty
|
||||
}
|
||||
|
||||
@@ -701,6 +710,9 @@ public class CraftingCPUCluster implements IAECluster, ICraftingCPU
|
||||
if ( !(job instanceof CraftingJob) )
|
||||
return null;
|
||||
|
||||
if ( isBusy() || getAvailableStorage() < job.getByteTotal() )
|
||||
return null;
|
||||
|
||||
IStorageGrid sg = g.getCache( IStorageGrid.class );
|
||||
IMEInventory<IAEItemStack> storage = sg.getItemInventory();
|
||||
MECraftingInventory ci = new MECraftingInventory( storage, true, false, false );
|
||||
|
||||
Reference in New Issue
Block a user