FIX: the print_z is incorrect when use 0.8 nozzle printer

jira: none
Change-Id: Ie06c0e1b763be7178246e5dae101e650b8534f4b
(cherry picked from commit 3309a40d42726169d6ee952ff31063b654a6fbdf)
This commit is contained in:
zhimin.zeng
2025-02-17 14:10:21 +08:00
committed by Noisyfox
parent b84cca503f
commit d375836781

View File

@@ -4066,6 +4066,13 @@ LayerResult GCode::process_layer(
}
if(!timepals_gcode.empty()){
m_writer.set_current_position_clear(false);
double temp_z_after_tool_change;
if (GCodeProcessor::get_last_z_from_gcode(timepals_gcode, temp_z_after_tool_change)) {
Vec3d pos = m_writer.get_position();
pos(2) = temp_z_after_tool_change;
m_writer.set_position(pos);
}
}
return timepals_gcode;
};