!3041 修复:排钻自动偏移报错问题

pull/3042/MERGE
林三 1 month ago committed by ChenX
parent 36524abd21
commit 2dd37d5fb2

@ -1796,7 +1796,10 @@ export class DrawDrillingTool extends Singleton
private AutoDeviation(drillent: ObjectId<CADObject>[], woodPinss: ObjectId<CADObject>[][], needRemoveDrillList: WeakSet<WeakKey>, tHoleOffset: number, minDrillSegment: number)
{
const posX = (drillent[0].Object as CylinderHole).Position.clone().applyMatrix4(this.m_Face.OCSInv).x;
let drill = drillent.find((ent) => (ent?.Object as Hole)?.Position);
if (!drill) return;
const posX = (drill.Object as Hole).Position.clone().applyMatrix4(this.m_Face.OCSInv).x;
const index = this.m_MoveDistList.findIndex((d) => equaln(posX, d));
if (index === -1) return;

Loading…
Cancel
Save