diff --git a/LuaLibs/BeamExec.lua b/LuaLibs/BeamExec.lua index a793209..5d16f02 100644 --- a/LuaLibs/BeamExec.lua +++ b/LuaLibs/BeamExec.lua @@ -1333,7 +1333,7 @@ end ------------------------------------------------------------------------------------------------------------- function BeamExec.ProcessFeatures() - if not BD.IMPROVE_HEAD_TAIL_DRILLINGS then + if BD.IMPROVE_HEAD_TAIL_DRILLINGS == nil then BD.IMPROVE_HEAD_TAIL_DRILLINGS = true end -- verifica se possibile rotazione di 90 gradi diff --git a/LuaLibs/ProcessDrill.lua b/LuaLibs/ProcessDrill.lua index 471a893..cf836ab 100644 --- a/LuaLibs/ProcessDrill.lua +++ b/LuaLibs/ProcessDrill.lua @@ -413,7 +413,11 @@ function ProcessDrill.Make( Proc, nPhase, nRawId, nPartId) local dToolAddLength = dLen - dMaxElev if dDepth - dToolAddLength > dMaxDepth + 10 * GEO.EPS_SMALL then sMyWarn = 'Warning in drill : depth (' .. EgtNumToString( dDepth - dToolAddLength, 1) .. ') bigger than max tool depth (' .. EgtNumToString( dMaxDepth, 1) .. ')' - dDepth = dLen + if dMaxDepth == 0 then + dDepth = 0 + else + dDepth = dLen + end EgtOutLog( sMyWarn) end EgtSetMachiningParam( MCH_MP.DEPTH, dDepth)