diff --git a/src/libslic3r/GCodeWriter.cpp b/src/libslic3r/GCodeWriter.cpp index cfd3a45cd2..3e09ad89c9 100644 --- a/src/libslic3r/GCodeWriter.cpp +++ b/src/libslic3r/GCodeWriter.cpp @@ -687,7 +687,7 @@ std::string GCodeWriter::lift(LiftType lift_type, bool spiral_vase) //BBS double above = this->config.retract_lift_above.get_at(m_extruder->id()); double below = this->config.retract_lift_below.get_at(m_extruder->id()); - if (m_pos.z() >= above && (below == 0 || m_pos.z() <= below)) + if (m_pos.z() >= above && m_pos.z() <= below) target_lift = this->config.z_hop.get_at(m_extruder->id()); } // BBS diff --git a/src/libslic3r/PrintConfig.cpp b/src/libslic3r/PrintConfig.cpp index 6e3c6aa548..394a5cc1b6 100644 --- a/src/libslic3r/PrintConfig.cpp +++ b/src/libslic3r/PrintConfig.cpp @@ -2607,6 +2607,7 @@ void PrintConfigDef::init_fff_params() def->tooltip = L("Z hop will only come into effect when Z is above this value and is below the parameter: \"Z hop upper boundary\""); def->sidetext = L("mm"); def->mode = comAdvanced; + def->min = 0; def->set_default_value(new ConfigOptionFloats{0.}); def = this->add("retract_lift_below", coFloats); @@ -2614,6 +2615,7 @@ void PrintConfigDef::init_fff_params() def->tooltip = L("If this value is positive, Z hop will only come into effect when Z is above the parameter: \"Z hop lower boundary\" and is below this value"); def->sidetext = L("mm"); def->mode = comAdvanced; + def->min = 0; def->set_default_value(new ConfigOptionFloats{0.});