diff --git a/src/Mod/Path/PathScripts/PathDrilling.py b/src/Mod/Path/PathScripts/PathDrilling.py index 56c4d12ef6..d8c5c3e05a 100644 --- a/src/Mod/Path/PathScripts/PathDrilling.py +++ b/src/Mod/Path/PathScripts/PathDrilling.py @@ -87,6 +87,7 @@ class ObjectDrilling(PathCircularHoleBase.ObjectOp): lastAxis = None lastAngle = 0.0 + parentJob = PathUtils.findParentJob(obj) self.commandlist.append(Path.Command("(Begin Drilling)")) @@ -151,7 +152,10 @@ class ObjectDrilling(PathCircularHoleBase.ObjectOp): self.opSetDefaultRetractHeight(obj) cmdParams['R'] = obj.RetractHeight.Value + # move to hole location self.commandlist.append(Path.Command('G0', {'X': p['x'], 'Y': p['y'], 'F': self.horizRapid})) + startHeight = obj.StartDepth.Value + parentJob.SetupSheet.SafeHeightOffset.Value + self.commandlist.append(Path.Command('G0', {'Z': startHeight, 'F': self.vertFeed})) self.commandlist.append(Path.Command('G1', {'Z': obj.StartDepth.Value, 'F': self.vertFeed})) # Update changes to parameters