fix z top in indexed mode

This commit is contained in:
Stewart Allen 2025-06-12 23:11:34 -04:00
commit f4f1d881e7
2 changed files with 5 additions and 8 deletions

View file

@ -200,9 +200,6 @@ class OpRough extends CamOp {
POLY.offset([ newPolygon().centerRectangle(stock.center, stock.x, stock.y) ], step) :
POLY.offset(shadow, roughIn ? step : step + roughLeave + toolDiam / 2);
let facing = POLY.offset(inset, -step, { count: 999, flat: true });
if (isIndexed) {
ztOff = (stock.z / 2) - zMax;
}
let zdiv = ztOff / roughDown;
let zstep = (zdiv % 1 > 0) ? ztOff / (Math.floor(zdiv) + 1) : roughDown;
if (ztOff === 0) {