fix tool id comparison for change detection

This commit is contained in:
Stewart Allen 2024-09-10 11:00:27 -04:00
commit 1f0e17daeb

View file

@ -173,7 +173,7 @@ CAM.export = function(print, online) {
newpos.z = util.round(newpos.z, decimals);
// on tool change
let changeTool = !(out.tool && pos.t) || out.tool.id !== pos.t.id;
let changeTool = !(out.tool && pos.t) || out.tool.getID() !== pos.t.getID();
if (changeTool) {
pos.t = out.tool;
consts.tool = pos.t.getNumber();