function m6() local inst local selectedtool; local currenttool; inst=mc.mcGetInstance(); selectedtool = mc.mcToolGetSelected(inst) currenttool = mc.mcToolGetCurrent(inst) mc.mcCntlSetLastError(inst, "Press Cycle Start to finish the tool change."); --Remove this line if you would not like the Z axis to move mc.mcCntlGcodeExecute(inst, "G90 G53 G0 Z0.0");--Move the Z axis all the way up mc.mcCntlToolChangeManual(inst, true); --Here is where I would like to then allow the user to move the machine mc.mcCntlSetLastError(inst, "Next tool == " .. tostring(selectedtool) .. " Current Tool == " .. tostring(currenttool)); mc.mcToolSetCurrent(inst, selectedtool); end if (mc.mcInEditor() == 1) then dofile ("load_modules.mcs") m6() end