From c6718c94bf4cca861fd22fdf854e2103a5779324 Mon Sep 17 00:00:00 2001 From: Lukas Matena Date: Thu, 21 Dec 2017 14:24:47 +0100 Subject: [PATCH] Merge fix --- xs/src/libslic3r/Print.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/xs/src/libslic3r/Print.cpp b/xs/src/libslic3r/Print.cpp index 3cb2e481b..8b7f9805c 100644 --- a/xs/src/libslic3r/Print.cpp +++ b/xs/src/libslic3r/Print.cpp @@ -1044,14 +1044,15 @@ void Print::_make_wipe_tower() // Lets go through the wipe tower layers and determine pairs of extruder changes for each // to pass to wipe_tower (so that it can use it for planning the layout of the tower) + { - unsigned int current_extruder_id = initial_extruder_id; + unsigned int current_extruder_id = m_tool_ordering.all_extruders().back(); for (const auto &layer_tools : m_tool_ordering.layer_tools()) { // for all layers if (!layer_tools.has_wipe_tower) continue; bool first_layer = &layer_tools == &m_tool_ordering.front(); wipe_tower.plan_toolchange(layer_tools.print_z, layer_tools.wipe_tower_layer_height, current_extruder_id, current_extruder_id); for (const auto extruder_id : layer_tools.extruders) { - if ((first_layer && extruder_id == initial_extruder_id) || extruder_id != current_extruder_id) { + if ((first_layer && extruder_id == m_tool_ordering.all_extruders().back()) || extruder_id != current_extruder_id) { wipe_tower.plan_toolchange(layer_tools.print_z, layer_tools.wipe_tower_layer_height, current_extruder_id, extruder_id); current_extruder_id = extruder_id; } @@ -1069,7 +1070,7 @@ void Print::_make_wipe_tower() wipe_tower.generate(m_wipe_tower_tool_changes); // Set current_extruder_id to the last extruder primed. - unsigned int current_extruder_id = m_tool_ordering.all_extruders().back(); + /*unsigned int current_extruder_id = m_tool_ordering.all_extruders().back(); for (const ToolOrdering::LayerTools &layer_tools : m_tool_ordering.layer_tools()) { if (! layer_tools.has_wipe_tower)