Adding cool down and heat up settings for dual extrusion
This commit is contained in:
parent
8c69c37c2c
commit
d8d8e78a98
8 changed files with 87 additions and 48 deletions
|
|
@ -379,14 +379,15 @@ namespace MatterControl.Printing
|
|||
return false;
|
||||
}
|
||||
|
||||
public (int toolIndex, double time) NextToolChange(int instructionIndex, int currentToolIndex = -1)
|
||||
public (int toolIndex, double time) NextToolChange(int instructionIndex, int currentToolIndex = -1, int toolToLookFor = -1)
|
||||
{
|
||||
int nextToolChange = -1;
|
||||
// find the first tool change that we are less than
|
||||
for (int i = 0; i < toolChanges.Count; i++)
|
||||
{
|
||||
if (instructionIndex < toolChanges[i]
|
||||
&& GCodeCommandQueue[toolChanges[i]].ToolIndex != currentToolIndex)
|
||||
&& GCodeCommandQueue[toolChanges[i]].ToolIndex != currentToolIndex
|
||||
&& (toolToLookFor == -1 || GCodeCommandQueue[toolChanges[i]].ToolIndex == toolToLookFor))
|
||||
{
|
||||
nextToolChange = i;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue