var _COLOR = 0; macro "Pipette Tool - C000D1dD2cD2dD2eD3aD3bD3dD49D4cD58D5cD67D6bD76D7aD85D89D94D96D97D98Da2Da3Da7Db1Db6Dc1Dc5Dd1Dd5De2De3De4"{ samplePixelValue(); } macro "pipette" { samplePixelValue(); } macro "Fill Action Tool (f5) - C000T4b12f" { fill(); } macro "fill [f5]" { fill(); } function fill() { run("Subtract...", "value=65535"); run("Add...", "value="+_COLOR); } function samplePixelValue() { getCursorLoc(x, y, z, modifiers); _COLOR = getPixel(x,y); print(_COLOR); }