diff --git a/LuaLibs/FaceData.lua b/LuaLibs/FaceData.lua index 11b4926..d488119 100644 --- a/LuaLibs/FaceData.lua +++ b/LuaLibs/FaceData.lua @@ -422,6 +422,7 @@ local function GetBottomFaces( Proc) CurrentEdge.ptStart = BottomFaces[1].Edges[i].ptStart CurrentEdge.ptEnd = BottomFaces[1].Edges[i].ptEnd CurrentEdge.vtEdge = BottomFaces[1].Edges[i].vtEdge + CurrentEdge.id = BottomFaces[1].Edges[i].id if nFirstLongEdgeIndex then if i == nFirstLongEdgeIndex then @@ -520,6 +521,7 @@ local function GetLongFaces( Proc, MainFaces) CurrentEdge.ptStart = LongFaces[i].Edges[j].ptStart CurrentEdge.ptEnd = LongFaces[i].Edges[j].ptEnd CurrentEdge.vtEdge = LongFaces[i].Edges[j].vtEdge + CurrentEdge.id = LongFaces[i].Edges[j].id if Proc.Topology.sFamily == 'Tunnel' then if CurrentEdge.idAdjacentFace > -1 then @@ -619,6 +621,7 @@ local function GetSideFaces( Proc, MainFaces) CurrentEdge.ptStart = SideFaces[i].Edges[j].ptStart CurrentEdge.ptEnd = SideFaces[i].Edges[j].ptEnd CurrentEdge.vtEdge = SideFaces[i].Edges[j].vtEdge + CurrentEdge.id = SideFaces[i].Edges[j].id if Proc.Topology.sFamily == 'Tunnel' then if CurrentEdge.idAdjacentFace > -1 then diff --git a/LuaLibs/MachiningLib.lua b/LuaLibs/MachiningLib.lua index a4b8bf3..4f53bf9 100644 --- a/LuaLibs/MachiningLib.lua +++ b/LuaLibs/MachiningLib.lua @@ -584,6 +584,7 @@ function MachiningLib.FindBlade( Proc, ToolSearchParameters) end -- se dati sufficienti, si determina se con questo utensile il taglio è fattibile e il modo di lavorare della lama + -- TODO corretto il calcolo della dDepthToMachine? è comunque inutile calcolare per una profondità che so già andrà in collisione if bIsToolCompatible then if FaceToMachine and EdgeToMachine and Part and dElevation then local bIsBladeOk = false @@ -592,7 +593,7 @@ function MachiningLib.FindBlade( Proc, ToolSearchParameters) Edge = EdgeToMachine, Part = Part, Tool = TOOLS[i], - dDepthToMachine = dElevation + dDepthToMachine = min( dElevation, TOOLS[i].dMaxDepth) } local BladeEngagementOptionalParameters = { bIsDicing = bIsDicing